The Dobby Club API

Python . FastAPI . Vercel . Supabase . PostGres SQL

The ultimate REST API for the UK sitcom Peep Show.

I’m a huge nerd who likes Python and Peep Show so I thought I would build an API dedicated the show.

This API allows you to search the entire series for your favourite quote, listen to the internal monologues from Mark and Jez (characters), or read up on the actors who play them.

The Dobby Club API is built using the Python framework FastAPI hosted in Vercel for it’s lightweight deployment and CI/CD integration with Github. The database is a PostGres SQL database supplied by Supabase.

Overview

It’s no secret that fans of Peep Show love to quote the show and the memes that pair with them. There isn’t a conversation my friends and I don’t quote the show.

With The Dobby Club API fans can easily search the entire series for their favourite quotes, memes, and more.

The API returns JSON data on actors, characters, quotes and more. They can also search a goldmine of memes, avatars, and audio they can easily integrate into their applications.

The API is entirely free to use however certain limitations such as rate limiting has been built to avoid abuse.

I would LOVE for you to contribute to the project. If that’s building a new feature, helping maintain the database, or even if it’s just making sure your favourite meme is here PLEASE reach out or follow the contributing steps in the repo.

“Everything’s cool in The Dobby Club”

- Gerrard

  • FastAPI is a modern, fast web framework for building APIs with Python. It is designed for high performance and ease of use, allowing developers to quickly create robust, production-ready APIs. FastAPI uses asynchronous programming and automatic validation through Python type hints, making it both efficient and developer-friendly.

  • A cloud platform that simplifies the deployment and hosting of web applications. It offers automatic scaling, quick deployments, and serverless functions, making it a popular choice for developers.

  • Supabase is an open-source backend platform that provides a suite of tools for building scalable applications. It offers features like a real-time PostgreSQL database, authentication, and storage. It is often compared to Firebase (by Google) but is built on open standards, giving developers more control over their projects.

  • The database is a PostrGres SQL relational database. I sourced and pre-processed the data before adding to the database I had designed with the end user in mind. Creating relationships between data that they would find useful such as quote and meme. Furthermore,

  • Docker allows developers to create, deploy, and run applications in isolated environments called containers. Containers package an application and its dependencies, ensuring it runs consistently across different systems. Although Vercel does a good job of this already following best practice I have utilised a container here for consistency.

  • This is a Python library that provides rate-limiting functionality for FastAPI applications. It helps control the number of requests a user or client can make within a specified time, protecting APIs from being overwhelmed by excessive traffic or abuse. This API is limited to 5 calls a second enhancing API security and performance.

  • To secure the database from attacks such as SQL injection or unnecessary queries steps have been taken to sanitise and secure the input from users. The use of Enum in series options restricts the user to only a number that corresponds with a valid series. Furthermore, the use of the Supabase library over raw SQL to perform prepared statements.

Technical Details

Project Links

GitHub

GitHub

Live Docs

Live Docs

Contributing

Contributing

Previous
Previous

Python Library for Odin API (by Rev.io)

Next
Next

Visualising Conversational AI App