inter_api 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/inter_api/client.rb +1 -1
- data/lib/inter_api/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: '00359604a49c1e13d27dc95669f21d4de43530b5d1101d0945cb5c33d90517f0'
|
4
|
+
data.tar.gz: 6c7565195e26b407c1a0bb08a0a2188da5fe1f04b20c85319b4a9aca5ef16cd6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0b91d9df2cd30a8c8109f02fe4676618c817df5599cefceb25178656565dc8da277766f9196ba633760c4f918c6ef350c2cba7e6906857b8dc34f515a4184af1
|
7
|
+
data.tar.gz: c5f479d4773e988e80a5de2eaa8565c45142b8a062e44c073f09a43b0622ae02590964af25857c929f49dc33a78a236a99f26906cf3b6c199c2298b1e2ec2a0c
|
data/lib/inter_api/client.rb
CHANGED
@@ -30,7 +30,7 @@ module InterApi
|
|
30
30
|
grant_type: "client_credentials",
|
31
31
|
scope: @scopes
|
32
32
|
}
|
33
|
-
response = post("/oauth/v2/token", headers: headers, sslcert: @crt, sslkey: @key, body: body)
|
33
|
+
response = post("/oauth/v2/token", headers: headers, sslcert: @crt, sslkey: @key, body: body) { |response| validate_response(response, "access_token") }
|
34
34
|
@token = response.json["access_token"]
|
35
35
|
@token_expires_at = Time.now + response.json["expires_in"]
|
36
36
|
end
|
data/lib/inter_api/version.rb
CHANGED