API & Integrations

REST API for integrating ThinkLocAI into your applications, with streaming, OAuth, and OpenAPI documentation.

Without API Integration

  • Manual copy-paste between systems
  • No automation of AI tasks
  • AI not connected to other systems
  • Time-consuming manual processes

With ThinkLocAI API

  • REST API covering all features
  • SSE streaming for real-time responses
  • OAuth 2.0 for secure authentication
  • OpenAPI specification and SDKs

Interactive Demo

ThinkLocAI - API Playground

Request

// ThinkLocAI REST API
const response = await fetch('/api/chat', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json',
    'Authorization': 'Bearer YOUR_API_KEY'
  },
  body: JSON.stringify({
    model: 'llama-3.1-70b',
    messages: [
      { role: 'user', content: 'Zusammenfassung...' }
    ],
    stream: true
  })
});

Response

Response appears here...

Transparency notice: this demo is a simulation using prepared sample data and does not show output from a live AI model. Labelled in line with Art. 50 of Regulation (EU) 2024/1689.

Features in Detail

REST API

RESTful API with JSON responses for all ThinkLocAI features.

SSE Streaming

Responses are streamed token by token via Server-Sent Events.

OAuth 2.0

Authentication with bearer tokens and a refresh mechanism.

Webhooks

Event-based notifications for asynchronous workflows.

OpenAPI Spec

OpenAPI 3.0 documentation for automatic client generation.

SDK Support

Native SDKs for Python, JavaScript/TypeScript, and more languages.

Technical Details

API Endpoints

  • /api/chat: Conversations
  • /api/documents: RAG Upload
  • /api/users: User Management
  • /api/audit: Audit Logs

Authentication

  • Bearer Token Auth
  • API Key Support
  • OAuth 2.0 Flow
  • CORS Configuration

Response Formats

  • JSON Standard
  • SSE Streaming
  • Pagination
  • Error Handling

Use Cases

Workflow Automation

Integrate AI into your existing automation platforms like n8n or Zapier.

Enterprise Integration

Connect to ERP, CRM, and other enterprise systems via API.

Custom Applications

Build tailored AI applications on top of the ThinkLocAI API.

Plan the connection to your systems

Start with the API documentation and connect ThinkLocAI to your existing applications.