DocsAPI ReferenceVoucher/bff/voucher/add
postVoucherAdmin BFF

/bff/voucher/add

Creates a new voucher with the specified parameters. The voucher code must be unique within the organisation and will be converted to uppercase.

VoucherpostBffVoucherAdd

Parameters

10 body

10 total
Body · 10
codestringRequired

Unique voucher code (will be converted to uppercase).

typestringRequired

Discount type: fixed, percentage, free-credit, or free-product.

valuestringRequired

Discount value (e.g., "100" for fixed, "10" for 10% percentage).

usageLimitnumber

Maximum number of uses. Omit for unlimited.

notestring

Internal note for administrative purposes.

activeboolean

Whether voucher is active immediately (default: false).

isOrderSingletonboolean

Limit to one use per order (default: false).

validFromstring

ISO date string for validity start.

validTostring

ISO date string for validity end.

costnumber | null

Money the voucher cost when issued (organisation default currency). Use null to leave unset → resulting credits applied 1:1 to money. Use 0 to mark as gifted → resulting credits carry zero money value. Any positive number is the real cash equivalent of the voucher.

Request

POST /bff/voucher/add

post
curl -X POST "https://api.bizkithub.com/bff/voucher/add" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
  "code": "SUMMER2024",
  "type": "percentage",
  "value": "10",
  "usageLimit": 100,
  "note": "Summer campaign",
  "active": false,
  "isOrderSingleton": false,
  "validFrom": "2024-01-01T00:00:00Z",
  "validTo": "2024-12-31T23:59:59Z",
  "cost": 0
}'

Response

Created voucher confirmation.

{
  "code": "example_code"
}

All response codes

1 status code documented

Need an API key?

All BizKitHub API endpoints require authentication via API key.

Get API Key