From 98ddf236374bb932c2a83ed05f290b271ec350a8 Mon Sep 17 00:00:00 2001 From: "stripe-openapi[bot]" <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 23 Apr 2024 09:56:03 -0700 Subject: [PATCH] Update OpenAPI for 855c1c2ebb8812653eba2a8afbe66340929affe3 (#1170) Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> --- api/openapi-spec/spec3.sdk.json | 5153 ++++++++++++++++++++++++++++--- pkg/cmd/resources_cmds.go | 72 +- pkg/proxy/events_list.go | 1 + 3 files changed, 4794 insertions(+), 432 deletions(-) diff --git a/api/openapi-spec/spec3.sdk.json b/api/openapi-spec/spec3.sdk.json index b220b2f8..185305f6 100644 --- a/api/openapi-spec/spec3.sdk.json +++ b/api/openapi-spec/spec3.sdk.json @@ -2,7 +2,7 @@ "components": { "schemas": { "account": { - "description": "This is an object representing a Stripe account. You can retrieve it to see\nproperties on the account like its current requirements or if the account is\nenabled to make live charges or receive payouts.\n\nFor Custom accounts, the properties below are always returned. For other accounts, some properties are returned until that\naccount has started to go through Connect Onboarding. Once you create an [Account Link](https://stripe.com/docs/api/account_links) or [Account Session](https://stripe.com/docs/api/account_sessions),\nsome properties are only returned for Custom accounts. Learn about the differences [between accounts](https://stripe.com/docs/connect/accounts).", + "description": "This is an object representing a Stripe account. You can retrieve it to see\nproperties on the account like its current requirements or if the account is\nenabled to make live charges or receive payouts.\n\nFor accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection)\nis `application`, which includes Custom accounts, the properties below are always\nreturned.\n\nFor accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection)\nis `stripe`, which includes Standard and Express accounts, some properties are only returned\nuntil you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions)\nto start Connect Onboarding. Learn about the [differences between accounts](/connect/accounts).", "properties": { "business_profile": { "anyOf": [ @@ -14,7 +14,7 @@ "nullable": true }, "business_type": { - "description": "The business type. Once you create an [Account Link](https://stripe.com/docs/api/account_links) or [Account Session](https://stripe.com/docs/api/account_sessions), this property is only returned for Custom accounts.", + "description": "The business type. After you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property is only returned for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "enum": [ "company", "government_entity", @@ -54,7 +54,7 @@ "type": "string" }, "details_submitted": { - "description": "Whether account details have been submitted. Standard accounts cannot receive payouts before this is true.", + "description": "Whether account details have been submitted. Accounts with Stripe Dashboard access, which includes Standard accounts, cannot receive payouts before this is true.", "type": "boolean" }, "email": { @@ -148,7 +148,7 @@ "$ref": "#/components/schemas/account_tos_acceptance" }, "type": { - "description": "The Stripe account type. Can be `standard`, `express`, or `custom`.", + "description": "The Stripe account type. Can be `standard`, `express`, `custom`, or `none`.", "enum": [ "custom", "express", @@ -1452,7 +1452,7 @@ "description": "", "properties": { "debit_negative_balances": { - "description": "A Boolean indicating if Stripe should try to reclaim negative balances from an attached bank account. See our [Understanding Connect Account Balances](https://stripe.com/docs/connect/account-balances) documentation for details. Default value is `false` for Custom accounts, otherwise `true`.", + "description": "A Boolean indicating if Stripe should try to reclaim negative balances from an attached bank account. See [Understanding Connect account balances](/connect/account-balances) for details. The default value is `false` when [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, otherwise `true`.", "type": "boolean" }, "schedule": { @@ -2862,7 +2862,7 @@ "type": "array" }, "connect_reserved": { - "description": "Funds held due to negative balances on connected Custom accounts. You can find the connect reserve balance for each currency and payment type in the `source_types` property.", + "description": "Funds held due to negative balances on connected accounts where [account.controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. You can find the connect reserve balance for each currency and payment type in the `source_types` property.", "items": { "$ref": "#/components/schemas/balance_amount" }, @@ -3276,7 +3276,7 @@ } }, "bank_account": { - "description": "These bank accounts are payment methods on `Customer` objects.\n\nOn the other hand [External Accounts](https://stripe.com/docs/api#external_accounts) are transfer\ndestinations on `Account` objects for [Custom accounts](https://stripe.com/docs/connect/custom-accounts).\nThey can be bank accounts or debit cards as well, and are documented in the links above.\n\nRelated guide: [Bank debits and transfers](https://stripe.com/docs/payments/bank-debits-transfers)", + "description": "These bank accounts are payment methods on `Customer` objects.\n\nOn the other hand [External Accounts](/api#external_accounts) are transfer\ndestinations on `Account` objects for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection)\nis `application`, which includes [Custom accounts](/connect/custom-accounts).\nThey can be bank accounts or debit cards as well, and are documented in the links above.\n\nRelated guide: [Bank debits and transfers](/payments/bank-debits-transfers)", "properties": { "account": { "anyOf": [ @@ -3708,6 +3708,12 @@ "format": "unix-time", "type": "integer" }, + "next_refresh_available_at": { + "description": "Time at which the next ownership refresh can be initiated. This value will be `null` when `status` is `pending`. Measured in seconds since the Unix epoch.", + "format": "unix-time", + "nullable": true, + "type": "integer" + }, "status": { "description": "The status of the last refresh attempt.", "enum": [ @@ -3720,6 +3726,7 @@ }, "required": [ "last_attempted_at", + "next_refresh_available_at", "status" ], "title": "BankConnectionsResourceOwnershipRefresh", @@ -3809,12 +3816,12 @@ "type": "string" }, "event_name": { - "description": "The name of the usage event to record usage for. Corresponds with the `event_name` field on usage events.", + "description": "The name of the meter event to record usage for. Corresponds with the `event_name` field on meter events.", "maxLength": 5000, "type": "string" }, "event_time_window": { - "description": "The time window to pre-aggregate usage events for, if any.", + "description": "The time window to pre-aggregate meter events for, if any.", "enum": [ "day", "hour" @@ -3966,7 +3973,7 @@ "maxLength": 100, "type": "string" }, - "description": "The payload of the event.", + "description": "The payload of the event. This contains the fields corresponding to a meter's `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and `value_settings.event_payload_key` (default is `value`). Read more about the [payload](https://stripe.com/docs/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).", "type": "object" }, "timestamp": { @@ -4078,11 +4085,11 @@ "description": "A billing meter event summary represents an aggregated view of a customer's billing meter events within a specified timeframe. It indicates how much\nusage was accrued by a customer for that period.", "properties": { "aggregated_value": { - "description": "Aggregated value of all the events within start_time (inclusive) and end_time (inclusive). The aggregation strategy is defined on meter via `default_aggregation``.", + "description": "Aggregated value of all the events within `start_time` (inclusive) and `end_time` (inclusive). The aggregation strategy is defined on meter via `default_aggregation`.", "type": "number" }, "end_time": { - "description": "End timestamp for this usage summary (inclusive).", + "description": "End timestamp for this event summary (inclusive).", "format": "unix-time", "type": "integer" }, @@ -4096,7 +4103,7 @@ "type": "boolean" }, "meter": { - "description": "The meter associated with this usage summary.", + "description": "The meter associated with this event summary.", "maxLength": 5000, "type": "string" }, @@ -4108,7 +4115,7 @@ "type": "string" }, "start_time": { - "description": "Start timestamp for this usage summary (inclusive).", + "description": "Start timestamp for this event summary (inclusive).", "format": "unix-time", "type": "integer" } @@ -4241,7 +4248,7 @@ "description": "", "properties": { "event_payload_key": { - "description": "The key in the usage event payload to use as the value for this meter.", + "description": "The key in the meter event payload to use as the value for this meter.", "maxLength": 5000, "type": "string" } @@ -4257,7 +4264,7 @@ "description": "", "properties": { "event_payload_key": { - "description": "The key in the usage event payload to use for mapping the event to a customer.", + "description": "The key in the meter event payload to use for mapping the event to a customer.", "maxLength": 5000, "type": "string" }, @@ -4830,7 +4837,7 @@ "$ref": "#/components/schemas/account" } ], - "description": "The account this card belongs to. This attribute will not be in the card object if the card belongs to a customer or recipient instead.", + "description": "The account this card belongs to. This attribute will not be in the card object if the card belongs to a customer or recipient instead. This property is only available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "nullable": true, "x-expansionResources": { "oneOf": [ @@ -4912,7 +4919,7 @@ "type": "string" }, "currency": { - "description": "Three-letter [ISO code for currency](https://stripe.com/docs/payouts). Only applicable on accounts (not customers or recipients). The card can be used as a transfer destination for funds in this currency.", + "description": "Three-letter [ISO code for currency](https://stripe.com/docs/payouts). Only applicable on accounts (not customers or recipients). The card can be used as a transfer destination for funds in this currency. This property is only available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "nullable": true, "type": "string" }, @@ -4949,7 +4956,7 @@ "type": "string" }, "default_for_currency": { - "description": "Whether this card is the default external account for its currency.", + "description": "Whether this card is the default external account for its currency. This property is only available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "nullable": true, "type": "boolean" }, @@ -6581,6 +6588,15 @@ "maxLength": 5000, "type": "string" }, + "saved_payment_method_options": { + "anyOf": [ + { + "$ref": "#/components/schemas/payment_pages_checkout_session_saved_payment_method_options" + } + ], + "description": "Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.", + "nullable": true + }, "setup_intent": { "anyOf": [ { @@ -6749,6 +6765,7 @@ "payment_method_types", "payment_status", "recovered_from", + "saved_payment_method_options", "setup_intent", "shipping_address_collection", "shipping_cost", @@ -6782,6 +6799,7 @@ "payment_method_configuration_details", "payment_method_options", "phone_number_collection", + "saved_payment_method_options", "setup_intent", "shipping_address_collection", "shipping_cost", @@ -7042,6 +7060,13 @@ "type": "object", "x-expandableFields": [] }, + "checkout_amazon_pay_payment_method_options": { + "description": "", + "properties": {}, + "title": "CheckoutAmazonPayPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, "checkout_au_becs_debit_payment_method_options": { "description": "", "properties": { @@ -7393,6 +7418,21 @@ "type": "object", "x-expandableFields": [] }, + "checkout_mobilepay_payment_method_options": { + "description": "", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).", + "enum": [ + "none" + ], + "type": "string" + } + }, + "title": "CheckoutMobilepayPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, "checkout_oxxo_payment_method_options": { "description": "", "properties": { @@ -7539,6 +7579,9 @@ "alipay": { "$ref": "#/components/schemas/checkout_alipay_payment_method_options" }, + "amazon_pay": { + "$ref": "#/components/schemas/checkout_amazon_pay_payment_method_options" + }, "au_becs_debit": { "$ref": "#/components/schemas/checkout_au_becs_debit_payment_method_options" }, @@ -7584,6 +7627,9 @@ "link": { "$ref": "#/components/schemas/checkout_link_payment_method_options" }, + "mobilepay": { + "$ref": "#/components/schemas/checkout_mobilepay_payment_method_options" + }, "oxxo": { "$ref": "#/components/schemas/checkout_oxxo_payment_method_options" }, @@ -7622,6 +7668,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -7637,6 +7684,7 @@ "klarna", "konbini", "link", + "mobilepay", "oxxo", "p24", "paynow", @@ -8359,7 +8407,7 @@ "type": "integer" }, "expires_at": { - "description": "Time at which this ConfirmationToken expires and can no longer be used to confirm a PaymentIntent or SetupIntent. This is set to null once this ConfirmationToken has been used.", + "description": "Time at which this ConfirmationToken expires and can no longer be used to confirm a PaymentIntent or SetupIntent.", "format": "unix-time", "nullable": true, "type": "integer" @@ -8565,6 +8613,9 @@ "alipay": { "$ref": "#/components/schemas/payment_flows_private_payment_methods_alipay" }, + "amazon_pay": { + "$ref": "#/components/schemas/payment_method_amazon_pay" + }, "au_becs_debit": { "$ref": "#/components/schemas/payment_method_au_becs_debit" }, @@ -8662,6 +8713,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -8719,6 +8771,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -8891,7 +8944,7 @@ ] } }, - "connect_embedded_account_config": { + "connect_embedded_account_config_claim": { "description": "", "properties": { "enabled": { @@ -8899,14 +8952,14 @@ "type": "boolean" }, "features": { - "$ref": "#/components/schemas/connect_embedded_account_features" + "$ref": "#/components/schemas/connect_embedded_account_features_claim" } }, "required": [ "enabled", "features" ], - "title": "ConnectEmbeddedAccountConfig", + "title": "ConnectEmbeddedAccountConfigClaim", "type": "object", "x-expandableFields": [ "features" @@ -8916,7 +8969,7 @@ "in_package": "" } }, - "connect_embedded_account_features": { + "connect_embedded_account_features_claim": { "description": "", "properties": { "external_account_collection": { @@ -8927,7 +8980,7 @@ "required": [ "external_account_collection" ], - "title": "ConnectEmbeddedAccountFeatures", + "title": "ConnectEmbeddedAccountFeaturesClaim", "type": "object", "x-expandableFields": [], "x-stripeResource": { @@ -8938,37 +8991,57 @@ "connect_embedded_account_session_create_components": { "description": "", "properties": { + "account_management": { + "$ref": "#/components/schemas/connect_embedded_account_config_claim" + }, "account_onboarding": { - "$ref": "#/components/schemas/connect_embedded_account_config" + "$ref": "#/components/schemas/connect_embedded_account_config_claim" + }, + "balances": { + "$ref": "#/components/schemas/connect_embedded_payouts_config_claim" }, "documents": { "$ref": "#/components/schemas/connect_embedded_base_config_claim" }, + "notification_banner": { + "$ref": "#/components/schemas/connect_embedded_account_config_claim" + }, "payment_details": { - "$ref": "#/components/schemas/connect_embedded_payments_config" + "$ref": "#/components/schemas/connect_embedded_payments_config_claim" }, "payments": { - "$ref": "#/components/schemas/connect_embedded_payments_config" + "$ref": "#/components/schemas/connect_embedded_payments_config_claim" }, "payouts": { - "$ref": "#/components/schemas/connect_embedded_payouts_config" + "$ref": "#/components/schemas/connect_embedded_payouts_config_claim" + }, + "payouts_list": { + "$ref": "#/components/schemas/connect_embedded_base_config_claim" } }, "required": [ + "account_management", "account_onboarding", + "balances", "documents", + "notification_banner", "payment_details", "payments", - "payouts" + "payouts", + "payouts_list" ], "title": "ConnectEmbeddedAccountSessionCreateComponents", "type": "object", "x-expandableFields": [ + "account_management", "account_onboarding", + "balances", "documents", + "notification_banner", "payment_details", "payments", - "payouts" + "payouts", + "payouts_list" ], "x-stripeResource": { "class_name": "Components", @@ -9011,7 +9084,7 @@ "in_package": "" } }, - "connect_embedded_payments_config": { + "connect_embedded_payments_config_claim": { "description": "", "properties": { "enabled": { @@ -9026,7 +9099,7 @@ "enabled", "features" ], - "title": "ConnectEmbeddedPaymentsConfig", + "title": "ConnectEmbeddedPaymentsConfigClaim", "type": "object", "x-expandableFields": [ "features" @@ -9058,6 +9131,7 @@ }, "required": [ "capture_payments", + "destination_on_behalf_of_charge_management", "dispute_management", "refund_management" ], @@ -9069,7 +9143,7 @@ "in_package": "" } }, - "connect_embedded_payouts_config": { + "connect_embedded_payouts_config_claim": { "description": "", "properties": { "enabled": { @@ -9084,7 +9158,7 @@ "enabled", "features" ], - "title": "ConnectEmbeddedPayoutsConfig", + "title": "ConnectEmbeddedPayoutsConfigClaim", "type": "object", "x-expandableFields": [ "features" @@ -13910,24 +13984,18 @@ "description": "", "properties": { "card": { - "anyOf": [ - { - "$ref": "#/components/schemas/dispute_payment_method_details_card" - } - ], - "description": "Card specific dispute details.", - "nullable": true + "$ref": "#/components/schemas/dispute_payment_method_details_card" }, "type": { "description": "Payment method type.", "enum": [ "card" ], - "type": "string" + "type": "string", + "x-stripeBypassValidation": true } }, "required": [ - "card", "type" ], "title": "DisputePaymentMethodDetails", @@ -14044,6 +14112,96 @@ "in_package": "Entitlements" } }, + "entitlements.active_entitlement_summary": { + "description": "A summary of a customer's active entitlements.", + "properties": { + "customer": { + "description": "The customer that is entitled to this feature.", + "maxLength": 5000, + "type": "string" + }, + "entitlements": { + "description": "The list of entitlements this customer has.", + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/entitlements.active_entitlement" + }, + "type": "array" + }, + "has_more": { + "description": "True if this list has another page of items after this one that can be fetched.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value. Always has the value `list`.", + "enum": [ + "list" + ], + "type": "string" + }, + "url": { + "description": "The URL where this list can be accessed.", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "data", + "has_more", + "object", + "url" + ], + "title": "EntitlementsResourceCustomerEntitlementList", + "type": "object", + "x-expandableFields": [ + "data" + ] + }, + "livemode": { + "description": "Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.", + "type": "boolean" + }, + "object": { + "description": "String representing the object's type. Objects of the same type share the same value.", + "enum": [ + "entitlements.active_entitlement_summary" + ], + "type": "string" + } + }, + "required": [ + "customer", + "entitlements", + "livemode", + "object" + ], + "title": "ActiveEntitlementSummary", + "type": "object", + "x-expandableFields": [ + "entitlements" + ], + "x-stripeResource": { + "class_name": "ActiveEntitlementSummary", + "in_package": "Entitlements" + } + }, + "entitlements.active_entitlement_summary.updated": { + "description": "Occurs whenever a customer's entitlements change.", + "properties": { + "object": { + "$ref": "#/components/schemas/entitlements.active_entitlement_summary" + } + }, + "required": [ + "object" + ], + "type": "object", + "x-expandableFields": [], + "x-stripeEvent": { + "type": "entitlements.active_entitlement_summary.updated" + } + }, "entitlements.feature": { "description": "A feature represents a monetizable ability or functionality in your system.\nFeatures can be assigned to products, and when those products are purchased, Stripe will create an entitlement to the feature for the purchasing customer.", "properties": { @@ -14339,6 +14497,7 @@ "customer.tax_id.updated", "customer.updated", "customer_cash_balance_transaction.created", + "entitlements.active_entitlement_summary.updated", "file.created", "financial_connections.account.created", "financial_connections.account.deactivated", @@ -16157,13 +16316,8 @@ ] }, "forwarding.request": { - "description": "Instructs Stripe to make a request on your behalf using the destination URL and HTTP method in the config.\nA config is set up for each destination URL by Stripe at the time of onboarding. Stripe verifies requests with\nyour credentials in the config, and injects card details from the payment_method into the request.\n\nStripe redacts all sensitive fields and headers, including authentication credentials and card numbers,\nbefore storing the request and response data in the forwarding Request object, which are subject to a\n30-day retention period.\n\nYou can provide a Stripe idempotency key to make sure that requests with the same key result in only one\noutbound request. The Stripe idempotency key provided should be unique and different from any idempotency\nkeys provided on the underlying third-party request.\n\nForwarding Requests are synchronous requests that return a response or time out according to\nStripe’s limits.\n\nRelated guide: [Forward card details to third-party API endpoints](https://docs.stripe.com/payments/forwarding).", + "description": "Instructs Stripe to make a request on your behalf using the destination URL. The destination URL\nis activated by Stripe at the time of onboarding. Stripe verifies requests with your credentials\nprovided during onboarding, and injects card details from the payment_method into the request.\n\nStripe redacts all sensitive fields and headers, including authentication credentials and card numbers,\nbefore storing the request and response data in the forwarding Request object, which are subject to a\n30-day retention period.\n\nYou can provide a Stripe idempotency key to make sure that requests with the same key result in only one\noutbound request. The Stripe idempotency key provided should be unique and different from any idempotency\nkeys provided on the underlying third-party request.\n\nForwarding Requests are synchronous requests that return a response or time out according to\nStripe’s limits.\n\nRelated guide: [Forward card details to third-party API endpoints](https://docs.stripe.com/payments/forwarding).", "properties": { - "config": { - "description": "The Forwarding Config used when making the forwarded request. The config specifes the HTTP method, merchant credentials, connection settings, and supported destination URLs.", - "maxLength": 5000, - "type": "string" - }, "created": { "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", "format": "unix-time", @@ -16238,7 +16392,6 @@ } }, "required": [ - "config", "created", "id", "livemode", @@ -17531,10 +17684,12 @@ "required": [ "address", "dob", + "email", "first_name", "id_number", "id_number_type", - "last_name" + "last_name", + "phone" ], "title": "GelatoVerifiedOutputs", "type": "object", @@ -17807,6 +17962,7 @@ "metadata", "object", "options", + "provided_details", "redaction", "status", "type", @@ -19087,6 +19243,13 @@ "method_type": "custom", "operation": "post", "path": "/v1/invoices/{invoice}/void" + }, + { + "method_name": "create_preview", + "method_on": "service", + "method_type": "custom", + "operation": "post", + "path": "/v1/invoices/create_preview" } ], "x-stripeResource": { @@ -19602,11 +19765,11 @@ "items": { "enum": [ "balances", + "ownership", "payment_method", "transactions" ], - "type": "string", - "x-stripeBypassValidation": true + "type": "string" }, "type": "array" }, @@ -19615,6 +19778,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -19674,6 +19838,23 @@ "type": "object", "x-expandableFields": [] }, + "invoice_setting_customer_rendering_options": { + "description": "", + "properties": { + "amount_tax_display": { + "description": "How line-item prices and amounts will be displayed with respect to tax on invoice PDFs.", + "maxLength": 5000, + "nullable": true, + "type": "string" + } + }, + "required": [ + "amount_tax_display" + ], + "title": "InvoiceSettingCustomerRenderingOptions", + "type": "object", + "x-expandableFields": [] + }, "invoice_setting_customer_setting": { "description": "", "properties": { @@ -19714,7 +19895,7 @@ "rendering_options": { "anyOf": [ { - "$ref": "#/components/schemas/invoice_setting_rendering_options" + "$ref": "#/components/schemas/invoice_setting_customer_rendering_options" } ], "description": "Default options for invoice PDF rendering for this customer.", @@ -26790,7 +26971,7 @@ "type": "string" }, "unit": { - "description": "The units for `volume_decimal`. One of `us_gallon` or `liter`.", + "description": "The units for `volume_decimal`. One of `liter`, `us_gallon`, or `other`.", "maxLength": 5000, "type": "string" }, @@ -27715,7 +27896,7 @@ "maxLength": 500, "type": "string" }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items with `type=subscription` this will reflect the metadata of the subscription that caused the line item to be created.", + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Note that for line items with `type=subscription`, `metadata` reflects the current metadata from the subscription associated with the line item, unless the invoice line was directly updated with different metadata after creation.", "type": "object" }, "object": { @@ -27993,6 +28174,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -28015,7 +28197,7 @@ "x-expandableFields": [] }, "login_link": { - "description": "Login Links are single-use login link for an Express account to access their Stripe dashboard.", + "description": "Login Links are single-use URLs for a connected account to access the Express Dashboard. The connected account's [account.controller.stripe_dashboard.type](/api/accounts/object#account_object-controller-stripe_dashboard-type) must be `express` to have access to the Express Dashboard.", "properties": { "created": { "description": "Time at which the object was created. Measured in seconds since the Unix epoch.", @@ -30733,6 +30915,9 @@ "alipay": { "$ref": "#/components/schemas/payment_method_options_alipay" }, + "amazon_pay": { + "$ref": "#/components/schemas/payment_method_options_amazon_pay" + }, "au_becs_debit": { "$ref": "#/components/schemas/payment_intent_payment_method_options_au_becs_debit" }, @@ -30837,6 +31022,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -32867,6 +33053,9 @@ "alipay": { "$ref": "#/components/schemas/payment_flows_private_payment_methods_alipay" }, + "amazon_pay": { + "$ref": "#/components/schemas/payment_method_amazon_pay" + }, "au_becs_debit": { "$ref": "#/components/schemas/payment_method_au_becs_debit" }, @@ -33017,6 +33206,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -33080,6 +33270,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -33290,6 +33481,13 @@ "type": "object", "x-expandableFields": [] }, + "payment_method_amazon_pay": { + "description": "", + "properties": {}, + "title": "payment_method_amazon_pay", + "type": "object", + "x-expandableFields": [] + }, "payment_method_au_becs_debit": { "description": "", "properties": { @@ -33976,6 +34174,9 @@ "alipay": { "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" }, + "amazon_pay": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, "apple_pay": { "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" }, @@ -34097,6 +34298,9 @@ "sofort": { "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" }, + "swish": { + "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" + }, "us_bank_account": { "$ref": "#/components/schemas/payment_method_config_resource_payment_method_properties" }, @@ -34124,6 +34328,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "apple_pay", "au_becs_debit", "bacs_debit", @@ -34152,6 +34357,7 @@ "revolut_pay", "sepa_debit", "sofort", + "swish", "us_bank_account", "wechat_pay", "zip" @@ -34221,6 +34427,9 @@ "alipay": { "$ref": "#/components/schemas/payment_flows_private_payment_methods_alipay_details" }, + "amazon_pay": { + "$ref": "#/components/schemas/payment_method_details_amazon_pay" + }, "au_becs_debit": { "$ref": "#/components/schemas/payment_method_details_au_becs_debit" }, @@ -34347,6 +34556,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -34559,6 +34769,13 @@ "type": "object", "x-expandableFields": [] }, + "payment_method_details_amazon_pay": { + "description": "", + "properties": {}, + "title": "payment_method_details_amazon_pay", + "type": "object", + "x-expandableFields": [] + }, "payment_method_details_au_becs_debit": { "description": "", "properties": { @@ -37239,6 +37456,21 @@ "type": "object", "x-expandableFields": [] }, + "payment_method_options_amazon_pay": { + "description": "", + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": [ + "manual" + ], + "type": "string" + } + }, + "title": "payment_method_options_amazon_pay", + "type": "object", + "x-expandableFields": [] + }, "payment_method_options_bacs_debit": { "description": "", "properties": { @@ -37857,7 +38089,15 @@ }, "payment_method_options_revolut_pay": { "description": "", - "properties": {}, + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.", + "enum": [ + "manual" + ], + "type": "string" + } + }, "title": "payment_method_options_revolut_pay", "type": "object", "x-expandableFields": [] @@ -38985,6 +39225,40 @@ "type": "object", "x-expandableFields": [] }, + "payment_pages_checkout_session_saved_payment_method_options": { + "description": "", + "properties": { + "allow_redisplay_filters": { + "description": "Controls which payment methods are eligible to be redisplayed to returning customers. Corresponds to `allow_redisplay` on the payment method.", + "items": { + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "payment_method_save": { + "description": "Enable customers to choose if they wish to save their payment method for future use.", + "enum": [ + "disabled", + "enabled" + ], + "nullable": true, + "type": "string" + } + }, + "required": [ + "allow_redisplay_filters", + "payment_method_save" + ], + "title": "PaymentPagesCheckoutSessionSavedPaymentMethodOptions", + "type": "object", + "x-expandableFields": [] + }, "payment_pages_checkout_session_shipping_address_collection": { "description": "", "properties": { @@ -40034,7 +40308,7 @@ "x-expandableFields": [] }, "person": { - "description": "This is an object representing a person associated with a Stripe account.\n\nA platform cannot access a Standard or Express account's persons after the account starts onboarding, such as after generating an account link for the account.\nSee the [Standard onboarding](https://stripe.com/docs/connect/standard-accounts) or [Express onboarding documentation](https://stripe.com/docs/connect/express-accounts) for information about platform prefilling and account onboarding steps.\n\nRelated guide: [Handling identity verification with the API](https://stripe.com/docs/connect/handling-api-verification#person-information)", + "description": "This is an object representing a person associated with a Stripe account.\n\nA platform cannot access a person for an account where [account.controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`, which includes Standard and Express accounts, after creating an Account Link or Account Session to start Connect onboarding.\n\nSee the [Standard onboarding](/connect/standard-accounts) or [Express onboarding](/connect/express-accounts) documentation for information about prefilling information and account onboarding steps. Learn more about [handling identity verification with the API](/connect/handling-api-verification#person-information).", "properties": { "account": { "description": "The account the person is associated with.", @@ -44369,6 +44643,9 @@ "alipay": { "$ref": "#/components/schemas/destination_details_unimplemented" }, + "amazon_pay": { + "$ref": "#/components/schemas/destination_details_unimplemented" + }, "au_bank_transfer": { "$ref": "#/components/schemas/destination_details_unimplemented" }, @@ -44459,6 +44736,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_bank_transfer", "blik", "br_bank_transfer", @@ -46251,7 +46529,7 @@ } }, "setup_intent": { - "description": "A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments.\nFor example, you can use a SetupIntent to set up and save your customer's card without immediately collecting a payment.\nLater, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow.\n\nCreate a SetupIntent when you're ready to collect your customer's payment credentials.\nDon't maintain long-lived, unconfirmed SetupIntents because they might not be valid.\nThe SetupIntent transitions through multiple [statuses](https://stripe.com/docs/payments/intents#intent-statuses) as it guides\nyou through the setup process.\n\nSuccessful SetupIntents result in payment credentials that are optimized for future payments.\nFor example, cardholders in [certain regions](/guides/strong-customer-authentication) might need to be run through\n[Strong Customer Authentication](https://stripe.com/docs/strong-customer-authentication) during payment method collection\nto streamline later [off-session payments](https://stripe.com/docs/payments/setup-intents).\nIf you use the SetupIntent with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer),\nit automatically attaches the resulting payment method to that Customer after successful setup.\nWe recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on\nPaymentIntents to save payment methods to prevent saving invalid or unoptimized payment methods.\n\nBy using SetupIntents, you can reduce friction for your customers, even as regulations change over time.\n\nRelated guide: [Setup Intents API](https://stripe.com/docs/payments/setup-intents)", + "description": "A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments.\nFor example, you can use a SetupIntent to set up and save your customer's card without immediately collecting a payment.\nLater, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow.\n\nCreate a SetupIntent when you're ready to collect your customer's payment credentials.\nDon't maintain long-lived, unconfirmed SetupIntents because they might not be valid.\nThe SetupIntent transitions through multiple [statuses](https://docs.stripe.com/payments/intents#intent-statuses) as it guides\nyou through the setup process.\n\nSuccessful SetupIntents result in payment credentials that are optimized for future payments.\nFor example, cardholders in [certain regions](https://stripe.com/guides/strong-customer-authentication) might need to be run through\n[Strong Customer Authentication](https://docs.stripe.com/strong-customer-authentication) during payment method collection\nto streamline later [off-session payments](https://docs.stripe.com/payments/setup-intents).\nIf you use the SetupIntent with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer),\nit automatically attaches the resulting payment method to that Customer after successful setup.\nWe recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on\nPaymentIntents to save payment methods to prevent saving invalid or unoptimized payment methods.\n\nBy using SetupIntents, you can reduce friction for your customers, even as regulations change over time.\n\nRelated guide: [Setup Intents API](https://docs.stripe.com/payments/setup-intents)", "properties": { "application": { "anyOf": [ @@ -46817,6 +47095,9 @@ "acss_debit": { "$ref": "#/components/schemas/setup_intent_payment_method_options_acss_debit" }, + "amazon_pay": { + "$ref": "#/components/schemas/setup_intent_payment_method_options_amazon_pay" + }, "card": { "$ref": "#/components/schemas/setup_intent_payment_method_options_card" }, @@ -46840,6 +47121,7 @@ "type": "object", "x-expandableFields": [ "acss_debit", + "amazon_pay", "card", "card_present", "link", @@ -46883,6 +47165,13 @@ "mandate_options" ] }, + "setup_intent_payment_method_options_amazon_pay": { + "description": "", + "properties": {}, + "title": "setup_intent_payment_method_options_amazon_pay", + "type": "object", + "x-expandableFields": [] + }, "setup_intent_payment_method_options_card": { "description": "", "properties": { @@ -55465,7 +55754,7 @@ "x-expandableFields": [] }, "token": { - "description": "Tokenization is the process Stripe uses to collect sensitive card or bank\naccount details, or personally identifiable information (PII), directly from\nyour customers in a secure manner. A token representing this information is\nreturned to your server to use. Use our\n[recommended payments integrations](https://stripe.com/docs/payments) to perform this process\non the client-side. This guarantees that no sensitive card data touches your server,\nand allows your integration to operate in a PCI-compliant way.\n\nIf you can't use client-side tokenization, you can also create tokens using\nthe API with either your publishable or secret API key. If\nyour integration uses this method, you're responsible for any PCI compliance\nthat it might require, and you must keep your secret API key safe. Unlike with\nclient-side tokenization, your customer's information isn't sent directly to\nStripe, so we can't determine how it's handled or stored.\n\nYou can't store or use tokens more than once. To store card or bank account\ninformation for later use, create [Customer](https://stripe.com/docs/api#customers)\nobjects or [Custom accounts](https://stripe.com/docs/api#external_accounts).\n[Radar](https://stripe.com/docs/radar), our integrated solution for automatic fraud protection,\nperforms best with integrations that use client-side tokenization.", + "description": "Tokenization is the process Stripe uses to collect sensitive card or bank\naccount details, or personally identifiable information (PII), directly from\nyour customers in a secure manner. A token representing this information is\nreturned to your server to use. Use our\n[recommended payments integrations](https://stripe.com/docs/payments) to perform this process\non the client-side. This guarantees that no sensitive card data touches your server,\nand allows your integration to operate in a PCI-compliant way.\n\nIf you can't use client-side tokenization, you can also create tokens using\nthe API with either your publishable or secret API key. If\nyour integration uses this method, you're responsible for any PCI compliance\nthat it might require, and you must keep your secret API key safe. Unlike with\nclient-side tokenization, your customer's information isn't sent directly to\nStripe, so we can't determine how it's handled or stored.\n\nYou can't store or use tokens more than once. To store card or bank account\ninformation for later use, create [Customer](https://stripe.com/docs/api#customers)\nobjects or [External accounts](/api#external_accounts).\n[Radar](https://stripe.com/docs/radar), our integrated solution for automatic fraud protection,\nperforms best with integrations that use client-side tokenization.", "properties": { "bank_account": { "$ref": "#/components/schemas/bank_account" @@ -60566,6 +60855,31 @@ "components": { "description": "Each key of the dictionary represents an embedded component, and each embedded component maps to its configuration (e.g. whether it has been enabled or not).", "properties": { + "account_management": { + "description": "Configuration for the account management embedded component.", + "properties": { + "enabled": { + "description": "Whether the embedded component is enabled.", + "type": "boolean" + }, + "features": { + "description": "The list of features enabled in the embedded component.", + "properties": { + "external_account_collection": { + "description": "Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for custom accounts (or accounts where the platform is compliance owner). Otherwise, bank account collection is determined by compliance requirements.", + "type": "boolean" + } + }, + "title": "account_features_param", + "type": "object" + } + }, + "required": [ + "enabled" + ], + "title": "account_config_param", + "type": "object" + }, "account_onboarding": { "description": "Configuration for the account onboarding embedded component.", "properties": { @@ -60591,6 +60905,39 @@ "title": "account_config_param", "type": "object" }, + "balances": { + "description": "Configuration for the balances embedded component.", + "properties": { + "enabled": { + "description": "Whether the embedded component is enabled.", + "type": "boolean" + }, + "features": { + "description": "The list of features enabled in the embedded component.", + "properties": { + "edit_payout_schedule": { + "description": "Whether to allow payout schedule to be changed. Default `true` when Stripe owns Loss Liability, default `false` otherwise.", + "type": "boolean" + }, + "instant_payouts": { + "description": "Whether to allow creation of instant payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.", + "type": "boolean" + }, + "standard_payouts": { + "description": "Whether to allow creation of standard payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.", + "type": "boolean" + } + }, + "title": "payouts_features_param", + "type": "object" + } + }, + "required": [ + "enabled" + ], + "title": "payouts_config_param", + "type": "object" + }, "documents": { "description": "Configuration for the documents embedded component.", "properties": { @@ -60611,6 +60958,31 @@ "title": "base_config_param", "type": "object" }, + "notification_banner": { + "description": "Configuration for the notification banner embedded component.", + "properties": { + "enabled": { + "description": "Whether the embedded component is enabled.", + "type": "boolean" + }, + "features": { + "description": "The list of features enabled in the embedded component.", + "properties": { + "external_account_collection": { + "description": "Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for custom accounts (or accounts where the platform is compliance owner). Otherwise, bank account collection is determined by compliance requirements.", + "type": "boolean" + } + }, + "title": "account_features_param", + "type": "object" + } + }, + "required": [ + "enabled" + ], + "title": "account_config_param", + "type": "object" + }, "payment_details": { "description": "Configuration for the payment details embedded component.", "properties": { @@ -60717,6 +61089,26 @@ ], "title": "payouts_config_param", "type": "object" + }, + "payouts_list": { + "description": "Configuration for the payouts list embedded component.", + "properties": { + "enabled": { + "description": "Whether the embedded component is enabled.", + "type": "boolean" + }, + "features": { + "description": "The list of features enabled in the embedded component.", + "properties": {}, + "title": "base_features_param", + "type": "object" + } + }, + "required": [ + "enabled" + ], + "title": "base_config_param", + "type": "object" } }, "title": "account_session_create_components_param", @@ -61116,7 +61508,7 @@ "type": "object" }, "business_type": { - "description": "The business type. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for Custom accounts.", + "description": "The business type. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "enum": [ "company", "government_entity", @@ -61127,7 +61519,7 @@ "x-stripeBypassValidation": true }, "capabilities": { - "description": "Each key of the dictionary represents a capability, and each capability maps to its settings (e.g. whether it has been requested or not). Each capability will be inactive until you have provided its specific requirements and Stripe has verified them. An account may have some of its requested capabilities be active and some be inactive.", + "description": "Each key of the dictionary represents a capability, and each capability\nmaps to its settings (for example, whether it has been requested or not). Each\ncapability is inactive until you have provided its specific\nrequirements and Stripe has verified them. An account might have some\nof its requested capabilities be active and some be inactive.\n\nRequired when [account.controller.stripe_dashboard.type](/api/accounts/create#create_account-controller-dashboard-type)\nis `none`, which includes Custom accounts.", "properties": { "acss_debit_payments": { "description": "The acss_debit_payments capability.", @@ -61574,7 +61966,7 @@ "type": "object" }, "company": { - "description": "Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for Custom accounts.", + "description": "Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "properties": { "address": { "description": "The company's primary address.", @@ -62022,7 +62414,7 @@ "type": "object" }, "email": { - "description": "The email address of the account holder. This is only to make the account easier to identify to you. Stripe only emails Custom accounts with your consent.", + "description": "The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.", "type": "string" }, "expand": { @@ -62034,13 +62426,13 @@ "type": "array" }, "external_account": { - "description": "A card or bank account to attach to the account for receiving [payouts](https://docs.stripe.com/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](https://docs.stripe.com/js), or a dictionary, as documented in the `external_account` parameter for [bank account](https://docs.stripe.com/api#account_create_bank_account) creation.

By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](https://docs.stripe.com/api#account_create_bank_account) or [card creation](https://docs.stripe.com/api#account_create_card) APIs. After you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for Custom accounts.", + "description": "A card or bank account to attach to the account for receiving [payouts](/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](/js), or a dictionary, as documented in the `external_account` parameter for [bank account](/api#account_create_bank_account) creation.

By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](/api#account_create_bank_account) or [card creation](/api#account_create_card) APIs. After you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "maxLength": 5000, "type": "string", "x-stripeBypassValidation": true }, "individual": { - "description": "Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for Custom accounts.", + "description": "Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "properties": { "address": { "description": "The individual's primary address.", @@ -62708,7 +63100,7 @@ "type": "object" }, "tos_acceptance": { - "description": "Details on the account's acceptance of the [Stripe Services Agreement](https://docs.stripe.com/connect/updating-accounts#tos-acceptance) This property can only be updated for Custom accounts.", + "description": "Details on the account's acceptance of the [Stripe Services Agreement](/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "properties": { "date": { "description": "The Unix timestamp marking when the account representative accepted their service agreement.", @@ -62775,7 +63167,7 @@ }, "/v1/accounts/{account}": { "delete": { - "description": "

With Connect, you can delete accounts you manage.

\n\n

Accounts created using test-mode keys can be deleted at any time. Standard accounts created using live-mode keys cannot be deleted. Custom or Express accounts created using live-mode keys can only be deleted once all balances are zero.

\n\n

If you want to delete your own account, use the account information tab in your account settings instead.

", + "description": "

With Connect, you can delete accounts you manage.

\n\n

Test-mode accounts can be deleted at any time.

\n\n

Live-mode accounts where Stripe is responsible for negative account balances cannot be deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be deleted when all balances are zero.

\n\n

If you want to delete your own account, use the account information tab in your account settings instead.

", "operationId": "DeleteAccountsAccount", "parameters": [ { @@ -62892,7 +63284,7 @@ } }, "post": { - "description": "

Updates a connected account by setting the values of the parameters passed. Any parameters not provided are\nleft unchanged.

\n\n

For Custom accounts, you can update any information on the account. For other accounts, you can update all information until that\naccount has started to go through Connect Onboarding. Once you create an Account Link or Account Session,\nsome properties can only be changed or updated for Custom accounts.

\n\n

To update your own account, use the Dashboard. Refer to our\nConnect documentation to learn more about updating accounts.

", + "description": "

Updates a connected account by setting the values of the parameters passed. Any parameters not provided are\nleft unchanged.

\n\n

For accounts where controller.requirement_collection\nis application, which includes Custom accounts, you can update any information on the account.

\n\n

For accounts where controller.requirement_collection\nis stripe, which includes Standard and Express accounts, you can update all information until you create\nan Account Link or Account Session to start Connect onboarding,\nafter which some properties can no longer be updated.

\n\n

To update your own account, use the Dashboard. Refer to our\nConnect documentation to learn more about updating accounts.

", "operationId": "PostAccountsAccount", "parameters": [ { @@ -63090,7 +63482,7 @@ "type": "object" }, "business_type": { - "description": "The business type. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for Custom accounts.", + "description": "The business type. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "enum": [ "company", "government_entity", @@ -63101,7 +63493,7 @@ "x-stripeBypassValidation": true }, "capabilities": { - "description": "Each key of the dictionary represents a capability, and each capability maps to its settings (e.g. whether it has been requested or not). Each capability will be inactive until you have provided its specific requirements and Stripe has verified them. An account may have some of its requested capabilities be active and some be inactive.", + "description": "Each key of the dictionary represents a capability, and each capability\nmaps to its settings (for example, whether it has been requested or not). Each\ncapability is inactive until you have provided its specific\nrequirements and Stripe has verified them. An account might have some\nof its requested capabilities be active and some be inactive.\n\nRequired when [account.controller.stripe_dashboard.type](/api/accounts/create#create_account-controller-dashboard-type)\nis `none`, which includes Custom accounts.", "properties": { "acss_debit_payments": { "description": "The acss_debit_payments capability.", @@ -63548,7 +63940,7 @@ "type": "object" }, "company": { - "description": "Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for Custom accounts.", + "description": "Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "properties": { "address": { "description": "The company's primary address.", @@ -63930,7 +64322,7 @@ "type": "object" }, "email": { - "description": "The email address of the account holder. This is only to make the account easier to identify to you. Stripe only emails Custom accounts with your consent.", + "description": "The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.", "type": "string" }, "expand": { @@ -63942,13 +64334,13 @@ "type": "array" }, "external_account": { - "description": "A card or bank account to attach to the account for receiving [payouts](https://docs.stripe.com/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](https://docs.stripe.com/js), or a dictionary, as documented in the `external_account` parameter for [bank account](https://docs.stripe.com/api#account_create_bank_account) creation.

By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](https://docs.stripe.com/api#account_create_bank_account) or [card creation](https://docs.stripe.com/api#account_create_card) APIs. After you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for Custom accounts.", + "description": "A card or bank account to attach to the account for receiving [payouts](/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](/js), or a dictionary, as documented in the `external_account` parameter for [bank account](/api#account_create_bank_account) creation.

By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](/api#account_create_bank_account) or [card creation](/api#account_create_card) APIs. After you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "maxLength": 5000, "type": "string", "x-stripeBypassValidation": true }, "individual": { - "description": "Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions), this property can only be updated for Custom accounts.", + "description": "Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "properties": { "address": { "description": "The individual's primary address.", @@ -64641,7 +65033,7 @@ "type": "object" }, "tos_acceptance": { - "description": "Details on the account's acceptance of the [Stripe Services Agreement](https://docs.stripe.com/connect/updating-accounts#tos-acceptance) This property can only be updated for Custom accounts.", + "description": "Details on the account's acceptance of the [Stripe Services Agreement](/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.", "properties": { "date": { "description": "The Unix timestamp marking when the account representative accepted their service agreement.", @@ -65334,7 +65726,7 @@ } }, "post": { - "description": "

Updates the metadata, account holder name, account holder type of a bank account belonging to a Custom account, and optionally sets it as the default for its currency. Other bank account details are not editable by design.

\n\n

You can re-enable a disabled bank account by performing an update call without providing any arguments or changes.

", + "description": "

Updates the metadata, account holder name, account holder type of a bank account belonging to\na connected account and optionally sets it as the default for its currency. Other bank account\ndetails are not editable by design.

\n\n

You can only update bank accounts when account.controller.requirement_collection is application, which includes Custom accounts.

\n\n

You can re-enable a disabled bank account by performing an update call without providing any\narguments or changes.

", "operationId": "PostAccountsAccountExternalAccountsId", "parameters": [ { @@ -65532,7 +65924,7 @@ }, "/v1/accounts/{account}/login_links": { "post": { - "description": "

Creates a single-use login link for an Express account to access their Stripe dashboard.

\n\n

You may only create login links for Express accounts connected to your platform.

", + "description": "

Creates a single-use login link for a connected account to access the Express Dashboard.

\n\n

You can only create login links for accounts that use the Express Dashboard and are connected to your platform.

", "operationId": "PostAccountsAccountLoginLinks", "parameters": [ { @@ -67155,7 +67547,7 @@ }, "/v1/accounts/{account}/reject": { "post": { - "description": "

With Connect, you may flag accounts as suspicious.

\n\n

Test-mode Custom and Express accounts can be rejected at any time. Accounts created using live-mode keys may only be rejected once all balances are zero.

", + "description": "

With Connect, you can reject accounts that you have flagged as suspicious.

\n\n

Only accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time. Live-mode accounts can only be rejected after all balances are zero.

", "operationId": "PostAccountsAccountReject", "parameters": [ { @@ -69081,19 +69473,18 @@ "additionalProperties": { "type": "string" }, - "description": "The payload of the event. This must contain a field with the event's numerical value and a field to map the event to a customer.", + "description": "The payload of the event. This must contain the fields corresponding to a meter's `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and `value_settings.event_payload_key` (default is `value`). Read more about the [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).", "type": "object" }, "timestamp": { - "description": "The time of the event. Measured in seconds since the Unix epoch.", + "description": "The time of the event. Measured in seconds since the Unix epoch. Must be within the past 35 calendar days or up to 5 minutes in the future. Defaults to current timestamp if not specified.", "format": "unix-time", "type": "integer" } }, "required": [ "event_name", - "payload", - "timestamp" + "payload" ], "type": "object" } @@ -69318,7 +69709,7 @@ "description": "The default settings to aggregate a meter's events with.", "properties": { "formula": { - "description": "Specifies how events are aggregated. Allowed values are `count` to count the number of events, `sum` to sum each event's value, or `last` to use the last event's value.", + "description": "Specifies how events are aggregated. Allowed values are `count` to count the number of events and `sum` to sum each event's value.", "enum": [ "count", "sum" @@ -69338,12 +69729,12 @@ "type": "string" }, "event_name": { - "description": "The name of the usage event to record usage for. Corresponds with the `event_name` field on usage events.", + "description": "The name of the meter event to record usage for. Corresponds with the `event_name` field on meter events.", "maxLength": 100, "type": "string" }, "event_time_window": { - "description": "The time window to pre-aggregate usage events for, if any.", + "description": "The time window to pre-aggregate meter events for, if any.", "enum": [ "day", "hour" @@ -69359,7 +69750,7 @@ "type": "array" }, "value_settings": { - "description": "Fields that specify how to calculate a usage event's value.", + "description": "Fields that specify how to calculate a meter event's value.", "properties": { "event_payload_key": { "description": "The key in the usage event payload to use as the value for this meter. For example, if the event payload contains usage on a `bytes_used` field, then set the event_payload_key to \"bytes_used\".", @@ -69634,7 +70025,7 @@ "style": "form" }, { - "description": "The timestamp from when to stop aggregating usage events (exclusive).", + "description": "The timestamp from when to stop aggregating meter events (exclusive).", "in": "query", "name": "end_time", "required": true, @@ -69692,7 +70083,7 @@ "style": "form" }, { - "description": "The timestamp from when to start aggregating usage events (inclusive).", + "description": "The timestamp from when to start aggregating meter events (inclusive).", "in": "query", "name": "start_time", "required": true, @@ -72660,6 +73051,10 @@ "explode": true, "style": "deepObject" }, + "payment_method_data": { + "explode": true, + "style": "deepObject" + }, "payment_method_options": { "explode": true, "style": "deepObject" @@ -72672,6 +73067,10 @@ "explode": true, "style": "deepObject" }, + "saved_payment_method_options": { + "explode": true, + "style": "deepObject" + }, "setup_intent_data": { "explode": true, "style": "deepObject" @@ -73658,6 +74057,22 @@ "maxLength": 100, "type": "string" }, + "payment_method_data": { + "description": "This parameter allows you to set some attributes on the payment method created during a Checkout session.", + "properties": { + "allow_redisplay": { + "description": "Allow redisplay will be set on the payment method on confirmation and indicates whether this payment method can be shown again to the customer in a checkout flow. Only set this field if you wish to override the allow_redisplay value determined by Checkout.", + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + } + }, + "title": "payment_method_data_param", + "type": "object" + }, "payment_method_options": { "description": "Payment-method-specific configuration.", "properties": { @@ -73791,6 +74206,21 @@ "title": "payment_method_options_param", "type": "object" }, + "amazon_pay": { + "description": "contains details about the AmazonPay payment method options.", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).", + "enum": [ + "none", + "off_session" + ], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, "au_becs_debit": { "description": "contains details about the AU Becs Debit payment method options.", "properties": { @@ -74109,6 +74539,20 @@ "title": "payment_method_options_param", "type": "object" }, + "mobilepay": { + "description": "contains details about the Mobilepay payment method options.", + "properties": { + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).", + "enum": [ + "none" + ], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, "oxxo": { "description": "contains details about the OXXO payment method options.", "properties": { @@ -74315,6 +74759,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -74392,6 +74837,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -74408,6 +74854,7 @@ "klarna", "konbini", "link", + "mobilepay", "oxxo", "p24", "paynow", @@ -74455,6 +74902,33 @@ "maxLength": 5000, "type": "string" }, + "saved_payment_method_options": { + "description": "Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.", + "properties": { + "allow_redisplay_filters": { + "description": "Controls which payment methods are eligible to be redisplayed to returning customers. Corresponds to `allow_redisplay` on the payment method.", + "items": { + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, + "type": "array" + }, + "payment_method_save": { + "description": "Enable customers to choose if they wish to save their payment method for future use.", + "enum": [ + "disabled", + "enabled" + ], + "type": "string" + } + }, + "title": "saved_payment_method_options_param", + "type": "object" + }, "setup_intent_data": { "description": "A subset of parameters to be passed to SetupIntent creation for Checkout Sessions in `setup` mode.", "properties": { @@ -78993,7 +79467,7 @@ "type": "string" } }, - "title": "rendering_options_param", + "title": "customer_rendering_options_param", "type": "object" }, { @@ -79785,7 +80259,7 @@ "type": "string" } }, - "title": "rendering_options_param", + "title": "customer_rendering_options_param", "type": "object" }, { @@ -80970,6 +81444,21 @@ "description": "

Returns a list of PaymentMethods for a given Customer

", "operationId": "GetCustomersCustomerPaymentMethods", "parameters": [ + { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "in": "query", + "name": "allow_redisplay", + "required": false, + "schema": { + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, + "style": "form" + }, { "in": "path", "name": "customer", @@ -81036,6 +81525,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -86263,11 +86753,6 @@ "schema": { "additionalProperties": false, "properties": { - "config": { - "description": "The Forwarding Config used when making the forwarded request. The config specifes the HTTP method, merchant credentials, connection settings, and supported destination URLs.", - "maxLength": 5000, - "type": "string" - }, "expand": { "description": "Specifies which fields in the response should be expanded.", "items": { @@ -86337,7 +86822,6 @@ } }, "required": [ - "config", "payment_method", "replacements", "url" @@ -86987,38 +87471,229 @@ } ], "description": "Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document)." - }, + } + }, + "title": "session_options_param", + "type": "object" + }, + "provided_details": { + "description": "Details provided about the user being verified. These details may be shown to the user.", + "properties": { "email": { - "anyOf": [ - { - "properties": { - "require_verification": { - "description": "Request one time password verification of `provided_details.email`.", - "type": "boolean" - } - }, - "title": "email_options", - "type": "object" - }, - { - "enum": [ - "" - ], - "type": "string" - } - ], - "description": "Options that apply to the email check." + "description": "Email of user being verified", + "type": "string" }, "phone": { + "description": "Phone number of user being verified", + "type": "string" + } + }, + "title": "provided_details_param", + "type": "object" + }, + "return_url": { + "description": "The URL that the user will be redirected to upon completing the verification flow.", + "type": "string" + }, + "type": { + "description": "The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed. You must provide a `type` if not passing `verification_flow`.", + "enum": [ + "document", + "id_number" + ], + "type": "string", + "x-stripeBypassValidation": true + }, + "verification_flow": { + "description": "The ID of a Verification Flow from the Dashboard. See https://docs.stripe.com/identity/verification-flows.", + "maxLength": 5000, + "type": "string" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/identity.verification_session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, + "/v1/identity/verification_sessions/{session}": { + "get": { + "description": "

Retrieves the details of a VerificationSession that was previously created.

\n\n

When the session status is requires_input, you can use this method to retrieve a valid\nclient_secret or url to allow re-submission.

", + "operationId": "GetIdentityVerificationSessionsSession", + "parameters": [ + { + "description": "Specifies which fields in the response should be expanded.", + "explode": true, + "in": "query", + "name": "expand", + "required": false, + "schema": { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "style": "deepObject" + }, + { + "in": "path", + "name": "session", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": {}, + "schema": { + "additionalProperties": false, + "properties": {}, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/identity.verification_session" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + }, + "post": { + "description": "

Updates a VerificationSession object.

\n\n

When the session status is requires_input, you can use this method to update the\nverification check and options.

", + "operationId": "PostIdentityVerificationSessionsSession", + "parameters": [ + { + "in": "path", + "name": "session", + "required": true, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "simple" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "expand": { + "explode": true, + "style": "deepObject" + }, + "metadata": { + "explode": true, + "style": "deepObject" + }, + "options": { + "explode": true, + "style": "deepObject" + }, + "provided_details": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", + "type": "object" + }, + "options": { + "description": "A set of options for the session’s verification checks.", + "properties": { + "document": { "anyOf": [ { "properties": { - "require_verification": { - "description": "Request one time password verification of `provided_details.phone`.", + "allowed_types": { + "description": "Array of strings of allowed identity document types. If the provided identity document isn’t one of the allowed types, the verification check will fail with a document_type_not_allowed error code.", + "items": { + "enum": [ + "driving_license", + "id_card", + "passport" + ], + "type": "string" + }, + "type": "array" + }, + "require_id_number": { + "description": "Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document’s extracted name and date of birth.", + "type": "boolean" + }, + "require_live_capture": { + "description": "Disable image uploads, identity document images have to be captured using the device’s camera.", + "type": "boolean" + }, + "require_matching_selfie": { + "description": "Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user’s face. [Learn more](https://stripe.com/docs/identity/selfie).", "type": "boolean" } }, - "title": "phone_options", + "title": "document_options", "type": "object" }, { @@ -87028,282 +87703,7 @@ "type": "string" } ], - "description": "Options that apply to the phone check." - } - }, - "title": "session_options_param", - "type": "object" - }, - "provided_details": { - "description": "Details provided about the user being verified. These details may be shown to the user.", - "properties": { - "email": { - "description": "Email of user being verified", - "type": "string" - }, - "phone": { - "description": "Phone number of user being verified", - "type": "string" - } - }, - "title": "provided_details_param", - "type": "object" - }, - "return_url": { - "description": "The URL that the user will be redirected to upon completing the verification flow.", - "type": "string" - }, - "type": { - "description": "The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed.", - "enum": [ - "document", - "id_number" - ], - "type": "string", - "x-stripeBypassValidation": true - }, - "verification_flow": { - "description": "The ID of a Verification Flow from the Dashboard.", - "maxLength": 5000, - "type": "string" - } - }, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/identity.verification_session" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - } - }, - "/v1/identity/verification_sessions/{session}": { - "get": { - "description": "

Retrieves the details of a VerificationSession that was previously created.

\n\n

When the session status is requires_input, you can use this method to retrieve a valid\nclient_secret or url to allow re-submission.

", - "operationId": "GetIdentityVerificationSessionsSession", - "parameters": [ - { - "description": "Specifies which fields in the response should be expanded.", - "explode": true, - "in": "query", - "name": "expand", - "required": false, - "schema": { - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "style": "deepObject" - }, - { - "in": "path", - "name": "session", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": {}, - "schema": { - "additionalProperties": false, - "properties": {}, - "type": "object" - } - } - }, - "required": false - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/identity.verification_session" - } - } - }, - "description": "Successful response." - }, - "default": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/error" - } - } - }, - "description": "Error response." - } - } - }, - "post": { - "description": "

Updates a VerificationSession object.

\n\n

When the session status is requires_input, you can use this method to update the\nverification check and options.

", - "operationId": "PostIdentityVerificationSessionsSession", - "parameters": [ - { - "in": "path", - "name": "session", - "required": true, - "schema": { - "maxLength": 5000, - "type": "string" - }, - "style": "simple" - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "encoding": { - "expand": { - "explode": true, - "style": "deepObject" - }, - "metadata": { - "explode": true, - "style": "deepObject" - }, - "options": { - "explode": true, - "style": "deepObject" - }, - "provided_details": { - "explode": true, - "style": "deepObject" - } - }, - "schema": { - "additionalProperties": false, - "properties": { - "expand": { - "description": "Specifies which fields in the response should be expanded.", - "items": { - "maxLength": 5000, - "type": "string" - }, - "type": "array" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.", - "type": "object" - }, - "options": { - "description": "A set of options for the session’s verification checks.", - "properties": { - "document": { - "anyOf": [ - { - "properties": { - "allowed_types": { - "description": "Array of strings of allowed identity document types. If the provided identity document isn’t one of the allowed types, the verification check will fail with a document_type_not_allowed error code.", - "items": { - "enum": [ - "driving_license", - "id_card", - "passport" - ], - "type": "string" - }, - "type": "array" - }, - "require_id_number": { - "description": "Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document’s extracted name and date of birth.", - "type": "boolean" - }, - "require_live_capture": { - "description": "Disable image uploads, identity document images have to be captured using the device’s camera.", - "type": "boolean" - }, - "require_matching_selfie": { - "description": "Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user’s face. [Learn more](https://stripe.com/docs/identity/selfie).", - "type": "boolean" - } - }, - "title": "document_options", - "type": "object" - }, - { - "enum": [ - "" - ], - "type": "string" - } - ], - "description": "Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document)." - }, - "email": { - "anyOf": [ - { - "properties": { - "require_verification": { - "description": "Request one time password verification of `provided_details.email`.", - "type": "boolean" - } - }, - "title": "email_options", - "type": "object" - }, - { - "enum": [ - "" - ], - "type": "string" - } - ], - "description": "Options that apply to the email check." - }, - "phone": { - "anyOf": [ - { - "properties": { - "require_verification": { - "description": "Request one time password verification of `provided_details.phone`.", - "type": "boolean" - } - }, - "title": "phone_options", - "type": "object" - }, - { - "enum": [ - "" - ], - "type": "string" - } - ], - "description": "Options that apply to the phone check." + "description": "Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document)." } }, "title": "session_options_param", @@ -89218,6 +89618,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -89632,6 +90033,1597 @@ } } }, + "/v1/invoices/create_preview": { + "post": { + "description": "

At any time, you can preview the upcoming invoice for a customer. This will show you all the charges that are pending, including subscription renewal charges, invoice item charges, etc. It will also show you any discounts that are applicable to the invoice.

\n\n

Note that when you are viewing an upcoming invoice, you are simply viewing a preview – the invoice has not yet been created. As such, the upcoming invoice will not show up in invoice listing calls, and you cannot use the API to pay or edit the invoice. If you want to change the amount that your customer will be billed, you can add, remove, or update pending invoice items, or update the customer’s discount.

\n\n

You can preview the effects of updating a subscription, including a preview of what proration will take place. To ensure that the actual proration is calculated exactly the same as the previewed proration, you should pass the subscription_details.proration_date parameter when doing the actual subscription update. The recommended way to get only the prorations being previewed is to consider only proration line items where period[start] is equal to the subscription_details.proration_date value passed in the request.

", + "operationId": "PostInvoicesCreatePreview", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "encoding": { + "automatic_tax": { + "explode": true, + "style": "deepObject" + }, + "customer_details": { + "explode": true, + "style": "deepObject" + }, + "discounts": { + "explode": true, + "style": "deepObject" + }, + "expand": { + "explode": true, + "style": "deepObject" + }, + "invoice_items": { + "explode": true, + "style": "deepObject" + }, + "issuer": { + "explode": true, + "style": "deepObject" + }, + "on_behalf_of": { + "explode": true, + "style": "deepObject" + }, + "schedule_details": { + "explode": true, + "style": "deepObject" + }, + "subscription_details": { + "explode": true, + "style": "deepObject" + } + }, + "schema": { + "additionalProperties": false, + "properties": { + "automatic_tax": { + "description": "Settings for automatic tax lookup for this invoice preview.", + "properties": { + "enabled": { + "description": "Whether Stripe automatically computes tax on this invoice. Note that incompatible invoice items (invoice items with manually specified [tax rates](https://stripe.com/docs/api/tax_rates), negative amounts, or `tax_behavior=unspecified`) cannot be added to automatic tax invoices.", + "type": "boolean" + }, + "liability": { + "description": "The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.", + "properties": { + "account": { + "description": "The connected account being referenced when `type` is `account`.", + "type": "string" + }, + "type": { + "description": "Type of the account referenced in the request.", + "enum": [ + "account", + "self" + ], + "type": "string" + } + }, + "required": [ + "type" + ], + "title": "param", + "type": "object" + } + }, + "required": [ + "enabled" + ], + "title": "automatic_tax_param", + "type": "object" + }, + "coupon": { + "description": "The ID of the coupon to apply to this phase of the subscription schedule. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "maxLength": 5000, + "type": "string" + }, + "currency": { + "description": "The currency to preview this invoice in. Defaults to that of `customer` if not specified.", + "type": "string" + }, + "customer": { + "description": "The identifier of the customer whose upcoming invoice you'd like to retrieve. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.", + "maxLength": 5000, + "type": "string" + }, + "customer_details": { + "description": "Details about the customer you want to invoice or overrides for an existing customer. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.", + "properties": { + "address": { + "anyOf": [ + { + "properties": { + "city": { + "description": "City, district, suburb, town, or village.", + "maxLength": 5000, + "type": "string" + }, + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "type": "string" + }, + "line1": { + "description": "Address line 1 (e.g., street, PO Box, or company name).", + "maxLength": 5000, + "type": "string" + }, + "line2": { + "description": "Address line 2 (e.g., apartment, suite, unit, or building).", + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "description": "ZIP or postal code.", + "maxLength": 5000, + "type": "string" + }, + "state": { + "description": "State, county, province, or region.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The customer's address." + }, + "shipping": { + "anyOf": [ + { + "properties": { + "address": { + "description": "Customer shipping address.", + "properties": { + "city": { + "description": "City, district, suburb, town, or village.", + "maxLength": 5000, + "type": "string" + }, + "country": { + "description": "Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).", + "maxLength": 5000, + "type": "string" + }, + "line1": { + "description": "Address line 1 (e.g., street, PO Box, or company name).", + "maxLength": 5000, + "type": "string" + }, + "line2": { + "description": "Address line 2 (e.g., apartment, suite, unit, or building).", + "maxLength": 5000, + "type": "string" + }, + "postal_code": { + "description": "ZIP or postal code.", + "maxLength": 5000, + "type": "string" + }, + "state": { + "description": "State, county, province, or region.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "optional_fields_address", + "type": "object" + }, + "name": { + "description": "Customer name.", + "maxLength": 5000, + "type": "string" + }, + "phone": { + "description": "Customer phone (including extension).", + "maxLength": 5000, + "type": "string" + } + }, + "required": [ + "address", + "name" + ], + "title": "customer_shipping", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The customer's shipping information. Appears on invoices emailed to this customer." + }, + "tax": { + "description": "Tax details about the customer.", + "properties": { + "ip_address": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A recent IP address of the customer used for tax reporting and tax location inference. Stripe recommends updating the IP address when a new PaymentMethod is attached or the address field on the customer is updated. We recommend against updating this field more frequently since it could result in unexpected tax location/reporting outcomes." + } + }, + "title": "tax_param", + "type": "object" + }, + "tax_exempt": { + "description": "The customer's tax exemption. One of `none`, `exempt`, or `reverse`.", + "enum": [ + "", + "exempt", + "none", + "reverse" + ], + "type": "string" + }, + "tax_ids": { + "description": "The customer's tax IDs.", + "items": { + "properties": { + "type": { + "description": "Type of the tax ID, one of `ad_nrt`, `ae_trn`, `ar_cuit`, `au_abn`, `au_arn`, `bg_uic`, `bh_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `ch_vat`, `cl_tin`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `hk_br`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kr_brn`, `kz_bin`, `li_uid`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sv_nit`, `th_vat`, `tr_tin`, `tw_vat`, `ua_vat`, `us_ein`, `uy_ruc`, `ve_rif`, `vn_tin`, or `za_vat`", + "enum": [ + "ad_nrt", + "ae_trn", + "ar_cuit", + "au_abn", + "au_arn", + "bg_uic", + "bh_vat", + "bo_tin", + "br_cnpj", + "br_cpf", + "ca_bn", + "ca_gst_hst", + "ca_pst_bc", + "ca_pst_mb", + "ca_pst_sk", + "ca_qst", + "ch_vat", + "cl_tin", + "cn_tin", + "co_nit", + "cr_tin", + "do_rcn", + "ec_ruc", + "eg_tin", + "es_cif", + "eu_oss_vat", + "eu_vat", + "gb_vat", + "ge_vat", + "hk_br", + "hu_tin", + "id_npwp", + "il_vat", + "in_gst", + "is_vat", + "jp_cn", + "jp_rn", + "jp_trn", + "ke_pin", + "kr_brn", + "kz_bin", + "li_uid", + "mx_rfc", + "my_frp", + "my_itn", + "my_sst", + "ng_tin", + "no_vat", + "no_voec", + "nz_gst", + "om_vat", + "pe_ruc", + "ph_tin", + "ro_tin", + "rs_pib", + "ru_inn", + "ru_kpp", + "sa_vat", + "sg_gst", + "sg_uen", + "si_tin", + "sv_nit", + "th_vat", + "tr_tin", + "tw_vat", + "ua_vat", + "us_ein", + "uy_ruc", + "ve_rif", + "vn_tin", + "za_vat" + ], + "maxLength": 5000, + "type": "string", + "x-stripeBypassValidation": true + }, + "value": { + "description": "Value of the tax ID.", + "type": "string" + } + }, + "required": [ + "type", + "value" + ], + "title": "data_params", + "type": "object" + }, + "type": "array" + } + }, + "title": "customer_details_param", + "type": "object" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the subscription or customer. This works for both coupons directly applied to an invoice and coupons applied to a subscription. Pass an empty string to avoid inheriting any discounts." + }, + "expand": { + "description": "Specifies which fields in the response should be expanded.", + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + "invoice_items": { + "description": "List of invoice items to add or update in the upcoming invoice preview.", + "items": { + "properties": { + "amount": { + "description": "The integer amount in cents (or local equivalent) of previewed invoice item.", + "type": "integer" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). Only applicable to new invoice items.", + "type": "string" + }, + "description": { + "description": "An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.", + "maxLength": 5000, + "type": "string" + }, + "discountable": { + "description": "Explicitly controls whether discounts apply to this invoice item. Defaults to true, except for negative invoice items.", + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the invoice item in the preview." + }, + "invoiceitem": { + "description": "The ID of the invoice item to update in preview. If not specified, a new invoice item will be added to the preview of the upcoming invoice.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "period": { + "description": "The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.", + "properties": { + "end": { + "description": "The end of the period, which must be greater than or equal to the start. This value is inclusive.", + "format": "unix-time", + "type": "integer" + }, + "start": { + "description": "The start of the period. This value is inclusive.", + "format": "unix-time", + "type": "integer" + } + }, + "required": [ + "end", + "start" + ], + "title": "period", + "type": "object" + }, + "price": { + "description": "The ID of the price object.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "product": { + "description": "The ID of the product that this price will belong to.", + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product" + ], + "title": "one_time_price_data", + "type": "object" + }, + "quantity": { + "description": "Non-negative integer. The quantity of units for the invoice item.", + "type": "integer" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "tax_code": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A [tax code](https://stripe.com/docs/tax/tax-categories) ID." + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The tax rates that apply to the item. When set, any `default_tax_rates` do not apply to this item." + }, + "unit_amount": { + "description": "The integer unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This unit_amount will be multiplied by the quantity to get the full amount. If you want to apply a credit to the customer's account, pass a negative unit_amount.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "title": "invoice_item_preview_params", + "type": "object" + }, + "type": "array" + }, + "issuer": { + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", + "properties": { + "account": { + "description": "The connected account being referenced when `type` is `account`.", + "type": "string" + }, + "type": { + "description": "Type of the account referenced in the request.", + "enum": [ + "account", + "self" + ], + "type": "string" + } + }, + "required": [ + "type" + ], + "title": "param", + "type": "object" + }, + "on_behalf_of": { + "anyOf": [ + { + "type": "string" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details." + }, + "schedule": { + "description": "The identifier of the schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields.", + "maxLength": 5000, + "type": "string" + }, + "schedule_details": { + "description": "The schedule creation or modification params to apply as a preview. Cannot be used with `subscription` or `subscription_` prefixed fields.", + "properties": { + "end_behavior": { + "description": "Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.", + "enum": [ + "cancel", + "release" + ], + "type": "string" + }, + "phases": { + "description": "List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.", + "items": { + "properties": { + "add_invoice_items": { + "description": "A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.", + "items": { + "properties": { + "discounts": { + "description": "The coupons to redeem into discounts for the item.", + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "description": "The ID of the price object.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "product": { + "description": "The ID of the product that this price will belong to.", + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product" + ], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "description": "Quantity for this item. Defaults to 1.", + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item." + } + }, + "title": "add_invoice_item_entry", + "type": "object", + "x-stripeParam": { + "class_name": "AddInvoiceItem" + } + }, + "type": "array" + }, + "application_fee_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).", + "type": "number" + }, + "automatic_tax": { + "description": "Automatic tax settings for this phase.", + "properties": { + "enabled": { + "description": "Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.", + "type": "boolean" + }, + "liability": { + "description": "The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.", + "properties": { + "account": { + "description": "The connected account being referenced when `type` is `account`.", + "type": "string" + }, + "type": { + "description": "Type of the account referenced in the request.", + "enum": [ + "account", + "self" + ], + "type": "string" + } + }, + "required": [ + "type" + ], + "title": "param", + "type": "object" + } + }, + "required": [ + "enabled" + ], + "title": "automatic_tax_config", + "type": "object" + }, + "billing_cycle_anchor": { + "description": "Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", + "enum": [ + "automatic", + "phase_start" + ], + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "description": "Monetary threshold that triggers the subscription to advance to a new billing period", + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "description": "Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.", + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds." + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.", + "enum": [ + "charge_automatically", + "send_invoice" + ], + "type": "string" + }, + "coupon": { + "description": "The ID of the coupon to apply to this phase of the subscription schedule. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "maxLength": 5000, + "type": "string" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "default_payment_method": { + "description": "ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.", + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase." + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts." + }, + "end_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + } + ], + "description": "The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set." + }, + "invoice_settings": { + "description": "All invoices will be billed using the specified settings.", + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule." + }, + "days_until_due": { + "description": "Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.", + "type": "integer" + }, + "issuer": { + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", + "properties": { + "account": { + "description": "The connected account being referenced when `type` is `account`.", + "type": "string" + }, + "type": { + "description": "Type of the account referenced in the request.", + "enum": [ + "account", + "self" + ], + "type": "string" + } + }, + "required": [ + "type" + ], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings", + "type": "object" + }, + "items": { + "description": "List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.", + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "description": "Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))", + "type": "integer" + } + }, + "required": [ + "usage_gte" + ], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the subscription item." + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.", + "type": "object" + }, + "plan": { + "description": "The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.", + "maxLength": 5000, + "type": "string" + }, + "price": { + "description": "The ID of the price object.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "product": { + "description": "The ID of the product that this price will belong to.", + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "description": "The recurring components of a price such as `interval` and `interval_count`.", + "properties": { + "interval": { + "description": "Specifies billing frequency. Either `day`, `week`, `month` or `year`.", + "enum": [ + "day", + "month", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).", + "type": "integer" + } + }, + "required": [ + "interval" + ], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product", + "recurring" + ], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "description": "Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.", + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates." + } + }, + "title": "configuration_item_params", + "type": "object" + }, + "type": "array" + }, + "iterations": { + "description": "Integer representing the multiplier applied to the price interval. For example, `iterations=2` applied to a price with `interval=month` and `interval_count=3` results in a phase of duration `2 * 3 months = 6 months`. If set, `end_date` must not be set.", + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.", + "type": "object" + }, + "on_behalf_of": { + "description": "The account on behalf of which to charge, for each of the associated subscription's invoices.", + "type": "string" + }, + "proration_behavior": { + "description": "Whether the subscription schedule will create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase. The default value is `create_prorations`. This setting controls prorations when a phase is started asynchronously and it is persisted as a field on the phase. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration of the current phase.", + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + }, + "start_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + } + ], + "description": "The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase." + }, + "transfer_data": { + "description": "The data with which to automatically create a Transfer for each of the associated subscription's invoices.", + "properties": { + "amount_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.", + "type": "number" + }, + "destination": { + "description": "ID of an existing, connected Stripe account.", + "type": "string" + } + }, + "required": [ + "destination" + ], + "title": "transfer_data_specs", + "type": "object" + }, + "trial": { + "description": "If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.", + "type": "boolean" + }, + "trial_end": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + } + ], + "description": "Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`" + } + }, + "required": [ + "items" + ], + "title": "phase_configuration_params", + "type": "object" + }, + "type": "array" + }, + "proration_behavior": { + "description": "In cases where the `schedule_details` params update the currently active phase, specifies if and how to prorate at the time of the request.", + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + } + }, + "title": "schedule_details_params", + "type": "object" + }, + "subscription": { + "description": "The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.", + "maxLength": 5000, + "type": "string" + }, + "subscription_details": { + "description": "The subscription creation or modification params to apply as a preview. Cannot be used with `schedule` or `schedule_details` fields.", + "properties": { + "billing_cycle_anchor": { + "anyOf": [ + { + "enum": [ + "now", + "unchanged" + ], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ], + "description": "For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`." + }, + "cancel_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period." + }, + "cancel_at_period_end": { + "description": "Boolean indicating whether this subscription should cancel at the end of the current period.", + "type": "boolean" + }, + "cancel_now": { + "description": "This simulates the subscription being canceled or expired immediately.", + "type": "boolean" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set." + }, + "items": { + "description": "A list of up to 20 subscription items, each with an attached price.", + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "description": "Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))", + "type": "integer" + } + }, + "required": [ + "usage_gte" + ], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds." + }, + "clear_usage": { + "description": "Delete all usage for a given subscription item. Allowed only when `deleted` is set to `true` and the current plan's `usage_type` is `metered`.", + "type": "boolean" + }, + "deleted": { + "description": "A flag that, if set to `true`, will delete the specified item.", + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the subscription item." + }, + "id": { + "description": "Subscription item to update.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "plan": { + "description": "Plan ID for this item, as a string.", + "maxLength": 5000, + "type": "string" + }, + "price": { + "description": "The ID of the price object. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "product": { + "description": "The ID of the product that this price will belong to.", + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "description": "The recurring components of a price such as `interval` and `interval_count`.", + "properties": { + "interval": { + "description": "Specifies billing frequency. Either `day`, `week`, `month` or `year`.", + "enum": [ + "day", + "month", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).", + "type": "integer" + } + }, + "required": [ + "interval" + ], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product", + "recurring" + ], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "description": "Quantity for this item.", + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates." + } + }, + "title": "subscription_item_update_params", + "type": "object" + }, + "type": "array" + }, + "proration_behavior": { + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.", + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + }, + "proration_date": { + "description": "If previewing an update to a subscription, and doing proration, `subscription_details.proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_details.items`, or `subscription_details.trial_end` are required. Also, `subscription_details.proration_behavior` cannot be set to 'none'.", + "format": "unix-time", + "type": "integer" + }, + "resume_at": { + "description": "For paused subscriptions, setting `subscription_details.resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed.", + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + }, + "start_date": { + "description": "Date a subscription is intended to start (can be future or past).", + "format": "unix-time", + "type": "integer" + }, + "trial_end": { + "anyOf": [ + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ], + "description": "If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_details.items` or `subscription` is required." + } + }, + "title": "subscription_details_params", + "type": "object" + } + }, + "type": "object" + } + } + }, + "required": false + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/invoice" + } + } + }, + "description": "Successful response." + }, + "default": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error" + } + } + }, + "description": "Error response." + } + } + } + }, "/v1/invoices/search": { "get": { "description": "

