POST /order-cancellations

Cancels an order.

Servers

Request headers

Name Type Required Description
Content-Type String Yes The media type of the request body.

Default value: "application/json"

Request body fields

Name Type Required Description
canceledTime String No

Date and time when an order is canceled. By default, this occurs when status is confirmed, unless draft is specified.

description String No

Description of the cancellation reason in free form.

prorated Boolean No

Specifies if the customer gets a pro-rata credit for the time remaining between churnTime and order next renewal time.

Default value: false

proratedInvoiceId String No

ID of the invoice on which the cancellation proration is calculated.

createdTime String No

Date and time when the resource is created. This value is set automatically when the resource is created.

churnTime String No

Date and time when the order is deactivated. If this field and churnTimePolicy are omitted, this value defaults to the current time.

churnTimePolicy String No

Specifies when the order is to be deactivated. The churnTimePolicy takes precedence over the churnTime in request.

Valid values:

  • null
  • "at-next-renewal"
  • "now"
status String No

Status of the order cancellation.

Valid values:

  • "confirmed"
  • "completed"
  • "revoked"
  • "draft"

Default value: "confirmed"

id String No

ID of the cancellation.

_links[] Array No

Related links.

_links[].href String No

Link URL.

_links[].rel String No

Type of link.

Valid values:

  • "self"
orderId String Yes

ID of the canceled order.

updatedTime String No

Date and time when the resource is updated. This value is set automatically when the resource is updated.

lineItemSubtotal Object No

Subtotal of the line items added after the order cancellation.

lineItemSubtotal.amount Number No

Subtotal amount of the line items.

lineItemSubtotal.currency String No

Currency code in ISO 4217 format.

canceledBy String No

Specifies who initiated the cancellation.

Valid values:

  • "merchant"
  • "rebilly"
  • "customer"

Default value: "customer"

reason String No

Reason for the cancellation.

Valid values:

  • "bugs-or-problems"
  • "billing-failure"
  • "risk-warning"
  • "missing-features"
  • "other"
  • "did-not-want"
  • "contract-expired"
  • "did-not-use"
  • "too-expensive"
  • "do-not-remember"

Default value: "other"

lineItems[] Array No

Items to be added to the new invoice. Proration item is generated and added automatically.

lineItems[].periodEndTime String No

Date and time when the service period ends for this item.

lineItems[].description String No

Description of the line item.

lineItems[].updatedTime String No

Date and time when the resource is updated. This value is set automatically when the resource is updated.

lineItems[].unitPriceAmount Number Yes

Unit price of the line item.

lineItems[].periodStartTime String No

Date and time when the service period begins for this item.

lineItems[].createdTime String No

Date and time when the resource is created. This value is set automatically when the resource is created.

lineItems[].quantity Integer Yes

Quantity of the line item.

lineItems[].type String Yes

Type of invoice line item.

Valid values:

  • "credit"
  • "debit"
lineItems[].unitPriceCurrency String Yes

Currency code in ISO 4217 format.

appliedInvoiceId String No

ID of the invoice on which the cancellation fees or credits are applied.

How to start integrating

  1. Add HTTP Task to your workflow definition.
  2. Search for the API you want to integrate with and click on the name.
    • This loads the API reference documentation and prepares the Http request settings.
  3. Click Test request to test run your request to the API and see the API's response.