HORIZON HASKELLDocslts/ghc-9.10.x248f8f02026-10-05Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · 248f8f0 · 2026-10-05

Modulestripeapi-3.0.0.0Haskell2010

StripeAPI.Operations.PostCustomersCustomerSubscriptionsSubscriptionExposedId

Contains the different functions to run the operation postCustomersCustomerSubscriptionsSubscriptionExposedId

  • 63 types
  • 26 values
  • Packagestripeapi-3.0.0.0
  • Exports89
  • LanguageHaskell2010
  • LicenceMIT
  • SourcePostCustomersCustomerSubscriptionsSubscriptionExposedId.hs
valuepostCustomersCustomerSubscriptionsSubscriptionExposedId
  1. :: MonadHTTP m
  2. => PostCustomersCustomerSubscriptionsSubscriptionExposedIdParameters

    Contains all available parameters of this operation (query and path parameters)

  3. -> Maybe PostCustomersCustomerSubscriptionsSubscriptionExposedIdRequestBody

    The request body to send

  4. -> ClientT m (Response PostCustomersCustomerSubscriptionsSubscriptionExposedIdResponse)

    Monadic computation which returns the result of the operation

#
POST /v1/customers/{customer}/subscriptions/{subscription_exposed_id}

<p>Updates an existing subscription on a customer to match the specified parameters. When changing plans or quantities, we will optionally prorate the price we charge next month to make up for any price changes. To preview how the proration will be calculated, use the <a href="#upcoming_invoice">upcoming invoice</a> endpoint.</p>

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.parameters in the specification.

Constructors

Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema in the specification.

Constructors

Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.add_invoice_items.items.properties.price_data.properties.tax_behavior in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.add_invoice_items.items.properties.tax_rates.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.automatic_tax in the specification.

Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.billing_cycle_anchor in the specification.

Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time. For more information, see the billing cycle documentation.

Constructors

Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.billing_thresholds.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.billing_thresholds.anyOf in the specification.

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.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.cancel_at.anyOf in the specification.

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.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.collection_method in the specification.

Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions. Defaults to `charge_automatically`.

Constructors

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.default_tax_rates.anyOf in the specification.

The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription. Pass an empty string to remove previously-defined tax rates.

Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.items.items in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.items.items.properties.billing_thresholds.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.items.items.properties.billing_thresholds.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.items.items.properties.metadata.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.items.items.properties.price_data.properties.recurring in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.items.items.properties.price_data.properties.recurring.properties.interval in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.items.items.properties.price_data.properties.tax_behavior in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.items.items.properties.tax_rates.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.metadata.anyOf in the specification.

Set of key-value pairs 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`.

Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.pause_collection.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.pause_collection.anyOf.properties.behavior in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.pause_collection.anyOf in the specification.

If specified, payment collection for this subscription will be paused.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_behavior in the specification.

Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the SCA Migration Guide for Billing to learn more. This is the default behavior.

Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription’s invoice. Such as failed payments, SCA regulation, or collecting a mandate for a bank debit payment method.

Use `pending_if_incomplete` to update the subscription using pending updates. When you use `pending_if_incomplete` you can only pass the parameters supported by pending updates.

Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the changelog to learn more.

Constructors

Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options in the specification.

Constructors

Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.acss_debit.anyOf.properties.mandate_options in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.acss_debit.anyOf.properties.mandate_options.properties.transaction_type in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.acss_debit.anyOf.properties.verification_method in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.acss_debit.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.bancontact.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.bancontact.anyOf.properties.preferred_language in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.bancontact.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.card.anyOf.properties.mandate_options.properties.amount_type in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.card.anyOf.properties.request_three_d_secure in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.card.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.customer_balance.anyOf.properties.bank_transfer.properties.eu_bank_transfer in the specification.

Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.konbini.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.us_bank_account.anyOf.properties.financial_connections in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.us_bank_account.anyOf.properties.financial_connections.properties.permissions.items in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.us_bank_account.anyOf.properties.verification_method in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_options.properties.us_bank_account.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_types.anyOf.items in the specification.

Constructors

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.payment_method_types.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.payment_settings.properties.save_default_payment_method in the specification.

Instances4Eq, Show, FromJSON, ToJSON
Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.pending_invoice_item_interval.anyOf.properties.interval in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.pending_invoice_item_interval.anyOf in the specification.

Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling Create an invoice for the given subscription at the specified interval.

Instances4Eq, Show, FromJSON, ToJSON

Defines the enum schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.proration_behavior in the specification.

Determines how to handle 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.

Constructors

Instances4Eq, Show, FromJSON, ToJSON

Defines the object schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.transfer_data.anyOf in the specification.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.transfer_data.anyOf in the specification.

If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges. This will be unset if you POST an empty value.

Instances4Eq, Show, FromJSON, ToJSON

Defines the oneOf schema located at paths./v1/customers/{customer}/subscriptions/{subscription_exposed_id}.POST.requestBody.content.application/x-www-form-urlencoded.schema.properties.trial_end.anyOf in the specification.

Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`.

Instances4Eq, Show, FromJSON, ToJSON

Represents a response of the operation postCustomersCustomerSubscriptionsSubscriptionExposedId.

The response constructor is chosen by the status code of the response. If no case matches (no specific case for the response code, no range case, no default case), PostCustomersCustomerSubscriptionsSubscriptionExposedIdResponseError is used.

Instances2Eq, Show