Does Retrofit support websocket by now?
Asked Answered
D

1

8

I know that it was a work in progress and it was supposed to become a thing in version 2.1, which is the latest version.

So, is it a thing ready now? Couldn't find any info on that topic.

And if it is a thing already, how would use I it?

Diminutive answered 9/8, 2016 at 16:9 Comment(2)
I think it does not support web sockets yet since it's not being mentioned in its changelog: github.com/square/retrofit/blob/master/CHANGELOG.md Hopefully on 2.2.Philately
OkHttp supports WebSockets now. Check out this simple tutorial medium.com/@ssaurel/…Lutestring
C
0

Retrofit is built on top of OkHttp, and OkHttp supports WebSockets starting from the version 3.5, more on this here.

For an example, you can see the following answer on StackOverflow.

Caning answered 8/9, 2023 at 9:55 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.