novinzodevelopers
API referencePlugin contractFunctions

Create Hosted Payment

POST/functions/create-hosted-payment

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

storeId*string
Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$
connectionId*string
Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$
paymentId*string
Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$
orderId*string
Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$
amount*
email*string
returnUrl*string
cancelUrl*string
saveMethod?boolean|null
externalCustomerId?string|null

Response Body

application/json

curl -X POST "https://example.com/functions/create-hosted-payment" \  -H "Content-Type: application/json" \  -d '{    "storeId": "string",    "connectionId": "string",    "paymentId": "string",    "orderId": "string",    "amount": {      "amountMinorUnits": "string",      "currency": "AED"    },    "email": "string",    "returnUrl": "string",    "cancelUrl": "string"  }'
{  "_tag": "Created",  "externalId": "string",  "redirectUrl": "string",  "expiresAt": "string"}