Pular para o conteúdo principal
POST
Cancel a boleto batch

Autorizações

Authorization
string
header
obrigatório

JWT bearer token issued by the identity provider.

Cabeçalhos

X-Organization-Id
string

Organization the batch belongs to. Required: a request without it, or with a value that is not a canonical UUID, is refused with 400 PBP-0025. A batch of another organization is answered 404, exactly as one that does not exist.

Idempotency-Key
string
obrigatório

Client-supplied idempotency key, a UUID. Required: a request without it, with a value that is not a UUID, or with the nil UUID (00000000-0000-0000-0000-000000000000) is refused with 400 PBP-0012.

Parâmetros de caminho

batch_id
string<uuid>
obrigatório

Batch identifier (UUID), the batchId the creation answered. A value that is not a UUID is refused with 400 PBP-0001.

Exemplo:

"0192a3b4-c5d6-7e8f-9a0b-1c2d3e4f5a6b"

Corpo

application/json
reason
string
obrigatório

Reason for the cancellation, recorded on every item canceled as its cancellationReason. Required: absent, blank once trimmed or longer than 500 characters is refused with 400 PBP-0001, with the same messages as POST /v1/boletos/{id}/cancel.

Exemplo:

"Cobrança emitida em duplicidade"

Resposta

One result per item of the batch, in ascending position: whether this request canceled the item (CANCELED), could not cancel it (NOT_CANCELABLE) or attempted it and was refused (CANCEL_FAILED), and the status of its boleto after the attempt. Canceling only part of a batch is not an error.

batchId
string<uuid>
obrigatório

Batch identifier.

Exemplo:

"0192a3b4-c5d6-7e8f-9a0b-1c2d3e4f5a6b"

items
object[] | null
obrigatório

One result per item of the batch, in ascending position.