100 days of code - day 37

 Today was a straight up API day using requests and little more.

This is in preparation for tomorrow where I do my first 6 min, so there is likely no walk through and no solutions provided.

We used the API set at https://pixe.la

This is a cool website that makes is easy to create a habit tracker (much like the commit tracker in github)

For the first time in a while I used something other than requests.get .

One of the standout things I noticed was that when you use put, post and delete from requests, you no longer have the params argument. Instead you use a json= argument. This was new for me as I wasn't aware of it before.

I also gained a proper understanding of the difference between headers= and params= in the requests.get method.

The basics (as I understand it) is that headers will pass the information silently (and thus wont display things like API keys into the browser bar) where as params will pass the details as part of the URL.

Comments

Popular Posts