Geocoder microservice.
- Ruby 3.1.0
bundle install
bin/http
The app is running by default at http://localhost:3000
.
To change the port edit file config/settings.yml
.
POST http://localhost:3000/v1/coordinates
PARAMS
{
city: 'Москва'
}
RESPONSE
200 OK
{
"latitude": 55.7540471,
"longitude": 37.620405
}
OR
404 Not Found
{
"error": "Cannot locate 'Paris'"
}
OR
422 Unprocessable Entity
{
"errors": [
{
"city": "Invalid city"
}
]
}
bin/rpc
bundle exec rspec