Skip to main content
PATCH
/
companies
/
{company_id}
/
entitlements
/
{id}
Update Entitlement
curl --request PATCH \
  --url https://api.maplebilling.com/api/v1/companies/{company_id}/entitlements/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "adjust_for_quantity": "<unknown>",
  "aggregator_type": "OR",
  "name": "<unknown>",
  "possible_values": "<unknown>"
}
'
{
  "aggregator_type": "<string>",
  "id": "<string>",
  "key": "<string>",
  "name": "<string>",
  "possible_values": [
    "<string>"
  ],
  "type": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

Idempotency-Key
string

The idempotency key that will be used to ensure the request is only performed once

Path Parameters

company_id
string
required

The company ID with the prefix 'cmp_'.

id
string
required

The resource ID

Body

application/json
adjust_for_quantity
null | boolean

Whether the entitlement should be multiplied by the quantity selected

aggregator_type
null | enum<string>

The aggregator type of the entitlement in case a customer has different values for different subscriptions. This can be one of OR, AND (for BOOL), ADD, MINIMUM, MAXIMUM (for NUMBER), COALESCE (for TEXT or ENUM)

Available options:
OR,
AND,
ADD,
MINIMUM,
MAXIMUM,
COALESCE
name
null | string

The name of the entitlement

possible_values
null | string[]

The possible values for the entitlement of enum type

Response

200 - application/json

OK

aggregator_type
string

The aggregator type of the entitlement

id
string

The ID of the entitlement

key
string

The key of the entitlement

name
string

The name of the entitlement

possible_values
string[]

The possible values of the entitlement if the type is ENUM

type
string

The type of the entitlement that can be BOOL, TEXT, NUMBER or ENUM