deepseek-v4-flash
deepseek-v4-flash
ข้อความDeepSeekdeepseekdeepseek-v4-flash

文本对话深度推理

การยืนยันตัวตน

Base URL
https://api.dreamtoai.com
Authorization
Authorization: Bearer YOUR_API_KEY
Content-Type
application/json
ชื่อโมเดล (model)
deepseek-v4-flash

โปรโตคอลการเชื่อมต่อ

ทำไมต้องเลือกโปรโตคอลนี้

适合已有 OpenAI SDK、Chat Completions 代码或统一网关接入的用户。

URL เอนด์พอยต์
POST/v1/chat/completions
Authorization: Bearer YOUR_API_KEYContent-Type: application/json

JSON คำขอและการตอบกลับ

คำขอ
{
  "model": "deepseek-v4-flash",
  "messages": [
    {
      "content": "你好,世界",
      "role": "user"
    }
  ],
  "system_instruction": "你是一个严谨的助手。",
  "temperature": 1,
  "top_p": 1,
  "max_tokens": 4096,
  "stop": [
    "\n\n"
  ],
  "stream": false,
  "stream_options": {
    "include_usage": true
  },
  "thinking": {
    "reasoning_effort": "high",
    "type": "enabled"
  },
  "response_format": {
    "type": "json_object"
  },
  "tools": [],
  "tool_choice": "auto",
  "logprobs": false,
  "top_logprobs": 5,
  "user_id": "user_123"
}
การตอบกลับ
{
  "output": {
    "text": "你好,世界"
  }
}

ฟิลด์คำขอและการตอบกลับ

ฟิลด์คำขอ
ฟิลด์ประเภทจำเป็น
messagesarrayY
system_instructionstringN
temperaturenumberN
top_pnumberN
max_tokensintegerN
stoparrayN
streambooleanN
stream_optionsobjectN
thinkingobjectN
response_formatobjectN
toolsarrayN
tool_choiceenumN
logprobsbooleanN
top_logprobsintegerN
user_idstringN
ฟิลด์การตอบกลับ
ฟิลด์ประเภทจำเป็น
output.textstringN

ตัวอย่างโค้ด

cURLrequest.sh
curl -X POST "https://api.dreamtoai.com/v1/chat/completions" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
  "model": "deepseek-v4-flash",
  "messages": [
    {
      "content": "你好,世界",
      "role": "user"
    }
  ],
  "system_instruction": "你是一个严谨的助手。",
  "temperature": 1,
  "top_p": 1,
  "max_tokens": 4096,
  "stop": [
    "\n\n"
  ],
  "stream": false,
  "stream_options": {
    "include_usage": true
  },
  "thinking": {
    "reasoning_effort": "high",
    "type": "enabled"
  },
  "response_format": {
    "type": "json_object"
  },
  "tools": [],
  "tool_choice": "auto",
  "logprobs": false,
  "top_logprobs": 5,
  "user_id": "user_123"
}'