How subscriptions start, pause, resume, and cancel — and what each transition means for billing.
A subscription links a customer to a billing plan and drives the entire billing cycle. This guide covers every state a subscription can be in and how to move between them.
Fetch a single subscription or list subscriptions filtered by customer, plan, or status.
# Get one subscriptioncurl https://api.monigo.co/v1/subscriptions/<subscription_id> \ -H "Authorization: Bearer mk_live_..."# List active subscriptions for a customercurl "https://api.monigo.co/v1/subscriptions?customer_id=<customer_id>&status=active" \ -H "Authorization: Bearer mk_live_..."
// Get onesub, err := client.Subscriptions.Get(ctx, subscriptionID)// List by customerlist, err := client.Subscriptions.List(ctx, monigo.ListSubscriptionsParams{ CustomerID: customerID, Status: monigo.SubscriptionStatusActive,})
// Get oneconst sub = await client.subscriptions.get(subscriptionId)// List by customerconst list = await client.subscriptions.list({ customer_id: customerId, status: SubscriptionStatus.Active,})
Pausing freezes billing without ending the customer relationship. While paused:
Incoming events are still ingested and stored
Those events are not included in any invoice until the subscription is resumed
No invoice is generated at period end
Use pausing for grace periods, customer-initiated downtimes, or when a payment fails and you want to give the customer time to update their payment method.
curl -X POST https://api.monigo.co/v1/subscriptions/<subscription_id>/pause \ -H "Authorization: Bearer mk_live_..."
const sub = await client.subscriptions.cancel(subscriptionId)
Cancellation is immediate and irreversible. If you need to temporarily stop billing, use pause instead. A canceled subscription cannot be reactivated — you would need to create a new subscription.
After cancellation:
A final invoice is generated for the partial period
The invoice is finalized and sent for collection
The subscription.canceled webhook is fired
No further events are attributed to this subscription
Billing Cycle — how periods advance and invoices are triggered
Invoice Lifecycle — what happens to the invoices a subscription generates
Webhooks — full event catalog and signature verification
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Monigo","colors":{"primary":"#00c951","light":"#00bf55","dark":"#00bc7d"},"logo":{"light":"https://monigo.co/img/light-logo.png","dark":"https://monigo.co/img/dark-logo.png","href":"https://monigo.co"},"favicon":"https://monigo.co/favicon.png","api":{"openapi":"api-reference/public-openapi.yaml","mdx":{"auth":{"method":"bearer"}}},"navbar":{"links":[{"href":"https://monigo.co/dashboard","label":"Dashboard"}],"primary":{"type":"button","label":"Get Started","href":"https://monigo.co/register"}},"footer":{"socials":{}},"styling":{"latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"monigo","hasAudioNarration":false,"actualSubdomain":"monigo","customDomains":["docs.monigo.co"],"gitSource":{"type":"github","owner":"monigo-africa","repo":"platform","deployBranch":"main","contentDirectory":"docs","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6a3d008b8ec7800b2791766a","collectionId":"696be4ae-e474-4de3-b0b1-71f3cd9f13a2","schemaVersion":"v3"},"entitlements":{},"buildId":"6a3d008b8ec7800b2791766a:success","clientVersion":"0.0.3966","searchFilterCounts":[{"language":"default","tag":"API Reference","count":43},{"language":"default","tag":"Guides","count":16},{"language":"default","tag":"wallets","count":9},{"language":"default","tag":"Integrations","count":5},{"language":"default","tag":"customers","count":5},{"language":"default","tag":"invoices","count":5},{"language":"default","tag":"metrics","count":5},{"language":"default","tag":"payout-accounts","count":5},{"language":"default","tag":"plans","count":5},{"language":"default","tag":"subscriptions","count":5}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableAskAiSearchBar":true},"hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-v7-file-tree","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"pause-universal-search-reconcile","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"per-site-search-delta","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-private-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-nav-generations","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-agent-model-picker","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"isAtlas":false,"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"guides/subscription-lifecycle","slug":"/guides/subscription-lifecycle","pageMetadata":{"title":"Subscription Lifecycle","description":"How subscriptions start, pause, resume, and cancel — and what each transition means for billing.","href":"/guides/subscription-lifecycle"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"How subscriptions start, pause, resume, and cancel — and what each transition means for billing.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,hr:`hr`,li:`li`,ol:`ol`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,CodeGroup,Heading,Mermaid,Table,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!CodeGroup)_missingMdxReference(`CodeGroup`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Mermaid)_missingMdxReference(`Mermaid`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`A subscription links a customer to a billing plan and drives the entire billing cycle. This guide covers every state a subscription can be in and how to move between them.`}),`\n`,_jsx(Heading,{level:`2`,id:`status-overview`,children:`Status overview`}),`\n`,_jsx(Mermaid,{chart:`stateDiagram-v2\n [*] --> active : create\n\n active --> paused\n active --> canceled\n\n paused --> active\n paused --> canceled`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Status`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`active`})}),_jsx(_components.td,{children:`The subscription is running. Events accumulate and invoices are generated at period end.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`paused`})}),_jsx(_components.td,{children:`No new events are counted and no invoice is generated until the subscription is resumed.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`canceled`})}),_jsx(_components.td,{children:`The subscription has ended. The current period’s usage is invoiced and no further billing occurs.`})]})]})]}),`\n`,_jsx(_components.hr,{}),`\n`,_jsx(Heading,{level:`2`,id:`creating-a-subscription`,children:`Creating a subscription`}),`\n`,_jsx(_components.p,{children:`Subscriptions start immediately when created. The first billing period begins at the moment of creation.`}),`\n`,_jsxs(CodeGroup,{children:[_jsx(CodeBlock,{filename:`cURL`,numberOfLines:`7`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`7`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -X`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` POST`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://api.monigo.co/v1/subscriptions`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization: Bearer mk_live_...\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Content-Type: application/json\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -d`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` '{`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"customer_id\": \"\u003ccustomer_id>\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"plan_id\": \"\u003cplan_id>\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` }'`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`Go`,numberOfLines:`4`,language:`go`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`go`,children:_jsxs(_components.code,{language:`go`,numberOfLines:`4`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`sub`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`err`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`Create`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`ctx`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`monigo`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`CreateSubscriptionRequest`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` CustomerID`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`customerID`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` PlanID`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`planID`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`})`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`TypeScript`,numberOfLines:`4`,language:`typescript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`typescript`,children:_jsxs(_components.code,{language:`typescript`,numberOfLines:`4`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` sub`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`create`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` customer_id:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` customerId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` plan_id:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` planId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`})`})}),`\n`]})})})]}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Response fields to note:`})}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Field`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`id`})}),_jsx(_components.td,{children:`The subscription UUID — required for invoice generation`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`status`})}),_jsxs(_components.td,{children:[`Always `,_jsx(_components.code,{children:`active`}),` on creation`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`current_period_start`})}),_jsx(_components.td,{children:`When the first billing period began`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`current_period_end`})}),_jsx(_components.td,{children:`When the first invoice will be generated`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`trial_ends_at`})}),_jsxs(_components.td,{children:[`Present only if the plan has `,_jsx(_components.code,{children:`trial_period_days > 0`})]})]})]})]}),`\n`,_jsx(_components.hr,{}),`\n`,_jsx(Heading,{level:`2`,id:`querying-subscriptions`,children:`Querying subscriptions`}),`\n`,_jsx(_components.p,{children:`Fetch a single subscription or list subscriptions filtered by customer, plan, or status.`}),`\n`,_jsxs(CodeGroup,{children:[_jsx(CodeBlock,{filename:`cURL`,numberOfLines:`7`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`7`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Get one subscription`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://api.monigo.co/v1/subscriptions/`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`\u003c`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`subscription_i`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`d`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization: Bearer mk_live_...\"`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# List active subscriptions for a customer`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"https://api.monigo.co/v1/subscriptions?customer_id=\u003ccustomer_id>\u0026status=active\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization: Bearer mk_live_...\"`})]}),`\n`]})})}),_jsx(CodeBlock,{filename:`Go`,numberOfLines:`8`,language:`go`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`go`,children:_jsxs(_components.code,{language:`go`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Get one`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`sub`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`err`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`Get`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`ctx`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptionID`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// List by customer`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`list`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`err`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`List`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`ctx`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`monigo`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`ListSubscriptionsParams`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` CustomerID`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`customerID`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` Status`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`monigo`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`SubscriptionStatusActive`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`})`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`TypeScript`,numberOfLines:`8`,language:`typescript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`typescript`,children:_jsxs(_components.code,{language:`typescript`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Get one`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` sub`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`get`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptionId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// List by customer`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` list`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`list`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` customer_id:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` customerId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` status:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` SubscriptionStatus`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Active`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`})`})}),`\n`]})})})]}),`\n`,_jsx(_components.hr,{}),`\n`,_jsx(Heading,{level:`2`,id:`pausing-a-subscription`,children:`Pausing a subscription`}),`\n`,_jsx(_components.p,{children:`Pausing freezes billing without ending the customer relationship. While paused:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`Incoming events are `,_jsx(_components.strong,{children:`still ingested`}),` and stored`]}),`\n`,_jsxs(_components.li,{children:[`Those events are `,_jsx(_components.strong,{children:`not included`}),` in any invoice until the subscription is resumed`]}),`\n`,_jsx(_components.li,{children:`No invoice is generated at period end`}),`\n`]}),`\n`,_jsx(_components.p,{children:`Use pausing for grace periods, customer-initiated downtimes, or when a payment fails and you want to give the customer time to update their payment method.`}),`\n`,_jsxs(CodeGroup,{children:[_jsx(CodeBlock,{filename:`cURL`,numberOfLines:`2`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`2`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -X`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` POST`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://api.monigo.co/v1/subscriptions/`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`\u003c`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`subscription_i`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`d`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`/pause`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization: Bearer mk_live_...\"`})]}),`\n`]})})}),_jsx(CodeBlock,{filename:`Go`,numberOfLines:`1`,language:`go`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`go`,children:_jsxs(_components.code,{language:`go`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`sub`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`err`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`Pause`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`ctx`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptionID`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`]})})}),_jsx(CodeBlock,{filename:`TypeScript`,numberOfLines:`1`,language:`typescript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`typescript`,children:_jsxs(_components.code,{language:`typescript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` sub`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`pause`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptionId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`]})})})]}),`\n`,_jsx(_components.hr,{}),`\n`,_jsx(Heading,{level:`2`,id:`resuming-a-subscription`,children:`Resuming a subscription`}),`\n`,_jsxs(_components.p,{children:[`Resuming an `,_jsx(_components.code,{children:`active`}),` billing period. Usage accumulated while paused is included in the next invoice.`]}),`\n`,_jsxs(CodeGroup,{children:[_jsx(CodeBlock,{filename:`cURL`,numberOfLines:`2`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`2`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -X`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` POST`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://api.monigo.co/v1/subscriptions/`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`\u003c`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`subscription_i`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`d`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`/resume`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization: Bearer mk_live_...\"`})]}),`\n`]})})}),_jsx(CodeBlock,{filename:`Go`,numberOfLines:`1`,language:`go`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`go`,children:_jsxs(_components.code,{language:`go`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`sub`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`err`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`Resume`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`ctx`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptionID`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`]})})}),_jsx(CodeBlock,{filename:`TypeScript`,numberOfLines:`1`,language:`typescript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`typescript`,children:_jsxs(_components.code,{language:`typescript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` sub`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`resume`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptionId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`]})})})]}),`\n`,_jsx(_components.hr,{}),`\n`,_jsx(Heading,{level:`2`,id:`canceling-a-subscription`,children:`Canceling a subscription`}),`\n`,_jsx(_components.p,{children:`Canceling ends the subscription. Monigo generates a final invoice for all usage accumulated in the current period up to the cancellation time.`}),`\n`,_jsxs(CodeGroup,{children:[_jsx(CodeBlock,{filename:`cURL`,numberOfLines:`2`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`2`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -X`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` POST`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://api.monigo.co/v1/subscriptions/`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`\u003c`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`subscription_i`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`d`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`/cancel`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization: Bearer mk_live_...\"`})]}),`\n`]})})}),_jsx(CodeBlock,{filename:`Go`,numberOfLines:`1`,language:`go`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`go`,children:_jsxs(_components.code,{language:`go`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`sub`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`err`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`Cancel`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`ctx`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptionID`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`]})})}),_jsx(CodeBlock,{filename:`TypeScript`,numberOfLines:`1`,language:`typescript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`typescript`,children:_jsxs(_components.code,{language:`typescript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` sub`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptions`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`cancel`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`subscriptionId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`]})})})]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`Cancellation is immediate and irreversible. If you need to temporarily stop billing, use `,_jsx(_components.strong,{children:`pause`}),` instead. A canceled subscription cannot be reactivated — you would need to create a new subscription.`]})}),`\n`,_jsx(_components.p,{children:`After cancellation:`}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsx(_components.li,{children:`A final invoice is generated for the partial period`}),`\n`,_jsx(_components.li,{children:`The invoice is finalized and sent for collection`}),`\n`,_jsxs(_components.li,{children:[`The `,_jsx(_components.code,{children:`subscription.canceled`}),` webhook is fired`]}),`\n`,_jsx(_components.li,{children:`No further events are attributed to this subscription`}),`\n`]}),`\n`,_jsx(_components.hr,{}),`\n`,_jsx(Heading,{level:`2`,id:`webhook-events`,children:`Webhook events`}),`\n`,_jsxs(_components.p,{children:[`Subscribe to these events in `,_jsx(_components.strong,{children:`Dashboard → Webhooks`}),` to react to subscription state changes:`]}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Event`}),_jsx(_components.th,{children:`Fired when`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`subscription.created`})}),_jsx(_components.td,{children:`A new subscription is created`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`subscription.paused`})}),_jsx(_components.td,{children:`A subscription is paused`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`subscription.resumed`})}),_jsx(_components.td,{children:`A paused subscription is resumed`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`subscription.canceled`})}),_jsx(_components.td,{children:`A subscription is canceled`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`subscription.trial_ending`})}),_jsx(_components.td,{children:`The trial period is 3 days from ending`})]})]})]}),`\n`,_jsx(_components.hr,{}),`\n`,_jsx(Heading,{level:`2`,id:`related`,children:`Related`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.a,{href:`/concepts/billing-cycle`,children:`Billing Cycle`}),` — how periods advance and invoices are triggered`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.a,{href:`/guides/invoice-lifecycle`,children:`Invoice Lifecycle`}),` — what happens to the invoices a subscription generates`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.a,{href:`/integrations/webhooks`,children:`Webhooks`}),` — full event catalog and signature verification`]}),`\n`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Subscription Lifecycle","description":"How subscriptions start, pause, resume, and cancel — and what each transition means for billing.","href":"/guides/subscription-lifecycle"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Status overview","slug":"status-overview","depth":2,"children":[]},{"title":"Creating a subscription","slug":"creating-a-subscription","depth":2,"children":[]},{"title":"Querying subscriptions","slug":"querying-subscriptions","depth":2,"children":[]},{"title":"Pausing a subscription","slug":"pausing-a-subscription","depth":2,"children":[]},{"title":"Resuming a subscription","slug":"resuming-a-subscription","depth":2,"children":[]},{"title":"Canceling a subscription","slug":"canceling-a-subscription","depth":2,"children":[]},{"title":"Webhook events","slug":"webhook-events","depth":2,"children":[]},{"title":"Related","slug":"related","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/monigo/79a1091b788139b9/scripts/generate-public-spec.js"],"subdomain":"monigo","siteName":"Monigo","title":"Subscription Lifecycle - Monigo","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-03-05T17:33:19.997Z","originalFileLocation":"guides/subscription-lifecycle.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"How subscriptions start, pause, resume, and cancel — and what each transition means for billing.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Monigo\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"https://monigo.co/favicon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"https://monigo.co/favicon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"https://monigo.co/favicon.png\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/png\" href=\"https://monigo.co/favicon.png\">\u003cmeta data-mint-head property=\"og:title\" content=\"Subscription Lifecycle - Monigo\">\u003cmeta data-mint-head property=\"og:description\" content=\"How subscriptions start, pause, resume, and cancel — and what each transition means for billing.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Monigo\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.monigo.co/guides/subscription-lifecycle\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://monigo.mintlify.app/_mintlify/api/og/v2?division=Guides\u0026amp;title=Subscription+Lifecycle\u0026amp;description=How+subscriptions+start%2C+pause%2C+resume%2C+and+cancel+%E2%80%94+and+what+each+transition+means+for+billing.\u0026amp;theme=f706b4e2e7db18203ca5fefe\u0026amp;signature=f60a5994dac9f0516b2588d7f3ed0da972b396a90a609398c33d52c59a3b8853\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Subscription Lifecycle - Monigo\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"How subscriptions start, pause, resume, and cancel — and what each transition means for billing.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://monigo.mintlify.app/_mintlify/api/og/v2?division=Guides\u0026amp;title=Subscription+Lifecycle\u0026amp;description=How+subscriptions+start%2C+pause%2C+resume%2C+and+cancel+%E2%80%94+and+what+each+transition+means+for+billing.\u0026amp;theme=f706b4e2e7db18203ca5fefe\u0026amp;signature=f60a5994dac9f0516b2588d7f3ed0da972b396a90a609398c33d52c59a3b8853\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"https://mintlify.s3.us-west-1.amazonaws.com/monigo/_generated/favicon/browserconfig.xml?v=3\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Monigo\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#00c951\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.monigo.co/guides/subscription-lifecycle\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/guides/subscription-lifecycle.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.monigo.co/#organization\",\"name\":\"Monigo\",\"url\":\"https://docs.monigo.co\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://monigo.co/img/light-logo.png\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.monigo.co#website\",\"name\":\"Monigo\",\"url\":\"https://docs.monigo.co\",\"publisher\":{\"@id\":\"https://docs.monigo.co/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.monigo.co/guides/subscription-lifecycle#webpage\",\"url\":\"https://docs.monigo.co/guides/subscription-lifecycle\",\"name\":\"Subscription Lifecycle\",\"description\":\"How subscriptions start, pause, resume, and cancel — and what each transition means for billing.\",\"dateModified\":\"2026-03-05T17:33:19.997Z\",\"isPartOf\":{\"@id\":\"https://docs.monigo.co#website\"},\"breadcrumb\":{\"@id\":\"https://docs.monigo.co/guides/subscription-lifecycle#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.monigo.co/guides/subscription-lifecycle#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Guides\",\"item\":\"https://docs.monigo.co/guides/usage-based-billing\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Subscription Lifecycle\",\"item\":\"https://docs.monigo.co/guides/subscription-lifecycle\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.monigo.co/guides/subscription-lifecycle#article\",\"headline\":\"Subscription Lifecycle\",\"name\":\"Subscription Lifecycle\",\"description\":\"How subscriptions start, pause, resume, and cancel — and what each transition means for billing.\",\"url\":\"https://docs.monigo.co/guides/subscription-lifecycle\",\"mainEntityOfPage\":{\"@id\":\"https://docs.monigo.co/guides/subscription-lifecycle#webpage\"},\"dateModified\":\"2026-03-05T17:33:19.997Z\",\"publisher\":{\"@id\":\"https://docs.monigo.co/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.monigo.co#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Monigo\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Monigo","nav":{"global":null,"groups":[{"group":"Get Started","pages":[{"title":"What is Monigo?","href":"/introduction"},{"title":"Quickstart","href":"/getting-started/quickstart"},{"title":"Authentication","href":"/getting-started/authentication"},{"title":"Test vs Live Mode","href":"/getting-started/environments"}]},{"group":"Concepts","pages":[{"title":"Data Model","href":"/concepts/data-model"},{"title":"Billing Cycle","href":"/concepts/billing-cycle"},{"title":"Usage Alerts","href":"/concepts/usage-alerts"}]},{"group":"Guides","pages":[{"title":"Usage-Based Billing","href":"/guides/usage-based-billing"},{"title":"Pricing Models","href":"/guides/pricing-models"},{"title":"Postpaid Billing","href":"/guides/postpaid-billing"},{"title":"Prepaid Billing","href":"/guides/prepaid-billing"},{"title":"Real-Time Billing","href":"/guides/realtime-billing"},{"title":"Wallet Management","href":"/guides/wallet-management"},{"title":"AI Prepaid Wallet","description":"Charge an AI agent's customers by usage — meter tokens as events, price them with a real-time plan, and debit a prepaid wallet continuously as the agent runs.","href":"/guides/ai-prepaid-wallet"},{"title":"Subscription Lifecycle","href":"/guides/subscription-lifecycle"},{"title":"Invoice Lifecycle","description":"How invoices move from draft to finalized to paid — and when to void them.","href":"/guides/invoice-lifecycle"},{"title":"Event-Driven Payouts","href":"/guides/event-driven-payouts"},{"title":"Marketplace Platforms","href":"/guides/marketplace-platforms"},{"title":"Metering","href":"/guides/metering"},{"title":"Idempotency \u0026 Replayability","href":"/guides/idempotency"},{"title":"Customer Portal","href":"/guides/customer-portal"},{"title":"Embedding the Portal","href":"/guides/embedding-the-portal"},{"title":"Usage Alerts","href":"/guides/usage-alerts"}]},{"group":"SDKs","pages":[{"title":"Go SDK","href":"/sdks/go"},{"title":"JavaScript SDK","href":"/sdks/javascript"}]},{"group":"Integrations","pages":[{"title":"Paystack","href":"/integrations/paystack"},{"title":"Flutterwave","href":"/integrations/flutterwave"},{"title":"Monnify","href":"/integrations/monnify"},{"title":"Webhooks","href":"/integrations/webhooks"},{"title":"QuickBooks","href":"/integrations/quickbooks"}]},{"group":"API Reference","pages":[{"group":"customers","pages":[{"title":"List customers","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/customers","href":"/api-reference/customers/list-customers"},{"title":"Create a customer","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/customers","href":"/api-reference/customers/create-a-customer"},{"title":"Get a customer","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/customers/{customer_id}","href":"/api-reference/customers/get-a-customer"},{"title":"Update a customer","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml put /v1/customers/{customer_id}","href":"/api-reference/customers/update-a-customer"},{"title":"Delete a customer","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml delete /v1/customers/{customer_id}","href":"/api-reference/customers/delete-a-customer"}]},{"group":"payout-accounts","pages":[{"title":"List payout accounts","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/customers/{customer_id}/payout-accounts","href":"/api-reference/payout-accounts/list-payout-accounts"},{"title":"Create a payout account","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/customers/{customer_id}/payout-accounts","href":"/api-reference/payout-accounts/create-a-payout-account"},{"title":"Get a payout account","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/customers/{customer_id}/payout-accounts/{account_id}","href":"/api-reference/payout-accounts/get-a-payout-account"},{"title":"Update a payout account","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml put /v1/customers/{customer_id}/payout-accounts/{account_id}","href":"/api-reference/payout-accounts/update-a-payout-account"},{"title":"Delete a payout account","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml delete /v1/customers/{customer_id}/payout-accounts/{account_id}","href":"/api-reference/payout-accounts/delete-a-payout-account"}]},{"group":"wallets","pages":[{"title":"List customer wallets","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/customers/{customer_id}/wallets","href":"/api-reference/wallets/list-customer-wallets"},{"title":"List wallets","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/wallets","href":"/api-reference/wallets/list-wallets"},{"title":"Get or create a wallet","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/wallets","href":"/api-reference/wallets/get-or-create-a-wallet"},{"title":"Get a wallet","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/wallets/{wallet_id}","href":"/api-reference/wallets/get-a-wallet"},{"title":"Credit a wallet","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/wallets/{wallet_id}/credit","href":"/api-reference/wallets/credit-a-wallet"},{"title":"Debit a wallet","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/wallets/{wallet_id}/debit","href":"/api-reference/wallets/debit-a-wallet"},{"title":"List wallet transactions","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/wallets/{wallet_id}/transactions","href":"/api-reference/wallets/list-wallet-transactions"},{"title":"List virtual accounts","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/wallets/{wallet_id}/virtual-accounts","href":"/api-reference/wallets/list-virtual-accounts"},{"title":"Create a virtual account","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/wallets/{wallet_id}/virtual-accounts","href":"/api-reference/wallets/create-a-virtual-account"}]},{"group":"events-replay","pages":[{"title":"Initiate an event replay (API key)","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/events/replay","href":"/api-reference/events-replay/initiate-an-event-replay-api-key"},{"title":"Get a replay job (API key)","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/events/replay/{job_id}","href":"/api-reference/events-replay/get-a-replay-job-api-key"}]},{"group":"ingestion","pages":[{"title":"Ingest usage events","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/ingest","href":"/api-reference/ingestion/ingest-usage-events"}]},{"group":"invoices","pages":[{"title":"List invoices","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/invoices","href":"/api-reference/invoices/list-invoices"},{"title":"Get an invoice","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/invoices/{invoice_id}","href":"/api-reference/invoices/get-an-invoice"},{"title":"Finalize an invoice","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/invoices/{invoice_id}/finalize","href":"/api-reference/invoices/finalize-an-invoice"},{"title":"Void an invoice","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/invoices/{invoice_id}/void","href":"/api-reference/invoices/void-an-invoice"},{"title":"Generate an invoice","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/invoices/generate","href":"/api-reference/invoices/generate-an-invoice"}]},{"group":"metrics","pages":[{"title":"List metrics","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/metrics","href":"/api-reference/metrics/list-metrics"},{"title":"Create a metric","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/metrics","href":"/api-reference/metrics/create-a-metric"},{"title":"Get a metric","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/metrics/{metric_id}","href":"/api-reference/metrics/get-a-metric"},{"title":"Update a metric","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml put /v1/metrics/{metric_id}","href":"/api-reference/metrics/update-a-metric"},{"title":"Delete a metric","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml delete /v1/metrics/{metric_id}","href":"/api-reference/metrics/delete-a-metric"}]},{"group":"plans","pages":[{"title":"List plans","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/plans","href":"/api-reference/plans/list-plans"},{"title":"Create a plan","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/plans","href":"/api-reference/plans/create-a-plan"},{"title":"Get a plan","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/plans/{plan_id}","href":"/api-reference/plans/get-a-plan"},{"title":"Update a plan","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml put /v1/plans/{plan_id}","href":"/api-reference/plans/update-a-plan"},{"title":"Delete a plan","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml delete /v1/plans/{plan_id}","href":"/api-reference/plans/delete-a-plan"}]},{"group":"subscriptions","pages":[{"title":"List subscriptions","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/subscriptions","href":"/api-reference/subscriptions/list-subscriptions"},{"title":"Create a subscription","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml post /v1/subscriptions","href":"/api-reference/subscriptions/create-a-subscription"},{"title":"Get a subscription","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/subscriptions/{subscription_id}","href":"/api-reference/subscriptions/get-a-subscription"},{"title":"Delete a subscription","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml delete /v1/subscriptions/{subscription_id}","href":"/api-reference/subscriptions/delete-a-subscription"},{"title":"Update subscription status","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml patch /v1/subscriptions/{subscription_id}","href":"/api-reference/subscriptions/update-subscription-status"}]},{"group":"usage","pages":[{"title":"Query usage rollups (API key)","deprecated":null,"version":null,"openapi":"/api-reference/public-openapi.yaml get /v1/usage","href":"/api-reference/usage/query-usage-rollups-api-key"}]}]}]},"title":"Subscription Lifecycle - Monigo","buildId":"dpl_cadrRc5H9XQiJQbDFN5mcYRs2PAj","deploymentId":"dpl_cadrRc5H9XQiJQbDFN5mcYRs2PAj","dynamics":[],"chunks":[]}