diff --git a/source/includes/invoices/_inv_gerar_boletos.md b/source/includes/invoices/_inv_gerar_boletos.md new file mode 100644 index 0000000..cde505d --- /dev/null +++ b/source/includes/invoices/_inv_gerar_boletos.md @@ -0,0 +1,31 @@ +## Gerar Boletos + +Solicita a criação de boletos para os recebimentos do faturamento + +
+ +
+ +
+
+ PATCH + api/v1/contracts/{contract_id}/invoices/{id}/create_charges +
+
+ + +> Exemplo de Corpo + +```json + "Essa requisição não possui corpo" +``` + +> Exemplo do retorno + +```json + "Não há conteudo de retorno ao gerar os boletos" +``` diff --git a/source/includes/receivables/_rec_confirmar_recebimento.md b/source/includes/receivables/_rec_confirmar_recebimento.md index 3ef3037..5400bc6 100644 --- a/source/includes/receivables/_rec_confirmar_recebimento.md +++ b/source/includes/receivables/_rec_confirmar_recebimento.md @@ -5,7 +5,7 @@ Atualiza a situação do recebimento para recebida.
PATCH - api/v1/contracts/{contract_id}/receivables/{receivable_id}/receive + api/v1/contracts/{contract_id}/receivables/{id}/receive
diff --git a/source/includes/receivables/_rec_desfazer_recebimento.md b/source/includes/receivables/_rec_desfazer_recebimento.md index 5061d36..800c369 100644 --- a/source/includes/receivables/_rec_desfazer_recebimento.md +++ b/source/includes/receivables/_rec_desfazer_recebimento.md @@ -5,7 +5,7 @@ Atualiza a situação do recebimento para a receber.
PATCH - api/v1/contracts/{contract_id}/receivables/{receivable_id}/undo_receipt + api/v1/contracts/{contract_id}/receivables/{id}/undo_receipt
diff --git a/source/includes/receivables/_rec_detalhes.md b/source/includes/receivables/_rec_detalhes.md new file mode 100644 index 0000000..833a71d --- /dev/null +++ b/source/includes/receivables/_rec_detalhes.md @@ -0,0 +1,45 @@ +## Detalhes Recebimento + +Mostra detalhes de um recebimento através de seu id + +
+
+ GET + api/v1/contracts/{contract_id}/receivables/{id} +
+
+ + +> Exemplo de Corpo + +```json + "Essa requisição não possui corpo" +``` + +> Exemplo do retorno + +```json +{ + "receivable": { + "id": 182348, + "invoice_id": 184535, + "due_date": "02/12/2019", + "value": "100.0", + "gross_value": "10000.0", + "payment_value": "0.0", + "received_value": null, + "received_at": null, + "created_at": "10/12/2018 10:55:11 -02:00", + "state": "to_emit", + "payment_gateway_status": null, + "cobrato_charge_id": null, + "cobrato_errors": null, + "finance_receivable_id": null, + "myfinance_sale_id": null, + "finance_entity_id": null, + "myfinance_errors": "Ocorreu um erro ao criar recebível no Myfinance. Verifique os erros: A entidade 57.757.975/0001-86 não foi encontrada no Myfinance. Corrija o faturamento e sincronize.", + "myfinance_receivable_account_id": null, + "billet_url": null + } +} +``` diff --git a/source/includes/receivables/_rec_gerar_boleto.md b/source/includes/receivables/_rec_gerar_boleto.md new file mode 100644 index 0000000..38c76ab --- /dev/null +++ b/source/includes/receivables/_rec_gerar_boleto.md @@ -0,0 +1,31 @@ +## Recriar Boleto + +Solicita a geração de um novo boleto para o recebimento. + +
+ +
+ +
+
+ PATCH + api/v1/contracts/{contract_id}/receivables/{id}/create_charge +
+
+ + +> Exemplo de Corpo + +```json + "Essa requisição não possui corpo" +``` + +> Exemplo do retorno + +```json + "Não há conteudo de retorno ao gerar o boleto" +``` diff --git a/source/includes/webhooks/_charge_creation_error.md b/source/includes/webhooks/_charge_creation_error.md new file mode 100644 index 0000000..a302852 --- /dev/null +++ b/source/includes/webhooks/_charge_creation_error.md @@ -0,0 +1,28 @@ +## Charge_creation_error + +Evento: charge_creation_error + +Objeto: Receivable + +Descrição: +Quando ocorre uma falha na geração ou no registro do boleto de um recebimento + +
+
+ POST +
+
+ + +> Exemplo de Corpo + +```json +{ + "event": "charge_creation_error", + "object_type": "Receivable", + "object_id": "id-do-objeto", + "invoice_id": "id-do-faturamento", + "contract_token": "token-do-contrato", + "contract_id": "id-do-contrato" +} +``` diff --git a/source/includes/webhooks/_charge_creation_success.md b/source/includes/webhooks/_charge_creation_success.md new file mode 100644 index 0000000..10da830 --- /dev/null +++ b/source/includes/webhooks/_charge_creation_success.md @@ -0,0 +1,28 @@ +## Charge_creation_success + +Evento: charge_creation_success + +Objeto: Receivable + +Descrição: +Quando o boleto de um recebimento é registrado com sucesso + +
+
+ POST +
+
+ + +> Exemplo de Corpo + +```json +{ + "event": "charge_creation_success", + "object_type": "Receivable", + "object_id": "id-do-objeto", + "invoice_id": "id-do-faturamento", + "contract_token": "token-do-contrato", + "contract_id": "id-do-contrato" +} +``` diff --git a/source/index.html.md b/source/index.html.md index dc29896..208598b 100644 --- a/source/index.html.md +++ b/source/index.html.md @@ -24,6 +24,8 @@ includes: - webhooks/undo_receival - webhooks/receivement_error - webhooks/change_plan + - webhooks/charge_creation_success + - webhooks/charge_creation_error - organizacoes/organizacoes - organizacoes/org_lista - organizacoes/org_cria @@ -78,6 +80,7 @@ includes: - invoices/inv_bloqueio - invoices/inv_aprova - invoices/inv_apaga + - invoices/inv_gerar_boletos - http_status/http_status - invoices_rules/invoices_rules - invoices_rules/invrule_cria @@ -95,8 +98,10 @@ includes: - invoice_template/invTem_busca - receivables/receivables - receivables/rec_busca + - receivables/rec_detalhes - receivables/rec_confirmar_recebimento - receivables/rec_desfazer_recebimento + - receivables/rec_gerar_boleto - email_templates/email_templates - email_templates/email_templates_list - nfses/nfses