Code Challenge 41 - Daily Python Tip Part 2 - Build an API

PyBites, Wed 01 November 2017, Challenge

API, Bottle, Daily Python Tip, Django, Flask

It's not that I'm so smart, it's just that I stay with problems longer. - A. Einstein

Hi Pythonistas, you heard of Daily Python Tip? It's a Twitter account that posts one python tip per day, run by @karlafej and @simecek. We partnered up with them and use their awesome collection of tips to build a web app (part 1) and a simple API (part 2).

The Challenge

If you built a web app for part 1 you could use its data / backend. If not just use the Daily Python Tip's backend. We want this challenge to be independent so API lovers are not required to build a web app first.

The goal is to make a simple API using Flask, Django Rest Framework of another (Python) framework. Something the guys at Daily Python Tip could actually use!

HTTP verbs / actions:

If you took part 1 and are using your own DB / backend you could also implement:


  1. Add Twitter login / authentication to your API so you can implement more actions:
  2. Only allow POST upon login
  3. Add your Twitter handle upon POSTing a new tip
  4. Make a user endpoint with likes, bookmarks, etc
  5. Be creative ...
  6. Host it to the cloud (Heroku, PythonAnywhere, ...)

Slack Channel

For a beginner some of our challenges might be overwhelming. Another observation is that the process of doing these challenges is as interesting as the final result.

We are eager to expand our awesome PyBites community. For this reason we are opening up our private Slack for you to discuss our code challenges and let us know how you're progressing your Python skills. Send us an email if you want to join.

This way you get the unique opportunity to learn from other Pythonistas and share some of your own learning.


To get credit PR your work to our Community branch of our Challenges repo. See detailed instructions here.


Our goal is to learn and teach you Python through practical exercises. Learning a programming language is way more fun as a community!

For any feedback, issues or ideas use GH Issues, tweet us or drop us an email.

Keep Calm and Code in Python!

-- PyBites

PyBites Python Tips

Do you want to get 250+ concise and applicable Python tips in an ebook that will cost you less than 10 bucks (future updates included), check it out here.

Get our Python Tips Book

"The discussions are succinct yet thorough enough to give you a solid grasp of the particular problem. I just wish I would have had this book when I started learning Python." - Daniel H

"Bob and Julian are the masters at aggregating these small snippets of code that can really make certain aspects of coding easier." - Jesse B

"This is now my favourite first Python go-to reference." - Anthony L

"Do you ever go on one of those cooking websites for a recipe and have to scroll for what feels like an eternity to get to the ingredients and the 4 steps the recipe actually takes? This is the opposite of that." - Sergio S

Get the book