API Reference
Outpost exposes REST endpoints through the Next.js API routes for programmatic access to
tickets, accounts, and configuration. All endpoints require authentication.
Authentication
API requests are authenticated via session cookies (for dashboard users) or API keys for
external integrations.
curl -H "Authorization: Bearer YOUR_API_KEY" \
https://your-outpost.com/api/tickets
Tickets
List Tickets
| Method | Path | Description |
| GET | /api/tickets | List tickets with pagination and filters |
Query parameters:
status — Filter by status: open, in_progress, resolved, closed
priority — Filter by priority: critical, high, medium, low
source — Filter by source: discord, slack, teams, github, web
assignee — Filter by assignee user ID
account — Filter by account ID
page — Page number (default: 1)
limit — Items per page (default: 50, max: 100)
Get Ticket
| Method | Path | Description |
| GET | /api/tickets/:id | Get a single ticket with full details |
Create Ticket
| Method | Path | Description |
| POST | /api/tickets | Create a new ticket |
{
"title": "Unable to connect to API",
"description": "Getting 502 errors when calling /api/chat",
"source": "web",
"priority": "high",
"accountId": "acc_123"
}
Update Ticket
| Method | Path | Description |
| PATCH | /api/tickets/:id | Update ticket fields |
Accounts
| Method | Path | Description |
| GET | /api/accounts | List all customer accounts |
| GET | /api/accounts/:id | Get account details with support history |
| POST | /api/accounts | Create a new account |
| PATCH | /api/accounts/:id | Update account details |
Analytics
| Method | Path | Description |
| GET | /api/analytics/overview | Dashboard overview metrics |
| GET | /api/analytics/sla | SLA compliance report |
| GET | /api/analytics/volume | Ticket volume over time |
| GET | /api/analytics/agents | Per-agent performance metrics |
Webhooks
Outpost can send webhooks to external systems when events occur. Configure webhook
endpoints in the dashboard under Settings → Webhooks.
Events
| Event | Description |
| ticket.created | New ticket created from any source |
| ticket.updated | Ticket fields changed (status, priority, assignee) |
| ticket.resolved | Ticket marked as resolved |
| ticket.sla_breach | SLA response or resolution target missed |
| message.created | New message on a ticket |
| account.created | New customer account added |
Webhook Payload
{
"event": "ticket.created",
"timestamp": "2025-01-15T10:30:00Z",
"data": {
"id": "tkt_abc123",
"title": "Unable to connect to API",
"status": "open",
"priority": "high",
"source": "discord"
}
}
Signature verification: All webhook payloads include an
X-Outpost-Signature header containing an HMAC-SHA256 signature. Verify
this against your webhook secret to ensure the payload is authentic.