Developer Reference
Integrate Amajoni AI agent security data into your SIEM, SOAR, CI/CD pipelines, and compliance dashboards. All endpoints are authenticated, rate-limited, and return JSON.
All requests require an X-API-Key header containing your API key. Keys are created in Settings → API Keys and are only shown once at creation time.
curl https://amajoni-production.up.railway.app/v1/posture \ -H "X-API-Key: amj_your_key_here"
Rate limiting
60 requests per minute per API key. Exceeded requests receive HTTP 429 with aRetry-After: 60 header.
List endpoints return a paginated envelope. Single-resource endpoints return the object directly. Errors always include an error object.
// List response
{
"object": "list",
"data": [ ... ],
"meta": { "total": 42, "limit": 50, "offset": 0, "has_more": false }
}
// Error response
{
"error": { "code": "not_found", "message": "Agent 'xyz' not found." }
}/v1/agentsList agents
Returns all AI agents discovered in your cloud environment, sorted by blast radius descending. Supports filtering by risk level, cloud provider, environment, and internet exposure.
Query Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| limit | integer | No | Number of results (1–100, default 50) |
| offset | integer | No | Number of results to skip for pagination |
| risk_level | string | No | Filter: critical | high | medium | low |
| cloud | string | No | Filter by cloud provider: AWS | GCP | Azure |
| environment | string | No | Filter by environment: production | staging | development |
| is_internet_exposed | boolean | No | Filter to internet-exposed agents only |
curl "https://amajoni-production.up.railway.app/v1/agents?risk_level=critical&limit=10" \ -H "X-API-Key: amj_your_key_here"
/v1/agents/{id}Get a single agent
Returns full detail for one AI agent by its UUID, including permissions, signals, governance fields, and blast radius.
curl https://amajoni-production.up.railway.app/v1/agents/550e8400-e29b-41d4-a716-446655440000 \ -H "X-API-Key: amj_your_key_here"
/v1/agents/{id}Update agent governance fields
Update ownership, team, approval status, tags, or review cadence for an agent. Only the fields you include are changed. When approval_status is set to 'approved', last_reviewed_at is automatically set to now.
Request Body Fields
| Field | Type | Description |
|---|---|---|
| owner_name | string | Full name of the human owner |
| owner_email | string | Email address of the owner |
| team | string | Team or cost centre name |
| approval_status | string | approved | pending_review | unreviewed | rejected |
| tags | string[] | Array of free-text labels |
| review_cadence_days | integer | Days between required reviews (default 90) |
curl -X PATCH \
https://amajoni-production.up.railway.app/v1/agents/550e8400-e29b-41d4-a716-446655440000 \
-H "X-API-Key: amj_your_key_here" \
-H "Content-Type: application/json" \
-d '{ "owner_name": "Jane Smith", "team": "ML Platform", "approval_status": "approved" }'/v1/agents/bulkBulk update agent governance fields
Apply the same governance changes to up to 100 agents in a single request. Useful for SOAR runbooks and CI/CD pipelines that deploy batches of agents. Agents not owned by your org are silently skipped.
Request Body Fields
| Field | Type | Description |
|---|---|---|
| agent_ids | string[] | List of agent UUIDs to update (max 100) |
| updates | object | Governance fields to apply (same as PATCH /v1/agents/{id}) |
curl -X POST \
https://amajoni-production.up.railway.app/v1/agents/bulk \
-H "X-API-Key: amj_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"agent_ids": ["id-1", "id-2", "id-3"],
"updates": { "team": "ML Platform", "approval_status": "pending_review" }
}'
// Response
{ "object": "bulk_update_result", "updated": 3, "skipped": 0, "agent_ids": ["id-1","id-2","id-3"] }/v1/agents/{id}/findingsGet findings for one agent
Returns all security findings for a specific agent, derived from its signals and mapped to OWASP LLM Top 10, MITRE ATT&CK, SOC 2, and NIST AI RMF.
curl https://amajoni-production.up.railway.app/v1/agents/550e8400-e29b-41d4-a716-446655440000/findings \ -H "X-API-Key: amj_your_key_here"
/v1/findingsList all security findings
Returns all security findings across your entire agent fleet. Each finding maps a signal to a security framework. Filter by severity or framework to build targeted alert pipelines.
Query Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| severity | string | No | Filter: critical | high | medium | low |
| framework | string | No | Filter: OWASP | MITRE | SOC2 | NIST | Signal |
| agent_id | string | No | Scope to a single agent |
| limit | integer | No | Results per page (1–100, default 50) |
| offset | integer | No | Pagination offset |
curl "https://amajoni-production.up.railway.app/v1/findings?severity=critical&framework=OWASP" \ -H "X-API-Key: amj_your_key_here"
/v1/postureGet org posture summary
Returns an overall security posture score (0–100 with letter grade), agent counts by risk level, finding counts by severity, and exposure statistics. Use this as a dashboard feed or CI/CD gate.
curl https://amajoni-production.up.railway.app/v1/posture \
-H "X-API-Key: amj_your_key_here"
// Response
{
"object": "posture",
"score": 72,
"grade": "B",
"total_agents": 14,
"agents_by_risk": { "critical": 1, "high": 3, "medium": 6, "low": 4 },
"agents_unowned": 5,
"agents_internet_exposed": 2,
"avg_blast_radius": 41.2,
"total_findings": 23
}/v1/activityList activity events
Returns the security event log — scans, agent discoveries, governance changes, alerts, and signal detections. Most recent events first.
Query Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| severity | string | No | Filter: critical | high | medium | low | info |
| event_type | string | No | e.g. scan_completed | agent_discovered | critical_found |
| limit | integer | No | Results per page (1–100, default 50) |
| offset | integer | No | Pagination offset |
curl "https://amajoni-production.up.railway.app/v1/activity?severity=critical&limit=20" \ -H "X-API-Key: amj_your_key_here"
/v1/scansList recent scans
Returns scan records with status, timing, cloud provider, and agent counts discovered.
curl https://amajoni-production.up.railway.app/v1/scans \ -H "X-API-Key: amj_your_key_here"
/v1/governanceGet governance summary
Returns ownership and review status across all agents. Response includes total_agents, approved, pending_review, unreviewed, rejected, unowned_agents, overdue_reviews, governance_rate (%), and a per-agent list with review_due flags. Useful for EU AI Act Art.14 (human oversight) compliance dashboards.
curl https://amajoni-production.up.railway.app/v1/governance \ -H "X-API-Key: amj_your_key_here"
/v1/export/siemSIEM-ready flat event export
Returns all security findings as a flat JSON array, one event per finding with full agent context embedded. Designed for direct ingestion into Splunk, QRadar, Elastic, or any SIEM that accepts JSON event streams.
curl https://amajoni-production.up.railway.app/v1/export/siem \ -H "X-API-Key: amj_your_key_here" # Pipe into jq to filter critical events curl ... | jq '.events[] | select(.severity == "critical")'
/v1/export/csvCSV governance export
Returns the full agent inventory and governance status as a CSV file with BOM encoding for Excel compatibility. Includes risk level, blast radius, signals, owner, team, approval status, and review dates.
curl https://amajoni-production.up.railway.app/v1/export/csv \ -H "X-API-Key: amj_your_key_here" \ -o amajoni-agents.csv
/v1/alertsList active alerts
Returns persistent alerts for your organisation — each alert corresponds to a triggered rule (blast radius, governance gap, or security signal). Alerts are resolved automatically on the next scan if their condition clears. Results are sorted by severity (critical first) then last_seen_at descending.
Query Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| severity | string | No | Filter by severity: critical | high | medium | low |
| triage_state | string | No | Filter by workflow state: new | acknowledged | dismissed | false_positive | resolved |
| resolved | boolean | No | Include resolved alerts (default: false) |
| limit | integer | No | Results per page, 1–200 (default: 50) |
| offset | integer | No | Pagination offset (default: 0) |
curl https://amajoni-production.up.railway.app/v1/alerts \ -H "X-API-Key: amj_your_key_here" # Filter to critical alerts only curl "https://amajoni-production.up.railway.app/v1/alerts?severity=critical" \ -H "X-API-Key: amj_your_key_here" # Show only unacknowledged (new) alerts curl "https://amajoni-production.up.railway.app/v1/alerts?triage_state=new" \ -H "X-API-Key: amj_your_key_here"
| Status | Meaning |
|---|---|
| 401 | Missing or invalid API key |
| 404 | Resource not found or not owned by your org |
| 400 | Malformed request (missing required fields or bad values) |
| 429 | Rate limit exceeded — wait 60 s then retry |
| 500 | Internal server error — contact support if persistent |
Need help?
Email hi@amajoni.com with your question. Include your X-API-Key prefix (first 8 chars only — never the full key) to help us identify your account.