Stripe: Create an Onboarding Link
Stripe terminal.postTerminalOnboardingLinks: arguments, response, policy and SDK examples.
← Terminal operations · Get started
Operation stripe.postterminalonboardinglinks
Provider route: POST /v1/terminal/onboarding_links. Alter supplies the connection’s credentials and routing.
Call through Alter
Section titled “Call through Alter”Install @alter-ai/sdk @alter-ai/stripe with npm, or alter-sdk-stripe with pip. Supply your connected customer’s grant ID and the arguments described below.
import { App } from "@alter-ai/sdk";import { StripeIntegration } from "@alter-ai/stripe";
async function execute(input: Parameters<StripeIntegration["terminal"]["postTerminalOnboardingLinks"]>[0]) { const app = new App({ apiKey: process.env.ALTER_API_KEY! }); try { const provider = new StripeIntegration(app, { grantId: process.env.PROVIDER_GRANT_ID! }); const call = await provider.terminal.postTerminalOnboardingLinks(input); const result = await call.wait(); return result.bodyJson(); } finally { await app.close(); }}import osfrom alter_sdk import Appfrom alter_sdk_stripe import StripeIntegration
async def execute(arguments): async with App(api_key=os.environ["ALTER_API_KEY"]) as app: provider = StripeIntegration(app, {"grant_id": os.environ["PROVIDER_GRANT_ID"]}) call = await provider.terminal.post_terminal_onboarding_links(arguments) result = await call.wait() return result.body_json()| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: not allowed |
headers | object | Optional | Additional keys: not allowed |
headers.Idempotency-Key | string | Optional | Minimum length: 1 Maximum length: 255 |
body | object | Required within parent | Additional keys: not allowed |
body.expand | array | Optional | Specifies which fields in the response should be expanded. |
body.expand[] | string | Each item | Maximum length: 5000 |
body.link_options | object | Required within parent | Specific fields needed to generate the desired link type. |
body.link_options.apple_terms_and_conditions | object | Optional | |
body.link_options.apple_terms_and_conditions.allow_relinking | boolean | Optional | |
body.link_options.apple_terms_and_conditions.merchant_display_name | string | Required within parent | Maximum length: 5000 |
body.link_type | string | Required within parent | The type of link being generated. One of: apple_terms_and_conditions |
body.on_behalf_of | string | Optional | Stripe account ID to generate the link for. Maximum length: 5000 |
Response
Section titled “Response”Response media type: application/json. The table describes the pinned successful response. Referenced models link to their complete fields.
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | Model | Root | Expand Create an Onboarding Link — response body |
Referenced models: Create an Onboarding Link — response body
Schemas
Section titled “Schemas”Create an Onboarding Link — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Returns redirect links used for onboarding onto Tap to Pay on iPhone. |
link_options | Model | Required within parent | Expand Create an Onboarding Link — response body — link options |
link_type | string | Required within parent | The type of link being generated. Known values: apple_terms_and_conditions |
object | string | Required within parent | Known values: terminal.onboarding_link |
on_behalf_of | JSON | Optional | |
on_behalf_of (anyOf 1) | string | Alternative | Stripe account ID to generate the link for. Maximum length: 5000 |
on_behalf_of (anyOf 2) | null | Alternative | |
redirect_url | string | Required within parent | The link passed back to the user for their onboarding. Maximum length: 5000 |
Referenced models: Create an Onboarding Link — response body — link options
Create an Onboarding Link — response body — link options
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Link type options associated with the current onboarding link object. |
apple_terms_and_conditions | JSON | Optional | |
apple_terms_and_conditions (anyOf 1) | JSON | Alternative | The options associated with the Apple Terms and Conditions link type. |
apple_terms_and_conditions (anyOf 1) (anyOf 1) | Model | Alternative | Expand Create an Onboarding Link — response body — link options apple terms and conditions value allow relinking, merchant display name |
apple_terms_and_conditions (anyOf 2) | null | Alternative |
Referenced models: Create an Onboarding Link — response body — link options apple terms and conditions value allow relinking, merchant display name
Create an Onboarding Link — response body — link options apple terms and conditions value allow relinking, merchant display name
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Options associated with the Apple Terms and Conditions link type. |
allow_relinking | JSON | Optional | |
allow_relinking (anyOf 1) | boolean | Alternative | Whether the link should also support users relinking their Apple account. |
allow_relinking (anyOf 2) | null | Alternative | |
merchant_display_name | string | Required within parent | The business name of the merchant accepting Apple's Terms and Conditions. Maximum length: 5000 |
Policy, approvals and errors
Section titled “Policy, approvals and errors”SDK function policy ID: stripe.postterminalonboardinglinks. Catalog operation: PostTerminalOnboardingLinks. Rules can name either ID; function rules distinguish managed calls and conservatively cover raw calls sharing the route. Existing grant permissions and policy rules apply. wait() returns an immediate result or waits for a required approval; it never approves the request itself. Persist the approval ID to resume after a restart.
Provider errors retain their response; JSON decoding raises ProviderAPIError for provider failures. ManagedOperationError identifies contract/input/retention errors. See error handling and provider-specific behavior. Sensitive input may be refused before approval storage. A decoding error never resubmits a write.
Pinned headers: {"Stripe-Version": "2026-09-30.endive"}