Set up your development environment

Installation & Setup

Set up your environment to work with the Vindex Ai API.

Environment Setup

Requirements

  • Runtime: Node.js 18+, PHP 8.1+, or Python 3.9+
  • Package Manager: npm, composer, or pip
  • HTTP Client: cURL or any HTTP library

Environment Variables

Store your API key in environment variables:
bash
# .env
VINDEX_API_KEY=vdx_your_api_key_here
VINDEX_BASE_URL=https://ai.vindex.ai

API Keys

Finding Your API Key

  1. Navigate to Sites
  2. Open your site
  3. Copy the API Key from the site overview card
All keys are live keys and work against the production API.

Send a Live Request

Basic chat request

bash
curl -X POST https://ai.vindex.ai/api/chat \
  -H "Content-Type: application/json" \
  -H "X-API-Key: YOUR_API_KEY" \
  -d '{
    "message": "Hello! What can you help me with?",
    "session_id": "live-session-001"
  }'
json
{
  "reply": "Hi! I'm here to help you with anything you need. How can I assist you today?",
  "session_id": "live-session-001"
}