Skip to content
Last updated

Welcome to Freddy! This guide will help you get up and running with the Freddy AI platform quickly and efficiently.

📋 Prerequisites

Before you begin, make sure you have:

  • A Freddy account (sign up at Freddy Hub)
  • Basic understanding of REST APIs
  • Your preferred development environment set up

🔑 Step 1: Get Your API Key

  1. Log in to the Freddy Hub
  2. Navigate to SettingsAPI Keys
  3. Click "Create New API Key"
  4. Copy and store your API key securely

⚠️ Important: Your API key starts with ak_ and should be kept secure.

🌐 Step 2: Base URL

All API requests should be made to:

https://api.freddy.ai/v2/

🔐 Step 3: Authentication

Include your API key in every request header:

curl -H "api-key: ak_your_api_key_here" \
     -H "Content-Type: application/json" \
     https://api.freddy.ai/v2/models

🎯 Step 4: Your First Request

Let's make your first API call to list available AI models:

Using cURL

curl -X GET "https://api.freddy.ai/v2/models" \
  -H "api-key: ak_your_api_key_here"

Using Python

import requests

api_key = "ak_your_api_key_here"
headers = {"api-key": api_key}

response = requests.get(
    "https://api.freddy.ai/v2/models",
    headers=headers
)

print(response.json())

Using JavaScript

const apiKey = "ak_your_api_key_here";

fetch("https://api.freddy.ai/v2/models", {
  headers: {
    "api-key": apiKey
  }
})
  .then(response => response.json())
  .then(data => console.log(data));

🤖 Step 5: Generate Your First AI Response

Now let's create an AI response:

curl -X POST "https://api.freddy.ai/v2/model/response" \
  -H "api-key: ak_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gpt-4",
    "messages": [
      {
        "role": "user",
        "content": "Hello, Freddy! How can you help me?"
      }
    ]
  }'

✅ Next Steps

Congratulations! You've made your first API calls. Here's what to explore next:

  1. Authentication Guide - Learn about advanced authentication
  2. Best Practices - Follow recommended patterns
  3. Code Examples - See more practical examples
  4. API Reference - Explore all available endpoints

🆘 Need Help?

  • 📖 Complete Documentation - Full guides and tutorials
  • 🔌 API Reference - Detailed endpoint documentation
  • 🌐 Hub - Access the main application
  • 📧 Support - Contact our team for assistance

Ready to build something amazing with Freddy AI! 🚀