---
title: Connector
description: Connector protocol schemas
---

{/* ⚠️  AUTO-GENERATED — DO NOT EDIT. Run build-docs.ts to regenerate. Hand-written docs go in content/docs/guides/. */}

<Callout type="info">
**Source:** `packages/spec/src/api/connector.zod.ts`
</Callout>

## TypeScript Usage

```typescript
import { ErrorCategory, RetryStrategy, WebhookConfig, WebhookEvent } from '@objectstack/spec/api';
import type { ErrorCategory, RetryStrategy, WebhookConfig, WebhookEvent } from '@objectstack/spec/api';

// Validate data
const result = ErrorCategory.parse(data);
```

---

## ErrorCategory

### Allowed Values

* `validation`
* `authentication`
* `authorization`
* `not_found`
* `conflict`
* `rate_limit`
* `server`
* `external`
* `maintenance`


---

## RetryStrategy

### Allowed Values

* `no_retry`
* `retry_immediate`
* `retry_backoff`
* `retry_after`


---

## WebhookConfig

### Properties

| Property | Type | Required | Description |
| :--- | :--- | :--- | :--- |
| **enabled** | `boolean` | ✅ | Enable webhook support |
| **events** | `Object[]` | ✅ | Registered webhook events |
| **deliveryConfig** | `Object` | ✅ | Webhook delivery configuration |
| **registrationEndpoint** | `string` | ✅ | URL path for webhook registration |


---

## WebhookEvent

### Properties

| Property | Type | Required | Description |
| :--- | :--- | :--- | :--- |
| **name** | `string` | ✅ | Webhook event identifier (snake_case) |
| **description** | `string` | ✅ | Human-readable event description |
| **method** | `Enum<'GET' \| 'POST' \| 'PUT' \| 'DELETE' \| 'PATCH' \| 'HEAD' \| 'OPTIONS'>` | ✅ | HTTP method for webhook delivery |
| **payloadSchema** | `string` | ✅ | JSON Schema $ref for the webhook payload |
| **headers** | `Record<string, string>` | optional | Custom headers to include in webhook delivery |
| **security** | `Enum<'hmac_sha256' \| 'basic' \| 'bearer' \| 'api_key'>[]` | ✅ | Supported authentication methods for webhook verification |


---

