토큰이 지원하는 모델 조회
curl --request GET \
--url https://api.example.com/v1/modelsimport requests
url = "https://api.example.com/v1/models"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/v1/models', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/v1/models",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/models"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.example.com/v1/models")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/models")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodyAPI 키 & 콘솔 관리
토큰이 지원하는 모델 조회
지정한 토큰에서 사용 가능한 모델 목록을 조회합니다
GET
/
v1
/
models
토큰이 지원하는 모델 조회
curl --request GET \
--url https://api.example.com/v1/modelsimport requests
url = "https://api.example.com/v1/models"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/v1/models', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/v1/models",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/models"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.example.com/v1/models")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/models")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body업데이트: 2026-06-06
인터페이스 설명
현재 토큰(API Key)이 호출할 수 있는 모델 목록을 조회합니다. 토큰에 모델 제한이 없으면 시스템에서 활성화된 모든 모델을 반환합니다. 현재 권장되며 실제로 지원되는 인터페이스는 다음과 같습니다.GET /v1/models
GET /api/token/models는 현재 공개적으로 사용할 수 있는 인터페이스가 아니므로 /v1/models를 사용하세요.
인증 방식
API Key(sk-xxx)를 사용해 인증합니다.Authorization: Bearer sk-xxx
응답 형식
{
"success": true,
"object": "list",
"data": [
{
"id": "gpt-5.5",
"object": "model",
"owned_by": "openai"
},
{
"id": "claude-opus-4-8",
"object": "model",
"owned_by": "anthropic"
}
]
}
코드 예시
from openai import OpenAI
client = OpenAI(
api_key="sk-xxx",
base_url="https://api.crazyrouter.com/v1"
)
# OpenAI SDK를 통해 모델 목록 가져오기
models = client.models.list()
for model in models.data:
print(model.id)
import requests
response = requests.get(
"https://api.crazyrouter.com/v1/models",
headers={"Authorization": "Bearer sk-xxx"}
)
models = response.json()["data"]
for model in models:
print(model["id"])
curl https://api.crazyrouter.com/v1/models \
-H "Authorization: Bearer sk-xxx"
OpenAI SDK를 사용하는 경우
client.models.list()는 실제로 GET /v1/models를 호출하는 것입니다.