Skip to main content
Customer-facing API requests use secret API keys from trusted server environments.
Keep secret keys on your server. Do not place them in browsers, mobile apps, hosted checkout pages, or logs. Create and rotate merchant keys in Developers → API keys and platform keys in Connect → API keys.

Browser credentials

Ionic Blocks uses a publishable key and an intent’s client secret. Your backend creates the intent and returns those two values to the browser. For Connect, the browser also selects the receiving merchant with the account option, and the platform secret key stays on your server.

Choosing key permissions

In Developers → API keys, choose a restricted secret key when an integration needs a specific set of permissions. The picker shows the permissions currently available to you. Select all selects those current choices; Read only and Write only select the available actions of that kind. You can also select individual actions independently. A restricted key keeps the permissions selected when you create it. New Ionic permissions are not added to that key automatically. Standard secret keys follow Ionic’s managed standard policy and can receive permissions explicitly added to that policy. Platform credentials in Connect → API keys offer permissions approved for your Platform Program and environment. A permission available to a Platform may be unavailable for an Account key or a connected account’s consent. If access changes while a form is open, reload the inventory and review the selection; the server checks the current policy when creating the key.

Platforms and connected accounts

An authorized Platform can act for one connected account by adding that Account’s Ionic Merchant ID to a server-side request:
Use this header only when the endpoint’s API reference lists Ionic-Account. The header is not a global account switch and does not make an unsupported endpoint delegable. Omit it when the key owner is accessing its own Account. A request selects exactly one connected account. PaymentIntents, SetupIntents, and customers accept the header. Platform payment domains and platform webhook endpoints belong to the platform itself, so those requests carry no Ionic-Account. See How Connect works.
Never accept an Account ID from an untrusted browser and forward it with a Platform secret key. Choose the connected account on your server after authenticating and authorizing your own user.

Hosted checkout

Your backend creates checkout sessions and payment links. Ionic-hosted checkout handles buyer payment collection and confirmation without requiring you to send raw card data to the API. Create checkout resources on your server, redirect the buyer, and retrieve the completed session from your server before fulfilling the order.

Retry behavior

Authentication identifies the caller. Idempotency identifies a retryable operation. For create and refund calls, send the same Idempotency-Key when retrying the same operation. See Idempotency for the retry model.