You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
1.0 KiB
37 lines
1.0 KiB
import request from "../utils/request";
|
|
|
|
const APIurl = import.meta.env.VITE_APP_API_BASE_URL;
|
|
const MJAPIurl = import.meta.env.VITE_APP_MJ_API_BASE_URL;
|
|
|
|
|
|
// 工作流获取用户意图接口
|
|
export const getReplyAPI = function (params) {
|
|
return fetch("https://api.coze.cn/v1/workflow/run", {
|
|
method: "POST",
|
|
body: JSON.stringify({
|
|
workflow_id: "7512677411467001910",
|
|
parameters: params,
|
|
}),
|
|
headers: {
|
|
"Content-Type": "application/json",
|
|
Authorization:
|
|
"Bearer pat_cOhJRgrEpjXwJJLW1N3YNjCxy19HYTpMFY6XlNCLi4ogm5tdfV266gWIB7MeaRIU",
|
|
},
|
|
});
|
|
};
|
|
|
|
// 获取第二个工作流给出的结论
|
|
export const getConclusionAPI = function (params) {
|
|
return fetch("https://api.coze.cn/v1/workflow/run", {
|
|
method: "POST",
|
|
body: JSON.stringify({
|
|
workflow_id: "7509384582975897650",
|
|
parameters: params,
|
|
}),
|
|
headers: {
|
|
"Content-Type": "application/json",
|
|
Authorization:
|
|
"Bearer pat_cOhJRgrEpjXwJJLW1N3YNjCxy19HYTpMFY6XlNCLi4ogm5tdfV266gWIB7MeaRIU",
|
|
},
|
|
});
|
|
};
|