stytch 10.27.0 → 10.28.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/lib/stytch/b2b_discovery.rb +18 -2
- data/lib/stytch/b2b_magic_links.rb +9 -1
- data/lib/stytch/b2b_oauth.rb +9 -1
- data/lib/stytch/b2b_organizations.rb +8 -2
- data/lib/stytch/b2b_otp.rb +18 -2
- data/lib/stytch/b2b_passwords.rb +36 -4
- data/lib/stytch/b2b_recovery_codes.rb +9 -1
- data/lib/stytch/b2b_sessions.rb +27 -3
- data/lib/stytch/b2b_sso.rb +9 -1
- data/lib/stytch/b2b_totps.rb +9 -1
- data/lib/stytch/crypto_wallets.rb +9 -1
- data/lib/stytch/magic_links.rb +9 -1
- data/lib/stytch/oauth.rb +9 -1
- data/lib/stytch/otps.rb +9 -1
- data/lib/stytch/passwords.rb +45 -5
- data/lib/stytch/sessions.rb +27 -3
- data/lib/stytch/totps.rb +18 -2
- data/lib/stytch/users.rb +3 -0
- data/lib/stytch/version.rb +1 -1
- data/lib/stytch/webauthn.rb +18 -2
- 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: 84042207ac59233533cc823e147225b53dfb242577ada92f7c371d91f0067346
|
4
|
+
data.tar.gz: 43abe43af046750571190adbb0aba08f2126c5781812385c7bf4cb88ee41871c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 579d066dd8ebbda2724b7ff7824cd92686bdfecdabf10df8cf562f29a6025f24e814a746832838868c173800aac0399fac882cb52a5e281d5e776b99f4057796
|
7
|
+
data.tar.gz: 6dc2c0f7ae5a048d4bba0bebcf7a002f94afc7dee8d82f844147313920212814256b9aa1ad21d4cf6dbcd6396215e5213285494475e31b17aa4f47e01e75be65
|
data/lib/stytch/b2b_discovery.rb
CHANGED
@@ -78,6 +78,9 @@ module StytchB2B
|
|
78
78
|
# Request support for additional languages [here](https://docs.google.com/forms/d/e/1FAIpQLScZSpAu_m2AmLXRT3F3kap-s_mcV6UTBitYn6CdyWP0-o7YjQ/viewform?usp=sf_link")!
|
79
79
|
#
|
80
80
|
# The type of this field is nilable +ExchangeRequestLocale+ (string enum).
|
81
|
+
# telemetry_id::
|
82
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
83
|
+
# The type of this field is nilable +String+.
|
81
84
|
#
|
82
85
|
# == Returns:
|
83
86
|
# An object with the following fields:
|
@@ -117,12 +120,16 @@ module StytchB2B
|
|
117
120
|
# primary_required::
|
118
121
|
# Information about the primary authentication requirements of the Organization.
|
119
122
|
# The type of this field is nilable +PrimaryRequired+ (+object+).
|
123
|
+
# member_device::
|
124
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
125
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
120
126
|
def exchange(
|
121
127
|
intermediate_session_token:,
|
122
128
|
organization_id:,
|
123
129
|
session_duration_minutes: nil,
|
124
130
|
session_custom_claims: nil,
|
125
|
-
locale: nil
|
131
|
+
locale: nil,
|
132
|
+
telemetry_id: nil
|
126
133
|
)
|
127
134
|
headers = {}
|
128
135
|
request = {
|
@@ -132,6 +139,7 @@ module StytchB2B
|
|
132
139
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
133
140
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
134
141
|
request[:locale] = locale unless locale.nil?
|
142
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
135
143
|
|
136
144
|
post_request('/v1/b2b/discovery/intermediate_sessions/exchange', request, headers)
|
137
145
|
end
|
@@ -305,6 +313,9 @@ module StytchB2B
|
|
305
313
|
# allowed_third_party_connected_apps::
|
306
314
|
# An array of third party Connected App IDs that are allowed for the Organization. Only used when the Organization's `third_party_connected_apps_allowed_type` is `RESTRICTED`.
|
307
315
|
# The type of this field is nilable list of +String+.
|
316
|
+
# telemetry_id::
|
317
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
318
|
+
# The type of this field is nilable +String+.
|
308
319
|
#
|
309
320
|
# == Returns:
|
310
321
|
# An object with the following fields:
|
@@ -344,6 +355,9 @@ module StytchB2B
|
|
344
355
|
# primary_required::
|
345
356
|
# Information about the primary authentication requirements of the Organization.
|
346
357
|
# The type of this field is nilable +PrimaryRequired+ (+object+).
|
358
|
+
# member_device::
|
359
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
360
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
347
361
|
def create(
|
348
362
|
intermediate_session_token:,
|
349
363
|
session_duration_minutes: nil,
|
@@ -367,7 +381,8 @@ module StytchB2B
|
|
367
381
|
first_party_connected_apps_allowed_type: nil,
|
368
382
|
allowed_first_party_connected_apps: nil,
|
369
383
|
third_party_connected_apps_allowed_type: nil,
|
370
|
-
allowed_third_party_connected_apps: nil
|
384
|
+
allowed_third_party_connected_apps: nil,
|
385
|
+
telemetry_id: nil
|
371
386
|
)
|
372
387
|
headers = {}
|
373
388
|
request = {
|
@@ -395,6 +410,7 @@ module StytchB2B
|
|
395
410
|
request[:allowed_first_party_connected_apps] = allowed_first_party_connected_apps unless allowed_first_party_connected_apps.nil?
|
396
411
|
request[:third_party_connected_apps_allowed_type] = third_party_connected_apps_allowed_type unless third_party_connected_apps_allowed_type.nil?
|
397
412
|
request[:allowed_third_party_connected_apps] = allowed_third_party_connected_apps unless allowed_third_party_connected_apps.nil?
|
413
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
398
414
|
|
399
415
|
post_request('/v1/b2b/discovery/organizations/create', request, headers)
|
400
416
|
end
|
@@ -79,6 +79,9 @@ module StytchB2B
|
|
79
79
|
# intermediate_session_token::
|
80
80
|
# Adds this primary authentication factor to the intermediate session token. If the resulting set of factors satisfies the organization's primary authentication requirements and MFA requirements, the intermediate session token will be consumed and converted to a member session. If not, the same intermediate session token will be returned.
|
81
81
|
# The type of this field is nilable +String+.
|
82
|
+
# telemetry_id::
|
83
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
84
|
+
# The type of this field is nilable +String+.
|
82
85
|
#
|
83
86
|
# == Returns:
|
84
87
|
# An object with the following fields:
|
@@ -127,6 +130,9 @@ module StytchB2B
|
|
127
130
|
# primary_required::
|
128
131
|
# (no documentation yet)
|
129
132
|
# The type of this field is nilable +PrimaryRequired+ (+object+).
|
133
|
+
# member_device::
|
134
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
135
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
130
136
|
def authenticate(
|
131
137
|
magic_links_token:,
|
132
138
|
pkce_code_verifier: nil,
|
@@ -135,7 +141,8 @@ module StytchB2B
|
|
135
141
|
session_duration_minutes: nil,
|
136
142
|
session_custom_claims: nil,
|
137
143
|
locale: nil,
|
138
|
-
intermediate_session_token: nil
|
144
|
+
intermediate_session_token: nil,
|
145
|
+
telemetry_id: nil
|
139
146
|
)
|
140
147
|
headers = {}
|
141
148
|
request = {
|
@@ -148,6 +155,7 @@ module StytchB2B
|
|
148
155
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
149
156
|
request[:locale] = locale unless locale.nil?
|
150
157
|
request[:intermediate_session_token] = intermediate_session_token unless intermediate_session_token.nil?
|
158
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
151
159
|
|
152
160
|
post_request('/v1/b2b/magic_links/authenticate', request, headers)
|
153
161
|
end
|
data/lib/stytch/b2b_oauth.rb
CHANGED
@@ -77,6 +77,9 @@ module StytchB2B
|
|
77
77
|
# intermediate_session_token::
|
78
78
|
# Adds this primary authentication factor to the intermediate session token. If the resulting set of factors satisfies the organization's primary authentication requirements and MFA requirements, the intermediate session token will be consumed and converted to a member session. If not, the same intermediate session token will be returned.
|
79
79
|
# The type of this field is nilable +String+.
|
80
|
+
# telemetry_id::
|
81
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
82
|
+
# The type of this field is nilable +String+.
|
80
83
|
#
|
81
84
|
# == Returns:
|
82
85
|
# An object with the following fields:
|
@@ -133,6 +136,9 @@ module StytchB2B
|
|
133
136
|
# primary_required::
|
134
137
|
# Information about the primary authentication requirements of the Organization.
|
135
138
|
# The type of this field is nilable +PrimaryRequired+ (+object+).
|
139
|
+
# member_device::
|
140
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
141
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
136
142
|
def authenticate(
|
137
143
|
oauth_token:,
|
138
144
|
session_token: nil,
|
@@ -141,7 +147,8 @@ module StytchB2B
|
|
141
147
|
session_custom_claims: nil,
|
142
148
|
pkce_code_verifier: nil,
|
143
149
|
locale: nil,
|
144
|
-
intermediate_session_token: nil
|
150
|
+
intermediate_session_token: nil,
|
151
|
+
telemetry_id: nil
|
145
152
|
)
|
146
153
|
headers = {}
|
147
154
|
request = {
|
@@ -154,6 +161,7 @@ module StytchB2B
|
|
154
161
|
request[:pkce_code_verifier] = pkce_code_verifier unless pkce_code_verifier.nil?
|
155
162
|
request[:locale] = locale unless locale.nil?
|
156
163
|
request[:intermediate_session_token] = intermediate_session_token unless intermediate_session_token.nil?
|
164
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
157
165
|
|
158
166
|
post_request('/v1/b2b/oauth/authenticate', request, headers)
|
159
167
|
end
|
@@ -607,7 +607,10 @@ module StytchB2B
|
|
607
607
|
delete_request("/v1/b2b/organizations/#{organization_id}", headers)
|
608
608
|
end
|
609
609
|
|
610
|
-
#
|
610
|
+
#
|
611
|
+
# **Warning**: This endpoint is not recommended for use in login flows. Scaling issues may occur, as search performance may vary from ~150 milliseconds to 9 seconds depending on query complexity and rate limits are set to 100 requests/second.
|
612
|
+
#
|
613
|
+
# Search across your Organizations. Returns an array of Organization objects.
|
611
614
|
#
|
612
615
|
# == Parameters:
|
613
616
|
# cursor::
|
@@ -1262,9 +1265,12 @@ module StytchB2B
|
|
1262
1265
|
delete_request("/v1/b2b/organizations/#{organization_id}/members/#{member_id}/totp", headers)
|
1263
1266
|
end
|
1264
1267
|
|
1268
|
+
#
|
1269
|
+
# **Warning**: This endpoint is not recommended for use in login flows. Scaling issues may occur, as search performance may vary from ~150 milliseconds to 9 seconds depending on query complexity and rate limits are set to 100 requests/second.
|
1270
|
+
#
|
1265
1271
|
# Search for Members within specified Organizations. An array with at least one `organization_id` is required. Submitting an empty `query` returns all non-deleted Members within the specified Organizations.
|
1266
1272
|
#
|
1267
|
-
#
|
1273
|
+
# All fuzzy search filters require a minimum of three characters.
|
1268
1274
|
#
|
1269
1275
|
# == Parameters:
|
1270
1276
|
# organization_ids::
|
data/lib/stytch/b2b_otp.rb
CHANGED
@@ -184,6 +184,9 @@ module StytchB2B
|
|
184
184
|
# set_default_mfa::
|
185
185
|
# (no documentation yet)
|
186
186
|
# The type of this field is nilable +Boolean+.
|
187
|
+
# telemetry_id::
|
188
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
189
|
+
# The type of this field is nilable +String+.
|
187
190
|
#
|
188
191
|
# == Returns:
|
189
192
|
# An object with the following fields:
|
@@ -211,6 +214,9 @@ module StytchB2B
|
|
211
214
|
# member_session::
|
212
215
|
# The [Session object](https://stytch.com/docs/b2b/api/session-object).
|
213
216
|
# The type of this field is nilable +MemberSession+ (+object+).
|
217
|
+
# member_device::
|
218
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
219
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
214
220
|
def authenticate(
|
215
221
|
organization_id:,
|
216
222
|
member_id:,
|
@@ -221,7 +227,8 @@ module StytchB2B
|
|
221
227
|
session_duration_minutes: nil,
|
222
228
|
session_custom_claims: nil,
|
223
229
|
set_mfa_enrollment: nil,
|
224
|
-
set_default_mfa: nil
|
230
|
+
set_default_mfa: nil,
|
231
|
+
telemetry_id: nil
|
225
232
|
)
|
226
233
|
headers = {}
|
227
234
|
request = {
|
@@ -236,6 +243,7 @@ module StytchB2B
|
|
236
243
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
237
244
|
request[:set_mfa_enrollment] = set_mfa_enrollment unless set_mfa_enrollment.nil?
|
238
245
|
request[:set_default_mfa] = set_default_mfa unless set_default_mfa.nil?
|
246
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
239
247
|
|
240
248
|
post_request('/v1/b2b/otps/sms/authenticate', request, headers)
|
241
249
|
end
|
@@ -383,6 +391,9 @@ module StytchB2B
|
|
383
391
|
# Request support for additional languages [here](https://docs.google.com/forms/d/e/1FAIpQLScZSpAu_m2AmLXRT3F3kap-s_mcV6UTBitYn6CdyWP0-o7YjQ/viewform?usp=sf_link")!
|
384
392
|
#
|
385
393
|
# The type of this field is nilable +AuthenticateRequestLocale+ (string enum).
|
394
|
+
# telemetry_id::
|
395
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
396
|
+
# The type of this field is nilable +String+.
|
386
397
|
#
|
387
398
|
# == Returns:
|
388
399
|
# An object with the following fields:
|
@@ -428,6 +439,9 @@ module StytchB2B
|
|
428
439
|
# primary_required::
|
429
440
|
# (no documentation yet)
|
430
441
|
# The type of this field is nilable +PrimaryRequired+ (+object+).
|
442
|
+
# member_device::
|
443
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
444
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
431
445
|
def authenticate(
|
432
446
|
organization_id:,
|
433
447
|
email_address:,
|
@@ -437,7 +451,8 @@ module StytchB2B
|
|
437
451
|
intermediate_session_token: nil,
|
438
452
|
session_duration_minutes: nil,
|
439
453
|
session_custom_claims: nil,
|
440
|
-
locale: nil
|
454
|
+
locale: nil,
|
455
|
+
telemetry_id: nil
|
441
456
|
)
|
442
457
|
headers = {}
|
443
458
|
request = {
|
@@ -451,6 +466,7 @@ module StytchB2B
|
|
451
466
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
452
467
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
453
468
|
request[:locale] = locale unless locale.nil?
|
469
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
454
470
|
|
455
471
|
post_request('/v1/b2b/otps/email/authenticate', request, headers)
|
456
472
|
end
|
data/lib/stytch/b2b_passwords.rb
CHANGED
@@ -284,6 +284,9 @@ module StytchB2B
|
|
284
284
|
# intermediate_session_token::
|
285
285
|
# Adds this primary authentication factor to the intermediate session token. If the resulting set of factors satisfies the organization's primary authentication requirements and MFA requirements, the intermediate session token will be consumed and converted to a member session. If not, the same intermediate session token will be returned.
|
286
286
|
# The type of this field is nilable +String+.
|
287
|
+
# telemetry_id::
|
288
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
289
|
+
# The type of this field is nilable +String+.
|
287
290
|
#
|
288
291
|
# == Returns:
|
289
292
|
# An object with the following fields:
|
@@ -326,6 +329,9 @@ module StytchB2B
|
|
326
329
|
# primary_required::
|
327
330
|
# Information about the primary authentication requirements of the Organization.
|
328
331
|
# The type of this field is nilable +PrimaryRequired+ (+object+).
|
332
|
+
# member_device::
|
333
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
334
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
329
335
|
def authenticate(
|
330
336
|
organization_id:,
|
331
337
|
email_address:,
|
@@ -335,7 +341,8 @@ module StytchB2B
|
|
335
341
|
session_jwt: nil,
|
336
342
|
session_custom_claims: nil,
|
337
343
|
locale: nil,
|
338
|
-
intermediate_session_token: nil
|
344
|
+
intermediate_session_token: nil,
|
345
|
+
telemetry_id: nil
|
339
346
|
)
|
340
347
|
headers = {}
|
341
348
|
request = {
|
@@ -349,6 +356,7 @@ module StytchB2B
|
|
349
356
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
350
357
|
request[:locale] = locale unless locale.nil?
|
351
358
|
request[:intermediate_session_token] = intermediate_session_token unless intermediate_session_token.nil?
|
359
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
352
360
|
|
353
361
|
post_request('/v1/b2b/passwords/authenticate', request, headers)
|
354
362
|
end
|
@@ -534,6 +542,9 @@ module StytchB2B
|
|
534
542
|
# intermediate_session_token::
|
535
543
|
# Adds this primary authentication factor to the intermediate session token. If the resulting set of factors satisfies the organization's primary authentication requirements and MFA requirements, the intermediate session token will be consumed and converted to a member session. If not, the same intermediate session token will be returned.
|
536
544
|
# The type of this field is nilable +String+.
|
545
|
+
# telemetry_id::
|
546
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
547
|
+
# The type of this field is nilable +String+.
|
537
548
|
#
|
538
549
|
# == Returns:
|
539
550
|
# An object with the following fields:
|
@@ -579,6 +590,9 @@ module StytchB2B
|
|
579
590
|
# primary_required::
|
580
591
|
# Information about the primary authentication requirements of the Organization.
|
581
592
|
# The type of this field is nilable +PrimaryRequired+ (+object+).
|
593
|
+
# member_device::
|
594
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
595
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
582
596
|
def reset(
|
583
597
|
password_reset_token:,
|
584
598
|
password:,
|
@@ -588,7 +602,8 @@ module StytchB2B
|
|
588
602
|
code_verifier: nil,
|
589
603
|
session_custom_claims: nil,
|
590
604
|
locale: nil,
|
591
|
-
intermediate_session_token: nil
|
605
|
+
intermediate_session_token: nil,
|
606
|
+
telemetry_id: nil
|
592
607
|
)
|
593
608
|
headers = {}
|
594
609
|
request = {
|
@@ -602,6 +617,7 @@ module StytchB2B
|
|
602
617
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
603
618
|
request[:locale] = locale unless locale.nil?
|
604
619
|
request[:intermediate_session_token] = intermediate_session_token unless intermediate_session_token.nil?
|
620
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
605
621
|
|
606
622
|
post_request('/v1/b2b/passwords/email/reset', request, headers)
|
607
623
|
end
|
@@ -709,6 +725,9 @@ module StytchB2B
|
|
709
725
|
# Request support for additional languages [here](https://docs.google.com/forms/d/e/1FAIpQLScZSpAu_m2AmLXRT3F3kap-s_mcV6UTBitYn6CdyWP0-o7YjQ/viewform?usp=sf_link")!
|
710
726
|
#
|
711
727
|
# The type of this field is nilable +ResetRequestLocale+ (string enum).
|
728
|
+
# telemetry_id::
|
729
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
730
|
+
# The type of this field is nilable +String+.
|
712
731
|
#
|
713
732
|
# == Returns:
|
714
733
|
# An object with the following fields:
|
@@ -745,6 +764,9 @@ module StytchB2B
|
|
745
764
|
# mfa_required::
|
746
765
|
# Information about the MFA requirements of the Organization and the Member's options for fulfilling MFA.
|
747
766
|
# The type of this field is nilable +MfaRequired+ (+object+).
|
767
|
+
# member_device::
|
768
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
769
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
748
770
|
def reset(
|
749
771
|
organization_id:,
|
750
772
|
password:,
|
@@ -752,7 +774,8 @@ module StytchB2B
|
|
752
774
|
session_jwt: nil,
|
753
775
|
session_duration_minutes: nil,
|
754
776
|
session_custom_claims: nil,
|
755
|
-
locale: nil
|
777
|
+
locale: nil,
|
778
|
+
telemetry_id: nil
|
756
779
|
)
|
757
780
|
headers = {}
|
758
781
|
request = {
|
@@ -764,6 +787,7 @@ module StytchB2B
|
|
764
787
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
765
788
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
766
789
|
request[:locale] = locale unless locale.nil?
|
790
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
767
791
|
|
768
792
|
post_request('/v1/b2b/passwords/session/reset', request, headers)
|
769
793
|
end
|
@@ -839,6 +863,9 @@ module StytchB2B
|
|
839
863
|
# Request support for additional languages [here](https://docs.google.com/forms/d/e/1FAIpQLScZSpAu_m2AmLXRT3F3kap-s_mcV6UTBitYn6CdyWP0-o7YjQ/viewform?usp=sf_link")!
|
840
864
|
#
|
841
865
|
# The type of this field is nilable +ResetRequestLocale+ (string enum).
|
866
|
+
# telemetry_id::
|
867
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
868
|
+
# The type of this field is nilable +String+.
|
842
869
|
#
|
843
870
|
# == Returns:
|
844
871
|
# An object with the following fields:
|
@@ -878,6 +905,9 @@ module StytchB2B
|
|
878
905
|
# primary_required::
|
879
906
|
# Information about the primary authentication requirements of the Organization.
|
880
907
|
# The type of this field is nilable +PrimaryRequired+ (+object+).
|
908
|
+
# member_device::
|
909
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
910
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
881
911
|
def reset(
|
882
912
|
email_address:,
|
883
913
|
existing_password:,
|
@@ -887,7 +917,8 @@ module StytchB2B
|
|
887
917
|
session_duration_minutes: nil,
|
888
918
|
session_jwt: nil,
|
889
919
|
session_custom_claims: nil,
|
890
|
-
locale: nil
|
920
|
+
locale: nil,
|
921
|
+
telemetry_id: nil
|
891
922
|
)
|
892
923
|
headers = {}
|
893
924
|
request = {
|
@@ -901,6 +932,7 @@ module StytchB2B
|
|
901
932
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
902
933
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
903
934
|
request[:locale] = locale unless locale.nil?
|
935
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
904
936
|
|
905
937
|
post_request('/v1/b2b/passwords/existing_password/reset', request, headers)
|
906
938
|
end
|
@@ -55,6 +55,9 @@ module StytchB2B
|
|
55
55
|
# delete a key, supply a null value. Custom claims made with reserved claims (`iss`, `sub`, `aud`, `exp`, `nbf`, `iat`, `jti`) will be ignored.
|
56
56
|
# Total custom claims size cannot exceed four kilobytes.
|
57
57
|
# The type of this field is nilable +object+.
|
58
|
+
# telemetry_id::
|
59
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
60
|
+
# The type of this field is nilable +String+.
|
58
61
|
#
|
59
62
|
# == Returns:
|
60
63
|
# An object with the following fields:
|
@@ -85,6 +88,9 @@ module StytchB2B
|
|
85
88
|
# member_session::
|
86
89
|
# The [Session object](https://stytch.com/docs/b2b/api/session-object).
|
87
90
|
# The type of this field is nilable +MemberSession+ (+object+).
|
91
|
+
# member_device::
|
92
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
93
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
88
94
|
def recover(
|
89
95
|
organization_id:,
|
90
96
|
member_id:,
|
@@ -93,7 +99,8 @@ module StytchB2B
|
|
93
99
|
session_token: nil,
|
94
100
|
session_jwt: nil,
|
95
101
|
session_duration_minutes: nil,
|
96
|
-
session_custom_claims: nil
|
102
|
+
session_custom_claims: nil,
|
103
|
+
telemetry_id: nil
|
97
104
|
)
|
98
105
|
headers = {}
|
99
106
|
request = {
|
@@ -106,6 +113,7 @@ module StytchB2B
|
|
106
113
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
107
114
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
108
115
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
116
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
109
117
|
|
110
118
|
post_request('/v1/b2b/recovery_codes/recover', request, headers)
|
111
119
|
end
|
data/lib/stytch/b2b_sessions.rb
CHANGED
@@ -284,6 +284,9 @@ module StytchB2B
|
|
284
284
|
# Request support for additional languages [here](https://docs.google.com/forms/d/e/1FAIpQLScZSpAu_m2AmLXRT3F3kap-s_mcV6UTBitYn6CdyWP0-o7YjQ/viewform?usp=sf_link")!
|
285
285
|
#
|
286
286
|
# The type of this field is nilable +ExchangeRequestLocale+ (string enum).
|
287
|
+
# telemetry_id::
|
288
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
289
|
+
# The type of this field is nilable +String+.
|
287
290
|
#
|
288
291
|
# == Returns:
|
289
292
|
# An object with the following fields:
|
@@ -323,13 +326,17 @@ module StytchB2B
|
|
323
326
|
# primary_required::
|
324
327
|
# Information about the primary authentication requirements of the Organization.
|
325
328
|
# The type of this field is nilable +PrimaryRequired+ (+object+).
|
329
|
+
# member_device::
|
330
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
331
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
326
332
|
def exchange(
|
327
333
|
organization_id:,
|
328
334
|
session_token: nil,
|
329
335
|
session_jwt: nil,
|
330
336
|
session_duration_minutes: nil,
|
331
337
|
session_custom_claims: nil,
|
332
|
-
locale: nil
|
338
|
+
locale: nil,
|
339
|
+
telemetry_id: nil
|
333
340
|
)
|
334
341
|
headers = {}
|
335
342
|
request = {
|
@@ -340,6 +347,7 @@ module StytchB2B
|
|
340
347
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
341
348
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
342
349
|
request[:locale] = locale unless locale.nil?
|
350
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
343
351
|
|
344
352
|
post_request('/v1/b2b/sessions/exchange', request, headers)
|
345
353
|
end
|
@@ -375,6 +383,9 @@ module StytchB2B
|
|
375
383
|
# delete a key, supply a null value. Custom claims made with reserved claims (`iss`, `sub`, `aud`, `exp`, `nbf`, `iat`, `jti`) will be ignored.
|
376
384
|
# Total custom claims size cannot exceed four kilobytes.
|
377
385
|
# The type of this field is nilable +object+.
|
386
|
+
# telemetry_id::
|
387
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
388
|
+
# The type of this field is nilable +String+.
|
378
389
|
#
|
379
390
|
# == Returns:
|
380
391
|
# An object with the following fields:
|
@@ -402,10 +413,14 @@ module StytchB2B
|
|
402
413
|
# member_session::
|
403
414
|
# The [Session object](https://stytch.com/docs/b2b/api/session-object).
|
404
415
|
# The type of this field is nilable +MemberSession+ (+object+).
|
416
|
+
# member_device::
|
417
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
418
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
405
419
|
def exchange_access_token(
|
406
420
|
access_token:,
|
407
421
|
session_duration_minutes: nil,
|
408
|
-
session_custom_claims: nil
|
422
|
+
session_custom_claims: nil,
|
423
|
+
telemetry_id: nil
|
409
424
|
)
|
410
425
|
headers = {}
|
411
426
|
request = {
|
@@ -413,6 +428,7 @@ module StytchB2B
|
|
413
428
|
}
|
414
429
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
415
430
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
431
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
416
432
|
|
417
433
|
post_request('/v1/b2b/sessions/exchange_access_token', request, headers)
|
418
434
|
end
|
@@ -453,6 +469,9 @@ module StytchB2B
|
|
453
469
|
# session_jwt::
|
454
470
|
# The `session_jwt` for the session that you wish to add the trusted auth token authentication factor to.
|
455
471
|
# The type of this field is nilable +String+.
|
472
|
+
# telemetry_id::
|
473
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
474
|
+
# The type of this field is nilable +String+.
|
456
475
|
#
|
457
476
|
# == Returns:
|
458
477
|
# An object with the following fields:
|
@@ -480,6 +499,9 @@ module StytchB2B
|
|
480
499
|
# status_code::
|
481
500
|
# The HTTP status code of the response. Stytch follows standard HTTP response status code patterns, e.g. 2XX values equate to success, 3XX values are redirects, 4XX are client errors, and 5XX are server errors.
|
482
501
|
# The type of this field is +Integer+.
|
502
|
+
# member_device::
|
503
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
504
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
483
505
|
def attest(
|
484
506
|
organization_id:,
|
485
507
|
profile_id:,
|
@@ -487,7 +509,8 @@ module StytchB2B
|
|
487
509
|
session_duration_minutes: nil,
|
488
510
|
session_custom_claims: nil,
|
489
511
|
session_token: nil,
|
490
|
-
session_jwt: nil
|
512
|
+
session_jwt: nil,
|
513
|
+
telemetry_id: nil
|
491
514
|
)
|
492
515
|
headers = {}
|
493
516
|
request = {
|
@@ -499,6 +522,7 @@ module StytchB2B
|
|
499
522
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
500
523
|
request[:session_token] = session_token unless session_token.nil?
|
501
524
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
525
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
502
526
|
|
503
527
|
post_request('/v1/b2b/sessions/attest', request, headers)
|
504
528
|
end
|
data/lib/stytch/b2b_sso.rb
CHANGED
@@ -188,6 +188,9 @@ module StytchB2B
|
|
188
188
|
# intermediate_session_token::
|
189
189
|
# Adds this primary authentication factor to the intermediate session token. If the resulting set of factors satisfies the organization's primary authentication requirements and MFA requirements, the intermediate session token will be consumed and converted to a member session. If not, the same intermediate session token will be returned.
|
190
190
|
# The type of this field is nilable +String+.
|
191
|
+
# telemetry_id::
|
192
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
193
|
+
# The type of this field is nilable +String+.
|
191
194
|
#
|
192
195
|
# == Returns:
|
193
196
|
# An object with the following fields:
|
@@ -233,6 +236,9 @@ module StytchB2B
|
|
233
236
|
# primary_required::
|
234
237
|
# (no documentation yet)
|
235
238
|
# The type of this field is nilable +PrimaryRequired+ (+object+).
|
239
|
+
# member_device::
|
240
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
241
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
236
242
|
def authenticate(
|
237
243
|
sso_token:,
|
238
244
|
pkce_code_verifier: nil,
|
@@ -241,7 +247,8 @@ module StytchB2B
|
|
241
247
|
session_duration_minutes: nil,
|
242
248
|
session_custom_claims: nil,
|
243
249
|
locale: nil,
|
244
|
-
intermediate_session_token: nil
|
250
|
+
intermediate_session_token: nil,
|
251
|
+
telemetry_id: nil
|
245
252
|
)
|
246
253
|
headers = {}
|
247
254
|
request = {
|
@@ -254,6 +261,7 @@ module StytchB2B
|
|
254
261
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
255
262
|
request[:locale] = locale unless locale.nil?
|
256
263
|
request[:intermediate_session_token] = intermediate_session_token unless intermediate_session_token.nil?
|
264
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
257
265
|
|
258
266
|
post_request('/v1/b2b/sso/authenticate', request, headers)
|
259
267
|
end
|
data/lib/stytch/b2b_totps.rb
CHANGED
@@ -142,6 +142,9 @@ module StytchB2B
|
|
142
142
|
# set_default_mfa::
|
143
143
|
# If passed will set the authenticated method to the default MFA method. Completing an MFA authentication flow for the first time for a Member will implicitly set the method to the default MFA method. This option can be used to update the default MFA method if multiple are being used.
|
144
144
|
# The type of this field is nilable +Boolean+.
|
145
|
+
# telemetry_id::
|
146
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the Member. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
147
|
+
# The type of this field is nilable +String+.
|
145
148
|
#
|
146
149
|
# == Returns:
|
147
150
|
# An object with the following fields:
|
@@ -169,6 +172,9 @@ module StytchB2B
|
|
169
172
|
# member_session::
|
170
173
|
# The [Session object](https://stytch.com/docs/b2b/api/session-object).
|
171
174
|
# The type of this field is nilable +MemberSession+ (+object+).
|
175
|
+
# member_device::
|
176
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `member_device` response field will contain information about the member's device attributes.
|
177
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
172
178
|
def authenticate(
|
173
179
|
organization_id:,
|
174
180
|
member_id:,
|
@@ -179,7 +185,8 @@ module StytchB2B
|
|
179
185
|
session_duration_minutes: nil,
|
180
186
|
session_custom_claims: nil,
|
181
187
|
set_mfa_enrollment: nil,
|
182
|
-
set_default_mfa: nil
|
188
|
+
set_default_mfa: nil,
|
189
|
+
telemetry_id: nil
|
183
190
|
)
|
184
191
|
headers = {}
|
185
192
|
request = {
|
@@ -194,6 +201,7 @@ module StytchB2B
|
|
194
201
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
195
202
|
request[:set_mfa_enrollment] = set_mfa_enrollment unless set_mfa_enrollment.nil?
|
196
203
|
request[:set_default_mfa] = set_default_mfa unless set_default_mfa.nil?
|
204
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
197
205
|
|
198
206
|
post_request('/v1/b2b/totp/authenticate', request, headers)
|
199
207
|
end
|
@@ -115,6 +115,9 @@ module Stytch
|
|
115
115
|
#
|
116
116
|
# Custom claims made with reserved claims ("iss", "sub", "aud", "exp", "nbf", "iat", "jti") will be ignored. Total custom claims size cannot exceed four kilobytes.
|
117
117
|
# The type of this field is nilable +object+.
|
118
|
+
# telemetry_id::
|
119
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
120
|
+
# The type of this field is nilable +String+.
|
118
121
|
#
|
119
122
|
# == Returns:
|
120
123
|
# An object with the following fields:
|
@@ -145,6 +148,9 @@ module Stytch
|
|
145
148
|
# siwe_params::
|
146
149
|
# The parameters of the Sign In With Ethereum (SIWE) message that was signed.
|
147
150
|
# The type of this field is nilable +SIWEParamsResponse+ (+object+).
|
151
|
+
# user_device::
|
152
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
153
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
148
154
|
def authenticate(
|
149
155
|
crypto_wallet_type:,
|
150
156
|
crypto_wallet_address:,
|
@@ -152,7 +158,8 @@ module Stytch
|
|
152
158
|
session_token: nil,
|
153
159
|
session_duration_minutes: nil,
|
154
160
|
session_jwt: nil,
|
155
|
-
session_custom_claims: nil
|
161
|
+
session_custom_claims: nil,
|
162
|
+
telemetry_id: nil
|
156
163
|
)
|
157
164
|
headers = {}
|
158
165
|
request = {
|
@@ -164,6 +171,7 @@ module Stytch
|
|
164
171
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
165
172
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
166
173
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
174
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
167
175
|
|
168
176
|
post_request('/v1/crypto_wallets/authenticate', request, headers)
|
169
177
|
end
|
data/lib/stytch/magic_links.rb
CHANGED
@@ -60,6 +60,9 @@ module Stytch
|
|
60
60
|
# code_verifier::
|
61
61
|
# A base64url encoded one time secret used to validate that the request starts and ends on the same device.
|
62
62
|
# The type of this field is nilable +String+.
|
63
|
+
# telemetry_id::
|
64
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
65
|
+
# The type of this field is nilable +String+.
|
63
66
|
#
|
64
67
|
# == Returns:
|
65
68
|
# An object with the following fields:
|
@@ -93,6 +96,9 @@ module Stytch
|
|
93
96
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
94
97
|
#
|
95
98
|
# The type of this field is nilable +Session+ (+object+).
|
99
|
+
# user_device::
|
100
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
101
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
96
102
|
def authenticate(
|
97
103
|
token:,
|
98
104
|
attributes: nil,
|
@@ -101,7 +107,8 @@ module Stytch
|
|
101
107
|
session_duration_minutes: nil,
|
102
108
|
session_jwt: nil,
|
103
109
|
session_custom_claims: nil,
|
104
|
-
code_verifier: nil
|
110
|
+
code_verifier: nil,
|
111
|
+
telemetry_id: nil
|
105
112
|
)
|
106
113
|
headers = {}
|
107
114
|
request = {
|
@@ -114,6 +121,7 @@ module Stytch
|
|
114
121
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
115
122
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
116
123
|
request[:code_verifier] = code_verifier unless code_verifier.nil?
|
124
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
117
125
|
|
118
126
|
post_request('/v1/magic_links/authenticate', request, headers)
|
119
127
|
end
|
data/lib/stytch/oauth.rb
CHANGED
@@ -101,6 +101,9 @@ module Stytch
|
|
101
101
|
# code_verifier::
|
102
102
|
# A base64url encoded one time secret used to validate that the request starts and ends on the same device.
|
103
103
|
# The type of this field is nilable +String+.
|
104
|
+
# telemetry_id::
|
105
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
106
|
+
# The type of this field is nilable +String+.
|
104
107
|
#
|
105
108
|
# == Returns:
|
106
109
|
# An object with the following fields:
|
@@ -145,13 +148,17 @@ module Stytch
|
|
145
148
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
146
149
|
#
|
147
150
|
# The type of this field is nilable +Session+ (+object+).
|
151
|
+
# user_device::
|
152
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
153
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
148
154
|
def authenticate(
|
149
155
|
token:,
|
150
156
|
session_token: nil,
|
151
157
|
session_duration_minutes: nil,
|
152
158
|
session_jwt: nil,
|
153
159
|
session_custom_claims: nil,
|
154
|
-
code_verifier: nil
|
160
|
+
code_verifier: nil,
|
161
|
+
telemetry_id: nil
|
155
162
|
)
|
156
163
|
headers = {}
|
157
164
|
request = {
|
@@ -162,6 +169,7 @@ module Stytch
|
|
162
169
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
163
170
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
164
171
|
request[:code_verifier] = code_verifier unless code_verifier.nil?
|
172
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
165
173
|
|
166
174
|
post_request('/v1/oauth/authenticate', request, headers)
|
167
175
|
end
|
data/lib/stytch/otps.rb
CHANGED
@@ -58,6 +58,9 @@ module Stytch
|
|
58
58
|
#
|
59
59
|
# Custom claims made with reserved claims ("iss", "sub", "aud", "exp", "nbf", "iat", "jti") will be ignored. Total custom claims size cannot exceed four kilobytes.
|
60
60
|
# The type of this field is nilable +object+.
|
61
|
+
# telemetry_id::
|
62
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
63
|
+
# The type of this field is nilable +String+.
|
61
64
|
#
|
62
65
|
# == Returns:
|
63
66
|
# An object with the following fields:
|
@@ -91,6 +94,9 @@ module Stytch
|
|
91
94
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
92
95
|
#
|
93
96
|
# The type of this field is nilable +Session+ (+object+).
|
97
|
+
# user_device::
|
98
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
99
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
94
100
|
def authenticate(
|
95
101
|
method_id:,
|
96
102
|
code:,
|
@@ -99,7 +105,8 @@ module Stytch
|
|
99
105
|
session_token: nil,
|
100
106
|
session_duration_minutes: nil,
|
101
107
|
session_jwt: nil,
|
102
|
-
session_custom_claims: nil
|
108
|
+
session_custom_claims: nil,
|
109
|
+
telemetry_id: nil
|
103
110
|
)
|
104
111
|
headers = {}
|
105
112
|
request = {
|
@@ -112,6 +119,7 @@ module Stytch
|
|
112
119
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
113
120
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
114
121
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
122
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
115
123
|
|
116
124
|
post_request('/v1/otps/authenticate', request, headers)
|
117
125
|
end
|
data/lib/stytch/passwords.rb
CHANGED
@@ -61,6 +61,9 @@ module Stytch
|
|
61
61
|
# name::
|
62
62
|
# The name of the user. Each field in the name object is optional.
|
63
63
|
# The type of this field is nilable +Name+ (+object+).
|
64
|
+
# telemetry_id::
|
65
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
66
|
+
# The type of this field is nilable +String+.
|
64
67
|
#
|
65
68
|
# == Returns:
|
66
69
|
# An object with the following fields:
|
@@ -91,6 +94,9 @@ module Stytch
|
|
91
94
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
92
95
|
#
|
93
96
|
# The type of this field is nilable +Session+ (+object+).
|
97
|
+
# user_device::
|
98
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
99
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
94
100
|
def create(
|
95
101
|
email:,
|
96
102
|
password:,
|
@@ -98,7 +104,8 @@ module Stytch
|
|
98
104
|
session_custom_claims: nil,
|
99
105
|
trusted_metadata: nil,
|
100
106
|
untrusted_metadata: nil,
|
101
|
-
name: nil
|
107
|
+
name: nil,
|
108
|
+
telemetry_id: nil
|
102
109
|
)
|
103
110
|
headers = {}
|
104
111
|
request = {
|
@@ -110,6 +117,7 @@ module Stytch
|
|
110
117
|
request[:trusted_metadata] = trusted_metadata unless trusted_metadata.nil?
|
111
118
|
request[:untrusted_metadata] = untrusted_metadata unless untrusted_metadata.nil?
|
112
119
|
request[:name] = name unless name.nil?
|
120
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
113
121
|
|
114
122
|
post_request('/v1/passwords', request, headers)
|
115
123
|
end
|
@@ -151,6 +159,9 @@ module Stytch
|
|
151
159
|
#
|
152
160
|
# Custom claims made with reserved claims ("iss", "sub", "aud", "exp", "nbf", "iat", "jti") will be ignored. Total custom claims size cannot exceed four kilobytes.
|
153
161
|
# The type of this field is nilable +object+.
|
162
|
+
# telemetry_id::
|
163
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
164
|
+
# The type of this field is nilable +String+.
|
154
165
|
#
|
155
166
|
# == Returns:
|
156
167
|
# An object with the following fields:
|
@@ -178,13 +189,17 @@ module Stytch
|
|
178
189
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
179
190
|
#
|
180
191
|
# The type of this field is nilable +Session+ (+object+).
|
192
|
+
# user_device::
|
193
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
194
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
181
195
|
def authenticate(
|
182
196
|
email:,
|
183
197
|
password:,
|
184
198
|
session_token: nil,
|
185
199
|
session_duration_minutes: nil,
|
186
200
|
session_jwt: nil,
|
187
|
-
session_custom_claims: nil
|
201
|
+
session_custom_claims: nil,
|
202
|
+
telemetry_id: nil
|
188
203
|
)
|
189
204
|
headers = {}
|
190
205
|
request = {
|
@@ -195,6 +210,7 @@ module Stytch
|
|
195
210
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
196
211
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
197
212
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
213
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
198
214
|
|
199
215
|
post_request('/v1/passwords/authenticate', request, headers)
|
200
216
|
end
|
@@ -510,6 +526,9 @@ module Stytch
|
|
510
526
|
# options::
|
511
527
|
# Specify optional security settings.
|
512
528
|
# The type of this field is nilable +Options+ (+object+).
|
529
|
+
# telemetry_id::
|
530
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
531
|
+
# The type of this field is nilable +String+.
|
513
532
|
#
|
514
533
|
# == Returns:
|
515
534
|
# An object with the following fields:
|
@@ -537,6 +556,9 @@ module Stytch
|
|
537
556
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
538
557
|
#
|
539
558
|
# The type of this field is nilable +Session+ (+object+).
|
559
|
+
# user_device::
|
560
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
561
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
540
562
|
def reset(
|
541
563
|
token:,
|
542
564
|
password:,
|
@@ -546,7 +568,8 @@ module Stytch
|
|
546
568
|
code_verifier: nil,
|
547
569
|
session_custom_claims: nil,
|
548
570
|
attributes: nil,
|
549
|
-
options: nil
|
571
|
+
options: nil,
|
572
|
+
telemetry_id: nil
|
550
573
|
)
|
551
574
|
headers = {}
|
552
575
|
request = {
|
@@ -560,6 +583,7 @@ module Stytch
|
|
560
583
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
561
584
|
request[:attributes] = attributes unless attributes.nil?
|
562
585
|
request[:options] = options unless options.nil?
|
586
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
563
587
|
|
564
588
|
post_request('/v1/passwords/email/reset', request, headers)
|
565
589
|
end
|
@@ -608,6 +632,9 @@ module Stytch
|
|
608
632
|
#
|
609
633
|
# Custom claims made with reserved claims ("iss", "sub", "aud", "exp", "nbf", "iat", "jti") will be ignored. Total custom claims size cannot exceed four kilobytes.
|
610
634
|
# The type of this field is nilable +object+.
|
635
|
+
# telemetry_id::
|
636
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
637
|
+
# The type of this field is nilable +String+.
|
611
638
|
#
|
612
639
|
# == Returns:
|
613
640
|
# An object with the following fields:
|
@@ -635,6 +662,9 @@ module Stytch
|
|
635
662
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
636
663
|
#
|
637
664
|
# The type of this field is nilable +Session+ (+object+).
|
665
|
+
# user_device::
|
666
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
667
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
638
668
|
def reset(
|
639
669
|
email:,
|
640
670
|
existing_password:,
|
@@ -642,7 +672,8 @@ module Stytch
|
|
642
672
|
session_token: nil,
|
643
673
|
session_duration_minutes: nil,
|
644
674
|
session_jwt: nil,
|
645
|
-
session_custom_claims: nil
|
675
|
+
session_custom_claims: nil,
|
676
|
+
telemetry_id: nil
|
646
677
|
)
|
647
678
|
headers = {}
|
648
679
|
request = {
|
@@ -654,6 +685,7 @@ module Stytch
|
|
654
685
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
655
686
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
656
687
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
688
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
657
689
|
|
658
690
|
post_request('/v1/passwords/existing_password/reset', request, headers)
|
659
691
|
end
|
@@ -696,6 +728,9 @@ module Stytch
|
|
696
728
|
#
|
697
729
|
# Custom claims made with reserved claims ("iss", "sub", "aud", "exp", "nbf", "iat", "jti") will be ignored. Total custom claims size cannot exceed four kilobytes.
|
698
730
|
# The type of this field is nilable +object+.
|
731
|
+
# telemetry_id::
|
732
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
733
|
+
# The type of this field is nilable +String+.
|
699
734
|
#
|
700
735
|
# == Returns:
|
701
736
|
# An object with the following fields:
|
@@ -723,12 +758,16 @@ module Stytch
|
|
723
758
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
724
759
|
#
|
725
760
|
# The type of this field is nilable +Session+ (+object+).
|
761
|
+
# user_device::
|
762
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
763
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
726
764
|
def reset(
|
727
765
|
password:,
|
728
766
|
session_token: nil,
|
729
767
|
session_jwt: nil,
|
730
768
|
session_duration_minutes: nil,
|
731
|
-
session_custom_claims: nil
|
769
|
+
session_custom_claims: nil,
|
770
|
+
telemetry_id: nil
|
732
771
|
)
|
733
772
|
headers = {}
|
734
773
|
request = {
|
@@ -738,6 +777,7 @@ module Stytch
|
|
738
777
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
739
778
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
740
779
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
780
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
741
781
|
|
742
782
|
post_request('/v1/passwords/session/reset', request, headers)
|
743
783
|
end
|
data/lib/stytch/sessions.rb
CHANGED
@@ -192,6 +192,9 @@ module Stytch
|
|
192
192
|
#
|
193
193
|
# Custom claims made with reserved claims ("iss", "sub", "aud", "exp", "nbf", "iat", "jti") will be ignored. Total custom claims size cannot exceed four kilobytes.
|
194
194
|
# The type of this field is nilable +object+.
|
195
|
+
# telemetry_id::
|
196
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
197
|
+
# The type of this field is nilable +String+.
|
195
198
|
#
|
196
199
|
# == Returns:
|
197
200
|
# An object with the following fields:
|
@@ -219,10 +222,14 @@ module Stytch
|
|
219
222
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
220
223
|
#
|
221
224
|
# The type of this field is nilable +Session+ (+object+).
|
225
|
+
# user_device::
|
226
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
227
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
222
228
|
def migrate(
|
223
229
|
session_token:,
|
224
230
|
session_duration_minutes: nil,
|
225
|
-
session_custom_claims: nil
|
231
|
+
session_custom_claims: nil,
|
232
|
+
telemetry_id: nil
|
226
233
|
)
|
227
234
|
headers = {}
|
228
235
|
request = {
|
@@ -230,6 +237,7 @@ module Stytch
|
|
230
237
|
}
|
231
238
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
232
239
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
240
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
233
241
|
|
234
242
|
post_request('/v1/sessions/migrate', request, headers)
|
235
243
|
end
|
@@ -261,6 +269,9 @@ module Stytch
|
|
261
269
|
#
|
262
270
|
# Custom claims made with reserved claims ("iss", "sub", "aud", "exp", "nbf", "iat", "jti") will be ignored. Total custom claims size cannot exceed four kilobytes.
|
263
271
|
# The type of this field is nilable +object+.
|
272
|
+
# telemetry_id::
|
273
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
274
|
+
# The type of this field is nilable +String+.
|
264
275
|
#
|
265
276
|
# == Returns:
|
266
277
|
# An object with the following fields:
|
@@ -288,10 +299,14 @@ module Stytch
|
|
288
299
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
289
300
|
#
|
290
301
|
# The type of this field is nilable +Session+ (+object+).
|
302
|
+
# user_device::
|
303
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
304
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
291
305
|
def exchange_access_token(
|
292
306
|
access_token:,
|
293
307
|
session_duration_minutes: nil,
|
294
|
-
session_custom_claims: nil
|
308
|
+
session_custom_claims: nil,
|
309
|
+
telemetry_id: nil
|
295
310
|
)
|
296
311
|
headers = {}
|
297
312
|
request = {
|
@@ -299,6 +314,7 @@ module Stytch
|
|
299
314
|
}
|
300
315
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
301
316
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
317
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
302
318
|
|
303
319
|
post_request('/v1/sessions/exchange_access_token', request, headers)
|
304
320
|
end
|
@@ -371,6 +387,9 @@ module Stytch
|
|
371
387
|
# session_jwt::
|
372
388
|
# The `session_jwt` for the session that you wish to add the trusted auth token authentication factor to.
|
373
389
|
# The type of this field is nilable +String+.
|
390
|
+
# telemetry_id::
|
391
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
392
|
+
# The type of this field is nilable +String+.
|
374
393
|
#
|
375
394
|
# == Returns:
|
376
395
|
# An object with the following fields:
|
@@ -398,13 +417,17 @@ module Stytch
|
|
398
417
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
399
418
|
#
|
400
419
|
# The type of this field is nilable +Session+ (+object+).
|
420
|
+
# user_device::
|
421
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
422
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
401
423
|
def attest(
|
402
424
|
profile_id:,
|
403
425
|
token:,
|
404
426
|
session_duration_minutes: nil,
|
405
427
|
session_custom_claims: nil,
|
406
428
|
session_token: nil,
|
407
|
-
session_jwt: nil
|
429
|
+
session_jwt: nil,
|
430
|
+
telemetry_id: nil
|
408
431
|
)
|
409
432
|
headers = {}
|
410
433
|
request = {
|
@@ -415,6 +438,7 @@ module Stytch
|
|
415
438
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
416
439
|
request[:session_token] = session_token unless session_token.nil?
|
417
440
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
441
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
418
442
|
|
419
443
|
post_request('/v1/sessions/attest', request, headers)
|
420
444
|
end
|
data/lib/stytch/totps.rb
CHANGED
@@ -96,6 +96,9 @@ module Stytch
|
|
96
96
|
#
|
97
97
|
# Custom claims made with reserved claims ("iss", "sub", "aud", "exp", "nbf", "iat", "jti") will be ignored. Total custom claims size cannot exceed four kilobytes.
|
98
98
|
# The type of this field is nilable +object+.
|
99
|
+
# telemetry_id::
|
100
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
101
|
+
# The type of this field is nilable +String+.
|
99
102
|
#
|
100
103
|
# == Returns:
|
101
104
|
# An object with the following fields:
|
@@ -126,13 +129,17 @@ module Stytch
|
|
126
129
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
127
130
|
#
|
128
131
|
# The type of this field is nilable +Session+ (+object+).
|
132
|
+
# user_device::
|
133
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
134
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
129
135
|
def authenticate(
|
130
136
|
user_id:,
|
131
137
|
totp_code:,
|
132
138
|
session_token: nil,
|
133
139
|
session_duration_minutes: nil,
|
134
140
|
session_jwt: nil,
|
135
|
-
session_custom_claims: nil
|
141
|
+
session_custom_claims: nil,
|
142
|
+
telemetry_id: nil
|
136
143
|
)
|
137
144
|
headers = {}
|
138
145
|
request = {
|
@@ -143,6 +150,7 @@ module Stytch
|
|
143
150
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
144
151
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
145
152
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
153
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
146
154
|
|
147
155
|
post_request('/v1/totps/authenticate', request, headers)
|
148
156
|
end
|
@@ -210,6 +218,9 @@ module Stytch
|
|
210
218
|
#
|
211
219
|
# Custom claims made with reserved claims ("iss", "sub", "aud", "exp", "nbf", "iat", "jti") will be ignored. Total custom claims size cannot exceed four kilobytes.
|
212
220
|
# The type of this field is nilable +object+.
|
221
|
+
# telemetry_id::
|
222
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
223
|
+
# The type of this field is nilable +String+.
|
213
224
|
#
|
214
225
|
# == Returns:
|
215
226
|
# An object with the following fields:
|
@@ -240,13 +251,17 @@ module Stytch
|
|
240
251
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
241
252
|
#
|
242
253
|
# The type of this field is nilable +Session+ (+object+).
|
254
|
+
# user_device::
|
255
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
256
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
243
257
|
def recover(
|
244
258
|
user_id:,
|
245
259
|
recovery_code:,
|
246
260
|
session_token: nil,
|
247
261
|
session_duration_minutes: nil,
|
248
262
|
session_jwt: nil,
|
249
|
-
session_custom_claims: nil
|
263
|
+
session_custom_claims: nil,
|
264
|
+
telemetry_id: nil
|
250
265
|
)
|
251
266
|
headers = {}
|
252
267
|
request = {
|
@@ -257,6 +272,7 @@ module Stytch
|
|
257
272
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
258
273
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
259
274
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
275
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
260
276
|
|
261
277
|
post_request('/v1/totps/recover', request, headers)
|
262
278
|
end
|
data/lib/stytch/users.rb
CHANGED
@@ -173,6 +173,9 @@ module Stytch
|
|
173
173
|
get_request(request, headers)
|
174
174
|
end
|
175
175
|
|
176
|
+
#
|
177
|
+
# **Warning**: This endpoint is not recommended for use in login flows. Scaling issues may occur, as search performance may vary from ~150 milliseconds to 9 seconds depending on query complexity and rate limits are set to 150 requests/second.
|
178
|
+
#
|
176
179
|
# Search for Users within your Stytch Project.
|
177
180
|
#
|
178
181
|
# Use the `query` object to filter by different fields. See the `query.operands.filter_value` documentation below for a list of available filters.
|
data/lib/stytch/version.rb
CHANGED
data/lib/stytch/webauthn.rb
CHANGED
@@ -128,6 +128,9 @@ module Stytch
|
|
128
128
|
#
|
129
129
|
# Custom claims made with reserved claims ("iss", "sub", "aud", "exp", "nbf", "iat", "jti") will be ignored. Total custom claims size cannot exceed four kilobytes.
|
130
130
|
# The type of this field is nilable +object+.
|
131
|
+
# telemetry_id::
|
132
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
133
|
+
# The type of this field is nilable +String+.
|
131
134
|
#
|
132
135
|
# == Returns:
|
133
136
|
# An object with the following fields:
|
@@ -158,13 +161,17 @@ module Stytch
|
|
158
161
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
159
162
|
#
|
160
163
|
# The type of this field is nilable +Session+ (+object+).
|
164
|
+
# user_device::
|
165
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
166
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
161
167
|
def register(
|
162
168
|
user_id:,
|
163
169
|
public_key_credential:,
|
164
170
|
session_token: nil,
|
165
171
|
session_duration_minutes: nil,
|
166
172
|
session_jwt: nil,
|
167
|
-
session_custom_claims: nil
|
173
|
+
session_custom_claims: nil,
|
174
|
+
telemetry_id: nil
|
168
175
|
)
|
169
176
|
headers = {}
|
170
177
|
request = {
|
@@ -175,6 +182,7 @@ module Stytch
|
|
175
182
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
176
183
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
177
184
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
185
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
178
186
|
|
179
187
|
post_request('/v1/webauthn/register', request, headers)
|
180
188
|
end
|
@@ -258,6 +266,9 @@ module Stytch
|
|
258
266
|
#
|
259
267
|
# Custom claims made with reserved claims ("iss", "sub", "aud", "exp", "nbf", "iat", "jti") will be ignored. Total custom claims size cannot exceed four kilobytes.
|
260
268
|
# The type of this field is nilable +object+.
|
269
|
+
# telemetry_id::
|
270
|
+
# If the `telemetry_id` is passed, as part of this request, Stytch will call the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) and store the associated fingerprints and IPGEO information for the User. Your workspace must be enabled for Device Fingerprinting to use this feature.
|
271
|
+
# The type of this field is nilable +String+.
|
261
272
|
#
|
262
273
|
# == Returns:
|
263
274
|
# An object with the following fields:
|
@@ -288,12 +299,16 @@ module Stytch
|
|
288
299
|
# See [Session object](https://stytch.com/docs/api/session-object) for complete response fields.
|
289
300
|
#
|
290
301
|
# The type of this field is nilable +Session+ (+object+).
|
302
|
+
# user_device::
|
303
|
+
# If a valid `telemetry_id` was passed in the request and the [Fingerprint Lookup API](https://stytch.com/docs/fraud/api/fingerprint-lookup) returned results, the `user_device` response field will contain information about the user's device attributes.
|
304
|
+
# The type of this field is nilable +DeviceInfo+ (+object+).
|
291
305
|
def authenticate(
|
292
306
|
public_key_credential:,
|
293
307
|
session_token: nil,
|
294
308
|
session_duration_minutes: nil,
|
295
309
|
session_jwt: nil,
|
296
|
-
session_custom_claims: nil
|
310
|
+
session_custom_claims: nil,
|
311
|
+
telemetry_id: nil
|
297
312
|
)
|
298
313
|
headers = {}
|
299
314
|
request = {
|
@@ -303,6 +318,7 @@ module Stytch
|
|
303
318
|
request[:session_duration_minutes] = session_duration_minutes unless session_duration_minutes.nil?
|
304
319
|
request[:session_jwt] = session_jwt unless session_jwt.nil?
|
305
320
|
request[:session_custom_claims] = session_custom_claims unless session_custom_claims.nil?
|
321
|
+
request[:telemetry_id] = telemetry_id unless telemetry_id.nil?
|
306
322
|
|
307
323
|
post_request('/v1/webauthn/authenticate', request, headers)
|
308
324
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: stytch
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 10.
|
4
|
+
version: 10.28.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- stytch
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-08-
|
11
|
+
date: 2025-08-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|