Skip to content →

RESTful!

RESTful has been something on my mind for a very long time. Ever since i was young, i had stumbled upon something called RESTful… well back when i was still a young developer working on simple html pages for absolute joy.

Today, i will be posting some of the resources I feel that have been of great use  to me when learning how RESTful works. If you’re interested to know more… you should definitely read every last word these articles have to offer.

The below shows how in relation the HTTP methods are with the normal CRUD operations and SQL operations. Picture is taken from scotch.io

There are four main parts to a simple HTTP request

  1. Endpoint (this is basically the url eg: github’s root-endpoint is api-github.com, root-endpoint basically means the starting point hence “root”)
  2. HTTP Method (covered above in the picture)
  3. Headers (just additional information about the request/response more information : https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers)
  4. Content (data/body)

We’ve already covered what methods are.. and on to headers (Headers are simply property-value pairs– to me, this is really just a way of providing information to the client/server -eg so the server may know what this request/response is for… etc!)

As for Content… it’s just the information to be sent to the server. HTTP Status codes & error messages are just as important because they tell you what has happened to your request/response!


Picture is taken from smashingmagazine.com

Finally, i’ve really learnt a lot of what RESTful is due to my knowledge in applying it. I’ve made a simple web-application on C# with the help of what i’ve learnt in school. You’ll be able to download the demo (which helped me to learn here!!: https://github.com/bchewy/CSharp-HTTP-Methods-API-)

References (i do not any of the pictures posted above)
Scotch: https://scotch.io/bar-talk/a-quick-understanding-of-rest
Smashingmagazine : https://www.smashingmagazine.com/2018/01/understanding-using-rest-api/

 

Published in Guides

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: