BrainstormRouter Agents API

The agents API from BrainstormRouter — 10 operation(s) for agents.

Operations 11

GET /v1/agent/anomaly/me Recent security events for the calling agent #
POST /v1/agent/bootstrap Zero-human agent onboarding — profile + enforced limits + JWT #
GET /v1/agent/limits/me Budget + rate-limit state for the calling agent #
GET /v1/agent/status Full self-awareness: profile, limits, anomaly, governance #
POST /v1/agents/{agentId}/run Start the agent loop for a session and stream events as SSE #
GET /v1/agents/{agentId}/runs Run history for an agent (sessions with aggregate metadata) #
POST /v1/agents/{agentId}/sessions Create an idle session for the agent (no loop) #
DELETE /v1/agents/{agentId}/sessions/{sessionId} Terminate a session (status → ended) #
GET /v1/agents/{agentId}/sessions/{sessionId} Get a session by id #
POST /v1/agents/{agentId}/sessions/{sessionId}/events Publish a user event to a running session (PG NOTIFY) #
GET /v1/runs/active All active runs for the tenant (status = running) #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/brainstormrouter-com:brainstormrouter-com-agents-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

brainstormrouter-com-agents-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: BrainstormRouter Agents API
  version: 1.0.0
  description: 'Autonomous AI API Engine — multi-tenant gateway that intelligently routes

    AI traffic across providers with built-in memory, cost optimization, and

    autonomous background processing.


    All `/v1/*` endpoints require an API key via `Authorization: Bearer `.'
  contact:
    name: BrainstormRouter
    url: https://brainstormrouter.com
  license:
    name: Proprietary
    identifier: LicenseRef-Proprietary
servers:
- url: https://api.brainstormrouter.com
  description: Production
