POST as GET: Get current weather by city request model
POST as GET: Get current weather by city name, state code and country code; State code and country code are optional
POST
/api/v1/current/weather/city
curl \
-X POST http://bytemetwice.ninja/api/v1/current/weather/city \
-H "Content-Type: application/json" \
-d '{"id":"string","name":"string","stateCode":"string","countryCode":"string"}'
Request example
{
"id": "string",
"name": "string",
"stateCode": "string",
"countryCode": "string"
}
Response examples (200)
{
"currentWeather": {
"coord": {
"lon": 42.0,
"lat": 42.0
},
"weather": [
{
"id": 42,
"main": "string",
"description": "string",
"icon": "string"
}
],
"base": "string",
"main": {
"temp": 42.0,
"feels_like": 42.0,
"temp_min": 42.0,
"temp_max": 42.0,
"pressure": 42,
"humidity": 42,
"sea_level": 42,
"grnd_level": 42
},
"visibility": 42,
"wind": {
"speed": 42.0,
"deg": 42,
"gust": 42.0
},
"rain": {
"1h": 42.0
},
"clouds": {
"all": 42
},
"dt": 42,
"sys": {
"type": 42,
"id": 42,
"country": "string",
"sunrise": 42,
"sunset": 42
},
"timezone": 42,
"id": 42,
"name": "string",
"cod": 42
},
"message": "string"
}