# Create knowledge source Creates a new knowledge source. Endpoint: POST /knowledge Version: 1.0.0 Security: ApiKeyAuth, OrgIdAuth ## Request fields (application/json): - `type` (string, required) Type of knowledge source Enum: "website", "document" - `source` (string, required) URL for websites or filename for documents Example: "https://docs.example.com" - `agentId` (string) Optional agent ID - `metadata` (object) Additional metadata ## Response 201 fields (application/json): - `knowledgeSource` (object) - `knowledgeSource.id` (string, required) Unique identifier for the knowledge source - `knowledgeSource.orgId` (string, required) Organization ID - `knowledgeSource.agentId` (string,null) Optional agent ID if knowledge is agent-specific - `knowledgeSource.type` (string, required) Type of knowledge source Enum: "website", "document" - `knowledgeSource.source` (string, required) URL for websites or filename for documents Example: "https://docs.example.com" - `knowledgeSource.status` (string, required) Processing status Enum: "pending", "processing", "completed", "failed" - `knowledgeSource.lastSyncedAt` (string,null) Last sync timestamp - `knowledgeSource.metadata` (object,null) Additional metadata - `knowledgeSource.createdAt` (string) - `knowledgeSource.updatedAt` (string) ## Response 400 fields (application/json): - `error` (string) Error message Example: "Missing required headers" - `details` (string) Additional error details Example: "x-api-key and x-org-id headers are required" ## Response 401 fields (application/json): - `error` (string) Error message Example: "Missing required headers" - `details` (string) Additional error details Example: "x-api-key and x-org-id headers are required"