Teravera Secure AI

API Developer Documentation

Welcome to the Teravera Secure AI API Developer Documentation. This guide provides everything you need to integrate, authenticate, and interact with our secure AI services.

Get started quickly with our clear examples and best practices.

Example cURL Request
curl --location "https://api.teravera.com/api/AuthenticateFunction?code=HieH2aRe4eQZ4D-x6usgBImy2vTJHvoiCg3nfLM0B-jiAzFukK4wYQ==" \
--header "Content-Type: application/json" \
--data '{
    "Username": "YOUR-USER-HERE",
    "AccessKey": "YOUR-USER-KEY",
    "OrganisationId": "YOUR-ORG-ID"
}'

Introduction

System Overview

The Teravera AI is an enterprise-grade, Azure native AI Agent platform designed for secure, scalable document querying. It processes uploaded documents into searchable content using vector embeddings, keyword search, and LLM-based response generation.

The APIs and endpoints described in this document are intended for developers integrating directly with the system. This includes functionality for document upload, query execution, and response handling. Authentication is handled via OAuth 2.0, and all operations are executed within the scope of the client's secure Azure environment.

Note: Throughout this documentation, AgentId and OrganisationID are represented as your unique GUIDs(Globally Unique Identifiers) - long alphanumeric strings (e.g., 550e8400-e29b-41d4-a716-446655440000) that let us uniquely identify your agent and organisation.

Key Features:

  • Secure Document Ingestion: Current File Type support (PDF, DOCX, TXT, CSV, Excel)
  • Dynamic Indexing Pipeline: Documents are automatically chunked, embedded, and stored.
  • Multi-Modal Retrieval: Combines vector search, BM25 keyword ranking, and semantic reranking to return highly relevant document chunks.
  • LLM-Based Response Generation: Retrieved data processed and sent along with the prompt to an Azure-hosted LLM (e.g., ChatGPT-4o).
  • Tenant-Level Isolation: Each client operates in a fully separated Azure environment enforced via RBAC and Zero Trust architecture.
  • No Data Retention: All queries, intermediate data, and outputs are transient—nothing is stored or used for model training.
  • Scalable and Fault-Tolerant: The system leverages serverless orchestration to dynamically scale and recover from transient failures.

Authentication Endpoint

All API requests to the Teravera AI system must be authenticated using a valid JWT bearer token. Tokens are issued via the /api/Auth/GenerateToken endpoint. 

Authentication Token Request Format

Requests to the authentication endpoint include a username, access key, and organisation ID:

{
    "Username": "Your Username Here",
    "AccessKey": "Your Access Key Here",
    "OrganisationId": "Your Organisation GUID Here"
}

Authentication Token Success Response

On successful authentication, a signed JWT is issued as a session token and returned in a Set-Cookie header:

{
    "Token": "Output JWT Token Here",
    "Expires": "expiry date here - yyyy-MM-ddTHH:mm:ssZ",
    "Username": "Your Username here",
    "OrganisationId": "Your Organisation GUID"
}

Once you receive the JWT token from the authentication endpoint include it in the Authorisation header for all subsequent API requests:

 Authorization: Bearer abcdefghijklmnop123456… 

Replace the token value with the actual JWT token you received in the successful authentication response.

Authentication Token Error Responses

If the authentication endpoint fails, it will produce one of the following error codes

Status Code Description Common Causes
400 Bad Request Request is malformed or missing fields
  • Missing username or password
500 Internal Server Error Unhandled backend exception
  • Unexpected runtime error
  • Incorrect username or password as this is proxied to an external token issuer
503 Service Unavailable Auth/session infrastructure is unreachable
  • Token validation or session DB temporarily down

Create Agent Endpoint

The /api/CreateAgentFunction endpoint creates a new agent with the specified configuration and capabilities.

Create Agent Request Format

Request to the create agent endpoint must include an authorization header with the token obtained from the authentication endpoint as well as the message containing the agent configuration, structured as follows:

{
    "Id": "Optional Agent GUID Here",
    "Name": "example agent",
    "Description": "Optional description of the agent",
    "Plugins": [0,1,2,3],
    "Instructions": "Behavioral instructions for the agent",
    "OrganisationId": "Your Organisation GUID here",
    "IsDynamicFlexibility": false,
    "Flexibility": 1,
    "Scope": 0,
    "AllowDocumentDownload": true,
    "GenerateRawChatGptResponse": false,
    "NotFoundMessage": "Custom message when no answer is found",
    "PresetPrompts":{
          "Prompt Question":"Prompt Answer"
     }
}

The meaning of each respective field is as follows:

  • Id: An optional unique identifier for the agent. If provided the system will use this as the agent GUID.If not provided, a new GUID will be automatically generated for this agent. 
  • Name: An optional display name for the agent. If not provided, defaults to "ApiCreated-{AgentId}".
  • Description: An optional human-readable description explaining the agent's purpose and capabilities.
  • Plugins: A required array of plugin type identifiers (enums) that define the agent's capabilities. Available plugins must be enabled for the organisation.
  • Instructions: Behavioral instructions that guide how the agent should respond to queries and interact with users.
  • OrganisationId: A required identifier representing the organisation that will own this agent. Must be a valid organisation GUID.
  • IsDynamicFlexibility: A boolean flag indicating whether the agent should dynamically adjust its response flexibility based on context.
  • Flexibility: An enumerated value representing the agent's response flexibility level (affects how creative or conservative responses are).
  • Scope: An enumerated value representing the agent's operational scope (defines who can access the agent)
  • AllowDocumentDownload: A boolean flag indicating whether users can download source documents through this agent.
  • GenerateRawChatGptResponse: A boolean flag for including raw LLM responses alongside processed answers.
  • NotFoundMessage: An optional custom message displayed when the agent cannot find relevant content. Defaults to empty string if not provided.
  • PresetPrompts: An optional dictionary of predefined prompts that can be used to standardize common interactions.

Create Agent Success Response

{
   "Message": "New Agent Created",
   "Agent": {
        "Id": "New Agent GUID",
        "Name": "example name",
        "CreatedDate": "1.1.2025 00:00:01",
        "Description": "example description",
        "Plugins": {
            "Text Documents": 0
        },
        "OrganisationId": "Agent Organisation GUID",
        "Instructions": "example instructions",
        "IsDynamicFlexibility": true,
        "Flexibility": 0,
        "Scope": 0,
        "AllowDocumentDownload": false,
        "GenerateRawChatGptResponse": true,
        "NotFoundMessage": "example not found message",
        "PresetPrompts": {
            "Example Prompt": "Example Response"
        }
    }
}

The meaning of each respective field is as follows:

  • Message: A confirmation message indicating successful agent update.
  • Agent: The complete created agent object showing all current values after the create operation.

Create Agent Error Responses

If the create agent endpoint fails, it will produce one of the following error codes

Status Code Description Common Causes
400 Bad Request Request is malformed or missing fields
  • Missing/invalid Fields
  • Invalid JSON Format
401 Unauthorized Token is missing, invalid, or expired
  • No/expired/invalid authorization token in header or cookie
403 Forbidden Auth/session infrastructure is unreachable
  • Deactivated user account
  • Requesting plugins not enabled for organisation
404 Not Found Organisation does not exist
  • Invalid Organisation
409 Conflict Agent ID conflict with existing agent
  • Attempting to reuse ID of existing agent
500 Internal Server Error Unhandled backend exception
  • Internal Proccessing Error
  • Database connectivity issues

List Agent Endpoint

The /api/ListAgentsFunction endpoint retrieves a list of available agents based on the user's access permissions and specified parameters.

List Agent Request Format

Request to the list agents endpoint must include an authorization header with the token obtained from the authentication endpoint as well as the message containing optional filter parameters, structured as follows:

{
    "UserId": "Optional User GUID Here",
    "OrganisationId": "Optional Organisation GUID Here",
    "ShowDeletedAgents": false
}

The meaning of each respective field is as follows:

  • UserId: An optional identifier for a specific user. When provided, returns agents created by that user. If not provided, defaults to the authenticated user's agents (for basic users) or broader scope (for elevated users).
  • OrganisationId: An optional identifier representing the organisation. When provided, returns all agents within that organisation (subject to user permissions). Users can only access agents within their own organisation.
  • ShowDeletedAgents: An optional boolean flag indicating whether to include deleted agents in the response. Defaults to false if not specified.

List Agent Success Response

{
    "Message": "User agents",
    "AgentCount": 3,
    "Agents": [
       {
            "Id": "Agent GUID",
            "Name": "Example Agent Name",
            "Instructions": "Agent Instructions here",
            "CreatedDate": "01.01.2025",
            "CreatedDateTime": "01.01.2025 12:00:00",
            "Status": 0,
            "Description": "Agent description here",
            "OrganisationId": "Organisation Guid",
            "OrganisationName": "Organisation Name",
            "CreatedByUserId": "User ",
            "CreatedByUserName": "User Name",
            "IsFlexibilityDynamic": false,
            "PresetPrompts": null,
            "IsDynamicFlexibility": false,
            "Flexibility": 0,
            "Scope": 0,
            "AllowDocumentDownload": false,
            "GenerateRawChatGptResponse": false,
            "NotFoundMessage": ""
        },
        {
         More Agents here…..
        }
    ]
}

The meaning of each respective field is as follows:

  • Message: A descriptive message indicating the scope of agents returned (e.g., "User agents", "Organisation Agents", "All agents").
  • AgentCount: The total number of agents returned in the response.
  • Agents: An array of agent objects containing detailed information about each agent: 
  • Id: Unique identifier for the agent
  • Name: Display name of the agent
  • Instructions: Behavioral instructions configured for the agent
  • CreatedDate: Date the agent was created (format: DD.MM.YYYY)
  • CreatedDateTime: Full timestamp when the agent was created
  • Status: Numeric status code representing the agent's current state
  • Description: Human-readable description of the agent's purpose
  • OrganisationId: GUID of the organisation that owns the agent
  • OrganisationName: Display name of the owning organisation
  • CreatedByUserId: GUID of the user who created the agent
  • CreatedByUserName: Display name of the user who created the agent
  • IsFlexibilityDynamic: Boolean indicating if flexibility settings are dynamically adjusted
  • PresetPrompts: Array of predefined prompts for the agent (may be null)
  • IsDynamicFlexibility: Boolean flag for dynamic flexibility mode
  • Flexibility: Enum value representing the agent's response flexibility level
  • Scope: Numeric value representing the agent's operational scope
  • AllowDocumentDownload: Boolean indicating if users can download documents through this agent
  • GenerateRawChatGptResponse: Boolean flag for including raw LLM responses
  • NotFoundMessage: Custom message displayed when no relevant content is found

List Agent Error Responses

If the list agent endpoint fails, it will produce one of the following error codes:

Status Code Description Common Causes
400 Bad Request Request is malformed or invalid fields
  • Invalid JSON
401 Unauthorized Token is missing, invalid, or expired
  • No/expired/invalid authorization token in header or cookie
403 Forbidden User Lacks Permission to access requested resource
  • Deactivated user account
  • User Attempting to access other organisations/users agents
500 Internal Server Error Unhandled backend exception
  • Internal Proccessing Error
  • DB error
503 Service Unavailable Auth/session infrastructure is unreachable
  • Authentication middleware or session DB temporarily down

Update Agent Endpoint

The /api/UpdateAgentFunction endpoint modifies an existing agent's configuration, allowing partial updates to specific fields while preserving unchanged properties.

Update Agent Request Format

