DEV Community

Cover image for OpenRouter 콴웬 3.6 사용법: 지금 바로 사용하세요
Rihpig
Rihpig

Posted on • Originally published at apidog.com

OpenRouter 콴웬 3.6 사용법: 지금 바로 사용하세요

요약

Qwen 3.6 Plus Preview가 2026년 3월 30일에 출시되었습니다. 100만 토큰 컨텍스트 창, 필수적인 사고 과정(chain-of-thought) 추론, 도구 사용 지원이 특징입니다. 현재 OpenRouter에서 완전히 무료로 제공되며, OpenAI 호환 클라이언트에서 모델 ID qwen/qwen3.6-plus-preview:free를 사용해 바로 요청을 보낼 수 있습니다.

지금 Apidog을 사용해보세요

조용히 등장한 모델

Alibaba Cloud는 2026년 3월 30일 Qwen 3.6 Plus Preview를 공개했습니다. 별도의 대기 목록이나 이벤트 없이, OpenRouter에서 100만 토큰당 $0로 바로 사용할 수 있게 되었습니다.

Qwen 3.6 Plus Preview

출시 후 이틀간 약 40만 건의 요청, 4억 개 이상의 토큰이 처리되었습니다. 개발자들은 속도 면에서도 만족감을 표했습니다.

이 글에서는 계정 생성부터 API 키 발급, cURL, Python, Node.js 예제 코드, Qwen 3.6의 최적 사용 사례까지 바로 실전에 투입할 수 있는 방법을 안내합니다.

💡 어떤 AI API를 사용하든, 요청을 안정적으로 테스트하고 디버깅하는 도구가 필요합니다. Apidog는 OpenRouter를 포함한 모든 REST API와 연동되는 무료 툴입니다.

이 가이드만 따라 하면 Qwen 3.6의 무료 호출, 기능 및 한계점까지 바로 파악할 수 있습니다.

Qwen 3.5 시리즈와 Qwen 3.6의 주요 변화

Qwen 3.5 대비 3.6은 다음 세 가지가 실질적으로 개선되었습니다.

1. 100만 토큰 컨텍스트 창 지원

Qwen 3.5는 최대 128K 토큰까지 지원했지만, Qwen 3.6은 100만 토큰 입력을 지원합니다.

  • 100만 토큰은 약 75만 단어 분량이며, 전체 코드베이스, 1년치 Slack 로그, 방대한 법률 문서 등 대규모 입력 처리가 가능합니다.
  • 대부분 무료 모델의 컨텍스트 창은 8K~32K가 한계입니다. 100만 토큰을 무료로 활용할 수 있는 기회입니다.

2. 추론(Chain-of-Thought)이 기본 내장

Qwen 3.6은 별도의 프롬프트 없이도 사고 과정(chain-of-thought)을 내부적으로 생성합니다. "단계별로 생각하라" 같은 명령이 필요 없습니다.

  • 수학뿐 아니라, 코딩·프론트엔드·일반 문제 해결까지 자동 적용됩니다.

3. 더 신뢰할 수 있는 에이전트적 행동

3.5의 도구 호출은 종종 오류가 났지만, 3.6에서는 잘못된 인자 타입, 존재하지 않는 함수 호출 같은 문제가 크게 줄었습니다. 실제 워크플로우에서 도구 호출 신뢰도가 높아졌습니다.

특히 다음 작업에 강점을 보입니다:

  • 에이전트 코딩(다단계 코드 생성)
  • 프론트엔드 개발(HTML, CSS, JavaScript 컴포넌트 생성)
  • 대규모 문제 해결(분석, 긴 문서 요약 등)

Qwen 3.6 무료 사용 방법

필요한 준비물:

  1. OpenRouter 계정
  2. API 키(무료 모델은 신용카드 필요 없음)

1단계: OpenRouter 계정 생성

openrouter.ai에서 이메일 또는 Google 계정으로 가입하세요. 2분 내에 완료됩니다. 무료 모델은 결제 정보 없이 바로 사용 가능합니다.

2단계: API 키 생성

  1. 오른쪽 상단 아바타 클릭
  2. API Keys 선택
  3. Create Key 클릭
  4. 이름 지정(예: qwen-test) 후 Create
  5. 생성된 키(sk-or-v1-...) 복사

API 키 생성

키는 한 번만 보이므로 반드시 안전하게 보관하세요.

3단계: 첫 번째 요청 보내기

모델 ID: qwen/qwen3.6-plus-preview:free

