The Subscription Object

Attributes

This object represents a subscription that can be associated with a customer.

Fields WHITELABEL computes

billing_cycles.scheduling_date, retries.stopped, retries.attempts_made, retries.outcome and retries.next_retry_at are computed by WHITELABEL from the subscription’s own state. They are read-only: sending them is ignored on Create Subscription and on Update Subscription, and the values you read back are always WHITELABEL’s.

idstring

The unique identifier of the subscription (MAX 64 ; MIN 36).

Example: 7304911d-5df9-429e-8488-ad41abea1a4c

namestring

The subscription name (MAX 255; MIN 3).

Example: sub_001

descriptionstring

The subscription description (MAX 255; MIN 3).

Example: Servicio de streaming

account_idstring

The unique identifier of the account that will have the subscription plan available to use (MAX 64 ; MIN 36).

Example: 2404911d-5df9-429e-8488-ad41abea1a4b

merchant_referencestring

Identification of the subscription plan (MAX 255; MIN 3).

Example: 001_marzo_23

soft_descriptorstring

Statement descriptor shown on the cardholder’s bank statement (MAX 255). When set, it is propagated to every rebill payment generated by the subscription engine. Length and formatting limits vary by provider; see Statement descriptor on recurring payments.

Example: ACME SUBSCRIPTION

countrystring

The subscription’s country.

Example: CO

statusenum

Status of the subscription.

Possible values:

  • CREATED = Transitory status while the initial payment hasn’t been processed yet. Only occurs when the subscription is created with initial_payment_validation: true; it transitions to ACTIVE once the first payment succeeds (or to CANCELED if it fails and retries are exhausted).
  • ACTIVE = The subscription has been created with an associated customer and is already active.
  • TRIALING = The subscription is inside a plan’s leading trial phase (see plan_id/current_phase). Transitions to ACTIVE automatically once the trial ends — this is webhooked like any other status change.
  • PAST_DUE = A recurring charge failed and the subscription is awaiting recovery. It keeps billing and can still be canceled; the next successful charge returns it to ACTIVE — or to TRIALING if the trial phase is still running — and each transition is webhooked. If the status is not enabled for your account, a failed charge leaves the subscription in ACTIVE while the retries run instead. See Retries.
  • PAUSED = The subscription has been paused and can be reactivated.
  • COMPLETED = The subscription is completed because it reached the end date and time.
  • CANCELED = Subscription canceled. See cancellation_source for what triggered it.
cancellation_sourceenum

What caused the subscription to be canceled. Only set once the subscription reaches CANCELED; null otherwise.

Possible values:

  • MERCHANT = You canceled the subscription, through Cancel Subscription or the dashboard.
  • SYSTEM = WHITELABEL canceled the subscription automatically. This includes a subscription created with initial_payment_validation: true whose first payment did not succeed.
  • PLAN_CHANGE = The subscription was replaced as part of a plan change. A new subscription continues the customer’s billing under the new plan.
  • RETRIES_EXHAUSTED = Retries for a billing cycle ended without a successful payment while the subscription had retries.cancel_on_exhausted_retries set to true. See Retries.

Treat this field as open-ended. New values can be introduced as WHITELABEL adds cancellation behaviors, so handle an unrecognized value gracefully rather than switching exhaustively over the list above. RETRIES_EXHAUSTED is the most recent addition.

plan_idstring

The unique identifier of the plan this subscription was created from, if any (MAX 64; MIN 36). Only present when the subscription is linked to a plan — absent (not null) for subscriptions created with a raw amount/frequency instead of a plan_id.

Example: 00000000-0000-4000-8000-000000000001

plan_assigned_atTimestamp

When the subscription is linked to a plan, the moment the plan was attached — at creation from a plan, migration onto a plan, or a plan change. Only present on plan-linked subscriptions.

previous_subscription_idstring

When this subscription was created by a plan change (switching an existing subscription to a different plan), this is the id of the subscription it replaced. Only present in that case.

Scheduled changes made with the plan_change object on Update Subscription apply in place and never set this field.

phasesarray of objects

The linked plan’s phase definitions, exactly as the plan declares them. Only present on plan-linked subscriptions whose plan has phases.

