atmon docs

REFERENCE/TOOLKITS/STRIPE.MD

Stripe

Payments and billing. Manage customers, collect and refund payments, issue invoices, and run recurring subscriptions.

PropertyValue
Slugstripe
Definition version0.1.0
Base URLhttps://api.stripe.com/v1
Auth schemesapi_key
Action tools31
By class13 read, 12 write, 6 destructive
Triggers0
Provider rate limit100 requests per 1s, per account

Measured routing accuracy

46 golden cases replayed through the router over the whole index: measured over corpus ea4f12ad2948 (65 toolkits, 2283 tools indexed and 13 declared uncallable), 31 cases written by hand and 15 cases from the paraphrase pass. A case counts as top-1 when its gold tool ranked first and top-8 when it reached the slate at all.

MeasureCasesShare
top-129/4663.0%
top-840/4687.0%

The sweep is offline: the reranker is a deterministic identity fake that returns candidates in the order retrieval produced them, so top-1 measures retrieval order rather than a reranked slate. just eval-live measures the same cases through the live reranker.

Authentication

Connect an entity with ConnectionsService.InitiateConnection, naming this toolkit's slug. Credentials stay in the connections vault; callers hold connected-account ids only.

api_key

PropertyValue
Placementheader
NameAuthorization
Rendered asBearer {key}

Submit the key with ConnectionsService rather than putting it in a request; it is sealed at rest and never returned.

Tools

31 action tools. The catalog-wide slug is stripe.<tool>, which is what search_tools returns and call_tool takes.

stripe.create_customer

Create a new customer record for billing. Use when the user wants to add, register, or set up a new customer, buyer, or account before charging them or starting a subscription. Optional name, email, and phone.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /customers.

Arguments:

ArgumentTypeRequiredNotes
descriptionstringnoInternal note about this customer, not shown to them.
emailstringnoCustomer's email address, e.g. "jane@example.com".
metadataobjectnoOptional key-value metadata to attach, e.g. {"account_id": "6735"}.
namestringnoCustomer's full name or business name.
phonestringnoCustomer's phone number.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
balanceinteger
createdinteger
currencystring
emailstring
idstring
namestring
phonestring

Also retrieved by: "set up a new buyer in stripe", "I need a billing profile for this client", "register this person so we can charge them later", "add someone to our customer list", "onboard a new account for payments".

stripe.get_customer

Get one customer's details by their Stripe customer id: name, email, phone, and account balance. Use when the user names a specific customer. For finding customers by email or browsing all of them, use list_customers.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /customers/{{params.customer_id}}.

Arguments:

ArgumentTypeRequiredNotes
customer_idstringyesStripe customer id, e.g. "cus_Qx7Nk2VbA1u9Zp".

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
balanceinteger
createdinteger
currencystring
delinquentboolean
emailstring
idstring
namestring
phonestring

Also retrieved by: "pull up this person's billing profile", "what's on file for this buyer", "check their account balance", "look up their contact info in stripe".

stripe.list_customers

List customers on the account, optionally filtered by email. Use when the user asks who our customers are, wants to look someone up by email, or browses the customer base. For one known customer, use get_customer.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /customers.

Arguments:

ArgumentTypeRequiredNotes
emailstringnoOnly customers with this exact email address.
limitintegernoResults per page, max 100. Defaults to 10.
starting_afterstringnoCustomer id to page after, from a previous page's last result.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
dataarray of object
data[].createdinteger
data[].emailstring
data[].idstring
data[].namestring
has_moreboolean

Also retrieved by: "who's on our books", "find the buyer with this email", "show everyone we bill", "search for a customer by their email address".

stripe.update_customer

Edit an existing customer's name, email, phone, or description. Use when the user wants to update, correct, or change a customer's contact details. Only the fields given change; omit others to leave them as is.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /customers/{{params.customer_id}}.

Arguments:

ArgumentTypeRequiredNotes
customer_idstringyesStripe customer id to update.
descriptionstringnoNew internal note about this customer.
emailstringnoNew email address.
namestringnoNew name.
phonestringnoNew phone number.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
emailstring
idstring
namestring
phonestring

