> ## Documentation Index
> Fetch the complete documentation index at: https://docs.wepayout.co/llms.txt
> Use this file to discover all available pages before exploring further.

# Query

> Query the registered webhook URLs

# Query

This endpoint allows querying the registered webhook URLs. Filtering can only be done using the event field.

* If the event parameter is provided, only the webhooks related to that event will be returned
* If no filter is provided, all registered webhooks will be returned

## Query Parameters

<ParamField query="event" type="string">
  Get a list of webhooks for a specific event type. Currently, only the `onboarding` event is supported.

  Allowed values: `onboarding`
</ParamField>

## Response

Returns an array of webhook objects.

<ResponseField name="array" type="array">
  Array of webhook objects

  <Expandable title="Webhook Object">
    <ResponseField name="event" type="string">
      Type of event that triggers the webhook

      Example: `onboarding`
    </ResponseField>

    <ResponseField name="url" type="string">
      HTTPS endpoint URL that will receive notifications for the specified event

      Example: `https://my-url.requestcatcher.com/test`
    </ResponseField>
  </Expandable>
</ResponseField>

## Request Example

<CodeGroup>
  ```bash cURL theme={null}
  curl --request GET \
    --url 'https://api.sandbox.wepayout.com.br/v2/register/companies/webhooks' \
    --header 'Accept: application/json' \
    --header 'Authorization: Bearer {token}'
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch('https://api.sandbox.wepayout.com.br/v2/register/companies/webhooks', {
    method: 'GET',
    headers: {
      'Accept': 'application/json',
      'Authorization': 'Bearer YOUR_TOKEN'
    }
  });

  const data = await response.json();
  console.log(data);
  ```

  ```python Python theme={null}
  import requests

  url = 'https://api.sandbox.wepayout.com.br/v2/register/companies/webhooks'
  headers = {
      'Accept': 'application/json',
      'Authorization': 'Bearer YOUR_TOKEN'
  }

  response = requests.get(url, headers=headers)
  print(response.json())
  ```
</CodeGroup>

<ResponseExample>
  ```json 200 OK theme={null}
  [
    {
      "event": "onboarding",
      "url": "https://my-url.requestcatcher.com/test"
    }
  ]
  ```
</ResponseExample>
