noresponse 9.4.0 → 9.4.2

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.
Files changed (26) hide show
  1. checksums.yaml +4 -4
  2. data/lib/no_response/accounts.rb +293 -0
  3. data/lib/no_response/models/operations/searchaccounts_response.rb +32 -0
  4. data/lib/no_response/models/operations/searchaccounts_response.rbi +20 -0
  5. data/lib/no_response/models/operations.rb +1 -0
  6. data/lib/no_response/models/shared/accountdirectorypage.rb +77 -0
  7. data/lib/no_response/models/shared/accountdirectorypage.rbi +38 -0
  8. data/lib/no_response/models/shared/accountdirectorypageitem.rb +65 -0
  9. data/lib/no_response/models/shared/accountdirectorypageitem.rbi +32 -0
  10. data/lib/no_response/models/shared/accountdirectorysearchrequest.rb +65 -0
  11. data/lib/no_response/models/shared/accountdirectorysearchrequest.rbi +32 -0
  12. data/lib/no_response/models/shared/assessment.rb +1 -1
  13. data/lib/no_response/models/shared/assessmentaggregaterequest.rb +1 -1
  14. data/lib/no_response/models/shared/assessmentdetail.rb +2 -2
  15. data/lib/no_response/models/shared/assessmentrevision.rb +1 -1
  16. data/lib/no_response/models/shared/assessmentsearchitem.rb +1 -1
  17. data/lib/no_response/models/shared/assessmentsearchrequest.rb +1 -1
  18. data/lib/no_response/models/shared/confidence.rb +1 -1
  19. data/lib/no_response/models/shared/decisionreceipt.rb +1 -1
  20. data/lib/no_response/models/shared/reasoncode.rb +1 -0
  21. data/lib/no_response/models/shared/risk.rb +1 -1
  22. data/lib/no_response/models/shared/riskcoverage.rb +4 -4
  23. data/lib/no_response/models/shared/status.rb +1 -1
  24. data/lib/no_response/models/shared.rb +3 -0
  25. data/lib/no_response/sdkconfiguration.rb +2 -2
  26. metadata +9 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2a7a4007667832081cb401d07ff168481e8b0cdc4d9a04f5f0073e0b90091055
4
- data.tar.gz: 395f33f137064474997f8ac4e317f8cc28eeb7985ba59cf4f9a131d6f5bb69d2
3
+ metadata.gz: 4841d5bf61440a9ed5297a66f4e7d7fb820bed09831a82e47f82e64667b392ed
4
+ data.tar.gz: 5066f04bd959fbc943c8db239e9f514d961a66a62c2482df743c37b1b00b5024
5
5
  SHA512:
6
- metadata.gz: ff44abdfd0eb5e23ec94da15450a264b51ce6cb11a1bd0be5e66fa295fd43594a1d0e3daf2e270cd2bb55970f90bba44a4996d25acdef6b15fde303327412c90
7
- data.tar.gz: 450e4088b4029c7f3d33a2be2c3d6e9e184bd540673f4d1d3f740ac59834b0ac77fa4c01a0dbec407b20518456c72bfcc07a1a1da8e3e1dd58c7caee25f00a5f
6
+ metadata.gz: a8c8a8067ffce9661db26303506a401a66c4ac29aa3762e22fd1cb2b2c19b9668e584efc4213616369b211c19cc36a3c42a211a6e00c171115234db3c0692b82
7
+ data.tar.gz: e18056623cc7625e67347c7fe43b15751fa16d4e978f5acfa9a3e2718672b045771b28fada6c5cbf16dcc66eee7446de480927f17f75a049ccf19f99b2acd52a
@@ -4266,5 +4266,298 @@ module NoResponse
4266
4266
 
4267
4267
  end
4268
4268
  end
