#xinjin-custom-acct

1 messages · Page 1 of 1 (latest)

normal swallow
#

hello, no webhook as there was nothing created/updated in your Stripe account. Plus your code creates Custom accounts so you would catch it there

shadow dome
#

How can I captcha that?

normal swallow
#

not captcha that

#

catch it

#

like you know your code tries to create a Custom account

#

so your code gets a response, either a Custom Account, or an error

#

that is what I meant

shadow dome
#
          const card = event.data.object
          console.log('card', card)
          if (
            card.charges_enabled &&
            card.requirements.eventually_due.length === 0 &&
            card.requirements.pending_verification.length === 0 &&
            card.external_accounts.total_count > 0
          ) {
            return await this.handleExternalAccountCreated(card)
          }```
#

To confirm all validation worked,

#

I am using. this hook.

#

So in the case of invalid data,

#

it should be failed when submitting user's detail?

normal swallow
#

I'm confused

#

can you re-word your question, I don't understand

shadow dome
#

So I am creating custom stripe connect account.

#

await stripe.accounts.update(accountId, data)

#

I updated with full of detail.

#

In the case of valid data,

shadow dome
#

So, I want to know the case that validation is failed.

normal swallow
#

So, I want to know the case that validation is failed.
yes when validation of any Account or Person information fails, that is reported back on the account.updated event, the Account object is updated with different fields like the requirements hash that tells you what additional verification details are needed

shadow dome
#

Can you send me example of account.update object when validation is failed?

normal swallow
#

it will just send you an account object

#

with fields in the requirements: {} hash

shadow dome
#

It there any fields which is related with validation is failed?

normal swallow
#

there is no one validation

#

there is validation on n number of fields

#

so really you just have to look at the requirements hash and see what fields are required to be collected

shadow dome
#

So only thing I can is to know if validation is finished or not?

#

I can not know if submitted data is not valid?