#noah_api

1 messages · Page 1 of 1 (latest)

half sapphireBOT
#

👋 Welcome to your new thread!

⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1476766124472402063

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

verbal spire
#

Code block A:

const account = await stripe.v2.core.accounts.create({
    display_name: company.owner.email,
    dashboard: 'none',
    include: ['requirements', 'identity'],
    defaults: {
      responsibilities: {
        fees_collector: 'stripe',
        losses_collector: 'stripe',
      },
    },
    identity: {
      country: country,
      ...(entityType && { entity_type: entityType }),
    },
    configuration: {
      merchant: {
        capabilities: {
          card_payments: { requested: true },
        },
      },
      recipient: {
        capabilities: {
          stripe_balance: {
            stripe_transfers: { requested: true },
          },
        },
      },
    },
  });
#

Code block B:

const account = await stripe.v2.core.accounts.update(accountId, {
    include: ['requirements'],
    identity: {
      attestations: {
        terms_of_service: {
          account: {
            date: new Date().toISOString(),
            ip,
            user_agent: userAgent || 'unknown',
          },
        },
      },
    },
  });

The goal on my end is to have a completely white-labled approach where we dont show stripe branding to users but use stripe via API

lime crystal
#

Hey! Apologies for the delay, do give me some time to catch up!

lime crystal
#

Hey! Apologies for the delay.

The error code "tos_acceptance_on_behalf_not_allowed" indicates that you're trying to accept the Terms of Service (ToS) on behalf of accounts where the requirement collection is owned by Stripe, and this operation is not permitted.

#

If you want the platform to be the one for accepting the TOS, you should set the responsibilities as such:

responsibilities: {
  fees_collector: "application",
  losses_collector: "application",
 requirements_collector: 'application'
},
verbal spire
#

when i try that it says it doesnt exist, i am on the latest version and i cant see it in docs too :(

lime crystal
#

Ah, apologies, I realised that that field is something that is automatically set for you and not something that we can specify in the create call

#

Using those values, stripe will automatically determine who the requirements collector is

#

This is specific to the Accounts V2 API

#

In this case, to create a v2 Account with requirements_collector as the platform, you would have to set:

responsibilities: {
  fees_collector: "application",
  losses_collector: "application",

}

verbal spire
#

I see, so there is no way for me to offer a fully custom experience unless i, the application/platform also takes in all of the risk + costs

is this different on v1?

#

should i use application_custom to offset some of the risk back to the connected account and still let me have the control over requirements collector?

lime crystal
#

For Account V1, if you tried with :

controller: {
stripe_dashboard: {type: 'none'},
fees: {payer: 'stripe'},
losses: {payments: 'stripe'},
requirement_collection: 'application',
},

You would receive the error message: "Invalid controller[fees][payer]: must be one of application or account",

verbal spire
#

oh so we just have to be the losses_collector and keep fees_collector as stripe for us to have requirements_collector as application?

#

or what if i set it to application_custom for losses_collector?

is there any where that we can mix these and see the outcome of requirements_collector?

lime crystal
verbal spire
#

oh okay sorry

so if we want to do API onboarding we can never set fees and losses to both be stripe is what i am understanding here?

lime crystal
#

Yup, let me list down the options and the results of each:

  1. fees_collector: stripe + losses_collector: stripe OR fees_collector: "application" + losses_collector: "stripe"
    Result: requirement_collection:"stripe"

  2. fees_collector: application +losses_collector: application OR fees_collector: application_custom + losses_collector: application
    Result: requirement_collection: "application"

  3. fees_collector: stripe + losses_collector: "application"
    Result: Error will be returned This account configuration is not supported.

#

Apologies for the delat once again, was testing out the different combinations to confirm

verbal spire
#

Thanks so much no need to apologise at all!

I will read through that now :)

half sapphireBOT
#

⛔️ Stripe developers have stepped away for a short while

Please leave your questions here, and we’ll respond as soon as we're back! If you need help urgently, you can contact Stripe support for help.