# API Specification

## Auth
- POST /api/auth/login
- POST /api/auth/refresh
- POST /api/auth/logout
- GET /api/auth/me

## Users
- GET /api/users
- POST /api/users
- GET /api/users/:id
- PATCH /api/users/:id
- DELETE /api/users/:id

## Contacts
- GET /api/contacts
- POST /api/contacts
- POST /api/contacts/import
- POST /api/contacts/export
- GET /api/contacts/:id
- PATCH /api/contacts/:id
- DELETE /api/contacts/:id

## Conversations
- GET /api/conversations
- GET /api/conversations/:id
- PATCH /api/conversations/:id/assign
- PATCH /api/conversations/:id/status
- POST /api/conversations/:id/note

## Messages
- GET /api/messages
- GET /api/messages/:id
- POST /api/messages/send
- POST /api/messages/bulk-send
- POST /api/messages/:id/retry

## Drafts
- GET /api/drafts
- POST /api/drafts
- GET /api/drafts/:id
- PATCH /api/drafts/:id
- POST /api/drafts/:id/approve
- POST /api/drafts/:id/reject
- POST /api/drafts/:id/send

## Campaigns
- GET /api/campaigns
- POST /api/campaigns
- GET /api/campaigns/:id
- PATCH /api/campaigns/:id
- POST /api/campaigns/:id/start
- POST /api/campaigns/:id/pause
- POST /api/campaigns/:id/cancel
- GET /api/campaigns/:id/report

## Templates
- GET /api/templates
- POST /api/templates
- GET /api/templates/:id
- PATCH /api/templates/:id
- POST /api/templates/:id/sync
- POST /api/templates/:id/approve
- POST /api/templates/:id/archive

## Integrations
- GET /api/integrations/whatsapp
- PATCH /api/integrations/whatsapp
- POST /api/integrations/whatsapp/test
- GET /api/integrations/senders
- POST /api/integrations/senders

## Logs
- GET /api/logs/activity
- GET /api/logs/webhooks
- GET /api/logs/jobs

## Dashboard
- GET /api/dashboard/summary
- GET /api/dashboard/message-stats
- GET /api/dashboard/campaign-stats
