Guides
Getting started

Testing in the sandbox

Okto's test CPFs, error triggers, KYC and Face Match outcomes and per-product controlled chaos.

By default, every player with a valid CPF passes KYC and every approved payment ends paid. To exercise the other paths, use the test data from Okto's Swagger, which Mimicr reproduces, or controlled chaos.

Test CPFs

The outcome shows up when the player acts (pays the QR, approves at the bank) or when the withdrawal is processed, 15 seconds after creation, not in the creation response.

CPFKYC statusCode when the player pays or receives
604.184.437-34, 617.750.603-81REGULARnone, approved
186.265.157-40REGULAR_EXPIREDnone, approved
051.375.187-43, 111.090.128-37DECEASED_HOLDER2015 Payment refused due to deceased cpf status
211.115.937-95, 216.183.447-90MINOR2014 Payment refused due to minor cpf status
707.726.010-03NOT_FOUND4202 CPF Rejected on KYC
028.385.850-88, 106.049.566-06REGULARIZATION_PENDING4202
612.445.243-01, 129.748.148-83SUSPENDED4202
031.819.767-76CANCELED_CRAFT4202
453.178.287-91PEP2019 Payment refused due to cpf belonging to pep or sanctioned list
606.594.933-73SANCTIONS2019

Any other valid CPF is treated as REGULAR. CPFs with a wrong check digit are refused at creation with 2001.

Other triggers

ValueWhereOutcome
CPF 021.449.531-04payer2020 Payment rejected due to cpf mismatch validation failed
CPF 001.408.346-99payer2023 Payment refused due to unauthorized bank being used
Account 6349462035540000bankAccounts[].accountNumber, bankAccount.accountNumber or the Pix by Key payerAccount2021 Payment rejected due to account mismatch validation failed
CNPJ keydictKey of Create a withdrawal by keythe withdrawal fails with 2002
Amount above 25000000any amount2018 at creation
Withdrawal above the available balanceCreate a withdrawal by key, Create a manual withdrawal2050 at creation
Same amount and same receiver on the same daywithdrawals1001 at creation
Participant 5439f937-165c-4213-ac50-b10ebe6cb9f9 ("Banco Fora do Ar")Pix Direct and Biometric Pix4133 at creation

By product

ProductWhat the test CPFs do
Classic PixThe deposit ends failed with the code from the table; with isClosedLoop, an approved deposit goes to reviewing
WithdrawalsThe withdrawal ends failed with the code of the CPF in taxId (or of the CPF key)
Automatic PixThe immediate charge fails and the recurrence becomes FAILED
Biometric PixEnrollment validation answers 4131; payments and journeys end failed
Pix DirectThe payment ends failed; refusing at the bank gives 4448 and letting it expire gives 4447
Pix by Key2020 and 2021 (or an account not registered for the CPF, including a player with no accounts) go to reviewing; the other codes, failed
Smart PIXThe journey ends failed; limits of 100000 per payment (4104) and 500000 in total (4134)
Pay and PlayThe payment fails; a CPF in blocked-users gives 4202

Face Match

CPF or actionOutcome
123.456.789-09success
111.444.777-35rejected, 4203 CPF Rejected on the facial recognition
CPF failing KYC (table above, except 2020 and 2023)rejected, 4202
The player gives up on the selfiefailed, 4303 inconclusive face match
Nobody acts within 1 hourexpired

KYC

KYC lookups require the terms to be accepted for the CPF (Accept terms and conditions); without it, 6000. Get basic data returns the status from the table (DECEASED_HOLDER shows as DECEASED; REGULAR_EXPIRED, PEP and SANCTIONS show as REGULAR). The compliance lookup ends REPROVED for PEP, SANCTIONS and NOT_FOUND; the other asynchronous lookups end APPROVED. See Face Match and KYC.

Controlled chaos

Each product has its own failure settings, in the console ("Caos controlado" tab) or at PUT https://api.mimicr.dev/v1/okto/chaos/{key}:

KeyProductCodes allowed in opsFailCode
depositDeposits (classic Pix)4202, 2020, 2021, 2023, 2011
withdrawWithdrawals2006, 2007, 2008, 2050, 2011
by_keyPix by Key4202, 2011, 2023
directPix Direct4450, 4449, 4448, 4447, 4401
automaticAutomatic Pix4450, 4501, 4202, 4401
biometricBiometric Pix4136, 4130, 4134, 4119, 4122
smartSmart PIX4450, 4134, 4202, 4401
pay_and_playPay and Play 2.04202, 2020, 2011
kycKYCnone (API errors, latency and notifications only)
face_matchFace Match4203, 4303
bash
curl --request PUT \
  --url https://api.mimicr.dev/v1/okto/chaos/deposit \
  --header 'Authorization: Bearer mk_...' \
  --header 'Content-Type: application/json' \
  --data '{ "enabled": true, "opsFailRate": 100, "opsFailCode": 2011, "webhookFailRate": 50 }'

With opsFailRate: 100, every deposit that would be paid ends failed with 2011. API errors answer 500, 503 or 429 with Okto's envelope (code 1000) and the X-Mimicr-Chaos header. mock-* endpoints are never affected, and neither are the shared routes (/operator, /transactions/status, GET /transactions). The fields are in Sandbox control.

Remember to turn chaos off at the end of the test: {"enabled": false}.