m2x 2.5.0 → 2.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 59f5fa4e180f9d9067d21cfbbb3342958af3d50b
4
- data.tar.gz: 49b24d5d53244a4cee2fa4184cbe511b3f58c944
3
+ metadata.gz: 2df83391fd90e9c9f4f55d0a641e63defe16ba3c
4
+ data.tar.gz: 91c7801e47439fd6da3647c13c43bf1024c22335
5
5
  SHA512:
6
- metadata.gz: 9281c9fb417a8dcca37a16f4694376178817f890df0709a009e8ed09114b11ed2083bc5538d42b59c8550215c22dfd56b3583f7f536944d0ed662633b1b4c543
7
- data.tar.gz: 07bd17b448b28a10feb2e381575861d45372884ec41bb4c48d47e75aeb72ea1dfcd8750a60e70e5b21c29c4638641d5dd516d019ce57c856f74576adb74b8270
6
+ metadata.gz: 50a34788fec3c8616ef32c3d9dc9fbd04454d47c631e314d8490766818907744cebdab5e6d975345d35abca245250bd0c9edea9616b65a8011e45a62e60722fb
7
+ data.tar.gz: ee6d3ba03c5ea86a37234258ec7c8a3a58edc063caf511a03ca7e44d9f6000ad5d211e2c7ca09f3f6bd44ba40f82775e5a9615a271fb5574379d3db66800e724
@@ -33,6 +33,12 @@ class M2X::Client::Collection < M2X::Client::Resource
33
33
  @path ||= "#{ PATH }/#{ URI.encode(@attributes.fetch("id")) }"
34
34
  end
35
35
 
36
+ def devices
37
+ res = @client.get("#{path}/devices")
38
+
39
+ res.json["devices"].map{ |atts| M2X::Client::Device.new(@client, atts) } if res.success?
40
+ end
41
+
36
42
  # Add device to collection
37
43
  #
38
44
  # https://m2x.att.com/developer/documentation/v2/collections#Add-device-to-collection
@@ -1,5 +1,5 @@
1
1
  module M2X
2
2
  class Client
3
- VERSION = "2.5.0"
3
+ VERSION = "2.6.0"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: m2x
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.5.0
4
+ version: 2.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Leandro López
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2016-05-26 00:00:00.000000000 Z
13
+ date: 2016-07-07 00:00:00.000000000 Z
14
14
  dependencies: []
15
15
  description: AT&T’s M2X is a cloud-based fully managed data storage service for network
16
16
  connected machine-to-machine (M2M) devices. From trucks and turbines to vending