4269
+
4270
+ sig {
4271
+ params(
4272
+ request: Models::Shared::AccountDirectorySearchRequest,
4273
+ retries: T.nilable(Utils::RetryConfig),
4274
+ timeout_ms: T.nilable(Integer),
4275
+ http_headers: T.nilable(T::Hash[T.any(String, Symbol), String])
4276
+ )
4277
+ .returns(Models::Operations::SearchAccountsResponse)
4278
+ }
4279
+ def search(request:, retries: nil, timeout_ms: nil, http_headers: nil)
4280
+ # search - Search distinct accounts by email or account ID
4281
+ # Search distinct accounts observed in retained assessments in this environment. Match an exact account_id or canonical email; an email matches any retained assessment belonging to the account. The response contains one row per account with its newest retained assessment, current decision when available, per-account assessment count, and total distinct-account count. Send next_cursor with unchanged filters to continue. Totals are exact below 10000 and capped at 10000. Results are live across pages. Requires history access and identifier access for email. Read-only and safe to retry.
4282
+ url, params = @sdk_configuration.get_server_details
4283
+ base_url = Utils.template_url(url, params)
4284
+ url = "#{base_url}/v1/accounts/search"
4285
+ headers = {}
4286
+ headers = T.cast(headers, T::Hash[String, String])
4287
+ req_content_type, data, form = Utils.serialize_request_body(request, false, false, :request, :json)
4288
+ headers["content-type"] = req_content_type
4289
+ raise StandardError, "request body is required" if data.nil? && form.nil?
4290
+
4291
+ if form && !form.empty?
4292
+ body = Utils.encode_form(form)
4293
+ elsif Utils.match_content_type(req_content_type, "application/x-www-form-urlencoded")
4294
+ body = URI.encode_www_form(T.cast(data, T::Hash[Symbol, Object]))
4295
+ else
4296
+ body = data
4297
+ end
4298
+
4299
+ headers["Accept"] = "application/json"
4300
+ headers["user-agent"] = @sdk_configuration.user_agent
4301
+ retries ||= @sdk_configuration.retry_config
4302
+ retries ||= Utils::RetryConfig.new(
4303
+ backoff: Utils::BackoffStrategy.new(
4304
+ exponent: 2.0,
4305
+ initial_interval: 500,
4306
+ max_elapsed_time: 30_000,
4307
+ max_interval: 8000
4308
+ ),
4309
+ retry_connection_errors: true,
4310
+ strategy: "backoff"
4311
+ )
4312
+ retry_options = retries.to_faraday_retry_options(initial_time: Time.now)
4313
+ retry_options[:retry_statuses] = [408, 429, 500, 501, 502, 503, 504, 505]
4314
+
4315
+ security = @sdk_configuration.security_source&.call
4316
+
4317
+ timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
4318
+ timeout ||= @sdk_configuration.timeout
4319
+
4320
+ connection = @sdk_configuration.client.dup
4321
+ connection.use(Utils::RetryMiddleware, retry_options)
4322
+
4323
+ hook_ctx = SDKHooks::HookContext.new(
4324
+ config: @sdk_configuration,
4325
+ base_url: base_url,
4326
+ oauth2_scopes: nil,
4327
+ operation_id: "searchAccounts",
4328
+ security_source: @sdk_configuration.security_source
4329
+ )
4330
+
4331
+ error = T.let(nil, T.nilable(StandardError))
4332
+ http_response = T.let(nil, T.nilable(Faraday::Response))
4333
+
4334
+ begin
4335
+ http_response = T.must(connection).post(url) do |req|
4336
+ req.body = body
4337
+ req.headers.merge!(headers)
4338
+ req.options.timeout = timeout unless timeout.nil?
4339
+ Utils.configure_request_security(req, security)
4340
+ http_headers&.each do |key, value|
4341
+ req.headers[key.to_s] = value
4342
+ end
4343
+
4344
+ @sdk_configuration.hooks.before_request(
4345
+ hook_ctx: SDKHooks::BeforeRequestHookContext.new(
4346
+ hook_ctx: hook_ctx
4347
+ ),
4348
+ request: req
4349
+ )
4350
+ end
4351
+
4352
+ rescue StandardError => e
4353
+ error = e
4354
+ ensure
4355
+ if http_response.nil? || Utils.error_status?(http_response.status)
4356
+ http_response = @sdk_configuration.hooks.after_error(
4357
+ error: error,
4358
+ hook_ctx: SDKHooks::AfterErrorHookContext.new(
4359
+ hook_ctx: hook_ctx
4360
+ ),
4361
+ response: http_response
4362
+ )
4363
+ else
4364
+ http_response = @sdk_configuration.hooks.after_success(
4365
+ hook_ctx: SDKHooks::AfterSuccessHookContext.new(
4366
+ hook_ctx: hook_ctx
4367
+ ),
4368
+ response: http_response
4369
+ )
4370
+ end
4371
+
4372
+ if http_response.nil?
4373
+ raise error if !error.nil?
4374
+ raise "no response"
4375
+ end
4376
+ end
4377
+
4378
+ content_type = http_response.headers.fetch("Content-Type", "application/octet-stream")
4379
+ if Utils.match_status_code(http_response.status, ["200"])
4380
+ if Utils.match_content_type(content_type, "application/json")
4381
+ @sdk_configuration.hooks.after_success(
4382
+ hook_ctx: SDKHooks::AfterSuccessHookContext.new(
4383
+ hook_ctx: hook_ctx
4384
+ ),
4385
+ response: http_response
4386
+ )
4387
+ response_data = http_response.env.response_body
4388
+ obj = Crystalline.unmarshal_json(JSON.parse(response_data), Models::Shared::AccountDirectoryPage)
4389
+ result = obj
4390
+ response = Models::Operations::SearchAccountsResponse.new(
4391
+ result: result,
4392
+ headers: http_response.headers
4393
+ )
4394
+
4395
+ return response
4396
+ else
4397
+ raise(
4398
+ ::NoResponse::Models::Errors::APIStatusError.new(
4399
+ status_code: http_response.status,
4400
+ body: http_response.env.response_body,
4401
+ raw_response: http_response
4402
+ ),
4403
+ "Unknown content type received"
4404
+ )
4405
+ end
4406
+ elsif Utils.match_status_code(http_response.status, ["400"])
4407
+ if Utils.match_content_type(content_type, "application/problem+json")
4408
+ @sdk_configuration.hooks.after_success(
4409
+ hook_ctx: SDKHooks::AfterSuccessHookContext.new(
4410
+ hook_ctx: hook_ctx
4411
+ ),
4412
+ response: http_response
4413
+ )
4414
+ response_data = http_response.env.response_body
4415
+ obj = Crystalline.unmarshal_json(JSON.parse(response_data), Models::Errors::BadRequestError)
4416
+ raise obj
4417
+ else
4418
+ raise(
4419
+ ::NoResponse::Models::Errors::APIStatusError.new(
4420
+ status_code: http_response.status,
4421
+ body: http_response.env.response_body,
4422
+ raw_response: http_response
4423
+ ),
4424
+ "Unknown content type received"
4425
+ )
4426
+ end
4427
+ elsif Utils.match_status_code(http_response.status, ["401"])
4428
+ if Utils.match_content_type(content_type, "application/problem+json")
4429
+ @sdk_configuration.hooks.after_success(
4430
+ hook_ctx: SDKHooks::AfterSuccessHookContext.new(
4431
+ hook_ctx: hook_ctx
4432
+ ),
4433
+ response: http_response
4434
+ )
4435
+ response_data = http_response.env.response_body
4436
+ obj = Crystalline.unmarshal_json(JSON.parse(response_data), Models::Errors::AuthenticationError)
4437
+ raise obj
4438
+ else
4439
+ raise(
4440
+ ::NoResponse::Models::Errors::APIStatusError.new(
4441
+ status_code: http_response.status,
4442
+ body: http_response.env.response_body,
4443
+ raw_response: http_response
4444
+ ),
4445
+ "Unknown content type received"
4446
+ )
4447
+ end
4448
+ elsif Utils.match_status_code(http_response.status, ["403"])
4449
+ if Utils.match_content_type(content_type, "application/problem+json")
4450
+ @sdk_configuration.hooks.after_success(
4451
+ hook_ctx: SDKHooks::AfterSuccessHookContext.new(
4452
+ hook_ctx: hook_ctx
4453
+ ),
4454
+ response: http_response
4455
+ )
4456
+ response_data = http_response.env.response_body
4457
+ obj = Crystalline.unmarshal_json(JSON.parse(response_data), Models::Errors::PermissionDeniedError)
4458
+ raise obj
4459
+ else
4460
+ raise(
4461
+ ::NoResponse::Models::Errors::APIStatusError.new(
4462
+ status_code: http_response.status,
4463
+ body: http_response.env.response_body,
4464
+ raw_response: http_response
4465
+ ),
4466
+ "Unknown content type received"
4467
+ )
4468
+ end
4469
+ elsif Utils.match_status_code(http_response.status, ["404"])
4470
+ if Utils.match_content_type(content_type, "application/problem+json")
4471
+ @sdk_configuration.hooks.after_success(
4472
+ hook_ctx: SDKHooks::AfterSuccessHookContext.new(
4473
+ hook_ctx: hook_ctx
4474
+ ),
4475
+ response: http_response
4476
+ )
4477
+ response_data = http_response.env.response_body
4478
+ obj = Crystalline.unmarshal_json(JSON.parse(response_data), Models::Errors::NotFoundError)
4479
+ raise obj
4480
+ else
4481
+ raise(
4482
+ ::NoResponse::Models::Errors::APIStatusError.new(
4483
+ status_code: http_response.status,
4484
+ body: http_response.env.response_body,
4485
+ raw_response: http_response
4486
+ ),
4487
+ "Unknown content type received"
4488
+ )
4489
+ end
4490
+ elsif Utils.match_status_code(http_response.status, ["409"])
4491
+ if Utils.match_content_type(content_type, "application/problem+json")
4492
+ @sdk_configuration.hooks.after_success(
4493
+ hook_ctx: SDKHooks::AfterSuccessHookContext.new(
4494
+ hook_ctx: hook_ctx
4495
+ ),
4496
+ response: http_response
4497
+ )
4498
+ response_data = http_response.env.response_body
4499
+ obj = Crystalline.unmarshal_json(JSON.parse(response_data), Models::Errors::ConflictError)
4500
+ raise obj
4501
+ else
4502
+ raise(
4503
+ ::NoResponse::Models::Errors::APIStatusError.new(
4504
+ status_code: http_response.status,
4505
+ body: http_response.env.response_body,
4506
+ raw_response: http_response
4507
+ ),
4508
+ "Unknown content type received"
4509
+ )
4510
+ end
4511
+ elsif Utils.match_status_code(http_response.status, ["429"])
4512
+ if Utils.match_content_type(content_type, "application/problem+json")
4513
+ @sdk_configuration.hooks.after_success(
4514
+ hook_ctx: SDKHooks::AfterSuccessHookContext.new(
4515
+ hook_ctx: hook_ctx
4516
+ ),
4517
+ response: http_response
4518
+ )
4519
+ response_data = http_response.env.response_body
4520
+ obj = Crystalline.unmarshal_json(JSON.parse(response_data), Models::Errors::RateLimitError)
4521
+ raise obj
4522
+ else
4523
+ raise(
4524
+ ::NoResponse::Models::Errors::APIStatusError.new(
4525
+ status_code: http_response.status,
4526
+ body: http_response.env.response_body,
4527
+ raw_response: http_response
4528
+ ),
4529
+ "Unknown content type received"
4530
+ )
4531
+ end
4532
+ elsif Utils.match_status_code(http_response.status, ["4XX"])
4533
+ raise(
4534
+ ::NoResponse::Models::Errors::APIStatusError.new(
4535
+ status_code: http_response.status,
4536
+ body: http_response.env.response_body,
4537
+ raw_response: http_response
4538
+ ),
4539
+ "API error occurred"
4540
+ )
4541
+ elsif Utils.match_status_code(http_response.status, ["5XX"])
4542
+ raise(
4543
+ ::NoResponse::Models::Errors::APIStatusError.new(
4544
+ status_code: http_response.status,
4545
+ body: http_response.env.response_body,
4546
+ raw_response: http_response
4547
+ ),
4548
+ "API error occurred"
4549
+ )
4550
+ else
4551
+ raise(
4552
+ ::NoResponse::Models::Errors::APIStatusError.new(
4553
+ status_code: http_response.status,
4554
+ body: http_response.env.response_body,
4555
+ raw_response: http_response
4556
+ ),
4557
+ "Unknown status code received"
4558
+ )
4559
+
4560
+ end
4561
+ end
4269
4562
  end
4270
4563
  end
@@ -0,0 +1,32 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ module NoResponse
5
+ module Models
6
+ module Operations
7
+
8
+ class SearchAccountsResponse
9
+ extend T::Sig
10
+ include Crystalline::MetadataFields
11
+
12
+ field :headers, Crystalline::Hash.new(Symbol, Crystalline::Array.new(::String))
13
+
14
+ field :result, Models::Shared::AccountDirectoryPage, {}
15
+
16
+ sig { params(headers: T::Hash[Symbol, T::Array[::String]], result: Models::Shared::AccountDirectoryPage).void }
17
+ def initialize(headers:, result:)
18
+ @headers = headers
19
+ @result = result
20
+ end
21
+
22
+ sig { params(other: T.untyped).returns(T::Boolean) }
23
+ def ==(other)
24
+ return false unless other.is_a?(self.class)
25
+ return false unless @headers == other.headers
26
+ return false unless @result == other.result
27
+ true
28
+ end
29
+ end
30
+ end
31
+ end
32
+ end
@@ -0,0 +1,20 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class NoResponse::Models::Operations::SearchAccountsResponse
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class NoResponse::Models::Operations::SearchAccountsResponse
9
+ def headers
10
+ end
11
+
12
+ def headers=(str_)
13
+ end
14
+
15
+ def result
16
+ end
17
+
18
+ def result=(str_)
19
+ end
20
+ end
@@ -182,6 +182,7 @@ module NoResponse
182
182
  autoload :RotateIntegrationSecretResponse, "no_response/models/operations/rotateintegrationsecret_response.rb"
