# Generated by API Evangelist (build-phrasing.py). Our phrasing, not observed demand. overlay: 1.0.0 info: title: API Evangelist conversational phrasing for Clerk Backend Billing API version: 1.0.0 extends: openapi/clerk-com-billing-api-openapi.yml actions: - target: $.info update: x-apievangelist-phrasing: method: generated generated: '2026-09-26' generator: build-phrasing.py label: Generated by API Evangelist operations: 16 - target: $.paths['/users/{user_id}/billing/subscription'].get update: x-apievangelist-phrasing: intent: Retrieve a user's billing subscription effect: read questions: - What plans is a given user subscribed to and what is their payment status? - How do I read a user's billing subscription items from my backend? instructions: - text: Get the billing subscription for user {user_id}. slots: user_id: path.user_id - text: Show which plans user {user_id} is paying for. slots: user_id: path.user_id method: generated generated: '2026-09-26' - target: $.paths['/users/{user_id}/billing/credits'].get update: x-apievangelist-phrasing: intent: Check a user's credit balance effect: read questions: - How much billing credit does a user have left? - Can I see a user's credit balance before their next recurring charge? instructions: - text: Get the credit balance for user {user_id}. slots: user_id: path.user_id - text: Tell me how many credits user {user_id} has. slots: user_id: path.user_id method: generated generated: '2026-09-26' - target: $.paths['/users/{user_id}/billing/credits'].post update: x-apievangelist-phrasing: intent: Add or remove credit for a user effect: write questions: - How do I give a user account credit toward future charges? - Can I decrease a user's credit balance and record a note on the ledger entry? - Is adjusting a user's credits safe to retry with an idempotency key? instructions: - text: 'Adjust user {user_id} credits: {action} {amount} with idempotency key {idempotency_key}.' slots: user_id: path.user_id action: requestBody.action amount: requestBody.amount idempotency_key: requestBody.idempotency_key - text: Credit user {user_id} {amount} in {currency} ({action}) with key {idempotency_key} and note {note}. slots: user_id: path.user_id amount: requestBody.amount currency: requestBody.currency action: requestBody.action idempotency_key: requestBody.idempotency_key note: requestBody.note method: generated generated: '2026-09-26' - target: $.paths['/organizations/{organization_id}/billing/subscription'].get update: x-apievangelist-phrasing: intent: Retrieve an organization's billing subscription effect: read questions: - Which plans is an organization subscribed to, as seen from the backend? - How do I check an organization's payment status and subscription items server-side? instructions: - text: Get the billing subscription for organization {organization_id} from the backend. slots: organization_id: path.organization_id - text: Show which plans organization {organization_id} pays for. slots: organization_id: path.organization_id method: generated generated: '2026-09-26' - target: $.paths['/organizations/{organization_id}/billing/credits'].get update: x-apievangelist-phrasing: intent: Check an organization's credit balance effect: read questions: - How much billing credit does an organization have available? - Can I see an organization's credits before its next renewal? instructions: - text: Get the credit balance for organization {organization_id}. slots: organization_id: path.organization_id - text: Tell me how many credits organization {organization_id} has. slots: organization_id: path.organization_id method: generated generated: '2026-09-26' - target: $.paths['/organizations/{organization_id}/billing/credits'].post update: x-apievangelist-phrasing: intent: Add or remove credit for an organization effect: write questions: - How do I grant an organization credit to offset its next bill? - Can I deduct credits from an organization and leave a note on the ledger? instructions: - text: 'Adjust organization {organization_id} credits: {action} {amount} with idempotency key {idempotency_key}.' slots: organization_id: path.organization_id action: requestBody.action amount: requestBody.amount idempotency_key: requestBody.idempotency_key - text: Give organization {organization_id} {amount} {currency} of credit ({action}), key {idempotency_key}. slots: organization_id: path.organization_id amount: requestBody.amount currency: requestBody.currency action: requestBody.action idempotency_key: requestBody.idempotency_key method: generated generated: '2026-09-26' - target: $.paths['/billing/plans'].get update: x-apievangelist-phrasing: intent: List all billing plans for the instance effect: read questions: - What billing plans, free and paid, are configured on my instance? - Can I list only the plans meant for organizations rather than users? instructions: - text: List every billing plan in my instance from the backend. - text: List billing plans for payer type {payer_type}. slots: payer_type: query.payer_type method: generated generated: '2026-09-26' - target: $.paths['/billing/prices'].get update: x-apievangelist-phrasing: intent: List billing prices effect: read questions: - Which prices, including custom ones, exist for my billing plans? - How do I see all the prices attached to one plan? instructions: - text: List all billing prices. - text: Show the prices for plan {plan_id}. slots: plan_id: query.plan_id method: generated generated: '2026-09-26' - target: $.paths['/billing/prices'].post update: x-apievangelist-phrasing: intent: Create a custom price for a plan effect: write questions: - How do I offer a specific customer a different price on the same plan? - Can a custom price have a separate monthly amount when billed annually? instructions: - text: Create a custom price of {amount} for plan {plan_id}. slots: amount: requestBody.amount plan_id: requestBody.plan_id - text: Add a {currency} price of {amount} to plan {plan_id} with annual monthly amount {annual_monthly_amount}. slots: currency: requestBody.currency amount: requestBody.amount plan_id: requestBody.plan_id annual_monthly_amount: requestBody.annual_monthly_amount method: generated generated: '2026-09-26' - target: $.paths['/billing/subscription_items'].get update: x-apievangelist-phrasing: intent: List subscription items across the instance effect: read questions: - Which users and organizations are subscribed to a given plan? - Can I list subscription items by status and exclude free plans? instructions: - text: List all subscription items on plan {plan_id}. slots: plan_id: query.plan_id - text: Show subscription items with status {status} for payer type {payer_type}. slots: status: query.status payer_type: query.payer_type method: generated generated: '2026-09-26' - target: $.paths['/billing/subscription_items/{subscription_item_id}'].delete update: x-apievangelist-phrasing: intent: Cancel a subscription item effect: destructive questions: - How do I cancel a customer's plan at the end of the billing period? - Can I cancel a subscription item immediately instead of waiting for the period to end? instructions: - text: Cancel subscription item {subscription_item_id} at period end. slots: subscription_item_id: path.subscription_item_id - text: Cancel subscription item {subscription_item_id} now (end_now {end_now}). slots: subscription_item_id: path.subscription_item_id end_now: query.end_now method: generated generated: '2026-09-26' - target: $.paths['/billing/subscription_items/{subscription_item_id}/extend_free_trial'].post update: x-apievangelist-phrasing: intent: Extend a subscription item's free trial effect: write questions: - How do I give a customer a longer free trial on their plan? - Is there a limit on how far into the future a free trial can be extended? instructions: - text: Extend the free trial of subscription item {subscription_item_id} to {extend_to}. slots: subscription_item_id: path.subscription_item_id extend_to: requestBody.extend_to - text: Push the trial end of subscription item {subscription_item_id} out to {extend_to}. slots: subscription_item_id: path.subscription_item_id extend_to: requestBody.extend_to method: generated generated: '2026-09-26' - target: $.paths['/billing/subscription_items/{subscription_item_id}/price_transition'].post update: x-apievangelist-phrasing: intent: Move a subscription item to a new price effect: write questions: - How do I switch a subscriber from one price to another on their subscription item? - Does a price transition take effect immediately or create an upcoming item? instructions: - text: Transition subscription item {subscription_item_id} from price {from_price_id} to {to_price_id}. slots: subscription_item_id: path.subscription_item_id from_price_id: requestBody.from_price_id to_price_id: requestBody.to_price_id - text: Move subscriber item {subscription_item_id} onto price {to_price_id}, replacing {from_price_id}. slots: subscription_item_id: path.subscription_item_id to_price_id: requestBody.to_price_id from_price_id: requestBody.from_price_id method: generated generated: '2026-09-26' - target: $.paths['/billing/statements'].get update: x-apievangelist-phrasing: intent: List all billing statements for the instance effect: read questions: - Where can I see every billing statement issued across my instance? - How do I page through all statements, newest first, from the backend? instructions: - text: List all billing statements for my instance. - text: Show the latest {limit} instance billing statements. slots: limit: query.limit method: generated generated: '2026-09-26' - target: $.paths['/billing/statements/{statementID}'].get update: x-apievangelist-phrasing: intent: Retrieve a billing statement from the backend effect: read questions: - How do I pull up the details of one billing statement on the server side? - What line items and totals are on a particular instance billing statement? instructions: - text: Retrieve billing statement {statementID} via the backend API. slots: statementID: path.statementID - text: Show the details of instance statement {statementID}. slots: statementID: path.statementID method: generated generated: '2026-09-26' - target: $.paths['/billing/statements/{statementID}/payment_attempts'].get update: x-apievangelist-phrasing: intent: List payment attempts on a statement effect: read questions: - Were there failed payment attempts on a billing statement? - How do I see every charge attempt made against a statement? instructions: - text: List payment attempts for statement {statementID}. slots: statementID: path.statementID - text: Show charge attempts made on billing statement {statementID}. slots: statementID: path.statementID method: generated generated: '2026-09-26'