dirigible 1.1.0 → 1.1.1
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 +4 -4
- data/README.md +4 -3
- data/dirigible.gemspec +0 -1
- data/lib/dirigible/device_information.rb +16 -4
- data/lib/dirigible/version.rb +1 -1
- data/lib/dirigible.rb +0 -1
- metadata +2 -16
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5a257f35d1388cef0b5cd4d2f68b6019dc5476f4
|
4
|
+
data.tar.gz: 6ebfc55d2e1f49254c37a722da78aada9ade089b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6228c89d0ca39ad5afecc068e31825973a697d91483f983332c28cb96e75cf4231aba8caff41aa0597f4a9f54258fae031f323deca63ec4e845ef12165a6ca3f
|
7
|
+
data.tar.gz: 6742f3510312827e7284683aeb1441c7f728b144f6c3c3fe08a260622dc4f7ee1ec1f4ce67e1174d8bd2afc5d7c5c743e865e2fafa1a3b9e4428054ea3c39b55
|
data/README.md
CHANGED
@@ -108,9 +108,10 @@ end
|
|
108
108
|
* [Get Backberry PIN device information](http://rdoc.info/github/anthonator/dirigible/master/Dirigible/DeviceInformation.get_device_pin)
|
109
109
|
* [Get iOS device token information](http://rdoc.info/github/anthonator/dirigible/master/Dirigible/DeviceInformation.get_device_token)
|
110
110
|
* [List Android APID's registered to an application](http://rdoc.info/github/anthonator/dirigible/master/Dirigible/DeviceInformation.list_apids)
|
111
|
-
* [List Blackberry PIN's registered to an application](http://rdoc.info/github/anthonator/dirigible/master/Dirigible/DeviceInformation.
|
112
|
-
* [
|
113
|
-
* [List device tokens
|
111
|
+
* [List Blackberry PIN's registered to an application](http://rdoc.info/github/anthonator/dirigible/master/Dirigible/DeviceInformation.list_device_pins)
|
112
|
+
* [Count iOS device tokens registered to an application](http://rdoc.info/github/anthonator/dirigible/master/Dirigible/DeviceInformation.count_device_tokens)
|
113
|
+
* [List iOS device tokens registered to an application](http://rdoc.info/github/anthonator/dirigible/master/Dirigible/DeviceInformation.list_device_tokens)
|
114
|
+
* [List iOS device tokens that can't recieve messages](http://rdoc.info/github/anthonator/dirigible/master/Dirigible/DeviceInformation.device_token_feedback)
|
114
115
|
|
115
116
|
### Device Registration
|
116
117
|
|
data/dirigible.gemspec
CHANGED
@@ -31,6 +31,18 @@ class Dirigible::DeviceInformation
|
|
31
31
|
Dirigible.get("/device_pins/#{id}")
|
32
32
|
end
|
33
33
|
|
34
|
+
# Count iOS device tokens registered to this application
|
35
|
+
#
|
36
|
+
# @example Example request:
|
37
|
+
# Dirigible::DeviceInformation.count_device_tokens[:device_tokens_count]
|
38
|
+
# Dirigible::DeviceInformation.count_device_tokens[:active_device_tokens_count]
|
39
|
+
#
|
40
|
+
# @see http://docs.urbanairship.com/reference/api/v3/device_information.html#device-listing
|
41
|
+
def self.count_device_tokens
|
42
|
+
Dirigible.get("/device_tokens/count")
|
43
|
+
end
|
44
|
+
|
45
|
+
|
34
46
|
# Fetch iOS device tokens registered to this application
|
35
47
|
# and associated metadata.
|
36
48
|
#
|
@@ -43,7 +55,7 @@ class Dirigible::DeviceInformation
|
|
43
55
|
#
|
44
56
|
# @see http://docs.urbanairship.com/reference/api/v3/device_information.html#device-listing
|
45
57
|
def self.list_device_tokens(options = {})
|
46
|
-
List.new(Dirigible.get('/device_tokens',
|
58
|
+
List.new(Dirigible.get('/device_tokens', options))
|
47
59
|
end
|
48
60
|
|
49
61
|
# Fetch Android APIDs registered to this application and
|
@@ -58,7 +70,7 @@ class Dirigible::DeviceInformation
|
|
58
70
|
#
|
59
71
|
# @see http://docs.urbanairship.com/reference/api/v3/device_information.html#device-listing
|
60
72
|
def self.list_apids(options = {})
|
61
|
-
List.new(Dirigible.get('/apids',
|
73
|
+
List.new(Dirigible.get('/apids', options))
|
62
74
|
end
|
63
75
|
|
64
76
|
# Fetch BlackBerry PINs registered to this application and
|
@@ -73,7 +85,7 @@ class Dirigible::DeviceInformation
|
|
73
85
|
#
|
74
86
|
# @see http://docs.urbanairship.com/reference/api/v3/device_information.html#device-listing
|
75
87
|
def self.list_device_pins(options = {})
|
76
|
-
List.new(Dirigible.get('/device_pins',
|
88
|
+
List.new(Dirigible.get('/device_pins', options))
|
77
89
|
end
|
78
90
|
|
79
91
|
# Fetch device tokens that can't recieve messages because
|
@@ -101,7 +113,7 @@ class Dirigible::DeviceInformation
|
|
101
113
|
def next_page(params = {})
|
102
114
|
return nil if @response[:next_page].nil?
|
103
115
|
uri = URI.parse(@response[:next_page])
|
104
|
-
path = "/#{uri.path.gsub(/\/api
|
116
|
+
path = "/#{uri.path.gsub(/\/api\/|\//, '')}"
|
105
117
|
# Shew! Need to simplify this!
|
106
118
|
params = (CGI.parse(uri.query).map{ |k,v| { k => v[0] } }.reduce({}) { |h,pairs| pairs.each { |k,v| (h[k.to_sym] = v) }; h }).merge!(params)
|
107
119
|
List.new(Dirigible.get(path, params))
|
data/lib/dirigible/version.rb
CHANGED
data/lib/dirigible.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dirigible
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Anthony Smith
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-02-
|
11
|
+
date: 2014-02-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -38,20 +38,6 @@ dependencies:
|
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0.9'
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: hashie
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - "~>"
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: '2.0'
|
48
|
-
type: :runtime
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - "~>"
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: '2.0'
|
55
41
|
- !ruby/object:Gem::Dependency
|
56
42
|
name: multi_json
|
57
43
|
requirement: !ruby/object:Gem::Requirement
|