183
183
  autoload :RotateWebhookSigningKeyRequest, "no_response/models/operations/rotatewebhooksigningkey_request.rb"
184
184
  autoload :RotateWebhookSigningKeyResponse, "no_response/models/operations/rotatewebhooksigningkey_response.rb"
185
+ autoload :SearchAccountsResponse, "no_response/models/operations/searchaccounts_response.rb"
185
186
  autoload :SearchAssessmentsResponse, "no_response/models/operations/searchassessments_response.rb"
186
187
  autoload :SendWebhookTestEventRequest, "no_response/models/operations/sendwebhooktestevent_request.rb"
187
188
  autoload :SendWebhookTestEventResponse, "no_response/models/operations/sendwebhooktestevent_response.rb"
@@ -0,0 +1,77 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ module NoResponse
5
+ module Models
6
+ module Shared
7
+ # Accounts observed in retained assessments, newest seen first, with each account once per page and across pages. Counts and keyset pagination are computed over distinct accounts in one database snapshot per page. Live data can change between pages.
8
+ class AccountDirectoryPage
9
+ extend T::Sig
10
+ include Crystalline::MetadataFields
11
+
12
+ field(
13
+ :items,
14
+ Crystalline::Array.new(Models::Shared::AccountDirectoryPageItem),
15
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("items"), required: true}}
16
+ )
17
+ # Distinct accounts matching the filters, exact below 10000 and capped at 10000.
18
+ field(
19
+ :total,
20
+ ::Integer,
21
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("total"), required: true}}
22
+ )
23
+ # True when at least 10000 accounts match.
24
+ field(
25
+ :total_capped,
26
+ Crystalline::Boolean.new,
27
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("total_capped"), required: true}}
28
+ )
29
+ # Version of the body shape.
30
+ field(
31
+ :schema_version,
32
+ ::String,
33
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("schema_version"), required: true}}
34
+ )
35
+ # Opaque, expiring cursor bound to this environment, operation and every filter. Keep the filters unchanged.
36
+ field(
37
+ :next_cursor,
38
+ Crystalline::Nilable.new(::String),
39
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("next_cursor")}}
40
+ )
41
+
42
+ sig {
43
+ params(
44
+ items: T::Array[Models::Shared::AccountDirectoryPageItem],
45
+ total: ::Integer,
46
+ total_capped: T::Boolean,
47
+ schema_version: ::String,
48
+ next_cursor: T.nilable(::String)
49
+ )
50
+ .void
51
+ }
52
+ def initialize(items:, total:, total_capped:, schema_version: "1", next_cursor: nil)
53
+ @items = items
54
+ @total = total
55
+ @total_capped = total_capped
56
+ unless schema_version == "1"
57
+ raise ArgumentError, "Invalid value for schema_version"
58
+ end
59
+
60
+ @schema_version = "1"
61
+ @next_cursor = next_cursor
62
+ end
63
+
64
+ sig { params(other: T.untyped).returns(T::Boolean) }
65
+ def ==(other)
66
+ return false unless other.is_a?(self.class)
67
+ return false unless @items == other.items
68
+ return false unless @total == other.total
69
+ return false unless @total_capped == other.total_capped
70
+ return false unless @schema_version == other.schema_version
71
+ return false unless @next_cursor == other.next_cursor
72
+ true
73
+ end
74
+ end
75
+ end
76
+ end
77
+ end
@@ -0,0 +1,38 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class NoResponse::Models::Shared::AccountDirectoryPage
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class NoResponse::Models::Shared::AccountDirectoryPage
9
+ def items
10
+ end
11
+
12
+ def items=(str_)
13
+ end
14
+
15
+ def total
16
+ end
17
+
18
+ def total=(str_)
19
+ end
20
+
21
+ def total_capped
22
+ end
23
+
24
+ def total_capped=(str_)
25
+ end
26
+
27
+ def schema_version
28
+ end
29
+
30
+ def schema_version=(str_)
31
+ end
32
+
33
+ def next_cursor
34
+ end
35
+
36
+ def next_cursor=(str_)
37
+ end
38
+ end
@@ -0,0 +1,65 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ module NoResponse
5
+ module Models
6
+ module Shared
7
+
8
+ class AccountDirectoryPageItem
9
+ extend T::Sig
10
+ include Crystalline::MetadataFields
11
+
12
+ # Your own opaque identifier for the account being checked, scoped to your workspace. 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 by the pattern, as is an exact-shape JWT; a hex digest such as a SHA-256 is allowed, because hashing an internal id is a common pseudonymous scheme. A value such as '07700900123' or 'jane.doe.gmail.com' cannot be told apart from an opaque id. It travels in bodies, and in a URL only as the path segment of GET /v1/accounts/{account_id} and its /assessments. 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
+ # Retrieve a retained assessment version with its original decision, policy, flow and depth. This response excludes the current account decision. Current retention and response-mode permissions still apply.
19
+ field(
20
+ :latest,
21
+ Models::Shared::AssessmentRevision,
22
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("latest"), required: true}}
23
+ )
24
+ # Count of admitted retained assessments belonging to this account, not just the returned page.
25
+ field(
26
+ :assessments,
27
+ ::Integer,
28
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("assessments"), required: true}}
29
+ )
30
+ # Body of the 200 answer to GET /v1/accounts/{account_id}: the one current risk of one of the calling workspace's accounts. It is the risk of the account's latest assessment that has a decision (status complete or partial), by created_at and then assessment_id, scored exactly as GET /v1/assessments/{assessment_id} scores that assessment, plus the account's own reason shared_api_key when a key issued to the account was used from many IP addresses or countries (POST /v1/key_usage/batches). Its assessments are the account's history (GET /v1/accounts/{account_id}/assessments).
31
+ field(
32
+ :current,
33
+ Crystalline::Nilable.new(Models::Shared::Account),
34
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("current")}}
35
+ )
36
+
37
+ sig {
38
+ params(
39
+ account_id: ::String,
40
+ latest: Models::Shared::AssessmentRevision,
41
+ assessments: ::Integer,
42
+ current: T.nilable(Models::Shared::Account)
43
+ )
44
+ .void
45
+ }
46
+ def initialize(account_id:, latest:, assessments:, current: nil)
47
+ @account_id = account_id
48
+ @latest = latest
49
+ @assessments = assessments
50
+ @current = current
51
+ end
52
+
53
+ sig { params(other: T.untyped).returns(T::Boolean) }
54
+ def ==(other)
55
+ return false unless other.is_a?(self.class)
56
+ return false unless @account_id == other.account_id
57
+ return false unless @latest == other.latest
58
+ return false unless @assessments == other.assessments
59
+ return false unless @current == other.current
60
+ true
61
+ end
62
+ end
63
+ end
64
+ end
65
+ end
@@ -0,0 +1,32 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class NoResponse::Models::Shared::AccountDirectoryPageItem
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class NoResponse::Models::Shared::AccountDirectoryPageItem
9
+ def account_id
10
+ end
11
+
12
+ def account_id=(str_)
13
+ end
14
+
15
+ def latest
16
+ end
17
+
18
+ def latest=(str_)
19
+ end
20
+
21
+ def assessments
22
+ end
23
+
24
+ def assessments=(str_)
25
+ end
26
+
27
+ def current
28
+ end
29
+
30
+ def current=(str_)
31
+ end
32
+ end
@@ -0,0 +1,65 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ module NoResponse
5
+ module Models
6
+ module Shared
7
+ # Bounded distinct-account search for a single authenticated workspace/environment. Email matches any retained admitted assessment of an account, using assessment search's canonical mailbox rules. No assessment history download is required.
8
+ class AccountDirectorySearchRequest
9
+ extend T::Sig
10
+ include Crystalline::MetadataFields
11
+
12
+ # Your own opaque identifier for the account being checked, scoped to your workspace. 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 by the pattern, as is an exact-shape JWT; a hex digest such as a SHA-256 is allowed, because hashing an internal id is a common pseudonymous scheme. A value such as '07700900123' or 'jane.doe.gmail.com' cannot be told apart from an opaque id. It travels in bodies, and in a URL only as the path segment of GET /v1/accounts/{account_id} and its /assessments. 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
+ Crystalline::Nilable.new(::String),
16
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("account_id")}}
17
+ )
18
+ # Assessments of every account that one of its retained admitted assessments sent this mailbox as identifiers.email, matched as lists match an email entry: case-insensitive, a +tag removed and, at gmail.com and googlemail.com, the dots of the local part ignored. Only assessments stored since email list matching began carry the mailbox. An address that is not a valid mailbox is refused with 400.
19
+ field(
20
+ :email,
21
+ Crystalline::Nilable.new(::String),
22
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("email")}}
23
+ )
24
+ # Opaque, expiring cursor bound to this environment, operation and every filter. Keep the filters unchanged.
25
+ field(
26
+ :cursor,
27
+ Crystalline::Nilable.new(::String),
28
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("cursor")}}
29
+ )
30
+
31
+ field(
32
+ :limit,
33
+ Crystalline::Nilable.new(::Integer),
34
+ {'format_json': {'letter_case': ::NoResponse::Utils.field_name("limit")}}
35
+ )
36
+
37
+ sig {
38
+ params(
39
+ account_id: T.nilable(::String),
40
+ email: T.nilable(::String),
41
+ cursor: T.nilable(::String),
42
+ limit: T.nilable(::Integer)
43
+ )
44
+ .void
45
+ }
46
+ def initialize(account_id: nil, email: nil, cursor: nil, limit: 25)
47
+ @account_id = account_id
48
+ @email = email
49
+ @cursor = cursor
50
+ @limit = limit
51
+ end
52
+
53
+ sig { params(other: T.untyped).returns(T::Boolean) }
54
+ def ==(other)
55
+ return false unless other.is_a?(self.class)
56
+ return false unless @account_id == other.account_id
57
+ return false unless @email == other.email
58
+ return false unless @cursor == other.cursor
59
+ return false unless @limit == other.limit
60
+ true
61
+ end
62
+ end
63
+ end
64
+ end
65
+ end
@@ -0,0 +1,32 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class NoResponse::Models::Shared::AccountDirectorySearchRequest
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class NoResponse::Models::Shared::AccountDirectorySearchRequest
9
+ def account_id
10
+ end
11
+
12
+ def account_id=(str_)
13
+ end
14
+
15
+ def email
16
+ end
17
+
18
+ def email=(str_)
19
+ end
20
+
21
+ def cursor
22
+ end
23
+
24
+ def cursor=(str_)
25
+ end
26
+
27
+ def limit
28
+ end
29
+
30
+ def limit=(str_)
31
+ end
32
+ end
@@ -11,7 +11,7 @@ module NoResponse
11
11
 
