API
REST API reference
Programmatic access to agents, licenses, configuration, alerts, flows, and reports. Base URL: /api/v1
API v1
TRIVLA REST API
Authenticate with a bearer token from the portal (Settings → API keys). All requests use JSON and HTTPS.
curl -H "Authorization: Bearer trvl_api_xxxx" \
https://portal.trivla.com/api/v1/agents
Authentication
Email/password login. Returns JWT access and refresh tokens. Google OAuth uses /api/v1/auth/google.
Agents
List registered agents with status, version, last seen, and license state.
Agent self-registration with license key, hostname, OS, and capabilities.
Licenses
List license keys, seat usage, and expiration.
Validate a license key. Called by agents on startup and periodically.
Flows & analytics
Query network flows from StarRocks. Supports filters for protocol, application, IP, and country.
SIP call list, ladder, and Homer-style dialog state. Live cache when agents are exporting SIP telemetry.
Alerts
List security and operational alerts. Filter by severity, agent, and time range.
Agent alert ingestion endpoint. Used internally by agents; documented for custom integrations.
Configuration
Fetch firewall rules, threat feed settings, and capture policy for an agent.
Full OpenAPI 3.0 specification will ship with the open-source portal repository. This reference covers the core endpoints used by agents and integrations.