Skip to content

Commit 97d7835

Browse files
committed
Update README.md
1 parent beb3dce commit 97d7835

File tree

1 file changed

+18
-3
lines changed

1 file changed

+18
-3
lines changed

README.md

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,12 @@ Add the following to your **Gemfile**
1212

1313
## Usage
1414

15+
16+
### Current weather information API
17+
1518
```ruby
1619
require 'open_weather'
1720

18-
# current weather APIs
19-
2021
# get current weather by city name
2122
OpenWeather::Current.city("Cochin, IN")
2223

@@ -28,8 +29,16 @@ OpenWeather::Current.geocode(9.94, 76.26)
2829

2930
# get the current weather in degrees celsius
3031
OpenWeather::Current.city("Cochin, IN", units: 'metric')
32+
```
33+
34+
Documentation about the current weather end-point:
35+
http://openweathermap.org/current
36+
3137

32-
# weather forecast APIs
38+
### Weather forecast API
39+
40+
```ruby
41+
require 'open_weather'
3342

3443
# get weather forecast by city name
3544
OpenWeather::Forecast.city("Cochin, IN")
@@ -44,6 +53,9 @@ OpenWeather::Forecast.city_id("1273874")
4453
OpenWeather::Forecast.geocode(9.94, 76.26)
4554
```
4655

56+
Doucumentation about the weather forecast end-point:
57+
http://openweathermap.org/forecast
58+
4759
#### Using the API key
4860

4961
```ruby
@@ -52,6 +64,9 @@ options = { units: "metric", APPID: 1111111111 }
5264
OpenWeather::Current.city("Berlin, DE", options)
5365
```
5466

67+
How to get an API key and tips for an effective usage of the API:
68+
http://openweathermap.org/appid
69+
5570

5671
## Contributing
5772

0 commit comments

Comments
 (0)