Obter sessão 3DS
curl --request GET \
--url https://api.upag.io/v1/3ds/sessions/{sessionId} \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.upag.io/v1/3ds/sessions/{sessionId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://api.upag.io/v1/3ds/sessions/{sessionId}';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));3D Secure
Obter sessão 3DS
Consulta uma sessão 3D Secure pelo ID
GET
https://api.upag.io
/
v1
/
3ds
/
sessions
/
{sessionId}
Obter sessão 3DS
curl --request GET \
--url https://api.upag.io/v1/3ds/sessions/{sessionId} \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.upag.io/v1/3ds/sessions/{sessionId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://api.upag.io/v1/3ds/sessions/{sessionId}';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));Retorna a sessão, sem o
Campos em Referência.
clientSecret. Uma sessão que passou de expiresAt sem ser finalizada é devolvida como expired.
Permissão: charge.read. Apenas chave secreta (sk_…).
Os exemplos usam o sandbox (
https://api.upag.dev/v1). Em produção use https://api.upag.io/v1 com sk_live_….Endpoint
curl https://api.upag.dev/v1/3ds/sessions/9b7c1e52-3f0a-4d86-a1c4-6e2d8f35b790 \
-H "Authorization: Bearer sk_test_your_api_key"
import { Upag } from 'upag';
const upag = new Upag('sk_test_your_api_key');
const session = await upag.threeDSecure.retrieveSession('9b7c1e52-3f0a-4d86-a1c4-6e2d8f35b790');
Parâmetros
string (uuid)
required
ID da sessão.
Resposta
200 OK
Response
{
"id": "9b7c1e52-3f0a-4d86-a1c4-6e2d8f35b790",
"status": "completed",
"finalAmount": 11016,
"card": "5f0c3d1a-7b2e-4c9d-8a41-0e6f2b9d7c15",
"expiresAt": "2026-09-30T19:06:02.113Z"
}
Erros
| Status | Código | Causa |
|---|---|---|
400 | invalid_params | sessionId não é UUID |
404 | session_not_found | Sessão inexistente ou de outra conta |
404 | not_found | 3D Secure não está habilitado neste ambiente |