Flutter REST API Crash Course - Part 2: Building an API Service with the Dart http package

preview_player
Показать описание
Course Link: 👇👇

This is the second chapter of my Flutter REST API crash course, where you will learn how to build this Coronavirus Tracker Application.

Highlights

00:00 - Intro
00:22 - App Architecture Overview
03:14 - Installing the http package
04:32 - Saving the API key + GitHub source code + the Error Lens extension
07:12 - The API class
10:54 - The APIService class: requesting an access token
15:01 - Parsing the http response and retrieving the access token
17:52 - Using the API Service to show the access token
21:09 - Adding the remaining endpoints to the API class
23:57 - Requesting and parsing data from the remaining endpoints
29:32 - Using the APIService class to show endpoint data
33:25 - Recap on the APIService class

Useful links:

NOTE: this complete the course content that is freely available on YouTube.
You can purchase the full course at this link (new content added weekly): 👇👇

Happy Coding!
Рекомендации по теме
Комментарии
Автор

Note: the Nubentos API v1.0.0 is no longer available. You can use this API as a replacement:

CodeWithAndrea
Автор

That is a great idea to create a map between endpoint and paths. Thanks for sharing!

FlutterExplained
Автор

What theme are you using for the visual Studio Code? Its cool...

arafahomarali
Автор

How does Flutter handle withCredentials httponly cookie requests? My API does not implement OAuth. We just use standard httponly session cookies.

fooked
Автор

What is the difference between the special course and the full course on your site?

sonikslayer
Автор

Hi, I'm getting an HTTP/1.1 500 Internal Server Error. The response body is:


{
"code": "ER_PARSE_ERROR",
"errno": 1064,
"sqlMessage": "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' ORDER BY lastUpdated DESC limit 1' at line 1",
"sqlState": "42000",
"index": 0,
"sql": "SELECT lastUpdated AS date, country AS country, active AS data FROM extendedData WHERE ' ORDER BY lastUpdated DESC limit 1;"
}


Any idea what could be the issues here?
When I test the endpoints in the api console I get the same response.

Gabriel_Wangai
Автор

hi, may i know what extension used at 8:16 to create constructor?

dinoXman
Автор

Will you upload the entire course to YouTube?

nickledesmac.
Автор

hi, very nice tutorial. could you please tell what extension that you talked about at 28:57

SeyamMs
Автор

I can't find ".vscode" folder in my project Please help me

suniltimilsina