Search for invoices you’ve previously created using Stripe’s Search Query Language.\nDon’t use search in read-after-write flows where strict consistency is necessary. Under normal operating\nconditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up\nto an hour behind during outages. Search functionality is not available to merchants in India.

", @@ -90429,6 +92421,632 @@ }, "style": "form" }, + { + "description": "The schedule creation or modification params to apply as a preview. Cannot be used with `subscription` or `subscription_` prefixed fields.", + "explode": true, + "in": "query", + "name": "schedule_details", + "required": false, + "schema": { + "properties": { + "end_behavior": { + "description": "Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.", + "enum": [ + "cancel", + "release" + ], + "type": "string" + }, + "phases": { + "description": "List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.", + "items": { + "properties": { + "add_invoice_items": { + "description": "A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.", + "items": { + "properties": { + "discounts": { + "description": "The coupons to redeem into discounts for the item.", + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "description": "The ID of the price object.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "product": { + "description": "The ID of the product that this price will belong to.", + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product" + ], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "description": "Quantity for this item. Defaults to 1.", + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item." + } + }, + "title": "add_invoice_item_entry", + "type": "object", + "x-stripeParam": { + "class_name": "AddInvoiceItem" + } + }, + "type": "array" + }, + "application_fee_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).", + "type": "number" + }, + "automatic_tax": { + "description": "Automatic tax settings for this phase.", + "properties": { + "enabled": { + "description": "Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.", + "type": "boolean" + }, + "liability": { + "description": "The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.", + "properties": { + "account": { + "description": "The connected account being referenced when `type` is `account`.", + "type": "string" + }, + "type": { + "description": "Type of the account referenced in the request.", + "enum": [ + "account", + "self" + ], + "type": "string" + } + }, + "required": [ + "type" + ], + "title": "param", + "type": "object" + } + }, + "required": [ + "enabled" + ], + "title": "automatic_tax_config", + "type": "object" + }, + "billing_cycle_anchor": { + "description": "Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", + "enum": [ + "automatic", + "phase_start" + ], + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "description": "Monetary threshold that triggers the subscription to advance to a new billing period", + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "description": "Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.", + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds." + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.", + "enum": [ + "charge_automatically", + "send_invoice" + ], + "type": "string" + }, + "coupon": { + "description": "The ID of the coupon to apply to this phase of the subscription schedule. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "maxLength": 5000, + "type": "string" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "default_payment_method": { + "description": "ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.", + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase." + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts." + }, + "end_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + } + ], + "description": "The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set." + }, + "invoice_settings": { + "description": "All invoices will be billed using the specified settings.", + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule." + }, + "days_until_due": { + "description": "Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.", + "type": "integer" + }, + "issuer": { + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", + "properties": { + "account": { + "description": "The connected account being referenced when `type` is `account`.", + "type": "string" + }, + "type": { + "description": "Type of the account referenced in the request.", + "enum": [ + "account", + "self" + ], + "type": "string" + } + }, + "required": [ + "type" + ], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings", + "type": "object" + }, + "items": { + "description": "List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.", + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "description": "Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))", + "type": "integer" + } + }, + "required": [ + "usage_gte" + ], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the subscription item." + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.", + "type": "object" + }, + "plan": { + "description": "The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.", + "maxLength": 5000, + "type": "string" + }, + "price": { + "description": "The ID of the price object.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "product": { + "description": "The ID of the product that this price will belong to.", + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "description": "The recurring components of a price such as `interval` and `interval_count`.", + "properties": { + "interval": { + "description": "Specifies billing frequency. Either `day`, `week`, `month` or `year`.", + "enum": [ + "day", + "month", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).", + "type": "integer" + } + }, + "required": [ + "interval" + ], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product", + "recurring" + ], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "description": "Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.", + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates." + } + }, + "title": "configuration_item_params", + "type": "object" + }, + "type": "array" + }, + "iterations": { + "description": "Integer representing the multiplier applied to the price interval. For example, `iterations=2` applied to a price with `interval=month` and `interval_count=3` results in a phase of duration `2 * 3 months = 6 months`. If set, `end_date` must not be set.", + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.", + "type": "object" + }, + "on_behalf_of": { + "description": "The account on behalf of which to charge, for each of the associated subscription's invoices.", + "type": "string" + }, + "proration_behavior": { + "description": "Whether the subscription schedule will create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase. The default value is `create_prorations`. This setting controls prorations when a phase is started asynchronously and it is persisted as a field on the phase. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration of the current phase.", + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + }, + "start_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + } + ], + "description": "The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase." + }, + "transfer_data": { + "description": "The data with which to automatically create a Transfer for each of the associated subscription's invoices.", + "properties": { + "amount_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.", + "type": "number" + }, + "destination": { + "description": "ID of an existing, connected Stripe account.", + "type": "string" + } + }, + "required": [ + "destination" + ], + "title": "transfer_data_specs", + "type": "object" + }, + "trial": { + "description": "If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.", + "type": "boolean" + }, + "trial_end": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + } + ], + "description": "Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`" + } + }, + "required": [ + "items" + ], + "title": "phase_configuration_params", + "type": "object" + }, + "type": "array" + }, + "proration_behavior": { + "description": "In cases where the `schedule_details` params update the currently active phase, specifies if and how to prorate at the time of the request.", + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + } + }, + "title": "schedule_details_params", + "type": "object" + }, + "style": "deepObject" + }, { "description": "The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.", "in": "query", @@ -90441,7 +93059,7 @@ "style": "form" }, { - "description": "For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`.", + "description": "For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`. This field has been deprecated and will be removed in a future API version. Use `subscription_details.billing_cycle_anchor` instead.", "explode": true, "in": "query", "name": "subscription_billing_cycle_anchor", @@ -90465,7 +93083,7 @@ "style": "deepObject" }, { - "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.", + "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_at` instead.", "explode": true, "in": "query", "name": "subscription_cancel_at", @@ -90487,7 +93105,7 @@ "style": "deepObject" }, { - "description": "Boolean indicating whether this subscription should cancel at the end of the current period.", + "description": "Boolean indicating whether this subscription should cancel at the end of the current period. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_at_period_end` instead.", "in": "query", "name": "subscription_cancel_at_period_end", "required": false, @@ -90497,7 +93115,7 @@ "style": "form" }, { - "description": "This simulates the subscription being canceled or expired immediately.", + "description": "This simulates the subscription being canceled or expired immediately. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_now` instead.", "in": "query", "name": "subscription_cancel_now", "required": false, @@ -90507,7 +93125,7 @@ "style": "form" }, { - "description": "If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set.", + "description": "If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set. This field has been deprecated and will be removed in a future API version. Use `subscription_details.default_tax_rates` instead.", "explode": true, "in": "query", "name": "subscription_default_tax_rates", @@ -90532,7 +93150,316 @@ "style": "deepObject" }, { - "description": "A list of up to 20 subscription items, each with an attached price.", + "description": "The subscription creation or modification params to apply as a preview. Cannot be used with `schedule` or `schedule_details` fields.", + "explode": true, + "in": "query", + "name": "subscription_details", + "required": false, + "schema": { + "properties": { + "billing_cycle_anchor": { + "anyOf": [ + { + "enum": [ + "now", + "unchanged" + ], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ], + "description": "For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`." + }, + "cancel_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period." + }, + "cancel_at_period_end": { + "description": "Boolean indicating whether this subscription should cancel at the end of the current period.", + "type": "boolean" + }, + "cancel_now": { + "description": "This simulates the subscription being canceled or expired immediately.", + "type": "boolean" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set." + }, + "items": { + "description": "A list of up to 20 subscription items, each with an attached price.", + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "description": "Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))", + "type": "integer" + } + }, + "required": [ + "usage_gte" + ], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds." + }, + "clear_usage": { + "description": "Delete all usage for a given subscription item. Allowed only when `deleted` is set to `true` and the current plan's `usage_type` is `metered`.", + "type": "boolean" + }, + "deleted": { + "description": "A flag that, if set to `true`, will delete the specified item.", + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the subscription item." + }, + "id": { + "description": "Subscription item to update.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "plan": { + "description": "Plan ID for this item, as a string.", + "maxLength": 5000, + "type": "string" + }, + "price": { + "description": "The ID of the price object. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "product": { + "description": "The ID of the product that this price will belong to.", + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "description": "The recurring components of a price such as `interval` and `interval_count`.", + "properties": { + "interval": { + "description": "Specifies billing frequency. Either `day`, `week`, `month` or `year`.", + "enum": [ + "day", + "month", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).", + "type": "integer" + } + }, + "required": [ + "interval" + ], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product", + "recurring" + ], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "description": "Quantity for this item.", + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates." + } + }, + "title": "subscription_item_update_params", + "type": "object" + }, + "type": "array" + }, + "proration_behavior": { + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.", + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + }, + "proration_date": { + "description": "If previewing an update to a subscription, and doing proration, `subscription_details.proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_details.items`, or `subscription_details.trial_end` are required. Also, `subscription_details.proration_behavior` cannot be set to 'none'.", + "format": "unix-time", + "type": "integer" + }, + "resume_at": { + "description": "For paused subscriptions, setting `subscription_details.resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed.", + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + }, + "start_date": { + "description": "Date a subscription is intended to start (can be future or past).", + "format": "unix-time", + "type": "integer" + }, + "trial_end": { + "anyOf": [ + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ], + "description": "If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_details.items` or `subscription` is required." + } + }, + "title": "subscription_details_params", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "A list of up to 20 subscription items, each with an attached price. This field has been deprecated and will be removed in a future API version. Use `subscription_details.items` instead.", "explode": true, "in": "query", "name": "subscription_items", @@ -90733,7 +93660,7 @@ "style": "deepObject" }, { - "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.", + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`. This field has been deprecated and will be removed in a future API version. Use `subscription_details.proration_behavior` instead.", "in": "query", "name": "subscription_proration_behavior", "required": false, @@ -90748,7 +93675,7 @@ "style": "form" }, { - "description": "If previewing an update to a subscription, and doing proration, `subscription_proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_items`, or `subscription_trial_end` are required. Also, `subscription_proration_behavior` cannot be set to 'none'.", + "description": "If previewing an update to a subscription, and doing proration, `subscription_proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_items`, or `subscription_trial_end` are required. Also, `subscription_proration_behavior` cannot be set to 'none'. This field has been deprecated and will be removed in a future API version. Use `subscription_details.proration_date` instead.", "in": "query", "name": "subscription_proration_date", "required": false, @@ -90759,7 +93686,7 @@ "style": "form" }, { - "description": "For paused subscriptions, setting `subscription_resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed.", + "description": "For paused subscriptions, setting `subscription_resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed. This field has been deprecated and will be removed in a future API version. Use `subscription_details.resume_at` instead.", "in": "query", "name": "subscription_resume_at", "required": false, @@ -90773,7 +93700,7 @@ "style": "form" }, { - "description": "Date a subscription is intended to start (can be future or past).", + "description": "Date a subscription is intended to start (can be future or past). This field has been deprecated and will be removed in a future API version. Use `subscription_details.start_date` instead.", "in": "query", "name": "subscription_start_date", "required": false, @@ -90784,7 +93711,7 @@ "style": "form" }, { - "description": "If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_items` or `subscription` is required.", + "description": "If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_items` or `subscription` is required. This field has been deprecated and will be removed in a future API version. Use `subscription_details.trial_end` instead.", "explode": true, "in": "query", "name": "subscription_trial_end", @@ -91539,6 +94466,632 @@ }, "style": "form" }, + { + "description": "The schedule creation or modification params to apply as a preview. Cannot be used with `subscription` or `subscription_` prefixed fields.", + "explode": true, + "in": "query", + "name": "schedule_details", + "required": false, + "schema": { + "properties": { + "end_behavior": { + "description": "Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.", + "enum": [ + "cancel", + "release" + ], + "type": "string" + }, + "phases": { + "description": "List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.", + "items": { + "properties": { + "add_invoice_items": { + "description": "A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.", + "items": { + "properties": { + "discounts": { + "description": "The coupons to redeem into discounts for the item.", + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + "price": { + "description": "The ID of the price object.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "product": { + "description": "The ID of the product that this price will belong to.", + "maxLength": 5000, + "type": "string" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product" + ], + "title": "one_time_price_data_with_negative_amounts", + "type": "object" + }, + "quantity": { + "description": "Quantity for this item. Defaults to 1.", + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item." + } + }, + "title": "add_invoice_item_entry", + "type": "object", + "x-stripeParam": { + "class_name": "AddInvoiceItem" + } + }, + "type": "array" + }, + "application_fee_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).", + "type": "number" + }, + "automatic_tax": { + "description": "Automatic tax settings for this phase.", + "properties": { + "enabled": { + "description": "Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.", + "type": "boolean" + }, + "liability": { + "description": "The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.", + "properties": { + "account": { + "description": "The connected account being referenced when `type` is `account`.", + "type": "string" + }, + "type": { + "description": "Type of the account referenced in the request.", + "enum": [ + "account", + "self" + ], + "type": "string" + } + }, + "required": [ + "type" + ], + "title": "param", + "type": "object" + } + }, + "required": [ + "enabled" + ], + "title": "automatic_tax_config", + "type": "object" + }, + "billing_cycle_anchor": { + "description": "Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).", + "enum": [ + "automatic", + "phase_start" + ], + "type": "string" + }, + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "amount_gte": { + "description": "Monetary threshold that triggers the subscription to advance to a new billing period", + "type": "integer" + }, + "reset_billing_cycle_anchor": { + "description": "Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.", + "type": "boolean" + } + }, + "title": "billing_thresholds_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds." + }, + "collection_method": { + "description": "Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.", + "enum": [ + "charge_automatically", + "send_invoice" + ], + "type": "string" + }, + "coupon": { + "description": "The ID of the coupon to apply to this phase of the subscription schedule. This field has been deprecated and will be removed in a future API version. Use `discounts` instead.", + "maxLength": 5000, + "type": "string" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "default_payment_method": { + "description": "ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.", + "maxLength": 5000, + "type": "string" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase." + }, + "description": { + "anyOf": [ + { + "maxLength": 500, + "type": "string" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts." + }, + "end_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + } + ], + "description": "The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set." + }, + "invoice_settings": { + "description": "All invoices will be billed using the specified settings.", + "properties": { + "account_tax_ids": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule." + }, + "days_until_due": { + "description": "Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.", + "type": "integer" + }, + "issuer": { + "description": "The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.", + "properties": { + "account": { + "description": "The connected account being referenced when `type` is `account`.", + "type": "string" + }, + "type": { + "description": "Type of the account referenced in the request.", + "enum": [ + "account", + "self" + ], + "type": "string" + } + }, + "required": [ + "type" + ], + "title": "param", + "type": "object" + } + }, + "title": "invoice_settings", + "type": "object" + }, + "items": { + "description": "List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.", + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "description": "Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))", + "type": "integer" + } + }, + "required": [ + "usage_gte" + ], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds." + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the subscription item." + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.", + "type": "object" + }, + "plan": { + "description": "The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.", + "maxLength": 5000, + "type": "string" + }, + "price": { + "description": "The ID of the price object.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "product": { + "description": "The ID of the product that this price will belong to.", + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "description": "The recurring components of a price such as `interval` and `interval_count`.", + "properties": { + "interval": { + "description": "Specifies billing frequency. Either `day`, `week`, `month` or `year`.", + "enum": [ + "day", + "month", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).", + "type": "integer" + } + }, + "required": [ + "interval" + ], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product", + "recurring" + ], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "description": "Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.", + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates." + } + }, + "title": "configuration_item_params", + "type": "object" + }, + "type": "array" + }, + "iterations": { + "description": "Integer representing the multiplier applied to the price interval. For example, `iterations=2` applied to a price with `interval=month` and `interval_count=3` results in a phase of duration `2 * 3 months = 6 months`. If set, `end_date` must not be set.", + "type": "integer" + }, + "metadata": { + "additionalProperties": { + "type": "string" + }, + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.", + "type": "object" + }, + "on_behalf_of": { + "description": "The account on behalf of which to charge, for each of the associated subscription's invoices.", + "type": "string" + }, + "proration_behavior": { + "description": "Whether the subscription schedule will create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase. The default value is `create_prorations`. This setting controls prorations when a phase is started asynchronously and it is persisted as a field on the phase. It's different from the request-level [proration_behavior](https://stripe.com/docs/api/subscription_schedules/update#update_subscription_schedule-proration_behavior) parameter which controls what happens if the update request affects the billing configuration of the current phase.", + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + }, + "start_date": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + } + ], + "description": "The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase." + }, + "transfer_data": { + "description": "The data with which to automatically create a Transfer for each of the associated subscription's invoices.", + "properties": { + "amount_percent": { + "description": "A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.", + "type": "number" + }, + "destination": { + "description": "ID of an existing, connected Stripe account.", + "type": "string" + } + }, + "required": [ + "destination" + ], + "title": "transfer_data_specs", + "type": "object" + }, + "trial": { + "description": "If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.", + "type": "boolean" + }, + "trial_end": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + } + ], + "description": "Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`" + } + }, + "required": [ + "items" + ], + "title": "phase_configuration_params", + "type": "object" + }, + "type": "array" + }, + "proration_behavior": { + "description": "In cases where the `schedule_details` params update the currently active phase, specifies if and how to prorate at the time of the request.", + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + } + }, + "title": "schedule_details_params", + "type": "object" + }, + "style": "deepObject" + }, { "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", "in": "query", @@ -91562,7 +95115,7 @@ "style": "form" }, { - "description": "For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`.", + "description": "For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`. This field has been deprecated and will be removed in a future API version. Use `subscription_details.billing_cycle_anchor` instead.", "explode": true, "in": "query", "name": "subscription_billing_cycle_anchor", @@ -91586,7 +95139,7 @@ "style": "deepObject" }, { - "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.", + "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_at` instead.", "explode": true, "in": "query", "name": "subscription_cancel_at", @@ -91608,7 +95161,7 @@ "style": "deepObject" }, { - "description": "Boolean indicating whether this subscription should cancel at the end of the current period.", + "description": "Boolean indicating whether this subscription should cancel at the end of the current period. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_at_period_end` instead.", "in": "query", "name": "subscription_cancel_at_period_end", "required": false, @@ -91618,7 +95171,7 @@ "style": "form" }, { - "description": "This simulates the subscription being canceled or expired immediately.", + "description": "This simulates the subscription being canceled or expired immediately. This field has been deprecated and will be removed in a future API version. Use `subscription_details.cancel_now` instead.", "in": "query", "name": "subscription_cancel_now", "required": false, @@ -91628,7 +95181,7 @@ "style": "form" }, { - "description": "If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set.", + "description": "If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set. This field has been deprecated and will be removed in a future API version. Use `subscription_details.default_tax_rates` instead.", "explode": true, "in": "query", "name": "subscription_default_tax_rates", @@ -91653,7 +95206,316 @@ "style": "deepObject" }, { - "description": "A list of up to 20 subscription items, each with an attached price.", + "description": "The subscription creation or modification params to apply as a preview. Cannot be used with `schedule` or `schedule_details` fields.", + "explode": true, + "in": "query", + "name": "subscription_details", + "required": false, + "schema": { + "properties": { + "billing_cycle_anchor": { + "anyOf": [ + { + "enum": [ + "now", + "unchanged" + ], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ], + "description": "For new subscriptions, a future timestamp to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). This is used to determine the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. For existing subscriptions, the value can only be set to `now` or `unchanged`." + }, + "cancel_at": { + "anyOf": [ + { + "format": "unix-time", + "type": "integer" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period." + }, + "cancel_at_period_end": { + "description": "Boolean indicating whether this subscription should cancel at the end of the current period.", + "type": "boolean" + }, + "cancel_now": { + "description": "This simulates the subscription being canceled or expired immediately.", + "type": "boolean" + }, + "default_tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "If provided, the invoice returned will preview updating or creating a subscription with these default tax rates. The default tax rates will apply to any line item that does not have `tax_rates` set." + }, + "items": { + "description": "A list of up to 20 subscription items, each with an attached price.", + "items": { + "properties": { + "billing_thresholds": { + "anyOf": [ + { + "properties": { + "usage_gte": { + "description": "Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))", + "type": "integer" + } + }, + "required": [ + "usage_gte" + ], + "title": "item_billing_thresholds_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds." + }, + "clear_usage": { + "description": "Delete all usage for a given subscription item. Allowed only when `deleted` is set to `true` and the current plan's `usage_type` is `metered`.", + "type": "boolean" + }, + "deleted": { + "description": "A flag that, if set to `true`, will delete the specified item.", + "type": "boolean" + }, + "discounts": { + "anyOf": [ + { + "items": { + "properties": { + "coupon": { + "description": "ID of the coupon to create a new discount for.", + "maxLength": 5000, + "type": "string" + }, + "discount": { + "description": "ID of an existing discount on the object (or one of its ancestors) to reuse.", + "maxLength": 5000, + "type": "string" + }, + "promotion_code": { + "description": "ID of the promotion code to create a new discount for.", + "maxLength": 5000, + "type": "string" + } + }, + "title": "discounts_data_param", + "type": "object" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "The coupons to redeem into discounts for the subscription item." + }, + "id": { + "description": "Subscription item to update.", + "maxLength": 5000, + "type": "string" + }, + "metadata": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + }, + "plan": { + "description": "Plan ID for this item, as a string.", + "maxLength": 5000, + "type": "string" + }, + "price": { + "description": "The ID of the price object. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.", + "maxLength": 5000, + "type": "string" + }, + "price_data": { + "description": "Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.", + "properties": { + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).", + "type": "string" + }, + "product": { + "description": "The ID of the product that this price will belong to.", + "maxLength": 5000, + "type": "string" + }, + "recurring": { + "description": "The recurring components of a price such as `interval` and `interval_count`.", + "properties": { + "interval": { + "description": "Specifies billing frequency. Either `day`, `week`, `month` or `year`.", + "enum": [ + "day", + "month", + "week", + "year" + ], + "type": "string" + }, + "interval_count": { + "description": "The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).", + "type": "integer" + } + }, + "required": [ + "interval" + ], + "title": "recurring_adhoc", + "type": "object" + }, + "tax_behavior": { + "description": "Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.", + "enum": [ + "exclusive", + "inclusive", + "unspecified" + ], + "type": "string" + }, + "unit_amount": { + "description": "A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.", + "type": "integer" + }, + "unit_amount_decimal": { + "description": "Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.", + "format": "decimal", + "type": "string" + } + }, + "required": [ + "currency", + "product", + "recurring" + ], + "title": "recurring_price_data", + "type": "object" + }, + "quantity": { + "description": "Quantity for this item.", + "type": "integer" + }, + "tax_rates": { + "anyOf": [ + { + "items": { + "maxLength": 5000, + "type": "string" + }, + "type": "array" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates." + } + }, + "title": "subscription_item_update_params", + "type": "object" + }, + "type": "array" + }, + "proration_behavior": { + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.", + "enum": [ + "always_invoice", + "create_prorations", + "none" + ], + "type": "string" + }, + "proration_date": { + "description": "If previewing an update to a subscription, and doing proration, `subscription_details.proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_details.items`, or `subscription_details.trial_end` are required. Also, `subscription_details.proration_behavior` cannot be set to 'none'.", + "format": "unix-time", + "type": "integer" + }, + "resume_at": { + "description": "For paused subscriptions, setting `subscription_details.resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed.", + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + }, + "start_date": { + "description": "Date a subscription is intended to start (can be future or past).", + "format": "unix-time", + "type": "integer" + }, + "trial_end": { + "anyOf": [ + { + "enum": [ + "now" + ], + "maxLength": 5000, + "type": "string" + }, + { + "format": "unix-time", + "type": "integer" + } + ], + "description": "If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_details.items` or `subscription` is required." + } + }, + "title": "subscription_details_params", + "type": "object" + }, + "style": "deepObject" + }, + { + "description": "A list of up to 20 subscription items, each with an attached price. This field has been deprecated and will be removed in a future API version. Use `subscription_details.items` instead.", "explode": true, "in": "query", "name": "subscription_items", @@ -91854,7 +95716,7 @@ "style": "deepObject" }, { - "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`.", + "description": "Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when the billing cycle changes (e.g., when switching plans, resetting `billing_cycle_anchor=now`, or starting a trial), or if an item's `quantity` changes. The default value is `create_prorations`. This field has been deprecated and will be removed in a future API version. Use `subscription_details.proration_behavior` instead.", "in": "query", "name": "subscription_proration_behavior", "required": false, @@ -91869,7 +95731,7 @@ "style": "form" }, { - "description": "If previewing an update to a subscription, and doing proration, `subscription_proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_items`, or `subscription_trial_end` are required. Also, `subscription_proration_behavior` cannot be set to 'none'.", + "description": "If previewing an update to a subscription, and doing proration, `subscription_proration_date` forces the proration to be calculated as though the update was done at the specified time. The time given must be within the current subscription period and within the current phase of the schedule backing this subscription, if the schedule exists. If set, `subscription`, and one of `subscription_items`, or `subscription_trial_end` are required. Also, `subscription_proration_behavior` cannot be set to 'none'. This field has been deprecated and will be removed in a future API version. Use `subscription_details.proration_date` instead.", "in": "query", "name": "subscription_proration_date", "required": false, @@ -91880,7 +95742,7 @@ "style": "form" }, { - "description": "For paused subscriptions, setting `subscription_resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed.", + "description": "For paused subscriptions, setting `subscription_resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed. This field has been deprecated and will be removed in a future API version. Use `subscription_details.resume_at` instead.", "in": "query", "name": "subscription_resume_at", "required": false, @@ -91894,7 +95756,7 @@ "style": "form" }, { - "description": "Date a subscription is intended to start (can be future or past).", + "description": "Date a subscription is intended to start (can be future or past). This field has been deprecated and will be removed in a future API version. Use `subscription_details.start_date` instead.", "in": "query", "name": "subscription_start_date", "required": false, @@ -91905,7 +95767,7 @@ "style": "form" }, { - "description": "If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_items` or `subscription` is required.", + "description": "If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_items` or `subscription` is required. This field has been deprecated and will be removed in a future API version. Use `subscription_details.trial_end` instead.", "explode": true, "in": "query", "name": "subscription_trial_end", @@ -92780,6 +96642,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -93552,7 +97415,7 @@ "type": "string" } ], - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`." + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. For `type=recurring` line items, the incoming metadata specified on the request is directly used to set this value, in contrast to `type=invoiceitem` line items, where any existing metadata on the invoice line is merged with the incoming data." }, "period": { "description": "The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have [Stripe Revenue Recognition](https://stripe.com/docs/revenue-recognition) enabled, the period will be used to recognize and defer revenue. See the [Revenue Recognition documentation](https://stripe.com/docs/revenue-recognition/methodology/subscriptions-and-invoicing) for details.", @@ -104068,6 +107931,21 @@ "title": "param", "type": "object" }, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, + "amazon_pay": { + "description": "If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, "au_becs_debit": { "description": "If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.", "properties": { @@ -104576,6 +108454,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -104850,6 +108729,40 @@ ], "description": "If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options." }, + "amazon_pay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.\n\nIf provided, this parameter will override the top level behavior of `capture_method` when finalizing the payment with this payment method type.\n\nIf `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter will unset the stored value for this payment method type.", + "enum": [ + "", + "manual" + ], + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).", + "enum": [ + "", + "none", + "off_session" + ], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options." + }, "au_becs_debit": { "anyOf": [ { @@ -106105,6 +110018,14 @@ "anyOf": [ { "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.\n\nIf provided, this parameter will override the top level behavior of `capture_method` when finalizing the payment with this payment method type.\n\nIf `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter will unset the stored value for this payment method type.", + "enum": [ + "", + "manual" + ], + "type": "string" + }, "setup_future_usage": { "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).", "enum": [ @@ -106266,6 +110187,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -106997,6 +110919,21 @@ "title": "param", "type": "object" }, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, + "amazon_pay": { + "description": "If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, "au_becs_debit": { "description": "If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.", "properties": { @@ -107505,6 +111442,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -107779,6 +111717,40 @@ ], "description": "If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options." }, + "amazon_pay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.\n\nIf provided, this parameter will override the top level behavior of `capture_method` when finalizing the payment with this payment method type.\n\nIf `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter will unset the stored value for this payment method type.", + "enum": [ + "", + "manual" + ], + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).", + "enum": [ + "", + "none", + "off_session" + ], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options." + }, "au_becs_debit": { "anyOf": [ { @@ -109034,6 +113006,14 @@ "anyOf": [ { "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.\n\nIf provided, this parameter will override the top level behavior of `capture_method` when finalizing the payment with this payment method type.\n\nIf `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter will unset the stored value for this payment method type.", + "enum": [ + "", + "manual" + ], + "type": "string" + }, "setup_future_usage": { "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).", "enum": [ @@ -109195,6 +113175,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -110074,6 +114055,21 @@ "title": "param", "type": "object" }, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, + "amazon_pay": { + "description": "If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, "au_becs_debit": { "description": "If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.", "properties": { @@ -110582,6 +114578,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -110856,6 +114853,40 @@ ], "description": "If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options." }, + "amazon_pay": { + "anyOf": [ + { + "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.\n\nIf provided, this parameter will override the top level behavior of `capture_method` when finalizing the payment with this payment method type.\n\nIf `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter will unset the stored value for this payment method type.", + "enum": [ + "", + "manual" + ], + "type": "string" + }, + "setup_future_usage": { + "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).", + "enum": [ + "", + "none", + "off_session" + ], + "type": "string" + } + }, + "title": "payment_method_options_param", + "type": "object" + }, + { + "enum": [ + "" + ], + "type": "string" + } + ], + "description": "If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options." + }, "au_becs_debit": { "anyOf": [ { @@ -112111,6 +116142,14 @@ "anyOf": [ { "properties": { + "capture_method": { + "description": "Controls when the funds will be captured from the customer's account.\n\nIf provided, this parameter will override the top level behavior of `capture_method` when finalizing the payment with this payment method type.\n\nIf `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter will unset the stored value for this payment method type.", + "enum": [ + "", + "manual" + ], + "type": "string" + }, "setup_future_usage": { "description": "Indicates that you intend to make future payments with this PaymentIntent's payment method.\n\nProviding this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.\n\nWhen processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).", "enum": [ @@ -112272,6 +116311,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -115600,6 +119640,17 @@ }, "style": "deepObject" }, + { + "description": "A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.", + "in": "query", + "name": "ending_before", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" + }, { "description": "Specifies which fields in the response should be expanded.", "explode": true, @@ -115614,6 +119665,27 @@ "type": "array" }, "style": "deepObject" + }, + { + "description": "A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.", + "in": "query", + "name": "limit", + "required": false, + "schema": { + "type": "integer" + }, + "style": "form" + }, + { + "description": "A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.", + "in": "query", + "name": "starting_after", + "required": false, + "schema": { + "maxLength": 5000, + "type": "string" + }, + "style": "form" } ], "requestBody": { @@ -115656,6 +119728,7 @@ "url": { "description": "The URL where this list can be accessed.", "maxLength": 5000, + "pattern": "^/v1/payment_method_configurations", "type": "string" } }, @@ -115710,6 +119783,10 @@ "explode": true, "style": "deepObject" }, + "amazon_pay": { + "explode": true, + "style": "deepObject" + }, "apple_pay": { "explode": true, "style": "deepObject" @@ -115830,6 +119907,10 @@ "explode": true, "style": "deepObject" }, + "swish": { + "explode": true, + "style": "deepObject" + }, "us_bank_account": { "explode": true, "style": "deepObject" @@ -115938,6 +120019,29 @@ "title": "payment_method_param", "type": "object" }, + "amazon_pay": { + "description": "Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.", + "properties": { + "display_preference": { + "description": "Whether or not the payment method should be displayed.", + "properties": { + "preference": { + "description": "The account's preference for whether or not to display this payment method.", + "enum": [ + "none", + "off", + "on" + ], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, "apple_pay": { "description": "Stripe users can accept [Apple Pay](/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.", "properties": { @@ -116623,6 +120727,29 @@ "title": "payment_method_param", "type": "object" }, + "swish": { + "description": "Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.", + "properties": { + "display_preference": { + "description": "Whether or not the payment method should be displayed.", + "properties": { + "preference": { + "description": "The account's preference for whether or not to display this payment method.", + "enum": [ + "none", + "off", + "on" + ], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, "us_bank_account": { "description": "Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-debit) for more details.", "properties": { @@ -116825,6 +120952,10 @@ "explode": true, "style": "deepObject" }, + "amazon_pay": { + "explode": true, + "style": "deepObject" + }, "apple_pay": { "explode": true, "style": "deepObject" @@ -116945,6 +121076,10 @@ "explode": true, "style": "deepObject" }, + "swish": { + "explode": true, + "style": "deepObject" + }, "us_bank_account": { "explode": true, "style": "deepObject" @@ -117057,6 +121192,29 @@ "title": "payment_method_param", "type": "object" }, + "amazon_pay": { + "description": "Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.", + "properties": { + "display_preference": { + "description": "Whether or not the payment method should be displayed.", + "properties": { + "preference": { + "description": "The account's preference for whether or not to display this payment method.", + "enum": [ + "none", + "off", + "on" + ], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, "apple_pay": { "description": "Stripe users can accept [Apple Pay](/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.", "properties": { @@ -117737,6 +121895,29 @@ "title": "payment_method_param", "type": "object" }, + "swish": { + "description": "Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.", + "properties": { + "display_preference": { + "description": "Whether or not the payment method should be displayed.", + "properties": { + "preference": { + "description": "The account's preference for whether or not to display this payment method.", + "enum": [ + "none", + "off", + "on" + ], + "type": "string" + } + }, + "title": "display_preference_param", + "type": "object" + } + }, + "title": "payment_method_param", + "type": "object" + }, "us_bank_account": { "description": "Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-debit) for more details.", "properties": { @@ -118325,6 +122506,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -118457,6 +122639,10 @@ "explode": true, "style": "deepObject" }, + "amazon_pay": { + "explode": true, + "style": "deepObject" + }, "au_becs_debit": { "explode": true, "style": "deepObject" @@ -118646,6 +122832,21 @@ "title": "param", "type": "object" }, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, + "amazon_pay": { + "description": "If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, "au_becs_debit": { "description": "If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.", "properties": { @@ -119243,6 +123444,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -119472,6 +123674,15 @@ "schema": { "additionalProperties": false, "properties": { + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, "billing_details": { "description": "Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.", "properties": { @@ -129926,6 +134137,21 @@ "title": "param", "type": "object" }, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, + "amazon_pay": { + "description": "If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, "au_becs_debit": { "description": "If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.", "properties": { @@ -130434,6 +134660,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -130606,6 +134833,12 @@ "title": "setup_intent_payment_method_options_param", "type": "object" }, + "amazon_pay": { + "description": "If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.", + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, "card": { "description": "Configuration for any card setup attempted on this SetupIntent.", "properties": { @@ -130886,6 +135119,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -131261,6 +135495,21 @@ "title": "param", "type": "object" }, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, + "amazon_pay": { + "description": "If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, "au_becs_debit": { "description": "If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.", "properties": { @@ -131769,6 +136018,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -131941,6 +136191,12 @@ "title": "setup_intent_payment_method_options_param", "type": "object" }, + "amazon_pay": { + "description": "If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.", + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, "card": { "description": "Configuration for any card setup attempted on this SetupIntent.", "properties": { @@ -132221,6 +136477,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -132628,6 +136885,21 @@ "title": "param", "type": "object" }, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, + "amazon_pay": { + "description": "If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, "au_becs_debit": { "description": "If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.", "properties": { @@ -133136,6 +137408,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -133308,6 +137581,12 @@ "title": "setup_intent_payment_method_options_param", "type": "object" }, + "amazon_pay": { + "description": "If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.", + "properties": {}, + "title": "setup_intent_payment_method_options_param", + "type": "object" + }, "card": { "description": "Configuration for any card setup attempted on this SetupIntent.", "properties": { @@ -133588,6 +137867,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -140339,6 +144619,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -141936,6 +146217,7 @@ "items": { "enum": [ "balances", + "ownership", "transactions" ], "type": "string", @@ -149540,6 +153822,21 @@ "title": "param", "type": "object" }, + "allow_redisplay": { + "description": "This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.", + "enum": [ + "always", + "limited", + "unspecified" + ], + "type": "string" + }, + "amazon_pay": { + "description": "If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.", + "properties": {}, + "title": "param", + "type": "object" + }, "au_becs_debit": { "description": "If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.", "properties": { @@ -150048,6 +154345,7 @@ "affirm", "afterpay_clearpay", "alipay", + "amazon_pay", "au_becs_debit", "bacs_debit", "bancontact", @@ -151045,9 +155343,10 @@ "type": "string" }, "unit": { - "description": "The units for `volume_decimal`. One of `us_gallon` or `liter`.", + "description": "The units for `volume_decimal`. One of `liter`, `us_gallon`, or `other`.", "enum": [ "liter", + "other", "us_gallon" ], "maxLength": 5000, @@ -152356,9 +156655,10 @@ "type": "string" }, "unit": { - "description": "The units for `volume_decimal`. One of `us_gallon` or `liter`.", + "description": "The units for `volume_decimal`. One of `liter`, `us_gallon`, or `other`.", "enum": [ "liter", + "other", "us_gallon" ], "maxLength": 5000, @@ -152939,9 +157239,10 @@ "type": "string" }, "unit": { - "description": "The units for `volume_decimal`. One of `us_gallon` or `liter`.", + "description": "The units for `volume_decimal`. One of `liter`, `us_gallon`, or `other`.", "enum": [ "liter", + "other", "us_gallon" ], "maxLength": 5000, @@ -154626,7 +158927,7 @@ }, "/v1/tokens": { "post": { - "description": "

Creates a single-use token that represents a bank account’s details.\nYou can use this token with any API method in place of a bank account dictionary. You can only use this token once. To do so, attach it to a Custom account.

", + "description": "

Creates a single-use token that represents a bank account’s details.\nYou can use this token with any API method in place of a bank account dictionary. You can only use this token once. To do so, attach it to a connected account where controller.requirement_collection is application, which includes Custom accounts.

", "operationId": "PostTokens", "requestBody": { "content": { @@ -162165,6 +166466,7 @@ "customer.tax_id.updated", "customer.updated", "customer_cash_balance_transaction.created", + "entitlements.active_entitlement_summary.updated", "file.created", "financial_connections.account.created", "financial_connections.account.deactivated", @@ -162642,6 +166944,7 @@ "customer.tax_id.updated", "customer.updated", "customer_cash_balance_transaction.created", + "entitlements.active_entitlement_summary.updated", "file.created", "financial_connections.account.created", "financial_connections.account.deactivated", diff --git a/pkg/cmd/resources_cmds.go b/pkg/cmd/resources_cmds.go index 581bfa1b..d9ac7c43 100644 --- a/pkg/cmd/resources_cmds.go +++ b/pkg/cmd/resources_cmds.go @@ -192,9 +192,17 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { }, &Config) resource.NewOperationCmd(rAccountSessionsCmd.Cmd, "create", "/v1/account_sessions", http.MethodPost, map[string]string{ "account": "string", - "components.account_onboarding.enabled": "boolean", + "components.account_management.enabled": "boolean", + "components.account_management.features.external_account_collection": "boolean", + "components.account_onboarding.enabled": "boolean", "components.account_onboarding.features.external_account_collection": "boolean", + "components.balances.enabled": "boolean", + "components.balances.features.edit_payout_schedule": "boolean", + "components.balances.features.instant_payouts": "boolean", + "components.balances.features.standard_payouts": "boolean", "components.documents.enabled": "boolean", + "components.notification_banner.enabled": "boolean", + "components.notification_banner.features.external_account_collection": "boolean", "components.payment_details.enabled": "boolean", "components.payment_details.features.capture_payments": "boolean", "components.payment_details.features.destination_on_behalf_of_charge_management": "boolean", @@ -209,6 +217,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "components.payouts.features.edit_payout_schedule": "boolean", "components.payouts.features.instant_payouts": "boolean", "components.payouts.features.standard_payouts": "boolean", + "components.payouts_list.enabled": "boolean", }, &Config) resource.NewOperationCmd(rAccountsCmd.Cmd, "capabilities", "/v1/accounts/{account}/capabilities", http.MethodGet, map[string]string{}, &Config) resource.NewOperationCmd(rAccountsCmd.Cmd, "create", "/v1/accounts", http.MethodPost, map[string]string{ @@ -771,6 +780,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "payment_method_data.acss_debit.account_number": "string", "payment_method_data.acss_debit.institution_number": "string", "payment_method_data.acss_debit.transit_number": "string", + "payment_method_data.allow_redisplay": "string", "payment_method_data.au_becs_debit.account_number": "string", "payment_method_data.au_becs_debit.bsb_number": "string", "payment_method_data.bacs_debit.account_number": "string", @@ -961,10 +971,11 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "test_clock": "string", }, &Config) resource.NewOperationCmd(rCustomersCmd.Cmd, "list_payment_methods", "/v1/customers/{customer}/payment_methods", http.MethodGet, map[string]string{ - "ending_before": "string", - "limit": "integer", - "starting_after": "string", - "type": "string", + "allow_redisplay": "string", + "ending_before": "string", + "limit": "integer", + "starting_after": "string", + "type": "string", }, &Config) resource.NewOperationCmd(rCustomersCmd.Cmd, "retrieve", "/v1/customers/{customer}", http.MethodGet, map[string]string{}, &Config) resource.NewOperationCmd(rCustomersCmd.Cmd, "retrieve_payment_method", "/v1/customers/{customer}/payment_methods/{payment_method}", http.MethodGet, map[string]string{}, &Config) @@ -1231,6 +1242,33 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "transfer_data.amount": "integer", "transfer_data.destination": "string", }, &Config) + resource.NewOperationCmd(rInvoicesCmd.Cmd, "create_preview", "/v1/invoices/create_preview", http.MethodPost, map[string]string{ + "automatic_tax.enabled": "boolean", + "automatic_tax.liability.account": "string", + "automatic_tax.liability.type": "string", + "coupon": "string", + "currency": "string", + "customer": "string", + "customer_details.tax.ip_address": "string", + "customer_details.tax_exempt": "string", + "issuer.account": "string", + "issuer.type": "string", + "on_behalf_of": "string", + "schedule": "string", + "schedule_details.end_behavior": "string", + "schedule_details.proration_behavior": "string", + "subscription": "string", + "subscription_details.billing_cycle_anchor": "string", + "subscription_details.cancel_at": "integer", + "subscription_details.cancel_at_period_end": "boolean", + "subscription_details.cancel_now": "boolean", + "subscription_details.default_tax_rates": "array", + "subscription_details.proration_behavior": "string", + "subscription_details.proration_date": "integer", + "subscription_details.resume_at": "string", + "subscription_details.start_date": "integer", + "subscription_details.trial_end": "string", + }, &Config) resource.NewOperationCmd(rInvoicesCmd.Cmd, "delete", "/v1/invoices/{invoice}", http.MethodDelete, map[string]string{}, &Config) resource.NewOperationCmd(rInvoicesCmd.Cmd, "finalize_invoice", "/v1/invoices/{invoice}/finalize", http.MethodPost, map[string]string{ "auto_advance": "boolean", @@ -1381,6 +1419,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "payment_method_data.acss_debit.account_number": "string", "payment_method_data.acss_debit.institution_number": "string", "payment_method_data.acss_debit.transit_number": "string", + "payment_method_data.allow_redisplay": "string", "payment_method_data.au_becs_debit.account_number": "string", "payment_method_data.au_becs_debit.bsb_number": "string", "payment_method_data.bacs_debit.account_number": "string", @@ -1433,6 +1472,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "payment_method_data.acss_debit.account_number": "string", "payment_method_data.acss_debit.institution_number": "string", "payment_method_data.acss_debit.transit_number": "string", + "payment_method_data.allow_redisplay": "string", "payment_method_data.au_becs_debit.account_number": "string", "payment_method_data.au_becs_debit.bsb_number": "string", "payment_method_data.bacs_debit.account_number": "string", @@ -1514,6 +1554,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "payment_method_data.acss_debit.account_number": "string", "payment_method_data.acss_debit.institution_number": "string", "payment_method_data.acss_debit.transit_number": "string", + "payment_method_data.allow_redisplay": "string", "payment_method_data.au_becs_debit.account_number": "string", "payment_method_data.au_becs_debit.bsb_number": "string", "payment_method_data.bacs_debit.account_number": "string", @@ -1640,6 +1681,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "affirm.display_preference.preference": "string", "afterpay_clearpay.display_preference.preference": "string", "alipay.display_preference.preference": "string", + "amazon_pay.display_preference.preference": "string", "apple_pay.display_preference.preference": "string", "apple_pay_later.display_preference.preference": "string", "au_becs_debit.display_preference.preference": "string", @@ -1671,12 +1713,16 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "revolut_pay.display_preference.preference": "string", "sepa_debit.display_preference.preference": "string", "sofort.display_preference.preference": "string", + "swish.display_preference.preference": "string", "us_bank_account.display_preference.preference": "string", "wechat_pay.display_preference.preference": "string", "zip.display_preference.preference": "string", }, &Config) resource.NewOperationCmd(rPaymentMethodConfigurationsCmd.Cmd, "list", "/v1/payment_method_configurations", http.MethodGet, map[string]string{ - "application": "string", + "application": "string", + "ending_before": "string", + "limit": "integer", + "starting_after": "string", }, &Config) resource.NewOperationCmd(rPaymentMethodConfigurationsCmd.Cmd, "retrieve", "/v1/payment_method_configurations/{configuration}", http.MethodGet, map[string]string{}, &Config) resource.NewOperationCmd(rPaymentMethodConfigurationsCmd.Cmd, "update", "/v1/payment_method_configurations/{configuration}", http.MethodPost, map[string]string{ @@ -1685,6 +1731,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "affirm.display_preference.preference": "string", "afterpay_clearpay.display_preference.preference": "string", "alipay.display_preference.preference": "string", + "amazon_pay.display_preference.preference": "string", "apple_pay.display_preference.preference": "string", "apple_pay_later.display_preference.preference": "string", "au_becs_debit.display_preference.preference": "string", @@ -1715,6 +1762,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "revolut_pay.display_preference.preference": "string", "sepa_debit.display_preference.preference": "string", "sofort.display_preference.preference": "string", + "swish.display_preference.preference": "string", "us_bank_account.display_preference.preference": "string", "wechat_pay.display_preference.preference": "string", "zip.display_preference.preference": "string", @@ -1742,6 +1790,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "acss_debit.account_number": "string", "acss_debit.institution_number": "string", "acss_debit.transit_number": "string", + "allow_redisplay": "string", "au_becs_debit.account_number": "string", "au_becs_debit.bsb_number": "string", "bacs_debit.account_number": "string", @@ -1780,6 +1829,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { }, &Config) resource.NewOperationCmd(rPaymentMethodsCmd.Cmd, "retrieve", "/v1/payment_methods/{payment_method}", http.MethodGet, map[string]string{}, &Config) resource.NewOperationCmd(rPaymentMethodsCmd.Cmd, "update", "/v1/payment_methods/{payment_method}", http.MethodPost, map[string]string{ + "allow_redisplay": "string", "billing_details.email": "string", "billing_details.name": "string", "billing_details.phone": "string", @@ -2255,6 +2305,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "payment_method_data.acss_debit.account_number": "string", "payment_method_data.acss_debit.institution_number": "string", "payment_method_data.acss_debit.transit_number": "string", + "payment_method_data.allow_redisplay": "string", "payment_method_data.au_becs_debit.account_number": "string", "payment_method_data.au_becs_debit.bsb_number": "string", "payment_method_data.bacs_debit.account_number": "string", @@ -2335,6 +2386,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "payment_method_data.acss_debit.account_number": "string", "payment_method_data.acss_debit.institution_number": "string", "payment_method_data.acss_debit.transit_number": "string", + "payment_method_data.allow_redisplay": "string", "payment_method_data.au_becs_debit.account_number": "string", "payment_method_data.au_becs_debit.bsb_number": "string", "payment_method_data.bacs_debit.account_number": "string", @@ -2426,6 +2478,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "payment_method_data.acss_debit.account_number": "string", "payment_method_data.acss_debit.institution_number": "string", "payment_method_data.acss_debit.transit_number": "string", + "payment_method_data.allow_redisplay": "string", "payment_method_data.au_becs_debit.account_number": "string", "payment_method_data.au_becs_debit.bsb_number": "string", "payment_method_data.bacs_debit.account_number": "string", @@ -3283,6 +3336,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "payment_intent_data.transfer_group": "string", "payment_method_collection": "string", "payment_method_configuration": "string", + "payment_method_data.allow_redisplay": "string", "payment_method_options.acss_debit.currency": "string", "payment_method_options.acss_debit.mandate_options.custom_mandate_url": "string", "payment_method_options.acss_debit.mandate_options.default_for": "array", @@ -3294,6 +3348,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "payment_method_options.affirm.setup_future_usage": "string", "payment_method_options.afterpay_clearpay.setup_future_usage": "string", "payment_method_options.alipay.setup_future_usage": "string", + "payment_method_options.amazon_pay.setup_future_usage": "string", "payment_method_options.au_becs_debit.setup_future_usage": "string", "payment_method_options.bacs_debit.setup_future_usage": "string", "payment_method_options.bancontact.setup_future_usage": "string", @@ -3319,6 +3374,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "payment_method_options.konbini.expires_after_days": "integer", "payment_method_options.konbini.setup_future_usage": "string", "payment_method_options.link.setup_future_usage": "string", + "payment_method_options.mobilepay.setup_future_usage": "string", "payment_method_options.oxxo.expires_after_days": "integer", "payment_method_options.oxxo.setup_future_usage": "string", "payment_method_options.p24.setup_future_usage": "string", @@ -3345,6 +3401,8 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "phone_number_collection.enabled": "boolean", "redirect_on_completion": "string", "return_url": "string", + "saved_payment_method_options.allow_redisplay_filters": "array", + "saved_payment_method_options.payment_method_save": "string", "setup_intent_data.description": "string", "setup_intent_data.on_behalf_of": "string", "shipping_address_collection.allowed_countries": "array", @@ -3474,7 +3532,6 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { }, &Config) resource.NewOperationCmd(rFinancialConnectionsTransactionsCmd.Cmd, "retrieve", "/v1/financial_connections/transactions/{transaction}", http.MethodGet, map[string]string{}, &Config) resource.NewOperationCmd(rForwardingRequestsCmd.Cmd, "create", "/v1/forwarding/requests", http.MethodPost, map[string]string{ - "config": "string", "payment_method": "string", "replacements": "array", "request.body": "string", @@ -4156,6 +4213,7 @@ func addAllResourcesCmds(rootCmd *cobra.Command) { "payment_method_data.acss_debit.account_number": "string", "payment_method_data.acss_debit.institution_number": "string", "payment_method_data.acss_debit.transit_number": "string", + "payment_method_data.allow_redisplay": "string", "payment_method_data.au_becs_debit.account_number": "string", "payment_method_data.au_becs_debit.bsb_number": "string", "payment_method_data.bacs_debit.account_number": "string", diff --git a/pkg/proxy/events_list.go b/pkg/proxy/events_list.go index 96f0ed86..2b43e5f9 100644 --- a/pkg/proxy/events_list.go +++ b/pkg/proxy/events_list.go @@ -71,6 +71,7 @@ var validEvents = map[string]bool{ "customer.tax_id.updated": true, "customer.updated": true, "customer_cash_balance_transaction.created": true, + "entitlements.active_entitlement_summary.updated": true, "file.created": true, "financial_connections.account.created": true, "financial_connections.account.deactivated": true,