Skip to content
Proud to collaborate with Microsoft for Startups

stripe.subscriptions.get_subscription ​

Get a Stripe subscription and its current status

Read a subscription. status is the field entitlement should key on: active and trialing mean entitled; past_due, canceled, unpaid and incomplete do not.

Acts on the CUSTOMER'S OWN Stripe account, authenticated via the org-scoped Stripe connection selected by cloud_connection_uuid.

Inputs:

  • cloud_connection_uuid: Org-scoped Stripe connection (customer's own account).
  • subscription_id: Stripe subscription ID (sub_...).

Outputs (terminal state_data):

  • subscription_id: str
  • status: str — active | trialing | past_due | canceled | unpaid | incomplete
  • customer_id: str
  • price_id: str — price on the first item
  • item_id: str — subscription item id, needed to change the plan
  • current_period_end: int — unix timestamp
  • cancel_at_period_end: bool
  • subscription_metadata: json

Connection required: cloud_connection_uuid — the organization's own Stripe account credentials; there is no platform-key fallback.

Overview ​

PropertyValue
Workflow typeAtomic
LibraryApp-stripe
Version1.0

Input Schema ​

FieldTypeRequiredDefaultDescription
cloud_connection_uuiduuidYes—Org-scoped Stripe connection (customer's own account)
subscription_idstringYes—Stripe subscription ID (sub_...)

Output Schema ​

FieldTypeRequiredDefaultDescription
subscription_idstringNo——
statusstringNo——
customer_idstringNo——
price_idstringNo——
item_idstringNo——
current_period_endintegerNo——
cancel_at_period_endbooleanNo——
subscription_metadatajsonNo——
cloud_connection_uuiduuidNo——
failure_reasonstringNo——
failure_typestringNo——
failed_actionstringNo——
failed_at_statestringNo——
failed_stepstringNo——
errorstringNo——
error_typestringNo——
failed_layerintegerNo——

States ​

StateInitialTerminalSuccessAuto-advanceDescription
pendingYesNo—execute—
completedNoYesYes——
failedNoYesNo——

State Diagram ​

Transitions ​

FromActionToDescription
pendingexecutecompleted—
* (any state)failfailed—

API Usage ​

bash
POST /api/workflows/start
Content-Type: application/json

{
  "workflow_type": "stripe.subscriptions.get_subscription",
  "initial_data": {
    "cloud_connection_uuid": "value",
    "subscription_id": "value"
  }
}