Get Products
The Get Products Endpoint is used to get the data of each product and denomination activated for the merchant.
Service EndpointsCopied!
Endpoint |
POST /api/merchant/products |
Request Header |
Authorization: Bearer <your_jwt_token_here> Content-Type: application/json |
Request ParametersCopied!
Name |
Type |
Required? |
Description |
---|---|---|---|
|
string |
Yes |
ID of the merchant |
|
string |
No |
ID of the product |
|
string |
No |
ID of the deno |
Only one of product_id
or deno_id
should be passed if used. If both are passed, deno_id
takes precedence.
Use Case 1: Get all products / denominationsCopied!
This returns the data of all active products and denominations for the merchant.
Request Body
{
"merchant_id": "M00001"
}
Use Case 2: Get denominations under a specific productCopied!
This returns the data of all active denos under the specified product_id
.
Request Body
{
"merchant_id": "M00001",
"product_id": "MLBBTH"
}
Use Case 3: Get denominations under a specific productCopied!
This returns the data of the specified deno_id
.
Request Body
{
"merchant_id": "M00001",
"deno_id": "MLBBTH100"
}
Response ParametersCopied!
Name |
Type |
Description |
---|---|---|
|
string |
ID of the product |
|
string |
Name of the product |
|
string |
Type of the product |
|
string |
ID of the deno |
|
string |
Name of the deno |
|
string |
Currency of the deno |
|
string |
Price of the deno |
|
string |
Error code |
|
string |
Message |
Sample ResponseCopied!
{
"data": [
{
"product_id": "GENSH",
"product_name": "Genshin Impact",
"product_type": "RELOAD",
"deno_id": "GENSH60",
"deno_name": "Genshin Impact - 60 Genesis Crystals",
"deno_currency": "USD",
"deno_price": "1,88"
},
{
"product_id": "ROO",
"product_name": "Ragnarok Origin"
"product_type": "RELOAD",,
"deno_id": "ROO40",
"deno_name": "Ragnarok Origin - 40 Nyan Berry",
"deno_currency": "USD",
"deno_price": "5.82"
},
]
}