This is the plan’s ladder, not this subscriber’s. Unlike billing_phases it includes the terminal REGULAR phase, and it is read from the plan rather than snapshotted at creation, so it reflects the plan as it stands today. On the REGULAR row duration, frequency and amount are all null — that phase runs until the subscription ends and its price resolves from the plan at every billing.

Use billing_phases for what this subscription will actually be charged, and phases to describe the plan behind it.

Hide properties
orderint
namestring
typeenum

TRIAL or REGULAR.

durationobject

How long the phase lasts, as type and value. null on the REGULAR phase.

frequencyobject

How often the phase bills, as type and value. null on the REGULAR phase.

amountobject

The phase price, as currency and value. null on the REGULAR phase.

total_paymentsint

How many charges the phase covers. null on the REGULAR phase.

country_pricesarray of objects

Per-country overrides of the phase price, each with a country and an amount. Empty when the phase has none.

current_phaseenum

Which phase of the linked plan’s trial ladder the subscription is currently in. Only present on plan-linked subscriptions. Absent as well when the subscription was created by a plan change with skip_trial: true — that subscription is plan-linked and its plan has phases, but it never enters the ladder.

Possible values: TRIAL, REGULAR.

current_phase_endTimestamp

When the phase named by current_phase hands over to the next one — for a subscription in its trial, the moment it switches to the regular price. It is the end of the last billing period the phase covers, so on the final period of a trial it equals current_period_end.

null on subscriptions that are not inside a phase: those with no plan, and plan-linked ones that already left the ladder and are on the plan’s regular price.

Example: 2023-03-16T20:00:00.786342Z

billing_phasesarray of objects

The plan’s leading TRIAL phases, snapshotted for this subscriber’s country at creation time. Only present on plan-linked subscriptions whose plan has phases. Absent as well when the subscription was created by a plan change with skip_trial: true — that subscription is plan-linked and its plan has phases, but it never enters the ladder.

The terminal REGULAR phase is never included here. Its price isn’t pinned at creation — it resolves from the plan at every billing, so plan price edits reach running subscriptions. When current_phase is REGULAR, the ladder is exhausted and the subscription bills the plan’s regular price; there’s no corresponding row in this array for that.
Hide properties
orderint
typeenum

Always TRIAL — see the note above.

namestring

Mirrors the phase’s own required name.

amountobject
Hide properties
currencystring
valuenumber
frequencyobject
Hide properties
typeenum

DAY, WEEK, MONTH, or YEAR.

valueint
start_cycleint
end_cycleint
amountobject

Specifies the subscription amount object, with the value and currency.

Hide properties
currencyenum

The currency used to make the payment (MAX 3; MIN 3; ISO 4217).

Possible enum values: Check the Country reference.

valuenumber

The payment amount (multiple of 0.0001).

Example: 12100.00

frequencyobject

The frequency defined for the payment subscription. If not set, defaults are MONTH for type and 1 for value.

Hide properties
typeenum

The type of interval the subscription will have in time. If not set, always MONTH by default.

Possible enum values: DAY, WEEK, MONTH, or YEAR.

On a subscription whose payment_method.type is PIX_AUTOMATIC, only WEEK, MONTH and YEAR with value 1 are accepted — every other combination is rejected with 400 INVALID_PARAMETERS. See Pix Automático.

valueint

The value between each interval the subscription will have in time. If not set, always 1 by default.

Example: 1

billing_cyclesobject

Specifies the billing_cycles object.

Hide properties
totalnumber

Total amount of billing cycles.

Example: 10

currentnumber

The next billing cycle to be charged — not the cycle currently in progress.

Subscriptions are billed in advance: the charge for a cycle fires at the start of the period it pays for, and the counter moves on as soon as that charge is dispatched. While the subscriber is inside the period paid for by cycle N, this field therefore already reads N + 1. The cycle in progress is current - 1. One exception: the counter stops on the last cycle. Once current reaches billing_cycles.total — or availability.finish_at passes — the subscription is marked COMPLETED and current is frozen at total for the whole of that final period, so there the cycle in progress is current, not current - 1.

