본문으로 건너뛰기
cheapllm.shop 무료 키 대시보드
Currently facing a lot of demand - Slowdowns may occur - Sorry for the inconvenience
문서 / 연결 방법

두 줄로 연결하세요.

모든 내용이 한 페이지에. 코드가 이미 OpenAI 채팅 API를 지원한다면 01번 섹션만 읽으면 끝입니다.

빠른 시작

설정값
Base URLhttps://cheapllm.shop/v1
API 키sk-cheap-...은(는) 대시보드에서 확인하세요
모델deepseek-v4.1-flash-1017
curl https://cheapllm.shop/v1/chat/completions \
  -H "Authorization: Bearer $CHEAPLLM_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "deepseek-v4.1-flash-1017",
    "messages": [{"role": "user", "content": "Hello!"}]
  }'

Windows에서는 PowerShell에서:

Invoke-RestMethod -Method Post -Uri "https://cheapllm.shop/v1/chat/completions" `
  -Headers @{ Authorization = "Bearer $env:CHEAPLLM_API_KEY" } -ContentType "application/json" `
  -Body '{"model": "deepseek-v4.1-flash-1017", "messages": [{"role": "user", "content": "Hello!"}]}'

Python

from openai import OpenAI

client = OpenAI(base_url="https://cheapllm.shop/v1", api_key="sk-cheap-...")

resp = client.chat.completions.create(
    model="deepseek-v4.1-flash-1017",
    messages=[{"role": "user", "content": "Hello!"}],
)
print(resp.choices[0].message.content)

Node / TypeScript

import OpenAI from "openai";

const client = new OpenAI({ baseURL: "https://cheapllm.shop/v1", apiKey: process.env.CHEAPLLM_API_KEY });

const resp = await client.chat.completions.create({
  model: "deepseek-v4.1-flash-1017",
  messages: [{ role: "user", content: "Hello!" }],
});
console.log(resp.choices[0].message.content);

SDK 없이 일반 fetch 사용

const r = await fetch("https://cheapllm.shop/v1/chat/completions", {
  method: "POST",
  headers: { "Authorization": `Bearer ${KEY}`, "Content-Type": "application/json" },
  body: JSON.stringify({ model: "deepseek-v4.1-flash-1017", messages: [{ role: "user", content: "Hello!" }] }),
});
const data = await r.json();

키

키를 Authorization: Bearer sk-cheap-...로 보내세요. x-api-key 헤더도 사용하는 클라이언트에서는 동작합니다.

  • 대시보드에서 최대 25개의 키를 만들 수 있으며, 앱이나 팀원별로 하나씩 사용하세요.
  • 키는 생성할 때 한 번만 표시됩니다. 저희는 지문(fingerprint)만 저장합니다.
  • 폐기는 다음 요청부터 적용됩니다.
  • CORS가 열려 있어 브라우저 앱에서 API를 직접 호출할 수 있습니다. 다만 공개 웹 페이지에 키를 넣지 마세요. 누구나 읽을 수 있습니다.

채팅 완성

POST /v1/chat/completions은(는) OpenAI 엔드포인트와 동일한 본문을 받습니다. 가장 많이 쓰는 필드는 다음과 같습니다:

필드설명
modeldeepseek-v4.1-flash-1017. 선택 사항이며, 유일한 필수 항목입니다.
messages필수. system, user, assistant, tool 역할.
stream서버 전송 이벤트(SSE)용 true. 아래를 참고하세요.
max_tokens답변의 상한이며 추론도 포함됩니다.
temperature, top_p일반적인 샘플링.
stop문자열 또는 문자열 목록.
tools, tool_choice, response_format모델에 그대로 전달됩니다.

응답에는 prompt_tokens과 completion_tokens가 포함된 usage 객체와, 문의 시 인용할 만한 x-request-id 헤더가 포함됩니다.

스트리밍

"stream": true을 사용하면 text/event-stream을 받습니다: 청크마다 data: {...} 한 줄과 마지막에 data: [DONE]. "stream_options": {"include_usage": true}를 추가하면 토큰 수가 포함된 마지막 청크를 받습니다.

stream = client.chat.completions.create(
    model="deepseek-v4.1-flash-1017",
    messages=[{"role": "user", "content": "Count to five, slowly."}],
    stream=True,
    stream_options={"include_usage": True},
)
for chunk in stream:
    if chunk.choices:
        print(chunk.choices[0].delta.content or "", end="", flush=True)
    elif chunk.usage:
        print("\n", chunk.usage)

연결을 닫으면 생성이 중단되므로, 취소된 요청은 시간 비용이 발생하지 않습니다.

추론

모델은 답변 전에 사고합니다. 사고 내용은 답변과 별도로 도착하므로 출력을 오염시키지 않습니다:

위치추론답변
스트리밍delta.reasoning_content (또한 delta.reasoning)delta.content
비스트리밍message.reasoning_contentmessage.content
추론 토큰은 completion_tokens과 max_tokens에 포함됩니다. 답변이 잘리면 max_tokens를 높이세요.

모델

GET /v1/models은(는) 제공되는 모델 목록을 보여줍니다. 현재는 하나의 모델입니다:

{"object": "list", "data": [{"id": "deepseek-v4.1-flash-1017", "object": "model", "owned_by": "cheapllm"}]}

