Skip to main content
POST
/
v1
/
products
/
{id}
/
items
/
redeem
Redeem Product Item
curl --request POST \
  --url https://dev.api.mufi.app/v1/products/{id}/items/redeem \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "product_item_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
'
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z",
  "product_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "item_id": 123,
  "redemption_count": 123,
  "redemption_quantity": 123,
  "is_fully_redeemed": true,
  "user": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "email": "jsmith@example.com",
    "first_name": "<string>",
    "last_name": "<string>"
  },
  "product": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "name": "<string>",
    "type": "admission",
    "redemption_quantity": 123
  },
  "redeemed_at": 123
}

Authorizations

Authorization
string
header
required

A JWT Access Token obtained from Google Cloud.

Path Parameters

id
string<uuid>
required

The product ID.

Body

application/json

The ID of the product item to redeem. Product items can only be redeemed once.

product_item_id
string<uuid>
required

The ID of the product item to redeem.

Response

A product item was successfully redeemed.

id
string<uuid>
required

The ID of the product item.

created_at
string<date-time>
required

The date and time the product item was created.

updated_at
string<date-time>
required

The date and time the product item was last updated.

product_id
string<uuid>
required

The ID of the product.

item_id
integer
required

The unique item ID as an integer of the product item. If NFT, this is the NFT ID too.

redemption_count
integer
required

How many times this item has been redeemed.

redemption_quantity
integer
required

How many times this item can be redeemed in total.

is_fully_redeemed
boolean
required

Whether this item has been fully redeemed.

user
object
required

The current owner of the product item.

product
object
required

The product this item belongs to.

redeemed_at
integer | null

The UNIX timestamp when the product item was fully redeemed. Null if not fully redeemed.