BrainstormRouter Prompts API
The prompts API from BrainstormRouter — 15 operation(s) for prompts.
The prompts API from BrainstormRouter — 15 operation(s) for prompts.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
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.curl "https://apis.io/api/v1/apis/brainstormrouter-com:brainstormrouter-com-prompts-api"
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.
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: 3.2.0
info:
title: BrainstormRouter Prompts 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: Prompts
paths:
/auth/prompts:
get:
operationId: authPromptsList
summary: List prompt templates (non-archived)
tags:
- Prompts
x-br-capability-id: auth.prompts.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:
- SupabaseJwt: []
post:
operationId: authPromptsCreate
summary: Create a new prompt template (version 1)
tags:
- Prompts
x-br-capability-id: auth.prompts.create
x-br-version: v1
requestBody:
required: true
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
properties:
id:
type: string
template:
type: string
variables:
type: object
propertyNames:
type: string
additionalProperties: {}
environment:
type: string
change_note:
type: string
required:
- id
- template
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:
- SupabaseJwt: []
/auth/prompts/{id}:
delete:
operationId: authPromptsDelete
summary: 'Archive a prompt (soft-delete: marks archived flag)'
tags:
- Prompts
x-br-capability-id: auth.prompts.delete
x-br-version: v1
parameters:
- name: id
in: path
required: true
schema:
type: string
responses:
'200':
description: Success
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
propertyNames:
type: string
additionalProperties: {}
security:
- SupabaseJwt: []
get:
operationId: authPromptsGet
summary: Get one prompt template (with all versions)
tags:
- Prompts
x-br-capability-id: auth.prompts.get
x-br-version: v1
parameters:
- name: id
in: path
required: true
schema:
type: string
responses:
'200':
description: Success
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
propertyNames:
type: string
additionalProperties: {}
security:
- SupabaseJwt: []
put:
operationId: authPromptsUpdate
summary: Update a prompt — appends a new version, doesn't mutate existing
tags:
- Prompts
x-br-capability-id: auth.prompts.update
x-br-version: v1
parameters:
- name: id
in: path
required: true
schema:
type: string
requestBody:
required: true
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
properties:
template:
type: string
variables:
type: object
propertyNames:
type: string
additionalProperties: {}
environment:
type: string
change_note:
type: string
required:
- template
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:
- SupabaseJwt: []
/auth/prompts/{id}/ab:
get:
operationId: authPromptsAbGet
summary: Get current A/B test state for a prompt
tags:
- Prompts
x-br-capability-id: auth.prompts.ab.get
x-br-version: v1
parameters:
- name: id
in: path
required: true
schema:
type: string
responses:
'200':
description: Success
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
propertyNames:
type: string
additionalProperties: {}
security:
- SupabaseJwt: []
post:
operationId: authPromptsAbAction
summary: Start or stop an A/B test on a prompt
tags:
- Prompts
x-br-capability-id: auth.prompts.ab.action
x-br-version: v1
parameters:
- name: id
in: path
required: true
schema:
type: string
requestBody:
required: true
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
properties:
action:
type: string
version_a:
type: number
version_b:
type: number
split_ratio:
type: number
required:
- action
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:
- SupabaseJwt: []
/auth/prompts/{id}/diff:
get:
operationId: authPromptsDiff
summary: Unified diff between two versions of a prompt template
tags:
- Prompts
x-br-capability-id: auth.prompts.diff
x-br-version: v1
parameters:
- name: id
in: path
required: true
schema:
type: string
- name: v1
in: query
required: false
schema:
type: string
- name: v2
in: query
required: false
schema:
type: string
responses:
'200':
description: Success
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
propertyNames:
type: string
additionalProperties: {}
security:
- SupabaseJwt: []
/auth/prompts/{id}/promote:
post:
operationId: authPromptsPromote
summary: Promote a prompt version to a target environment
tags:
- Prompts
x-br-capability-id: auth.prompts.promote
x-br-version: v1
parameters:
- name: id
in: path
required: true
schema:
type: string
requestBody:
required: true
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
properties:
version:
type: number
target_environment:
type: string
required:
- version
- target_environment
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:
- SupabaseJwt: []
/auth/prompts/{id}/test:
post:
operationId: authPromptsTest
summary: Render a prompt template with the supplied variables (dry-run)
tags:
- Prompts
x-br-capability-id: auth.prompts.test
x-br-version: v1
parameters:
- name: id
in: path
required: true
schema:
type: string
requestBody:
required: true
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
properties:
version:
type: number
environment:
type: string
variables:
type: object
propertyNames:
type: string
additionalProperties: {}
required: []
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:
- SupabaseJwt: []
/v1/prompts:
get:
operationId: systemPromptsList
summary: List all prompt templates for the tenant
tags:
- Prompts
x-br-capability-id: system.prompts.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: []
post:
operationId: systemPromptsCreate
summary: Create a versioned prompt template
tags:
- Prompts
x-br-capability-id: system.prompts.create
x-br-version: v1
requestBody:
required: true
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
properties:
id:
type: string
minLength: 1
template:
type: string
minLength: 1
variables:
type: object
propertyNames:
type: string
additionalProperties:
type: string
environment:
type: string
enum:
- dev
- staging
- prod
change_note:
type: string
required:
- id
- template
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/prompts/{id}:
delete:
operationId: systemPromptsArchive
summary: Archive a prompt template (soft delete)
tags:
- Prompts
x-br-capability-id: system.prompts.archive
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: systemPromptsGet
summary: Get a prompt template with its full version history
tags:
- Prompts
x-br-capability-id: system.prompts.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: []
put:
operationId: systemPromptsUpdate
summary: Update a prompt — auto-creates a new version
tags:
- Prompts
x-br-capability-id: system.prompts.update
x-br-version: v1
requestBody:
required: true
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
properties:
template:
type: string
minLength: 1
variables:
type: object
propertyNames:
type: string
additionalProperties:
type: string
environment:
type: string
enum:
- dev
- staging
- prod
change_note:
type: string
required:
- template
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/prompts/{id}/ab:
get:
operationId: systemPromptsAbGet
summary: Get A/B test results for a prompt
tags:
- Prompts
x-br-capability-id: system.prompts.ab.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: []
post:
operationId: systemPromptsAbSet
summary: Start or stop an A/B test for a prompt
tags:
- Prompts
x-br-capability-id: system.prompts.ab.set
x-br-version: v1
requestBody:
required: true
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
properties:
action:
type: string
enum:
- start
- stop
version_a:
type: integer
exclusiveMinimum: 0
maximum: 9007199254740991
version_b:
type: integer
exclusiveMinimum: 0
maximum: 9007199254740991
split_ratio:
type: number
minimum: 0
maximum: 1
required:
- action
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/prompts/{id}/diff:
get:
operationId: systemPromptsDiff
summary: Unified diff between two versions of a prompt
tags:
- Prompts
x-br-capability-id: system.prompts.diff
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/prompts/{id}/evaluate:
post:
operationId: systemPromptsEvaluate
summary: Run a prompt against test cases with a chosen scorer
tags:
- Prompts
x-br-capability-id: system.prompts.evaluate
x-br-version: v1
requestBody:
required: true
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
properties:
version:
type: integer
exclusiveMinimum: 0
maximum: 9007199254740991
test_cases:
minItems: 1
type: array
items:
type: object
properties:
input:
type: object
propertyNames:
type: string
additionalProperties:
type: string
expected_output:
type: string
required:
- input
additionalProperties: false
model:
type: string
scorer:
type: string
enum:
- exact_match
- contains
- validity
- llm_judge
store:
type: boolean
required:
- test_cases
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/prompts/{id}/evaluate/results:
get:
operationId: systemPromptsEvalResults
summary: List recent evaluation runs for a prompt with aggregate metrics
tags:
- Prompts
x-br-capability-id: system.prompts.evalResults
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/prompts/{id}/evaluate/results/{runId}/export:
get:
operationId: systemPromptsEvalExport
summary: Export a single evaluation run as JSON or CSV
tags:
- Prompts
x-br-capability-id: system.prompts.evalExport
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/prompts/{id}/promote:
post:
operationId: systemPromptsPromote
summary: Promote a prompt version to a higher environment
tags:
- Prompts
x-br-capability-id: system.prompts.promote
x-br-version: v1
requestBody:
required: true
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
properties:
version:
type: integer
exclusiveMinimum: 0
maximum: 9007199254740991
target_environment:
type: string
enum:
- dev
- staging
- prod
required:
- version
- target_environment
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/prompts/{id}/test:
post:
operationId: systemPromptsTest
summary: Test-resolve a prompt template with the given variables
tags:
- Prompts
x-br-capability-id: system.prompts.test
x-br-version: v1
requestBody:
required: true
content:
application/json:
schema:
$schema: http://json-schema.org/draft-07/schema#
type: object
properties:
variables:
type: object
propertyNames:
type: string
additionalProperties:
type: string
environment:
type: string
enum:
- dev
- staging
- prod
version:
type: integer
exclusiveMinimum: 0
maximum: 9007199254740991
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: []
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)