List models
curl --request GET \
--url https://api-direct.dimilinks.com/v1/models \
--header 'Authorization: Bearer <token>'import requests
url = "https://api-direct.dimilinks.com/v1/models"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api-direct.dimilinks.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-direct.dimilinks.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",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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-direct.dimilinks.com/v1/models"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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-direct.dimilinks.com/v1/models")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-direct.dimilinks.com/v1/models")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"object": "list",
"data": [
{
"id": "claude-sonnet-5",
"object": "model",
"created": 1777080000,
"owned_by": ""
}
]
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"code": "<string>"
}
}基本
モデル一覧
現在の API Key で利用できるモデルを照会します。
GET
/
models
List models
curl --request GET \
--url https://api-direct.dimilinks.com/v1/models \
--header 'Authorization: Bearer <token>'import requests
url = "https://api-direct.dimilinks.com/v1/models"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api-direct.dimilinks.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-direct.dimilinks.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",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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-direct.dimilinks.com/v1/models"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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-direct.dimilinks.com/v1/models")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-direct.dimilinks.com/v1/models")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"object": "list",
"data": [
{
"id": "claude-sonnet-5",
"object": "model",
"created": 1777080000,
"owned_by": ""
}
]
}{
"error": {
"message": "<string>",
"type": "invalid_request_error",
"code": "<string>"
}
}現在のキーで呼び出せるモデル一覧を取得します。レスポンスの
data[] にはテキスト、画像、動画の各モデルが含まれ、id のプレフィックスで区別できます。
リクエスト
curl "https://api-direct.dimilinks.com/v1/models" \
-H "Authorization: Bearer $DIMILINKS_API_KEY"
レスポンス
{
"object": "list",
"data": [
{ "id": "claude-opus-4-8", "object": "model", "created": 1777080000, "owned_by": "" },
{ "id": "claude-sonnet-5", "object": "model", "created": 1777080000, "owned_by": "" },
{ "id": "claude-haiku-4-5", "object": "model", "created": 1777080000, "owned_by": "" },
{ "id": "gpt-5.5", "object": "model", "created": 1777080000, "owned_by": "" },
{ "id": "gpt-5.6-terra", "object": "model", "created": 1777080000, "owned_by": "" },
{ "id": "kimi-k2.7-code", "object": "model", "created": 1777080000, "owned_by": "" },
{ "id": "qwen3.7-max", "object": "model", "created": 1777080000, "owned_by": "" },
{ "id": "gpt-image-2", "object": "model", "created": 1777080000, "owned_by": "" },
{ "id": "grok-imagine-video", "object": "model", "created": 1777080000, "owned_by": "" }
]
}
推奨モデル
| 用途 | 推奨モデル |
|---|---|
| 汎用対話、文章作成、長文書の処理 | claude-sonnet-5、claude-opus-4-8、gpt-5.5 |
| 複雑な推論 / コーディング | claude-opus-4-8、kimi-k2.7-code、gpt-5.6-terra |
| 低コストのバッチタスク | claude-haiku-4-5、gpt-5.4-mini、deepseek-v4-flash |
| 画像生成 / 編集 | gpt-image-2 |
| 動画生成 | grok-imagine-video |
利用上の推奨事項
- モデル一覧はオンラインでの提供状況に応じて変わります。
/v1/modelsを実行時の情報源とし、ハードコードしないでください。 - 最新モデルと機能フィールドの選び方については、モデルの選択と更新 を参照してください。
- モデルはそれぞれ異なるグループに属し、グループが課金倍率を直接決定します。詳しくは モデルグループと料金 を参照してください。
403 model_not_allowedが返された場合は、このキーに対象モデルの利用権限があるか確認してください。多くの場合、API Key の利用可能グループと対象モデルのenable_groupsに共通項がありません。- テキストモデルはデフォルトで
/v1/chat/completionsまたは/v1/messages、画像は/v1/images/*、動画は/v1/videos/*を使用します。