Configure live Stripe keys

<Info>This API is in beta. Endpoints, fields, and behavior may still change, so avoid depending on it in production.</Info>

Switches the app to live mode using live Stripe keys you already have from the Stripe dashboard, sent directly in the request body, rather than keys Base44 creates for you. Use Provision live Stripe keys instead to have Base44 create them automatically once the sandbox's Stripe account is activated.

Stores the keys, backs up the current test credentials, and redeploys backend functions with the updated secrets.

Key prefixes are checked, but success does not verify that the keys belong to the same Stripe account or can process payments.

Automatic webhook migration is best effort.

Requires write access to the app. Workspace viewers cannot call this operation.

post/api/apps/{app_id}/payments/stripe/configure-live-keys

Path parameters

app_idstring required

ID of the Base44 app.

ID of the Base44 app.

Request body

publishable_keystring required

Live Stripe publishable key beginning with pk_live_.

secret_keystring required

Live Stripe secret or restricted key beginning with sk_live_ or rk_live_.

webhook_secretstring nullable

Live webhook signing secret beginning with whsec_. Defaults to null, which attempts automatic migration when an existing webhook secret is present.

Example request

{
  "publishable_key": "pk_live_example",
  "secret_key": "sk_live_example",
  "webhook_secret": "whsec_example"
}

Response

The operation result.

successboolean required

Whether live keys were stored and the app was switched to live mode.

messagestring required

Human-readable configuration result.

live_keys_configuredboolean required

Whether the stored completion flag was confirmed. It can be false even after keys were stored if finalization failed.

webhook_migratedboolean required

Whether this call automatically migrated the webhook. It is false when a webhook secret was supplied directly.

Example response

{
  "success": true,
  "message": "Live mode API keys configured successfully. Test keys have been backed up.",
  "live_keys_configured": true
}

Changes