talon_one 0.0.7 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/management/client.rb +6 -6
- data/talon_one.gemspec +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 95e903cd6d515eaf7af79694d78f3175ed2c2ccc
|
4
|
+
data.tar.gz: af3ac0c034057857644dc3b581bceee4891dbd6f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 62788bee7b389d6206ba3905cd0d8312501491636a51e9cff202191331deb1b0b03f651b3e57897317a374fd6a144d47a7fcc1b671390d6553917ebf7a51272b
|
7
|
+
data.tar.gz: e48c7190c6949840970c9c2164ed9d5cc93476941acc2c55b4e7a5b68266b25d3e79f126010b04c0496abd0ebc9bcd854da5cabcbdaa8c835c1ca819090f0737
|
data/CHANGELOG.md
CHANGED
data/lib/management/client.rb
CHANGED
@@ -14,16 +14,12 @@ module TalonOne
|
|
14
14
|
email = config[:email] || ENV["TALONONE_EMAIL"]
|
15
15
|
password = config[:password] || ENV["TALONONE_PASSWORD"]
|
16
16
|
if email && password
|
17
|
-
login(email, password)
|
17
|
+
res = login(email, password)
|
18
|
+
@token = res["token"]
|
18
19
|
end
|
19
20
|
end
|
20
21
|
end
|
21
22
|
|
22
|
-
def login(email, password)
|
23
|
-
res = request "Post", "/v1/sessions", {"email" => email, "password" => password}
|
24
|
-
@token = res["token"]
|
25
|
-
end
|
26
|
-
|
27
23
|
def request(method, path, payload = nil)
|
28
24
|
req = Net::HTTP.const_get(method).new(@endpoint.path + path)
|
29
25
|
if @token
|
@@ -57,6 +53,10 @@ module TalonOne
|
|
57
53
|
request "Delete", path
|
58
54
|
end
|
59
55
|
|
56
|
+
def login(email, password)
|
57
|
+
post "/v1/sessions", {"email" => email, "password" => password}
|
58
|
+
end
|
59
|
+
|
60
60
|
def create_application(params)
|
61
61
|
post "/v1/applications", params
|
62
62
|
end
|
data/talon_one.gemspec
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = 'talon_one'
|
3
|
-
s.version = '0.0.
|
4
|
-
s.date = '2017-
|
3
|
+
s.version = '0.0.8'
|
4
|
+
s.date = '2017-06-06'
|
5
5
|
s.summary = 'Client for the Talon.One API'
|
6
6
|
s.description = 'A simple client for using the Talon.One API'
|
7
7
|
s.authors = ['Talon.One GmbH']
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: talon_one
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Talon.One GmbH
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-06-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: oj
|