HDTutorial
EN

Playback starts YouTube’s embedded player (privacy-enhanced mode).

Simple HTTP Request with OkHttp - Android Studio Tutorial

144,656 views November 3, 2018 4:20

Watch on YouTube
ChannelCoding in Flow

Description from the creator

In this video we will use the OkHttp library to make a simple asynchronous HTTP request, download a JSON from a URL and display it in a TextView. For this we will use OkHttp's enqueue method which executes the network call in a background thread. To update the TextView we will then access our main thread with the runOnUiThread method.

Dependency + instructions:
square.github.io/okhttp/

Reqres API:
reqres.in/

Example code:
gist.github.com/codinginflow/639a729e567d64a66a…

____________________
💻 Find the BEST programming tutorials on TutHub:
tuthub.io

⭐ Get my MVVM Caching Course now:
codinginflow.com/caching

❗ Subscribe to the channel:
youtube.com/c/codinginflo...

📨 Subscribe to the Coding in Flow newsletter:
codinginflow.com/newsletter

❓ Join our free developer community:
discord.gg/TSnMvmc

📣 Follow Coding in Flow on other sites:
Facebook: facebook.com/codinginflow
Instagram: instagram.com/codinginflow
TikTok: tiktok.com/@codinginflow
Twitter: twitter.com/codinginflow
Github: github.com/codinginflow

💰 Business requests, sponsoring, etc.: [email protected]

About this tutorial

Coding in Flow published this 4:20 video tutorial on November 3, 2018. It has been watched 144,656 times on YouTube.

Duration
4:20
Published
November 3, 2018
Views
144,656
Likes
1,709

Tags

Share

This tutorial in other languages