REST API
The v1 REST API under /api/v1: authentication with API keys and the job endpoints.
The v1 API lives under /api/v1 and authenticates with an API key from server.api_keys:
Shell
curl http://localhost:7420/api/v1/jobs?status=failed -H "X-Sextant-Key: $SEXTANT_KEY"| Method and path | Purpose |
|---|---|
POST /api/v1/jobs |
Enqueue a job |
GET /api/v1/jobs |
List jobs, filter with status |
GET /api/v1/jobs/:id |
Retrieve a job |
POST /api/v1/jobs/:id/requeue |
Requeue a failed job |
Shell
curl -X POST http://localhost:7420/api/v1/jobs \
-H "X-Sextant-Key: $SEXTANT_KEY" -H "Content-Type: application/json" \
-d '{"handler":"send-receipt","payload":{"to":"[email protected]"},"retries":3,"delay":60}'