> For the complete documentation index, see [llms.txt](https://synconics.gitbook.io/webhook/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://synconics.gitbook.io/webhook/endpoints/get-a-webhooks/get-a-list-of-specific-webhooks-using-domain-filter.md).

# Get a list of specific webhooks using domain filter

Give a [Domain](https://www.odoo.com/documentation/16.0/developer/reference/backend/orm.html#reference-orm-domains) filter and optionally a list of fields to fetch. By default, it will fetch all the webhooks and relavent fields the current user can read.

**`GET /restapi/1.0/webhooks/?domain={comma_separated_list_of_args}`**

**Request**:

```
GET /restapi/1.0/webhooks?domain=[('model','=','product.product'),('kind','=','on_write')] HTTP/1.1
Host: {your_Odoo_server_url}
```

**Response**:

```
HTTP/1.1 200 OK

{
  'webhook': [
      {
          'id': 7,
          'name': 'Product Update',
          'model': 'product.product',
          'kind': 'on_write',
          'address': 'https://requestbin.net/152eq5l1',
          'format': 'json',
          'language': 'en_US',
          'fields': [],
          'create_date': '2017-11-02 12:15:47',
          'write_date': '2017-11-02 14:12:40'
      }
  ]
}
```

**Query Parameters:**

* **domain** – OPTIONAL. A [search domain](https://www.odoo.com/documentation/16.0/developer/reference/backend/orm.html#reference-orm-domains). Use an empty list to match all webhooks.
* **fields** – OPTIONAL. list of field names to return (default is all fields).
* **offset** – OPTIONAL. Number of results to ignore (default: none)
* **limit** – OPTIONAL. Maximum number of webhooks to return (default: all)
* **order** – OPTIONAL. Sort string
* **count** – OPTIONAL. if True, only counts and returns the number of matching webhooks (default: False)

| Headers and Status Codes | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| ------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Request Headers          | <ul><li><a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-accept">Accept</a> – the response content type depends on <em>Accept</em> header</li><li><a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-authorization">Authorization</a> – The OAuth protocol parameters to authenticate.</li></ul>                                                                                                                                                                            |
| Response Headers         | <ul><li><a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-content-type">Content-Type</a> – this depends on <em>Accept</em> header of request</li></ul>                                                                                                                                                                                                                                                                                                                              |
| Status Codes             | <ul><li><a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-200-ok">200 OK</a> – no error</li><li><a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-404-not-found">404 Not Found</a> – there’s no resource</li><li><a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-401-unauthorized">401 Unauthorized</a> – authentication failed</li><li><a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-403-forbidden">403 Forbidden</a> – if any error raise</li></ul> |

Conversely, picking only six fields deemed interesting.

**Request**:

```
GET /restapi/1.0/webhooks?domain=[('model','=','product.product'),('kind','=','on_write')]&fields=['name', 'model', 'kind', 'address', 'format', 'language']&limit=5 HTTP/1.1
Host: {your_Odoo_server_url}
```

**Response**:

```
HTTP/1.1 200 OK

{
  'webhook': [
      {
          'id': 7,
          'name': 'Product Update',
          'model': 'product.product',
          'kind': 'on_write',
          'address': 'https://requestbin.net/152eq5l1',
          'format': 'json',
          'language': 'en_US'
      }
  ]
}
```

<mark style="color:blue;">**Note**</mark>

<mark style="color:blue;">even if the</mark> <mark style="color:blue;"></mark><mark style="color:blue;"><mark style="color:orange;">`id`<mark style="color:orange;"></mark> <mark style="color:blue;"></mark><mark style="color:blue;">field is not requested, it is always returned</mark>
