@Dean #44 设置了,foxapi可以拉出来,但是NextChat连接就显示:已拦截跨源请求:同源策略禁止读取位于 https://xxxx.zeabur.app/v1/chat/completions 的远程资源。(原因:CORS 预检响应未能成功)。状态码:404 Access to fetch at 'https://xxxxx.zeabur.app/v1/chat/completions' from origin 'https://xxxxx.zeabur.app' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: It does not have HTTP ok status.
@Dean #44 StackOverflow上查了一下, 好像是You don't have a handler for service.options("/" so it 404s. You need to respond with a 200 OK status. 也可以参见这个:https://www.cnblogs.com/jaycethanks/p/16917117.html
@Dean #31 大佬,你帖子里用的post工具是啥
@everum #41 postman 不过我好多同事说没有apifox好用
大佬,apifox可以显示回答内容,但是NextChat显示failed to fetch,不知道是为啥
@everum #43 环境变量设置默认channelId了吗
@Dean #44 设置了,foxapi可以拉出来,但是NextChat连接就显示:已拦截跨源请求:同源策略禁止读取位于 https://xxxx.zeabur.app/v1/chat/completions 的远程资源。(原因:CORS 预检响应未能成功)。状态码:404
Access to fetch at 'https://xxxxx.zeabur.app/v1/chat/completions' from origin 'https://xxxxx.zeabur.app' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: It does not have HTTP ok status.
请问下有办法做到客户端新建会话的功能吗?
我发现在新建DOCKER容器时如果不指定默认频道的话是信息是发不到频道里的,但是如果指定频道,客户端的新建会话功能是不生效的,前面问的问题还是在上下文中
@Dean #44
StackOverflow上查了一下, 好像是You don't have a handler for service.options("/" so it 404s.
You need to respond with a 200 OK status.
也可以参见这个:https://www.cnblogs.com/jaycethanks/p/16917117.html
@everum #45 docker查看下什么时候拉取的镜像 今天修改了一次跨域的问题
@5700pgf #46 如果想用openai对齐的接口新建会话比较难,如果使用项目自有的接口可以传递discord的频道/线程id来新建会话
感谢大佬,接到lobechat用了,lobe的接口地址要填到/v1,试了好久才发现