https://github.com/1deyce/currency-converter-cli
A simple currency converter application that fetches exchange rates and allows users to convert amounts between different currencies.
https://github.com/1deyce/currency-converter-cli
errors fmt go godotenv log os strconv
Last synced: 3 months ago
JSON representation
A simple currency converter application that fetches exchange rates and allows users to convert amounts between different currencies.
- Host: GitHub
- URL: https://github.com/1deyce/currency-converter-cli
- Owner: 1deyce
- Created: 2025-01-07T11:49:19.000Z (5 months ago)
- Default Branch: main
- Last Pushed: 2025-01-07T14:03:03.000Z (5 months ago)
- Last Synced: 2025-01-07T14:45:16.320Z (5 months ago)
- Topics: errors, fmt, go, godotenv, log, os, strconv
- Language: Go
- Homepage:
- Size: 6.84 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Currency Converter
A simple currency converter application that fetches exchange rates and allows users to convert amounts between different currencies.
## Features
- Fetches real-time exchange rates from Open Exchange Rates API.
- Converts amounts between selected currencies.
- Validates user input for currency selection and amount.## Packages Used
- net/http for http requests to the currency exchange api
- github.com/charmbracelet/huh for the TUI interface form
- encoding/json in order to marshal the data for the api## Requirements
- Go (version 1.14 or later)
- An API key from [Open Exchange Rates]## Example
Please select the currency you wish to convert FROM:
1. United States Dollar
2. Great Britain Pound
3. Euro
4. Japanese Yen
5. South African RandPlease enter the amount you wish to convert:
? 100Please select the currency you wish to convert TO:
1. United States Dollar
2. Great Britain Pound
3. Euro
4. Japanese Yen
5. South African RandConverted amount: 85.00 GBP