Skip to main content
POST
/
api
/
v1
/
vm
/
buyback
Sell back an item
curl --request POST \
  --url https://api.example.com/api/v1/vm/buyback \
  --header 'Content-Type: application/json' \
  --data '
{
  "item_id": "<string>"
}
'
{
  "success": true,
  "amount": 98.5
}
Sells an item back to the pack it was pulled from for its buyback_price. Sellback is an instant server-side transaction. No on-chain signing is required from the end user.

Request body

item_id
string
required
The item’s id from the purchase response (nfts[].id) or /api/v1/inventory/:user_id (items[].id).

Example request

POST /api/v1/vm/buyback
X-API-Key: <your_api_key>
Content-Type: application/json

{
  "item_id": "9XnY...mint_address"
}

Response

{
  "success": true,
  "amount": 98.5
}

Errors

StatusBodyMeaning
400{ "error": "Item not found" }Returned for missing item_id, unknown item_id, items already sold back, items locked into an active shipping order, or items that don’t belong to a tracked user.
400{ "error": "Item has expired" }Sellback window has closed. In sandbox, items expire 7 days after purchase.
400{ "error": "Transaction failed" }Sellback transaction failed (production-only).
400{ "error": "Item already has an active buyback session" }A sellback is already in progress (production-only).
429{ "error": "A buyback request for this item is already being processed" }Concurrent request, retry after a moment (production-only).
500{ "error": "An unexpected error occurred" }Internal server error
Sandbox does not emit 429, the in-progress envelope, or Transaction failed. Sandbox sellbacks are atomic with no concurrency control. Production may emit any of the rows above.

Pricing

Production: fmv × buyback_percent re-fetched from the live oracle at sellback time, with a voucher path of max(mint_price, fmv × buyback_percent). Sandbox: the amount returned equals the buyback_price that was assigned at buy/init time. Prices are frozen, not live, and there is no voucher logic. Sellback is always immediate and never settles real funds.
Sellback has a time window. Items can only be sold back within a limited period after being pulled. Check buyback_expires_at on inventory items.

Phygitals funds the buyback

The 85% buyback is underwritten by Phygitals, not the partner. When this endpoint returns success: true, the liquidity comes from us. Partners don’t post capital, don’t run a secondary market, and don’t carry sellback risk. You route the call, we pay the user. Pricing comes from our pricing oracle (powered by Alt), which provides the live FMV feed used to compute buyback_price on every inventory item. See platform overview → Phygitals funds the buybacks.