Skip to main content

Introduction

This section defines the complete schemas for events related to Subscriptions on Webround Commerce. Subscription management allows for the automation of recurring sales by monitoring payment status, trial periods, and billing cycles synchronized with Stripe in real-time.

Why Listen to Subscription Events

Integrating subscription events is essential for:

  • Access Management: Activating or revoking permissions and services based on the subscription status (e.g., active, past_due, canceled).
  • Billing Synchronization: Monitoring period end dates (currentPeriodEnd) and managing scheduled renewals or cancellations.
  • Customer Care: Providing immediate assistance for failed invoices by monitoring the latestInvoiceId.
  • Trial Analysis: Tracking the start and end of trial periods to drive marketing conversion strategies.

Complete Events and Payload Table

EventPayload SchemaJSON Example
subscription.createdSubscription SchemaLink
subscription.updatedSubscription SchemaLink
subscription.canceledSubscription SchemaLink
subscription.deletedSubscription Deleted SchemaLink

Subscription Schema (subscriptionDataSchema)

FieldTypeNotes
iduuidRequired. Unique ID on Webround
stripeIdstringRequired. Stripe subscription ID
storeCustomerIduuidRequired. Internal customer ID
stripeCustomerIdstringRequired. Stripe customer ID
statusstringStatus (e.g., trialing, active, past_due, canceled)
activeSinceisoDateActivation start date
currentPeriodEndisoDateEnd date of the current billing cycle
cancelAtPeriodEndbooleanIf true, the subscription will expire at the end of the period
latestInvoiceIdstringID of the last generated invoice
trialStart/EndisoDateTrial period dates

Subscription Example

{
"envelopeId": "e1f2g3h4-i5j6-4a5b-b6c7-d8e9f0a1b2c3",
"eventType": "subscription.updated",
"storeId": "7292a83e-967b-4861-80a5-2964e52003c4",
"occurredAt": "2026-02-22T23:45:00.000Z",
"data": {
"id": "s1b2c3d4-e5f6-4a5b-b6c7-d8e9f0a1b2c3",
"stripeId": "sub_1QRsT2U3V4W5X6",
"storeCustomerId": "c1d2e3f4-g5h6-4a5b-b6c7-d8e9f0a1b2c3",
"stripeCustomerId": "cus_R987654321",
"stripeAccountId": "acct_123456789",
"storeId": "7292a83e-967b-4861-80a5-2964e52003c4",
"status": "active",
"activeSince": "2026-01-22T10:00:00.000Z",
"currentPeriodEnd": "2026-03-22T10:00:00.000Z",
"cancelAtPeriodEnd": false,
"latestInvoiceId": "in_1QSx...",
"latestInvoiceUrl": "https://invoice.stripe.com/...",
"trialStart": null,
"trialEnd": null,
"createdAt": "2026-01-22T10:00:00.000Z",
"updatedAt": "2026-02-22T23:45:00.000Z"
},
"eventId": "k1l2m3n4-o5p6-4a5b-b6c7-d8e9f0a1b2c3"
}


Subscription Deleted Schema (subscriptionDeletedSchema)

FieldTypeNotes
subscriptionIduuidRequired. ID of the removed subscription

Subscription Deleted Example

{
"envelopeId": "f2g3h4i5-j6k7-4a5b-b6c7-d8e9f0a1b2c3",
"eventType": "subscription.deleted",
"storeId": "7292a83e-967b-4861-80a5-2964e52003c4",
"occurredAt": "2026-02-22T23:50:00.000Z",
"data": {
"subscriptionId": "s1b2c3d4-e5f6-4a5b-b6c7-d8e9f0a1b2c3"
},
"eventId": "l2m3n4o5-p6q7-4a5b-b6c7-d8e9f0a1b2c3"
}