# POST /auto-responders

**Resource:** [Auto Responders](./auto-responders.md)  
**MCP tool:** `create_auto_responder`  
**Scopes:** `agent-ops:write`  
**Write operation:** yes

Create or update (upsert by identity) an auto-responder config. identity_kind "phone" needs identity_ref = a phone_numbers.id; "email_config" needs identity_ref = an email_config.id. Defaults: enabled=false, mode="draft" (queues replies for human approval, never auto-sends unless mode="auto_send" is explicitly set).

## Parameters

| Name | In | Type | Required | Description |
|------|----|------|----------|-------------|
| `channel` | body | string | yes |  |
| `identity_kind` | body | string | yes |  |
| `identity_ref` | body | string | yes | phone_numbers.id or email_config.id matching identity_kind |
| `enabled` | body | boolean | no |  |
| `mode` | body | string | no | draft (default) queues for approval; auto_send sends immediately |
| `instructions` | body | string | no |  |
| `tone` | body | string | no |  |
| `knowledge_base_id` | body | string | no |  |
| `business_hours_only` | body | boolean | no |  |
| `config` | body | object | no | What the AI is told about the customer, what it can do, and how it handles each type of inbound. context_modules: array of opportunity, contact, customer_account, products, work_orders, bookings, invoices, a CRM record snapshot funnelled into the draft as reference only (the AI does not proactively volunteer it). tools: object keyed by tool name (lookup_account, work_order_status, check_pricing, check_availability, book_appointment, cancel_booking, reschedule_booking, request_callback, take_message, unsubscribe, create_invoice_payment_link) with { enabled: boolean, requires_approval?: boolean }. requires_approval only applies to write tools (book_appointment, cancel_booking, reschedule_booking, request_callback, take_message, unsubscribe, create_invoice_payment_link) and defaults to true for customer-visible actions; when true the action queues into /settings/approvals instead of executing immediately. triage_actions: object keyed by inbound category (new_enquiry, existing_customer, general_question, booking_request, complaint, billing_account, sales_pitch, vendor_supplier, recruitment_partnership, automated_notification) mapping each to one of auto_respond, escalate, do_nothing — auto_respond drafts a reply, escalate drafts but always queues for approval, do_nothing ignores it. Unset categories use sensible defaults (enquiries auto-respond, complaint/billing escalate, sales pitches/vendor/machine mail do nothing). |
| `require_approval` | body | boolean | no | Optional. Set true to route this write into the approval queue for human review instead of executing it immediately (returns 202 + an approval_id). Works even when your key/token has permission to execute directly. |

## Request example

```bash
curl -X POST   "https://api.trustpager.com/functions/v1/api/v1/auto-responders"   -H "Authorization: Bearer YOUR_API_KEY"   -H "Content-Type: application/json"   -d '{"channel":"...","identity_kind":"...","identity_ref":"..."}'
```

---
Base URL: `https://api.trustpager.com/functions/v1/api/v1` — Auth: `Authorization: Bearer YOUR_API_KEY`