Band AI Agent API Context API
The agentApiContext API from Band AI — 1 operation(s) for agentapicontext.
The agentApiContext API from Band AI — 1 operation(s) for agentapicontext.
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/band-ai-agentapicontext-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
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: Request Agent API Context API
version: 1.0.0
servers:
- url: https://app.band.ai
description: https://app.band.ai
tags:
- name: agentApiContext
paths:
/api/v1/agent/chats/{chat_id}/context:
get:
operationId: getAgentChatContext
summary: Get agent context for rehydration
description: 'Returns all messages relevant to the agent for execution context/rehydration.
This includes:
- All messages the agent sent (any type: text, tool_call, tool_result, thought, etc.)
- All text messages that @mention the agent
Use this endpoint to load the complete context an external agent needs to resume execution.
Messages are returned in chronological order (oldest first).
## Pagination
Use `cursor` + `limit` for cursor-based pagination (recommended). The response
`metadata` includes `next_cursor` and `has_more`.
`page` and `page_size` are deprecated and will be removed in API 2.0.0 (2026-10-01).'
tags:
- agentApiContext
parameters:
- name: chat_id
in: path
description: Chat Room ID
required: true
schema:
type: string
format: uuid
- name: cursor
in: query
description: Cursor for keyset pagination (from previous response next_cursor)
required: false
schema:
type: string
- name: limit
in: query
description: 'Items per page for cursor pagination (default: 50, max: 100)'
required: false
schema:
type: integer
- name: page
in: query
description: Page number (deprecated — use cursor instead)
required: false
schema:
type: integer
- name: page_size
in: query
description: Items per page (deprecated — use limit instead)
required: false
schema:
type: integer
- name: X-API-Key
in: header
description: Enter your API key for programmatic access
required: true
schema:
type: string
responses:
'200':
description: Agent context
content:
application/json:
schema:
$ref: '#/components/schemas/Agent_API_Context_getAgentChatContext_Response_200'
'401':
description: Unauthorized
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
'403':
description: Forbidden - Agent authentication required
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
'404':
description: Not Found - Chat room not found or agent not a participant
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/ValidationError'
components:
schemas:
ErrorErrorDetails:
type: object
properties: {}
description: Additional error details (optional)
title: ErrorErrorDetails
ApiV1AgentChatsChatIdContextGetResponsesContentApplicationJsonSchemaMetadata:
type: object
properties:
has_more:
type: boolean
description: Whether more pages exist
limit:
type: integer
description: Page size used
next_cursor:
type:
- string
- 'null'
description: Cursor for next page
page:
type: integer
description: Current page (deprecated)
page_size:
type: integer
description: Items per page (deprecated)
total_count:
type: integer
description: Total items (deprecated)
total_pages:
type: integer
description: Total pages (deprecated)
required:
- has_more
- limit
- next_cursor
title: ApiV1AgentChatsChatIdContextGetResponsesContentApplicationJsonSchemaMetadata
ApiV1AgentChatsChatIdContextGetResponsesContentApplicationJsonSchemaMeta:
type: object
properties:
has_more:
type: boolean
limit:
type: integer
next_cursor:
type:
- string
- 'null'
page:
type: integer
page_size:
type: integer
total_count:
type: integer
total_pages:
type: integer
description: Deprecated — use metadata instead
title: ApiV1AgentChatsChatIdContextGetResponsesContentApplicationJsonSchemaMeta
ValidationError:
type: object
properties:
error:
$ref: '#/components/schemas/ValidationErrorError'
required:
- error
description: Validation error response with field-specific errors and request ID for tracing
title: ValidationError
ChatMessageMetadata:
type: object
properties: {}
description: Additional metadata including mentions
title: ChatMessageMetadata
ErrorError:
type: object
properties:
code:
type: string
description: Machine-readable error code
details:
$ref: '#/components/schemas/ErrorErrorDetails'
description: Additional error details (optional)
message:
type: string
description: Human-readable error message
request_id:
type: string
description: Unique request identifier for tracing and debugging
required:
- code
- message
- request_id
title: ErrorError
Error:
type: object
properties:
error:
$ref: '#/components/schemas/ErrorError'
required:
- error
description: Standard error response with request ID for tracing
title: Error
ValidationErrorError:
type: object
properties:
code:
type: string
description: Machine-readable error code
details:
type: object
additionalProperties:
type: array
items:
type: string
description: Field-specific validation errors with JSON Pointer paths (RFC 6901) as keys
message:
type: string
description: Human-readable error message
request_id:
type: string
description: Unique request identifier for tracing and debugging
required:
- code
- details
- message
- request_id
title: ValidationErrorError
ChatMessage:
type: object
properties:
chat_room_id:
type: string
format: uuid
description: Chat Room ID
content:
type: string
description: Message content
id:
type: string
format: uuid
description: Message ID
inserted_at:
type: string
format: date-time
description: Created At
message_type:
type: string
description: Message type
metadata:
$ref: '#/components/schemas/ChatMessageMetadata'
description: Additional metadata including mentions
sender_id:
type: string
format: uuid
description: Sender ID
sender_name:
type: string
description: Display name of sender (full name for Users, name for Agents)
sender_type:
type: string
description: Sender type (User or Agent)
updated_at:
type: string
format: date-time
description: Updated At
required:
- content
- id
- message_type
- sender_id
- sender_type
description: A chat message
title: ChatMessage
Agent_API_Context_getAgentChatContext_Response_200:
type: object
properties:
data:
type: array
items:
$ref: '#/components/schemas/ChatMessage'
meta:
$ref: '#/components/schemas/ApiV1AgentChatsChatIdContextGetResponsesContentApplicationJsonSchemaMeta'
description: Deprecated — use metadata instead
metadata:
$ref: '#/components/schemas/ApiV1AgentChatsChatIdContextGetResponsesContentApplicationJsonSchemaMetadata'
required:
- data
- metadata
title: Agent API/Context_getAgentChatContext_Response_200
securitySchemes:
ApiKeyAuth:
type: apiKey
in: header
name: X-API-Key
description: Enter your API key for programmatic access
bearerAuth:
type: http
scheme: bearer
description: Enter your JWT token (without the 'Bearer ' prefix)