OpenRouter는 OpenAI API와 동일한 요청 포맷을 사용합니다. OpenAI 호환 클라이언트라면 그대로 사용할 수 있습니다.

cURL 예제

curl https://openrouter.ai/api/v1/chat/completions \
  -H "Authorization: Bearer sk-or-v1-YOUR_KEY_HERE" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "qwen/qwen3.6-plus-preview:free",
    "messages": [
      {
        "role": "user",
        "content": "Write a Python function that parses a JWT token and returns the payload as a dictionary."
      }
    ]
  }'
Enter fullscreen mode Exit fullscreen mode

Python (requests) 예제

import requests

def call_qwen(prompt: str, api_key: str) -> str:
    response = requests.post(
        "https://openrouter.ai/api/v1/chat/completions",
        headers={
            "Authorization": f"Bearer {api_key}",
            "Content-Type": "application/json",
        },
        json={
            "model": "qwen/qwen3.6-plus-preview:free",
            "messages": [{"role": "user", "content": prompt}],
        },
        timeout=60,
    )
    response.raise_for_status()
    return response.json()["choices"][0]["message"]["content"]

result = call_qwen(
    "Write a Python function that parses a JWT token and returns the payload.",
    api_key="sk-or-v1-YOUR_KEY_HERE"
)
print(result)
Enter fullscreen mode Exit fullscreen mode

Node.js (fetch) 예제

async function callQwen(prompt, apiKey) {
  const response = await fetch("https://openrouter.ai/api/v1/chat/completions", {
    method: "POST",
    headers: {
      "Authorization": `Bearer ${apiKey}`,
      "Content-Type": "application/json",
    },
    body: JSON.stringify({
      model: "qwen/qwen3.6-plus-preview:free",
      messages: [{ role: "user", content: prompt }],
    }),
  });

  if (!response.ok) {
    throw new Error(`OpenRouter error: ${response.status} ${await response.text()}`);
  }

  const data = await response.json();
  return data.choices[0].message.content;
}

callQwen(
  "Write a JavaScript function that validates an email address.",
  "sk-or-v1-YOUR_KEY_HERE"
).then(console.log);
Enter fullscreen mode Exit fullscreen mode

OpenAI SDK (Python)

from openai import OpenAI

client = OpenAI(
    base_url="https://openrouter.ai/api/v1",
    api_key="sk-or-v1-YOUR_KEY_HERE",
)

response = client.chat.completions.create(
    model="qwen/qwen3.6-plus-preview:free",
    messages=[
        {
            "role": "system",
            "content": "You are a senior backend engineer. Write clean, production-ready code."
        },
        {
            "role": "user",
            "content": "Write a Python function that retries a failed HTTP request up to 3 times with exponential backoff."
        }
    ],
)

print(response.choices[0].message.content)
Enter fullscreen mode Exit fullscreen mode

도구 사용 및 에이전트 워크플로우

Qwen 3.6은 무료 모델 중에서 도구 사용 능력이 뛰어납니다. 아래는 OpenAI SDK로 함수 호출 도구를 정의하는 예제입니다.

from openai import OpenAI
import json

client = OpenAI(
    base_url="https://openrouter.ai/api/v1",
    api_key="sk-or-v1-YOUR_KEY_HERE",
)

tools = [
    {
        "type": "function",
        "function": {
            "name": "search_api_docs",
            "description": "Search the API documentation for a specific endpoint or parameter",
            "parameters": {
                "type": "object",
                "properties": {
                    "query": {
                        "type": "string",
                        "description": "The search query"
                    },
                    "version": {
                        "type": "string",
                        "enum": ["v1", "v2", "v3"],
                        "description": "API version to search"
                    }
                },
                "required": ["query"]
            }
        }
    },
    {
        "type": "function",
        "function": {
            "name": "run_api_test",
            "description": "Execute a test request against an API endpoint",
            "parameters": {
                "type": "object",
                "properties": {
                    "endpoint": {"type": "string"},
                    "method": {"type": "string", "enum": ["GET", "POST", "PUT", "DELETE"]},
                    "body": {"type": "object"}
                },
                "required": ["endpoint", "method"]
            }
        }
    }
]

messages = [
    {
        "role": "user",
        "content": "Find documentation for the /users endpoint and run a test GET request against it."
    }
]

response = client.chat.completions.create(
    model="qwen/qwen3.6-plus-preview:free",
    messages=messages,
    tools=tools,
    tool_choice="auto",
)