A subscription created with a two-cycle trial reads current: 2 for the whole of the first trial period, and current: 3 during the second — the trial is still running even though current has passed the trial cycle count. current_period_start and current_period_end tell you when the current period runs; they do not tell you whether the subscription is still in its trial. To locate the trial, compare the cycle in progress (current - 1) against trial_period.billing_cycles — legacy trial_period subscriptions stay ACTIVE and carry no current_phase while trialing.

Because the counter advances when a charge is dispatched rather than when it succeeds, a failed cycle never rolls it back — current has already moved on before the first retry runs, and it stays there whether or not the retries eventually collect.

The first cycle is the other exception: when initial_payment_validation is true, its counter moves only once that first charge succeeds. While the charge is pending or being retried, current stays 1; if it is never collected the subscription is cancelled with current still 1. From the second cycle onward the dispatch-time rule applies.

Example: 2

next_atTimestamp

The date of the next payment for the subscription. Always present. When current_period_end is returned it is this same instant.

Example: 2023-02-16T20:00:00.786342Z

scheduling_dateTimestamp

When the debit instruction is handed to the Pix rail — exactly next_at minus four days. Present only on PIX_AUTOMATIC subscriptions that WHITELABEL executes, and only for organizations the four-day scheduling lead is enabled for; absent — not null — everywhere else. Returned by Retrieve Subscription, on List Subscriptions items, and on subscription webhook payloads. See Pix Automático.

Example: 2026-11-27T00:00:00Z

current_period_startTimestamp

The start of the billing period currently in progress: one billing cadence before current_period_end. It is derived from the schedule, not from payments, so a subscription reports its window from the moment it is created, before any charge has been attempted.

The cadence used is the one that scheduled the window. Inside a plan phase — a trial, an introductory price, any phase of a plan — that is the phase’s own step, so a 14-day trial reports 14-day periods even when the plan bills monthly. On the first cycle after a phase ends the window still measures the cadence of the phase that scheduled it.

It never falls before availability.start_at: the first period of a subscription starts when the subscription does.

Returned on Retrieve Subscription, on List Subscriptions and on subscription webhook payloads.

Terminal subscriptions report their final billing period rather than going null — a CANCELED or COMPLETED subscription keeps the window it last had, the same way PAUSED freezes its window instead of advancing it. null, together with current_period_end, only when the subscription has no recurring cadence at all. On REST responses the keys may be omitted entirely instead of sent as null — treat null and missing as the same thing.

Example: 2023-01-16T20:00:00.912480Z

current_period_endTimestamp

The end of the billing period currently in progress, which is also when the next charge is scheduled. Always equal to billing_cycles.next_at.

This pair describes the period the subscription is scheduled into, not one that is necessarily paid for: if a cycle’s charge failed and its retries are still running, the window has already moved to the period that charge was meant to open. A PAUSED subscription keeps the window it was paused inside rather than advancing it, and a CANCELED or COMPLETED subscription keeps its final window rather than clearing it — in both cases current_period_end can be well in the past, so check status before reading it as an upcoming date.

null under the same conditions as current_period_start; the two are always returned together.

Example: 2023-02-16T20:00:00.786342Z

billing_dateobject

[Optional] Specifies the billing_date object. Mutually exclusive with the frequency object.

Hide properties
typestring

The type of billing_date the subscription will have in time. PREPAID, POSTDATE, DAY. If not set, the creation date for the plan will be set by default.

Example: DAY

daynumber

The day of the month to charge the subscription if the type is set to DAY. Always 1 by default.

Example: 2

customer_payerobject

Specifies the customer_payer object.

Hide properties
id*string

The unique identifier of the customer (MAX 255; MIN 3).

Example: 3t04911d-5df9-429e-8488-ad41abea1a2c

payment_methodobject

Specifies the payment_method object.

Hide properties
typeenum

Type of the payment method.

Possible enum values: CARD, PAYPAL_ENROLLMENT, PIX_AUTOMATIC

PIX_AUTOMATIC bills a Brazilian Pix Automático mandate, is matched case-insensitively, and accepts only the cadences the mandate can express — see Pix Automático.

tokenstring

The one-time use payment method token provided by WHITELABEL SDK (MAX 64; MIN 36).

