https://github.com/fulanii/rest-api-project
https://github.com/fulanii/rest-api-project
beautifulsoup4 bs4 flask flask-api flask-restful psycopg2 psycopg2-binary requests-python
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/fulanii/rest-api-project
- Owner: fulanii
- Created: 2022-11-29T18:53:01.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-08-05T20:30:42.000Z (9 months ago)
- Last Synced: 2025-01-07T16:15:48.895Z (4 months ago)
- Topics: beautifulsoup4, bs4, flask, flask-api, flask-restful, psycopg2, psycopg2-binary, requests-python
- Language: HTML
- Homepage:
- Size: 52.4 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Rest API Project
In this project i built a rest API with python and flask, I first scraped and cleaned country data online. Then stored the data in a PostgreSQL database, I've made the data available with an api. Using the api you can access countries info like: ``` name, capital, population, area size, country code and country iso code.```Finally I made a country fun fact table where you can add a fun fact about any country using a ```POST```request, or edit/update the fun fact with a ```PUT``` request.
- [This project documentations](https://fulanii.github.io/rest-api-project/)
Project Demo
GET endpoints
POST and PUT endpoints
# Run locally
Will be hosting this api online soon, in the meantime you can download it and run it locally by following the steps bellow.1. Clone the repo: ```$ git clone https://github.com/fulanii/rest-api-project.git```
2. cd rest-api-project/project and ``` pip install requirements.txt```
3. connect to a postgres db (replace ```database, user, and password``` fields)
4. run server.py to create the tables, scrape and insert data
5. check out the project [Documentation](https://fulanii.github.io/rest-api-project/)
By the way i did this project in fastapi [check it out](https://github.com/fulanii/fastapi-project)