api-docs v5.116.0

API Docs

Table of contents


Billing_Promo

Billing Promo - Delete

Back to top

Delete a specific billing promo

DELETE /billing-promos/:id

Headers - Header

Name Type Description
Authorization string

key to place the API token to using the grant 'Bearer'

Header examples

Authorization-Example

{
  "Authorization": "Bearer <your-api-token>"
}

Examples

Example usage:

curl "https://yourdomain.com/billing-promos/<billing-promo-id>" \
  -X DELETE \
  -H "Authorization: Bearer <your-api-token>"

Success response

Success response - Success 200

Name Type Description
id string
createdAt number

timestamp

Default value: currentTime
createdBy number

account uid

organization string
type string Allowed values: rewards,buy-n-take-m
validityStartAt number

timestamp

Default value: currentTime
validityEndAt number

timestamp

productType string Allowed values: service,inventory-variant
product string
productN number Default value: 1
rewardProductType string Default value: productType
rewardProduct string Default value: product
rewardProductM number Default value: productN

Success response example

Success response example - Success-Response:

HTTP/1.1 200 OK
{
  "id": "id-1",
  "createdAt": 1564661697125,
  "createdBy": "some-uid"
}

Billing Promo - Find

Back to top

Get list of billing promos

GET /billing-promos

Headers - Header

Name Type Description
Authorization string

key to place the API token to using the grant 'Bearer'

Header examples

Authorization-Example

{
  "Authorization": "Bearer <your-api-token>"
}

Examples

Example usage:

curl "https://yourdomain.com/billing-promos" \
  -X GET \
  -H "Authorization: Bearer <your-api-token>"

Success response

Success response - Success 200

Name Type Description
billingPromos object[]

array of billingPromo

billingPromos.id string
billingPromos.createdAt number

timestamp

Default value: currentTime
billingPromos.createdBy number

account uid

billingPromos.organization string
billingPromos.type string Allowed values: rebillingPromos.wards,buy-n-take-m
billingPromos.validityStartAt number

timestamp

Default value: currentTime
billingPromos.validityEndAt number

timestamp

billingPromos.productType string Allowed values: service,inventory-variant
billingPromos.product string
billingPromos.productN number Default value: 1
billingPromos.rewardProductType string Default value: productType
billingPromos.rewardProduct string Default value: product
billingPromos.rewardProductM number Default value: productN

Success response example

Success response example - Success-Response:

HTTP/1.1 200 OK
[
  {
    "id": "id-1",
    "createdAt": 1564661697125,
    "createdBy": "some-uid"
  },
  {
    "id": "id-2",
    "createdAt": 1564661697125,
    "createdBy": "some-uid"
  }
]

Billing Promo - Get

Back to top

Get a specific billing promo

GET /billing-promos/:id

Headers - Header

Name Type Description
Authorization string

key to place the API token to using the grant 'Bearer'

Header examples

Authorization-Example

{
  "Authorization": "Bearer <your-api-token>"
}

Examples

Example usage:

curl "https://yourdomain.com/billing-promos/<billing-promo-id>" \
  -X GET \
  -H "Authorization: Bearer <your-api-token>"

Success response

Success response - Success 200

Name Type Description
id string
createdAt number

timestamp

Default value: currentTime
createdBy number

account uid

organization string
type string Allowed values: rewards,buy-n-take-m
validityStartAt number

timestamp

Default value: currentTime
validityEndAt number

timestamp

productType string Allowed values: service,inventory-variant
product string
productN number Default value: 1
rewardProductType string Default value: productType
rewardProduct string Default value: product
rewardProductM number Default value: productN

Success response example

Success response example - Success-Response:

HTTP/1.1 200 OK
{
  "id": "id-1",
  "createdAt": 1564661697125,
  "createdBy": "some-uid"
}

Billing Promo - Post

Back to top

Create billing promo

POST /billing-promos

Headers - Header

Name Type Description
Authorization string

key to place the API token to using the grant 'Bearer'

Header examples

Authorization-Example

{
  "Authorization": "Bearer <your-api-token>"
}

Parameters - Parameter

Name Type Description
createdAt number optional

timestamp

Default value: currentTime
organization string
type string Allowed values: rewards,buy-n-take-m
validityStartAt number optional

timestamp

Default value: currentTime
validityEndAt number optional

timestamp

productType string Allowed values: service,inventory-variant
product string
productN number optional Default value: 1
rewardProductType string optional Default value: productType
rewardProduct string optional Default value: product
rewardProductM number optional Default value: productN

Examples

Example usage:

curl "https://yourdomain.com/billing-promos" \
  -X POST \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer <your-api-token>" \
  -d '{
    "organization": "org-id",
    "type": "rewards",
    "productType": "service",
    "product": "some-product-id"
  }'

Parameters examples

json - Request-Example

{
  "organization": "org-id",
  "type": "rewards",
  "productType": "service",
  "product": "some-product-id"
}

Success response

Success response - Success 200

Name Type Description
id string
createdAt number

timestamp

Default value: currentTime
createdBy number

account uid

organization string
type string Allowed values: rewards,buy-n-take-m
validityStartAt number

timestamp

Default value: currentTime
validityEndAt number

timestamp

productType string Allowed values: service,inventory-variant
product string
productN number Default value: 1
rewardProductType string Default value: productType
rewardProduct string Default value: product
rewardProductM number Default value: productN

Success response example

Success response example - Success-Response:

HTTP/1.1 200 OK
{
  "id": "id-1",
  "createdAt": 1564661697125,
  "createdBy": "some-uid"
}

results matching ""

    No results matching ""