Skip to main content
To connect an external Knowledge Base, open Knowledge Bases, click Knowledge, and select External Knowledge Base. The Knowledge Base is created in the selected Project.
Create menu on the Knowledge Bases page listing Knowledge Base and External Knowledge Base, with External Knowledge Base selected.

Choose External Knowledge Base when connecting a Knowledge Base.

The Connect External Knowledge Base modal opens.
Connect External Knowledge Base modal with Key, Description, Name, API URL, API Key, and Path fields, and Cancel and Connect actions.

Connect External Knowledge Base modal.

Orq.ai includes the API Key in the Authorization: Bearer <API_KEY> header when calling your endpoint.
API keys are encrypted using workspace-specific keys (AES-256-GCM).
Select Connect to finalize.

API Payloads

Example payloads for the request and response expected from your external API:
The API must respond like a standard Knowledge Base search. See our Search API for the expected payload format.

Example Implementations

Get the Code

Install Dependencies

Run the Server

Test the API

The API is running at http://localhost:8000Dynamic Documentation is available at http://localhost:8000/docs

Get the Code

Install Dependencies

Run the Server

Test the API

The API is running at http://localhost:8000Dynamic Documentation is available at http://localhost:8000/doc

Integrate Vector Database Providers

Orq.ai supports providers like Weaviate and Pinecone, as both platforms expose REST APIs that conform to the expected payload format.

Troubleshoot Common Errors

Cannot connect to external API
  1. Verify your API endpoint is publicly accessible via HTTPS.
  2. Check your API logs for incoming requests from Orq.ai IP addresses.
  3. Verify your firewall/security groups allow inbound HTTPS traffic.
API key authentication failing
  1. Verify the API key is correct and has not expired.
  2. Check that your API expects Bearer authentication in the Authorization header.
  3. Confirm your API key has the necessary permissions to perform searches.
No results returned or poor quality results
  1. Verify your API returns the expected response format (see Response Payload above).
  2. Check that scores.search_score values are between 0 and 1.
  3. Test with different threshold values (lower threshold = more results).
  4. If using reranking, ensure both search_score and rerank_score are provided.
  5. Verify your external vector database has sufficient indexed documents.
Slow response times
  1. Monitor your external API response times.
  2. Consider implementing caching for frequently searched queries.
  3. Optimize your vector database indexes.
  4. Check if your external API is rate limiting requests.

Configure your External Knowledge Base

Datasource configuration is not accessible within External Knowledge Bases, as data is hosted outside of Orq.ai.
The available configurations are:
For detailed configuration options, see Agentic RAG, Search Modes, and Rerank Model on the Knowledge Bases page. These settings apply to both internal and external Knowledge Bases.
Your External Knowledge Base is connected: