PUT
/
rewards
/
{id}
curl --request PUT \
  --url https://v2.firstpromoter.com/api/v2/company/rewards/{id} \
  --header 'Account-ID: <account-id>' \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "name": "<string>",
  "is_promoter_reward": true,
  "promoter_reward_type": "sale",
  "tier_reward_mode": "tier_commission_mode",
  "tier_level": 123,
  "coupon": "<string>",
  "hide_reward": true,
  "duration": "once",
  "duration_in_months": 123,
  "max_redemptions": 123,
  "should_create_provider_coupon": true,
  "new_customers_only": true,
  "provider_coupon_id": "<string>",
  "schemas": [
    {
      "unit": "cash",
      "amount": 123,
      "flat_amount": true,
      "rules": [
        {
          "type": "customer_sales_count",
          "condition": "less than",
          "filter_by": "price",
          "value": 123,
          "operator": "and"
        }
      ]
    }
  ]
}'
{
  "id": 123,
  "name": "<string>",
  "is_promoter_reward": true,
  "promoter_reward_type": "sale",
  "coupon": "<string>",
  "editable": true,
  "hide_reward": true,
  "provider_coupon_id": "<string>",
  "duration": "once",
  "duration_in_months": 123,
  "max_redemptions": 123,
  "new_customers_only": true,
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z",
  "provider": "<string>",
  "tier_reward_mode": "tier_commission_mode",
  "tier_level": 123,
  "schemas": [
    {
      "unit": "cash",
      "amount": 123,
      "flat_amount": true,
      "rules": [
        {
          "type": "customer_sales_count",
          "condition": "less than",
          "filter_by": "<string>",
          "value": 123,
          "operator": "and"
        }
      ]
    }
  ]
}

Authorizations

Authorization
string
header
required

Access token passed as a Bearer token in the Authorization header

Headers

Account-ID
string
required

Account identifier that specifies which account is making the request

Example:

"acc_123456"

Path Parameters

id
integer
required

ID of the reward to update

Body

application/json

Response

200
application/json

Reward updated successfully

The response is of type object.