{"openapi":"3.0.3","info":{"title":"Ailos Cobrança API","version":"1.0.0","description":"API para geração e gestão de boletos"},"servers":[{"url":"https://api.exemplo.com"}],"paths":{"/v2/boletos/gerar/boleto/convenios/{numeroConvenio}":{"post":{"summary":"Gerar boleto (síncrono)","parameters":[{"name":"numeroConvenio","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BoletoRequest"}}}},"responses":{"200":{"description":"Boleto gerado","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BoletoResponse"}}}}}}},"/v2/boletos/consultar/boleto/convenios/{numeroConvenio}/{numeroBoleto}":{"get":{"summary":"Consultar boleto","parameters":[{"name":"numeroConvenio","in":"path","required":true,"schema":{"type":"integer"}},{"name":"numeroBoleto","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Dados do boleto","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BoletoResponse"}}}}}}},"/v1/pagadores/cadastrar":{"post":{"summary":"Cadastrar pagador","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Pagador"}}}},"responses":{"200":{"description":"Pagador criado"}}}},"/v1/pagadores/consultar/{numeroInscricao}":{"get":{"summary":"Consultar pagador","parameters":[{"name":"numeroInscricao","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Dados do pagador","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Pagador"}}}}}}}},"components":{"schemas":{"BoletoRequest":{"type":"object","required":["convenioCobranca","documento","emissao","pagador","vencimento","valorBoleto"],"properties":{"convenioCobranca":{"type":"object","required":["codigoCarteiraCobranca"],"properties":{"codigoCarteiraCobranca":{"type":"integer"}}},"documento":{"type":"object","required":["numeroDocumento","especieDocumento"],"properties":{"numeroDocumento":{"type":"integer"},"descricaoDocumento":{"type":"string"},"especieDocumento":{"type":"integer","enum":[1,2,3,4,5,6,7]}}},"emissao":{"type":"object","required":["formaEmissao","dataEmissaoDocumento"],"properties":{"formaEmissao":{"type":"integer","enum":[2,3]},"dataEmissaoDocumento":{"type":"string","format":"date"}}},"pagador":{"$ref":"#/components/schemas/Pagador"},"vencimento":{"type":"object","required":["dataVencimento"],"properties":{"dataVencimento":{"type":"string","format":"date"}}},"valorBoleto":{"type":"object","required":["valorNominal"],"properties":{"valorNominal":{"type":"number","format":"float"}}}}},"Pagador":{"type":"object","required":["entidadeLegal","endereco"],"properties":{"entidadeLegal":{"type":"object","required":["identificadorReceitaFederal","tipoPessoa","nome"],"properties":{"identificadorReceitaFederal":{"type":"string"},"tipoPessoa":{"type":"integer","enum":[1,2]},"nome":{"type":"string"}}},"endereco":{"type":"object","required":["cep","logradouro","bairro","cidade","uf"],"properties":{"cep":{"type":"string"},"logradouro":{"type":"string"},"numero":{"type":"string"},"complemento":{"type":"string"},"bairro":{"type":"string"},"cidade":{"type":"string"},"uf":{"type":"string"}}}}},"BoletoResponse":{"type":"object","properties":{"boleto":{"type":"object","properties":{"documento":{"type":"object","properties":{"numeroDocumento":{"type":"integer"},"nossoNumero":{"type":"string"}}},"valorBoleto":{"type":"object","properties":{"valorOriginalTitulo":{"type":"number"},"valorAtual":{"type":"number"}}},"codigoBarras":{"type":"object","properties":{"codigoBarras":{"type":"string"},"linhaDigitavel":{"type":"string"}}},"pagamento":{"type":"object","properties":{"indicadorPagamento":{"type":"integer"},"dataPagamento":{"type":"string","format":"date-time"}}}}}}}}}}