# Webhooks

## Webhook triggered on installment status updates

> The platform supports webhook notifications to inform clients of changes in the status of submitted invoice installments.\
> \
> This webhook is triggered whenever a installment status is updated in the anticipation process.\
> \
> To use this feature, you must implement an HTTPS POST endpoint on your system to receive event notifications.\
> Once a webhook is triggered, our platform will send a POST request to the configured URL with the relevant payload.\
> \
> \### Anticipation status:\
> \- \*\*Created\*\*: Invoice installment submitted\
> \- \*\*Updated\*\*: Invoice installment updated\
> \- \*\*Deleted\*\*: Invoice installment deleted\
> \- \*\*Requested\*\*: Anticipation requested\
> \- \*\*Approved\*\*: Anticipation approved\
> \- \*\*Rejected\*\*: Anticipation rejected\
> \- \*\*Cancelled\*\*: Anticipation cancelled\
> \- \*\*Settled\*\*: Anticipation settled\
> \- \*\*Failed\*\*: Invoice installment update failed<br>

```json
{"openapi":"3.0.0","info":{"title":"Financing API","version":"1.0.0"},"servers":[{"url":"https://api.sandbox.trio.com.br","variables":{}},{"url":"https://api.qa.trio.com.br","variables":{}},{"url":"https://api.trio.com.br","variables":{}}],"paths":{"/webhooks/invoice_installments_status_anticipation":{"post":{"summary":"Webhook triggered on installment status updates","description":"The platform supports webhook notifications to inform clients of changes in the status of submitted invoice installments.\n\nThis webhook is triggered whenever a installment status is updated in the anticipation process.\n\nTo use this feature, you must implement an HTTPS POST endpoint on your system to receive event notifications.\nOnce a webhook is triggered, our platform will send a POST request to the configured URL with the relevant payload.\n\n### Anticipation status:\n- **Created**: Invoice installment submitted\n- **Updated**: Invoice installment updated\n- **Deleted**: Invoice installment deleted\n- **Requested**: Anticipation requested\n- **Approved**: Anticipation approved\n- **Rejected**: Anticipation rejected\n- **Cancelled**: Anticipation cancelled\n- **Settled**: Anticipation settled\n- **Failed**: Invoice installment update failed\n","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/invoice_installment"}}}},"responses":{"200":{"description":"Acknowledged"}},"tags":["webhooks"]}}},"components":{"schemas":{"invoice_installment":{"type":"object","required":["issue_date","invoice_number","invoice_series","installment","installment_due_date","installment_amount","document_supplier"],"properties":{"issue_date":{"type":"string","format":"date"},"invoice_number":{"type":"string"},"invoice_series":{"type":"string"},"installment":{"type":"string"},"installment_due_date":{"type":"string","format":"date"},"installment_amount":{"type":"number","format":"float","minimum":0},"document_supplier":{"type":"string"},"anticipation_status":{"type":"string","enum":["Created","Updated","Deleted","Requested","Approved","Rejected","Cancelled","Failed"]},"id":{"type":"string","format":"uuid"},"factoring_payable_id":{"type":"string","format":"uuid"},"stages":{"type":"array","items":{"$ref":"#/components/schemas/stage"}}}},"stage":{"type":"object","required":["anticipation_status","timestamp","error_message","error_code"],"properties":{"anticipation_status":{"type":"string","enum":["Created","Updated","Deleted","Requested","Approved","Rejected","Cancelled","Failed"]},"timestamp":{"type":"string","format":"date"},"error_message":{"type":"string"},"error_code":{"type":"string"}}}}}}
```

## Webhook triggered on factoring payables status updates

> The platform supports webhook notifications to inform clients of changes in the status of submitted factoring payables (Assignment of Receivables).\
> \
> This webhook is triggered whenever a installment status is updated in the anticipation process.\
> \
> To use this feature, you must implement an HTTPS POST endpoint on your system to receive event notifications.\
> Once a webhook is triggered, our platform will send a POST request to the configured URL with the relevant payload.\
> \
> \### Anticipation status:\
> \- \*\*Created\*\*: Factoring payables submitted\
> \- \*\*Updated\*\*: Factoring payables updated\
> \- \*\*Deleted\*\*: Factoring payables deleted\
> \- \*\*Settled\*\*: Factoring payables settled<br>

```json
{"openapi":"3.0.0","info":{"title":"Financing API","version":"1.0.0"},"servers":[{"url":"https://api.sandbox.trio.com.br","variables":{}},{"url":"https://api.qa.trio.com.br","variables":{}},{"url":"https://api.trio.com.br","variables":{}}],"paths":{"/webhooks/factoring_payables_status":{"post":{"summary":"Webhook triggered on factoring payables status updates","description":"The platform supports webhook notifications to inform clients of changes in the status of submitted factoring payables (Assignment of Receivables).\n\nThis webhook is triggered whenever a installment status is updated in the anticipation process.\n\nTo use this feature, you must implement an HTTPS POST endpoint on your system to receive event notifications.\nOnce a webhook is triggered, our platform will send a POST request to the configured URL with the relevant payload.\n\n### Anticipation status:\n- **Created**: Factoring payables submitted\n- **Updated**: Factoring payables updated\n- **Deleted**: Factoring payables deleted\n- **Settled**: Factoring payables settled\n","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/factoring_payable"}}}},"responses":{"200":{"description":"Acknowledged"}},"tags":["webhooks"]}}},"components":{"schemas":{"factoring_payable":{"type":"object","required":["issue_date","document_number","installment","installment_due_date","installment_amount","document_supplier"],"properties":{"document_number":{"type":"string"},"installment":{"type":"string"},"installment_due_date":{"type":"string","format":"date"},"installment_amount":{"type":"number","format":"float","minimum":0},"document_supplier":{"type":"string"},"anticipation_status":{"type":"string","enum":["Created","Updated","Deleted","Settled"]},"hash_brcode":{"type":"string"},"id":{"type":"string","format":"uuid"},"invoice_installment_id":{"type":"string","format":"uuid"}}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.trio.com.br/api_reference/financing-api/webhooks.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
