Introduction & project preview
In this project, we'll build a URL-shortening API tailored as an in-house tool for your company. This is especially handy if you're part of a startup looking to optimize internal processes without the extra expense of third-party services. By crafting our custom solution, we gain flexibility and save on costs.
Topics Covered:
Creating REST endpoints with CRUD functionality: Learn to set up the backbone of our URL shortener, allowing creation, reading, updating, and deletion of shortened URLs.
Enhancing GET requests with pagination and filtering: We'll implement methods to manage large sets of shortened URLs efficiently, ensuring quick access and organization.
Applying validation with DTOs (Data Transfer Objects) and Pipes: Understand how to ensure data integrity and valid requests within our API.
Persisting data with database integration: Dive into how we store and manage our data reliably using a database.
Securing our API with basic API key authentication and Guards: Explore how to protect our API from unauthorized access.
Configuring our service using the Config module: We'll configure our API for different environments with ease and flexibility.
Testing our application: Grasp the importance and techniques for thorough testing with unit tests, integration tests, and end-to-end tests to ensure reliability.
As we progress, remember that this is more than just code; it's about creating a tool that makes our digital life a bit easier. Let's get started!
Here's the Github repo if you want to check out the full code:
https://github.com/tomwray13/url-shortener
And here's the deployed app if you want to give it a spin in Postman:
https://url-shortener-production-c1f9.up.railway.app/url