12
12
  # This assessment's id, equal to detail.assessment_id.
13
13
  field :id, ::String, {'format_json': {'letter_case': ::NoResponse::Utils.field_name("id"), required: true}}
14
- # complete: final; nothing is still running. A lane that failed or missed its 10 s deadline stays listed in incomplete_sources, and confidence is lower. partial: a recommendation exists and at least one lane is still running or did not settle (see incomplete_sources). pending: nothing usable before the deadline; no recommendation yet, poll or wait for the webhook.
14
+ # Processing state, separate from evidence coverage. complete: final; nothing is still running, but unsupported, failed or unanswered lanes remain in incomplete_sources. partial: a recommendation exists and evidence is incomplete; assessment_url identifies continuing work when present. pending: no recommendation yet; poll or wait for the webhook. Finished processing does not mean all sources answered.
15
15
  field(
16
16
  :status,
17
17
  Models::Shared::Status,
@@ -48,7 +48,7 @@ module NoResponse
48
48
  }
49
49
  }
50
50
  )
51
- # complete: final; nothing is still running. A lane that failed or missed its 10 s deadline stays listed in incomplete_sources, and confidence is lower. partial: a recommendation exists and at least one lane is still running or did not settle (see incomplete_sources). pending: nothing usable before the deadline; no recommendation yet, poll or wait for the webhook.
51
+ # Processing state, separate from evidence coverage. complete: final; nothing is still running, but unsupported, failed or unanswered lanes remain in incomplete_sources. partial: a recommendation exists and evidence is incomplete; assessment_url identifies continuing work when present. pending: no recommendation yet; poll or wait for the webhook. Finished processing does not mean all sources answered.
52
52
  field(
53
53
  :status,
54
54
  Crystalline::Nilable.new(Models::Shared::Status),
@@ -21,7 +21,7 @@ module NoResponse
21
21
  ::String,
22
22
  {'format_json': {'letter_case': ::NoResponse::Utils.field_name("account_id"), required: true}}
23
23
  )
