rjmetrics-client 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +8 -8
- data/lib/rjmetrics_client.rb +6 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
OWZkNzgyZjJiMTg2YmU5NzIwNjVhM2E5NGM1MDBjMDY3YzRiZGM0Yg==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
OGYwMTE3OGFjZjE2NGM5ZjA4NjhlOGNiYzY3M2Q2NTY3NmIzNDQ2OQ==
|
7
7
|
!binary "U0hBNTEy":
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
MWNhZWRkMTgzNjYyYzM3NTc4N2JjYTQ5NWMxNWIzZjkwMzM1Y2U4MTA0YjBl
|
10
|
+
YTJmMmMxMGFmNTZkOGVjYmU4MjI1MzMyOTJmYzBmM2UwMDM1YTY5MmRmY2E4
|
11
|
+
OGRiYjI2ZTQwYzU2MzdjMDU3Yzc3MzIxNzE4NjkyOWQ3MGEzNDY=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
ZTM3MjU0NDg0ZDk0YzVmY2FkYTdmMDYxMWU5YmMxNGM3N2RhYzllNzNlOWRk
|
14
|
+
ZjJmZmI1ZmM2NGUyY2Y5ZTM5NDU2Njc1ZWRhOWRiNWNiZWMyMTgxN2U5Yzgz
|
15
|
+
Y2VlMWI2NWM0MjZmYTk3MmFmZDI0ZWQ3ZWUxZTkwNGUwNWJlN2U=
|
data/lib/rjmetrics_client.rb
CHANGED
@@ -3,11 +3,16 @@ class RJMetricsClient
|
|
3
3
|
def initialize(client_id, api_key, timeout_in_seconds = 10)
|
4
4
|
@client = Client.new(client_id, api_key, timeout_in_seconds)
|
5
5
|
|
6
|
-
if not
|
6
|
+
if not authenticated?
|
7
7
|
raise Client::UnableToConnectException, "Connection failed. Please double check your credentials."
|
8
8
|
end
|
9
9
|
end
|
10
10
|
|
11
|
+
# Validates credentials by making a request to the RJMetrics API Sandbox.
|
12
|
+
def authenticated?
|
13
|
+
return @client.authenticated?
|
14
|
+
end
|
15
|
+
|
11
16
|
# Sends data to RJMetrics Data Import API.
|
12
17
|
#
|
13
18
|
# @param table_name [String] the table name you wish to store the data
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rjmetrics-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Owen Jones
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-02-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rest-client
|
@@ -99,3 +99,4 @@ signing_key:
|
|
99
99
|
specification_version: 4
|
100
100
|
summary: RJMetrics Data Import API Client Library
|
101
101
|
test_files: []
|
102
|
+
has_rdoc:
|