Make your first API call
All public requests go through the gateway and use a live or test API key. Create a key in the dashboard and store the secret immediately; it is shown once.
Authentication
Authorization: Bearer oa_test_...
Idempotency-Key: your-stable-request-id
POST /v1/research
curl https://api.openagently.com/v1/research \
-H "Authorization: Bearer $OPENAGENTLY_API_KEY" \
-H "Idempotency-Key: research-42" \
-H "Content-Type: application/json" \
-d '{"query":"Compare project tools for small agencies","depth":"standard","recency":"12-months","outputFormat":"markdown","includeCitations":true}'
POST /v1/extract
{
"template": "product-catalog",
"urls": ["https://example.com/products"],
"outputFormat": "json"
}Allowed templates: company-profile, product-catalog, pricing-page, job-listing, and article-metadata.
GET /v1/tasks/{taskId}
Long tasks return 202 Accepted. Poll this endpoint for status, final output, usage, and customer-visible credits charged.
Signed webhooks
Register the exact HTTPS destination in the dashboard before placing it in webhookUrl. Verify X-OpenAgently-Signature by computing HMAC-SHA256 over {timestamp}.{rawBody} with the secret shown at registration. Reject old timestamps and deduplicate by X-OpenAgently-Delivery-Id.
