Buscar split por ID
curl --request GET \
--url https://api.sandbox.z2pay.com/v1/splits/{id} \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.sandbox.z2pay.com/v1/splits/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.sandbox.z2pay.com/v1/splits/{id}"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"id": "spl_rja7dpb3xfyccdg7ukuicd0am",
"name": "Split padrão produtores",
"config": [
{
"recipientId": "rec_tazseadvfg6aym95njwzvc6fs",
"type": "sale",
"value": 80,
"valueType": "percentage",
"processingFee": true,
"liable": true
},
{
"recipientId": "rec_guuh4ppadxc0n47i82fuseq5u",
"type": "sale",
"value": 20,
"valueType": "percentage",
"processingFee": false,
"liable": false
}
],
"salesKey": "SALES-2025-ABC",
"checkoutId": "chk_yi65vojl1sh936l7b93tdg8ix",
"isActive": true,
"createdAt": "2025-06-29T13:45:30.000Z",
"updatedAt": "2025-06-29T13:45:30.000Z"
}{
"error": {
"code": "UNAUTHORIZED",
"message": "Invalid API key"
}
}{
"error": {
"code": "NOT_FOUND",
"message": "Split not found"
}
}Splits
Buscar split por ID
Retorna uma configuração de divisão e as regras que ela carrega.
GET
/
splits
/
{id}
Buscar split por ID
curl --request GET \
--url https://api.sandbox.z2pay.com/v1/splits/{id} \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.sandbox.z2pay.com/v1/splits/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.sandbox.z2pay.com/v1/splits/{id}"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"id": "spl_rja7dpb3xfyccdg7ukuicd0am",
"name": "Split padrão produtores",
"config": [
{
"recipientId": "rec_tazseadvfg6aym95njwzvc6fs",
"type": "sale",
"value": 80,
"valueType": "percentage",
"processingFee": true,
"liable": true
},
{
"recipientId": "rec_guuh4ppadxc0n47i82fuseq5u",
"type": "sale",
"value": 20,
"valueType": "percentage",
"processingFee": false,
"liable": false
}
],
"salesKey": "SALES-2025-ABC",
"checkoutId": "chk_yi65vojl1sh936l7b93tdg8ix",
"isActive": true,
"createdAt": "2025-06-29T13:45:30.000Z",
"updatedAt": "2025-06-29T13:45:30.000Z"
}{
"error": {
"code": "UNAUTHORIZED",
"message": "Invalid API key"
}
}{
"error": {
"code": "NOT_FOUND",
"message": "Split not found"
}
}GET /splits/:id
Faz parte do recurso Splits — as regras de validação do array config estão lá.
Devolve a configuração com o array config completo: quem recebe, quanto, e quem carrega a taxa e o
risco de chargeback.
Isto é a regra, não o que foi pago. A configuração pode ter sido alterada depois de uma venda,
e o que cada recebedor efetivamente recebeu está na transação, não aqui. Para auditar dinheiro,
parta da transação.
A resposta não diz se os recebedores continuam aptos. O
config guarda os rec_ como estavam
na criação; se um deles perdeu a aptidão depois, a configuração continua igual e é a cobrança
que passa a falhar. Ver GET /recipients.Exemplo
curl https://api.sandbox.z2pay.com/v1/splits/spl_t8k3nzc1qvre6y0wjaxm5fdbh \
-H "x-api-key: SUA_CHAVE_DE_SANDBOX"
Resposta 200
{
"id": "spl_t8k3nzc1qvre6y0wjaxm5fdbh",
"name": "Marketplace — 80/20",
"isActive": true,
"salesKey": null,
"checkoutId": null,
"config": [
{
"recipientId": "rec_v57bi6ruyolouw3cpaq2ofy1k",
"value": 80,
"valueType": "percentage",
"type": "sale",
"processingFee": true,
"liable": true
},
{
"recipientId": "rec_h2q8dm4xzkw05rbvtsc7jyneo",
"value": 20,
"valueType": "percentage",
"type": "sale",
"processingFee": false,
"liable": false
}
],
"createdAt": "2026-08-11T12:00:00.000Z",
"updatedAt": "2026-08-11T12:00:00.000Z"
}
Response
Dados do split