Model names containing deepseek are routed to it too, so tools with a hard-coded DeepSeek model name just work.

Limits

Free tier

During the beta every account is free, with no rate limit. When the beta ends, every account keeps a permanent free tier, with no card: at least 5,000 input tokens and 1,000 output tokens per hour (5,000 and 1,000 today), counted per account over a rolling hour, all keys together. These numbers can go up, never below that minimum. Past the free tier, usage is billed at $0.005 per million input tokens, $0.001 per million cached input tokens and $0.14 per million output tokens, with no rate limit. We'll email every account before the beta ends.

Rate and size limits

ThingLimit
Requests per minuteNone
Tokens per minuteNone
Parallel requestsNone
Request body4 MB
Keys per account25
When traffic spikes we queue your request and retry for up to 30 seconds before answering 503. That's not a limit on you, it means the kitchen is full for a moment. Retry after the number of seconds in Retry-After; the official SDKs do this on their own.

Errors

Errors come back as {"error": {"message", "type", "code"}}, like OpenAI's.

StatusMeaningWhat to do
400Bad body, e.g. no messagesRead the message, fix the request
401Missing, wrong or revoked keyCheck the header, or make a new key
404Unknown model or endpointUse deepseek-v4.1-flash-1017
413Body over 4 MBTrim the prompt
503Kitchen full, even after our retriesRetry after Retry-After seconds
504Generation took too longLower max_tokens or stream

Anthropic and Responses formats

Tools built for the Anthropic Messages API (Claude Code, the Anthropic SDKs) can use the same model. Point them at https://cheapllm.shop; they call POST /v1/messages. The key works as x-api-key or Authorization: Bearer. Any model name is accepted and routed to deepseek-v4.1-flash-1017.

curl https://cheapllm.shop/v1/messages \
  -H "x-api-key: $CHEAPLLM_API_KEY" \
  -H "anthropic-version: 2023-06-01" \
  -H "content-type: application/json" \
  -d '{"model": "deepseek-v4.1-flash-1017", "max_tokens": 1024,
       "messages": [{"role": "user", "content": "Hello!"}]}'

Supported: text, images, system prompts, tool use and tool results, streaming events, stop sequences. Thinking blocks are not returned. POST /v1/messages/count_tokens returns an estimate.

Tools built for the OpenAI Responses API (Codex CLI, recent OpenAI SDK code) can call POST /v1/responses on https://cheapllm.shop/v1: text and image input, instructions, function and custom tools, streaming events. Stateless only (store and previous_response_id are not kept).

Can't find it here? : it has read these docs and knows the 40 integrations.

Your tools

Step-by-step settings for Claude Code, OpenCode, Codex CLI, DeepSeek Harness, Cline, Roo Code, Kilo Code, Continue, Copilot, Cursor, Zed and many more are on the integrations page. In short: anything with an "OpenAI-compatible" or "custom base URL" setting works with the base URL, your key and the model name above.

Environment variables

export OPENAI_BASE_URL=https://cheapllm.shop/v1
export OPENAI_API_BASE=https://cheapllm.shop/v1   # older libraries
export OPENAI_API_KEY=sk-cheap-...

Windows (PowerShell; setx keeps them for new windows):

setx OPENAI_BASE_URL "https://cheapllm.shop/v1"
setx OPENAI_API_BASE "https://cheapllm.shop/v1"
setx OPENAI_API_KEY "sk-cheap-..."

Or let the installer pick, install and configure your tools (all 40 from the integrations page): curl -fsSL https://cheapllm.shop/setup.sh | sh on macOS and Linux, irm https://cheapllm.shop/setup.ps1 | iex in Windows PowerShell.

Open WebUI

Admin settings, Connections, OpenAI API: add a connection with the base URL and your key. The model appears in the picker.

LibreChat

endpoints:
  custom:
    - name: "cheapllm"
      apiKey: "${CHEAPLLM_API_KEY}"
      baseURL: "https://cheapllm.shop/v1"
      models:
        default: ["deepseek-v4.1-flash-1017"]

Continue (VS Code, JetBrains)

models:
  - name: cheapllm
    provider: openai
    model: deepseek-v4.1-flash-1017
    apiBase: https://cheapllm.shop/v1
    apiKey: sk-cheap-...

Aider

aider --openai-api-base https://cheapllm.shop/v1 --openai-api-key sk-cheap-... \
      --model openai/deepseek-v4.1-flash-1017

Cursor

Settings, Models: paste your key in the OpenAI API key field, turn on "Override OpenAI Base URL" with the base URL, then add the model name as a custom model.

LangChain

from langchain_openai import ChatOpenAI
llm = ChatOpenAI(model="deepseek-v4.1-flash-1017", base_url="https://cheapllm.shop/v1", api_key="sk-cheap-...")

Vercel AI SDK

import { createOpenAICompatible } from "@ai-sdk/openai-compatible";
const cheapllm = createOpenAICompatible({ name: "cheapllm", baseURL: "https://cheapllm.shop/v1", apiKey: process.env.CHEAPLLM_API_KEY });
const model = cheapllm("deepseek-v4.1-flash-1017");

Stuck? Write to [email protected] with the x-request-id of the failing call.