Also retrieved by: "fix their email on file", "this person's phone number changed", "correct the billing contact details", "change what we have saved for them".

stripe.delete_customer

Permanently delete a customer and detach their payment methods. Irreversible; open invoices and subscriptions are not canceled first. Use only when the user explicitly asks to delete or remove a customer record entirely.

Class destructive (held by the mutation gate until the call's own arguments carry "confirm": true). No scopes beyond the connection's defaults. Calls DELETE /customers/{{params.customer_id}}.

Arguments:

ArgumentTypeRequiredNotes
customer_idstringyesStripe customer id to delete.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
deletedboolean
idstring

Also retrieved by: "wipe this buyer out of stripe for good", "get rid of their billing profile entirely", "remove them from our records completely", "erase this account, they asked to be forgotten".

stripe.create_payment_intent

Start a payment intent to collect a charge from a customer for a given amount and currency. Use when the user wants to charge a card, collect payment, or bill someone once. Confirm separately with confirm_payment_intent.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /payment_intents.

Arguments:

ArgumentTypeRequiredNotes
amountintegeryesAmount in the smallest currency unit, e.g. 2000 for $20.00 usd.
currencystringyesThree-letter ISO currency code, e.g. "usd".
customerstringnoStripe customer id to charge.
descriptionstringnoInternal note about this charge.
metadataobjectnoOptional key-value metadata to attach, e.g. {"order_id": "6735"}.
payment_methodstringnoStripe payment method id to attach, e.g. "pm_1NakL2".

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
amountinteger
client_secretstring
currencystring
customerstring
idstring
statusstring

Also retrieved by: "charge this card for the order", "bill them for what they owe", "take payment for this purchase", "set up a one-time charge", "collect money from this buyer".

stripe.get_payment_intent

Get one payment intent by id: its status, amount, currency, and linked customer. Use when the user asks whether a charge went through or wants details on a specific payment attempt.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /payment_intents/{{params.payment_intent_id}}.

Arguments:

ArgumentTypeRequiredNotes
payment_intent_idstringyesStripe payment intent id, e.g. "pi_3P9k2VbA1u9Zp".

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
amountinteger
createdinteger
currencystring
customerstring
descriptionstring
idstring
statusstring

Also retrieved by: "did that charge go through", "check the status of this payment attempt", "what happened with this transaction".

stripe.list_payment_intents

List payment intents, optionally filtered by customer. Use when the user asks about recent charges, payment attempts, or a customer's payment history. For a single known payment, use get_payment_intent.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /payment_intents.

Arguments:

ArgumentTypeRequiredNotes
customerstringnoOnly payment intents for this customer id.
limitintegernoResults per page, max 100. Defaults to 10.
starting_afterstringnoPayment intent id to page after, from a previous page's last result.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
dataarray of object
data[].amountinteger
data[].currencystring
data[].customerstring
data[].idstring
data[].statusstring
has_moreboolean

Also retrieved by: "show this buyer's payment history", "what charges have we tried recently", "pull up recent transactions for this account".

stripe.confirm_payment_intent

Confirm a payment intent with a payment method to actually attempt the charge. Use when the user wants to complete, finalize, or run a payment that was started but not yet charged.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /payment_intents/{{params.payment_intent_id}}/confirm.

Arguments:

ArgumentTypeRequiredNotes
payment_intent_idstringyesStripe payment intent id to confirm.
payment_methodstringnoPayment method id to charge, if not already attached.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
client_secretstring
idstring
statusstring

Also retrieved by: "run the charge now that we have a card", "go ahead and process that payment", "finish collecting on this pending charge".

stripe.capture_payment_intent

Capture funds on a payment intent that was authorized but held, completing the charge. Use when the user wants to capture, collect, or finalize an authorized hold, e.g. after shipping an order. Supports a partial capture amount.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /payment_intents/{{params.payment_intent_id}}/capture.

Arguments:

ArgumentTypeRequiredNotes
amount_to_captureintegernoAmount to capture in the smallest currency unit. Defaults to the full authorized amount.
payment_intent_idstringyesStripe payment intent id to capture.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
amount_receivedinteger
idstring
statusstring

Also retrieved by: "grab the funds we held on their card", "collect the hold now that we shipped", "finalize the authorized charge".

stripe.cancel_payment_intent

Cancel a payment intent before it is captured, releasing any authorization hold. Irreversible once canceled; a new payment intent is needed to charge later. Use when the user wants to abandon, drop, or call off a pending charge.

Class destructive (held by the mutation gate until the call's own arguments carry "confirm": true). No scopes beyond the connection's defaults. Calls POST /payment_intents/{{params.payment_intent_id}}/cancel.

Arguments:

ArgumentTypeRequiredNotes
cancellation_reasonstring, one of duplicate, fraudulent, requested_by_customer, abandonednoWhy the payment intent is being canceled.
payment_intent_idstringyesStripe payment intent id to cancel.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
cancellation_reasonstring
idstring
statusstring

Also retrieved by: "drop this pending charge before it goes through", "release the hold on their card", "never mind, don't charge them after all", "abandon this payment attempt".

stripe.get_charge

Get one charge by id: amount, status, whether it was refunded, and the customer and payment intent it belongs to. Use when the user names a specific charge id. For refund details, use get_refund.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /charges/{{params.charge_id}}.

Arguments:

ArgumentTypeRequiredNotes
charge_idstringyesStripe charge id, e.g. "ch_3P9k2VbA1u9Zp".

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
amountinteger
createdinteger
currencystring
customerstring
idstring
paidboolean
payment_intentstring
refundedboolean
statusstring

Also retrieved by: "look up this specific transaction", "pull details on a past charge", "was this charge ever refunded".

stripe.list_charges

List charges, optionally filtered by customer or payment intent. Use when the user asks for a customer's charge history or past transactions. For refund status specifically, use list_refunds.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /charges.

Arguments:

ArgumentTypeRequiredNotes
customerstringnoOnly charges for this customer id.
limitintegernoResults per page, max 100. Defaults to 10.
payment_intentstringnoOnly the charge belonging to this payment intent id.
starting_afterstringnoCharge id to page after, from a previous page's last result.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
dataarray of object
data[].amountinteger
data[].currencystring
data[].customerstring
data[].idstring
data[].refundedboolean
data[].statusstring
has_moreboolean

Also retrieved by: "show past transactions for this buyer", "what have we charged them so far", "pull their transaction history".

stripe.create_refund

Refund a charge or payment intent, in full or in part. Irreversible once processed; the funds return to the customer's original payment method. Use when the user wants to refund, reverse, or give money back for a charge.

Class destructive (held by the mutation gate until the call's own arguments carry "confirm": true). No scopes beyond the connection's defaults. Calls POST /refunds.

Arguments:

ArgumentTypeRequiredNotes
amountintegernoAmount to refund in the smallest currency unit. Omit to refund in full.
chargestringnoStripe charge id to refund. Give this or payment_intent.
payment_intentstringnoStripe payment intent id to refund. Give this or charge.
reasonstring, one of duplicate, fraudulent, requested_by_customernoWhy the refund is being issued.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
amountinteger
currencystring
idstring
payment_intentstring
reasonstring
statusstring

Also retrieved by: "give this customer their money back", "reverse that charge, they want out", "send back what we took by mistake", "process a refund for a bad order", "undo this transaction and return the funds".

stripe.get_refund

Get one refund by id: its status, amount, and the charge or payment intent it applies to. Use when the user asks whether a specific refund went through.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /refunds/{{params.refund_id}}.

Arguments:

ArgumentTypeRequiredNotes
refund_idstringyesStripe refund id, e.g. "re_3P9k2VbA1u9Zp".

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
amountinteger
createdinteger
currencystring
idstring
payment_intentstring
reasonstring
statusstring

Also retrieved by: "did their money actually go back", "check on the status of a refund", "confirm this refund cleared".

stripe.list_refunds

List refunds, optionally filtered by payment intent or charge. Use when the user asks what has been refunded or wants a refund history for a customer or charge.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /refunds.

Arguments:

ArgumentTypeRequiredNotes
chargestringnoOnly refunds against this charge id.
limitintegernoResults per page, max 100. Defaults to 10.
payment_intentstringnoOnly refunds against this payment intent id.
starting_afterstringnoRefund id to page after, from a previous page's last result.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
dataarray of object
data[].amountinteger
data[].currencystring
data[].idstring
data[].payment_intentstring
data[].statusstring
has_moreboolean

Also retrieved by: "what have we refunded lately", "show refund history for this charge", "pull up everything we've given back".

stripe.create_invoice

Create a draft invoice for a customer, to be filled with invoice items before finalizing. Use when the user wants to start, draft, or open a new invoice or bill. Add line items with create_invoice_item, then finalize_invoice.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /invoices.

Arguments:

ArgumentTypeRequiredNotes
collection_methodstring, one of charge_automatically, send_invoicenoHow payment is collected. Defaults to charge_automatically.
customerstringyesStripe customer id to bill.
descriptionstringnoText shown on the invoice, e.g. "June consulting hours".
due_dateintegernoUnix timestamp payment is due by. Required when collection_method is send_invoice.
metadataobjectnoOptional key-value metadata to attach, e.g. {"po_number": "4471"}.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
amount_dueinteger
currencystring
customerstring
hosted_invoice_urlstring
idstring
statusstring

Also retrieved by: "start a bill for this client", "draft up an invoice", "open a new bill I can add items to", "kick off billing for this account".

stripe.get_invoice

Get one invoice by id: its status, amount due, amount paid, due date, and hosted payment page url. Use when the user names a specific invoice.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /invoices/{{params.invoice_id}}.

Arguments:

ArgumentTypeRequiredNotes
invoice_idstringyesStripe invoice id, e.g. "in_1P9k2VbA1u9Zp".

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
amount_dueinteger
amount_paidinteger
currencystring
customerstring
due_dateinteger
hosted_invoice_urlstring
idstring
numberstring
statusstring

Also retrieved by: "pull up this specific bill", "check the status on an invoice", "how much do they still owe on this".

stripe.list_invoices

List invoices, optionally filtered by customer or status such as draft, open, or paid. Use when the user asks about a customer's invoices, unpaid bills, or billing history.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /invoices.

Arguments:

ArgumentTypeRequiredNotes
customerstringnoOnly invoices for this customer id.
limitintegernoResults per page, max 100. Defaults to 10.
starting_afterstringnoInvoice id to page after, from a previous page's last result.
statusstring, one of draft, open, paid, uncollectible, voidnoOnly invoices in this state.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
dataarray of object
data[].amount_dueinteger
data[].currencystring
data[].customerstring
data[].idstring
data[].statusstring
has_moreboolean

Also retrieved by: "show this customer's unpaid bills", "what invoices are outstanding", "pull their billing history".

stripe.finalize_invoice

Finalize a draft invoice, locking its line items and generating the invoice number and payment page. Use when the user wants to lock in, close out, or ready a draft invoice for payment or sending.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /invoices/{{params.invoice_id}}/finalize.

Arguments:

ArgumentTypeRequiredNotes
auto_advancebooleannoTrue to let Stripe automatically attempt collection after finalizing.
invoice_idstringyesStripe draft invoice id to finalize.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
hosted_invoice_urlstring
idstring
numberstring
statusstring

Also retrieved by: "lock this draft bill so it's ready to send", "close out the invoice details", "make this invoice official".

stripe.send_invoice

Email a finalized invoice to the customer for payment. Use when the user wants to send, deliver, or mail an invoice to whoever owes it. The invoice must already be finalized.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /invoices/{{params.invoice_id}}/send.

Arguments:

ArgumentTypeRequiredNotes
invoice_idstringyesStripe finalized invoice id to email.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
idstring
statusstring

Also retrieved by: "email them the bill", "get this invoice out to the customer", "deliver the invoice so they can pay".

stripe.pay_invoice

Attempt to collect payment on an open invoice right away, charging the customer's default payment method. Use when the user wants to collect, charge, or force payment on a bill now rather than waiting.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /invoices/{{params.invoice_id}}/pay.

Arguments:

ArgumentTypeRequiredNotes
invoice_idstringyesStripe open invoice id to pay.
paid_out_of_bandbooleannoTrue to mark the invoice paid without charging anything, e.g. a wire received outside Stripe.
payment_methodstringnoPayment method id to charge instead of the customer's default.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
amount_paidinteger
idstring
statusstring

Also retrieved by: "charge them for this bill right now", "force collection on an open invoice", "go ahead and collect on this now instead of waiting".

stripe.void_invoice

Void a finalized invoice that will never be paid. Irreversible; the invoice stays on record marked void instead of being deleted. Use when the user wants to cancel, kill, or invalidate an invoice that was sent by mistake.

Class destructive (held by the mutation gate until the call's own arguments carry "confirm": true). No scopes beyond the connection's defaults. Calls POST /invoices/{{params.invoice_id}}/void.

Arguments:

ArgumentTypeRequiredNotes
invoice_idstringyesStripe finalized invoice id to void.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
idstring
statusstring

Also retrieved by: "kill this invoice, we sent it by mistake", "cancel a bill that should never be paid", "invalidate this invoice permanently".

stripe.delete_invoice

Permanently delete a draft invoice that has not been finalized. Irreversible and only works while the invoice is still a draft. For a finalized invoice that should never be paid, use void_invoice instead.

Class destructive (held by the mutation gate until the call's own arguments carry "confirm": true). No scopes beyond the connection's defaults. Calls DELETE /invoices/{{params.invoice_id}}.

Arguments:

ArgumentTypeRequiredNotes
invoice_idstringyesStripe draft invoice id to delete.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
deletedboolean
idstring

Also retrieved by: "scrap this draft bill, never mind", "throw out an invoice we haven't sent yet", "get rid of this unfinished bill".

stripe.create_invoice_item

Add a line item, charge, or credit to a customer's next invoice, or to a specific draft invoice. Use when the user wants to add a charge, fee, or product line to a bill before it is finalized.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /invoiceitems.

Arguments:

ArgumentTypeRequiredNotes
amountintegeryesAmount in the smallest currency unit. Negative for a credit.
currencystringyesThree-letter ISO currency code, e.g. "usd".
customerstringyesStripe customer id this line item bills.
descriptionstringnoText shown on the invoice for this line item.
invoicestringnoDraft invoice id to attach to. Omit to queue for the customer's next invoice.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
amountinteger
currencystring
customerstring
descriptionstring
idstring
invoicestring

Also retrieved by: "add a fee to their next bill", "tack on a charge before this invoice goes out", "queue up a line item for the next billing cycle", "credit them something on their upcoming invoice".

stripe.list_invoice_items

List pending invoice items for a customer or invoice that have not yet been billed. Use when the user asks what charges are queued up for someone's next invoice.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /invoiceitems.

Arguments:

ArgumentTypeRequiredNotes
customerstringnoOnly line items for this customer id.
invoicestringnoOnly line items attached to this draft invoice id.
limitintegernoResults per page, max 100. Defaults to 10.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
dataarray of object
data[].amountinteger
data[].currencystring
data[].customerstring
data[].descriptionstring
data[].idstring
has_moreboolean

Also retrieved by: "what's queued up for their next bill", "show pending charges not yet invoiced", "see what's waiting to be billed".

stripe.create_subscription

Start a recurring subscription for a customer on one or more prices. Use when the user wants to subscribe, sign up, or put a customer on a recurring plan. Supports a trial period before the first charge.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /subscriptions.

Arguments:

ArgumentTypeRequiredNotes
collection_methodstring, one of charge_automatically, send_invoicenoHow each billing period is collected. Defaults to charge_automatically.
customerstringyesStripe customer id to subscribe.
itemsarray of objectyesPrice and quantity pairs the subscription bills for.
items[].pricestringyesStripe price id, e.g. "price_1P9k2VbA1u9Zp".
items[].quantityintegernoQuantity of this price. Defaults to 1.
metadataobjectnoOptional key-value metadata to attach, e.g. {"plan_source": "referral"}.
trial_period_daysintegernoDays of free trial before the first charge.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
current_period_endinteger
customerstring
idstring
itemsarray of object
items[].idstring
items[].priceobject
items[].price.idstring
statusstring

Also retrieved by: "put this customer on a recurring plan", "sign them up for our monthly service", "start billing them every cycle", "set up a subscription with a free trial".

stripe.get_subscription

Get one subscription by id: its status, billing period, whether it is set to cancel, and its price items. Use when the user asks about a specific customer's plan or subscription.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /subscriptions/{{params.subscription_id}}.

Arguments:

ArgumentTypeRequiredNotes
subscription_idstringyesStripe subscription id, e.g. "sub_1P9k2VbA1u9Zp".

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
cancel_at_period_endboolean
current_period_endinteger
current_period_startinteger
customerstring
idstring
itemsarray of object
items[].idstring
items[].priceobject
items[].price.idstring
statusstring

Also retrieved by: "what plan is this customer on", "check the status of their subscription", "is this account set to cancel".

stripe.list_subscriptions

List subscriptions, optionally filtered by customer, status, or price. Use when the user asks who is subscribed, what plan a customer is on, or wants a list of active or canceled subscriptions.

Class read (reads only). No scopes beyond the connection's defaults. Calls GET /subscriptions.

Arguments:

ArgumentTypeRequiredNotes
customerstringnoOnly subscriptions for this customer id.
limitintegernoResults per page, max 100. Defaults to 10.
pricestringnoOnly subscriptions that include this price id.
statusstring, one of active, past_due, unpaid, canceled, trialing, allnoOnly subscriptions in this state. Defaults to active.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
dataarray of object
data[].cancel_at_period_endboolean
data[].current_period_endinteger
data[].customerstring
data[].idstring
data[].statusstring
has_moreboolean

Also retrieved by: "who's actively subscribed right now", "show every canceled plan", "find accounts on this specific price".

stripe.update_subscription

Change a subscription's price items, or schedule it to cancel at the end of the current billing period. Use when the user wants to upgrade, downgrade, swap plans, or schedule a future cancellation without ending it now. To end it immediately, use cancel_subscription.

Class write (writes, no confirmation needed). No scopes beyond the connection's defaults. Calls POST /subscriptions/{{params.subscription_id}}.

Arguments:

ArgumentTypeRequiredNotes
cancel_at_period_endbooleannoTrue to end the subscription when the current period finishes, false to un-schedule that.
itemsarray of objectnoReplacement price and quantity pairs for the subscription.
items[].idstringnoExisting subscription item id, to change its price or quantity.
items[].pricestringnoStripe price id.
items[].quantityintegernoQuantity of this price.
proration_behaviorstring, one of create_prorations, none, always_invoicenoHow to prorate a mid-period price change. Defaults to create_prorations.
subscription_idstringyesStripe subscription id to update.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
cancel_at_period_endboolean
current_period_endinteger
idstring
statusstring

Also retrieved by: "move them to a different plan", "upgrade their subscription tier", "schedule this to end at the period's close", "swap the price on their plan".

stripe.cancel_subscription

End a subscription immediately, stopping future billing. Irreversible; a canceled subscription cannot be resumed and needs a new one. Use when the user wants to cancel, stop, or terminate a subscription right now, not at period end.

Class destructive (held by the mutation gate until the call's own arguments carry "confirm": true). No scopes beyond the connection's defaults. Calls DELETE /subscriptions/{{params.subscription_id}}.

Arguments:

ArgumentTypeRequiredNotes
invoice_nowbooleannoTrue to invoice any outstanding, unbilled usage immediately.
proratebooleannoTrue to credit the unused time remaining in the current period.
subscription_idstringyesStripe subscription id to cancel.

Result fields (the payload is trimmed to these before it reaches the model):

FieldTypeNotes
canceled_atinteger
idstring
statusstring

Also retrieved by: "stop billing them right now", "end this subscription immediately", "terminate their plan today, not later", "shut off their recurring charges for good".