Skip to main content
POST
/
discounts
/
validate
Validate discount code
curl --request POST \
  --url https://api.pocketsflow.com/discounts/validate \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "code": "<string>",
  "productId": "<string>"
}
'

Authorizations

Authorization
string
header
required

Enter your Pocketsflow API key (format: pk_live_... or pk_test_...)

Body

application/json
code
string
required

Discount code

productId
string

Product ID to check if discount applies

Response

Discount is valid