Skip to content

Commit 752aa52

Browse files
committed
跟进官网参数设定
1 parent b2cc132 commit 752aa52

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "deepseek-free-api",
3-
"version": "0.0.17",
3+
"version": "0.0.20",
44
"description": "DeepSeek Free API Server",
55
"type": "module",
66
"main": "dist/index.js",

src/api/controllers/chat.ts

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,15 +29,18 @@ const FAKE_HEADERS = {
2929
Priority: "u=1, i",
3030
Referer: "https://chat.deepseek.com/",
3131
"Sec-Ch-Ua":
32-
'"Chromium";v="130", "Google Chrome";v="130", "Not?A_Brand";v="99"',
32+
'"Chromium";v="133", "Google Chrome";v="133", "Not?A_Brand";v="99"',
3333
"Sec-Ch-Ua-Mobile": "?0",
3434
"Sec-Ch-Ua-Platform": '"Windows"',
3535
"Sec-Fetch-Dest": "empty",
3636
"Sec-Fetch-Mode": "cors",
3737
"Sec-Fetch-Site": "same-origin",
3838
"User-Agent":
39-
"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36",
40-
"X-App-Version": "20241129.1"
39+
"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/133.0.0.0 Safari/537.36",
40+
"X-App-Version": "20241129.1",
41+
"X-Client-Locale": "zh-CN",
42+
"X-Client-Platform": "web",
43+
"X-Client-Version": "1.0.0-always",
4144
};
4245
const EVENT_COMMIT_ID = '41e9c7b1';
4346
// 当前IP地址
@@ -155,7 +158,7 @@ async function createSession(model: string, refreshToken: string): Promise<strin
155158
const result = await axios.post(
156159
"https://chat.deepseek.com/api/v0/chat_session/create",
157160
{
158-
agent: "chat",
161+
character_id: null
159162
},
160163
{
161164
headers: {

0 commit comments

Comments
 (0)