Skip to content

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.

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 os
from alter_sdk import App
from 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()
FieldTypePresenceDescription and constraints
$objectRootAdditional keys: not allowed
headersobjectOptionalAdditional keys: not allowed
headers.Idempotency-KeystringOptionalMinimum length: 1
Maximum length: 255
bodyobjectRequired within parentAdditional keys: not allowed
body.expandarrayOptionalSpecifies which fields in the response should be expanded.
body.expand[]stringEach itemMaximum length: 5000
body.link_optionsobjectRequired within parentSpecific fields needed to generate the desired link type.
body.link_options.apple_terms_and_conditionsobjectOptional
body.link_options.apple_terms_and_conditions.allow_relinkingbooleanOptional
body.link_options.apple_terms_and_conditions.merchant_display_namestringRequired within parentMaximum length: 5000
body.link_typestringRequired within parentThe type of link being generated.
One of: apple_terms_and_conditions
body.on_behalf_ofstringOptionalStripe account ID to generate the link for.
Maximum length: 5000

Response media type: application/json. The table describes the pinned successful response. Referenced models link to their complete fields.

FieldTypePresenceDescription and constraints
$ModelRootExpand Create an Onboarding Link — response body

Referenced models: Create an Onboarding Link — response body

Create an Onboarding Link — response body
FieldTypePresenceDescription and constraints
$objectRootReturns redirect links used for onboarding onto Tap to Pay on iPhone.
link_optionsModelRequired within parentExpand Create an Onboarding Link — response body — link options
link_typestringRequired within parentThe type of link being generated.
Known values: apple_terms_and_conditions
objectstringRequired within parentKnown values: terminal.onboarding_link
on_behalf_ofJSONOptional
on_behalf_of (anyOf 1)stringAlternativeStripe account ID to generate the link for.
Maximum length: 5000
on_behalf_of (anyOf 2)nullAlternative
redirect_urlstringRequired within parentThe 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
FieldTypePresenceDescription and constraints
$objectRootLink type options associated with the current onboarding link object.
apple_terms_and_conditionsJSONOptional
apple_terms_and_conditions (anyOf 1)JSONAlternativeThe options associated with the Apple Terms and Conditions link type.
apple_terms_and_conditions (anyOf 1) (anyOf 1)ModelAlternativeExpand Create an Onboarding Link — response body — link options apple terms and conditions value allow relinking, merchant display name
apple_terms_and_conditions (anyOf 2)nullAlternative

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
FieldTypePresenceDescription and constraints
$objectRootOptions associated with the Apple Terms and Conditions link type.
allow_relinkingJSONOptional
allow_relinking (anyOf 1)booleanAlternativeWhether the link should also support users relinking their Apple account.
allow_relinking (anyOf 2)nullAlternative
merchant_display_namestringRequired within parentThe business name of the merchant accepting Apple's Terms and Conditions.
Maximum length: 5000

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"}

Official provider source

Report an issue with this page

Necessary

Required for sign-in, security, authorization, and remembering your choices.

Always active

Analytics

Helps us understand which product and documentation features are useful.

Performance diagnostics

Uses performance tracing and privacy-masked session replay to diagnose problems.

You can change these choices at any time from Cookie settings.