24
- # complete: final; nothing is still running. A lane that failed or missed its 10 s deadline stays listed in incomplete_sources, and confidence is lower. partial: a recommendation exists and at least one lane is still running or did not settle (see incomplete_sources). pending: nothing usable before the deadline; no recommendation yet, poll or wait for the webhook.
24
+ # Processing state, separate from evidence coverage. complete: final; nothing is still running, but unsupported, failed or unanswered lanes remain in incomplete_sources. partial: a recommendation exists and evidence is incomplete; assessment_url identifies continuing work when present. pending: no recommendation yet; poll or wait for the webhook. Finished processing does not mean all sources answered.
25
25
  field(
26
26
  :status,
27
27
  Models::Shared::Status,
@@ -33,7 +33,7 @@ module NoResponse
33
33
  }
34
34
  }
35
35
  )
36
- # Ordinal confidence in the recommendation under the current policy: low, medium, high or unavailable.
36
+ # Evidence coverage: how much of the planned source evidence gave a definite answer. This is not confidence that an identity is genuine, agreement between identifiers, a risk score or a probability. unavailable means no usable evidence answered; a terminal uncovered assessment can have this value and recommend review.
37
37
  field(
38
38
  :confidence,
39
39
  Models::Shared::Confidence,
@@ -11,7 +11,7 @@ module NoResponse
11
11
 
12
12
  # This assessment's id, equal to detail.assessment_id.
13
13
  field :id, ::String, {'format_json': {'letter_case': ::NoResponse::Utils.field_name("id"), required: true}}
14
- # complete: final; nothing is still running. A lane that failed or missed its 10 s deadline stays listed in incomplete_sources, and confidence is lower. partial: a recommendation exists and at least one lane is still running or did not settle (see incomplete_sources). pending: nothing usable before the deadline; no recommendation yet, poll or wait for the webhook.
14
+ # Processing state, separate from evidence coverage. complete: final; nothing is still running, but unsupported, failed or unanswered lanes remain in incomplete_sources. partial: a recommendation exists and evidence is incomplete; assessment_url identifies continuing work when present. pending: no recommendation yet; poll or wait for the webhook. Finished processing does not mean all sources answered.
15
15
  field(
16
16
  :status,
17
17
  Models::Shared::Status,
@@ -11,7 +11,7 @@ module NoResponse
11
11
 
12
12
  # This assessment's id, equal to detail.assessment_id.
13
13
  field :id, ::String, {'format_json': {'letter_case': ::NoResponse::Utils.field_name("id"), required: true}}
14
- # complete: final; nothing is still running. A lane that failed or missed its 10 s deadline stays listed in incomplete_sources, and confidence is lower. partial: a recommendation exists and at least one lane is still running or did not settle (see incomplete_sources). pending: nothing usable before the deadline; no recommendation yet, poll or wait for the webhook.
14
+ # Processing state, separate from evidence coverage. complete: final; nothing is still running, but unsupported, failed or unanswered lanes remain in incomplete_sources. partial: a recommendation exists and evidence is incomplete; assessment_url identifies continuing work when present. pending: no recommendation yet; poll or wait for the webhook. Finished processing does not mean all sources answered.
15
15
  field(
16
16
  :status,
17
17
  Models::Shared::Status,
@@ -35,7 +35,7 @@ module NoResponse
35
35
  }
36
36
  }
37
37
  )
