Skip to main content
POST
/
v1
/
rewards
curl --request POST \
  --url https://{cluster}.voucherify.io/v1/rewards \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'X-App-Id: <api-key>' \
  --header 'X-App-Token: <api-key>' \
  --data '{
  "name": "Digital - Gift Card Reward",
  "type": "CAMPAIGN",
  "metadata": {
    "Type": "Gift"
  },
  "parameters": {
    "campaign": {
      "id": "camp_hC2GdqYtOmTT45zfhib62cK1",
      "balance": 3000
    }
  }
}'
{
  "id": "rew_Crmu3hu2FKZWZIML59AeAs1n",
  "name": "Material Reward",
  "type": "MATERIAL",
  "parameters": {
    "product": {
      "id": "prod_0b15f6b9f650c16990",
      "sku_id": "sku_0b1621b319d248b79f"
    }
  },
  "stock": "2",
  "redeemed": null,
  "attributes": {
    "image_url": "{{internalVoucherifyURL}}",
    "description": "Archie's Series"
  },
  "created_at": "2022-08-25T11:20:58.172Z",
  "updated_at": null,
  "metadata": {
    "Type": "Material"
  },
  "object": "reward"
}

Authorizations

X-App-Id
string
header
required
X-App-Token
string
header
required
Authorization
string
header
required

Body

application/json
  • Digital Reward
  • Material Reward
  • Pay with Points Reward
parameters
object
required
name
string
metadata
object

Response

200 - application/json
id
string
required
Example:
name
string
required
stock
integer | null
required
redeemed
integer | null
required
metadata
object
required
type
enum<string>
required
Available options:
CAMPAIGN,
COIN,
MATERIAL
created_at
string<date-time>
required
Example:
updated_at
string<date-time> | null
required
Example:
object
enum<string>
default:reward
required
Available options:
reward
attributes
object
parameters
object
  • Digital
  • Pay with Points
  • Material