Skip to main content

First request

This page lists the agents of your organization: one authenticated GET, one paginated response. You need an API key in HACKAGENT_API_KEY.

List your agents​

curl -sS https://api.hackagent.dev/agent \
-H "Authorization: Bearer $HACKAGENT_API_KEY"

The response is a page of agents:

{
"count": 1,
"next": null,
"previous": null,
"results": [
{
"id": "3f2b8c1e-5d4a-4e6b-9c7d-1a2b3c4d5e6f",
"name": "Support bot",
"endpoint": "https://agent.example.com/v1",
"agent_type": "OPENAI",
"description": "Customer support assistant, staging deployment.",
"config": {
"name": "gpt-4o-mini",
"connection": {
"provider": "openai",
"type": "OPENAI",
"endpoint": "https://agent.example.com/v1",
"api_key": "${SUPPORT_BOT_API_KEY}"
}
},
"organization": "6a1d4f0e-2b3c-4d5e-8f90-123456789abc",
"organization_detail": {"id": "6a1d4f0e-2b3c-4d5e-8f90-123456789abc", "name": "Example Org"},
"owner": 42,
"owner_detail": null,
"created_at": "2026-11-02T09:30:00Z",
"updated_at": "2026-11-02T09:30:00Z"
}
]
}

An empty organization answers "count": 0 and an empty results. The agent's api_key is a ${NAME} reference to an organization secret, never the key itself: the API refuses literal credentials.

Read every page​

Lists return 10 items per page. next is the full URL of the following page, or null on the last one, so follow it until it runs out:

curl -sS "https://api.hackagent.dev/agent?page=2" \
-H "Authorization: Bearer $HACKAGENT_API_KEY"

Pagination lists the endpoints that take a larger page_size.

If it fails​

You getCheck
401The key and the header; see When authentication fails
404The path: no trailing slash (/agent, not /agent/)
429You hit the rate limit; wait the seconds in Retry-After

Next: follow a campaign from creation to report.