38
- # complete: final; nothing is still running. A lane that failed or missed its 10 s deadline stays listed in incomplete_sources, and confidence is lower. partial: a recommendation exists and at least one lane is still running or did not settle (see incomplete_sources). pending: nothing usable before the deadline; no recommendation yet, poll or wait for the webhook.
38
+ # Processing state, separate from evidence coverage. complete: final; nothing is still running, but unsupported, failed or unanswered lanes remain in incomplete_sources. partial: a recommendation exists and evidence is incomplete; assessment_url identifies continuing work when present. pending: no recommendation yet; poll or wait for the webhook. Finished processing does not mean all sources answered.
39
39
  field(
40
40
  :status,
41
41
  Crystalline::Nilable.new(Models::Shared::Status),
@@ -4,7 +4,7 @@
4
4
  module NoResponse
5
5
  module Models
6
6
  module Shared
7
- # Confidence - Ordinal confidence in the recommendation under the current policy: low, medium, high or unavailable.
7
+ # Confidence - Evidence coverage: how much of the planned source evidence gave a definite answer. This is not confidence that an identity is genuine, agreement between identifiers, a risk score or a probability. unavailable means no usable evidence answered; a terminal uncovered assessment can have this value and recommend review.
8
8
  class Confidence
9
9
  include ::Crystalline::Enum
10
10
  enums do
@@ -33,7 +33,7 @@ module NoResponse
33
33
  }
34
34
  }
35
35
  )
36
- # complete: final; nothing is still running. A lane that failed or missed its 10 s deadline stays listed in incomplete_sources, and confidence is lower. partial: a recommendation exists and at least one lane is still running or did not settle (see incomplete_sources). pending: nothing usable before the deadline; no recommendation yet, poll or wait for the webhook.
36
+ # Processing state, separate from evidence coverage. complete: final; nothing is still running, but unsupported, failed or unanswered lanes remain in incomplete_sources. partial: a recommendation exists and evidence is incomplete; assessment_url identifies continuing work when present. pending: no recommendation yet; poll or wait for the webhook. Finished processing does not mean all sources answered.
37
37
  field(
38
38
  :status,
39
39
  Models::Shared::Status,
@@ -12,6 +12,7 @@ module NoResponse
12
12
  VOIP_NUMBER = new("voip_number")
13
13
  DISPOSABLE_EMAIL = new("disposable_email")
14
14
  NEW_EMAIL = new("new_email")
15
+ NO_EMAIL_MATCHES = new("no_email_matches")
15
16
  SPAM_REPORTS = new("spam_reports")
16
17
  FRAUD_FLAG = new("fraud_flag")
17
18
  IDENTITY_MISMATCH = new("identity_mismatch")
@@ -62,7 +62,7 @@ module NoResponse
62
62
  Crystalline::Array.new(Models::Shared::RiskReason),
63
63
  {'format_json': {'letter_case': ::NoResponse::Utils.field_name("reasons"), required: true}}
64
64
  )