Request to the update agent endpoint must include an authorization header with the token obtained from the authentication endpoint as well as the message containing the agent updates, structured as follows:

{
    "Id": "Your Agent GUID",
    "Name": "Updated Agent Name",
    "Description": "Updated description",
    "Plugins": [0, 1],
    "Instructions": "Updated behavioral instructions",
    "IsDynamicFlexibility": true,
    "Flexibility": 2,
    "Scope": 1,
    "AllowDocumentDownload": true,
    "GenerateRawChatGptResponse": false,
    "NotFoundMessage": "Updated not found message",
    "PresetPrompts": {
        "updated prompt": "updated answer"
      }
}

The meaning of each respective field is as follows:

  • Id: A required unique identifier for the agent to be updated. Must be a valid agent GUID that exists and is not deleted.
  • Name: An optional new display name for the agent. Only updates when a non-null value is provided.
  • Description: An optional new description for the agent. Updates when provided, including null values which will clear the existing description.
  • Plugins: An optional array of plugin type identifiers to replace the agent's current plugin configuration. All specified plugins must be enabled for the organisation.
  • Instructions: An optional new set of behavioral instructions. Only updates when a non-null value is provided.
  • IsDynamicFlexibility: An optional boolean to enable or disable dynamic flexibility mode.
  • Flexibility: An optional enumerated value to set the agent's response flexibility level.
  • Scope: An optional enumerated value to set the agent's operational scope.
  • AllowDocumentDownload: An optional boolean to enable or disable document download permissions.
  • GenerateRawChatGptResponse: An optional boolean to enable or disable raw LLM response inclusion.
  • NotFoundMessage: An optional custom message for when no relevant content is found. Only updates when a non-null value is provided.
  • PresetPrompts: An optional dictionary of predefined prompts. When provided, completely replaces the existing preset prompts collection.

Update Agent Success Response

{
    "Message": "Agent Updated.",
    "Agent": {
        "Id": "Agent GUID",
        "Name": "example agent",
        "CreatedDate": "01.01.2025 12:00:00",
        "Description": "description of agent",
        "Plugins": {
            "Text Documents": 0
        },
        "OrganisationId": "Organisation GUID of agent",
        "Instructions": "example instructions",
        "IsDynamicFlexibility": true,
        "Flexibility": 0,
        "Scope": 0,
        "AllowDocumentDownload": false,
        "GenerateRawChatGptResponse": true,
        "NotFoundMessage": "example not found message",
        "PresetPrompts": {
            "Example question": "Example answer"
        }
    }
}

The meaning of each respective field is as follows:

  • Message: A confirmation message indicating successful agent update.
  • Agent: The complete updated agent object showing all current values after the update operation, including both modified and unchanged fields.

Update Agent Error Responses

If the list agent endpoint fails, it will produce one of the following error codes:

Status Code Description Common Causes
400 Bad Request Request is malformed or invalid fields
  • Invalid JSON
401 Unauthorized Token is missing, invalid, or expired
  • No/expired/invalid authorization token in header or cookie
403 Forbidden User Lacks Permission to access requested resource
  • Deactivated user account
  • User Attempting to access other organisations/users agents
404 Not Found Referenced organisation does not exist
  • Organisation not accessible/does not exist
409 Conflict Agent is in an invalid state for updates
  • Agent has been deleted/disabled
500 Internal Server Error Unhandled backend exception
  • Internal Processing Error
  • DB error

Delete Agent Endpoint

The /api/DeleteAgentFunction endpoint permanently deletes an agent along with all associated files, index documents, and blob storage data.

Delete Agent Request Format

Request to the delete agent endpoint must include an authorization header with the token obtained from the authentication endpoint as well as the message containing the agent identifiers, structured as follows:

{
    "OrganisationId": " Your Organisation GUID Here ",
    "AgentId": " Your Agent GUID Here "
}