Example: 9104911d-5df9-429e-8488-ad41abea1a4b

vaulted_tokenstring

The vaulted token of the stored payment method (MAX: 64; MIN: 36).

Example: 6104911d-5df9-429e-8488-ad41abea1a4b

cardobject

Specifies the card object.

Hide properties
verifyboolean

Using amount = 0 and verify = true, you can verify the user’s card without authorizing a real amount.

Possible values: true or false.

card_dataobject

Specifies the card_data object.

Hide properties
numberstring

Card’s number without any separators (MAX 19; MIN 8) - only available for PCI certified merchants.

Example: 4507990000000010

expiration_monthnumber

Card’s expiration month - MM (MAX 2; MIN 2) - only available for PCI certified merchants.

Example: 10

expiration_yearnumber

Card’s expiration year - YYYY (MAX 4; MIN 4) - only available for PCI certified merchants.

Example: 2025

security_codenumber

Card’s security code (MAX 4; MIN 3) - only available for PCI certified merchants.

Example: 123

holder_namestring

Cardholder’s full name as it appears on the card (MAX 26; MIN 3) - only available for PCI certified merchants.

Example: JOHN DOE

trial_periodobject

Specifies the trial_period object.

Hide properties
billing_cyclesnumber

Total amount of billing cycles the free_trial should apply to.

Example: 1

amountobject

Amount to be discounted for the trial period.

Hide properties
currencystring

The currency used to make the trial period. (ISO 4217 MAX 3; MIN 3).

Example: COP

valuenumber

The trial period amount value (multiple of 0.0001).

Example: 10

availabilityobject

Specifies the availability object. The dates that the subscription will be available. If null the start date will be the day of the creation and it will not have a finish date.

Hide properties
start_atTimestamp

The start date that the subscription will be available to use.

Example: 2024-01-16T00:00:00.786342Z

finish_atTimestamp

The end date until the subscription will be available to use.

Example: 2024-05-26T20:00:00.786342Z

retriesobject

Specifies the retries object. If we need to retry declined transactions in WHITELABEL and the amount if necessary.

Hide properties
retry_on_declinebool

If we should retry a payment or not after a first decline. False by default.

Example: true

amountnumber

The number of retries that the subscription plan will have to completion. The maximum equals your environment’s configured retry schedule length (6 in production). A value above the cap is rejected with 400 (Max retries attempts exceeded). Max: 6

Example: 4

strategystring

How the timing of each retry is decided. One of:

  • DEFAULT — the fixed retry schedule.
  • SMART — machine-learning-based retry timing, applied from the second retry onward. Available to all accounts.
  • CUSTOM_SCHEDULE — the per-attempt schedule array you provide.

Treat this field as open-ended. New values can be introduced as WHITELABEL adds retry behaviors, so handle an unrecognized value gracefully rather than switching exhaustively over the list above. SMART is the most recent addition.

Example: SMART

stop_on_hard_declinebool

When true and a hard decline is detected, retries stop for the current billing cycle only. On its own, the subscription stays ACTIVE and billing advances to the next cycle. If cancel_on_exhausted_retries is also true, the subscription is canceled instead.

Example: true

cancel_on_exhausted_retriesbool

When true, the subscription is canceled once retries for a billing cycle end without a successful payment, instead of advancing to the next cycle. cancellation_source is set to RETRIES_EXHAUSTED and a single SUBSCRIPTION.CANCEL webhook is emitted. Defaults to false. Create-only: it cannot be changed later — Update Subscription rejects a different value with 400. The cancellation itself is final — see Retries.

Example: true

stoppedbool

Whether retries for the current cycle have stopped. Present only while the subscription is PAST_DUE or has cancel_scheduled pending; omitted otherwise.

Whether this field (and attempts_made, outcome, next_retry_at below) keeps reporting the last cycle’s retry snapshot once the subscription reaches CANCELED, or is omitted at that point, is pending product confirmation — verify against a live response before depending on it.

attempts_madeint

Retry attempts made for the current cycle so far. Present only while the subscription is PAST_DUE or has cancel_scheduled pending; omitted otherwise.

outcomeenum

