API Reference
Cobranças · Boletos

Write off a boleto

POST/cobrancas/v2/boletos/{id}/baixar
Base URL: https://bb.mimicr.dev · provider: https://api.hm.bb.com.br

Writes off (cancels) an open boleto. It moves to state 7 (BAIXADO), leaves list A and joins B; the linked Pix can no longer be paid. In Mimicr, BB's 30-minute lock applies here too when turned on.

Scope: cobrancas.boletos-requisicao.

Authorization

Bearer token in the Authorization: Bearer <token> header. See Authentication.

Path parameters

idstringrequired

The boleto's nosso número: 20 digits, 000 + convênio (7) + control number (10). It is the numero returned on registration.

Example: "00031285570031443497"

Query parameters

gw-dev-app-keystringrequired

Your application's key (developer_application_key) in the Developers Portal. In Mimicr, the sandbox's (GET /v1/bb). Without it the gateway answers 403.

Example: "<app-key>"

Body

application/json
numeroConveniointegerrequired

The boleto's convênio.

Example: 3128557

Responses

200Boleto written off.
numeroContratoCobrancastring
dataBaixastring

dd.mm.aaaa

horarioBaixastring

hh:mm:ss

400Convênio not informed or the 30-minute lock (4923876).
errorsobject[]required
Show child attributes
codestringrequired

Code as <codigo>.<versao>.

Example: "4010673.1"
messagestringrequired

Error text.

Example: "Boleto não localizado."
actionstring

How to fix it.

Example: ""
401Missing, invalid or expired token.
statusCodeinteger
Example: 401
errorstring
Example: "Unauthorized"
messagestring
Example: "Bad credentials"
attributesobject
Show child attributes
errorstring
Example: "Bad Credentials"
403Missing or invalid application key (gateway shape), or a token without the operation's scope (Application key is not allowed to call this resource method).
Gateway
detailstring

Gateway error description.

Example: "A chave de aplicacao (AppKey) nao foi informada"
userHelpstring

How to solve it.

errorCodestring
Example: "403"
bbMsgobject
Show child attributes
categoriastring
Example: "SISTEMA"
tipostring
Example: "ERRO"
Escopo
statusCodeinteger
Example: 401
errorstring
Example: "Unauthorized"
messagestring
Example: "Bad credentials"
attributesobject
Show child attributes
errorstring
Example: "Bad Credentials"
404Boleto already written off, paid or non-existent (4923892).
errorsobject[]required
Show child attributes
codestringrequired

Code as <codigo>.<versao>.

Example: "4010673.1"
messagestringrequired

Error text.

Example: "Boleto não localizado."
actionstring

How to fix it.

Example: ""