The meaning of each respective field is as follows:

  • OrganisationId: A required identifier representing the client or tenant. This is used to enforce data isolation and access control between different clients.
  • AgentId: A required identifier for the current project or knowledgebase. It ensures the delete request is scoped to the correct set of uploaded documents and associated data.

Delete Agent Success Response

The endpoint returns a plain text success message indicating the scope of deletion:


Full Deletion: 

Index documents and blobs for Agent '[AgentId]' deleted successfully.Agent Deleted Successfully

When both search index documents and blob storage files are found and deleted.

 

Index Only:

Index documents for Agent '[AgentId]' deleted successfully. Blobs not found.Agent Deleted Successfully

When only search index documents are found and deleted.

 

Blobs Only

Blobs for Agent '[AgentId]' deleted successfully. No documents found in index.Agent Deleted Successfully 

When only blob storage files are found and deleted.

 

No Files Found

No index documents or blobs found for Agent '[AgentId]'.Agent Deleted Successfully"

When the agent exists but has no associated files.

Delete Agent Error Responses

If the list agent endpoint fails, it will produce one of the following error codes:

Status Code Description Common Causes
400 Bad Request Request is malformed or missing fields
  • Missing request field
  • Invalid Request format
  • Files still processing for agent
401 Unauthorized Token is missing, invalid, or expired
  • No/expired/invalid authorization token in header or cookie
403 Forbidden User Lacks Permission to access requested resource
  • Deactivated user account
  • Agent does not exist or already deleted
  • User Attempting to access other organisations/users agents
500 Internal Server Error Unhandled backend exception
  • Aazure Search Service error
  • Blob storage connectivity issues
  • Database operation failure

File Upload Endpoint

The /api/ReceiveAndUploadFileFunction endpoint handles uploading of both unstructured documents and structured tabular files.

Supported file types include .pdf, .docx, .txt, .csv, .xlsx, and .xls.

Upload Request Format

Request to the upload endpoint must include an authorisation header with the bearer token obtained from the authentication endpoint as well as the form data containing the file to be uploaded which is structured as follows:

{
    "AgentId": "Your Agent ID Here",
    "OrganisationId": "Your Organisation ID Here",
    "file": "file form-data"
}

Upload Success Response

A successful file upload returns the following response format, regardless of file type:

{
    "Message": "File received and uploaded to blob successfully. Beginning Indexing",
    "FileName": "example.pdf",
    "AgentId": "Your Agent ID Here",
    "OrganisationId": "Your Organisation ID Here"
}

Upload Error Responses

If the authentication endpoint fails, it will produce one of the following error codes:

Status Code Description Common Causes
400 Bad Request Request is malformed or missing fields
  • Missing Field
  • File contains no data
  • File exceeds max file size
  • Invalid file name
401 Unauthorized Token is missing, invalid, or expired
  • No/expired/invalid authorization token in header or cookie
409 Conflict Request contains invalid field
  • File with this name already uploaded
500 Internal Server Error Unhandled backend exception
  • Internal processing error
  • Cosmos DB/Blob error
503 Service Unavailable Auth/session infrastructure is unreachable
  • Authentication middleware or session DB temporarily down

Querying Endpoint

The /api/AskAgentFunction endpoint accepts a natural language query and returns a context-aware response generated from previously uploaded data.

Query Request Format

Request to the query endpoint include an authorisation header with the token obtained from the authentication endpoint as well as the message containing the query and the files to be queried which is structured as follows:

{
    "Query": "Example Query",
    "OrganisationId": "Your Organisation GUID Here",
    "AgentId": "Your Agent GUID Here",
    "UserId": "Optional User GUID",
    "ConversationId": "Optional Conversation GUID",
    "Messages": [
        {
            "role": "user",
            "content": "Previous message content"
        },
        {
            "role": "assistant", 
            "content": "Previous assistant response"
        }
    ],
    "FilesToSearch": ["file1.pdf", "file2.docx"],
    "ProjectSummary": "Example summary of documentation uploaded",
    "NotFoundMessage": "Apologies I could not answer your question.",
    "Flexibility": 2,
    "IsRawChatGptResponseOn": false,
    "RagMode": 0,
    "RequestedModes": [0, 3]
}

