Logo Weather API

Logo Weather API

API doc (version 0.3.1)

Description
- CORS is enabled allowing Javascript make requests across domain boundaries
- API URL => https://api.codetabs.com/weather/temp/
- JSON format is used by default. To get data in XML set up format=xml .
- Limit : 5 requests per second. Once reached subsequent requests will result in error 429 (too many requests) until your quota is cleared.
- Quota is shared among services [Alexa, Weather, Http Headers].
Endpoint - Get your local temp
This endpoint retrieves actual temp based on your public IP geolocation.
http Request : GET https://api.codetabs.com/weather/temp/
parameter "&format=" values are json(by default or if parameter is empty) or xml
examples :
https://api.codetabs.com/weather/temp/
https://api.codetabs.com/weather/temp?format=xml

response :
{
  "city": "paris",
  "country": "FR",
  "lat": "48.8600",
  "lon": "2.3500",
  "tempC": 21.62,
  "tempF": 53.62,
}       
      
Endpoint - Get temp from any location
This endpoint retrieves actual temp from the city passed as a parameter.
http Request : GET https://api.codetabs.com/weather/temp?city=paris/
parameter "&format=" values are json(by default or if parameter is empty) or xml
parameter "&city=" city i want to know the temperature.
https://api.codetabs.com/weather/temp?city=london
https://api.codetabs.com/weather/temp?city=london&format=xml

response :
{
  "city ": "london ",
  "country ": "GB ",
  "lat ": "51.5100 ",
  "lon ": "-0.1300 ",
  "tempC ": "9.18 ",
  "tempF ": "48.52 "
}