#Flolosain
1 messages · Page 1 of 1 (latest)
Your payload is wrong. capabilities[card_payments][requested] is a boolean, you're passing a string ('active'): https://stripe.com/docs/api/accounts/create#create_account-capabilities-card_payments-requested
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Thanks but still error when I put "true" : {
"error": {
"code": "parameter_unknown",
"doc_url": "https://stripe.com/docs/error-codes/parameter-unknown",
"message": "Received unknown parameter: capabilities[transfers][enabled]",
"param": "capabilities[transfers][enabled]",
"request_log_url": "https://dashboard.stripe.com/test/logs/req_oXFUF8dKTLYgo9?t=1683881599",
"type": "invalid_request_error"
}
}
Ok, that's a separate issue – an invalid parameter: https://stripe.com/docs/api/accounts/create#create_account-capabilities-transfers
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
I'd recommend checking the API reference rather than just blindly passing parameters until it works
I already try, here is my call :
type=custom&country=FR&email=email@individual.com&business_type=individual&individual[first_name]=Prénom&individual[last_name]=Nom&individual[address][line1]=2 allée clémence royer&individual[address][postal_code]=31300&individual[address][city]=Toulouse&individual[address][state]=FR&individual[address][country]=FR&capabilities[card_payments][requested]=true&capabilities[transfers][requested]=true
And what was the outcome of that API call?
Raw response for the API
Status code 400
{
"error": {
"message": "Connect platforms based in FR must create Custom accounts via account tokens. For documentation on account tokens, see https://stripe.com/docs/connect/account-tokens.",
"request_log_url": "https://dashboard.stripe.com/test/logs/req_kkfnTaO2uVRbNZ?t=1683881780",
"type": "invalid_request_error"
}
}
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
Ok, and what is unclear about that error? You've been using the tokens, so I'm confused how you're back to that
Can you share the payload you used for this call
The payload : type=custom&country=FR&email=email@individual.com&business_type=individual&individual[first_name]=Prénom&individual[last_name]=Nom&individual[address][line1]=2 allée clémence royer&individual[address][postal_code]=31300&individual[address][city]=Toulouse&individual[address][state]=FR&individual[address][country]=FR&capabilities[card_payments][requested]=true&capabilities[transfers][requested]=true
That payload doesn't match with the one we received for this error: https://dashboard.stripe.com/test/logs/req_oXFUF8dKTLYgo9
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
capabilities: {
card_payments: {
requested: "true",
},
transfers: {
enabled: "true",
},
},
Still passing transfers[enabled] which is invalid
Well, you're not passing the account_token you ned to generate as a FR platform: https://stripe.com/docs/connect/account-tokens
OOh ! How to do it with an API call ?
The doc explains this I believe. You need Stripe.js: https://stripe.com/docs/connect/account-tokens#workflow
There is a direct API for this: https://stripe.com/docs/api/tokens/create_account
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Then you need to pass that ct_xxx token when you create the Account via the account_token param: https://stripe.com/docs/connect/account-tokens#create-account
Which is what you're not doing now
No, a parameter in the body as per the link above. See: https://stripe.com/docs/api/accounts/create#create_account-account_token
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
I tried but still doesn't :
{
"error": {
"message": "Parameter 'business_type' cannot be used in conjunction with an account token. To set this field create a token with the desired changes. Pass the token with 'account_token' in a request without setting 'business_type'. See https://stripe.com/docs/connect/account-tokens#updating for more information.",
"param": "business_type",
"request_log_url": "https://dashboard.stripe.com/test/logs/req_4luGqzimuDrLUz?t=1683883605",
"type": "invalid_request_error"
}
}
Did you try removing the business_type parameter in your request like the error indicates?
Yes
{
"error": {
"message": "Parameter 'individual' cannot be used in conjunction with an account token. To set this field create a token with the desired changes. Pass the token with 'account_token' in a request without setting 'individual'. See https://stripe.com/docs/connect/account-tokens#updating for more information.",
"param": "individual",
"request_log_url": "https://dashboard.stripe.com/test/logs/req_ocWApqVqBEv2sP?t=1683883696",
"type": "invalid_request_error"
}
}
The same again, I guess?
Yes again
The issue is you're passing parameters that aren't supported you're using the account_token. You need to omit any parameters relevant to the indiovidual/business as they've already been passed when you created the Account Token
I'd strongly recommend reading https://stripe.com/docs/connect/account-tokens completely as it explains all of this