Context
TokenSource context management provides a flexible framework for managing AI assistant behaviors and capabilities within the financial services ecosystem. This system implements a primary association between contexts and AI assistants, with optional linking to specific objectives or projects.
Core Architecture
Primary Context-Assistant Association
The system establishes a direct relationship between contexts and AI assistants, ensuring:
Each AI assistant maintains a default context that defines its base behavior and knowledge domain
Contexts contain specific rules, constraints, and knowledge bases tailored to financial operations
Multiple assistants can share standardized contexts for consistent behavior across services
Context definitions include specialized knowledge for payment processing, compliance, and security protocols
Secondary Context-Objective Association
The system supports dynamic context assignment to objectives through:
Flexible context switching based on project phases or requirements
Optional linking between contexts and specific project objectives
Support for multiple assistant personalities within a single project
Dynamic context adaptation for different stages of financial workflows
Base Path: /v1/contexts
Get All Contexts
Method: GET
Endpoint: https://api.tokensource.com/v1/contexts
Description: Retrieves all contexts for the authenticated user.
Response (200 OK):
Get Context by ID
Method: GET
Endpoint: https://api.tokensource.com/v1/contexts/{id}
Description: Retrieves a specific context by its ID.
Parameters:
id
(integer, required)
Response (200 OK):
Response (404 Not Found):
Create Context
Method: POST
Endpoint: https://api.tokensource.com/v1/contexts
Description: Creates a new context.
Request Body:
Response (201 Created):
Update Context
Method: PUT
Endpoint: https://api.tokensource.com/v1/contexts/{id}
Description: Updates an existing context.
Parameters:
id
(integer, required)
Request Body:
Response (200 OK):
Delete Context
Method: DELETE
Endpoint: https://api.tokensource.com/v1/contexts/{id}
Description: Deletes a context.
Parameters:
id
(integer, required)
Response (200 OK):
Generate and Save Context
Method: POST
Endpoint: https://api.tokensource.com/v1/contexts/generate
Description: Generates and saves a new context.
Request Body:
Response (201 Created):
Related Endpoints
Get All Components
Method: GET
Endpoint: https://api.tokensource.com/v1/contexts/components
(Refer to the Components section for the response format.)
Get All Categories
Method: GET
Endpoint: https://api.tokensource.com/v1/contexts/categories
(Refer to the Categories section for the response format.)
Last updated