message = response.choices[0].message

if message.tool_calls:
    for tool_call in message.tool_calls:
        print(f"Tool: {tool_call.function.name}")
        args = json.loads(tool_call.function.arguments)
        print(f"Arguments: {json.dumps(args, indent=2)}")
else:
    print(message.content)
Enter fullscreen mode Exit fullscreen mode

모델은 함수 호출 형태로 결과를 반환하며, 실제 함수 실행은 사용자 코드가 담당합니다. 이러한 방식으로 다단계 에이전트 워크플로우를 쉽게 구축할 수 있습니다.

100만 토큰 컨텍스트 창 활용법

100만 토큰 컨텍스트는 대량의 데이터를 한 번에 처리해야 할 때 진가를 발휘합니다.

전체 코드베이스 검토

코드베이스 전체를 입력해 보안 취약점, 에러 미처리 함수, 네이밍 불일치 등을 자동 점검할 수 있습니다.

import os
from pathlib import Path
from openai import OpenAI

client = OpenAI(
    base_url="https://openrouter.ai/api/v1",
    api_key="sk-or-v1-YOUR_KEY_HERE",
)

def load_codebase(directory: str, extensions: list[str]) -> str:
    content_parts = []
    for path in Path(directory).rglob("*"):
        if path.suffix in extensions and path.is_file():
            try:
                text = path.read_text(encoding="utf-8", errors="ignore")
                content_parts.append(f"--- FILE: {path} ---\n{text}\n")
            except Exception:
                continue
    return "\n".join(content_parts)

codebase = load_codebase("./src", [".py", ".js", ".ts"])

response = client.chat.completions.create(
    model="qwen/qwen3.6-plus-preview:free",
    messages=[
        {
            "role": "user",
            "content": f"Review this codebase and identify:\n1. Security vulnerabilities\n2. Functions with no error handling\n3. Inconsistent naming conventions\n\nCodebase:\n{codebase}"
        }
    ],
)

print(response.choices[0].message.content)
Enter fullscreen mode Exit fullscreen mode

대규모 문서 분석

긴 법률 문서, 보고서, 논문 등에서 원하는 정보를 추출할 수 있습니다.

with open("annual_report_2025.txt", "r") as f:
    document = f.read()

response = client.chat.completions.create(
    model="qwen/qwen3.6-plus-preview:free",
    messages=[
        {
            "role": "user",
            "content": f"Extract all mentions of API rate limits and pricing changes from this document:\n\n{document}"
        }
    ],
)
Enter fullscreen mode Exit fullscreen mode

전체 기록을 포함한 다단계 대화

프롬프트를 잘라내지 않고 전체 대화 기록을 유지할 수 있어, 긴 디버깅 세션이나 면접에 유용합니다.

conversation = []

def chat(user_message: str) -> str:
    conversation.append({"role": "user", "content": user_message})
    response = client.chat.completions.create(
        model="qwen/qwen3.6-plus-preview:free",
        messages=conversation,
    )
    assistant_message = response.choices[0].message.content
    conversation.append({"role": "assistant", "content": assistant_message})
    return assistant_message

print(chat("I'm getting a 401 error from the GitHub API. Here's my code..."))
print(chat("I added the token but now I get a 403. The token has repo scope."))
print(chat("The repo is private. What scopes do I actually need?"))
Enter fullscreen mode Exit fullscreen mode

Apidog로 OpenRouter API 요청 테스트하기

OpenRouter API를 사용할 때 반복 테스트와 디버깅은 필수입니다. 명령줄이나 Postman으로는 한계가 있습니다.

Apidog 예시

Apidog은 요청 작성, 응답 검사, 테스트 자동화를 한 번에 처리할 수 있는 무료 API 클라이언트입니다.

Qwen 3.6 엔드포인트 테스트 방법:

  1. https://openrouter.ai/api/v1/chat/completions에 POST 요청 생성
  2. 헤더에 Authorization: Bearer sk-or-v1-... 추가
  3. 본문을 model, messages 포함 JSON으로 작성
  4. 요청 실행 후 응답 확인

컬렉션 저장, 모델 ID 전환, 자동화 테스트(응답 구조·함수명 체크 등)까지 지원합니다.

OpenRouter 기반 앱을 만든다면, Apidog에서 몇 가지 테스트 케이스를 먼저 만들어두면 예기치 못한 문제시 빠른 디버깅이 가능합니다.

무료 계층 제한 및 유의사항