The meaning of each respective field is as follows:

  • Query: A required natural language question posed by the user. This is used to perform semantic search across indexed content and to drive LLM response generation.
  • OrganisationId: A required identifier representing the client or tenant. This is used to enforce data isolation and access control between different clients.
  • AgentId: A required identifier for the current project or knowledgebase. It ensures the query is scoped to the correct set of uploaded documents and associated data.
  • UserId: An optional identifier for the user making the request. Used for logging and access control.
  • ConversationId: An optional identifier for maintaining conversation context. If not provided, a new conversation ID will be generated automatically.
  • Messages: An optional array of previous conversation messages to provide context. Only the last 20 messages are processed. Each message should contain: 
    • Role: The message sender ("user", "assistant", "system")
    • Content: The message content
  • FilesToSearch: An optional array of specific file ids to search within. If not provided, all files associated with the agent will be searched.
  • ProjectSummary: An optional description of the project or query context that may be inserted into the prompt to help the LLM disambiguate answers.
  • NotFoundMessage: An optional custom message returned when no relevant content is found. If not provided, defaults to "Apologies I could not find what you are looking for. Please rephrase your prompt".
  • Flexibility: An optional AgentFlexibility enum value (0-3) controlling response creativity. Defaults to PartiallyOpen (2).
  • IsRawChatGptResponseOn: An optional boolean flag to include raw LLM responses in the output. Defaults to false.
  • RagMode: An optional RagMode enum value specifying the retrieval mode. Defaults to Text (0).
  • RequestedModes: An optional array of RagMode values for multi-mode processing. When specified, the system will process the query using multiple RAG modes and combine results.

Query Success Response

{
    "Entity": {
        "Context": "...",
        "GeneratedResponse": {
              "Response": "Here is the answer to your query...",
              "ResponseMessages":null,
              "RawChatGptResponse":null,
	      "DataSource":{
                     "file-id-1": "document1.pdf", 
                     "file-id-2": "document2.docx"
                 }
                 "AnswerFound": true,
                 "InputTokens": 902,
                 "OutputTokens": 40
        },
        "FileNames": ["full list of files", "that matched", "the query"],
        "SearchResults": [...],
        "TableResults": null,
       "ConversationId":"Conversation GUID"
    },
    "ErrorMessage": "",
    "IsSuccess": true
}

The meaning of each respective field is as follows:

  • Entity: Main response container object containing all query results and metadata
    Context: The full context that was included for the content retrieval
  • GeneratedResponse: Object containing the language model's response and processing metadata 
    • Response: The natural language answer generated by the system based on retrieved content
    • DataSource: Dictionary mapping unique file identifiers to their display names for files that contributed content to the answer
    • InputTokens: Total number of tokens consumed in generating the LLM prompts
    • OutputTokens: Total number of tokens produced by the language model in its responses
    • AnswerFound: Boolean indicating whether meaningful content was found and used to generate an answer
    • FileNames: Array of unique file identifiers for all files that were matched during the search process
  • SearchResults: Array of search result objects containing document chunks, metadata, and relevance scores
  • ConversationId: Unique identifier for the conversation session, used to maintain context across multiple queries
  • ErrorMessage: Text field containing error details when the operation fails, empty when successful
  • IsSuccess: Boolean flag indicating whether the query operation completed successfully

Query Error Responses

If the authentication endpoint fails, it will produce one of the following error codes:

Status Code Description Common Causes
400 Bad Request Request is malformed or missing fields
  • Missing request field
401 Unauthorized Token is missing, invalid, or expired
  • No/expired/invalid authorization token in header or cookie
500 Internal Server Error Unhandled backend exception
  • Internal processing error
  • Cosmos DB/Blob error
