Testing Stripe Connect

    Before going live, use the following information to test your Connect integration.

    Testing topics:

    Testing payouts

    For Express and Custom accounts, use the following test bank and debit card numbers to trigger certain events during testing of payouts. These values can only be used when creating or updating Custom accounts via the API in test mode or with Express in test mode.

    To create test mode payouts for a Standard Stripe account, use any valid bank account details (e.g., your own). Test mode payouts simulate a live payout but are not processed with the bank.

    Test mode always has payouts enabled, as long as valid external bank information and other relevant conditions are met, and never requires real identity verification or other interactive steps that are part of the Custom account workflow.

    Bank numbers

    Sort Account Type
    108800 00012345 Payout succeeds.
    108800 11111116 Payout fails with a no_account code.
    108800 11111113 Payout fails with an account_closed code.
    108800 22222227 Payout fails with an insufficient_funds code.
    108800 33333335 Payout fails with a debit_not_authorized code.
    108800 44444440 Payout fails with an invalid_currency code.
    Routing Account Type
    110-000 000123456 Payout succeeds.
    110-000 111111116 Payout fails with a no_account code.
    110-000 111111113 Payout fails with an account_closed code.
    110-000 222222227 Payout fails with an insufficient_funds code.
    110-000 333333335 Payout fails with a debit_not_authorized code.
    110-000 444444440 Payout fails with an invalid_currency code.

    By specifying the appropriate country code (e.g., DE, IT, FR, etc.), you can use these test IBANs for any EU country and any valid currency for that country. As a demonstration, the IBANs displayed below are specified for Germany since they’re prefixed with DE.

    Number Type
    DE89370400440532013000 Payout succeeds.
    DE62370400440532013001 Payout fails with a no_account code.
    DE89370400440532013002 Payout fails with an account_closed code.
    DE89370400440532013003 Payout fails with an insufficient_funds code.
    DE89370400440532013004 Payout fails with a debit_not_authorized code.
    DE89370400440532013005 Payout fails with an invalid_currency code.
    Account Type
    1100000000000010 Payout succeeds.
    1100001111111016 Payout fails with a no_account code.
    1100001111111013 Payout fails with an account_closed code.
    1100002222222027 Payout fails with an insufficient_funds code.
    1100003333333035 Payout fails with a debit_not_authorized code.
    1100004444444040 Payout fails with an invalid_currency code.
    Routing Account Type
    110000 000123456 Payout succeeds.
    110000 111111116 Payout fails with a no_account code.
    110000 111111113 Payout fails with an account_closed code.
    110000 222222227 Payout fails with an insufficient_funds code.
    110000 333333335 Payout fails with a debit_not_authorized code.
    110000 444444440 Payout fails with an invalid_currency code.
    Routing Account Type
    110-0000 000123456789 Payout succeeds.
    110-0000 000111111116 Payout fails with a no_account code.
    110-0000 000111111113 Payout fails with an account_closed code.
    110-0000 000222222227 Payout fails with an insufficient_funds code.
    110-0000 000333333335 Payout fails with a debit_not_authorized code.
    110-0000 000444444440 Payout fails with an invalid_currency code.
    Routing Account Type
    11000-000 000123456789 Payout succeeds.
    11000-000 000111111116 Payout fails with a no_account code.
    11000-000 000111111113 Payout fails with an account_closed code.
    11000-000 000222222227 Payout fails with an insufficient_funds code.
    11000-000 000333333335 Payout fails with a debit_not_authorized code.
    11000-000 000444444440 Payout fails with an invalid_currency code.
    Routing Account Type
    1100000 0001234 Payout succeeds.
    1100000 1111116 Payout fails with a no_account code.
    1100000 1111113 Payout fails with an account_closed code.
    1100000 2222227 Payout fails with an insufficient_funds code.
    1100000 3333335 Payout fails with a debit_not_authorized code.
    1100000 4444440 Payout fails with an invalid_currency code.
    Routing Account Type
    000000001234567897 Payout succeeds.
    000000111111111117 Payout fails with a no_account code.
    000000111111111133 Payout fails with an account_closed code.
    000000222222222224 Payout fails with an insufficient_funds code.
    000000333333333331 Payout fails with a debit_not_authorized code.
    000000444444444448 Payout fails with an invalid_currency code.
    Routing Account Type
    TESTMYKL 000123456000 Payout succeeds.
    TESTMYKL 111111111116 Payout fails with a no_account code.
    TESTMYKL 111111111113 Payout fails with an account_closed code.
    TESTMYKL 222222222227 Payout fails with an insufficient_funds code.
    TESTMYKL 333333333335 Payout fails with a debit_not_authorized code.
    TESTMYKL 444444444440 Payout fails with an invalid_currency code.
    Routing Account Type
    1100-000 000123456 Payout succeeds.
    1100-000 111111116 Payout fails with a no_account code.
    1100-000 111111113 Payout fails with an account_closed code.
    1100-000 222222227 Payout fails with an insufficient_funds code.
    1100-000 333333335 Payout fails with a debit_not_authorized code.
    1100-000 444444440 Payout fails with an invalid_currency code.
    Routing Account Type
    110000000 000123456789 Payout succeeds.
    110000000 000111111116 Payout fails with a no_account code.
    110000000 000111111113 Payout fails with an account_closed code.
    110000000 000222222227 Payout fails with an insufficient_funds code.
    110000000 000333333335 Payout fails with a debit_not_authorized code.
    110000000 000444444440 Payout fails with an invalid_currency code.

    Debit card numbers

    Use these test debit card numbers to test payouts to a debit card. These can only be used with test secret keys.

    Number Token Type
    5200828282828210 tok_mastercard_debit_transferSuccess Mastercard debit. Payout succeeds.
    4000056655665556 tok_visa_debit_transferSuccess Visa debit. Payout succeeds.
    4000056655665564 tok_visa_debit_transferFail Visa debit. Payout fails with a could_not_process code.

    Creating accounts

    You can create any type of test account you need: Standard, Express, or Custom. You can also create multiple test accounts, e.g., representing multiple countries.

    To test the OAuth flow for connecting another account, create a new Stripe account using another email address and then take that new account through the OAuth flow. This works for both Standard and Express accounts.

    To test Express accounts without providing a real phone number, use 000 000 0000 as the phone number and 000-000 as the SMS code when prompted.

    You can create Custom test accounts using the code on the Custom Accounts page. The account does not need to be activated because it can’t be used for live charges.

    Using OAuth

    To easily test an OAuth integration, the development client_id allows you to:

    • Set your redirect_uri to a non-HTTPS URL
    • Set your redirect_uri to localhost
    • Force-skip the account form instead of having to fill out an entire account application (Standard accounts only)
    • Get test access tokens for connected users

    You’ll be able to find your development client_id in your connect settings.

    Testing Top-ups

    To test Top-ups in the Dashboard, enable test mode and select the desired test bank account in the drop-down menu within the top-up dialog. You can simulate a successful top-up or a top-up that fails due to insufficient funds.

    To test Top-ups in the API, use the following test bank tokens as the top-up source while in test mode. Each token simulates a specific kind of event.

    Token Type
    btok_us_verified Top-up succeeds
    btok_us_verified_noAccount Top-up fails with a no_account code
    btok_us_verified_accountClosed Top-up fails with an account_closed code
    btok_us_verified_insufficientFunds Top-up fails with an insufficient_funds code
    btok_us_verified_debitNotAuthorized Top-up fails with a debit_not_authorized code
    btok_us_verified_invalidCurrency Top-up fails with an invalid_currency code

    Generating test keys for live applications

    When using an access_token derived via the OAuth flow, you can only generate test access tokens using a development client_id, but may generate either live or test access tokens using a production client_id.

    To generate a test access token for a production client_id, use a refresh_token:

    curl https://connect.stripe.com/oauth/token \
      -u sk_test_4eC39HqLyjWDarjtT1zdp7dc: \
      -d client_secret=sk_test_4eC39HqLyjWDarjtT1zdp7dc \
      -d refresh_token=REFRESH_TOKEN \
      -d grant_type=refresh_token
    

    Note that it’s still preferable to authenticate using the Stripe-Account header, not an access token.

    Identity and address verification

    When creating test accounts to simulate identity verification, uploading any image results in the user being verified (whether the image is of an ID or not). Alternatively, for testing Custom accounts only, Stripe created two sample images you can use instead of uploading your own test IDs. These images do not work for testing Express accounts.

    • A verified image that causes the user to be automatically marked verified
    • An unverified image that causes the user to be automatically marked unverified

    For details, refer to Uploading a file.

    If you prefer, you can use sample file tokens instead of uploading images to simulate identity verification.

    If your platform has connected accounts in different countries or plans to, depending on the country, you might need to verify a person’s address as well as their identity. Stripe provides a sample date of birth (DOB) and sample addresses so that you can test for this requirement. For testing purposes, you can use the aforementioned verified and unverified images for the verification.document and verification.additional_document fields. Below is a listing of events you can simulate.

    • A verified date of birth and verified address that causes the user to be marked as verified.
    • A verified date of birth and unverified address that causes the user to be marked as unverified and verification.additional_document becomes required. You can view the requirement with the currently_due array.
    • An unverified date of birth and verified address that causes the user to be marked as unverified and verification.document becomes required. You can view the requirement with the currently_due array.
    • An unverified date of birth and unverified address that causes the user to be marked as unverified and both verification.document and verification.additional_document become required. You can view these requirements with the currently_due array.

    Trigger cards

    Use these card numbers on a charge to trigger various conditions when testing tiered verification.

    Number Token Type
    4000000000004202 tok_visa_triggerVerification Trigger a verification.
    4000000000004210 tok_visa_triggerChargeBlock Triggers a charge block.
    4000000000004236 tok_visa_triggerTransferBlock Triggers a payout block.

    Test file tokens

    Use these file tokens to trigger certain identity verification conditions.

    Token Type
    file_identity_document_success Uses the verified image and marks that document requirement as satisfied.
    file_identity_document_failure Uses the unverified image and marks that document requirement as not satisfied.

    Test dates of birth

    Use these dates of birth (DOB) to trigger certain verification conditions.

    Number Type
    1901-01-01 Successful verification. Any other DOB results in unsuccessful verification.
    19000101This DOB will trigger an Office of Foreign Assets Control (OFAC) alert.

    Test addresses

    Use these addresses for line1 to trigger certain verification conditions.

    Number Type
    address_full_match Successful verification.
    address_no_match Unsuccessful verification.

    Test personal ID numbers

    Use these personal ID numbers for individual[id_number] or the id_number attribute on the Person object to trigger certain verification conditions.

    Number Type
    000000000Successful verification. 0000 also works for SSN last 4 verification.
    111111111Unsuccessful verification (identity mismatch)

    Test business tax IDs

    Use these business tax ID numbers for company[tax_id] to trigger certain verification conditions.

    Number Type
    000000000Successful verification
    000000001Successful verification as a non-profit
    111111111Unsuccessful verification (identity mismatch)

    Business address validation

    In some countries, the business address associated with your connected account must be validated before charges, payouts, or both can be enabled on the account. Stripe provides sample values so that you can test for this user onboarding requirement.

    Test business addresses

    When passing values for the city, state, and postal_code arguments (they can be any value for testing), use these addresses for line1 to trigger certain validation conditions.

    Number Type
    address_full_match Both charges and payouts are enabled on the account.
    address_line1_no_match Only charges are enabled on the account. Since validation failed on the line1 attribute, it becomes listed again in the requirements hash.
    address_no_match Both charges and payouts are not enabled on the account. Since validation failed, the address attributes become listed again in the requirements hash.

    Was this page helpful?

    Thank you for helping improve Stripe's documentation. If you need help or have any questions, please consider contacting support.

    On this page