## Verify with micro-deposits for setup Use `stripe.verifyMicrodepositsForSetup` in the [Save details for future payments with pre-authorized debit in Canada](/payments/acss-debit/set-up-payment.md) or [Save details for future payments with ACH Direct Debit](/payments/ach-direct-debit/set-up-payment.md) flow to verify a customer's bank account with micro-deposits. It should be only called when [SetupIntent](/api/setup_intents.md) is in the `requires_action` state, and contains a `next_action` field that has a `type` equal to `verify_with_microdeposits`. Refer to our [integration guide](/payments/acss-debit/set-up-payment.md) for more details. > Verification can fail for several reasons. The failure may happen synchronously as a direct error response, or asynchronously through a `payment_intent.payment_failed` webhook event. > Refer to our [integration guide](/payments/acss-debit/accept-a-payment.md) for more details. `stripe.verifyMicrodepositsForSetup` will return a `Promise` which resolves with a result object. This object has either: * `result.setupIntent`: the [SetupIntent](/api/setup_intents) with a `status` of `succeeded`. * `result.error`: an error. Refer to the [API reference](/api#errors) and our [integration guide](/payments/acss-debit/set-up-payment) for all possible errors. **Syntax:** `stripe.verifyMicrodepositsForSetup(...)` - `clientSecret` (string) **required** The [client secret](/api/setup_intents/object.md#setup_intent_object-client_secret) of the `SetupIntent`. - `data` (object) Data to be sent with the request. - `amounts` (array) An array of two positive integers, in *cents*, equal to the values of the micro-deposits sent to the bank account. - `descriptor_code` (string) A six-character code starting with SM present in the microdeposit sent to the bank account. ### Verify with micro-deposits for setup ```js stripe.verifyMicrodepositsForSetup( '{SETUP_INTENT_CLIENT_SECRET}', { amounts: [32, 45], } ).then(function(result) { // Handle result.error or result.setupIntent }); ``` ```es_next const {setupIntent, error} = await stripe.verifyMicrodepositsForSetup( '{SETUP_INTENT_CLIENT_SECRET}', { amounts: [32, 45], } ); // Handle the setupIntent or error ```