Create an Account Session ​
Creates a AccountSession object that includes a single-use token that the platform can use on their front-end to grant client-side API access.
Returns ​
Returns an Account Session object if the call succeeded.
Parameters ​
account(string, required) The identifier of the account to create an Account Session for.components(object, required) Each key of the dictionary represents an embedded component, and each embedded component maps to its configuration (e.g. whether it has been enabled or not).components.account_management(object, optional) Configuration for the account management embedded component.components.account_management.enabled(boolean, required) Whether the embedded component is enabled.components.account_management.features(object, optional) The list of features enabled in the embedded component.components.account_management.features.disable_stripe_user_authentication(boolean, optional) Whether Stripe user authentication is disabled. This value can only betruefor accounts wherecontroller.requirement_collectionisapplicationfor the account. The default value is the opposite of theexternal_account_collectionvalue. For example, if you don’t setexternal_account_collection, it defaults totrueanddisable_stripe_user_authenticationdefaults tofalse.components.account_management.features.external_account_collection(boolean, optional) Whether external account collection is enabled. This feature can only befalsefor accounts where you’re responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature istrue.
components.account_onboarding(object, optional) Configuration for the account onboarding embedded component.components.account_onboarding.enabled(boolean, required) Whether the embedded component is enabled.components.account_onboarding.features(object, optional) The list of features enabled in the embedded component.components.account_onboarding.features.disable_stripe_user_authentication(boolean, optional) Whether Stripe user authentication is disabled. This value can only betruefor accounts wherecontroller.requirement_collectionisapplicationfor the account. The default value is the opposite of theexternal_account_collectionvalue. For example, if you don’t setexternal_account_collection, it defaults totrueanddisable_stripe_user_authenticationdefaults tofalse.components.account_onboarding.features.external_account_collection(boolean, optional) Whether external account collection is enabled. This feature can only befalsefor accounts where you’re responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature istrue.
components.balance_report(object, optional) Configuration for the balance report embedded component.components.balance_report.enabled(boolean, required) Whether the embedded component is enabled.components.balance_report.features(object, optional) An empty list, because this embedded component has no features.
components.balances(object, optional) Configuration for the balances embedded component.components.balances.enabled(boolean, required) Whether the embedded component is enabled.components.balances.features(object, optional) The list of features enabled in the embedded component.components.balances.features.disable_stripe_user_authentication(boolean, optional) Whether Stripe user authentication is disabled. This value can only betruefor accounts wherecontroller.requirement_collectionisapplicationfor the account. The default value is the opposite of theexternal_account_collectionvalue. For example, if you don’t setexternal_account_collection, it defaults totrueanddisable_stripe_user_authenticationdefaults tofalse.components.balances.features.edit_payout_schedule(boolean, optional) Whether to allow payout schedule to be changed. Defaults totruewhencontroller.losses.paymentsis set tostripefor the account, otherwisefalse.components.balances.features.external_account_collection(boolean, optional) Whether external account collection is enabled. This feature can only befalsefor accounts where you’re responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature istrue.components.balances.features.instant_payouts(enum, optional) Whether to allow creation of instant payouts. Defaults totruewhencontroller.losses.paymentsis set tostripefor the account, otherwisefalse. Possible enum values:disabledExplicitly disable instant payouts in the component, overriding the platform Dashboard settings.enabledExplicitly enable instant payouts in the component, overriding the platform Dashboard settings. This value is the default for connected accounts where Stripe is responsible for negative balances.use_dashboard_rulesEnable instant payouts in the component according to the platform Dashboard settings. This value is the default for connected accounts where the platform is responsible for negative balances.
components.balances.features.standard_payouts(boolean, optional) Whether to allow creation of standard payouts. Defaults totruewhencontroller.losses.paymentsis set tostripefor the account, otherwisefalse.
components.disputes_list(object, optional) Configuration for the disputes list embedded component.components.disputes_list.enabled(boolean, required) Whether the embedded component is enabled.components.disputes_list.features(object, optional) The list of features enabled in the embedded component.components.disputes_list.features.capture_payments(boolean, optional) Whether to allow capturing and cancelling payment intents. This istrueby default.components.disputes_list.features.destination_on_behalf_of_charge_management(boolean, optional) Whether connected accounts can manage destination charges that are created on behalf of them. This isfalseby default.components.disputes_list.features.dispute_management(boolean, optional) Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This istrueby default.components.disputes_list.features.refund_management(boolean, optional) Whether sending refunds is enabled. This istrueby default.
components.documents(object, optional) Configuration for the documents embedded component.components.documents.enabled(boolean, required) Whether the embedded component is enabled.components.documents.features(object, optional) An empty list, because this embedded component has no features.
components.financial_account(object, optional) Configuration for the financial account embedded component.components.financial_account.enabled(boolean, required) Whether the embedded component is enabled.components.financial_account.features(object, optional) The list of features enabled in the embedded component.components.financial_account.features.disable_stripe_user_authentication(boolean, optional) Whether Stripe user authentication is disabled. This value can only betruefor accounts wherecontroller.requirement_collectionisapplicationfor the account. The default value is the opposite of theexternal_account_collectionvalue. For example, if you don’t setexternal_account_collection, it defaults totrueanddisable_stripe_user_authenticationdefaults tofalse.components.financial_account.features.external_account_collection(boolean, optional) Whether external account collection is enabled. This feature can only befalsefor accounts where you’re responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature istrue.components.financial_account.features.send_money(boolean, optional) Whether to allow sending money.components.financial_account.features.transfer_balance(boolean, optional) Whether to allow transferring balance.
components.financial_account_transactions(object, optional) Configuration for the financial account transactions embedded component.components.financial_account_transactions.enabled(boolean, required) Whether the embedded component is enabled.components.financial_account_transactions.features(object, optional) The list of features enabled in the embedded component.components.financial_account_transactions.features.card_spend_dispute_management(boolean, optional) Whether to allow card spend dispute management features.
components.instant_payouts_promotion(object, optional) Configuration for the instant payouts promotion embedded component.components.instant_payouts_promotion.enabled(boolean, required) Whether the embedded component is enabled.components.instant_payouts_promotion.features(object, optional) The list of features enabled in the embedded component.components.instant_payouts_promotion.features.disable_stripe_user_authentication(boolean, optional) Whether Stripe user authentication is disabled. This value can only betruefor accounts wherecontroller.requirement_collectionisapplicationfor the account. The default value is the opposite of theexternal_account_collectionvalue. For example, if you don’t setexternal_account_collection, it defaults totrueanddisable_stripe_user_authenticationdefaults tofalse.components.instant_payouts_promotion.features.external_account_collection(boolean, optional) Whether external account collection is enabled. This feature can only befalsefor accounts where you’re responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature istrue.components.instant_payouts_promotion.features.instant_payouts(enum, optional) Whether to allow creation of instant payouts. Defaults totruewhencontroller.losses.paymentsis set tostripefor the account, otherwisefalse. Possible enum values:disabledExplicitly disable instant payouts in the component, overriding the platform Dashboard settings.enabledExplicitly enable instant payouts in the component, overriding the platform Dashboard settings. This value is the default for connected accounts where Stripe is responsible for negative balances.use_dashboard_rulesEnable instant payouts in the component according to the platform Dashboard settings. This value is the default for connected accounts where the platform is responsible for negative balances.
components.issuing_card(object, optional) Configuration for the issuing card embedded component.components.issuing_card.enabled(boolean, required) Whether the embedded component is enabled.components.issuing_card.features(object, optional) The list of features enabled in the embedded component.components.issuing_card.features.card_management(boolean, optional) Whether to allow card management features.components.issuing_card.features.card_spend_dispute_management(boolean, optional) Whether to allow card spend dispute management features.components.issuing_card.features.cardholder_management(boolean, optional) Whether to allow cardholder management features.components.issuing_card.features.spend_control_management(boolean, optional) Whether to allow spend control management features.
components.issuing_cards_list(object, optional) Configuration for the issuing cards list embedded component.components.issuing_cards_list.enabled(boolean, required) Whether the embedded component is enabled.components.issuing_cards_list.features(object, optional) The list of features enabled in the embedded component.components.issuing_cards_list.features.card_management(boolean, optional) Whether to allow card management features.components.issuing_cards_list.features.card_spend_dispute_management(boolean, optional) Whether to allow card spend dispute management features.components.issuing_cards_list.features.cardholder_management(boolean, optional) Whether to allow cardholder management features.components.issuing_cards_list.features.disable_stripe_user_authentication(boolean, optional) Whether Stripe user authentication is disabled. This value can only betruefor accounts wherecontroller.requirement_collectionisapplicationfor the account. The default value is the opposite of theexternal_account_collectionvalue. For example, if you don’t setexternal_account_collection, it defaults totrueanddisable_stripe_user_authenticationdefaults tofalse.components.issuing_cards_list.features.spend_control_management(boolean, optional) Whether to allow spend control management features.
components.notification_banner(object, optional) Configuration for the notification banner embedded component.components.notification_banner.enabled(boolean, required) Whether the embedded component is enabled.components.notification_banner.features(object, optional) The list of features enabled in the embedded component.components.notification_banner.features.disable_stripe_user_authentication(boolean, optional) Whether Stripe user authentication is disabled. This value can only betruefor accounts wherecontroller.requirement_collectionisapplicationfor the account. The default value is the opposite of theexternal_account_collectionvalue. For example, if you don’t setexternal_account_collection, it defaults totrueanddisable_stripe_user_authenticationdefaults tofalse.components.notification_banner.features.external_account_collection(boolean, optional) Whether external account collection is enabled. This feature can only befalsefor accounts where you’re responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature istrue.
components.payment_details(object, optional) Configuration for the payment details embedded component.components.payment_details.enabled(boolean, required) Whether the embedded component is enabled.components.payment_details.features(object, optional) The list of features enabled in the embedded component.components.payment_details.features.capture_payments(boolean, optional) Whether to allow capturing and cancelling payment intents. This istrueby default.components.payment_details.features.destination_on_behalf_of_charge_management(boolean, optional) Whether connected accounts can manage destination charges that are created on behalf of them. This isfalseby default.components.payment_details.features.dispute_management(boolean, optional) Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This istrueby default.components.payment_details.features.refund_management(boolean, optional) Whether sending refunds is enabled. This istrueby default.
components.payment_disputes(object, optional) Configuration for the payment disputes embedded component.components.payment_disputes.enabled(boolean, required) Whether the embedded component is enabled.components.payment_disputes.features(object, optional) The list of features enabled in the embedded component.components.payment_disputes.features.destination_on_behalf_of_charge_management(boolean, optional) Whether connected accounts can manage destination charges that are created on behalf of them. This isfalseby default.components.payment_disputes.features.dispute_management(boolean, optional) Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This istrueby default.components.payment_disputes.features.refund_management(boolean, optional) Whether sending refunds is enabled. This istrueby default.
components.payments(object, optional) Configuration for the payments embedded component.components.payments.enabled(boolean, required) Whether the embedded component is enabled.components.payments.features(object, optional) The list of features enabled in the embedded component.components.payments.features.capture_payments(boolean, optional) Whether to allow capturing and cancelling payment intents. This istrueby default.components.payments.features.destination_on_behalf_of_charge_management(boolean, optional) Whether connected accounts can manage destination charges that are created on behalf of them. This isfalseby default.components.payments.features.dispute_management(boolean, optional) Whether responding to disputes is enabled, including submitting evidence and accepting disputes. This istrueby default.components.payments.features.refund_management(boolean, optional) Whether sending refunds is enabled. This istrueby default.
components.payout_details(object, optional) Configuration for the payout details embedded component.components.payout_details.enabled(boolean, required) Whether the embedded component is enabled.components.payout_details.features(object, optional) An empty list, because this embedded component has no features.
components.payout_reconciliation_report(object, optional) Configuration for the payout reconciliation report embedded component.components.payout_reconciliation_report.enabled(boolean, required) Whether the embedded component is enabled.components.payout_reconciliation_report.features(object, optional) An empty list, because this embedded component has no features.
components.payouts(object, optional) Configuration for the payouts embedded component.components.payouts.enabled(boolean, required) Whether the embedded component is enabled.components.payouts.features(object, optional) The list of features enabled in the embedded component.components.payouts.features.disable_stripe_user_authentication(boolean, optional) Whether Stripe user authentication is disabled. This value can only betruefor accounts wherecontroller.requirement_collectionisapplicationfor the account. The default value is the opposite of theexternal_account_collectionvalue. For example, if you don’t setexternal_account_collection, it defaults totrueanddisable_stripe_user_authenticationdefaults tofalse.components.payouts.features.edit_payout_schedule(boolean, optional) Whether to allow payout schedule to be changed. Defaults totruewhencontroller.losses.paymentsis set tostripefor the account, otherwisefalse.components.payouts.features.external_account_collection(boolean, optional) Whether external account collection is enabled. This feature can only befalsefor accounts where you’re responsible for collecting updated information when requirements are due or change, like Custom accounts. The default value for this feature istrue.components.payouts.features.instant_payouts(enum, optional) Whether to allow creation of instant payouts. Defaults totruewhencontroller.losses.paymentsis set tostripefor the account, otherwisefalse. Possible enum values:disabledExplicitly disable instant payouts in the component, overriding the platform Dashboard settings.enabledExplicitly enable instant payouts in the component, overriding the platform Dashboard settings. This value is the default for connected accounts where Stripe is responsible for negative balances.use_dashboard_rulesEnable instant payouts in the component according to the platform Dashboard settings. This value is the default for connected accounts where the platform is responsible for negative balances.
components.payouts.features.standard_payouts(boolean, optional) Whether to allow creation of standard payouts. Defaults totruewhencontroller.losses.paymentsis set tostripefor the account, otherwisefalse.
components.payouts_list(object, optional) Configuration for the payouts list embedded component.components.payouts_list.enabled(boolean, required) Whether the embedded component is enabled.components.payouts_list.features(object, optional) An empty list, because this embedded component has no features.
components.tax_registrations(object, optional) Configuration for the tax registrations embedded component.components.tax_registrations.enabled(boolean, required) Whether the embedded component is enabled.components.tax_registrations.features(object, optional) An empty list, because this embedded component has no features.
components.tax_settings(object, optional) Configuration for the tax settings embedded component.components.tax_settings.enabled(boolean, required) Whether the embedded component is enabled.components.tax_settings.features(object, optional) An empty list, because this embedded component has no features.
curl
curl https://api.stripe.com/v1/account_sessions \
-u "<<YOUR_SECRET_KEY>>" \
-d account={{ACCOUNT_ID}} \
-d "components[account_onboarding][enabled]=true" \
-d "components[payments][enabled]=true" \
-d "components[payouts][enabled]=true" \
-d "components[balances][enabled]=true"Response ​
json
{
"object": "account_session",
"account": "acct_1NkDjjJyhOZfPCWt",
"client_secret": "_OXIKXxEihJokDBnDoe2sgG5OGSO2Q12shKvbeboxpALZGng",
"expires_at": 1693261123,
"livemode": false,
"components": {
"account_management": {
"enabled": false,
"features": {
"external_account_collection": true,
"disable_stripe_user_authentication": false
}
},
"account_onboarding": {
"enabled": true,
"features": {
"external_account_collection": true,
"disable_stripe_user_authentication": false
}
},
"balance_report": {
"enabled": false,
"features": {}
},
"balances": {
"enabled": true,
"features": {
"edit_payout_schedule": false,
"instant_payouts": "disabled",
"standard_payouts": false,
"external_account_collection": true,
"disable_stripe_user_authentication": false
}
},
"documents": {
"enabled": false,
"features": {}
},
"financial_account": {
"enabled": false,
"features": {
"disable_stripe_user_authentication": false,
"external_account_collection": false,
"money_movement": false,
"send_money": false,
"transfer_balance": false
}
},
"financial_account_transactions": {
"enabled": false,
"features": {
"card_spend_dispute_management": false
}
},
"issuing_card": {
"enabled": false,
"features": {
"card_management": false,
"card_spend_dispute_management": false,
"cardholder_management": false,
"spend_control_management": false
}
},
"issuing_cards_list": {
"enabled": false,
"features": {
"card_management": false,
"card_spend_dispute_management": false,
"cardholder_management": false,
"disable_stripe_user_authentication": false,
"spend_control_management": false
}
},
"notification_banner": {
"enabled": false,
"features": {
"external_account_collection": true,
"disable_stripe_user_authentication": false
}
},
"payment_details": {
"enabled": false,
"features": {
"capture_payments": true,
"destination_on_behalf_of_charge_management": false,
"dispute_management": true,
"refund_management": true
}
},
"payments": {
"enabled": true,
"features": {
"capture_payments": true,
"destination_on_behalf_of_charge_management": false,
"dispute_management": true,
"refund_management": true
}
},
"disputes_list": {
"enabled": false,
"features": {
"capture_payments": true,
"destination_on_behalf_of_charge_management": false,
"dispute_management": true,
"refund_management": true
}
},
"payment_disputes": {
"enabled": false,
"features": {
"destination_on_behalf_of_charge_management": false,
"dispute_management": true,
"refund_management": true
}
},
"payouts": {
"enabled": true,
"features": {
"edit_payout_schedule": false,
"instant_payouts": "disabled",
"standard_payouts": false,
"external_account_collection": true,
"disable_stripe_user_authentication": false
}
},
"payouts_list": {
"enabled": false,
"features": {}
},
"tax_registrations": {
"enabled": false,
"features": {}
},
"tax_settings": {
"enabled": false,
"features": {}
},
"instant_payouts_promotion": {
"enabled": false,
"features": {
"disable_stripe_user_authentication": false,
"external_account_collection": true,
"instant_payouts": "disabled"
}
},
"payout_details": {
"enabled": false,
"features": {}
},
"payout_reconciliation_report": {
"enabled": false,
"features": {}
}
}
}