How the current cycle’s retries resolved. One of RECOVERED, EXHAUSTED, or ABANDONED (retries stopped by a cancellation before exhausting on their own). Present only while the subscription is PAST_DUE or has cancel_scheduled pending; omitted otherwise.

next_retry_atTimestamp

When the next retry is scheduled. Present only while the subscription is PAST_DUE with retries still running; omitted otherwise.

profileenum

The fixed retry ladder the subscription follows instead of the configurable schedule. Always PIX_AUTOMATIC. Present only on PIX_AUTOMATIC subscriptions that WHITELABEL executes; absent — not null — on every other payment method, together with max_attempts, min_gap_hours and until below. See Pix Automático.

max_attemptsint

How many retries the Pix ladder runs. Always 3, matching the amount reported for these subscriptions.

min_gap_hoursint

Always 24 — the gap between the ladder’s debit dates, not between dispatch attempts. The ladder’s debit dates are D, D+1, D+2 and D+3; when a debit is refused synchronously the next instruction can be dispatched moments later, so compare debit dates rather than send times.

untilTimestamp

When the ladder stops — billing_cycles.next_at plus 7 days. It tracks the cycle, so it moves with next_at at every renewal.

cancel_scheduledobject

The cancellation scheduled for this subscription, or null when none is pending. Schedule one with the schedule block on POST /v1/subscriptions/{id}/cancel; undo it with "schedule": null. See Cancel Subscription.

Hide properties
modeenum

AFTER_CYCLES or AT_DATE, matching whichever of after_cycles/at was sent when the schedule was created.

after_cyclesint

The number of billing cycles that were requested, when mode is AFTER_CYCLES. null when mode is AT_DATE.

atTimestamp

The resolved date and time the cancellation will fire.

requested_atTimestamp

When the cancellation was scheduled.

past_due_behaviorenum

EXHAUST_RETRIES (default) or SKIP_RETRIES — what the schedule does if the subscription is PAST_DUE when it would otherwise fire. See Cancel Subscription.

This echo is pending product confirmation as a stable external contract — see the note on Cancel Subscription.

unpaid_cycleobject

The current billing cycle, when it is PAST_DUE and has not settled. Omitted — not null — for every other state.

Whether this field keeps reporting the unsettled cycle once the subscription reaches CANCELED, or is omitted at that point, is pending product confirmation — verify against a live response before depending on it.

Hide properties
cycle_numberint

The billing cycle that is unpaid, matching billing_cycles.current at the time it was computed.

amountobject

The amount due for the unpaid cycle. Same shape as the subscription-level amount.

attemptsint

Total charge attempts made for this cycle so far, including the original attempt.

last_failure_codestring

The decline/failure code from the most recent attempt. null if unavailable.

refundobject

The refund quote from the last immediate cancellation, or null/omitted when none was ever computed. Requested with the refund mode on POST /v1/subscriptions/{id}/cancel — see Cancel Subscription. Once computed, it persists and keeps appearing on every later read of the subscription.

Hide properties
modeenum

PRORATED, FULL, or CUSTOM — echoes what was requested.

amountobject

The computed (or CUSTOM-echoed) refund amount. Same shape as the subscription-level amount.

unused_daysint

Days of the billing cycle treated as unused. For FULL, equals period_days — the whole cycle counts as unused.

period_daysint

The billing cycle’s total length in days.

basisobject

What the refund was computed against.

Hide properties
billing_cycleint

The billing cycle the refund was computed against.

charged_amountobject

The amount actually charged for that cycle — the refund’s ceiling.

payment_idstring

The captured payment’s own id. null for a $0-phase quote with no payment to reference.

charged_atTimestamp

When that payment was captured. null for a $0-phase quote with no payment to reference.

executionstring

Always "MERCHANT" — WHITELABEL computes the quote, you execute the refund.

quoted_atTimestamp

When this quote was computed.

initial_payment_validationbool

Flag to identify if the subscription should wait for the first payment in order to continue. False by default.

Example: false

pending_plan_changeobject

The plan change scheduled for the next billing cycle, or null when none is pending. Schedule one with the plan_change block on PATCH /v1/subscriptions/{id}; undo it with "plan_change": null.