503 Service Unavailable Unavailable    Auth/session infrastructure is unreachable
  • Authentication middleware or session DB temporarily down

Delete File Endpoint

The /api/DeleteFileFunction endpoint removes both the file blob and indexed document chunks, based on the provided FileName and AgentId.

Delete Request Format

Request to the delete endpoint include an authorisation header with the token obtained from the authentication endpoint as well as the message containing the file to be deleted which is structured as follows:

{
    "FileName": "example.pdf",
    "OrganisationId": "Your Organisation ID Here",
    "AgentId": "Your Agent ID Here"
}

Delete Success Response

On successful deletion of the file, a plain text message is returned:

Index documents and blob for FileName ‘example.pdf' deleted successfully.

Delete Error Responses

If the delete endpoint fails, it will produce one of the following error codes:

Status Code Description Common Causes
400 Bad Request Request is malformed or missing fields
  • Missing request field
401 Unauthorized Token is missing, invalid, or expired
  • No/expired/invalid authorization token in header or cookie
500 Internal Server Error Unhandled backend exception
  • Internal processing error
  • Cosmos DB/Blob error
503 Service Unavailable Auth/session infrastructure is unreachable
  • Authentication middleware or session DB temporarily down

Appendix

This section provides the complete reference for all enumerated types used in the Teravera Secure AI API. When making API requests, use the integer values shown below.

Plugin Type Enum

Defines the available plugin capabilities that can be assigned to agents:

Value Name Description
0 TextDocument Enables processing and querying of unstructured text documents (PDF, DOCX, TXT)
1 Structured Documents Enables processing and querying of structured tabular data (CSV, XLSX, XLS)
2 DocumentIntelligence Enables advanced document analysis and form processing capabilities
3 SharepointConnection Enables direct integration with SharePoint document repositories

Usage Example:

{
.....
"Plugins": [0, 1, 2]
.....
}

Can be used when creating or updating an agent to assign plugins per agent.

AgentFlexibility Enum

Controls how creatively the agent responds to queries:

Value Name Description
0 FullyClosed Agent strictly adheres to document content, minimal inference
1 PartiallyClosed Agent primarily uses document content with limited logical inference
2 PartiallyOpen Agent uses document content but allows moderate creative interpretation
3 FullyOpen Agent can make broader inferences and creative connections from content

Usage Example:

{
....
"Flexibility": 2
....
}

Can be used to set the agent flexibility to partially open when creating or updating an agent.

Agent Scope Enum

Indicates the current operational state of an agent:

Value Name Description
0 Local Agent access restricted to local organisation users only
1 Affiliates Agent can be accessed by users from affiliated organizations
2 Global Agent can be accessed by users across all organisations

Usage Example:

{
....
"Scope": 1
....
}

Can be used when creating or updating agent to set the agent to be accessible by affiliates.

Agent Status Enum

Indicates the current operational state of an agent:

Value Name Description
0 Active Agent is operational and available for queries
1 Inactive Agent is temporarily disabled but can be reactivated
2 Deleted Agent has been permanently deleted and cannot be recovered

Usage Example:

{
....
"Status": 1
....
}

Can be used to update an agent to Inactive.

Rag Mode Enum

Defines the retrieval and processing modes available for queries:

Value Name Description
0 Text Standard Text-based retrieval from unstructured documents
1 Complete Comprehensive retrieval combining multiple sources and modes
3 Table Focuses on tabular data extraction and analysis from spreadsheets
4 DocAi Use advanced document intelligence for forma and layout processing

Usage Examples:

{
  "Query": "What does the document say about compliance?",
  "RagMode": 0
}

Agent will use Text Rag Mode only.

{
  "Query": "Summarize compliance risks across documents and extract key fields.",
  "RequestedModes": [0, 4]
}

Agent will use Text and DocAi Rag Modes for this query.

Thank you for connecting with Teravera. We have a lot of interest in Secure AI from developers, partners and distributors at the moment and will be in touch shortly.