Create Product
POST /v1/api/productsRequired scope: products:manage
Request body
Field
Type
Required
Description
name
string
Yes
Product name
description
string
No
Shown at checkout
price
number
Yes
Min: 0.01. USD for FIAT, token amount for CRYPTO.
currency_type
string
Yes
FIAT or CRYPTO
token
string
Conditional
Required if currency_type is CRYPTO
network
string
Conditional
Required if currency_type is CRYPTO
active
boolean
No
Default: true
Examples
curl -X POST https://apipay.byastra.ai/v1/api/products \
-H "X-Api-Key: ap_live_your_api_key" \
-H "Content-Type: application/json" \
-d '{
"name": "Pro Plan",
"description": "Monthly subscription",
"price": 49.00,
"currency_type": "FIAT"
}'curl -X POST https://apipay.byastra.ai/v1/api/products \
-H "X-Api-Key: ap_live_your_api_key" \
-H "Content-Type: application/json" \
-d '{
"name": "NFT Pass",
"price": 1.00,
"currency_type": "CRYPTO",
"token": "USDC",
"network": "BASE"
}'Response 201 Created
Last updated