security:
- BearerAuth: []
tags:
- name: Agents
paths:
  /v1/agent/anomaly/me:
    get:
      operationId: securityAgentAnomalyMe
      summary: Recent security events for the calling agent
      tags:
      - Agents
      x-br-capability-id: security.agent.anomaly.me
      x-br-version: v1
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                propertyNames:
                  type: string
                additionalProperties: {}
      security:
      - AgentJwt: []
  /v1/agent/bootstrap:
    post:
      operationId: securityAgentBootstrap
      summary: Zero-human agent onboarding — profile + enforced limits + JWT
      tags:
      - Agents
      x-br-capability-id: security.agent.bootstrap
      x-br-version: v1
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $schema: http://json-schema.org/draft-07/schema#
              type: object
              properties:
                agent_id:
                  type: string
                  pattern: ^[a-z0-9][a-z0-9-]{1,62}[a-z0-9]$
                display_name:
                  type: string
                cost_center:
                  type: string
                department:
                  type: string
                worker_type:
                  type: string
                budget_daily_usd:
                  type: number
                  exclusiveMinimum: 0
                budget_monthly_usd:
                  type: number
                  exclusiveMinimum: 0
                metadata:
                  type: object
                  propertyNames:
                    type: string
                  additionalProperties: {}
                soul_md:
                  type: string
                  maxLength: 16384
                owner_id:
                  type: string
                  minLength: 1
                  maxLength: 256
              required:
              - agent_id
              additionalProperties: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                propertyNames:
                  type: string
                additionalProperties: {}
      security:
      - BearerAuth: []
  /v1/agent/limits/me:
    get:
      operationId: securityAgentLimitsMe
      summary: Budget + rate-limit state for the calling agent
      tags:
      - Agents
      x-br-capability-id: security.agent.limits.me
      x-br-version: v1
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                propertyNames:
                  type: string
                additionalProperties: {}
      security:
      - AgentJwt: []
  /v1/agent/status:
    get:
      operationId: securityAgentStatus
      summary: 'Full self-awareness: profile, limits, anomaly, governance'
      tags:
      - Agents
      x-br-capability-id: security.agent.status
      x-br-version: v1
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                propertyNames:
                  type: string
                additionalProperties: {}
      security:
      - AgentJwt: []
  /v1/agents/{agentId}/run:
    post:
      operationId: systemAgentsRun
      summary: Start the agent loop for a session and stream events as SSE
      tags:
      - Agents
      x-br-capability-id: system.agents.run
      x-br-version: v1
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $schema: http://json-schema.org/draft-07/schema#
              type: object
              properties:
                message:
                  type: string
                  minLength: 1
                  maxLength: 100000
                session_id:
                  type: string
                  format: uuid
                  pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                max_turns:
                  type: integer
                  minimum: 1
                  maximum: 100
                max_duration_ms:
                  type: integer
                  minimum: 1000
                  maximum: 3600000
                budget_cap_usd:
                  type: number
                  minimum: 0
                system_prompt:
                  type: string
                  maxLength: 50000
              required:
              - message
              additionalProperties: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                propertyNames:
                  type: string
                additionalProperties: {}
        '402':
          description: Tenant has no provider keys (sandbox mode). Agent runs perform real inference and are refused rather than simulated; add a key via POST /v1/providers.
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      message:
                        type: string
                      type:
                        type: string
                        const: sandbox_mode
                      code:
                        type: string
                        const: provider_key_required
                      recovery:
                        type: object
                        properties:
                          action:
                            type: string
                            const: add_provider_key
                          recoverable:
                            type: boolean
                            const: true
                          endpoint:
                            type: string
                        required:
                        - action
                        - recoverable
                        - endpoint
                        additionalProperties: false
                      context:
                        type: object
                        properties:
                          endpoint:
                            type: string
                        required:
                        - endpoint
                        additionalProperties: false
                    required:
                    - message
                    - type
                    - code
                    additionalProperties: false
                required:
                - error
                additionalProperties: false
      security:
      - BearerAuth: []
  /v1/agents/{agentId}/runs:
    get:
      operationId: systemAgentsRunsList
      summary: Run history for an agent (sessions with aggregate metadata)
      tags:
      - Agents
      x-br-capability-id: system.agents.runs.list
      x-br-version: v1
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                propertyNames:
                  type: string
                additionalProperties: {}
      security:
      - BearerAuth: []
  /v1/agents/{agentId}/sessions:
    post:
      operationId: systemAgentsSessionsCreate
      summary: Create an idle session for the agent (no loop)
      tags:
      - Agents
      x-br-capability-id: system.agents.sessions.create
      x-br-version: v1
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $schema: http://json-schema.org/draft-07/schema#
              type: object
              properties:
                session_key:
                  type: string
                  maxLength: 256
                metadata:
                  type: object
                  propertyNames:
                    type: string
                  additionalProperties: {}
              additionalProperties: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                propertyNames:
                  type: string
                additionalProperties: {}
      security:
      - BearerAuth: []
  /v1/agents/{agentId}/sessions/{sessionId}:
    delete:
      operationId: systemAgentsSessionsTerminate
      summary: Terminate a session (status → ended)
      tags:
      - Agents
      x-br-capability-id: system.agents.sessions.terminate
      x-br-version: v1
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                propertyNames:
                  type: string
                additionalProperties: {}
      security:
      - BearerAuth: []
    get:
      operationId: systemAgentsSessionsGet
      summary: Get a session by id
      tags:
      - Agents
      x-br-capability-id: system.agents.sessions.get
      x-br-version: v1
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                propertyNames:
                  type: string
                additionalProperties: {}
      security:
      - BearerAuth: []
  /v1/agents/{agentId}/sessions/{sessionId}/events:
    post:
      operationId: systemAgentsSessionsSendEvent
      summary: Publish a user event to a running session (PG NOTIFY)
      tags:
      - Agents
      x-br-capability-id: system.agents.sessions.sendEvent
      x-br-version: v1
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $schema: http://json-schema.org/draft-07/schema#
              type: object
              properties:
                type:
                  type: string
                  enum:
                  - user.message
                  - user.interrupt
                text:
                  type: string
                  maxLength: 100000
                reason:
                  type: string
                  maxLength: 1000
              required:
              - type
              additionalProperties: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                propertyNames:
                  type: string
                additionalProperties: {}
      security:
      - BearerAuth: []
  /v1/runs/active:
    get:
      operationId: systemAgentsRunsActive
      summary: All active runs for the tenant (status = running)
      tags:
      - Agents
      x-br-capability-id: system.agents.runs.active
      x-br-version: v1
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                propertyNames:
                  type: string
                additionalProperties: {}
      security:
      - BearerAuth: []
components:
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: API key (e.g. `br_live_...`)
    SupabaseJWT:
      type: http
      scheme: bearer
      description: Supabase JWT token (dashboard auth)