Kong / unirest-java

Unirest in Java: Simplified, lightweight HTTP client library.
http://kong.github.io/unirest-java/
MIT License
2.6k stars 594 forks source link

Is Unirest supported Server-Sent Events? #525

Open gzlboy opened 5 months ago

gzlboy commented 5 months ago

Many AI APIs now require SSE calls. Does Unirest support it?

ryber commented 5 months ago

Not currently, it does support WebSockets, but not SSE. However there is no reason it cannot support SSE, so I will keep this issue as a feature request.

In the mean time, although I cannot vouch personally for it, this client from Cisco looks like it might be a good option: https://github.com/CiscoSE/commons-networking

gzlboy commented 5 months ago

Got it, looking forward to this feature, thanks!

ryber commented 4 weeks ago

Just putting the link to the spec here so I can stop googling for it https://html.spec.whatwg.org/multipage/server-sent-events.html#server-sent-events