A scheduled change is applied to this same subscription — no new subscription is created, and neither previous_subscription_id nor cancellation_source: PLAN_CHANGE is set.

Hide properties
plan_idstring

The identifier of the target plan.

plan_namestring

The name of the target plan.

directionstring

UPGRADE or DOWNGRADE. A longer billing frequency is an upgrade; on the same frequency, a higher resolved price is an upgrade. Informational only.

effectivestring

When the change applies. Always NEXT_BILLING_CYCLE — only scheduled changes appear here. An IMMEDIATE plan change (see Update Subscription) is applied in place and never becomes pending.

phases_behaviorstring

What happens when the target plan has phases. START_FROM_REGULAR (default) enters the regular phase directly; HONOR_PHASES enters through the target plan’s phase schedule — which sets status to TRIALING, current_phase to TRIAL, and repopulates billing_phases.

applies_atTimestamp

The billing event the change will take effect on — the subscription’s next billing date.

requested_atTimestamp

When the change was scheduled.

metadataarray of objects

Specifies the metadata array.

Hide properties
keystring

This value serves as a name or identifier for the metadata. Use a descriptive term. (MAX 48; MIN 1).

Example: sub_ext_id

valuestring

The information you wish to store within the metadata. (MAX 512; MIN 1).

Example: AA001

subscription_agreement_idstring

Links this subscription to the initial payment created with the same agreement ID. Used for tracking, reconciliation, and chargeback handling (MAX 255).

The value must exactly match the subscription_agreement_id sent in payment_method.detail.card.stored_credentials.subscription_agreement_id on the originating payment (payment_method.detail.wallet.stored_credentials.subscription_agreement_id when the originating payment is a wallet CIT).

Example: sa_6af2dfcd-44c0-4f16-a331-8bed3ed9c9fa

paymentsArray of strings

Specifies the payments array.

This array is currently always empty in webhook payloads. Subscribe to payment.* webhooks to track charges. For the subscription’s full charge history (amounts, provider, phase context), use List Subscription Payments instead of this field.

Example: [“5104911d-5df9-229e-8468-bd41abea1a4s”]

renewal_notification_daysint

Number of days before the next billing date at which the subscription.close_to_renewal webhook is sent. null means no renewal notification is sent for this subscription.

Example: 3

reasonstring

Free-form reason for the subscription’s current status, when one was recorded. null for subscriptions whose status changed without one.

Example: “merchant request”

cancellation_timeTimestamp

When the subscription was canceled (ISO 8601). Only set once the subscription reaches CANCELED; null otherwise. See cancellation_source for what triggered it.

Example: 2023-12-16T20:46:54.786342Z

ending_timeTimestamp

When the subscription completed or expired (ISO 8601). Only set once the subscription reaches COMPLETED; null otherwise.

Example: 2024-12-16T20:46:54.786342Z

created_atTimestamp

Subscription creation date and time (ISO 8601 MAX 27; MIN 27).

Example: 2023-12-16T20:46:54.786342Z

updated_atTimestamp

Subscription last updated date and time (ISO 8601 MAX 27; MIN 27).

Example: 2023-12-16T21:00:54.786342Z

additional_dataobject

Specifies the additional_data object. This object is not mandatory. However, if you send this information, the payment experience will be enhanced for your user.

Hide properties
orderobject

Specifies the order object.

Hide properties
itemsarray of object

Specifies the item’s object.

Hide properties
idstring

The unique identifier of the item (MAX 255; MIN 3).

Example: 3214

namestring

The name of the item (MAX 255; MIN 3).

Example: iPhone 12 Pro Max

quantityint

The quantity of the item (MAX 999; MIN 1).

Example: 1

unit_amountfloat

The unit amount of the item (multiple of 0.0001).

Example: 550

categorystring

The category of the item (MAX 255; MIN 3).

Possible values: Check the Item category list.

brandstring

The brand of the item (MAX 255; MIN 3).

Example: Apple

sku_codestring

The stock keeping unit (SKU) of the item (MAX 255; MIN 3).

Example: A2342

manufacture_part_numberstring

The manufacture part number of the item (MAX 255; MIN 3).

Example: 345621234