Validar SUCESSO no valor máximo permitido
[JSR-LIM-001] - Validar SUCESSO no valor máximo permitido
Introdução
Este documento descreve as condições necessárias e o fluxo de status para validar sucesso com valor máximo permitido no teste [JSR-LIM-001].
Condições Necessárias
Valores Críticos
| Parâmetro | Valor | Observação |
|---|---|---|
| Limite de transação | R$ 2.000,00 | Definido na etapa 4 (Approve) |
| Limite diário | R$ 2.000,00 | Definido na etapa 4 (Approve) |
| Valor do pagamento PIX | R$ 2.000,00 | Deve ser o mesmo valor do limite |
Status Necessários por Etapa
| Etapa | Requisição | Status Esperado | Observação |
|---|---|---|---|
| 1 | Get Application Token | - | Autenticação bem-sucedida |
| 2 | Enrollment Payment initiation | AWAITING_ACCOUNT_HOLDER_VALIDATION | Enrollment criado |
| 3 | Login | AWAITING_ACCOUNT_HOLDER_VALIDATION | Login bem-sucedido |
| 4 | Approve | AWAITING_ENROLLMENT | Limite definido: R$ 2.000,00 |
| 5 | Callback Payment Initiation | AWAITING_ENROLLMENT | Callback processado |
| 6 | fido-registration-options | - | Opções geradas |
| 7 | fido-registration | AUTHORISED | Enrollment autorizado |
| 8 | payment-initiation | AWAITING_AUTHORISATION | Payment criado |
| 9 | fido-sign-options | - | Opções de assinatura geradas |
| 10 | authorise | AUTHORISED | Payment autorizado |
| 11 | pix | CONSUMED | Sucesso |
Fluxo de Status
┌─────────────────────────────────────────────────────────────┐
│ 1. Enrollment Payment Initiation │
│ Status: AWAITING_ACCOUNT_HOLDER_VALIDATION │
└────────────────────┬────────────────────────────────────── ┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 2. Login + Approve │
│ Status: AWAITING_ENROLLMENT │
│ ⚠️ LIMITE DEFINIDO: R$ 2.000,00 │
└────────────────────┬──────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 3. Callback + FIDO Registration │
│ Status: AUTHORISED │
│ ✅ Enrollment completo e autorizado │
└────────────────────┬──────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 4. Payment Initiation │
│ Status: AWAITING_AUTHORISATION │
│ Valor: R$ 2.000,00 ⚠️ │
└────────────────────┬──────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 5. FIDO Sign + Authorise │
│ Status: AUTHORISED │
│ ✅ Payment autorizado │
└────────────────────┬──────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────┐
│ 6. PIX - Processamento │
│ Status: CONSUMED │
│ ✅ Pix realizado com sucesso │
└─────────────────────────────────────────────────────────────┘
Ponto Críticos
1. Definição do Limite ( Etapa 4 - Approve)
Na requisição Approve, é essencial definir o limite de transação:
{
"limits": {
"transactionLimit": "2000",
"dailyLimit": "2000"
}
}2. Valor do Pagamento (Etapa 8 - payment-initiation e Etapa 11 - pix)
O valor do pagamento deve ser o mesmo valor do limite:
{
"payment": {
"amount": "2000.00", // ⚠️ Valor necessário para testar o limite
"currency": "BRL"
}
}Validação do Sucesso
Resposta Esperada
{
"brandId": "69025598418e4eda09274a0a",
"redirectUrl": "http://localhost:8080/callback",
"enrollment": {
"rp": "pkhadson.github.io",
"platform": "CROSS_PLATFORM",
"enrollmentId": "6915e9514f99d21d6d195a83"
},
"tags": {
"merchant": "8d75198a"
},
"data": {
"loggedUser": {
"document": {
"identification": "71980571015",
"rel": "CPF"
}
},
"creditor": {
"cpfCnpj": "58764789000137",
"personType": "PESSOA_JURIDICA",
"name": "Marco Antonio de Brito"
},
"payment": {
"type": "PIX",
"date": "2025-11-13",
"currency": "BRL",
"amount": "2000.00",
"details": {
"localInstrument": "DICT",
"proxy": "[email protected]",
"creditorAccount": {
"accountType": "CACC",
"ispb": "12345678",
"issuer": "1774",
"number": "1234567890"
}
}
},
"remittanceInformation": ""
},
"applicationId": "68a482d2b3ee755e8bbdec8a",
"journeySessionId": "6915ea124f99d21d6d195a8c",
"paymentInitiationApi": "PAYMENTS_V4",
"tokenId": "6915ea12764d311d6d390c60",
"createdAt": "2025-11-13T14:24:18.222Z",
"updatedAt": "2025-11-13T14:26:10.045Z",
"authorizationUrl": "https://api.opb.ca422f1m.dev.fsapps.app/orgs/visa/auth?client_id=sQ0y5dBf9p1Vvg7HVKkjl&request_uri=urn%3Aietf%3Aparams%3Aoauth%3Arequest_uri%3AwHzLwucKtV2dlq3rLLlYT",
"ofConsentId": "6915ea144f99d21d6d195a8f",
"idempotencyKey": "b16510af-4933-4a5d-98b3-e4f07bf53369",
"id": "6915ea124f99d21d6d195a8d",
"ofPayments": [
{
"paymentInitiationId": "6915ea124f99d21d6d195a8d",
"consentId": "urn:visahml:2a2098f2-817a-4e8e-8d04-d252cb584af5",
"localInstrument": "DICT",
"payment": {
"amount": "2000.00",
"currency": "BRL"
},
"creditorAccount": {
"number": "1234567890",
"accountType": "CACC",
"ispb": "12345678",
"issuer": "1774"
},
"cnpjInitiator": "13935893000109",
"proxy": "[email protected]",
"endToEndId": "E139358932025111318124LTvop2DsrC",
"authorisationFlow": "FIDO_FLOW",
"creationDateTime": "2025-11-13T14:26:12Z",
"debtorAccount": {
"ispb": "12345678",
"issuer": "0001",
"number": "969139",
"accountType": "CACC"
},
"paymentId": "dfeb7cdd-ae54-4c4d-96bd-79c2616f7f62",
"status": "RCVD",
"statusUpdateDateTime": "2025-11-13T14:26:12Z",
"id": "6915ea824f99d21d6d195a94"
}
],
"ofConsent": {
"paymentInitiationId": "6915ea124f99d21d6d195a8d",
"consentId": "urn:visahml:2a2098f2-817a-4e8e-8d04-d252cb584af5",
"organization_id": "c55ceb2e-c9fb-4989-8ed1-39208d6d7951",
"brand_id": "cf4412a8-5b91-4e72-bf70-87b7e07d1344",
"authorization_url": "https://api.opb.ca422f1m.dev.fsapps.app/orgs/visa/auth?client_id=sQ0y5dBf9p1Vvg7HVKkjl&request_uri=urn%3Aietf%3Aparams%3Aoauth%3Arequest_uri%3AwHzLwucKtV2dlq3rLLlYT",
"consent_id": "urn:visahml:2a2098f2-817a-4e8e-8d04-d252cb584af5",
"code_verifier": "xDq7yJpn0X_O-adDYk38ApcSMLcBcWfLKWliopoQAJI",
"nonce": "vnO2x1R4GDUUhJVyQUjXJxXQNcsUkUOi3smzU7_VQ_c",
"state": "6915ea124f99d21d6d195a8d",
"redirect_uri": "https://api-sandbox-wl.openkeys.celcoin.sandbox.fsapps.app/callback",
"scope": "openid consent:urn:visahml:2a2098f2-817a-4e8e-8d04-d252cb584af5 payments",
"consentTerm": 0,
"consentTermUnit": "M",
"creationDateTime": "2025-11-13T14:24:19.000Z",
"creditor": {
"personType": "PESSOA_JURIDICA",
"cpfCnpj": "58764789000137",
"name": "Marco Antonio de Brito"
},
"events": [
{
"date": "2025-11-13T14:24:19.000Z",
"event": "AWAITING_AUTHORISATION"
},
{
"date": "2025-11-13T14:24:20.423Z",
"event": "REDIRECTED"
},
{
"date": "2025-11-13T14:25:23.280Z",
"event": "AUTHORISED"
}
],
"expirationDateTime": "2025-11-13T15:25:23.280Z",
"journey": [],
"kind": "PAYMENT",
"loggedUser": {
"document": {
"identification": "71980571015",
"rel": "CPF"
}
},
"nfc": false,
"organizationLogo": "https://www.celcoin.com.br/img/rede-celcoin-logo.svg",
"organizationName": "Mock Bank Visa Conecta",
"ownerBrandId": "cf4412a8-5b91-4e72-bf70-87b7e07d1344",
"ownerId": "c55ceb2e-c9fb-4989-8ed1-39208d6d7951",
"payment": {
"type": "PIX",
"date": "2025-11-13",
"currency": "BRL",
"amount": "2000.00",
"details": {
"localInstrument": "DICT",
"proxy": "[email protected]",
"creditorAccount": {
"ispb": "12345678",
"issuer": "1774",
"number": "1234567890",
"accountType": "CACC"
}
}
},
"status": "AUTHORISED",
"statusUpdateDateTime": "2025-11-13T14:25:23.280Z",
"transactions": [],
"id": "6915ea144f99d21d6d195a8f"
}
}
Condições para Reproduzir
- ✅ Enrollment deve estar no status AUTHORISED
- ✅ Payment deve estar no status AUTHORISED
- ✅ Limite de transação deve ser 2000
- ✅ Limite diário de transação deve ser 2000
- ✅ Valor do pagamento deve ser exatamente 2000.00
- ✅ Todas as etapas anteriores devem ser executadas com sucesso
Updated 3 days ago