{
"statusCode": 201,
"time": "2022-01-12T16:32:37.178Z",
"data": {
"code": "_PM3TX-7nVNY4K1pDqz8u",
"hostedUrl": "https://payment.fizen.io/commerce/charges/_PM3TX-7nVNY4K1pDqz8u"
},
}
{
"statusCode": 401,
"message": "Unauthorized"
}
curl --location --request POST 'https://pay-api.fizen.io/api/integration/v1/charges' \
--header 'X-FP-API-KEY: 7abd3993-daf7-4322-84c6-c86e04b3d884' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "Charge name",
"description": "Charge description",
"localPrice": {
"amount": 100,
"currency": "USD"
},
"metadata": {
"orderId": "order-id1",
"orderKey": "key1",
"source": "some-ecommerce"
},
"logoUrl": "https://logo-url.com/image.png",
"redirectUrl": "https://ecommerce-endpoint.com/redirect-url",
"cancelUrl": "https://ecommerce-endpoint.com/cancel-url"
}'
{
"statusCode": 201,
"time": "2022-01-12T16:32:37.178Z",
"data": {
"code": "OST1FNY35QDL",
"hostedUrl": "https://payment.fizen.io/commerce/charges/OST1FNY35QDL"
},
}