List statements
curl --request GET \
--url https://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statementsimport requests
url = "https://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements', 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://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"items": [
{
"id": "9d4e1f6a-3b2c-4a5d-8e7f-1a2b3c4d5e6f",
"realm": "f495ff0c-ab54-4f99-8e92-ca8682e4de9b",
"organization": "c4bd3f21-dfbd-44e8-8055-68ba15bed410",
"invoice": "0b7c2a44-6f1e-4d3b-9a8e-5c2f1d0e9b7a",
"identifier": "BANK_SLIP_CREATED",
"description": "Boleto da fatura de outubro",
"billingAmount": 15000,
"originalAmount": 15000,
"financialImpactType": "CREDIT",
"status": "DONE",
"effectiveAt": "2026-10-01T09:00:00.000Z",
"createdBy": "5f0c2b1e-8a3d-4e6f-9b7c-2d1a0e9f8c7b",
"updatedBy": "5f0c2b1e-8a3d-4e6f-9b7c-2d1a0e9f8c7b",
"createdAt": "2026-10-01T09:00:00.000Z",
"updatedAt": "2026-10-08T14:32:11.000Z",
"paymentData": {
"pix": {
"emv": "00020101021226870014br.gov.bcb.pix2565qrcode.exemplo.com.br/pix/v2/9d4e1f6a5204000053039865406150.005802BR5913EMPRESA EXEMPLO6009SAO PAULO62070503***6304ABCD",
"dueAt": "2026-10-10T23:59:59.000Z"
},
"bankSlip": {
"digitableLine": "34191790010104351004791020150008291070026000",
"barcode": "34192910700260001790001043510047902015000829",
"dueAt": "2026-10-10T23:59:59.000Z",
"expiresAt": "2026-11-09T23:59:59.000Z"
},
"pixInitiation": {
"paymentUrl": "https://pix.example.com/authorize/9d4e1f6a",
"scheduledTo": "2026-10-10T12:00:00.000Z"
}
},
"external": {
"b3BankSlip": "6711b4c0d8e1a30012b7c9f2",
"b3Pix": "6711b4c0d8e1a30012b7c9f3",
"b3PixBillingInitiationRequest": "6711b4c0d8e1a30012b7c9f4",
"b3PixBillingInitiationRequestItem": "6711b4c0d8e1a30012b7c9f5"
},
"error": {
"code": "PAYMENT_REJECTED",
"detail": "Saldo insuficiente na conta do pagador.",
"description": "O pagamento foi recusado pela instituição do pagador."
}
}
],
"next": "NjcxMWI0YzBkOGUxYTMwMDEyYjdjOWYy"
}{
"traceId": "1-68ee2a1b-3c4d5e6f7a8b9c0d1e2f3a4b",
"code": "INSUFFICIENT_PERMISSIONS",
"origin": "BILLING",
"message": "insufficient permissions"
}{
"traceId": "1-68ee2a1b-3c4d5e6f7a8b9c0d1e2f3a4b",
"code": "INVOICE_NOT_FOUND",
"origin": "BILLING",
"message": "invoice not found"
}{
"traceId": "1-68ee2a1b-3c4d5e6f7a8b9c0d1e2f3a4b",
"code": "BAD_REQUEST",
"origin": "BILLING",
"message": "Bad Request: Your request is invalid or incomplete. Please make sure you are requesting with the right fields.",
"fields": [
{
"field": "limit",
"message": "Too big: expected number to be <=100",
"code": "LIMIT_MAX"
}
]
}List statements
Lists the statements of an invoice, newest first: the amount owed, each payment instrument created for it (boleto, PIX, PIX Automático), the payments received, adjustments and manual settlements.
GET
/
realms
/
{realmId}
/
organizations
/
{organizationId}
/
invoices
/
{invoiceId}
/
statements
List statements
curl --request GET \
--url https://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statementsimport requests
url = "https://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements', 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://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.billing.v2.portao3.com.br/realms/{realmId}/organizations/{organizationId}/invoices/{invoiceId}/statements")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"items": [
{
"id": "9d4e1f6a-3b2c-4a5d-8e7f-1a2b3c4d5e6f",
"realm": "f495ff0c-ab54-4f99-8e92-ca8682e4de9b",
"organization": "c4bd3f21-dfbd-44e8-8055-68ba15bed410",
"invoice": "0b7c2a44-6f1e-4d3b-9a8e-5c2f1d0e9b7a",
"identifier": "BANK_SLIP_CREATED",
"description": "Boleto da fatura de outubro",
"billingAmount": 15000,
"originalAmount": 15000,
"financialImpactType": "CREDIT",
"status": "DONE",
"effectiveAt": "2026-10-01T09:00:00.000Z",
"createdBy": "5f0c2b1e-8a3d-4e6f-9b7c-2d1a0e9f8c7b",
"updatedBy": "5f0c2b1e-8a3d-4e6f-9b7c-2d1a0e9f8c7b",
"createdAt": "2026-10-01T09:00:00.000Z",
"updatedAt": "2026-10-08T14:32:11.000Z",
"paymentData": {
"pix": {
"emv": "00020101021226870014br.gov.bcb.pix2565qrcode.exemplo.com.br/pix/v2/9d4e1f6a5204000053039865406150.005802BR5913EMPRESA EXEMPLO6009SAO PAULO62070503***6304ABCD",
"dueAt": "2026-10-10T23:59:59.000Z"
},
"bankSlip": {
"digitableLine": "34191790010104351004791020150008291070026000",
"barcode": "34192910700260001790001043510047902015000829",
"dueAt": "2026-10-10T23:59:59.000Z",
"expiresAt": "2026-11-09T23:59:59.000Z"
},
"pixInitiation": {
"paymentUrl": "https://pix.example.com/authorize/9d4e1f6a",
"scheduledTo": "2026-10-10T12:00:00.000Z"
}
},
"external": {
"b3BankSlip": "6711b4c0d8e1a30012b7c9f2",
"b3Pix": "6711b4c0d8e1a30012b7c9f3",
"b3PixBillingInitiationRequest": "6711b4c0d8e1a30012b7c9f4",
"b3PixBillingInitiationRequestItem": "6711b4c0d8e1a30012b7c9f5"
},
"error": {
"code": "PAYMENT_REJECTED",
"detail": "Saldo insuficiente na conta do pagador.",
"description": "O pagamento foi recusado pela instituição do pagador."
}
}
],
"next": "NjcxMWI0YzBkOGUxYTMwMDEyYjdjOWYy"
}{
"traceId": "1-68ee2a1b-3c4d5e6f7a8b9c0d1e2f3a4b",
"code": "INSUFFICIENT_PERMISSIONS",
"origin": "BILLING",
"message": "insufficient permissions"
}{
"traceId": "1-68ee2a1b-3c4d5e6f7a8b9c0d1e2f3a4b",
"code": "INVOICE_NOT_FOUND",
"origin": "BILLING",
"message": "invoice not found"
}{
"traceId": "1-68ee2a1b-3c4d5e6f7a8b9c0d1e2f3a4b",
"code": "BAD_REQUEST",
"origin": "BILLING",
"message": "Bad Request: Your request is invalid or incomplete. Please make sure you are requesting with the right fields.",
"fields": [
{
"field": "limit",
"message": "Too big: expected number to be <=100",
"code": "LIMIT_MAX"
}
]
}Statements are the invoice’s financial record: the charges generated for it and the payments made against it. An invoice can be paid with more than one payment method — part by PIX, part by boleto, or a payment received outside Portão 3 — so its statements carry the full list of everything that moved on the invoice, and the invoice’s balance is computed from them.
The balance of the invoice comes from its
DONE statements: what is owed is the sum of billingAmount over the DEBIT ones, and what was paid is the sum over the CREDIT ones. Statements in any other status are listed but do not count yet.
Read the invoice as its issuer (role=VENDOR, the default) or as its payer (role=BUYER, when your organization is the invoice’s payer). Any member of the organization, or an admin of the realm, can list them. Page with limit + next.Path Parameters
ID of your realm.
Format: UUID
ID of your organization: the one that issued the invoice, or the one that pays it when role is BUYER.
Format: UUID
ID of the invoice whose statements you want to list.
Format: UUID
Query Parameters
Page size, 1–100. Defaults to 100.
Required range:
1 <= x <= 100Cursor returned as next by the previous page; it must be valid base64. Omit it for the first page. A valid cursor that no longer matches a statement also returns the first page.
Maximum string length:
128Pattern:
^[A-Za-z0-9+/]+={0,2}$Your side of the invoice. VENDOR (the default): your organization issued it. BUYER: your organization is the invoice's payer.
Available options:
VENDOR, BUYER