noresponse 2.0.17
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 +7 -0
- data/lib/crystalline/enum.rbi +17 -0
- data/lib/crystalline/metadata_fields.rb +263 -0
- data/lib/crystalline/module.rb +186 -0
- data/lib/crystalline/types.rb +168 -0
- data/lib/crystalline/utils.rb +67 -0
- data/lib/crystalline.rb +11 -0
- data/lib/no_response/assessments.rb +1252 -0
- data/lib/no_response/auth.rb +263 -0
- data/lib/no_response/issued_credential.rb +21 -0
- data/lib/no_response/keys.rb +318 -0
- data/lib/no_response/late_results.rb +301 -0
- data/lib/no_response/models/callbacks.rb +10 -0
- data/lib/no_response/models/errors/apistatuserror.rb +41 -0
- data/lib/no_response/models/errors/apistatuserror.rbi +30 -0
- data/lib/no_response/models/errors/authenticationerror.rb +108 -0
- data/lib/no_response/models/errors/authenticationerror.rbi +56 -0
- data/lib/no_response/models/errors/badrequesterror.rb +108 -0
- data/lib/no_response/models/errors/badrequesterror.rbi +56 -0
- data/lib/no_response/models/errors/conflicterror.rb +108 -0
- data/lib/no_response/models/errors/conflicterror.rbi +56 -0
- data/lib/no_response/models/errors/notfounderror.rb +108 -0
- data/lib/no_response/models/errors/notfounderror.rbi +56 -0
- data/lib/no_response/models/errors/permissiondeniederror.rb +108 -0
- data/lib/no_response/models/errors/permissiondeniederror.rbi +56 -0
- data/lib/no_response/models/errors/ratelimiterror.rb +108 -0
- data/lib/no_response/models/errors/ratelimiterror.rbi +56 -0
- data/lib/no_response/models/errors.rb +16 -0
- data/lib/no_response/models/operations/createassessment_request.rb +36 -0
- data/lib/no_response/models/operations/createassessment_request.rbi +20 -0
- data/lib/no_response/models/operations/createassessment_response.rb +32 -0
- data/lib/no_response/models/operations/createassessment_response.rbi +20 -0
- data/lib/no_response/models/operations/getassessment_request.rb +41 -0
- data/lib/no_response/models/operations/getassessment_request.rbi +20 -0
- data/lib/no_response/models/operations/getassessment_response.rb +32 -0
- data/lib/no_response/models/operations/getassessment_response.rbi +20 -0
- data/lib/no_response/models/operations/queryaccountassessments_response.rb +44 -0
- data/lib/no_response/models/operations/queryaccountassessments_response.rbi +20 -0
- data/lib/no_response/models/operations/recordassessmentoutcome_request.rb +52 -0
- data/lib/no_response/models/operations/recordassessmentoutcome_request.rbi +26 -0
- data/lib/no_response/models/operations/recordassessmentoutcome_response.rb +32 -0
- data/lib/no_response/models/operations/recordassessmentoutcome_response.rbi +20 -0
- data/lib/no_response/models/operations/rotateapikey_response.rb +32 -0
- data/lib/no_response/models/operations/rotateapikey_response.rbi +20 -0
- data/lib/no_response/models/operations.rb +17 -0
- data/lib/no_response/models/shared/alternate_name.rb +23 -0
- data/lib/no_response/models/shared/alternate_name.rbi +9 -0
- data/lib/no_response/models/shared/alternate_name_union.rb +23 -0
- data/lib/no_response/models/shared/alternate_name_union.rbi +9 -0
- data/lib/no_response/models/shared/assessment.rb +235 -0
- data/lib/no_response/models/shared/assessment.rbi +116 -0
- data/lib/no_response/models/shared/assessmentlist.rb +78 -0
- data/lib/no_response/models/shared/assessmentlist.rbi +38 -0
- data/lib/no_response/models/shared/assessmentoutcome.rb +61 -0
- data/lib/no_response/models/shared/assessmentoutcome.rbi +32 -0
- data/lib/no_response/models/shared/assessmentoutcomerequest.rb +71 -0
- data/lib/no_response/models/shared/assessmentoutcomerequest.rbi +32 -0
- data/lib/no_response/models/shared/assessmentquery.rb +70 -0
- data/lib/no_response/models/shared/assessmentquery.rbi +32 -0
- data/lib/no_response/models/shared/assessmentrequest.rb +125 -0
- data/lib/no_response/models/shared/assessmentrequest.rbi +62 -0
- data/lib/no_response/models/shared/assessmentrequestclientcontext.rb +125 -0
- data/lib/no_response/models/shared/assessmentrequestclientcontext.rbi +62 -0
- data/lib/no_response/models/shared/assessmentrequestidentifiers.rb +74 -0
- data/lib/no_response/models/shared/assessmentrequestidentifiers.rbi +38 -0
- data/lib/no_response/models/shared/assessmentrequestissuedcredential.rb +33 -0
- data/lib/no_response/models/shared/assessmentrequestissuedcredential.rbi +14 -0
- data/lib/no_response/models/shared/assessmentrequestpolicycontext.rb +46 -0
- data/lib/no_response/models/shared/assessmentrequestpolicycontext.rbi +20 -0
- data/lib/no_response/models/shared/assessmenttiming.rb +41 -0
- data/lib/no_response/models/shared/assessmenttiming.rbi +20 -0
- data/lib/no_response/models/shared/assurancelevel.rb +18 -0
- data/lib/no_response/models/shared/assurancelevel.rbi +9 -0
- data/lib/no_response/models/shared/authcontext.rb +285 -0
- data/lib/no_response/models/shared/authcontext.rbi +152 -0
- data/lib/no_response/models/shared/authcontextmfa.rb +55 -0
- data/lib/no_response/models/shared/authcontextmfa.rbi +26 -0
- data/lib/no_response/models/shared/authenticationerrorcode.rb +18 -0
- data/lib/no_response/models/shared/authenticationerrorcode.rbi +9 -0
- data/lib/no_response/models/shared/badrequesterrorcode.rb +20 -0
- data/lib/no_response/models/shared/badrequesterrorcode.rbi +9 -0
- data/lib/no_response/models/shared/band.rb +21 -0
- data/lib/no_response/models/shared/band.rbi +9 -0
- data/lib/no_response/models/shared/breach.rb +108 -0
- data/lib/no_response/models/shared/breach.rbi +56 -0
- data/lib/no_response/models/shared/breachexposed.rb +28 -0
- data/lib/no_response/models/shared/breachexposed.rbi +9 -0
- data/lib/no_response/models/shared/breachkind.rb +24 -0
- data/lib/no_response/models/shared/breachkind.rbi +9 -0
- data/lib/no_response/models/shared/breachselector.rb +20 -0
- data/lib/no_response/models/shared/breachselector.rbi +9 -0
- data/lib/no_response/models/shared/breachsummary.rb +109 -0
- data/lib/no_response/models/shared/breachsummary.rbi +56 -0
- data/lib/no_response/models/shared/confidence.rb +21 -0
- data/lib/no_response/models/shared/confidence.rbi +9 -0
- data/lib/no_response/models/shared/conflicterrorcode.rb +19 -0
- data/lib/no_response/models/shared/conflicterrorcode.rbi +9 -0
- data/lib/no_response/models/shared/consistency.rb +85 -0
- data/lib/no_response/models/shared/consistency.rbi +32 -0
- data/lib/no_response/models/shared/consistencyvalue.rb +21 -0
- data/lib/no_response/models/shared/consistencyvalue.rbi +9 -0
- data/lib/no_response/models/shared/country.rb +20 -0
- data/lib/no_response/models/shared/country.rbi +9 -0
- data/lib/no_response/models/shared/email.rb +23 -0
- data/lib/no_response/models/shared/email.rbi +9 -0
- data/lib/no_response/models/shared/email_union.rb +23 -0
- data/lib/no_response/models/shared/email_union.rbi +9 -0
- data/lib/no_response/models/shared/failurereason.rb +24 -0
- data/lib/no_response/models/shared/failurereason.rbi +9 -0
- data/lib/no_response/models/shared/flow.rb +18 -0
- data/lib/no_response/models/shared/flow.rbi +9 -0
- data/lib/no_response/models/shared/freshness.rb +20 -0
- data/lib/no_response/models/shared/freshness.rbi +9 -0
- data/lib/no_response/models/shared/hookpoint.rb +19 -0
- data/lib/no_response/models/shared/hookpoint.rbi +9 -0
- data/lib/no_response/models/shared/identifierkind.rb +21 -0
- data/lib/no_response/models/shared/identifierkind.rbi +9 -0
- data/lib/no_response/models/shared/incompletereason.rb +23 -0
- data/lib/no_response/models/shared/incompletereason.rbi +9 -0
- data/lib/no_response/models/shared/incompletesource.rb +53 -0
- data/lib/no_response/models/shared/incompletesource.rbi +20 -0
- data/lib/no_response/models/shared/ipsummary.rb +61 -0
- data/lib/no_response/models/shared/ipsummary.rbi +26 -0
- data/lib/no_response/models/shared/ipsummarytype.rb +24 -0
- data/lib/no_response/models/shared/ipsummarytype.rbi +9 -0
- data/lib/no_response/models/shared/keyrotation.rb +79 -0
- data/lib/no_response/models/shared/keyrotation.rbi +44 -0
- data/lib/no_response/models/shared/keyrotationrequest.rb +33 -0
- data/lib/no_response/models/shared/keyrotationrequest.rbi +14 -0
- data/lib/no_response/models/shared/lane.rb +21 -0
- data/lib/no_response/models/shared/lane.rbi +9 -0
- data/lib/no_response/models/shared/linetype.rb +22 -0
- data/lib/no_response/models/shared/linetype.rbi +9 -0
- data/lib/no_response/models/shared/location.rb +23 -0
- data/lib/no_response/models/shared/location.rbi +9 -0
- data/lib/no_response/models/shared/location_union.rb +23 -0
- data/lib/no_response/models/shared/location_union.rbi +9 -0
- data/lib/no_response/models/shared/name_candidate.rb +23 -0
- data/lib/no_response/models/shared/name_candidate.rbi +9 -0
- data/lib/no_response/models/shared/name_candidate_union.rb +23 -0
- data/lib/no_response/models/shared/name_candidate_union.rbi +9 -0
- data/lib/no_response/models/shared/notfounderrorcode.rb +18 -0
- data/lib/no_response/models/shared/notfounderrorcode.rbi +9 -0
- data/lib/no_response/models/shared/outcome.rb +23 -0
- data/lib/no_response/models/shared/outcome.rbi +9 -0
- data/lib/no_response/models/shared/permissiondeniederrorcode.rb +18 -0
- data/lib/no_response/models/shared/permissiondeniederrorcode.rbi +9 -0
- data/lib/no_response/models/shared/phoneenrichment.rb +32 -0
- data/lib/no_response/models/shared/phoneenrichment.rbi +14 -0
- data/lib/no_response/models/shared/phoneenrichmentfields.rb +451 -0
- data/lib/no_response/models/shared/phoneenrichmentfields.rbi +212 -0
- data/lib/no_response/models/shared/platform.rb +18 -0
- data/lib/no_response/models/shared/platform.rbi +9 -0
- data/lib/no_response/models/shared/probleminvalidparam.rb +48 -0
- data/lib/no_response/models/shared/probleminvalidparam.rbi +26 -0
- data/lib/no_response/models/shared/ratelimiterrorcode.rb +18 -0
- data/lib/no_response/models/shared/ratelimiterrorcode.rbi +9 -0
- data/lib/no_response/models/shared/reasoncode.rb +52 -0
- data/lib/no_response/models/shared/reasoncode.rbi +9 -0
- data/lib/no_response/models/shared/reasonidentifier.rb +23 -0
- data/lib/no_response/models/shared/reasonidentifier.rbi +9 -0
- data/lib/no_response/models/shared/recommendation.rb +20 -0
- data/lib/no_response/models/shared/recommendation.rbi +9 -0
- data/lib/no_response/models/shared/responsemode.rb +16 -0
- data/lib/no_response/models/shared/responsemode.rbi +9 -0
- data/lib/no_response/models/shared/risk.rb +171 -0
- data/lib/no_response/models/shared/risk.rbi +80 -0
- data/lib/no_response/models/shared/riskconfidence.rb +20 -0
- data/lib/no_response/models/shared/riskconfidence.rbi +9 -0
- data/lib/no_response/models/shared/riskcoverage.rb +49 -0
- data/lib/no_response/models/shared/riskcoverage.rbi +26 -0
- data/lib/no_response/models/shared/riskdetails.rb +55 -0
- data/lib/no_response/models/shared/riskdetails.rbi +26 -0
- data/lib/no_response/models/shared/riskdetailsbreachname.rb +40 -0
- data/lib/no_response/models/shared/riskdetailsbreachname.rbi +20 -0
- data/lib/no_response/models/shared/riskdetailsphonename.rb +40 -0
- data/lib/no_response/models/shared/riskdetailsphonename.rbi +20 -0
- data/lib/no_response/models/shared/riskreason.rb +67 -0
- data/lib/no_response/models/shared/riskreason.rbi +26 -0
- data/lib/no_response/models/shared/risksummary.rb +73 -0
- data/lib/no_response/models/shared/risksummary.rbi +38 -0
- data/lib/no_response/models/shared/risksummaryemail.rb +55 -0
- data/lib/no_response/models/shared/risksummaryemail.rbi +26 -0
- data/lib/no_response/models/shared/risksummaryphone.rb +69 -0
- data/lib/no_response/models/shared/risksummaryphone.rbi +32 -0
- data/lib/no_response/models/shared/risksummaryusername.rb +41 -0
- data/lib/no_response/models/shared/risksummaryusername.rbi +20 -0
- data/lib/no_response/models/shared/scope.rb +21 -0
- data/lib/no_response/models/shared/scope.rbi +9 -0
- data/lib/no_response/models/shared/security.rb +32 -0
- data/lib/no_response/models/shared/security.rbi +14 -0
- data/lib/no_response/models/shared/signal.rb +149 -0
- data/lib/no_response/models/shared/signal.rbi +68 -0
- data/lib/no_response/models/shared/signaloutcome.rb +22 -0
- data/lib/no_response/models/shared/signaloutcome.rbi +9 -0
- data/lib/no_response/models/shared/social_profile.rb +23 -0
- data/lib/no_response/models/shared/social_profile.rbi +9 -0
- data/lib/no_response/models/shared/social_profile_union.rb +23 -0
- data/lib/no_response/models/shared/social_profile_union.rbi +9 -0
- data/lib/no_response/models/shared/status.rb +20 -0
- data/lib/no_response/models/shared/status.rbi +9 -0
- data/lib/no_response/models/shared/timezone.rb +23 -0
- data/lib/no_response/models/shared/timezone.rbi +9 -0
- data/lib/no_response/models/shared/timezone_union.rb +23 -0
- data/lib/no_response/models/shared/timezone_union.rbi +9 -0
- data/lib/no_response/models/shared/transport.rb +17 -0
- data/lib/no_response/models/shared/transport.rbi +9 -0
- data/lib/no_response/models/shared/website.rb +23 -0
- data/lib/no_response/models/shared/website.rbi +9 -0
- data/lib/no_response/models/shared/website_union.rb +23 -0
- data/lib/no_response/models/shared/website_union.rbi +9 -0
- data/lib/no_response/models/shared.rb +92 -0
- data/lib/no_response/noresponseclient.rb +110 -0
- data/lib/no_response/sdk_hooks/hooks.rb +97 -0
- data/lib/no_response/sdk_hooks/idempotency_key_hook.rb +25 -0
- data/lib/no_response/sdk_hooks/registration.rb +43 -0
- data/lib/no_response/sdk_hooks/types.rb +178 -0
- data/lib/no_response/sdkconfiguration.rb +107 -0
- data/lib/no_response/sdkconfiguration.rbi +83 -0
- data/lib/no_response/utils/forms.rb +230 -0
- data/lib/no_response/utils/headers.rb +80 -0
- data/lib/no_response/utils/query_params.rb +165 -0
- data/lib/no_response/utils/request_bodies.rb +77 -0
- data/lib/no_response/utils/retries.rb +137 -0
- data/lib/no_response/utils/security.rb +156 -0
- data/lib/no_response/utils/url.rb +122 -0
- data/lib/no_response/utils/utils.rb +243 -0
- data/lib/no_response/wait.rb +66 -0
- data/lib/no_response/webhooks.rb +177 -0
- data/lib/noresponse.rb +25 -0
- metadata +501 -0
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
module NoResponse
|
|
5
|
+
module Models
|
|
6
|
+
module Shared
|
|
7
|
+
# POST /v1/assessments/query body. account_id travels in the body rather than the URL path so a provider value that turns out to hold personal data is not written to access logs, proxies or browser history. Read-only: no Idempotency-Key. An account with no unexpired assessments answers 200 with empty items.
|
|
8
|
+
class AssessmentQuery
|
|
9
|
+
extend T::Sig
|
|
10
|
+
include Crystalline::MetadataFields
|
|
11
|
+
|
|
12
|
+
# Your own opaque identifier for the account being checked, scoped to your tenant. Use an id you mint, with no direct identifier (email, phone, name or national id) in it. '|' is accepted so an Auth0 user id such as 'auth0|64abc' passes unchanged; '@', '+', '$' and whitespace are refused, as is a JWT; a hex digest such as a SHA-256 is allowed. It travels only in request bodies. An assessment requested by a provider hook at pre_registration, which has no account yet, carries the server-issued account_id pre: followed by its assessment_id.
|
|
13
|
+
field(
|
|
14
|
+
:account_id,
|
|
15
|
+
::String,
|
|
16
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("account_id"), required: true}}
|
|
17
|
+
)
|
|
18
|
+
# next_cursor from the previous page, unchanged. Opaque, MAC'd and bound to the tenant and account_id.
|
|
19
|
+
field(
|
|
20
|
+
:cursor,
|
|
21
|
+
Crystalline::Nilable.new(::String),
|
|
22
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("cursor")}}
|
|
23
|
+
)
|
|
24
|
+
# standard returns the consolidated risk response; detailed adds merged provider-neutral facts when the key has detailed scope. There is no raw mode.
|
|
25
|
+
field(
|
|
26
|
+
:response_mode,
|
|
27
|
+
Crystalline::Nilable.new(Models::Shared::ResponseMode),
|
|
28
|
+
{
|
|
29
|
+
'format_json': {
|
|
30
|
+
'letter_case': ::NoResponse::Utils.field_name("response_mode"),
|
|
31
|
+
'decoder': ::NoResponse::Utils.enum_from_string(Models::Shared::ResponseMode, true)
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
)
|
|
35
|
+
|
|
36
|
+
field(
|
|
37
|
+
:limit,
|
|
38
|
+
Crystalline::Nilable.new(::Integer),
|
|
39
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("limit")}}
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
sig {
|
|
43
|
+
params(
|
|
44
|
+
account_id: ::String,
|
|
45
|
+
cursor: T.nilable(::String),
|
|
46
|
+
response_mode: T.nilable(Models::Shared::ResponseMode),
|
|
47
|
+
limit: T.nilable(::Integer)
|
|
48
|
+
)
|
|
49
|
+
.void
|
|
50
|
+
}
|
|
51
|
+
def initialize(account_id:, cursor: nil, response_mode: nil, limit: 20)
|
|
52
|
+
@account_id = account_id
|
|
53
|
+
@cursor = cursor
|
|
54
|
+
@response_mode = response_mode
|
|
55
|
+
@limit = limit
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
sig { params(other: T.untyped).returns(T::Boolean) }
|
|
59
|
+
def ==(other)
|
|
60
|
+
return false unless other.is_a?(self.class)
|
|
61
|
+
return false unless @account_id == other.account_id
|
|
62
|
+
return false unless @cursor == other.cursor
|
|
63
|
+
return false unless @response_mode == other.response_mode
|
|
64
|
+
return false unless @limit == other.limit
|
|
65
|
+
true
|
|
66
|
+
end
|
|
67
|
+
end
|
|
68
|
+
end
|
|
69
|
+
end
|
|
70
|
+
end
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
class NoResponse::Models::Shared::AssessmentQuery
|
|
5
|
+
extend ::Crystalline::MetadataFields::ClassMethods
|
|
6
|
+
end
|
|
7
|
+
|
|
8
|
+
class NoResponse::Models::Shared::AssessmentQuery
|
|
9
|
+
def account_id
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
def account_id=(str_)
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
def cursor
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
def cursor=(str_)
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
def response_mode
|
|
22
|
+
end
|
|
23
|
+
|
|
24
|
+
def response_mode=(str_)
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
def limit
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
def limit=(str_)
|
|
31
|
+
end
|
|
32
|
+
end
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
module NoResponse
|
|
5
|
+
module Models
|
|
6
|
+
module Shared
|
|
7
|
+
# POST /v1/assessments body. At least one of email, username or phone is required; name and ip only refine an assessment. No field carries a password, hash, token or breach value, and unknown members are refused. The email local part is kept as received and only the domain is lower-cased; the username is compared case-insensitively; the phone is strict E.164 and is assessed asynchronously. The whole body is capped at 32768 bytes. client_context holds bounded hints from the signup client; auth_context holds normalised claims from a session your backend has verified. Raw tokens are refused.
|
|
8
|
+
class AssessmentRequest
|
|
9
|
+
extend T::Sig
|
|
10
|
+
include Crystalline::MetadataFields
|
|
11
|
+
|
|
12
|
+
# Your own opaque identifier for the account being checked, scoped to your tenant. Use an id you mint, with no direct identifier (email, phone, name or national id) in it. '|' is accepted so an Auth0 user id such as 'auth0|64abc' passes unchanged; '@', '+', '$' and whitespace are refused, as is a JWT; a hex digest such as a SHA-256 is allowed. It travels only in request bodies. An assessment requested by a provider hook at pre_registration, which has no account yet, carries the server-issued account_id pre: followed by its assessment_id.
|
|
13
|
+
field(
|
|
14
|
+
:account_id,
|
|
15
|
+
::String,
|
|
16
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("account_id"), required: true}}
|
|
17
|
+
)
|
|
18
|
+
# At least one of email, username or phone. name and ip refine the match and travel beside a lookup identifier; a body with only name or ip is refused with 400.
|
|
19
|
+
field(
|
|
20
|
+
:identifiers,
|
|
21
|
+
Models::Shared::AssessmentRequestIdentifiers,
|
|
22
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("identifiers"), required: true}}
|
|
23
|
+
)
|
|
24
|
+
|
|
25
|
+
field(
|
|
26
|
+
:policy_context,
|
|
27
|
+
Crystalline::Nilable.new(Models::Shared::AssessmentRequestPolicyContext),
|
|
28
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("policy_context")}}
|
|
29
|
+
)
|
|
30
|
+
# An optional provider correlation id, echoed back. It is not an idempotency key. Refuses an exact-shape JWT or a bare 40, 64 or 128 character hex digest; a UUID is accepted.
|
|
31
|
+
field(
|
|
32
|
+
:request_id,
|
|
33
|
+
Crystalline::Nilable.new(::String),
|
|
34
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("request_id")}}
|
|
35
|
+
)
|
|
36
|
+
# Optional tighter budget, 50 to 500 ms, measured from the moment the request reaches NoResponse. Absent means the 500 ms ceiling; a value above it is refused with 400 rather than clamped.
|
|
37
|
+
field(
|
|
38
|
+
:deadline_ms,
|
|
39
|
+
Crystalline::Nilable.new(::Integer),
|
|
40
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("deadline_ms")}}
|
|
41
|
+
)
|
|
42
|
+
# standard returns the consolidated risk response; detailed adds merged provider-neutral facts when the key has detailed scope. There is no raw mode.
|
|
43
|
+
field(
|
|
44
|
+
:response_mode,
|
|
45
|
+
Crystalline::Nilable.new(Models::Shared::ResponseMode),
|
|
46
|
+
{
|
|
47
|
+
'format_json': {
|
|
48
|
+
'letter_case': ::NoResponse::Utils.field_name("response_mode"),
|
|
49
|
+
'decoder': ::NoResponse::Utils.enum_from_string(Models::Shared::ResponseMode, true)
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
)
|
|
53
|
+
# Optional context observed by your signup client. The server parses these hints into coarse features, leaves raw user_agent and opaque ids out of every answer, and weighs a mismatch with the other evidence.
|
|
54
|
+
field(
|
|
55
|
+
:client_context,
|
|
56
|
+
Crystalline::Nilable.new(Models::Shared::AssessmentRequestClientContext),
|
|
57
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("client_context")}}
|
|
58
|
+
)
|
|
59
|
+
# Normalised claims from a session your backend has already verified with WorkOS, Clerk, Auth0 or any OIDC provider. Pass the output of the SDK's auth adapters, not a raw token.
|
|
60
|
+
field(
|
|
61
|
+
:auth_context,
|
|
62
|
+
Crystalline::Nilable.new(Models::Shared::AuthContext),
|
|
63
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("auth_context")}}
|
|
64
|
+
)
|
|
65
|
+
# Optional. When the signup gate issues an API key to the new account, send SHA-256 of that key, so later usage of the key, or a leaked copy, ties back to this assessment. Each SDK has a helper that computes it. Send only the hash: customer keys are high-entropy, so the hash reveals nothing about them. The assessment stores it, and no response, webhook or log carries it.
|
|
66
|
+
field(
|
|
67
|
+
:issued_credential,
|
|
68
|
+
Crystalline::Nilable.new(Models::Shared::AssessmentRequestIssuedCredential),
|
|
69
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("issued_credential")}}
|
|
70
|
+
)
|
|
71
|
+
|
|
72
|
+
sig {
|
|
73
|
+
params(
|
|
74
|
+
account_id: ::String,
|
|
75
|
+
identifiers: Models::Shared::AssessmentRequestIdentifiers,
|
|
76
|
+
policy_context: T.nilable(Models::Shared::AssessmentRequestPolicyContext),
|
|
77
|
+
request_id: T.nilable(::String),
|
|
78
|
+
deadline_ms: T.nilable(::Integer),
|
|
79
|
+
response_mode: T.nilable(Models::Shared::ResponseMode),
|
|
80
|
+
client_context: T.nilable(Models::Shared::AssessmentRequestClientContext),
|
|
81
|
+
auth_context: T.nilable(Models::Shared::AuthContext),
|
|
82
|
+
issued_credential: T.nilable(Models::Shared::AssessmentRequestIssuedCredential)
|
|
83
|
+
)
|
|
84
|
+
.void
|
|
85
|
+
}
|
|
86
|
+
def initialize(
|
|
87
|
+
account_id:,
|
|
88
|
+
identifiers:,
|
|
89
|
+
policy_context: nil,
|
|
90
|
+
request_id: nil,
|
|
91
|
+
deadline_ms: nil,
|
|
92
|
+
response_mode: nil,
|
|
93
|
+
client_context: nil,
|
|
94
|
+
auth_context: nil,
|
|
95
|
+
issued_credential: nil
|
|
96
|
+
)
|
|
97
|
+
@account_id = account_id
|
|
98
|
+
@identifiers = identifiers
|
|
99
|
+
@policy_context = policy_context
|
|
100
|
+
@request_id = request_id
|
|
101
|
+
@deadline_ms = deadline_ms
|
|
102
|
+
@response_mode = response_mode
|
|
103
|
+
@client_context = client_context
|
|
104
|
+
@auth_context = auth_context
|
|
105
|
+
@issued_credential = issued_credential
|
|
106
|
+
end
|
|
107
|
+
|
|
108
|
+
sig { params(other: T.untyped).returns(T::Boolean) }
|
|
109
|
+
def ==(other)
|
|
110
|
+
return false unless other.is_a?(self.class)
|
|
111
|
+
return false unless @account_id == other.account_id
|
|
112
|
+
return false unless @identifiers == other.identifiers
|
|
113
|
+
return false unless @policy_context == other.policy_context
|
|
114
|
+
return false unless @request_id == other.request_id
|
|
115
|
+
return false unless @deadline_ms == other.deadline_ms
|
|
116
|
+
return false unless @response_mode == other.response_mode
|
|
117
|
+
return false unless @client_context == other.client_context
|
|
118
|
+
return false unless @auth_context == other.auth_context
|
|
119
|
+
return false unless @issued_credential == other.issued_credential
|
|
120
|
+
true
|
|
121
|
+
end
|
|
122
|
+
end
|
|
123
|
+
end
|
|
124
|
+
end
|
|
125
|
+
end
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
class NoResponse::Models::Shared::AssessmentRequest
|
|
5
|
+
extend ::Crystalline::MetadataFields::ClassMethods
|
|
6
|
+
end
|
|
7
|
+
|
|
8
|
+
class NoResponse::Models::Shared::AssessmentRequest
|
|
9
|
+
def account_id
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
def account_id=(str_)
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
def identifiers
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
def identifiers=(str_)
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
def policy_context
|
|
22
|
+
end
|
|
23
|
+
|
|
24
|
+
def policy_context=(str_)
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
def request_id
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
def request_id=(str_)
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
def deadline_ms
|
|
34
|
+
end
|
|
35
|
+
|
|
36
|
+
def deadline_ms=(str_)
|
|
37
|
+
end
|
|
38
|
+
|
|
39
|
+
def response_mode
|
|
40
|
+
end
|
|
41
|
+
|
|
42
|
+
def response_mode=(str_)
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
def client_context
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
def client_context=(str_)
|
|
49
|
+
end
|
|
50
|
+
|
|
51
|
+
def auth_context
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
def auth_context=(str_)
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
def issued_credential
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
def issued_credential=(str_)
|
|
61
|
+
end
|
|
62
|
+
end
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
module NoResponse
|
|
5
|
+
module Models
|
|
6
|
+
module Shared
|
|
7
|
+
# Optional context observed by your signup client. The server parses these hints into coarse features, leaves raw user_agent and opaque ids out of every answer, and weighs a mismatch with the other evidence.
|
|
8
|
+
class AssessmentRequestClientContext
|
|
9
|
+
extend T::Sig
|
|
10
|
+
include Crystalline::MetadataFields
|
|
11
|
+
|
|
12
|
+
# IANA time-zone name such as Europe/London or America/Los_Angeles. Fixed numeric offsets are not accepted.
|
|
13
|
+
field(
|
|
14
|
+
:timezone,
|
|
15
|
+
Crystalline::Nilable.new(::String),
|
|
16
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("timezone")}}
|
|
17
|
+
)
|
|
18
|
+
# BCP 47 locale, for example en-AU. Treat as a presentation hint, not a nationality signal.
|
|
19
|
+
field(
|
|
20
|
+
:locale,
|
|
21
|
+
Crystalline::Nilable.new(::String),
|
|
22
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("locale")}}
|
|
23
|
+
)
|
|
24
|
+
# Client platform. Closed vocabulary keeps integrations stable.
|
|
25
|
+
field(
|
|
26
|
+
:platform,
|
|
27
|
+
Crystalline::Nilable.new(Models::Shared::Platform),
|
|
28
|
+
{
|
|
29
|
+
'format_json': {
|
|
30
|
+
'letter_case': ::NoResponse::Utils.field_name("platform"),
|
|
31
|
+
'decoder': ::NoResponse::Utils.enum_from_string(Models::Shared::Platform, true)
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
)
|
|
35
|
+
# Customer application version, without build metadata that contains secrets.
|
|
36
|
+
field(
|
|
37
|
+
:app_version,
|
|
38
|
+
Crystalline::Nilable.new(::String),
|
|
39
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("app_version")}}
|
|
40
|
+
)
|
|
41
|
+
# The raw User-Agent header of the signup request, at most 512 characters. It is parsed into coarse features and left out of every answer.
|
|
42
|
+
field(
|
|
43
|
+
:user_agent,
|
|
44
|
+
Crystalline::Nilable.new(::String),
|
|
45
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("user_agent")}}
|
|
46
|
+
)
|
|
47
|
+
# Tenant-scoped opaque identifier your application mints and rotates when the account or device changes. Send an id of your own, not a hardware fingerprint.
|
|
48
|
+
field(
|
|
49
|
+
:device_id,
|
|
50
|
+
Crystalline::Nilable.new(::String),
|
|
51
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("device_id")}}
|
|
52
|
+
)
|
|
53
|
+
# Opaque signup session identifier. It is used for tenant-scoped velocity and replay checks only.
|
|
54
|
+
field(
|
|
55
|
+
:session_id,
|
|
56
|
+
Crystalline::Nilable.new(::String),
|
|
57
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("session_id")}}
|
|
58
|
+
)
|
|
59
|
+
# Elapsed time from form start to submit. Values below three seconds are a weak automation hint, weighed with the other evidence.
|
|
60
|
+
field(
|
|
61
|
+
:form_duration_ms,
|
|
62
|
+
Crystalline::Nilable.new(::Integer),
|
|
63
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("form_duration_ms")}}
|
|
64
|
+
)
|
|
65
|
+
# RFC 3339 timestamp observed by the client. Server ingress time remains authoritative; a large clock skew is only a low-confidence feature.
|
|
66
|
+
field(
|
|
67
|
+
:client_observed_at,
|
|
68
|
+
Crystalline::Nilable.new(::String),
|
|
69
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("client_observed_at")}}
|
|
70
|
+
)
|
|
71
|
+
|
|
72
|
+
sig {
|
|
73
|
+
params(
|
|
74
|
+
timezone: T.nilable(::String),
|
|
75
|
+
locale: T.nilable(::String),
|
|
76
|
+
platform: T.nilable(Models::Shared::Platform),
|
|
77
|
+
app_version: T.nilable(::String),
|
|
78
|
+
user_agent: T.nilable(::String),
|
|
79
|
+
device_id: T.nilable(::String),
|
|
80
|
+
session_id: T.nilable(::String),
|
|
81
|
+
form_duration_ms: T.nilable(::Integer),
|
|
82
|
+
client_observed_at: T.nilable(::String)
|
|
83
|
+
)
|
|
84
|
+
.void
|
|
85
|
+
}
|
|
86
|
+
def initialize(
|
|
87
|
+
timezone: nil,
|
|
88
|
+
locale: nil,
|
|
89
|
+
platform: nil,
|
|
90
|
+
app_version: nil,
|
|
91
|
+
user_agent: nil,
|
|
92
|
+
device_id: nil,
|
|
93
|
+
session_id: nil,
|
|
94
|
+
form_duration_ms: nil,
|
|
95
|
+
client_observed_at: nil
|
|
96
|
+
)
|
|
97
|
+
@timezone = timezone
|
|
98
|
+
@locale = locale
|
|
99
|
+
@platform = platform
|
|
100
|
+
@app_version = app_version
|
|
101
|
+
@user_agent = user_agent
|
|
102
|
+
@device_id = device_id
|
|
103
|
+
@session_id = session_id
|
|
104
|
+
@form_duration_ms = form_duration_ms
|
|
105
|
+
@client_observed_at = client_observed_at
|
|
106
|
+
end
|
|
107
|
+
|
|
108
|
+
sig { params(other: T.untyped).returns(T::Boolean) }
|
|
109
|
+
def ==(other)
|
|
110
|
+
return false unless other.is_a?(self.class)
|
|
111
|
+
return false unless @timezone == other.timezone
|
|
112
|
+
return false unless @locale == other.locale
|
|
113
|
+
return false unless @platform == other.platform
|
|
114
|
+
return false unless @app_version == other.app_version
|
|
115
|
+
return false unless @user_agent == other.user_agent
|
|
116
|
+
return false unless @device_id == other.device_id
|
|
117
|
+
return false unless @session_id == other.session_id
|
|
118
|
+
return false unless @form_duration_ms == other.form_duration_ms
|
|
119
|
+
return false unless @client_observed_at == other.client_observed_at
|
|
120
|
+
true
|
|
121
|
+
end
|
|
122
|
+
end
|
|
123
|
+
end
|
|
124
|
+
end
|
|
125
|
+
end
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
class NoResponse::Models::Shared::AssessmentRequestClientContext
|
|
5
|
+
extend ::Crystalline::MetadataFields::ClassMethods
|
|
6
|
+
end
|
|
7
|
+
|
|
8
|
+
class NoResponse::Models::Shared::AssessmentRequestClientContext
|
|
9
|
+
def timezone
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
def timezone=(str_)
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
def locale
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
def locale=(str_)
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
def platform
|
|
22
|
+
end
|
|
23
|
+
|
|
24
|
+
def platform=(str_)
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
def app_version
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
def app_version=(str_)
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
def user_agent
|
|
34
|
+
end
|
|
35
|
+
|
|
36
|
+
def user_agent=(str_)
|
|
37
|
+
end
|
|
38
|
+
|
|
39
|
+
def device_id
|
|
40
|
+
end
|
|
41
|
+
|
|
42
|
+
def device_id=(str_)
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
def session_id
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
def session_id=(str_)
|
|
49
|
+
end
|
|
50
|
+
|
|
51
|
+
def form_duration_ms
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
def form_duration_ms=(str_)
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
def client_observed_at
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
def client_observed_at=(str_)
|
|
61
|
+
end
|
|
62
|
+
end
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
module NoResponse
|
|
5
|
+
module Models
|
|
6
|
+
module Shared
|
|
7
|
+
# At least one of email, username or phone. name and ip refine the match and travel beside a lookup identifier; a body with only name or ip is refused with 400.
|
|
8
|
+
class AssessmentRequestIdentifiers
|
|
9
|
+
extend T::Sig
|
|
10
|
+
include Crystalline::MetadataFields
|
|
11
|
+
|
|
12
|
+
# One address: a 1 to 64 character local part without whitespace, angle brackets, control or invisible characters, '@', and a domain with a letter TLD. Send an internationalised domain in punycode. Nothing is trimmed. The local part keeps its case and the domain is lower-cased; no alias rewriting ('+tag', dots or provider heuristics) is applied.
|
|
13
|
+
field(
|
|
14
|
+
:email,
|
|
15
|
+
Crystalline::Nilable.new(::String),
|
|
16
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("email")}}
|
|
17
|
+
)
|
|
18
|
+
# The handle the account is signing up with: 1 to 64 characters, no whitespace, control or invisible characters, and not a credential hash or token. Echoed as received; compared case-insensitively.
|
|
19
|
+
field(
|
|
20
|
+
:username,
|
|
21
|
+
Crystalline::Nilable.new(::String),
|
|
22
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("username")}}
|
|
23
|
+
)
|
|
24
|
+
# Strict E.164: '+', then 8 to 15 digits, the first not 0, with no separators. Phone evidence is gathered asynchronously, so a phone-only request answers 202 pending and the phone is listed in incomplete_sources on the synchronous answer.
|
|
25
|
+
field(
|
|
26
|
+
:phone,
|
|
27
|
+
Crystalline::Nilable.new(::String),
|
|
28
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("phone")}}
|
|
29
|
+
)
|
|
30
|
+
# The full name as the user typed it, 1 to 128 characters with no control or invisible characters. It is used only to match names in the evidence.
|
|
31
|
+
field(
|
|
32
|
+
:name,
|
|
33
|
+
Crystalline::Nilable.new(::String),
|
|
34
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("name")}}
|
|
35
|
+
)
|
|
36
|
+
# The signup's client IP address: an IPv4 dotted quad without leading zeros, or an IPv6 address in its RFC 5952 text form (lower case, no leading zeros, the longest zero run compressed). Send an IPv4 client as a dotted quad, not IPv4-mapped. No zone, port or prefix. The server refuses a non-canonical IPv6 spelling, and every private, loopback, link-local, multicast, documentation or otherwise reserved address (the IANA special-purpose registries), with 400: only a public address says anything about a signup.
|
|
37
|
+
field(
|
|
38
|
+
:ip,
|
|
39
|
+
Crystalline::Nilable.new(::String),
|
|
40
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("ip")}}
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
sig {
|
|
44
|
+
params(
|
|
45
|
+
email: T.nilable(::String),
|
|
46
|
+
username: T.nilable(::String),
|
|
47
|
+
phone: T.nilable(::String),
|
|
48
|
+
name: T.nilable(::String),
|
|
49
|
+
ip: T.nilable(::String)
|
|
50
|
+
)
|
|
51
|
+
.void
|
|
52
|
+
}
|
|
53
|
+
def initialize(email: nil, username: nil, phone: nil, name: nil, ip: nil)
|
|
54
|
+
@email = email
|
|
55
|
+
@username = username
|
|
56
|
+
@phone = phone
|
|
57
|
+
@name = name
|
|
58
|
+
@ip = ip
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
sig { params(other: T.untyped).returns(T::Boolean) }
|
|
62
|
+
def ==(other)
|
|
63
|
+
return false unless other.is_a?(self.class)
|
|
64
|
+
return false unless @email == other.email
|
|
65
|
+
return false unless @username == other.username
|
|
66
|
+
return false unless @phone == other.phone
|
|
67
|
+
return false unless @name == other.name
|
|
68
|
+
return false unless @ip == other.ip
|
|
69
|
+
true
|
|
70
|
+
end
|
|
71
|
+
end
|
|
72
|
+
end
|
|
73
|
+
end
|
|
74
|
+
end
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
class NoResponse::Models::Shared::AssessmentRequestIdentifiers
|
|
5
|
+
extend ::Crystalline::MetadataFields::ClassMethods
|
|
6
|
+
end
|
|
7
|
+
|
|
8
|
+
class NoResponse::Models::Shared::AssessmentRequestIdentifiers
|
|
9
|
+
def email
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
def email=(str_)
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
def username
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
def username=(str_)
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
def phone
|
|
22
|
+
end
|
|
23
|
+
|
|
24
|
+
def phone=(str_)
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
def name
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
def name=(str_)
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
def ip
|
|
34
|
+
end
|
|
35
|
+
|
|
36
|
+
def ip=(str_)
|
|
37
|
+
end
|
|
38
|
+
end
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
module NoResponse
|
|
5
|
+
module Models
|
|
6
|
+
module Shared
|
|
7
|
+
# Optional. When the signup gate issues an API key to the new account, send SHA-256 of that key, so later usage of the key, or a leaked copy, ties back to this assessment. Each SDK has a helper that computes it. Send only the hash: customer keys are high-entropy, so the hash reveals nothing about them. The assessment stores it, and no response, webhook or log carries it.
|
|
8
|
+
class AssessmentRequestIssuedCredential
|
|
9
|
+
extend T::Sig
|
|
10
|
+
include Crystalline::MetadataFields
|
|
11
|
+
|
|
12
|
+
# SHA-256 of the issued key's UTF-8 bytes, as 64 lower-case hex characters.
|
|
13
|
+
field(
|
|
14
|
+
:sha256,
|
|
15
|
+
::String,
|
|
16
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("sha256"), required: true}}
|
|
17
|
+
)
|
|
18
|
+
|
|
19
|
+
sig { params(sha256: ::String).void }
|
|
20
|
+
def initialize(sha256:)
|
|
21
|
+
@sha256 = sha256
|
|
22
|
+
end
|
|
23
|
+
|
|
24
|
+
sig { params(other: T.untyped).returns(T::Boolean) }
|
|
25
|
+
def ==(other)
|
|
26
|
+
return false unless other.is_a?(self.class)
|
|
27
|
+
return false unless @sha256 == other.sha256
|
|
28
|
+
true
|
|
29
|
+
end
|
|
30
|
+
end
|
|
31
|
+
end
|
|
32
|
+
end
|
|
33
|
+
end
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
class NoResponse::Models::Shared::AssessmentRequestIssuedCredential
|
|
5
|
+
extend ::Crystalline::MetadataFields::ClassMethods
|
|
6
|
+
end
|
|
7
|
+
|
|
8
|
+
class NoResponse::Models::Shared::AssessmentRequestIssuedCredential
|
|
9
|
+
def sha256
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
def sha256=(str_)
|
|
13
|
+
end
|
|
14
|
+
end
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
# frozen_string_literal: true
|
|
3
|
+
|
|
4
|
+
module NoResponse
|
|
5
|
+
module Models
|
|
6
|
+
module Shared
|
|
7
|
+
|
|
8
|
+
class AssessmentRequestPolicyContext
|
|
9
|
+
extend T::Sig
|
|
10
|
+
include Crystalline::MetadataFields
|
|
11
|
+
|
|
12
|
+
# The provider flow the assessment gates. Absent means signup.
|
|
13
|
+
field(
|
|
14
|
+
:flow,
|
|
15
|
+
Crystalline::Nilable.new(Models::Shared::Flow),
|
|
16
|
+
{
|
|
17
|
+
'format_json': {
|
|
18
|
+
'letter_case': ::NoResponse::Utils.field_name("flow"),
|
|
19
|
+
'decoder': ::NoResponse::Utils.enum_from_string(Models::Shared::Flow, true)
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
)
|
|
23
|
+
# ISO 3166-1 alpha-2 region of the signup, as the provider determines it.
|
|
24
|
+
field(
|
|
25
|
+
:region,
|
|
26
|
+
Crystalline::Nilable.new(::String),
|
|
27
|
+
{'format_json': {'letter_case': ::NoResponse::Utils.field_name("region")}}
|
|
28
|
+
)
|
|
29
|
+
|
|
30
|
+
sig { params(flow: T.nilable(Models::Shared::Flow), region: T.nilable(::String)).void }
|
|
31
|
+
def initialize(flow: nil, region: nil)
|
|
32
|
+
@flow = flow
|
|
33
|
+
@region = region
|
|
34
|
+
end
|
|
35
|
+
|
|
36
|
+
sig { params(other: T.untyped).returns(T::Boolean) }
|
|
37
|
+
def ==(other)
|
|
38
|
+
return false unless other.is_a?(self.class)
|
|
39
|
+
return false unless @flow == other.flow
|
|
40
|
+
return false unless @region == other.region
|
|
41
|
+
true
|
|
42
|
+
end
|
|
43
|
+
end
|
|
44
|
+
end
|
|
45
|
+
end
|
|
46
|
+
end
|