Skip to main content
POST
/
api
/
canary
/
products
Create Product
curl --request POST \
  --url http://localhost:3000/api/canary/products \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "amount": 123,
  "currency": "<string>",
  "metadata": {
    "sku": "PROD-001",
    "category": "electronics"
  }
}
'
{
  "id": "product_001",
  "merchantId": "merchant_456",
  "name": "Airtime",
  "description": "Mobile phone airtime",
  "amount": 5000,
  "currency": "ZAR",
  "active": true,
  "metadata": {
    "category": "telecom",
    "provider": "vodacom"
  },
  "createdAt": "2025-01-15T10:30:00.000Z",
  "updatedAt": "2025-01-15T10:30:00.000Z"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Product details

name
string
required

The name of the product

amount
number
required

The price of the product in the smallest currency unit

currency
string
required

The three-letter ISO 4217 currency code

metadata
object
required

Optional custom metadata

Example:
{
"sku": "PROD-001",
"category": "electronics"
}
merchantId
string

The ID of the merchant whose balance is being requested. If omitted, defaults to the authenticated merchant.

description
string

A description of the product

active
boolean

Whether the product is active

Response

Product created successfully

id
string
required

Unique identifier

createdAt
string<date-time>
required
updatedAt
string<date-time>
required
merchantId
string
required
name
string
required
amount
number
required
currency
string
required
active
boolean
required
metadata
object
required
Example:
{ "sku": "PROD-001" }
deletedAt
string<date-time>
description
string