The Subscription Entity

Description

A subscription represents a purchased offering related to a business. It includes details such as the buyer, pricing, trial period, and the subscription's lifecycle state.

Entity Properties

NameDescriptionTypeRequired
uidThe entity UIDstringYes
created_atThe creation date and time of the objectstring (date-time)Yes
updated_atThe last updated date and time of the objectstring (date-time)Yes
display_nameThe subscription display namestringYes
is_activeIndicates whether the subscription is active (not canceled and not expired)booleanNo
offering_uidThe underlying directory offering UIDstringYes
offering_typeCategory of the offering. Possible values: package, app, sms, staff_slot.stringNo
purchase_stateCurrent subscription state. Possible values: pending, purchased, canceled, expired. Default: pending.stringNo
cancellation_dateThe date when the subscription was canceledstring (date-time)No
expiration_dateThe date when the subscription will expire (or expired)string (date-time)No
buyer_uidThe actor of the action, typically the staff UIDstringYes
business_uidThe business associated with the subscriptionstringYes
purchase_priceThe purchase price at the time the subscription was creatednumberYes
purchase_currencyThe currency used at the time of purchase. Possible values: USD, EUR, GBP.stringYes
payment_typeDefines the payment type. Possible values: monthly, annual, free, single_charge, bundle, external.stringYes
bundled_from_subscription_uidThe subscription UID that this subscription is bundled fromstringNo
charged_byDefines who charges for this subscription. Possible values: partner, platform.stringYes
trial_typeIndicates trial type. Possible values: no_trial, automatic_charge, expire. Default: no_trial.stringNo
next_charge_dateThe start date of the next billing cycle, or null if the subscription is set to expire.string (date-time)No

Example

{
  "uid": "c33f32c-95ae-4e8f-9f65-18bba589cb43",
  "created_at": "2024-01-01T09:00:00Z",
  "updated_at": "2024-03-20T12:34:56Z",
  "display_name": "Premium 10",
  "is_active": true,
  "offering_uid": "bc33f12d-98ee-428f-9f65-18bba589cb95",
  "offering_type": "package",
  "purchase_state": "purchased",
  "cancellation_date": "",
  "expiration_date": "",
  "buyer_uid": "user_12345",
  "business_uid": "biz_67890",
  "purchase_price": 99.99,
  "purchase_currency": "USD",
  "payment_type": "monthly",
  "bundled_from_subscription_uid": "",
  "charged_by": "platform",
  "trial_type": "no_trial",
  "next_charge_date": "2025-03-20T12:34:56Z"
}