Skip to content

rafnixg/bcv-api

Repository files navigation

BCV Exchange Rate API

Documentation

https://rafnixg.github.io/bcv-api/

Description

This API is used to get the exchange rate of the BCV (Central Bank of Venezuela). This API is a simple REST API that returns the exchange rate of the BCV in JSON format.

Installation

  1. Clone the repository and create a .env file in the root of the project, use .env.example as a template Remember to replace the values of the variables with your own values.
git clone https://github.com/rafnixg/bcv-api.git
cd bcv-api
cp .env.example .env
  1. Create a virtual environment
python -m venv venv
  1. Activate the virtual environment
# Windows
venv\Scripts\activate
# Linux
source venv/bin/activate
  1. Install the dependencies
pip install -r requirements.txt
  1. Run the API
uvicorn bcv_api.main:app --reload
  1. Open your browser and go to http://localhost:8000

Using Docker

  1. Clone the repository and create a .env file in the root of the project, use .env.example as a template Remember to replace the values of the variables with your own values.
git clone
cd bcv-api
cp .env.example .env
  1. Build the image with the Dockerfile, select the Dockerfile.newrelic file if you want to monitor the application with NewRelic
# Without newrelic monitoring
docker build -t bcv-api .

# With newrelic monitoring
docker build -t bcv-api -f Dockerfile.newrelic .
  1. Run the container
docker run -d --name bcv-api -p 8000:8000 --env-file .env bcv-api:latest
  1. Open your browser and go to http://localhost:8000

Built With

Author

License

This project is licensed under the GNU General Public License v3.0 - see the LICENSE file for details.