> For the complete documentation index, see [llms.txt](https://help.enterprise.ledger.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.enterprise.ledger.com/api-documentation/tutorials/api-functionalities/events-via-web-hooks.md).

# Events via web-hooks

Stay informed about events related to accounts, groups, requests, transactions, users, or whitelists by subscribing to web-hooks. Configure notifications using the following example:

{% tabs %}
{% tab title="Bash" %}

```bash
curl --request PUT \
  --url https://api.vault.ledger.com/notifications/configuration \
  --header 'authorization: Bearer {{access_token}}' \
  --header 'content-type: application/json' \
  --header 'x-ledger-workspace: minivault' \
  --data '{
    "all": {
      "webhook": {
        "secret": "secret", 
        "url": "{{notification_endpoint}}"
      }
    }
  }
```

{% endtab %}

{% tab title="JSON" %}

```json
{
  "all": {
    "webhook": {
      "secret": "secret",
      "url": "https://webhook.site/9773a594-4764-4807-8921-100133557f82"
    }
  }
}
```

{% endtab %}
{% endtabs %}

With notification\_endpoint a valid HTTPS endpoint that accepts POST queries with the payload similar too:

```json
{
  "payload_type": "TRANSACTION",
  "event_type": "NEW_TRANSACTION_HAS_BEEN_RECEIVED",
  "id": 260
}
```

For more details on how to use this endpoint please refer to the [API documentation](/api-documentation/reference/api-reference/notifications.md).

Replace `{{notification_endpoint}}` with a valid HTTPS endpoint that accepts POST queries. You'll receive notifications similar to the following payload:

```json
{
  "payload_type": "TRANSACTION",
  "event_type": "NEW_TRANSACTION_HAS_BEEN_RECEIVED",
  "id": 260
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://help.enterprise.ledger.com/api-documentation/tutorials/api-functionalities/events-via-web-hooks.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
