OpenAI Streaming Plugin CORS errors

Hi -

Can somebody help me solve CORS errors I am running into with my OpenAI assistants streaming plugin? I have tried a couple different approaching including websocket and polling but I am continuously running into CORS errors on the client side…

Any suggestions or insight would be appreciated. My goal is just to create a simple plugin which streams messages from the assistants API.

Thanks

You need to try from the server side because client side will throw cors error and you can do nothing about it.
One way is setting a server between which accept response as a backend and then pass it to you in the front.

Hope it helps

You might want to check out existing solution, unless you have specific requirements.

On the server side, the place receiving your request, you should add something like Allow-origins to * and Allow-method to * in your code’s response body.
Hope that helps

This topic was automatically closed after 70 days. New replies are no longer allowed.