i am using OKHttp for my project. i want to enable TLSv1.2 for my service call. can any body tell me how to enable it.
As far as I know OKHttp does not include own SSL/TLS libraries, therefore it just uses the standard SSLSocket provided by Android.
What TLS versions are supported (and enabled) depends on the used Android version.
On some phone TLS 1.2 is supported but not enabled by default. In such cases you could enable it by implementing a custom wrapper SSLSocketFactory that uses internally the default SSLSocketFactory and calls setEnabledProtocols(new String{"TLS1.2"}) on every Socket that is created.