passageidentity 0.0.6 → 0.1.0
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 +34 -2
- data/lib/passageidentity/auth.rb +0 -2
- data/lib/passageidentity/client.rb +7 -5
- data/lib/passageidentity/user_api.rb +8 -1
- data/passageidentity.gemspec +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2a49c21c71b6acf1b1406f827d7e3f23a4591cec7ef927c6bfbd079e51343f68
|
4
|
+
data.tar.gz: 153dc151a50192cf9d1b3cc65fe9ce09af4cf1fc2141798d8c0166b5c04eeab4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6b66e69f219441b18cbd87c404fb17acd02dde77dd39ba282673340b19e0f04fbf5ace426ba65b41ea5ef3abae927b96ad4380d52c1311ab9af01178367325c5
|
7
|
+
data.tar.gz: 1ce583a5d57247c97dcebd8f47242b8c4b5a79d84d54c889df7be37b494f3b93bf26fcf542b48d1de15ac975f4fe0b468d65a07426ea675091b4a3dcec516426
|
data/README.md
CHANGED
@@ -51,6 +51,35 @@ class ApplicationController < ActionController::Base
|
|
51
51
|
end
|
52
52
|
```
|
53
53
|
|
54
|
+
## Retrieve App Info
|
55
|
+
|
56
|
+
To retrieve information about an app , you should use the `get_app` method.
|
57
|
+
|
58
|
+
```ruby
|
59
|
+
require 'passageidentity'
|
60
|
+
|
61
|
+
PassageClient =
|
62
|
+
Passage::Client.new(app_id: PASSAGE_APP_ID)
|
63
|
+
app_info = PassageClient.get_app()
|
64
|
+
|
65
|
+
```
|
66
|
+
|
67
|
+
The information available in the Passage App struct returned by PassageClient.get_app():
|
68
|
+
|
69
|
+
```ruby
|
70
|
+
Struct.new :name,
|
71
|
+
:id,
|
72
|
+
:auth_origin,
|
73
|
+
:redirect_url,
|
74
|
+
:login_url,
|
75
|
+
:rsa_public_key,
|
76
|
+
:allowed_identifer,
|
77
|
+
:require_identifier_verification,
|
78
|
+
:session_timeout_length,
|
79
|
+
:user_metadata_schema,
|
80
|
+
:layouts,
|
81
|
+
```
|
82
|
+
|
54
83
|
## Retrieve User Info
|
55
84
|
|
56
85
|
To retrieve information about a user, you should use the `get` method. You will need to use a Passage API key, which can be created in the Passage Console under your Application Settings. This API key grants your web server access to the Passage management APIs to get and update information about users. This API key must be protected and stored in an appropriate secure storage location. It should never be hard-coded in the repository.
|
@@ -81,6 +110,7 @@ The information available in the Passage User struct returned by PassageClient.u
|
|
81
110
|
:email,
|
82
111
|
:phone,
|
83
112
|
:email_verified,
|
113
|
+
:phone_verified,
|
84
114
|
:created_at,
|
85
115
|
:updated_at,
|
86
116
|
:last_login_at,
|
@@ -154,7 +184,9 @@ The information available in the array of Passage Device struct returned by Pass
|
|
154
184
|
:cred_id,
|
155
185
|
:friendly_name,
|
156
186
|
:usage_count,
|
157
|
-
:
|
187
|
+
:updated_at,
|
188
|
+
:created_at,
|
189
|
+
:last_login_at,
|
158
190
|
|
159
191
|
```
|
160
192
|
|
@@ -175,7 +207,7 @@ end
|
|
175
207
|
|
176
208
|
## Create an Embeddable Magic Link
|
177
209
|
|
178
|
-
To create a magic link, you should use the `create_magic_link` method. You can check out our guide on embeddable magic links in our [docs](https://docs.passage.id/
|
210
|
+
To create a magic link, you should use the `create_magic_link` method. You can check out our guide on embeddable magic links in our [docs](https://docs.passage.id/guides/embedded-links).
|
179
211
|
|
180
212
|
```ruby
|
181
213
|
require 'passageidentity'
|
data/lib/passageidentity/auth.rb
CHANGED
@@ -13,8 +13,7 @@ module Passage
|
|
13
13
|
:login_url,
|
14
14
|
:rsa_public_key,
|
15
15
|
:allowed_identifer,
|
16
|
-
:
|
17
|
-
:require_email_verification,
|
16
|
+
:require_identifier_verification,
|
18
17
|
:session_timeout_length,
|
19
18
|
:user_metadata_schema,
|
20
19
|
:layouts,
|
@@ -25,6 +24,7 @@ module Passage
|
|
25
24
|
:email,
|
26
25
|
:phone,
|
27
26
|
:email_verified,
|
27
|
+
:phone_verified,
|
28
28
|
:created_at,
|
29
29
|
:updated_at,
|
30
30
|
:last_login_at,
|
@@ -51,7 +51,9 @@ module Passage
|
|
51
51
|
:cred_id,
|
52
52
|
:friendly_name,
|
53
53
|
:usage_count,
|
54
|
-
:
|
54
|
+
:updated_at,
|
55
|
+
:created_at,
|
56
|
+
:last_login_at,
|
55
57
|
keyword_init: true
|
56
58
|
|
57
59
|
COOKIE_STRATEGY = 0
|
@@ -124,8 +126,8 @@ module Passage
|
|
124
126
|
login_url: app_info["login_url"],
|
125
127
|
rsa_public_key: app_info["rsa_public_key"],
|
126
128
|
allowed_identifer: app_info["allowed_identifer"],
|
127
|
-
|
128
|
-
|
129
|
+
require_identifier_verification:
|
130
|
+
app_info["require_identifier_verification"],
|
129
131
|
session_timeout_length: app_info["session_timeout_length"],
|
130
132
|
user_metadata_schema: app_info["user_metadata_schema"],
|
131
133
|
layouts: app_info["layouts"]
|
@@ -22,6 +22,7 @@ module Passage
|
|
22
22
|
email: user["email"],
|
23
23
|
phone: user["phone"],
|
24
24
|
email_verified: user["email_verified"],
|
25
|
+
phone_verified: user["phone_verified"],
|
25
26
|
created_at: user["created_at"],
|
26
27
|
updated_at: user["updated_at"],
|
27
28
|
last_login_at: user["last_login_at"],
|
@@ -56,6 +57,7 @@ module Passage
|
|
56
57
|
email: user["email"],
|
57
58
|
phone: user["phone"],
|
58
59
|
email_verified: user["email_verified"],
|
60
|
+
phone_verified: user["phone_verified"],
|
59
61
|
created_at: user["created_at"],
|
60
62
|
updated_at: user["updated_at"],
|
61
63
|
last_login_at: user["last_login_at"],
|
@@ -90,6 +92,7 @@ module Passage
|
|
90
92
|
email: user["email"],
|
91
93
|
phone: user["phone"],
|
92
94
|
email_verified: user["email_verified"],
|
95
|
+
phone_verified: user["phone_verified"],
|
93
96
|
created_at: user["created_at"],
|
94
97
|
updated_at: user["updated_at"],
|
95
98
|
last_login_at: user["last_login_at"],
|
@@ -128,6 +131,7 @@ module Passage
|
|
128
131
|
email: user["email"],
|
129
132
|
phone: user["phone"],
|
130
133
|
email_verified: user["email_verified"],
|
134
|
+
phone_verified: user["phone_verified"],
|
131
135
|
created_at: user["created_at"],
|
132
136
|
updated_at: user["updated_at"],
|
133
137
|
last_login_at: user["last_login_at"],
|
@@ -164,6 +168,7 @@ module Passage
|
|
164
168
|
email: user["email"],
|
165
169
|
phone: user["phone"],
|
166
170
|
email_verified: user["email_verified"],
|
171
|
+
phone_verified: user["phone_verified"],
|
167
172
|
created_at: user["created_at"],
|
168
173
|
updated_at: user["updated_at"],
|
169
174
|
last_login_at: user["last_login_at"],
|
@@ -227,7 +232,9 @@ module Passage
|
|
227
232
|
cred_id: device["cred_id"],
|
228
233
|
friendly_name: device["friendly_name"],
|
229
234
|
usage_count: device["usage_count"],
|
230
|
-
|
235
|
+
updated_at: device["updated_at"],
|
236
|
+
created_at: device["created_at"],
|
237
|
+
last_login_at: device["last_login_at"]
|
231
238
|
)
|
232
239
|
)
|
233
240
|
end
|
data/passageidentity.gemspec
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = 'passageidentity'
|
3
|
-
s.version = '0.0
|
3
|
+
s.version = '0.1.0'
|
4
4
|
s.summary = 'Passage SDK for biometric authentication'
|
5
5
|
s.description =
|
6
6
|
'Enables verification of server-side authentication and user management for applications using Passage'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: passageidentity
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0
|
4
|
+
version: 0.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Passage Identity
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-07-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|