Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #4 from i0rek/docs

Updated Readme
  • Loading branch information...
commit 5b1947efe117a9b9c819140e6d157232faf37bda 2 parents 4acf71e + 167fe6b
@mtodd authored
Showing with 6 additions and 7 deletions.
  1. +6 −7 README.md
View
13 README.md
@@ -7,20 +7,19 @@ NOTE: This is a 3rd party gem and not an official product from Pingdom.
## Usage
- client = Pingdom::Client.new :username => u, :password => p
+ client = Pingdom::Client.new :username => u, :password => p, :key => k
check = client.checks.first #=> #<Pingdom::Check>
check.last_response_time #=> 200 (ms)
- check.status #=> :up
- check.up? #=> true
-
+ check.status #=> "up"
+
result = check.results.first(:probes => [1,2,3], :status => [:up, :down])
#=> #<Pingdom::Result>
result.status #=> :up
result.up? #=> true
result.response_time #=> 20000 (microsecs)
-
- avg = check.average(:from => 1.month.ago,
- :probes => [1,2,3])
+
+ avg = check.summary.average(:from => 1.month.ago,
+ :probes => [1,2,3])
#=> #<Pingdom::Summary::Average>
avg.response_time #=> 200 (ms)
probe_avg = avg.averages.first
Please sign in to comment.
Something went wrong with that request. Please try again.