This application is the final project of the Curso de FastAPI: Modularización, Datos Avanzados y Errores course of platzi. This app adds to the tweet updates feature. The user and tweet data is stored in a PostgreSQL database, it also has validations and restrictions.
Dependencies for Docker:
First you need to clone the repository.
git clone https://github.com/camicontr/twitter-api-fastapi.git
To install twitter-api-fastapi on a docker container, run the following command:
docker compose --env-file .env up
To run the API in the Docker container, run the following command:
Configure the server in pgadmin
- Go into pgadmin localhost:80, with user: admin@admin.com and password: admin
- Register a new server with name: DockerConnect, hostname: db, user and password: postgres
- Use
docker start twitter-api-fastapi_app
At this moment the app can already connect to the database
- Go into
http://localhost:8000/docs
here you will find all the documentation and you can use the api.