Consultar cobrança
curl --request GET \
--url https://sandbox.4seletpay.com.br/api/v1/charge/{code} \
--header 'Authorization: Bearer <token>' \
--header 'account: <account>'import requests
url = "https://sandbox.4seletpay.com.br/api/v1/charge/{code}"
headers = {
"account": "<account>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {account: '<account>', Authorization: 'Bearer <token>'}
};
fetch('https://sandbox.4seletpay.com.br/api/v1/charge/{code}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.4seletpay.com.br/api/v1/charge/{code}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"account: <account>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://sandbox.4seletpay.com.br/api/v1/charge/{code}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("account", "<account>")
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://sandbox.4seletpay.com.br/api/v1/charge/{code}")
.header("account", "<account>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.4seletpay.com.br/api/v1/charge/{code}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["account"] = '<account>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"mensagem": "Charge found",
"erro": false,
"mensagenserro": [],
"codigoretorno": 200,
"id": "00000000-0000-0000-0000-000000000000",
"data": {
"charge_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"charge_created_at": "11/03/2026 10:00:00",
"account_id": 1,
"code": "pur_abc123xyz",
"value": 199.8,
"charge_value": 199.8,
"coin": "BRL",
"status": "Approved",
"client": {
"code": "cli_abc123",
"name": "João Silva",
"email": "joao@exemplo.com.br",
"documents": [
{
"type": "CPF",
"number": "123.456.789-09",
"default": true
}
],
"phone": [
{
"ddi": "55",
"ddd": "11",
"number": "999999999",
"default": true
}
],
"addresss": [
{
"zipcode": "01310-100",
"street": "Avenida Paulista",
"number": "1000",
"neighborhood": "Bela Vista",
"city": "São Paulo",
"state": "SP"
}
]
},
"orders": [
{
"code": "ord_abc123xyz",
"status": "Approved",
"value": 199.8,
"error_message": null,
"items": [
{
"code": "produto_001",
"name": "Camiseta Premium",
"unitary_value": 99.9,
"quantity": 2
}
],
"charges": [
{
"code": "chg_abc123",
"status": "Approved",
"value": 199.8,
"canceled_amount": 0,
"nsu": "123456789",
"installments": 1,
"attempts": 1,
"payment": {
"code": null,
"copy_paste": null,
"expiration": null,
"payment_type": "CreditCard",
"installments": 1
},
"last_transaction": {
"transaction_id": "txn_abc123",
"type": "Authorization",
"status_code": "00",
"nsu": "123456789",
"event_date": "2026-03-11T10:00:00.000000Z",
"message_acquisition": "Transação autorizada"
},
"historics": [],
"card": {
"id": "card_abc123",
"name": "JOAO SILVA",
"type": "credit",
"number": "411111****1111",
"flag": "visa"
}
}
],
"confirmation_codes": []
}
]
}
}{
"mensagem": "Unauthenticated.",
"erro": true,
"mensagenserro": [],
"codigoretorno": 401,
"id": "00000000-0000-0000-0000-000000000000",
"data": []
}{
"mensagem": "The charge code does not match any charge",
"erro": true,
"mensagenserro": [],
"codigoretorno": 404,
"id": "00000000-0000-0000-0000-000000000000",
"data": []
}Cobranças
Consultar Cobrança
Retorna os detalhes completos de uma cobrança específica pelo seu código. Os dados são cacheados para melhor performance.
GET
/
v1
/
charge
/
{code}
Consultar cobrança
curl --request GET \
--url https://sandbox.4seletpay.com.br/api/v1/charge/{code} \
--header 'Authorization: Bearer <token>' \
--header 'account: <account>'import requests
url = "https://sandbox.4seletpay.com.br/api/v1/charge/{code}"
headers = {
"account": "<account>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {account: '<account>', Authorization: 'Bearer <token>'}
};
fetch('https://sandbox.4seletpay.com.br/api/v1/charge/{code}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.4seletpay.com.br/api/v1/charge/{code}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"account: <account>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://sandbox.4seletpay.com.br/api/v1/charge/{code}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("account", "<account>")
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://sandbox.4seletpay.com.br/api/v1/charge/{code}")
.header("account", "<account>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.4seletpay.com.br/api/v1/charge/{code}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["account"] = '<account>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"mensagem": "Charge found",
"erro": false,
"mensagenserro": [],
"codigoretorno": 200,
"id": "00000000-0000-0000-0000-000000000000",
"data": {
"charge_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"charge_created_at": "11/03/2026 10:00:00",
"account_id": 1,
"code": "pur_abc123xyz",
"value": 199.8,
"charge_value": 199.8,
"coin": "BRL",
"status": "Approved",
"client": {
"code": "cli_abc123",
"name": "João Silva",
"email": "joao@exemplo.com.br",
"documents": [
{
"type": "CPF",
"number": "123.456.789-09",
"default": true
}
],
"phone": [
{
"ddi": "55",
"ddd": "11",
"number": "999999999",
"default": true
}
],
"addresss": [
{
"zipcode": "01310-100",
"street": "Avenida Paulista",
"number": "1000",
"neighborhood": "Bela Vista",
"city": "São Paulo",
"state": "SP"
}
]
},
"orders": [
{
"code": "ord_abc123xyz",
"status": "Approved",
"value": 199.8,
"error_message": null,
"items": [
{
"code": "produto_001",
"name": "Camiseta Premium",
"unitary_value": 99.9,
"quantity": 2
}
],
"charges": [
{
"code": "chg_abc123",
"status": "Approved",
"value": 199.8,
"canceled_amount": 0,
"nsu": "123456789",
"installments": 1,
"attempts": 1,
"payment": {
"code": null,
"copy_paste": null,
"expiration": null,
"payment_type": "CreditCard",
"installments": 1
},
"last_transaction": {
"transaction_id": "txn_abc123",
"type": "Authorization",
"status_code": "00",
"nsu": "123456789",
"event_date": "2026-03-11T10:00:00.000000Z",
"message_acquisition": "Transação autorizada"
},
"historics": [],
"card": {
"id": "card_abc123",
"name": "JOAO SILVA",
"type": "credit",
"number": "411111****1111",
"flag": "visa"
}
}
],
"confirmation_codes": []
}
]
}
}{
"mensagem": "Unauthenticated.",
"erro": true,
"mensagenserro": [],
"codigoretorno": 401,
"id": "00000000-0000-0000-0000-000000000000",
"data": []
}{
"mensagem": "The charge code does not match any charge",
"erro": true,
"mensagenserro": [],
"codigoretorno": 404,
"id": "00000000-0000-0000-0000-000000000000",
"data": []
}Requer o header
account com o código da conta.Authorizations
Token JWT obtido via POST /v1/login. Envie no header Authorization: Bearer <token>.
Headers
Código da conta à qual a operação se aplica
Example:
"acc_abc123xyz"
Path Parameters
Código único da cobrança
Example:
"chg_abc123"
Response
Dados da cobrança retornados com sucesso
Resposta da consulta de cobrança (envelope APIReturnUtil + dados ConsultCharge)
⌘I
