This project is the final project of Python Developer bootcamp at Future Collars.
The project allows you to download exchange rate data from the NBP Web API and perform several operations on the downloaded data:
- currency conversion
- comparing exchange rates
- generation of time series charts
- preview Middle exchange rates of foreign currencies - table A from National Bank of Poland (Narodowy Bank Polski)
Project is created with:
- Python version: 3.9.x
- Flask version: 2.2.2
- SQLAlchemy version: 1.4.44
- requests version: 2.28.1
- plotly version: 5.11.0
The recommended way to get the source code of this project is by cloning this remote repository. You can that on any computer with Git installed with the following command:
$ git clone https://github.com/filrat2/currencies
To run this project, install all required Python modules in your virtual environment with the following command:
(venv) $ pip3 install -r requirements.txt
Before starting the server for the first time, you must download the data from National Bank of Poland (Narodowy Bank Polski) with the following command:
(venv) $ python3 download_data.py start-date end-date
Dates (start-date and end-date) must be provided in the YYYY-MM-DD format (ISO 8601 standard), for example:
(venv) $ python3 download_data.py 2022-09-29 2022-12-31 #a period of 93 days
Historic data for currency exchange rates are available since 2 January 2002 and a single enquiry cannot cover a period longer than 93 days. This data comes from Middle exchange rates of foreign currencies – table A.
To start server on your local machine use following command:
(venv) $ python3 -m flask --app backend run
To start server with active debugger on your local machine use following command:
(venv) $ python3 -m flask --app backend --debug run
- loop for downloading data from a period longer than 93 days
- more than one currency on plotly chart
- use the cron command-line tool (job scheduler) for daily automatic data download
- start hosting this project on free online service that gives a way to run Python programs inside a browser, like PythonAnywhere
- improve the appearance of the website
Hi, my name is Filip Ratajszczak and I am a geoinformation student at the Adam Mickiewicz University, Poznan, Poland.