curl --request POST \
--url https://uat-api.clinkbill.com/api/price \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--header 'X-Timestamp: <x-timestamp>' \
--data '
{
"productId": "prd_xxxxx",
"currency": "USD",
"unitAmount": 29.99,
"priceType": "recurring",
"recurringDetails": {
"interval": "month",
"intervalCount": 1,
"trialPeriodDays": 7,
"pricingModel": "flat_rate"
},
"isDefaultPrice": true
}
'{
"code": 123,
"msg": "<string>",
"data": {
"priceId": "<string>",
"priceSnapshotId": "<string>",
"productId": "<string>",
"currency": "USD",
"unitAmount": 123,
"priceType": "one_time",
"recurring": {
"interval": "day",
"trialPeriodDays": 123,
"pricingModel": "flat_rate",
"transformQuantity": {
"divideBy": 123,
"round": "up"
},
"intervalCount": 123
},
"active": true,
"createTime": 123
}
}"<string>"Price
Create Price
Create a price for an existing product under your current merchant account.
POST
/
price
curl --request POST \
--url https://uat-api.clinkbill.com/api/price \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--header 'X-Timestamp: <x-timestamp>' \
--data '
{
"productId": "prd_xxxxx",
"currency": "USD",
"unitAmount": 29.99,
"priceType": "recurring",
"recurringDetails": {
"interval": "month",
"intervalCount": 1,
"trialPeriodDays": 7,
"pricingModel": "flat_rate"
},
"isDefaultPrice": true
}
'{
"code": 123,
"msg": "<string>",
"data": {
"priceId": "<string>",
"priceSnapshotId": "<string>",
"productId": "<string>",
"currency": "USD",
"unitAmount": 123,
"priceType": "one_time",
"recurring": {
"interval": "day",
"trialPeriodDays": 123,
"pricingModel": "flat_rate",
"transformQuantity": {
"divideBy": 123,
"round": "up"
},
"intervalCount": 123
},
"active": true,
"createTime": 123
}
}"<string>"Authorizations
Your secret API key obtained from the Clink dashboard (Developers section)
Headers
Current timestamp in milliseconds since Unix epoch (required for request signing)
Example:
"1783513683000"
Body
application/json
Parameters required to create a price by API
Unique identifier of the product
Three-letter ISO currency code
Available options:
USD, EUR, JPY, GBP, AUD, CAD, CNY, HKD, SGD, KRW, AED, THB, IDR, PHP, MYR, BRL, INR Unit amount for one-time or recurring base price
Example:
29.99
Price type
Available options:
one_time, recurring Details of the Subscription
Show child attributes
Show child attributes
Regional pricing priority. Lower values have higher priority.
Whether this price should be the product default price