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

# Webhook client

> Manage webhook endpoints with the Paubox Rails SDK.

The Rails SDK delegates to the `paubox` Ruby gem for webhook management.

```ruby theme={null}
require 'paubox'

Paubox.configure do |config|
  config.api_key = 'YOUR_API_KEY'
end

client = Paubox::Client.new
```

## List webhook endpoints

```ruby theme={null}
endpoints = client.list_webhook_endpoints
```

## Create a webhook endpoint

```ruby theme={null}
endpoint = client.create_webhook_endpoint(
  target_url: 'https://example.com/webhooks/paubox',
  events: ['inbound_mail_received', 'api_mail_log_delivered'],
  signing_key: 'whsec_abc123',
)
```

## Get a webhook endpoint

```ruby theme={null}
endpoint = client.get_webhook_endpoint(42)
```

## Update a webhook endpoint

```ruby theme={null}
endpoint = client.update_webhook_endpoint(42, active: false)
```

## Delete a webhook endpoint

```ruby theme={null}
endpoint = client.delete_webhook_endpoint(42)
```
