This documentation is not accurate and is currently under development.

Fewzen AI API Endpoints

Explore the various endpoints available in the Fewzen AI API. This guide provides detailed information on each endpoint, including their purposes, required parameters, and usage examples.

Endpoint Categories

Chat
Endpoints for managing conversations and generating responses.
AI Agents
Endpoints for creating, managing, and interacting with AI agents.
Analytics
Endpoints for retrieving analytics and performance data.
Knowledge Base
Endpoints for managing and querying the AI's knowledge base.

Chat Endpoints

EndpointMethodDescription
/v1/chatPOSTSend a message and receive an AI-generated response
/v1/chat/historyGETRetrieve chat history for a specific conversation

Example: Sending a Chat Message

cURL Example
curl -X POST https://api.fewzen.ai/v1/chat \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "messages": [
      {"role": "user", "content": "What is the capital of France?"}
    ]
  }'

AI Agent Endpoints

EndpointMethodDescription
/v1/agentsPOSTCreate a new AI agent
/v1/agents/{agent_id}GETRetrieve details of a specific AI agent
/v1/agents/{agent_id}PUTUpdate an existing AI agent
/v1/agents/{agent_id}/trainPOSTTrain or fine-tune an AI agent

Analytics Endpoints

EndpointMethodDescription
/v1/analytics/usageGETRetrieve API usage statistics
/v1/analytics/performanceGETGet performance metrics for AI agents

Knowledge Base Endpoints

EndpointMethodDescription
/v1/knowledgePOSTAdd new information to the knowledge base
/v1/knowledge/searchGETSearch the knowledge base for specific information
/v1/knowledge/{entry_id}PUTUpdate an existing knowledge base entry

Response Formats

All API responses are returned in JSON format. A typical successful response will have the following structure:

{
  "success": true,
  "data": {
    // Response data specific to the endpoint
  },
  "meta": {
    // Metadata about the request/response
  }
}

In case of an error, the response will include an error message and code:

{
  "success": false,
  "error": {
    "code": "ERROR_CODE",
    "message": "Description of the error"
  }
}

Need More Details?

For in-depth information on request/response formats, parameters, and advanced usage, check out our detailed API reference.

View Full API Reference