Skip to main content
PATCH
/
v1
/
products
/
{productId}
Update a product
curl --request PATCH \
  --url https://api.yuvexpay.com/v1/products/{productId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "description": "<string>",
  "amount": 500000.005,
  "isActive": true,
  "metadata": {}
}
'
{
  "product": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "name": "<string>",
    "description": "<string>",
    "amount": 123,
    "externalId": "<string>",
    "isActive": true,
    "createdAt": "2023-11-07T05:31:56Z"
  },
  "message": "<string>"
}

Authorizations

Authorization
string
header
required

API access token obtained from POST /oauth/token. Include as Authorization: Bearer {token}.

Path Parameters

productId
string<uuid>
required

The product ID.

Body

application/json
name
string
Required string length: 1 - 200
description
string
Maximum string length: 1000
amount
number | null

Set to null to remove the default price.

Required range: 0.01 <= x <= 1000000
isActive
boolean
metadata
object

Response

Product updated.

product
object
message
string