omniauth-parallelmarkets 0.5.0 → 0.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
  SHA256:
3
- metadata.gz: 116a4e6f6b528976b72de3ea0fe9b1fbdb49789abf02fe1ec140596554cedbb9
4
- data.tar.gz: a609f558e13b46498bbe870c94873846a13a33a012700d78c261c76826995aa7
3
+ metadata.gz: 9d9f955824566ba7be54bb6041e602513ac5c4cf0a6c41abbcd84b700eabe9ca
4
+ data.tar.gz: 8a0a0ac60040da68d27a2dcf0061c9d3fc714742cc4cf24e43efcf7de10729b6
5
5
  SHA512:
6
- metadata.gz: cd138b8aab041a68b18601f66602b5b5753f5f7b820c1def738a024da32471ab72d81711a18ce53d64e4bc421e52d8d1e2d5e4167d52071551f4463d08aa3bb1
7
- data.tar.gz: 5487cb23b4ba7b1e4213634ac645b3525f894dfe4e693c7cb9414448d892a6cf400d5f9968db5c48c7b435723635b2691b49ee0347db7110c56694d38094ebba
6
+ metadata.gz: 6411a99701c9ac720a070699de9b948c570e950ad80c9cde73eca4d001c9461cbe8d6268a493e1e8e863c4f5364f94a0b6e0da9ae651afc6fc2a57b8c0ddc818
7
+ data.tar.gz: aa9544f7df643fbfd389fb3d8a16725e6a80f7ec7bd2b857d511e97d0b322daf0127817b04bd49a876d52ffffa3b85b97953462778bc90f7fcf3090816ea6bdd
@@ -2,6 +2,6 @@
2
2
 
3
3
  module OmniAuth
4
4
  module ParallelMarkets
5
- VERSION = '0.5.0'
5
+ VERSION = '0.6.0'
6
6
  end
7
7
  end
@@ -28,7 +28,9 @@ module OmniAuth
28
28
  user_providing_for: raw_info['user_providing_for'],
29
29
  # from /api/v1/accreditations
30
30
  accreditations: accreditations,
31
- indicated_unaccredited: raw_accreditations['indicated_unaccredited']
31
+ indicated_unaccredited: raw_accreditations['indicated_unaccredited'],
32
+ # from /api/v1/identity
33
+ identity_details: identity_details
32
34
  }
33
35
  end
34
36
 
@@ -74,6 +76,14 @@ module OmniAuth
74
76
  @accreditations ||= raw_accreditations.fetch('accreditations', [])
75
77
  end
76
78
 
79
+ def raw_identity
80
+ @raw_identity ||= scope?(:identity) ? access_token.get('/v1/identity').parsed : {}
81
+ end
82
+
83
+ def identity_details
84
+ @identity_details ||= raw_identity['identity_details']
85
+ end
86
+
77
87
  def to_contact_details(contact)
78
88
  (contact.nil? || contact.empty?) ? {} : {
79
89
  name: contact['name'] || "#{contact['first_name']} #{contact['last_name']}",
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniauth-parallelmarkets
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brian Muller
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-06-22 00:00:00.000000000 Z
11
+ date: 2021-08-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: omniauth-oauth2