HASH FUNCTION
Hash Function helps to find where the data is located. Somewhat related to data structure
APPLICATION PROGRAMMING INTERFACE (API)
API – Third Party Function –helps to do some activity –get the required data for our Program.
In programming languages it allow developers to interact with other systems / application to get data
(E.g)
OLA/UBER uses Google Map API
Some signup websites uses Gmail and Facebook API
SOAP API VS REST API
Older Version --Simple Object Access Protocol - Introduced by MicroSoft - XML
Current Version --REpresentational State Transfer – Supported by Google – json/xml
REST API – Simple and Look like a Web URL
FUTURE API -- PROTOBUF
HOW CAN WE USE API IN OUR PROGRAM TO GET DATA
XML VERSION
JSON VERSION
OPEN API
Easy to Access
Just enter URL & Get the data
https://restcountries.eu/rest/v2/all
CORS API - Cross Orgin Resource Sharing
Works perfectly in Back end. (Whenever we are running the code in the server it gives the data) but in Front end it gives Error (Whenever we run directly in the browser it shows error)
To run this kind of API in browser console we need additional proxy server
API
https://api.domainsdb.info/v1/domains/search?domain=facebook&zone=com
PROXY
https://cors-anywhere.herokuapp.com/
url = PROXY+API
AUTH API
To get this kind of API / API data we need some authorization and authentication from the third party
http://api.openweathermap.org/data/2.5/weather?q=New%20Delhi&appid=4d28367ef9a7022ee96d046c2a1f2b5f
To get the above API we need to get Auth from the below third party website
0 AUTH API - @ Backend Developer Course
MENTORS
How to get data through API in node js
Explanation for codes/keywords
Comments
Post a Comment