From a4c65fa30ea5ae9303851adedd2afbea0696e016 Mon Sep 17 00:00:00 2001 From: Vinlic Date: Sat, 9 Mar 2024 14:42:18 +0800 Subject: [PATCH] update README --- README.md | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 7883278..92f771d 100644 --- a/README.md +++ b/README.md @@ -4,6 +4,10 @@ https://udify.app/chat/Po0F6BMJ15q5vu2P +## 接入准备 + +从kimi获取refresh_token:进入kimi随便发起一个对话,然后F12打开开发者工具,从Application > Local Storage中找到refresh_token的值,这将作为API_KEY。 + ## 安装 请先安装好Node.js环境并且配置好环境变量,确认node命令可用。 @@ -48,4 +52,23 @@ pm2 reload kimi-free-api ```shell pm2 stop kimi-free-api -``` \ No newline at end of file +``` + +## 发起请求 + +目前支持与openai兼容的 `/v1/chat/completions` 接口 + +POST /v1/chat/completions + +```json +{ + "messages": [ + { + "role": "user", + "content": "测试" + } + ], + // 如果使用SSE流请设置为true + "stream": false +} +```