65
- # Sources counted by state, not named.
65
+ # Counts of planned source-identifier pairs by evidence outcome, deduplicated across signals and incomplete entries. These counts do not measure identity agreement or prove that processing is still running. A lane that was not searched is not an answered source.
66
66
  field(
67
67
  :coverage,
68
68
  Models::Shared::RiskCoverage,
@@ -4,24 +4,24 @@
4
4
  module NoResponse
5
5
  module Models
6
6
  module Shared
7
- # Sources counted by state, not named.
7
+ # Counts of planned source-identifier pairs by evidence outcome, deduplicated across signals and incomplete entries. These counts do not measure identity agreement or prove that processing is still running. A lane that was not searched is not an answered source.
8
8
  class RiskCoverage
9
9
  extend T::Sig
10
10
  include Crystalline::MetadataFields
11
11
 
12
- # Sources that gave a definite answer.
12
+ # Source-identifier pairs that gave a definite found or not_found answer.
13
13
  field(
14
14
  :answered,
15
15
  ::Integer,
16
16
  {'format_json': {'letter_case': ::NoResponse::Utils.field_name("answered"), required: true}}
17
17
  )
18
- # Sources that could not answer.
18
+ # Source-identifier pairs that could not answer, including unsupported coverage markers and source failures. Read detailed signals to distinguish Not covered from Failed.
19
19
  field(
20
20
  :failed,
21
21
  ::Integer,
22
22
  {'format_json': {'letter_case': ::NoResponse::Utils.field_name("failed"), required: true}}
23
23
  )
24
- # Sources still being asked.
24
+ # Source-identifier pairs with deferred or timed_out evidence. A terminal timeout can remain here after processing finishes; use assessment status and continuation metadata to determine whether work is still running.
25
25
  field(
26
26
  :pending,
27
27
  ::Integer,
@@ -4,7 +4,7 @@
4
4
  module NoResponse
5
5
  module Models
6
6
  module Shared
7
- # Status - complete: final; nothing is still running. A lane that failed or missed its 10 s deadline stays listed in incomplete_sources, and confidence is lower. partial: a recommendation exists and at least one lane is still running or did not settle (see incomplete_sources). pending: nothing usable before the deadline; no recommendation yet, poll or wait for the webhook.
7
+ # Status - Processing state, separate from evidence coverage. complete: final; nothing is still running, but unsupported, failed or unanswered lanes remain in incomplete_sources. partial: a recommendation exists and evidence is incomplete; assessment_url identifies continuing work when present. pending: no recommendation yet; poll or wait for the webhook. Finished processing does not mean all sources answered.
8
8
  class Status
9
9
  include ::Crystalline::Enum
10
10
  enums do
@@ -15,6 +15,9 @@ module NoResponse
15
15
  autoload :AccountDeleted, "no_response/models/shared/accountdeleted.rb"
16
16
  autoload :AccountDeletedEvent, "no_response/models/shared/accountdeletedevent.rb"
17
17
  autoload :AccountDeletion, "no_response/models/shared/accountdeletion.rb"
18
+ autoload :AccountDirectoryPage, "no_response/models/shared/accountdirectorypage.rb"
19
+ autoload :AccountDirectoryPageItem, "no_response/models/shared/accountdirectorypageitem.rb"
20
+ autoload :AccountDirectorySearchRequest, "no_response/models/shared/accountdirectorysearchrequest.rb"
18
21
  autoload :AccountEnforcementList, "no_response/models/shared/accountenforcementlist.rb"
19
22
  autoload :AccountExport, "no_response/models/shared/accountexport.rb"
20
23
  autoload :AccountList, "no_response/models/shared/accountlist.rb"
@@ -95,9 +95,9 @@ module NoResponse
95
95
 
96
96
  @language = "ruby"
97
97
  @openapi_doc_version = "1"
98
- @sdk_version = "9.4.0"
98
+ @sdk_version = "9.4.2"
99
99
  @gen_version = "internal"
100
- @user_agent = "noresponse-sdk/ruby 9.4.0 internal 1 noresponse"
100
+ @user_agent = "noresponse-sdk/ruby 9.4.2 internal 1 noresponse"
101
101
  end
102
102
 
103
103
  sig { returns([String, T::Hash[Symbol, String]]) }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: noresponse
3
3
  version: !ruby/object:Gem::Version
4
- version: 9.4.0
4
+ version: 9.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - NoResponse
@@ -628,6 +628,8 @@ files:
628
628
  - lib/no_response/models/operations/rotatewebhooksigningkey_request.rbi
629
629
  - lib/no_response/models/operations/rotatewebhooksigningkey_response.rb
630
630
  - lib/no_response/models/operations/rotatewebhooksigningkey_response.rbi
631
+ - lib/no_response/models/operations/searchaccounts_response.rb
632
+ - lib/no_response/models/operations/searchaccounts_response.rbi
631
633
  - lib/no_response/models/operations/searchassessments_response.rb
632
634
  - lib/no_response/models/operations/searchassessments_response.rbi
633
635
  - lib/no_response/models/operations/sendwebhooktestevent_request.rb
@@ -681,6 +683,12 @@ files:
681
683
  - lib/no_response/models/shared/accountdeletedevent.rbi
682
684
  - lib/no_response/models/shared/accountdeletion.rb
683
685
  - lib/no_response/models/shared/accountdeletion.rbi
686
+ - lib/no_response/models/shared/accountdirectorypage.rb
687
+ - lib/no_response/models/shared/accountdirectorypage.rbi
688
+ - lib/no_response/models/shared/accountdirectorypageitem.rb
689
+ - lib/no_response/models/shared/accountdirectorypageitem.rbi
690
+ - lib/no_response/models/shared/accountdirectorysearchrequest.rb
691
+ - lib/no_response/models/shared/accountdirectorysearchrequest.rbi
684
692
  - lib/no_response/models/shared/accountenforcementlist.rb
685
693
  - lib/no_response/models/shared/accountenforcementlist.rbi
686
694
  - lib/no_response/models/shared/accountexport.rb