Ointerference
DOCS

Quickstart

Make your first API call to Interference in under 2 minutes.

Quickstart Guide

Get started with Interference in three simple steps.


1. Create an API Key

  1. Sign in to your Interference Dashboard.
  2. Navigate to API Keys and click Generate New Key.
  3. Copy your live API key (starts with sk_live_...).

:::warning Secure Your Key Your secret API key is only shown once upon creation. Store it in a secure environment variable (INTERFERENCE_API_KEY) and never commit it to source control. :::


2. Configure Your Environment

Set your API key in your terminal or .env file:

export INTERFERENCE_API_KEY="sk_live_YOUR_API_KEY_HERE"

Base URL for all OpenAI-compatible SDKs:

https://api.interference.dev/v1

3. Make Your First Request

Choose your preferred language or SDK:

cURL

curl https://api.interference.dev/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $INTERFERENCE_API_KEY" \
  -d '{
    "model": "qwen3.6-plus",
    "messages": [
      { "role": "user", "content": "Explain quantum computing in one sentence." }
    ],
    "stream": true
  }'

Python (openai SDK)

Install the official OpenAI package:

pip install openai
from openai import OpenAI
import os

client = OpenAI(
    base_url="https://api.interference.dev/v1",
    api_key=os.environ.get("INTERFERENCE_API_KEY")
)

stream = client.chat.completions.create(
    model="qwen3.6-plus",
    messages=[
        {"role": "user", "content": "What is the capital of France?"}
    ],
    stream=True
)

for chunk in stream:
    if chunk.choices and chunk.choices[0].delta.content:
        print(chunk.choices[0].delta.content, end="", flush=True)

TypeScript / Node.js (openai SDK)

npm install openai
import OpenAI from "openai";

const client = new OpenAI({
  baseURL: "https://api.interference.dev/v1",
  apiKey: process.env.INTERFERENCE_API_KEY,
});

async function main() {
  const completion = await client.chat.completions.create({
    model: "glm-5.3-flash",
    messages: [{ role: "user", content: "Write a haiku about high-speed networks." }],
    stream: true,
  });

  for await (const chunk of completion) {
    process.stdout.write(chunk.choices[0]?.delta?.content || "");
  }
}

main();

Vercel AI SDK

npm install ai @ai-sdk/openai-compatible
import { createOpenAICompatible } from "@ai-sdk/openai-compatible";
import { streamText } from "ai";

const interference = createOpenAICompatible({
  name: "interference",
  baseURL: "https://api.interference.dev/v1",
  apiKey: process.env.INTERFERENCE_API_KEY,
});

const { textStream } = await streamText({
  model: interference("qwen3.6-plus"),
  prompt: "Write a TypeScript function to debounce an event.",
});

for await (const delta of textStream) {
  process.stdout.write(delta);
}

Next Steps

On this page