Qwen 3.6은 현재 무료지만, 영구적으로 유지된다는 보장은 없습니다. 실전 투입 전 다음을 반드시 고려하세요.

1. 요청 제한(Throttle) 존재

  • 무료 모델 용량은 전체 사용자와 공유합니다.
  • 피크 타임(미국 저녁 등)에는 지연·요청 제한 오류가 자주 발생할 수 있습니다.
  • 모든 코드에 재시도 로직 필수!
import time
import requests
from requests.adapters import HTTPAdapter
from urllib3.util.retry import Retry

session = requests.Session()
retry_strategy = Retry(
    total=3,
    backoff_factor=2,
    status_forcelist=[429, 500, 502, 503, 504],
)
adapter = HTTPAdapter(max_retries=retry_strategy)
session.mount("https://", adapter)

response = session.post(
    "https://openrouter.ai/api/v1/chat/completions",
    headers={"Authorization": "Bearer sk-or-v1-YOUR_KEY_HERE"},
    json={
        "model": "qwen/qwen3.6-plus-preview:free",
        "messages": [{"role": "user", "content": "Hello"}],
    },
    timeout=30,
)
Enter fullscreen mode Exit fullscreen mode

2. 데이터 수집

  • OpenRouter는 프롬프트/완성 데이터를 모델 개선 목적으로 저장합니다.
  • API 키, 비밀번호, 개인정보 등은 주지 마세요.

3. 미리보기 상태

  • 베타 버전이므로, 동작이 예고 없이 달라질 수 있습니다.
  • 프로덕션 사용 시 모델 ID를 고정하고, 회귀 테스트를 주기적으로 확인하세요.

4. 텍스트 전용

  • Qwen 3.6은 텍스트 입력/출력만 지원합니다. 이미지, 오디오, 파일 업로드는 불가합니다.

실제 사용 사례

코드 리뷰 에이전트: 내부 PR 도구를 만들어 전체 diff(수만 줄)를 Qwen 3.6에 넣고 논리 오류, 누락 테스트, 보안 취약점 피드백을 바로 받음. 100만 토큰 컨텍스트 덕분에 청킹 없이 가능.

프론트엔드 컴포넌트 생성: SaaS 대시보드 개발자가 디자인 사양으로부터 바로 React 컴포넌트(TypeScript, 반응형 CSS 포함) 생성.

API 문서 요약: 결제 API 마이그레이션 시 두 API 전체 문서(각 10만 토큰)를 한 번에 넣고 인증·웹훅·요청 제한 비교표를 30초 내에 생성.

openrouter.ai에서 계정 생성, 키 발급 후, 유료 모델 대신 qwen/qwen3.6-plus-preview:free로 바로 테스트해 보세요.

자주 묻는 질문

Qwen 3.6은 무료인가요?

네. 2026년 3월 현재 OpenRouter에서 입력/출력 100만 토큰당 $0입니다. 미리보기 기간 종료 후에는 가격이 변동될 수 있으니, OpenRouter 가격 페이지에서 최신 정보를 확인하세요.

무료 계층의 요청 제한은?

공개 제한치는 없지만, 모든 사용자가 용량을 공유합니다. 트래픽이 많으면 스로틀링이 발생할 수 있으니 재시도 로직을 반드시 추가하세요.

상업적 프로젝트에 쓸 수 있나요?

OpenRouter에서 상업적 사용이 가능합니다. 단, 결과물을 배포할 경우 Alibaba Cloud Qwen 모델 라이선스도 반드시 확인해야 합니다.

Qwen 3.6이 답변이 느린 이유는?

필수 사고 과정(chain-of-thought) 토큰이 있기 때문입니다. 응답 전 내부 추론을 거치므로 단순 질문에도 몇 초가 추가될 수 있습니다. 복잡한 작업에는 그만한 가치가 있습니다. 출력 스트리밍을 사용하면 중간 결과를 바로 볼 수 있습니다.

추론 토큰 비활성화 가능한가요?

아니요. 미리보기 버전에서는 추론이 필수입니다. 빠른 응답이 필요하다면 LLaMA 3.1 8B 등 더 작은 무료 모델을 추천합니다.

100만 토큰 컨텍스트 창이 비용에 영향이 있나요?

무료 계층에서는 영향이 없습니다. 단, 큰 요청은 처리 시간이 길고, 무료 계층에서는 시간 초과가 더 쉽게 발생할 수 있습니다(30~60초 timeout 추천).


Top comments (0)