REST Web Service exposing a single API that, given a Pokémon name, returns its "Shakespearean" description.
Under the hood it uses PokéAPI and Shakespeare translator.
Install rustup and then run:
RUST_LOG=info \
POKESPEARE_LISTEN_ADDR=0.0.0.0:8080 \
POKE_API_ENDPOINT=https://pokeapi.co \
FUN_TRANSLATIONS_API_ENDPOINT=https://api.funtranslations.com \
cargo run
docker build . -t pokespeare && \
docker run \
--env RUST_LOG=info \
--env POKESPEARE_LISTEN_ADDR=0.0.0.0:8080 \
--env POKE_API_ENDPOINT=https://pokeapi.co \
--env FUN_TRANSLATIONS_API_ENDPOINT=https://api.funtranslations.com \
-p 8080:8080
pokespeare
curl -v 0.0.0.0:8080/pokemon/bulbasaur`
Call the service & pretty print its output (requires jq)
curl -v 0.0.0.0:8080/pokemon/bulbasaur | jq
cargo test