It is a Time zone converter API in golang, it converts the time from one time zone to another timezone.
Please install and set-up Golang as well as install and set-up Postman on your system in advance.
- Clone this Project and Navigate to the folder.
https://github.com/k-avy/gotimezoneapi.git
cd gotimezoneapi
- Build the project using following command.
go build ./cmd/time
- Run the executable in your vscode terminal.
./time
- You can directly run it by the following command.
go run ./cmd/time
- You can see tis work on Postman on your system.
- You can convert the current time from one time zone to another using the following address with GET Method.
http://localhost:8080/convert?from="timezone1"&to="timezone2"
- You can convert the desired time from one time zone to another using the following address with GET Method.
http://localhost:8080/converttz?from="desiredtime"_"timezone1"&to="timezone2"