@wayai/cli 0.3.372 → 0.3.373
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.
- package/dist/index.js +1486 -1225
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -6266,6 +6266,23 @@ var init_chunk_63UWXV4T = __esm({
|
|
|
6266
6266
|
}
|
|
6267
6267
|
});
|
|
6268
6268
|
|
|
6269
|
+
// ../../packages/core/dist/chunk-WDAXZDJO.js
|
|
6270
|
+
var TOOLSET_ANSWER_PERSON_PARTIES, toolsetAnswerPersonSchema, toolsetAnswerPersonsSchema;
|
|
6271
|
+
var init_chunk_WDAXZDJO = __esm({
|
|
6272
|
+
"../../packages/core/dist/chunk-WDAXZDJO.js"() {
|
|
6273
|
+
"use strict";
|
|
6274
|
+
init_chunk_SSPK6ISL();
|
|
6275
|
+
init_chunk_AHISKXHA();
|
|
6276
|
+
init_zod();
|
|
6277
|
+
TOOLSET_ANSWER_PERSON_PARTIES = ["requester", "originator", "initiator", "delegator"];
|
|
6278
|
+
toolsetAnswerPersonSchema = external_exports.object({
|
|
6279
|
+
party: external_exports.enum(TOOLSET_ANSWER_PERSON_PARTIES),
|
|
6280
|
+
person_id: rekorPersonIdSchema
|
|
6281
|
+
}).strict();
|
|
6282
|
+
toolsetAnswerPersonsSchema = external_exports.array(toolsetAnswerPersonSchema).min(1).max(REKOR_MAX_PERSON_PARTIES);
|
|
6283
|
+
}
|
|
6284
|
+
});
|
|
6285
|
+
|
|
6269
6286
|
// ../../packages/core/dist/chunk-ZC6YGHNX.js
|
|
6270
6287
|
var updateUserBody, updateProfileBody, pathnameRegex, updatePreferencesBody, registerPushTokenBody, deletePushTokenQuery, recordAiDisclosureAcceptanceBody, activityQuery, deletionModeSchema, deletionRequestBody;
|
|
6271
6288
|
var init_chunk_ZC6YGHNX = __esm({
|
|
@@ -6349,750 +6366,55 @@ var init_chunk_HIGKBEPF = __esm({
|
|
|
6349
6366
|
}
|
|
6350
6367
|
});
|
|
6351
6368
|
|
|
6352
|
-
// ../../packages/core/dist/chunk-
|
|
6353
|
-
var
|
|
6354
|
-
var
|
|
6355
|
-
"../../packages/core/dist/chunk-
|
|
6356
|
-
"use strict";
|
|
6357
|
-
init_chunk_HZ6CADSY();
|
|
6358
|
-
init_zod();
|
|
6359
|
-
reportSourceSchema = external_exports.enum(["sentry", "cli", "review", "security_audit"]);
|
|
6360
|
-
intakeReportSourceSchema = external_exports.enum(["cli", "review", "security_audit"]);
|
|
6361
|
-
reportClassificationSchema = external_exports.enum(["bug", "flaky_test", "security", "enhancement"]);
|
|
6362
|
-
reportStatusSchema = external_exports.enum([
|
|
6363
|
-
"pending",
|
|
6364
|
-
"grouped",
|
|
6365
|
-
"escalated",
|
|
6366
|
-
"shipped",
|
|
6367
|
-
"contested",
|
|
6368
|
-
"addressed",
|
|
6369
|
-
"dismissed"
|
|
6370
|
-
]);
|
|
6371
|
-
reportLocaleSchema = external_exports.enum(["en", "pt", "es"]);
|
|
6372
|
-
reportMessageAuthorRoleSchema = external_exports.enum(["reporter", "triage", "fixer", "system"]);
|
|
6373
|
-
reportMessageSchema = external_exports.object({
|
|
6374
|
-
message_id: external_exports.string(),
|
|
6375
|
-
author_role: reportMessageAuthorRoleSchema,
|
|
6376
|
-
/** The status transition this note accompanied (e.g. 'shipped'); null for a free/system note. */
|
|
6377
|
-
transition: external_exports.string().nullable(),
|
|
6378
|
-
body: external_exports.string(),
|
|
6379
|
-
created_at: timestampSchema,
|
|
6380
|
-
/**
|
|
6381
|
-
* Visibility: `false` = reporter-facing (the default for every narrative entry); `true` =
|
|
6382
|
-
* triage-internal (e.g. a `hold` rationale) — surfaced to platform admins only and NEVER
|
|
6383
|
-
* returned on the reporter read path. The reporter's `GET /api/reports/:id` filters these out.
|
|
6384
|
-
*/
|
|
6385
|
-
internal: external_exports.boolean()
|
|
6386
|
-
});
|
|
6387
|
-
sentryRefStatusSchema = external_exports.enum(["valid", "not_found", "mismatch", "unverified"]);
|
|
6388
|
-
createReportBody = external_exports.object({
|
|
6389
|
-
title: external_exports.string().min(5).max(256),
|
|
6390
|
-
description: external_exports.string().min(10).max(5e3),
|
|
6391
|
-
steps_to_reproduce: external_exports.string().max(3e3).optional(),
|
|
6392
|
-
error_message: external_exports.string().max(2e3).optional(),
|
|
6393
|
-
// Taxonomy (server defaults: source=cli, classification=bug when absent).
|
|
6394
|
-
source: intakeReportSourceSchema.optional(),
|
|
6395
|
-
classification: reportClassificationSchema.optional(),
|
|
6396
|
-
// Stable dedup key (e.g. "<file>::<test>" for flaky, "<file>:<line>" for
|
|
6397
|
-
// security). When present, the fingerprint uses it instead of the body hash.
|
|
6398
|
-
dedup_key: external_exports.string().min(1).max(256).optional(),
|
|
6399
|
-
// Context fields (auto-captured by the CLI)
|
|
6400
|
-
organization_id: external_exports.string().optional(),
|
|
6401
|
-
hub_id: external_exports.string().uuid().optional(),
|
|
6402
|
-
hub_name: external_exports.string().max(256).optional(),
|
|
6403
|
-
conversation_id: external_exports.string().uuid().optional(),
|
|
6404
|
-
agent_id: external_exports.string().uuid().optional(),
|
|
6405
|
-
agent_name: external_exports.string().max(256).optional(),
|
|
6406
|
-
client_version: external_exports.string().max(64).optional(),
|
|
6407
|
-
additional_context: external_exports.string().max(2e3).optional()
|
|
6408
|
-
});
|
|
6409
|
-
editReportBody = external_exports.object({
|
|
6410
|
-
title: external_exports.string().min(5).max(256).optional(),
|
|
6411
|
-
description: external_exports.string().min(10).max(5e3).optional(),
|
|
6412
|
-
steps_to_reproduce: external_exports.string().max(3e3).optional(),
|
|
6413
|
-
error_message: external_exports.string().max(2e3).optional(),
|
|
6414
|
-
additional_context: external_exports.string().max(2e3).optional()
|
|
6415
|
-
}).strict().refine((b) => Object.keys(b).length > 0, {
|
|
6416
|
-
message: "at least one field must be provided"
|
|
6417
|
-
});
|
|
6418
|
-
reporterReportSummarySchema = external_exports.object({
|
|
6419
|
-
report_id: external_exports.string(),
|
|
6420
|
-
title: external_exports.string(),
|
|
6421
|
-
description: external_exports.string(),
|
|
6422
|
-
classification: reportClassificationSchema,
|
|
6423
|
-
status: reportStatusSchema,
|
|
6424
|
-
created_at: timestampSchema,
|
|
6425
|
-
triaged_at: timestampSchema.nullable(),
|
|
6426
|
-
resolved_at: timestampSchema.nullable(),
|
|
6427
|
-
/** How many times the reporter has contested (gates the hard cap). */
|
|
6428
|
-
contest_count: external_exports.number(),
|
|
6429
|
-
/** True once triage issued a non-contestable (final) dismissal. */
|
|
6430
|
-
dismissal_final: external_exports.boolean()
|
|
6431
|
-
});
|
|
6432
|
-
reporterListResponseSchema = external_exports.object({
|
|
6433
|
-
data: external_exports.array(reporterReportSummarySchema)
|
|
6434
|
-
});
|
|
6435
|
-
getReportResponseSchema = external_exports.object({
|
|
6436
|
-
report: reporterReportSummarySchema,
|
|
6437
|
-
messages: external_exports.array(reportMessageSchema)
|
|
6438
|
-
});
|
|
6439
|
-
reporterTransitionResponseSchema = external_exports.object({
|
|
6440
|
-
report: reporterReportSummarySchema
|
|
6441
|
-
});
|
|
6442
|
-
contestReportBody = external_exports.object({
|
|
6443
|
-
reason: external_exports.string().min(1).max(5e3)
|
|
6444
|
-
});
|
|
6445
|
-
reporterListQuery = external_exports.object({
|
|
6446
|
-
status: reportStatusSchema.optional()
|
|
6447
|
-
});
|
|
6448
|
-
listReportsQuery = external_exports.object({
|
|
6449
|
-
status: reportStatusSchema.optional(),
|
|
6450
|
-
source: reportSourceSchema.optional(),
|
|
6451
|
-
limit: external_exports.coerce.number().int().min(1).max(200).optional(),
|
|
6452
|
-
offset: external_exports.coerce.number().int().min(0).optional(),
|
|
6453
|
-
/** ISO 8601 lower bound on created_at. */
|
|
6454
|
-
since: external_exports.string().datetime().optional(),
|
|
6455
|
-
/**
|
|
6456
|
-
* ISO 8601 lower bound on resolution time — "what did we resolve recently", which `since`
|
|
6457
|
-
* (a created_at filter) cannot answer for a long-lived report resolved yesterday. Implies
|
|
6458
|
-
* a terminal status (`addressed`/`dismissed`) and orders on that same axis.
|
|
6459
|
-
*/
|
|
6460
|
-
resolved_since: external_exports.string().datetime().optional()
|
|
6461
|
-
});
|
|
6462
|
-
GITHUB_ISSUE_URL_REGEX = /^https:\/\/github\.com\/[^/]+\/[^/]+\/issues\/\d+(?:[/?#]|$)/;
|
|
6463
|
-
githubIssueUrlSchema = external_exports.string().url().refine((u) => GITHUB_ISSUE_URL_REGEX.test(u), {
|
|
6464
|
-
message: "must be an https://github.com/<owner>/<repo>/issues/<number> URL"
|
|
6465
|
-
});
|
|
6466
|
-
transitionReportBody = external_exports.discriminatedUnion("target", [
|
|
6467
|
-
external_exports.object({
|
|
6468
|
-
target: external_exports.literal("escalated"),
|
|
6469
|
-
gh_issue_url: githubIssueUrlSchema,
|
|
6470
|
-
ai_verdict: external_exports.string().max(2e3).optional()
|
|
6471
|
-
}),
|
|
6472
|
-
external_exports.object({
|
|
6473
|
-
target: external_exports.literal("shipped"),
|
|
6474
|
-
note: external_exports.string().min(1).max(2e3).optional()
|
|
6475
|
-
}),
|
|
6476
|
-
external_exports.object({
|
|
6477
|
-
target: external_exports.literal("addressed")
|
|
6478
|
-
}),
|
|
6479
|
-
external_exports.object({
|
|
6480
|
-
target: external_exports.literal("dismissed"),
|
|
6481
|
-
dismissal_reason: external_exports.string().min(1).max(5e3),
|
|
6482
|
-
ai_verdict: external_exports.string().max(2e3).optional(),
|
|
6483
|
-
final: external_exports.boolean().optional()
|
|
6484
|
-
})
|
|
6485
|
-
]);
|
|
6486
|
-
groupReportsBody = external_exports.object({
|
|
6487
|
-
member_ids: external_exports.array(external_exports.string().uuid()).min(1).max(100)
|
|
6488
|
-
});
|
|
6489
|
-
holdReportBody = external_exports.object({
|
|
6490
|
-
reason: external_exports.string().min(1).max(5e3)
|
|
6491
|
-
});
|
|
6492
|
-
}
|
|
6493
|
-
});
|
|
6494
|
-
|
|
6495
|
-
// ../../packages/core/dist/chunk-KEN2DASI.js
|
|
6496
|
-
var SECOND_FACTOR_TIERS, secondFactorTier, META_ENTITY_ID_PATTERN, metaEntityId, whatsappCallbackBody, authMeResponse, wsTicketResponse, sessionCheckResponse, logoutResponse, magicCodeSendBody, magicCodeSendResponse, magicCodeVerifyBody, magicCodeVerifyResponse, passwordLoginBody, normalizeEmail, REVIEW_ACCOUNT_EMAILS;
|
|
6497
|
-
var init_chunk_KEN2DASI = __esm({
|
|
6498
|
-
"../../packages/core/dist/chunk-KEN2DASI.js"() {
|
|
6499
|
-
"use strict";
|
|
6500
|
-
init_zod();
|
|
6501
|
-
SECOND_FACTOR_TIERS = ["off", "settings"];
|
|
6502
|
-
secondFactorTier = external_exports.enum(SECOND_FACTOR_TIERS);
|
|
6503
|
-
META_ENTITY_ID_PATTERN = /^\d{1,32}$/;
|
|
6504
|
-
metaEntityId = external_exports.string().regex(META_ENTITY_ID_PATTERN, "must be a numeric Meta entity id");
|
|
6505
|
-
whatsappCallbackBody = external_exports.object({
|
|
6506
|
-
state: external_exports.string().min(1, "state is required"),
|
|
6507
|
-
code: external_exports.string().optional(),
|
|
6508
|
-
access_token: external_exports.string().optional(),
|
|
6509
|
-
user_id: external_exports.string().optional(),
|
|
6510
|
-
/**
|
|
6511
|
-
* The phone number and WABA the operator actually picked in Meta's Embedded
|
|
6512
|
-
* Signup popup (posted to the opener as `WA_EMBEDDED_SIGNUP`). Optional:
|
|
6513
|
-
* older clients, and the redirect-based flow, never see that event and fall
|
|
6514
|
-
* back to discovery.
|
|
6515
|
-
*/
|
|
6516
|
-
phone_number_id: metaEntityId.optional(),
|
|
6517
|
-
waba_id: metaEntityId.optional()
|
|
6518
|
-
}).refine(
|
|
6519
|
-
(data) => !!data.access_token || !!data.code,
|
|
6520
|
-
{ message: "Missing required parameters: state and either access_token or code" }
|
|
6521
|
-
);
|
|
6522
|
-
authMeResponse = external_exports.object({
|
|
6523
|
-
user_id: external_exports.string(),
|
|
6524
|
-
email: external_exports.string(),
|
|
6525
|
-
org_id: external_exports.string().nullable(),
|
|
6526
|
-
is_platform_admin: external_exports.boolean()
|
|
6527
|
-
});
|
|
6528
|
-
wsTicketResponse = external_exports.object({
|
|
6529
|
-
ticket: external_exports.string(),
|
|
6530
|
-
/** Seconds until the ticket expires if unconsumed. */
|
|
6531
|
-
expires_in: external_exports.number()
|
|
6532
|
-
});
|
|
6533
|
-
sessionCheckResponse = external_exports.object({
|
|
6534
|
-
valid: external_exports.literal(true)
|
|
6535
|
-
});
|
|
6536
|
-
logoutResponse = external_exports.object({
|
|
6537
|
-
success: external_exports.literal(true)
|
|
6538
|
-
});
|
|
6539
|
-
magicCodeSendBody = external_exports.object({
|
|
6540
|
-
email: external_exports.string().email("Invalid email").max(254)
|
|
6541
|
-
// RFC 5321 max; bounds the request payload
|
|
6542
|
-
});
|
|
6543
|
-
magicCodeSendResponse = external_exports.object({
|
|
6544
|
-
success: external_exports.literal(true)
|
|
6545
|
-
});
|
|
6546
|
-
magicCodeVerifyBody = external_exports.object({
|
|
6547
|
-
email: external_exports.string().email("Invalid email").max(254),
|
|
6548
|
-
// RFC 5321 max; bounds the request payload
|
|
6549
|
-
code: external_exports.string().min(1, "Code is required").max(12)
|
|
6550
|
-
// WorkOS sends a 6-digit code; bound the input
|
|
6551
|
-
});
|
|
6552
|
-
magicCodeVerifyResponse = external_exports.object({
|
|
6553
|
-
access_token: external_exports.string(),
|
|
6554
|
-
refresh_token: external_exports.string()
|
|
6555
|
-
});
|
|
6556
|
-
passwordLoginBody = external_exports.object({
|
|
6557
|
-
email: external_exports.string().email("Invalid email").max(254),
|
|
6558
|
-
// RFC 5321 max; bounds the request payload
|
|
6559
|
-
password: external_exports.string().min(1, "Password is required").max(128)
|
|
6560
|
-
// bound the payload; WorkOS validates
|
|
6561
|
-
});
|
|
6562
|
-
normalizeEmail = (email) => email.trim().toLowerCase();
|
|
6563
|
-
REVIEW_ACCOUNT_EMAILS = new Set(
|
|
6564
|
-
["apple.review@wayai.pro", "play.review@wayai.pro", "microsoft.review@wayai.pro", "meta.review@wayai.pro"].map(
|
|
6565
|
-
normalizeEmail
|
|
6566
|
-
)
|
|
6567
|
-
);
|
|
6568
|
-
}
|
|
6569
|
-
});
|
|
6570
|
-
|
|
6571
|
-
// ../../packages/core/dist/chunk-PFGVH2CX.js
|
|
6572
|
-
var secondFactorCode, secondFactorRecoveryCode, secondFactorCodeBody, secondFactorRecoveryBody, secondFactorDisableBody, setOrgSecondFactorBody;
|
|
6573
|
-
var init_chunk_PFGVH2CX = __esm({
|
|
6574
|
-
"../../packages/core/dist/chunk-PFGVH2CX.js"() {
|
|
6575
|
-
"use strict";
|
|
6576
|
-
init_chunk_KEN2DASI();
|
|
6577
|
-
init_zod();
|
|
6578
|
-
secondFactorCode = external_exports.string().regex(/^\d{6}$/, "Enter the 6-digit code");
|
|
6579
|
-
secondFactorRecoveryCode = external_exports.string().min(1, "Enter a recovery code").max(64);
|
|
6580
|
-
secondFactorCodeBody = external_exports.object({ code: secondFactorCode });
|
|
6581
|
-
secondFactorRecoveryBody = external_exports.object({ recovery_code: secondFactorRecoveryCode });
|
|
6582
|
-
secondFactorDisableBody = external_exports.union([
|
|
6583
|
-
external_exports.object({ code: secondFactorCode, recovery_code: external_exports.undefined().optional() }),
|
|
6584
|
-
external_exports.object({ recovery_code: secondFactorRecoveryCode, code: external_exports.undefined().optional() })
|
|
6585
|
-
]);
|
|
6586
|
-
setOrgSecondFactorBody = external_exports.object({ tier: secondFactorTier });
|
|
6587
|
-
}
|
|
6588
|
-
});
|
|
6589
|
-
|
|
6590
|
-
// ../../packages/core/dist/chunk-TVUDMGWV.js
|
|
6591
|
-
var bootstrapQuery;
|
|
6592
|
-
var init_chunk_TVUDMGWV = __esm({
|
|
6593
|
-
"../../packages/core/dist/chunk-TVUDMGWV.js"() {
|
|
6594
|
-
"use strict";
|
|
6595
|
-
init_zod();
|
|
6596
|
-
bootstrapQuery = external_exports.object({
|
|
6597
|
-
active_hub_id: external_exports.string().uuid().optional(),
|
|
6598
|
-
active_conversation_id: external_exports.string().uuid().optional(),
|
|
6599
|
-
active_nav: external_exports.enum(["chat", "task", "support"]).optional(),
|
|
6600
|
-
/**
|
|
6601
|
-
* The people thread the URL names (`/chat/threads/:threadId`, gh #4661): the snapshot
|
|
6602
|
-
* preloads it as `people.active_thread` when the viewer is a member.
|
|
6603
|
-
*/
|
|
6604
|
-
active_thread_id: external_exports.string().uuid().optional()
|
|
6605
|
-
});
|
|
6606
|
-
}
|
|
6607
|
-
});
|
|
6608
|
-
|
|
6609
|
-
// ../../packages/core/dist/chunk-S4HVRNEQ.js
|
|
6610
|
-
var PERMISSIONS;
|
|
6611
|
-
var init_chunk_S4HVRNEQ = __esm({
|
|
6612
|
-
"../../packages/core/dist/chunk-S4HVRNEQ.js"() {
|
|
6613
|
-
"use strict";
|
|
6614
|
-
PERMISSIONS = [
|
|
6615
|
-
"hub:read",
|
|
6616
|
-
"hub:write",
|
|
6617
|
-
"hub:admin",
|
|
6618
|
-
"conversation:read",
|
|
6619
|
-
"conversation:write",
|
|
6620
|
-
"analytics:read",
|
|
6621
|
-
"billing:read",
|
|
6622
|
-
"billing:write",
|
|
6623
|
-
"org:read",
|
|
6624
|
-
"org:write",
|
|
6625
|
-
"org:admin",
|
|
6626
|
-
"contacts:write",
|
|
6627
|
-
"platform:admin",
|
|
6628
|
-
"*"
|
|
6629
|
-
];
|
|
6630
|
-
}
|
|
6631
|
-
});
|
|
6632
|
-
|
|
6633
|
-
// ../../packages/core/dist/chunk-WTIGECE5.js
|
|
6634
|
-
var MAX_NAME_LENGTH, MAX_HUBS_PER_GRANT, MAX_HUB_TAGS_PER_GRANT, MAX_GRANTS, permissionEnum, grantScopeSchema, grantSchema, createTokenBody, tokenOrgIdParam;
|
|
6635
|
-
var init_chunk_WTIGECE5 = __esm({
|
|
6636
|
-
"../../packages/core/dist/chunk-WTIGECE5.js"() {
|
|
6369
|
+
// ../../packages/core/dist/chunk-5FO3GNKP.js
|
|
6370
|
+
var DATA_PROXY_MOUNT, DATA_PROXY_PREFIX, BASE_DESTRUCTION_MOUNT, BASE_DESTRUCTION_PREFIX, BASE_DESTRUCTION_CONFIRM_PATH, COMMUNITY_EMAIL_UNSUBSCRIBE_PATH, CONTACT_BOOK_EMAIL_UNSUBSCRIBE_PATH, AUTOMATION_WEBHOOK_MOUNT, MANAGED_AGENTS_WEBHOOK_MOUNT, TELEGRAM_VAULT_WEBHOOK_PATH;
|
|
6371
|
+
var init_chunk_5FO3GNKP = __esm({
|
|
6372
|
+
"../../packages/core/dist/chunk-5FO3GNKP.js"() {
|
|
6637
6373
|
"use strict";
|
|
6638
|
-
|
|
6639
|
-
|
|
6640
|
-
|
|
6641
|
-
|
|
6642
|
-
|
|
6643
|
-
|
|
6644
|
-
|
|
6645
|
-
|
|
6646
|
-
|
|
6647
|
-
|
|
6648
|
-
);
|
|
6649
|
-
grantScopeSchema = external_exports.object({
|
|
6650
|
-
// Required: every token grant must declare its org tenancy. The handler
|
|
6651
|
-
// also strict-checks this as defense-in-depth, but failing at the Zod
|
|
6652
|
-
// boundary keeps the generated client type honest (org_id: string).
|
|
6653
|
-
org_id: external_exports.string().min(1),
|
|
6654
|
-
hubs: external_exports.array(external_exports.string().min(1)).min(1, "Each grant must have scope.hubs as a non-empty array").max(MAX_HUBS_PER_GRANT),
|
|
6655
|
-
hub_tags: external_exports.array(external_exports.string().min(1)).min(1, "scope.hub_tags must be a non-empty array if provided").max(MAX_HUB_TAGS_PER_GRANT).optional(),
|
|
6656
|
-
environments: external_exports.array(external_exports.enum(["production", "preview"])).min(1, "scope.environments must be a non-empty array if provided").optional()
|
|
6657
|
-
}).strict();
|
|
6658
|
-
grantSchema = external_exports.object({
|
|
6659
|
-
scope: grantScopeSchema,
|
|
6660
|
-
permissions: external_exports.array(permissionEnum).min(1, "Each grant must have permissions as a non-empty array")
|
|
6661
|
-
}).strict();
|
|
6662
|
-
createTokenBody = external_exports.object({
|
|
6663
|
-
name: external_exports.string().trim().min(1, "name is required").max(MAX_NAME_LENGTH, `name must be ${MAX_NAME_LENGTH} characters or fewer`),
|
|
6664
|
-
grants: external_exports.array(grantSchema).min(1, "grants must be a non-empty array").max(MAX_GRANTS),
|
|
6665
|
-
expires_at: external_exports.string().datetime({ message: "expires_at must be a valid ISO 8601 date" }).refine(
|
|
6666
|
-
(s) => new Date(s).getTime() > Date.now(),
|
|
6667
|
-
{ message: "expires_at must be in the future" }
|
|
6668
|
-
).optional()
|
|
6669
|
-
});
|
|
6670
|
-
tokenOrgIdParam = external_exports.object({ orgId: uuidSchema });
|
|
6374
|
+
DATA_PROXY_MOUNT = "/data";
|
|
6375
|
+
DATA_PROXY_PREFIX = `/api${DATA_PROXY_MOUNT}`;
|
|
6376
|
+
BASE_DESTRUCTION_MOUNT = "/bases";
|
|
6377
|
+
BASE_DESTRUCTION_PREFIX = `/api${BASE_DESTRUCTION_MOUNT}`;
|
|
6378
|
+
BASE_DESTRUCTION_CONFIRM_PATH = `${BASE_DESTRUCTION_PREFIX}/destruction/confirm`;
|
|
6379
|
+
COMMUNITY_EMAIL_UNSUBSCRIBE_PATH = "/api/communities/email-unsubscribe";
|
|
6380
|
+
CONTACT_BOOK_EMAIL_UNSUBSCRIBE_PATH = "/api/contact-book/email-unsubscribe";
|
|
6381
|
+
AUTOMATION_WEBHOOK_MOUNT = "/webhooks/automations";
|
|
6382
|
+
MANAGED_AGENTS_WEBHOOK_MOUNT = "/webhooks/managed-agents";
|
|
6383
|
+
TELEGRAM_VAULT_WEBHOOK_PATH = "/webhooks/telegram/vault";
|
|
6671
6384
|
}
|
|
6672
6385
|
});
|
|
6673
6386
|
|
|
6674
|
-
// ../../packages/core/dist/chunk-
|
|
6675
|
-
|
|
6676
|
-
|
|
6677
|
-
|
|
6678
|
-
|
|
6679
|
-
|
|
6680
|
-
|
|
6681
|
-
init_zod();
|
|
6682
|
-
TOOLSET_ANSWER_PERSON_PARTIES = ["requester", "originator", "initiator", "delegator"];
|
|
6683
|
-
toolsetAnswerPersonSchema = external_exports.object({
|
|
6684
|
-
party: external_exports.enum(TOOLSET_ANSWER_PERSON_PARTIES),
|
|
6685
|
-
person_id: rekorPersonIdSchema
|
|
6686
|
-
}).strict();
|
|
6687
|
-
toolsetAnswerPersonsSchema = external_exports.array(toolsetAnswerPersonSchema).min(1).max(REKOR_MAX_PERSON_PARTIES);
|
|
6387
|
+
// ../../packages/core/dist/chunk-AUD5MVHU.js
|
|
6388
|
+
function matchPath(pattern, path55) {
|
|
6389
|
+
const pathSegments2 = path55.replace(/\/$/, "").split("/");
|
|
6390
|
+
const isPrefix = pattern.endsWith("/*");
|
|
6391
|
+
const patternSegments = (isPrefix ? pattern.slice(0, -2) : pattern).split("/");
|
|
6392
|
+
if (isPrefix ? pathSegments2.length < patternSegments.length : pathSegments2.length !== patternSegments.length) {
|
|
6393
|
+
return false;
|
|
6688
6394
|
}
|
|
6689
|
-
|
|
6690
|
-
|
|
6691
|
-
|
|
6692
|
-
|
|
6693
|
-
|
|
6694
|
-
|
|
6695
|
-
|
|
6696
|
-
init_chunk_HZ6CADSY();
|
|
6697
|
-
init_zod();
|
|
6698
|
-
PEOPLE_CONTACT_PAGE_MAX = 100;
|
|
6699
|
-
PEOPLE_CONTACT_PAGE_DEFAULT = 50;
|
|
6700
|
-
PEOPLE_CONTACT_EMAIL_MAX_LENGTH = 254;
|
|
6701
|
-
peopleUserIdSchema = external_exports.string().max(64).regex(USER_ID_REGEX, "must be a user id");
|
|
6702
|
-
peopleInviteEmailSchema = external_exports.string().trim().max(PEOPLE_CONTACT_EMAIL_MAX_LENGTH).email();
|
|
6703
|
-
peopleContactInviteBody = external_exports.object({
|
|
6704
|
-
email: peopleInviteEmailSchema
|
|
6705
|
-
}).strict();
|
|
6706
|
-
peopleContactInviteIdParam = external_exports.object({ inviteId: uuidSchema });
|
|
6707
|
-
peopleContactUserIdParam = external_exports.object({ userId: peopleUserIdSchema });
|
|
6708
|
-
peopleContactBlockBody = external_exports.object({ user_id: peopleUserIdSchema, thread_id: uuidSchema.optional(), community_id: uuidSchema.optional() }).strict().refine((body) => body.thread_id === void 0 || body.community_id === void 0, {
|
|
6709
|
-
message: "Name a thread or a community, not both",
|
|
6710
|
-
path: ["community_id"]
|
|
6711
|
-
});
|
|
6712
|
-
peopleContactPageQuery = external_exports.object({
|
|
6713
|
-
cursor: external_exports.string().min(1).max(256).optional(),
|
|
6714
|
-
limit: external_exports.coerce.number().int().min(1).max(PEOPLE_CONTACT_PAGE_MAX).default(PEOPLE_CONTACT_PAGE_DEFAULT)
|
|
6715
|
-
});
|
|
6716
|
-
peopleOutgoingInviteSchema = external_exports.object({
|
|
6717
|
-
invite_id: uuidSchema,
|
|
6718
|
-
email: external_exports.string(),
|
|
6719
|
-
status: external_exports.literal("sent"),
|
|
6720
|
-
created_at: timestampSchema,
|
|
6721
|
-
expires_at: timestampSchema
|
|
6722
|
-
}).strict();
|
|
6723
|
-
peopleContactPersonSchema = external_exports.object({
|
|
6724
|
-
user_id: peopleUserIdSchema,
|
|
6725
|
-
display_name: external_exports.string().nullable(),
|
|
6726
|
-
email: external_exports.string().nullable()
|
|
6727
|
-
}).strict();
|
|
6728
|
-
peopleContactSchema = peopleContactPersonSchema.extend({ contact_since: timestampSchema, thread_id: uuidSchema }).strict();
|
|
6729
|
-
peopleIncomingInviteSchema = external_exports.object({
|
|
6730
|
-
invite_id: uuidSchema,
|
|
6731
|
-
inviter: peopleContactPersonSchema,
|
|
6732
|
-
created_at: timestampSchema,
|
|
6733
|
-
expires_at: timestampSchema
|
|
6734
|
-
}).strict();
|
|
6735
|
-
peopleBlockedUserSchema = peopleContactPersonSchema.extend({ blocked_at: timestampSchema, deleted_user: external_exports.boolean() }).strict();
|
|
6395
|
+
return patternSegments.every((segment2, i) => segment2 === "*" ? pathSegments2[i] !== "" : segment2 === pathSegments2[i]);
|
|
6396
|
+
}
|
|
6397
|
+
function getEndpointConfig(path55) {
|
|
6398
|
+
for (const excluded of EXCLUDED_PATHS) {
|
|
6399
|
+
if (matchPath(excluded, path55)) {
|
|
6400
|
+
return null;
|
|
6401
|
+
}
|
|
6736
6402
|
}
|
|
6737
|
-
|
|
6738
|
-
|
|
6739
|
-
|
|
6740
|
-
var PEOPLE_MODERATION_NOTE_MAX_LENGTH, ADMIN_PEOPLE_REPORTS_PAGE_MAX, ADMIN_PEOPLE_REPORTS_PAGE_DEFAULT, PEOPLE_SUSPENDED_REASON, peopleModerationActionSchema, moderationNoteSchema, adminPeopleReportListQuery, adminPeopleReportIdParam, adminPeopleMessageRemovalBody, adminPeopleSuspendBody, adminPeopleNoteBody;
|
|
6741
|
-
var init_chunk_ZXK6N2HN = __esm({
|
|
6742
|
-
"../../packages/core/dist/chunk-ZXK6N2HN.js"() {
|
|
6743
|
-
"use strict";
|
|
6744
|
-
init_chunk_ZVXO3XL6();
|
|
6745
|
-
init_chunk_HZ6CADSY();
|
|
6746
|
-
init_zod();
|
|
6747
|
-
PEOPLE_MODERATION_NOTE_MAX_LENGTH = 500;
|
|
6748
|
-
ADMIN_PEOPLE_REPORTS_PAGE_MAX = 100;
|
|
6749
|
-
ADMIN_PEOPLE_REPORTS_PAGE_DEFAULT = 50;
|
|
6750
|
-
PEOPLE_SUSPENDED_REASON = "suspended";
|
|
6751
|
-
peopleModerationActionSchema = external_exports.enum(["remove_message", "suspend", "unsuspend", "dismiss"]);
|
|
6752
|
-
moderationNoteSchema = optionalTrimmedText(PEOPLE_MODERATION_NOTE_MAX_LENGTH);
|
|
6753
|
-
adminPeopleReportListQuery = external_exports.object({
|
|
6754
|
-
pending: external_exports.enum(["true", "false"]).optional().transform((value) => value === "true"),
|
|
6755
|
-
/** Lower bound on `created_at`. */
|
|
6756
|
-
since: timestampSchema.optional(),
|
|
6757
|
-
limit: external_exports.coerce.number().int().min(1).max(ADMIN_PEOPLE_REPORTS_PAGE_MAX).default(ADMIN_PEOPLE_REPORTS_PAGE_DEFAULT),
|
|
6758
|
-
offset: external_exports.coerce.number().int().min(0).default(0)
|
|
6759
|
-
});
|
|
6760
|
-
adminPeopleReportIdParam = external_exports.object({ reportId: uuidSchema });
|
|
6761
|
-
adminPeopleMessageRemovalBody = external_exports.object({ report_id: uuidSchema, message_id: uuidSchema.optional(), note: moderationNoteSchema }).strict();
|
|
6762
|
-
adminPeopleSuspendBody = external_exports.object({ report_id: uuidSchema.optional(), note: moderationNoteSchema }).strict();
|
|
6763
|
-
adminPeopleNoteBody = external_exports.object({ note: moderationNoteSchema }).strict();
|
|
6403
|
+
const normalizedPath = path55.replace(/\/$/, "");
|
|
6404
|
+
if (!normalizedPath.endsWith("/*") && Object.prototype.hasOwnProperty.call(ENDPOINT_CONFIGS, normalizedPath)) {
|
|
6405
|
+
return ENDPOINT_CONFIGS[normalizedPath];
|
|
6764
6406
|
}
|
|
6765
|
-
|
|
6766
|
-
|
|
6767
|
-
|
|
6768
|
-
|
|
6769
|
-
|
|
6770
|
-
"../../packages/core/dist/chunk-Y7CFCYX4.js"() {
|
|
6771
|
-
"use strict";
|
|
6772
|
-
init_chunk_ZVXO3XL6();
|
|
6773
|
-
init_chunk_HZ6CADSY();
|
|
6774
|
-
init_zod();
|
|
6775
|
-
PEOPLE_REPORT_DETAILS_MAX_LENGTH = 500;
|
|
6776
|
-
peopleReportReasonSchema = external_exports.enum(["spam", "harassment", "hate", "sexual", "violence", "other"]);
|
|
6777
|
-
reportDetailsSchema = optionalTrimmedText(PEOPLE_REPORT_DETAILS_MAX_LENGTH);
|
|
6778
|
-
reportFields = { reason: peopleReportReasonSchema, details: reportDetailsSchema };
|
|
6779
|
-
peopleReportBody = external_exports.discriminatedUnion("target", [
|
|
6780
|
-
external_exports.object({ target: external_exports.literal("message"), thread_id: uuidSchema, message_id: uuidSchema, ...reportFields }).strict(),
|
|
6781
|
-
external_exports.object({ target: external_exports.literal("thread"), thread_id: uuidSchema, ...reportFields }).strict(),
|
|
6782
|
-
external_exports.object({ target: external_exports.literal("user"), user_id: peopleUserIdSchema, thread_id: uuidSchema.optional(), ...reportFields }).strict(),
|
|
6783
|
-
external_exports.object({
|
|
6784
|
-
target: external_exports.literal("community_message"),
|
|
6785
|
-
community_id: uuidSchema,
|
|
6786
|
-
room_id: uuidSchema,
|
|
6787
|
-
message_id: uuidSchema,
|
|
6788
|
-
...reportFields
|
|
6789
|
-
}).strict(),
|
|
6790
|
-
external_exports.object({ target: external_exports.literal("community_member"), community_id: uuidSchema, user_id: peopleUserIdSchema, ...reportFields }).strict()
|
|
6791
|
-
]);
|
|
6407
|
+
const sortedPatterns = Object.keys(ENDPOINT_CONFIGS).sort((a, b) => b.length - a.length);
|
|
6408
|
+
for (const pattern of sortedPatterns) {
|
|
6409
|
+
if (matchPath(pattern, path55)) {
|
|
6410
|
+
return ENDPOINT_CONFIGS[pattern];
|
|
6411
|
+
}
|
|
6792
6412
|
}
|
|
6793
|
-
}
|
|
6794
|
-
|
|
6795
|
-
// ../../packages/core/dist/chunk-UAOHHCW5.js
|
|
6796
|
-
function normalizeContactPhone(raw) {
|
|
6797
|
-
const compact = raw.trim().replace(/[\s\-.()]/g, "");
|
|
6798
|
-
const withPlus = compact.startsWith("00") ? `+${compact.slice(2)}` : compact;
|
|
6799
|
-
return /^\+[1-9]\d{7,14}$/.test(withPlus) ? withPlus : null;
|
|
6800
|
-
}
|
|
6801
|
-
function normalizeContactLabel(raw) {
|
|
6802
|
-
return raw.trim().replace(/\s+/g, " ").toLowerCase();
|
|
6803
|
-
}
|
|
6804
|
-
function importRowLabels(row, batchLabels) {
|
|
6805
|
-
return [.../* @__PURE__ */ new Set([...row.labels ?? [], ...batchLabels ?? []])];
|
|
6413
|
+
return { tier: "STANDARD" };
|
|
6806
6414
|
}
|
|
6807
|
-
var
|
|
6808
|
-
var
|
|
6809
|
-
"../../packages/core/dist/chunk-
|
|
6810
|
-
"use strict";
|
|
6811
|
-
init_zod();
|
|
6812
|
-
CONTACT_ENVIRONMENTS = ["production", "preview", "all"];
|
|
6813
|
-
CONTACT_NAME_MAX = 200;
|
|
6814
|
-
CONTACT_EMAIL_MAX = 320;
|
|
6815
|
-
CONTACT_PHONE_INPUT_MAX = 40;
|
|
6816
|
-
CONTACT_INSTAGRAM_SID_MAX = 64;
|
|
6817
|
-
CONTACT_METADATA_MAX_BYTES = 4096;
|
|
6818
|
-
CONTACT_LABEL_MAX = 64;
|
|
6819
|
-
CONTACT_LABELS_MAX = 20;
|
|
6820
|
-
CONTACT_SCOPE_TAGS_MAX = 20;
|
|
6821
|
-
CONTACT_PAGE_MAX = 100;
|
|
6822
|
-
CONTACT_IMPORT_BATCH_MAX = 500;
|
|
6823
|
-
CONTACT_SEARCH_MAX = 100;
|
|
6824
|
-
CONTACT_LIST_NAME_MAX = 64;
|
|
6825
|
-
CONTACT_LIST_NAME_REGEX = /^[a-z0-9]+(-[a-z0-9]+)*$/;
|
|
6826
|
-
CONTACT_LIST_DESCRIPTION_MAX = 1e3;
|
|
6827
|
-
CONTACT_LIST_FILTER_MAX = 20;
|
|
6828
|
-
CONTACT_LIST_PINS_PER_REQUEST_MAX = 100;
|
|
6829
|
-
SUPPRESSION_SCOPES = ["all", "marketing"];
|
|
6830
|
-
SUPPRESSION_ID_REGEX = /^[0-9a-f]{64}$/;
|
|
6831
|
-
contactName = external_exports.string().trim().min(1).max(CONTACT_NAME_MAX);
|
|
6832
|
-
contactPhone = external_exports.string().max(CONTACT_PHONE_INPUT_MAX).transform((raw, ctx) => {
|
|
6833
|
-
const phone = normalizeContactPhone(raw);
|
|
6834
|
-
if (phone === null) {
|
|
6835
|
-
ctx.addIssue({ code: external_exports.ZodIssueCode.custom, message: "Phone must be an international number, e.g. +5511999999999" });
|
|
6836
|
-
return external_exports.NEVER;
|
|
6837
|
-
}
|
|
6838
|
-
return phone;
|
|
6839
|
-
});
|
|
6840
|
-
contactEmail = external_exports.string().trim().toLowerCase().max(CONTACT_EMAIL_MAX).email();
|
|
6841
|
-
contactInstagramSid = external_exports.string().trim().min(1).max(CONTACT_INSTAGRAM_SID_MAX);
|
|
6842
|
-
contactLabel = external_exports.string().max(CONTACT_LABEL_MAX).transform(normalizeContactLabel).refine((label3) => label3.length > 0, "A label cannot be empty").refine((label3) => !label3.includes(","), "A label cannot contain a comma");
|
|
6843
|
-
contactLabels = external_exports.array(contactLabel).max(CONTACT_LABELS_MAX).transform((labels) => [...new Set(labels)]);
|
|
6844
|
-
contactMetadata = external_exports.record(external_exports.unknown()).refine((metadata) => {
|
|
6845
|
-
try {
|
|
6846
|
-
return new TextEncoder().encode(JSON.stringify(metadata)).length <= CONTACT_METADATA_MAX_BYTES;
|
|
6847
|
-
} catch {
|
|
6848
|
-
return false;
|
|
6849
|
-
}
|
|
6850
|
-
}, `Metadata must serialize to at most ${CONTACT_METADATA_MAX_BYTES} bytes`);
|
|
6851
|
-
scopeTagIds = external_exports.array(external_exports.string().uuid()).min(1).max(CONTACT_SCOPE_TAGS_MAX).transform((ids) => [...new Set(ids)]);
|
|
6852
|
-
contactVisibilitySchema = external_exports.discriminatedUnion("scope", [
|
|
6853
|
-
external_exports.object({ scope: external_exports.literal("all_hubs") }).strict(),
|
|
6854
|
-
external_exports.object({ scope: external_exports.literal("tags"), tag_ids: scopeTagIds }).strict()
|
|
6855
|
-
]);
|
|
6856
|
-
hasIdentity = (row) => Boolean(row.phone || row.email || row.instagram_sid);
|
|
6857
|
-
IDENTITY_REQUIRED = "A contact needs a phone, an email or an Instagram id";
|
|
6858
|
-
contactBookOrgQuery = external_exports.object({
|
|
6859
|
-
organization_id: external_exports.string().uuid()
|
|
6860
|
-
});
|
|
6861
|
-
contactBookContactParam = external_exports.object({
|
|
6862
|
-
contactId: external_exports.string().uuid()
|
|
6863
|
-
});
|
|
6864
|
-
contactBookListParam = external_exports.object({
|
|
6865
|
-
listId: external_exports.string().uuid()
|
|
6866
|
-
});
|
|
6867
|
-
contactBookHubParam = external_exports.object({
|
|
6868
|
-
hubId: external_exports.string().uuid()
|
|
6869
|
-
});
|
|
6870
|
-
contactBookPageQuery = external_exports.object({
|
|
6871
|
-
cursor: external_exports.string().max(2048).optional(),
|
|
6872
|
-
limit: external_exports.coerce.number().int().min(1).max(CONTACT_PAGE_MAX).default(50)
|
|
6873
|
-
});
|
|
6874
|
-
listContactBookContactsQuery = contactBookOrgQuery.merge(contactBookPageQuery).extend({
|
|
6875
|
-
q: external_exports.string().trim().max(CONTACT_SEARCH_MAX).optional(),
|
|
6876
|
-
label: external_exports.string().max(CONTACT_LABEL_MAX).transform(normalizeContactLabel).optional(),
|
|
6877
|
-
scope_tag_id: external_exports.string().uuid().optional()
|
|
6878
|
-
});
|
|
6879
|
-
listHubContactBookContactsQuery = contactBookPageQuery.extend({
|
|
6880
|
-
q: external_exports.string().trim().max(CONTACT_SEARCH_MAX).optional()
|
|
6881
|
-
});
|
|
6882
|
-
contactBookLinkCandidatesQuery = contactBookOrgQuery.extend({
|
|
6883
|
-
email: contactEmail
|
|
6884
|
-
});
|
|
6885
|
-
listContactBookListMembersQuery = contactBookOrgQuery.merge(contactBookPageQuery);
|
|
6886
|
-
contactRowFields = {
|
|
6887
|
-
name: contactName,
|
|
6888
|
-
phone: contactPhone.nullish(),
|
|
6889
|
-
email: contactEmail.nullish(),
|
|
6890
|
-
instagram_sid: contactInstagramSid.nullish(),
|
|
6891
|
-
labels: contactLabels.optional(),
|
|
6892
|
-
metadata: contactMetadata.optional()
|
|
6893
|
-
};
|
|
6894
|
-
createContactBookContactBody = external_exports.object({
|
|
6895
|
-
organization_id: external_exports.string().uuid(),
|
|
6896
|
-
...contactRowFields,
|
|
6897
|
-
visibility: contactVisibilitySchema,
|
|
6898
|
-
environment: external_exports.enum(CONTACT_ENVIRONMENTS).optional()
|
|
6899
|
-
}).strict().refine(hasIdentity, IDENTITY_REQUIRED);
|
|
6900
|
-
updateContactBookContactBody = external_exports.object({
|
|
6901
|
-
name: contactName.optional(),
|
|
6902
|
-
phone: contactPhone.nullable().optional(),
|
|
6903
|
-
email: contactEmail.nullable().optional(),
|
|
6904
|
-
instagram_sid: contactInstagramSid.nullable().optional(),
|
|
6905
|
-
labels: contactLabels.optional(),
|
|
6906
|
-
metadata: contactMetadata.optional(),
|
|
6907
|
-
visibility: contactVisibilitySchema.optional(),
|
|
6908
|
-
environment: external_exports.enum(CONTACT_ENVIRONMENTS).optional()
|
|
6909
|
-
}).strict();
|
|
6910
|
-
contactImportRowSchema = external_exports.object(contactRowFields).strict().refine(hasIdentity, IDENTITY_REQUIRED);
|
|
6911
|
-
importContactBookContactsBody = external_exports.object({
|
|
6912
|
-
organization_id: external_exports.string().uuid(),
|
|
6913
|
-
visibility: contactVisibilitySchema,
|
|
6914
|
-
environment: external_exports.enum(CONTACT_ENVIRONMENTS).optional(),
|
|
6915
|
-
labels: contactLabels.optional(),
|
|
6916
|
-
rows: external_exports.array(contactImportRowSchema).min(1).max(CONTACT_IMPORT_BATCH_MAX)
|
|
6917
|
-
}).strict().superRefine((batch, ctx) => {
|
|
6918
|
-
batch.rows.forEach((row, index) => {
|
|
6919
|
-
if (importRowLabels(row, batch.labels).length > CONTACT_LABELS_MAX) {
|
|
6920
|
-
ctx.addIssue({
|
|
6921
|
-
code: external_exports.ZodIssueCode.custom,
|
|
6922
|
-
path: ["rows", index, "labels"],
|
|
6923
|
-
message: `A contact holds at most ${CONTACT_LABELS_MAX} labels, the batch's included`
|
|
6924
|
-
});
|
|
6925
|
-
}
|
|
6926
|
-
});
|
|
6927
|
-
});
|
|
6928
|
-
linkContactBookContactBody = external_exports.object({
|
|
6929
|
-
user_id: external_exports.string().min(1).max(128)
|
|
6930
|
-
}).strict();
|
|
6931
|
-
listName = external_exports.string().trim().min(1).max(CONTACT_LIST_NAME_MAX).regex(CONTACT_LIST_NAME_REGEX, {
|
|
6932
|
-
message: 'Must be lowercase alphanumeric with hyphens (e.g. "vip-customers")'
|
|
6933
|
-
});
|
|
6934
|
-
contactListFilterSchema = external_exports.object({
|
|
6935
|
-
labels: external_exports.array(contactLabel).max(CONTACT_LIST_FILTER_MAX).transform((l) => [...new Set(l)]).default([]),
|
|
6936
|
-
scope_tag_ids: external_exports.array(external_exports.string().uuid()).max(CONTACT_LIST_FILTER_MAX).transform((t) => [...new Set(t)]).default([])
|
|
6937
|
-
}).strict();
|
|
6938
|
-
createContactBookListBody = external_exports.object({
|
|
6939
|
-
organization_id: external_exports.string().uuid(),
|
|
6940
|
-
name: listName,
|
|
6941
|
-
description: external_exports.string().max(CONTACT_LIST_DESCRIPTION_MAX).nullish(),
|
|
6942
|
-
filter: contactListFilterSchema.optional()
|
|
6943
|
-
}).strict();
|
|
6944
|
-
updateContactBookListBody = external_exports.object({
|
|
6945
|
-
name: listName.optional(),
|
|
6946
|
-
description: external_exports.string().max(CONTACT_LIST_DESCRIPTION_MAX).nullable().optional(),
|
|
6947
|
-
filter: contactListFilterSchema.optional()
|
|
6948
|
-
}).strict();
|
|
6949
|
-
updateContactBookListPinsBody = external_exports.object({
|
|
6950
|
-
add: external_exports.array(external_exports.string().uuid()).max(CONTACT_LIST_PINS_PER_REQUEST_MAX).default([]),
|
|
6951
|
-
remove: external_exports.array(external_exports.string().uuid()).max(CONTACT_LIST_PINS_PER_REQUEST_MAX).default([])
|
|
6952
|
-
}).strict().refine((b) => b.add.length + b.remove.length > 0, "Add or remove at least one contact");
|
|
6953
|
-
suppressionIdentitySchema = external_exports.discriminatedUnion("kind", [
|
|
6954
|
-
external_exports.object({ kind: external_exports.literal("phone"), value: contactPhone }).strict(),
|
|
6955
|
-
external_exports.object({ kind: external_exports.literal("email"), value: contactEmail }).strict(),
|
|
6956
|
-
external_exports.object({ kind: external_exports.literal("instagram"), value: contactInstagramSid }).strict()
|
|
6957
|
-
]);
|
|
6958
|
-
createContactBookSuppressionBody = external_exports.object({
|
|
6959
|
-
organization_id: external_exports.string().uuid(),
|
|
6960
|
-
identity: suppressionIdentitySchema,
|
|
6961
|
-
scope: external_exports.enum(SUPPRESSION_SCOPES)
|
|
6962
|
-
}).strict();
|
|
6963
|
-
contactBookSuppressionParam = external_exports.object({
|
|
6964
|
-
suppressionId: external_exports.string().regex(SUPPRESSION_ID_REGEX)
|
|
6965
|
-
});
|
|
6966
|
-
listContactBookSuppressionsQuery = contactBookOrgQuery.merge(contactBookPageQuery);
|
|
6967
|
-
contactBookEmailUnsubscribeTokenSchema = external_exports.string().max(200).regex(/^[0-9a-f-]{36}\.[0-9a-f]{64}\.[0-9a-f]{64}$/i);
|
|
6968
|
-
contactBookEmailUnsubscribeQuery = external_exports.object({ token: contactBookEmailUnsubscribeTokenSchema });
|
|
6969
|
-
orgListReferenceSchema = listName;
|
|
6970
|
-
}
|
|
6971
|
-
});
|
|
6972
|
-
|
|
6973
|
-
// ../../packages/core/dist/chunk-2YEGUQR7.js
|
|
6974
|
-
var PERSON_ID_PATTERN, CONTACT_PERSON_ID_PATTERN, PERSON_ID_FORM_MESSAGE, userPersonIdSchema, personIdSchema;
|
|
6975
|
-
var init_chunk_2YEGUQR7 = __esm({
|
|
6976
|
-
"../../packages/core/dist/chunk-2YEGUQR7.js"() {
|
|
6977
|
-
"use strict";
|
|
6978
|
-
init_zod();
|
|
6979
|
-
PERSON_ID_PATTERN = /^prs_[a-z2-7]{52}$/;
|
|
6980
|
-
CONTACT_PERSON_ID_PATTERN = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;
|
|
6981
|
-
PERSON_ID_FORM_MESSAGE = "Must be a person id (prs_\u2026) or a contact id (a lowercase UUID)";
|
|
6982
|
-
userPersonIdSchema = external_exports.string().regex(PERSON_ID_PATTERN, { message: "Must be a person id (prs_\u2026)" });
|
|
6983
|
-
personIdSchema = external_exports.string().refine(
|
|
6984
|
-
(value) => PERSON_ID_PATTERN.test(value) || CONTACT_PERSON_ID_PATTERN.test(value),
|
|
6985
|
-
{ message: PERSON_ID_FORM_MESSAGE }
|
|
6986
|
-
);
|
|
6987
|
-
}
|
|
6988
|
-
});
|
|
6989
|
-
|
|
6990
|
-
// ../../packages/core/dist/chunk-OS6EKEP4.js
|
|
6991
|
-
var PERSON_LINKS_MAX, PERSON_DENY_PAGE_MAX, personParam, personLinkParam, deniedPersonParam, listDeniedPersonsQuery, conversationCustomerPersonParam;
|
|
6992
|
-
var init_chunk_OS6EKEP4 = __esm({
|
|
6993
|
-
"../../packages/core/dist/chunk-OS6EKEP4.js"() {
|
|
6994
|
-
"use strict";
|
|
6995
|
-
init_chunk_UAOHHCW5();
|
|
6996
|
-
init_chunk_2YEGUQR7();
|
|
6997
|
-
init_zod();
|
|
6998
|
-
PERSON_LINKS_MAX = 15;
|
|
6999
|
-
PERSON_DENY_PAGE_MAX = 100;
|
|
7000
|
-
personParam = external_exports.object({
|
|
7001
|
-
personId: userPersonIdSchema
|
|
7002
|
-
});
|
|
7003
|
-
personLinkParam = personParam.extend({
|
|
7004
|
-
targetId: personIdSchema
|
|
7005
|
-
});
|
|
7006
|
-
deniedPersonParam = external_exports.object({
|
|
7007
|
-
personId: personIdSchema
|
|
7008
|
-
});
|
|
7009
|
-
listDeniedPersonsQuery = contactBookOrgQuery.extend({
|
|
7010
|
-
cursor: personIdSchema.optional(),
|
|
7011
|
-
limit: external_exports.coerce.number().int().min(1).max(PERSON_DENY_PAGE_MAX).default(50)
|
|
7012
|
-
});
|
|
7013
|
-
conversationCustomerPersonParam = external_exports.object({
|
|
7014
|
-
hubId: external_exports.string().uuid(),
|
|
7015
|
-
conversationId: external_exports.string().uuid()
|
|
7016
|
-
});
|
|
7017
|
-
}
|
|
7018
|
-
});
|
|
7019
|
-
|
|
7020
|
-
// ../../packages/core/dist/chunk-5DGHIY7L.js
|
|
7021
|
-
var rekorBaseChangeMessageSchema;
|
|
7022
|
-
var init_chunk_5DGHIY7L = __esm({
|
|
7023
|
-
"../../packages/core/dist/chunk-5DGHIY7L.js"() {
|
|
7024
|
-
"use strict";
|
|
7025
|
-
init_zod();
|
|
7026
|
-
rekorBaseChangeMessageSchema = external_exports.object({
|
|
7027
|
-
/** The WayAI org UUID — one id namespace. */
|
|
7028
|
-
org_id: external_exports.string().uuid(),
|
|
7029
|
-
/**
|
|
7030
|
-
* Not a UUID: a preview base id is `{prod_base_id}--{slug}`. Immutable per base — a
|
|
7031
|
-
* preview clone is its OWN base_id — so `(base_id, scope)` keys never collide across
|
|
7032
|
-
* environments. Empty is never a real base id, so it is non-conforming rather than a
|
|
7033
|
-
* frame keyed on nothing.
|
|
7034
|
-
*/
|
|
7035
|
-
base_id: external_exports.string().min(1),
|
|
7036
|
-
/**
|
|
7037
|
-
* Rides along so the client scopes its refetch without a lookup; the inspector scopes
|
|
7038
|
-
* by side.
|
|
7039
|
-
*/
|
|
7040
|
-
environment: external_exports.enum(["production", "preview"]),
|
|
7041
|
-
/** Which pane refetches. `base` covers create/delete/promote/config changes. */
|
|
7042
|
-
scope: external_exports.enum(["records", "record_types", "files", "base"])
|
|
7043
|
-
});
|
|
7044
|
-
}
|
|
7045
|
-
});
|
|
7046
|
-
|
|
7047
|
-
// ../../packages/core/dist/chunk-5FO3GNKP.js
|
|
7048
|
-
var DATA_PROXY_MOUNT, DATA_PROXY_PREFIX, BASE_DESTRUCTION_MOUNT, BASE_DESTRUCTION_PREFIX, BASE_DESTRUCTION_CONFIRM_PATH, COMMUNITY_EMAIL_UNSUBSCRIBE_PATH, CONTACT_BOOK_EMAIL_UNSUBSCRIBE_PATH, AUTOMATION_WEBHOOK_MOUNT, MANAGED_AGENTS_WEBHOOK_MOUNT, TELEGRAM_VAULT_WEBHOOK_PATH;
|
|
7049
|
-
var init_chunk_5FO3GNKP = __esm({
|
|
7050
|
-
"../../packages/core/dist/chunk-5FO3GNKP.js"() {
|
|
7051
|
-
"use strict";
|
|
7052
|
-
DATA_PROXY_MOUNT = "/data";
|
|
7053
|
-
DATA_PROXY_PREFIX = `/api${DATA_PROXY_MOUNT}`;
|
|
7054
|
-
BASE_DESTRUCTION_MOUNT = "/bases";
|
|
7055
|
-
BASE_DESTRUCTION_PREFIX = `/api${BASE_DESTRUCTION_MOUNT}`;
|
|
7056
|
-
BASE_DESTRUCTION_CONFIRM_PATH = `${BASE_DESTRUCTION_PREFIX}/destruction/confirm`;
|
|
7057
|
-
COMMUNITY_EMAIL_UNSUBSCRIBE_PATH = "/api/communities/email-unsubscribe";
|
|
7058
|
-
CONTACT_BOOK_EMAIL_UNSUBSCRIBE_PATH = "/api/contact-book/email-unsubscribe";
|
|
7059
|
-
AUTOMATION_WEBHOOK_MOUNT = "/webhooks/automations";
|
|
7060
|
-
MANAGED_AGENTS_WEBHOOK_MOUNT = "/webhooks/managed-agents";
|
|
7061
|
-
TELEGRAM_VAULT_WEBHOOK_PATH = "/webhooks/telegram/vault";
|
|
7062
|
-
}
|
|
7063
|
-
});
|
|
7064
|
-
|
|
7065
|
-
// ../../packages/core/dist/chunk-AUD5MVHU.js
|
|
7066
|
-
function matchPath(pattern, path55) {
|
|
7067
|
-
const pathSegments2 = path55.replace(/\/$/, "").split("/");
|
|
7068
|
-
const isPrefix = pattern.endsWith("/*");
|
|
7069
|
-
const patternSegments = (isPrefix ? pattern.slice(0, -2) : pattern).split("/");
|
|
7070
|
-
if (isPrefix ? pathSegments2.length < patternSegments.length : pathSegments2.length !== patternSegments.length) {
|
|
7071
|
-
return false;
|
|
7072
|
-
}
|
|
7073
|
-
return patternSegments.every((segment2, i) => segment2 === "*" ? pathSegments2[i] !== "" : segment2 === pathSegments2[i]);
|
|
7074
|
-
}
|
|
7075
|
-
function getEndpointConfig(path55) {
|
|
7076
|
-
for (const excluded of EXCLUDED_PATHS) {
|
|
7077
|
-
if (matchPath(excluded, path55)) {
|
|
7078
|
-
return null;
|
|
7079
|
-
}
|
|
7080
|
-
}
|
|
7081
|
-
const normalizedPath = path55.replace(/\/$/, "");
|
|
7082
|
-
if (!normalizedPath.endsWith("/*") && Object.prototype.hasOwnProperty.call(ENDPOINT_CONFIGS, normalizedPath)) {
|
|
7083
|
-
return ENDPOINT_CONFIGS[normalizedPath];
|
|
7084
|
-
}
|
|
7085
|
-
const sortedPatterns = Object.keys(ENDPOINT_CONFIGS).sort((a, b) => b.length - a.length);
|
|
7086
|
-
for (const pattern of sortedPatterns) {
|
|
7087
|
-
if (matchPath(pattern, path55)) {
|
|
7088
|
-
return ENDPOINT_CONFIGS[pattern];
|
|
7089
|
-
}
|
|
7090
|
-
}
|
|
7091
|
-
return { tier: "STANDARD" };
|
|
7092
|
-
}
|
|
7093
|
-
var ENDPOINT_CONFIGS, EXCLUDED_PATHS;
|
|
7094
|
-
var init_chunk_AUD5MVHU = __esm({
|
|
7095
|
-
"../../packages/core/dist/chunk-AUD5MVHU.js"() {
|
|
6415
|
+
var ENDPOINT_CONFIGS, EXCLUDED_PATHS;
|
|
6416
|
+
var init_chunk_AUD5MVHU = __esm({
|
|
6417
|
+
"../../packages/core/dist/chunk-AUD5MVHU.js"() {
|
|
7096
6418
|
"use strict";
|
|
7097
6419
|
init_chunk_5FO3GNKP();
|
|
7098
6420
|
ENDPOINT_CONFIGS = {
|
|
@@ -7676,74 +6998,752 @@ var init_chunk_AUD5MVHU = __esm({
|
|
|
7676
6998
|
"/api/auth/session-check": { tier: "STANDARD", userLimit: 120, skipAuthenticatedUsers: true },
|
|
7677
6999
|
"/api/auth/logout": { tier: "MODERATE", userLimit: 10, failClosed: true, skipAuthenticatedUsers: true }
|
|
7678
7000
|
};
|
|
7679
|
-
EXCLUDED_PATHS = /* @__PURE__ */ new Set(["/health"]);
|
|
7001
|
+
EXCLUDED_PATHS = /* @__PURE__ */ new Set(["/health"]);
|
|
7002
|
+
}
|
|
7003
|
+
});
|
|
7004
|
+
|
|
7005
|
+
// ../../packages/core/dist/chunk-2IPHTFV5.js
|
|
7006
|
+
function fileSnapshotChanged(run) {
|
|
7007
|
+
return run.written + run.removed > 0;
|
|
7008
|
+
}
|
|
7009
|
+
async function runFileSnapshot(opts) {
|
|
7010
|
+
const run = { pages: 0, written: 0, removed: 0, unchanged: 0 };
|
|
7011
|
+
const seen = /* @__PURE__ */ new Set();
|
|
7012
|
+
let cursor;
|
|
7013
|
+
while (run.pages < FILE_SNAPSHOT_MAX_PAGES) {
|
|
7014
|
+
const page = await sendWithRetry(opts, cursor);
|
|
7015
|
+
run.pages++;
|
|
7016
|
+
run.written += page.written;
|
|
7017
|
+
run.removed += page.removed;
|
|
7018
|
+
run.unchanged += page.unchanged;
|
|
7019
|
+
opts.onPage?.(page, run.pages);
|
|
7020
|
+
if (page.next_cursor === null) return run;
|
|
7021
|
+
if (seen.has(page.next_cursor)) {
|
|
7022
|
+
throw new Error(`The preview file snapshot repeated its cursor after page ${run.pages}, so it would never end.`);
|
|
7023
|
+
}
|
|
7024
|
+
seen.add(page.next_cursor);
|
|
7025
|
+
cursor = page.next_cursor;
|
|
7026
|
+
}
|
|
7027
|
+
throw new Error(`The preview file snapshot did not end after ${FILE_SNAPSHOT_MAX_PAGES} pages.`);
|
|
7028
|
+
}
|
|
7029
|
+
async function sendWithRetry(opts, cursor) {
|
|
7030
|
+
for (let attempt = 1; ; attempt++) {
|
|
7031
|
+
let body;
|
|
7032
|
+
try {
|
|
7033
|
+
body = await opts.sendPage(cursor);
|
|
7034
|
+
} catch (error) {
|
|
7035
|
+
if (attempt < FILE_SNAPSHOT_CONFLICT_ATTEMPTS && opts.isConflict(error)) continue;
|
|
7036
|
+
throw error;
|
|
7037
|
+
}
|
|
7038
|
+
const parsed = rekorFileSnapshotAnswerSchema.safeParse(body);
|
|
7039
|
+
if (!parsed.success) {
|
|
7040
|
+
throw new Error("The data product answered a preview file snapshot page WayAI cannot read: nothing more was sent.");
|
|
7041
|
+
}
|
|
7042
|
+
return parsed.data.data;
|
|
7043
|
+
}
|
|
7044
|
+
}
|
|
7045
|
+
var rekorFileSnapshotAnswerSchema, FILE_SNAPSHOT_MAX_PAGES, FILE_SNAPSHOT_CONFLICT_ATTEMPTS, FILE_SNAPSHOT_PAGE_SPACING_MS, FILE_SNAPSHOT_CONFLICT_STATUS;
|
|
7046
|
+
var init_chunk_2IPHTFV5 = __esm({
|
|
7047
|
+
"../../packages/core/dist/chunk-2IPHTFV5.js"() {
|
|
7048
|
+
"use strict";
|
|
7049
|
+
init_chunk_AUD5MVHU();
|
|
7050
|
+
init_chunk_5FO3GNKP();
|
|
7051
|
+
init_zod();
|
|
7052
|
+
rekorFileSnapshotAnswerSchema = external_exports.object({
|
|
7053
|
+
data: external_exports.object({
|
|
7054
|
+
next_cursor: external_exports.string().nullable(),
|
|
7055
|
+
/** Files the page created or replaced on the preview. */
|
|
7056
|
+
written: external_exports.number().int(),
|
|
7057
|
+
/** The preview's own files, ones production does not hold, the page removed. */
|
|
7058
|
+
removed: external_exports.number().int(),
|
|
7059
|
+
/** Files the page found already equal to production's. */
|
|
7060
|
+
unchanged: external_exports.number().int()
|
|
7061
|
+
})
|
|
7062
|
+
});
|
|
7063
|
+
FILE_SNAPSHOT_MAX_PAGES = 1e4;
|
|
7064
|
+
FILE_SNAPSHOT_CONFLICT_ATTEMPTS = 3;
|
|
7065
|
+
FILE_SNAPSHOT_PAGE_SPACING_MS = Math.ceil(
|
|
7066
|
+
6e4 / Math.max(1, Math.floor((getEndpointConfig(`${DATA_PROXY_PREFIX}/files/snapshot`)?.userLimit ?? 60) * 4 / 5))
|
|
7067
|
+
);
|
|
7068
|
+
FILE_SNAPSHOT_CONFLICT_STATUS = 409;
|
|
7069
|
+
}
|
|
7070
|
+
});
|
|
7071
|
+
|
|
7072
|
+
// ../../packages/core/dist/chunk-IPDOHAZ5.js
|
|
7073
|
+
var reportSourceSchema, intakeReportSourceSchema, reportClassificationSchema, reportStatusSchema, reportLocaleSchema, reportMessageAuthorRoleSchema, reportMessageSchema, sentryRefStatusSchema, createReportBody, editReportBody, reporterReportSummarySchema, reporterListResponseSchema, getReportResponseSchema, reporterTransitionResponseSchema, contestReportBody, reporterListQuery, listReportsQuery, GITHUB_ISSUE_URL_REGEX, githubIssueUrlSchema, transitionReportBody, groupReportsBody, holdReportBody;
|
|
7074
|
+
var init_chunk_IPDOHAZ5 = __esm({
|
|
7075
|
+
"../../packages/core/dist/chunk-IPDOHAZ5.js"() {
|
|
7076
|
+
"use strict";
|
|
7077
|
+
init_chunk_HZ6CADSY();
|
|
7078
|
+
init_zod();
|
|
7079
|
+
reportSourceSchema = external_exports.enum(["sentry", "cli", "review", "security_audit"]);
|
|
7080
|
+
intakeReportSourceSchema = external_exports.enum(["cli", "review", "security_audit"]);
|
|
7081
|
+
reportClassificationSchema = external_exports.enum(["bug", "flaky_test", "security", "enhancement"]);
|
|
7082
|
+
reportStatusSchema = external_exports.enum([
|
|
7083
|
+
"pending",
|
|
7084
|
+
"grouped",
|
|
7085
|
+
"escalated",
|
|
7086
|
+
"shipped",
|
|
7087
|
+
"contested",
|
|
7088
|
+
"addressed",
|
|
7089
|
+
"dismissed"
|
|
7090
|
+
]);
|
|
7091
|
+
reportLocaleSchema = external_exports.enum(["en", "pt", "es"]);
|
|
7092
|
+
reportMessageAuthorRoleSchema = external_exports.enum(["reporter", "triage", "fixer", "system"]);
|
|
7093
|
+
reportMessageSchema = external_exports.object({
|
|
7094
|
+
message_id: external_exports.string(),
|
|
7095
|
+
author_role: reportMessageAuthorRoleSchema,
|
|
7096
|
+
/** The status transition this note accompanied (e.g. 'shipped'); null for a free/system note. */
|
|
7097
|
+
transition: external_exports.string().nullable(),
|
|
7098
|
+
body: external_exports.string(),
|
|
7099
|
+
created_at: timestampSchema,
|
|
7100
|
+
/**
|
|
7101
|
+
* Visibility: `false` = reporter-facing (the default for every narrative entry); `true` =
|
|
7102
|
+
* triage-internal (e.g. a `hold` rationale) — surfaced to platform admins only and NEVER
|
|
7103
|
+
* returned on the reporter read path. The reporter's `GET /api/reports/:id` filters these out.
|
|
7104
|
+
*/
|
|
7105
|
+
internal: external_exports.boolean()
|
|
7106
|
+
});
|
|
7107
|
+
sentryRefStatusSchema = external_exports.enum(["valid", "not_found", "mismatch", "unverified"]);
|
|
7108
|
+
createReportBody = external_exports.object({
|
|
7109
|
+
title: external_exports.string().min(5).max(256),
|
|
7110
|
+
description: external_exports.string().min(10).max(5e3),
|
|
7111
|
+
steps_to_reproduce: external_exports.string().max(3e3).optional(),
|
|
7112
|
+
error_message: external_exports.string().max(2e3).optional(),
|
|
7113
|
+
// Taxonomy (server defaults: source=cli, classification=bug when absent).
|
|
7114
|
+
source: intakeReportSourceSchema.optional(),
|
|
7115
|
+
classification: reportClassificationSchema.optional(),
|
|
7116
|
+
// Stable dedup key (e.g. "<file>::<test>" for flaky, "<file>:<line>" for
|
|
7117
|
+
// security). When present, the fingerprint uses it instead of the body hash.
|
|
7118
|
+
dedup_key: external_exports.string().min(1).max(256).optional(),
|
|
7119
|
+
// Context fields (auto-captured by the CLI)
|
|
7120
|
+
organization_id: external_exports.string().optional(),
|
|
7121
|
+
hub_id: external_exports.string().uuid().optional(),
|
|
7122
|
+
hub_name: external_exports.string().max(256).optional(),
|
|
7123
|
+
conversation_id: external_exports.string().uuid().optional(),
|
|
7124
|
+
agent_id: external_exports.string().uuid().optional(),
|
|
7125
|
+
agent_name: external_exports.string().max(256).optional(),
|
|
7126
|
+
client_version: external_exports.string().max(64).optional(),
|
|
7127
|
+
additional_context: external_exports.string().max(2e3).optional()
|
|
7128
|
+
});
|
|
7129
|
+
editReportBody = external_exports.object({
|
|
7130
|
+
title: external_exports.string().min(5).max(256).optional(),
|
|
7131
|
+
description: external_exports.string().min(10).max(5e3).optional(),
|
|
7132
|
+
steps_to_reproduce: external_exports.string().max(3e3).optional(),
|
|
7133
|
+
error_message: external_exports.string().max(2e3).optional(),
|
|
7134
|
+
additional_context: external_exports.string().max(2e3).optional()
|
|
7135
|
+
}).strict().refine((b) => Object.keys(b).length > 0, {
|
|
7136
|
+
message: "at least one field must be provided"
|
|
7137
|
+
});
|
|
7138
|
+
reporterReportSummarySchema = external_exports.object({
|
|
7139
|
+
report_id: external_exports.string(),
|
|
7140
|
+
title: external_exports.string(),
|
|
7141
|
+
description: external_exports.string(),
|
|
7142
|
+
classification: reportClassificationSchema,
|
|
7143
|
+
status: reportStatusSchema,
|
|
7144
|
+
created_at: timestampSchema,
|
|
7145
|
+
triaged_at: timestampSchema.nullable(),
|
|
7146
|
+
resolved_at: timestampSchema.nullable(),
|
|
7147
|
+
/** How many times the reporter has contested (gates the hard cap). */
|
|
7148
|
+
contest_count: external_exports.number(),
|
|
7149
|
+
/** True once triage issued a non-contestable (final) dismissal. */
|
|
7150
|
+
dismissal_final: external_exports.boolean()
|
|
7151
|
+
});
|
|
7152
|
+
reporterListResponseSchema = external_exports.object({
|
|
7153
|
+
data: external_exports.array(reporterReportSummarySchema)
|
|
7154
|
+
});
|
|
7155
|
+
getReportResponseSchema = external_exports.object({
|
|
7156
|
+
report: reporterReportSummarySchema,
|
|
7157
|
+
messages: external_exports.array(reportMessageSchema)
|
|
7158
|
+
});
|
|
7159
|
+
reporterTransitionResponseSchema = external_exports.object({
|
|
7160
|
+
report: reporterReportSummarySchema
|
|
7161
|
+
});
|
|
7162
|
+
contestReportBody = external_exports.object({
|
|
7163
|
+
reason: external_exports.string().min(1).max(5e3)
|
|
7164
|
+
});
|
|
7165
|
+
reporterListQuery = external_exports.object({
|
|
7166
|
+
status: reportStatusSchema.optional()
|
|
7167
|
+
});
|
|
7168
|
+
listReportsQuery = external_exports.object({
|
|
7169
|
+
status: reportStatusSchema.optional(),
|
|
7170
|
+
source: reportSourceSchema.optional(),
|
|
7171
|
+
limit: external_exports.coerce.number().int().min(1).max(200).optional(),
|
|
7172
|
+
offset: external_exports.coerce.number().int().min(0).optional(),
|
|
7173
|
+
/** ISO 8601 lower bound on created_at. */
|
|
7174
|
+
since: external_exports.string().datetime().optional(),
|
|
7175
|
+
/**
|
|
7176
|
+
* ISO 8601 lower bound on resolution time — "what did we resolve recently", which `since`
|
|
7177
|
+
* (a created_at filter) cannot answer for a long-lived report resolved yesterday. Implies
|
|
7178
|
+
* a terminal status (`addressed`/`dismissed`) and orders on that same axis.
|
|
7179
|
+
*/
|
|
7180
|
+
resolved_since: external_exports.string().datetime().optional()
|
|
7181
|
+
});
|
|
7182
|
+
GITHUB_ISSUE_URL_REGEX = /^https:\/\/github\.com\/[^/]+\/[^/]+\/issues\/\d+(?:[/?#]|$)/;
|
|
7183
|
+
githubIssueUrlSchema = external_exports.string().url().refine((u) => GITHUB_ISSUE_URL_REGEX.test(u), {
|
|
7184
|
+
message: "must be an https://github.com/<owner>/<repo>/issues/<number> URL"
|
|
7185
|
+
});
|
|
7186
|
+
transitionReportBody = external_exports.discriminatedUnion("target", [
|
|
7187
|
+
external_exports.object({
|
|
7188
|
+
target: external_exports.literal("escalated"),
|
|
7189
|
+
gh_issue_url: githubIssueUrlSchema,
|
|
7190
|
+
ai_verdict: external_exports.string().max(2e3).optional()
|
|
7191
|
+
}),
|
|
7192
|
+
external_exports.object({
|
|
7193
|
+
target: external_exports.literal("shipped"),
|
|
7194
|
+
note: external_exports.string().min(1).max(2e3).optional()
|
|
7195
|
+
}),
|
|
7196
|
+
external_exports.object({
|
|
7197
|
+
target: external_exports.literal("addressed")
|
|
7198
|
+
}),
|
|
7199
|
+
external_exports.object({
|
|
7200
|
+
target: external_exports.literal("dismissed"),
|
|
7201
|
+
dismissal_reason: external_exports.string().min(1).max(5e3),
|
|
7202
|
+
ai_verdict: external_exports.string().max(2e3).optional(),
|
|
7203
|
+
final: external_exports.boolean().optional()
|
|
7204
|
+
})
|
|
7205
|
+
]);
|
|
7206
|
+
groupReportsBody = external_exports.object({
|
|
7207
|
+
member_ids: external_exports.array(external_exports.string().uuid()).min(1).max(100)
|
|
7208
|
+
});
|
|
7209
|
+
holdReportBody = external_exports.object({
|
|
7210
|
+
reason: external_exports.string().min(1).max(5e3)
|
|
7211
|
+
});
|
|
7212
|
+
}
|
|
7213
|
+
});
|
|
7214
|
+
|
|
7215
|
+
// ../../packages/core/dist/chunk-KEN2DASI.js
|
|
7216
|
+
var SECOND_FACTOR_TIERS, secondFactorTier, META_ENTITY_ID_PATTERN, metaEntityId, whatsappCallbackBody, authMeResponse, wsTicketResponse, sessionCheckResponse, logoutResponse, magicCodeSendBody, magicCodeSendResponse, magicCodeVerifyBody, magicCodeVerifyResponse, passwordLoginBody, normalizeEmail, REVIEW_ACCOUNT_EMAILS;
|
|
7217
|
+
var init_chunk_KEN2DASI = __esm({
|
|
7218
|
+
"../../packages/core/dist/chunk-KEN2DASI.js"() {
|
|
7219
|
+
"use strict";
|
|
7220
|
+
init_zod();
|
|
7221
|
+
SECOND_FACTOR_TIERS = ["off", "settings"];
|
|
7222
|
+
secondFactorTier = external_exports.enum(SECOND_FACTOR_TIERS);
|
|
7223
|
+
META_ENTITY_ID_PATTERN = /^\d{1,32}$/;
|
|
7224
|
+
metaEntityId = external_exports.string().regex(META_ENTITY_ID_PATTERN, "must be a numeric Meta entity id");
|
|
7225
|
+
whatsappCallbackBody = external_exports.object({
|
|
7226
|
+
state: external_exports.string().min(1, "state is required"),
|
|
7227
|
+
code: external_exports.string().optional(),
|
|
7228
|
+
access_token: external_exports.string().optional(),
|
|
7229
|
+
user_id: external_exports.string().optional(),
|
|
7230
|
+
/**
|
|
7231
|
+
* The phone number and WABA the operator actually picked in Meta's Embedded
|
|
7232
|
+
* Signup popup (posted to the opener as `WA_EMBEDDED_SIGNUP`). Optional:
|
|
7233
|
+
* older clients, and the redirect-based flow, never see that event and fall
|
|
7234
|
+
* back to discovery.
|
|
7235
|
+
*/
|
|
7236
|
+
phone_number_id: metaEntityId.optional(),
|
|
7237
|
+
waba_id: metaEntityId.optional()
|
|
7238
|
+
}).refine(
|
|
7239
|
+
(data) => !!data.access_token || !!data.code,
|
|
7240
|
+
{ message: "Missing required parameters: state and either access_token or code" }
|
|
7241
|
+
);
|
|
7242
|
+
authMeResponse = external_exports.object({
|
|
7243
|
+
user_id: external_exports.string(),
|
|
7244
|
+
email: external_exports.string(),
|
|
7245
|
+
org_id: external_exports.string().nullable(),
|
|
7246
|
+
is_platform_admin: external_exports.boolean()
|
|
7247
|
+
});
|
|
7248
|
+
wsTicketResponse = external_exports.object({
|
|
7249
|
+
ticket: external_exports.string(),
|
|
7250
|
+
/** Seconds until the ticket expires if unconsumed. */
|
|
7251
|
+
expires_in: external_exports.number()
|
|
7252
|
+
});
|
|
7253
|
+
sessionCheckResponse = external_exports.object({
|
|
7254
|
+
valid: external_exports.literal(true)
|
|
7255
|
+
});
|
|
7256
|
+
logoutResponse = external_exports.object({
|
|
7257
|
+
success: external_exports.literal(true)
|
|
7258
|
+
});
|
|
7259
|
+
magicCodeSendBody = external_exports.object({
|
|
7260
|
+
email: external_exports.string().email("Invalid email").max(254)
|
|
7261
|
+
// RFC 5321 max; bounds the request payload
|
|
7262
|
+
});
|
|
7263
|
+
magicCodeSendResponse = external_exports.object({
|
|
7264
|
+
success: external_exports.literal(true)
|
|
7265
|
+
});
|
|
7266
|
+
magicCodeVerifyBody = external_exports.object({
|
|
7267
|
+
email: external_exports.string().email("Invalid email").max(254),
|
|
7268
|
+
// RFC 5321 max; bounds the request payload
|
|
7269
|
+
code: external_exports.string().min(1, "Code is required").max(12)
|
|
7270
|
+
// WorkOS sends a 6-digit code; bound the input
|
|
7271
|
+
});
|
|
7272
|
+
magicCodeVerifyResponse = external_exports.object({
|
|
7273
|
+
access_token: external_exports.string(),
|
|
7274
|
+
refresh_token: external_exports.string()
|
|
7275
|
+
});
|
|
7276
|
+
passwordLoginBody = external_exports.object({
|
|
7277
|
+
email: external_exports.string().email("Invalid email").max(254),
|
|
7278
|
+
// RFC 5321 max; bounds the request payload
|
|
7279
|
+
password: external_exports.string().min(1, "Password is required").max(128)
|
|
7280
|
+
// bound the payload; WorkOS validates
|
|
7281
|
+
});
|
|
7282
|
+
normalizeEmail = (email) => email.trim().toLowerCase();
|
|
7283
|
+
REVIEW_ACCOUNT_EMAILS = new Set(
|
|
7284
|
+
["apple.review@wayai.pro", "play.review@wayai.pro", "microsoft.review@wayai.pro", "meta.review@wayai.pro"].map(
|
|
7285
|
+
normalizeEmail
|
|
7286
|
+
)
|
|
7287
|
+
);
|
|
7288
|
+
}
|
|
7289
|
+
});
|
|
7290
|
+
|
|
7291
|
+
// ../../packages/core/dist/chunk-PFGVH2CX.js
|
|
7292
|
+
var secondFactorCode, secondFactorRecoveryCode, secondFactorCodeBody, secondFactorRecoveryBody, secondFactorDisableBody, setOrgSecondFactorBody;
|
|
7293
|
+
var init_chunk_PFGVH2CX = __esm({
|
|
7294
|
+
"../../packages/core/dist/chunk-PFGVH2CX.js"() {
|
|
7295
|
+
"use strict";
|
|
7296
|
+
init_chunk_KEN2DASI();
|
|
7297
|
+
init_zod();
|
|
7298
|
+
secondFactorCode = external_exports.string().regex(/^\d{6}$/, "Enter the 6-digit code");
|
|
7299
|
+
secondFactorRecoveryCode = external_exports.string().min(1, "Enter a recovery code").max(64);
|
|
7300
|
+
secondFactorCodeBody = external_exports.object({ code: secondFactorCode });
|
|
7301
|
+
secondFactorRecoveryBody = external_exports.object({ recovery_code: secondFactorRecoveryCode });
|
|
7302
|
+
secondFactorDisableBody = external_exports.union([
|
|
7303
|
+
external_exports.object({ code: secondFactorCode, recovery_code: external_exports.undefined().optional() }),
|
|
7304
|
+
external_exports.object({ recovery_code: secondFactorRecoveryCode, code: external_exports.undefined().optional() })
|
|
7305
|
+
]);
|
|
7306
|
+
setOrgSecondFactorBody = external_exports.object({ tier: secondFactorTier });
|
|
7307
|
+
}
|
|
7308
|
+
});
|
|
7309
|
+
|
|
7310
|
+
// ../../packages/core/dist/chunk-TVUDMGWV.js
|
|
7311
|
+
var bootstrapQuery;
|
|
7312
|
+
var init_chunk_TVUDMGWV = __esm({
|
|
7313
|
+
"../../packages/core/dist/chunk-TVUDMGWV.js"() {
|
|
7314
|
+
"use strict";
|
|
7315
|
+
init_zod();
|
|
7316
|
+
bootstrapQuery = external_exports.object({
|
|
7317
|
+
active_hub_id: external_exports.string().uuid().optional(),
|
|
7318
|
+
active_conversation_id: external_exports.string().uuid().optional(),
|
|
7319
|
+
active_nav: external_exports.enum(["chat", "task", "support"]).optional(),
|
|
7320
|
+
/**
|
|
7321
|
+
* The people thread the URL names (`/chat/threads/:threadId`, gh #4661): the snapshot
|
|
7322
|
+
* preloads it as `people.active_thread` when the viewer is a member.
|
|
7323
|
+
*/
|
|
7324
|
+
active_thread_id: external_exports.string().uuid().optional()
|
|
7325
|
+
});
|
|
7326
|
+
}
|
|
7327
|
+
});
|
|
7328
|
+
|
|
7329
|
+
// ../../packages/core/dist/chunk-S4HVRNEQ.js
|
|
7330
|
+
var PERMISSIONS;
|
|
7331
|
+
var init_chunk_S4HVRNEQ = __esm({
|
|
7332
|
+
"../../packages/core/dist/chunk-S4HVRNEQ.js"() {
|
|
7333
|
+
"use strict";
|
|
7334
|
+
PERMISSIONS = [
|
|
7335
|
+
"hub:read",
|
|
7336
|
+
"hub:write",
|
|
7337
|
+
"hub:admin",
|
|
7338
|
+
"conversation:read",
|
|
7339
|
+
"conversation:write",
|
|
7340
|
+
"analytics:read",
|
|
7341
|
+
"billing:read",
|
|
7342
|
+
"billing:write",
|
|
7343
|
+
"org:read",
|
|
7344
|
+
"org:write",
|
|
7345
|
+
"org:admin",
|
|
7346
|
+
"contacts:write",
|
|
7347
|
+
"platform:admin",
|
|
7348
|
+
"*"
|
|
7349
|
+
];
|
|
7350
|
+
}
|
|
7351
|
+
});
|
|
7352
|
+
|
|
7353
|
+
// ../../packages/core/dist/chunk-WTIGECE5.js
|
|
7354
|
+
var MAX_NAME_LENGTH, MAX_HUBS_PER_GRANT, MAX_HUB_TAGS_PER_GRANT, MAX_GRANTS, permissionEnum, grantScopeSchema, grantSchema, createTokenBody, tokenOrgIdParam;
|
|
7355
|
+
var init_chunk_WTIGECE5 = __esm({
|
|
7356
|
+
"../../packages/core/dist/chunk-WTIGECE5.js"() {
|
|
7357
|
+
"use strict";
|
|
7358
|
+
init_chunk_S4HVRNEQ();
|
|
7359
|
+
init_chunk_HZ6CADSY();
|
|
7360
|
+
init_zod();
|
|
7361
|
+
MAX_NAME_LENGTH = 100;
|
|
7362
|
+
MAX_HUBS_PER_GRANT = 50;
|
|
7363
|
+
MAX_HUB_TAGS_PER_GRANT = 20;
|
|
7364
|
+
MAX_GRANTS = 20;
|
|
7365
|
+
permissionEnum = external_exports.enum(PERMISSIONS).refine(
|
|
7366
|
+
(p) => p !== "platform:admin",
|
|
7367
|
+
{ message: "platform:admin cannot be delegated via token creation" }
|
|
7368
|
+
);
|
|
7369
|
+
grantScopeSchema = external_exports.object({
|
|
7370
|
+
// Required: every token grant must declare its org tenancy. The handler
|
|
7371
|
+
// also strict-checks this as defense-in-depth, but failing at the Zod
|
|
7372
|
+
// boundary keeps the generated client type honest (org_id: string).
|
|
7373
|
+
org_id: external_exports.string().min(1),
|
|
7374
|
+
hubs: external_exports.array(external_exports.string().min(1)).min(1, "Each grant must have scope.hubs as a non-empty array").max(MAX_HUBS_PER_GRANT),
|
|
7375
|
+
hub_tags: external_exports.array(external_exports.string().min(1)).min(1, "scope.hub_tags must be a non-empty array if provided").max(MAX_HUB_TAGS_PER_GRANT).optional(),
|
|
7376
|
+
environments: external_exports.array(external_exports.enum(["production", "preview"])).min(1, "scope.environments must be a non-empty array if provided").optional()
|
|
7377
|
+
}).strict();
|
|
7378
|
+
grantSchema = external_exports.object({
|
|
7379
|
+
scope: grantScopeSchema,
|
|
7380
|
+
permissions: external_exports.array(permissionEnum).min(1, "Each grant must have permissions as a non-empty array")
|
|
7381
|
+
}).strict();
|
|
7382
|
+
createTokenBody = external_exports.object({
|
|
7383
|
+
name: external_exports.string().trim().min(1, "name is required").max(MAX_NAME_LENGTH, `name must be ${MAX_NAME_LENGTH} characters or fewer`),
|
|
7384
|
+
grants: external_exports.array(grantSchema).min(1, "grants must be a non-empty array").max(MAX_GRANTS),
|
|
7385
|
+
expires_at: external_exports.string().datetime({ message: "expires_at must be a valid ISO 8601 date" }).refine(
|
|
7386
|
+
(s) => new Date(s).getTime() > Date.now(),
|
|
7387
|
+
{ message: "expires_at must be in the future" }
|
|
7388
|
+
).optional()
|
|
7389
|
+
});
|
|
7390
|
+
tokenOrgIdParam = external_exports.object({ orgId: uuidSchema });
|
|
7391
|
+
}
|
|
7392
|
+
});
|
|
7393
|
+
|
|
7394
|
+
// ../../packages/core/dist/chunk-ZVXO3XL6.js
|
|
7395
|
+
var PEOPLE_CONTACT_PAGE_MAX, PEOPLE_CONTACT_PAGE_DEFAULT, PEOPLE_CONTACT_EMAIL_MAX_LENGTH, peopleUserIdSchema, peopleInviteEmailSchema, peopleContactInviteBody, peopleContactInviteIdParam, peopleContactUserIdParam, peopleContactBlockBody, peopleContactPageQuery, peopleOutgoingInviteSchema, peopleContactPersonSchema, peopleContactSchema, peopleIncomingInviteSchema, peopleBlockedUserSchema;
|
|
7396
|
+
var init_chunk_ZVXO3XL6 = __esm({
|
|
7397
|
+
"../../packages/core/dist/chunk-ZVXO3XL6.js"() {
|
|
7398
|
+
"use strict";
|
|
7399
|
+
init_chunk_HZ6CADSY();
|
|
7400
|
+
init_zod();
|
|
7401
|
+
PEOPLE_CONTACT_PAGE_MAX = 100;
|
|
7402
|
+
PEOPLE_CONTACT_PAGE_DEFAULT = 50;
|
|
7403
|
+
PEOPLE_CONTACT_EMAIL_MAX_LENGTH = 254;
|
|
7404
|
+
peopleUserIdSchema = external_exports.string().max(64).regex(USER_ID_REGEX, "must be a user id");
|
|
7405
|
+
peopleInviteEmailSchema = external_exports.string().trim().max(PEOPLE_CONTACT_EMAIL_MAX_LENGTH).email();
|
|
7406
|
+
peopleContactInviteBody = external_exports.object({
|
|
7407
|
+
email: peopleInviteEmailSchema
|
|
7408
|
+
}).strict();
|
|
7409
|
+
peopleContactInviteIdParam = external_exports.object({ inviteId: uuidSchema });
|
|
7410
|
+
peopleContactUserIdParam = external_exports.object({ userId: peopleUserIdSchema });
|
|
7411
|
+
peopleContactBlockBody = external_exports.object({ user_id: peopleUserIdSchema, thread_id: uuidSchema.optional(), community_id: uuidSchema.optional() }).strict().refine((body) => body.thread_id === void 0 || body.community_id === void 0, {
|
|
7412
|
+
message: "Name a thread or a community, not both",
|
|
7413
|
+
path: ["community_id"]
|
|
7414
|
+
});
|
|
7415
|
+
peopleContactPageQuery = external_exports.object({
|
|
7416
|
+
cursor: external_exports.string().min(1).max(256).optional(),
|
|
7417
|
+
limit: external_exports.coerce.number().int().min(1).max(PEOPLE_CONTACT_PAGE_MAX).default(PEOPLE_CONTACT_PAGE_DEFAULT)
|
|
7418
|
+
});
|
|
7419
|
+
peopleOutgoingInviteSchema = external_exports.object({
|
|
7420
|
+
invite_id: uuidSchema,
|
|
7421
|
+
email: external_exports.string(),
|
|
7422
|
+
status: external_exports.literal("sent"),
|
|
7423
|
+
created_at: timestampSchema,
|
|
7424
|
+
expires_at: timestampSchema
|
|
7425
|
+
}).strict();
|
|
7426
|
+
peopleContactPersonSchema = external_exports.object({
|
|
7427
|
+
user_id: peopleUserIdSchema,
|
|
7428
|
+
display_name: external_exports.string().nullable(),
|
|
7429
|
+
email: external_exports.string().nullable()
|
|
7430
|
+
}).strict();
|
|
7431
|
+
peopleContactSchema = peopleContactPersonSchema.extend({ contact_since: timestampSchema, thread_id: uuidSchema }).strict();
|
|
7432
|
+
peopleIncomingInviteSchema = external_exports.object({
|
|
7433
|
+
invite_id: uuidSchema,
|
|
7434
|
+
inviter: peopleContactPersonSchema,
|
|
7435
|
+
created_at: timestampSchema,
|
|
7436
|
+
expires_at: timestampSchema
|
|
7437
|
+
}).strict();
|
|
7438
|
+
peopleBlockedUserSchema = peopleContactPersonSchema.extend({ blocked_at: timestampSchema, deleted_user: external_exports.boolean() }).strict();
|
|
7439
|
+
}
|
|
7440
|
+
});
|
|
7441
|
+
|
|
7442
|
+
// ../../packages/core/dist/chunk-ZXK6N2HN.js
|
|
7443
|
+
var PEOPLE_MODERATION_NOTE_MAX_LENGTH, ADMIN_PEOPLE_REPORTS_PAGE_MAX, ADMIN_PEOPLE_REPORTS_PAGE_DEFAULT, PEOPLE_SUSPENDED_REASON, peopleModerationActionSchema, moderationNoteSchema, adminPeopleReportListQuery, adminPeopleReportIdParam, adminPeopleMessageRemovalBody, adminPeopleSuspendBody, adminPeopleNoteBody;
|
|
7444
|
+
var init_chunk_ZXK6N2HN = __esm({
|
|
7445
|
+
"../../packages/core/dist/chunk-ZXK6N2HN.js"() {
|
|
7446
|
+
"use strict";
|
|
7447
|
+
init_chunk_ZVXO3XL6();
|
|
7448
|
+
init_chunk_HZ6CADSY();
|
|
7449
|
+
init_zod();
|
|
7450
|
+
PEOPLE_MODERATION_NOTE_MAX_LENGTH = 500;
|
|
7451
|
+
ADMIN_PEOPLE_REPORTS_PAGE_MAX = 100;
|
|
7452
|
+
ADMIN_PEOPLE_REPORTS_PAGE_DEFAULT = 50;
|
|
7453
|
+
PEOPLE_SUSPENDED_REASON = "suspended";
|
|
7454
|
+
peopleModerationActionSchema = external_exports.enum(["remove_message", "suspend", "unsuspend", "dismiss"]);
|
|
7455
|
+
moderationNoteSchema = optionalTrimmedText(PEOPLE_MODERATION_NOTE_MAX_LENGTH);
|
|
7456
|
+
adminPeopleReportListQuery = external_exports.object({
|
|
7457
|
+
pending: external_exports.enum(["true", "false"]).optional().transform((value) => value === "true"),
|
|
7458
|
+
/** Lower bound on `created_at`. */
|
|
7459
|
+
since: timestampSchema.optional(),
|
|
7460
|
+
limit: external_exports.coerce.number().int().min(1).max(ADMIN_PEOPLE_REPORTS_PAGE_MAX).default(ADMIN_PEOPLE_REPORTS_PAGE_DEFAULT),
|
|
7461
|
+
offset: external_exports.coerce.number().int().min(0).default(0)
|
|
7462
|
+
});
|
|
7463
|
+
adminPeopleReportIdParam = external_exports.object({ reportId: uuidSchema });
|
|
7464
|
+
adminPeopleMessageRemovalBody = external_exports.object({ report_id: uuidSchema, message_id: uuidSchema.optional(), note: moderationNoteSchema }).strict();
|
|
7465
|
+
adminPeopleSuspendBody = external_exports.object({ report_id: uuidSchema.optional(), note: moderationNoteSchema }).strict();
|
|
7466
|
+
adminPeopleNoteBody = external_exports.object({ note: moderationNoteSchema }).strict();
|
|
7467
|
+
}
|
|
7468
|
+
});
|
|
7469
|
+
|
|
7470
|
+
// ../../packages/core/dist/chunk-Y7CFCYX4.js
|
|
7471
|
+
var PEOPLE_REPORT_DETAILS_MAX_LENGTH, peopleReportReasonSchema, reportDetailsSchema, reportFields, peopleReportBody;
|
|
7472
|
+
var init_chunk_Y7CFCYX4 = __esm({
|
|
7473
|
+
"../../packages/core/dist/chunk-Y7CFCYX4.js"() {
|
|
7474
|
+
"use strict";
|
|
7475
|
+
init_chunk_ZVXO3XL6();
|
|
7476
|
+
init_chunk_HZ6CADSY();
|
|
7477
|
+
init_zod();
|
|
7478
|
+
PEOPLE_REPORT_DETAILS_MAX_LENGTH = 500;
|
|
7479
|
+
peopleReportReasonSchema = external_exports.enum(["spam", "harassment", "hate", "sexual", "violence", "other"]);
|
|
7480
|
+
reportDetailsSchema = optionalTrimmedText(PEOPLE_REPORT_DETAILS_MAX_LENGTH);
|
|
7481
|
+
reportFields = { reason: peopleReportReasonSchema, details: reportDetailsSchema };
|
|
7482
|
+
peopleReportBody = external_exports.discriminatedUnion("target", [
|
|
7483
|
+
external_exports.object({ target: external_exports.literal("message"), thread_id: uuidSchema, message_id: uuidSchema, ...reportFields }).strict(),
|
|
7484
|
+
external_exports.object({ target: external_exports.literal("thread"), thread_id: uuidSchema, ...reportFields }).strict(),
|
|
7485
|
+
external_exports.object({ target: external_exports.literal("user"), user_id: peopleUserIdSchema, thread_id: uuidSchema.optional(), ...reportFields }).strict(),
|
|
7486
|
+
external_exports.object({
|
|
7487
|
+
target: external_exports.literal("community_message"),
|
|
7488
|
+
community_id: uuidSchema,
|
|
7489
|
+
room_id: uuidSchema,
|
|
7490
|
+
message_id: uuidSchema,
|
|
7491
|
+
...reportFields
|
|
7492
|
+
}).strict(),
|
|
7493
|
+
external_exports.object({ target: external_exports.literal("community_member"), community_id: uuidSchema, user_id: peopleUserIdSchema, ...reportFields }).strict()
|
|
7494
|
+
]);
|
|
7495
|
+
}
|
|
7496
|
+
});
|
|
7497
|
+
|
|
7498
|
+
// ../../packages/core/dist/chunk-UAOHHCW5.js
|
|
7499
|
+
function normalizeContactPhone(raw) {
|
|
7500
|
+
const compact = raw.trim().replace(/[\s\-.()]/g, "");
|
|
7501
|
+
const withPlus = compact.startsWith("00") ? `+${compact.slice(2)}` : compact;
|
|
7502
|
+
return /^\+[1-9]\d{7,14}$/.test(withPlus) ? withPlus : null;
|
|
7503
|
+
}
|
|
7504
|
+
function normalizeContactLabel(raw) {
|
|
7505
|
+
return raw.trim().replace(/\s+/g, " ").toLowerCase();
|
|
7506
|
+
}
|
|
7507
|
+
function importRowLabels(row, batchLabels) {
|
|
7508
|
+
return [.../* @__PURE__ */ new Set([...row.labels ?? [], ...batchLabels ?? []])];
|
|
7509
|
+
}
|
|
7510
|
+
var CONTACT_ENVIRONMENTS, CONTACT_NAME_MAX, CONTACT_EMAIL_MAX, CONTACT_PHONE_INPUT_MAX, CONTACT_INSTAGRAM_SID_MAX, CONTACT_METADATA_MAX_BYTES, CONTACT_LABEL_MAX, CONTACT_LABELS_MAX, CONTACT_SCOPE_TAGS_MAX, CONTACT_PAGE_MAX, CONTACT_IMPORT_BATCH_MAX, CONTACT_SEARCH_MAX, CONTACT_LIST_NAME_MAX, CONTACT_LIST_NAME_REGEX, CONTACT_LIST_DESCRIPTION_MAX, CONTACT_LIST_FILTER_MAX, CONTACT_LIST_PINS_PER_REQUEST_MAX, SUPPRESSION_SCOPES, SUPPRESSION_ID_REGEX, contactName, contactPhone, contactEmail, contactInstagramSid, contactLabel, contactLabels, contactMetadata, scopeTagIds, contactVisibilitySchema, hasIdentity, IDENTITY_REQUIRED, contactBookOrgQuery, contactBookContactParam, contactBookListParam, contactBookHubParam, contactBookPageQuery, listContactBookContactsQuery, listHubContactBookContactsQuery, contactBookLinkCandidatesQuery, listContactBookListMembersQuery, contactRowFields, createContactBookContactBody, updateContactBookContactBody, contactImportRowSchema, importContactBookContactsBody, linkContactBookContactBody, listName, contactListFilterSchema, createContactBookListBody, updateContactBookListBody, updateContactBookListPinsBody, suppressionIdentitySchema, createContactBookSuppressionBody, contactBookSuppressionParam, listContactBookSuppressionsQuery, contactBookEmailUnsubscribeTokenSchema, contactBookEmailUnsubscribeQuery, orgListReferenceSchema;
|
|
7511
|
+
var init_chunk_UAOHHCW5 = __esm({
|
|
7512
|
+
"../../packages/core/dist/chunk-UAOHHCW5.js"() {
|
|
7513
|
+
"use strict";
|
|
7514
|
+
init_zod();
|
|
7515
|
+
CONTACT_ENVIRONMENTS = ["production", "preview", "all"];
|
|
7516
|
+
CONTACT_NAME_MAX = 200;
|
|
7517
|
+
CONTACT_EMAIL_MAX = 320;
|
|
7518
|
+
CONTACT_PHONE_INPUT_MAX = 40;
|
|
7519
|
+
CONTACT_INSTAGRAM_SID_MAX = 64;
|
|
7520
|
+
CONTACT_METADATA_MAX_BYTES = 4096;
|
|
7521
|
+
CONTACT_LABEL_MAX = 64;
|
|
7522
|
+
CONTACT_LABELS_MAX = 20;
|
|
7523
|
+
CONTACT_SCOPE_TAGS_MAX = 20;
|
|
7524
|
+
CONTACT_PAGE_MAX = 100;
|
|
7525
|
+
CONTACT_IMPORT_BATCH_MAX = 500;
|
|
7526
|
+
CONTACT_SEARCH_MAX = 100;
|
|
7527
|
+
CONTACT_LIST_NAME_MAX = 64;
|
|
7528
|
+
CONTACT_LIST_NAME_REGEX = /^[a-z0-9]+(-[a-z0-9]+)*$/;
|
|
7529
|
+
CONTACT_LIST_DESCRIPTION_MAX = 1e3;
|
|
7530
|
+
CONTACT_LIST_FILTER_MAX = 20;
|
|
7531
|
+
CONTACT_LIST_PINS_PER_REQUEST_MAX = 100;
|
|
7532
|
+
SUPPRESSION_SCOPES = ["all", "marketing"];
|
|
7533
|
+
SUPPRESSION_ID_REGEX = /^[0-9a-f]{64}$/;
|
|
7534
|
+
contactName = external_exports.string().trim().min(1).max(CONTACT_NAME_MAX);
|
|
7535
|
+
contactPhone = external_exports.string().max(CONTACT_PHONE_INPUT_MAX).transform((raw, ctx) => {
|
|
7536
|
+
const phone = normalizeContactPhone(raw);
|
|
7537
|
+
if (phone === null) {
|
|
7538
|
+
ctx.addIssue({ code: external_exports.ZodIssueCode.custom, message: "Phone must be an international number, e.g. +5511999999999" });
|
|
7539
|
+
return external_exports.NEVER;
|
|
7540
|
+
}
|
|
7541
|
+
return phone;
|
|
7542
|
+
});
|
|
7543
|
+
contactEmail = external_exports.string().trim().toLowerCase().max(CONTACT_EMAIL_MAX).email();
|
|
7544
|
+
contactInstagramSid = external_exports.string().trim().min(1).max(CONTACT_INSTAGRAM_SID_MAX);
|
|
7545
|
+
contactLabel = external_exports.string().max(CONTACT_LABEL_MAX).transform(normalizeContactLabel).refine((label3) => label3.length > 0, "A label cannot be empty").refine((label3) => !label3.includes(","), "A label cannot contain a comma");
|
|
7546
|
+
contactLabels = external_exports.array(contactLabel).max(CONTACT_LABELS_MAX).transform((labels) => [...new Set(labels)]);
|
|
7547
|
+
contactMetadata = external_exports.record(external_exports.unknown()).refine((metadata) => {
|
|
7548
|
+
try {
|
|
7549
|
+
return new TextEncoder().encode(JSON.stringify(metadata)).length <= CONTACT_METADATA_MAX_BYTES;
|
|
7550
|
+
} catch {
|
|
7551
|
+
return false;
|
|
7552
|
+
}
|
|
7553
|
+
}, `Metadata must serialize to at most ${CONTACT_METADATA_MAX_BYTES} bytes`);
|
|
7554
|
+
scopeTagIds = external_exports.array(external_exports.string().uuid()).min(1).max(CONTACT_SCOPE_TAGS_MAX).transform((ids) => [...new Set(ids)]);
|
|
7555
|
+
contactVisibilitySchema = external_exports.discriminatedUnion("scope", [
|
|
7556
|
+
external_exports.object({ scope: external_exports.literal("all_hubs") }).strict(),
|
|
7557
|
+
external_exports.object({ scope: external_exports.literal("tags"), tag_ids: scopeTagIds }).strict()
|
|
7558
|
+
]);
|
|
7559
|
+
hasIdentity = (row) => Boolean(row.phone || row.email || row.instagram_sid);
|
|
7560
|
+
IDENTITY_REQUIRED = "A contact needs a phone, an email or an Instagram id";
|
|
7561
|
+
contactBookOrgQuery = external_exports.object({
|
|
7562
|
+
organization_id: external_exports.string().uuid()
|
|
7563
|
+
});
|
|
7564
|
+
contactBookContactParam = external_exports.object({
|
|
7565
|
+
contactId: external_exports.string().uuid()
|
|
7566
|
+
});
|
|
7567
|
+
contactBookListParam = external_exports.object({
|
|
7568
|
+
listId: external_exports.string().uuid()
|
|
7569
|
+
});
|
|
7570
|
+
contactBookHubParam = external_exports.object({
|
|
7571
|
+
hubId: external_exports.string().uuid()
|
|
7572
|
+
});
|
|
7573
|
+
contactBookPageQuery = external_exports.object({
|
|
7574
|
+
cursor: external_exports.string().max(2048).optional(),
|
|
7575
|
+
limit: external_exports.coerce.number().int().min(1).max(CONTACT_PAGE_MAX).default(50)
|
|
7576
|
+
});
|
|
7577
|
+
listContactBookContactsQuery = contactBookOrgQuery.merge(contactBookPageQuery).extend({
|
|
7578
|
+
q: external_exports.string().trim().max(CONTACT_SEARCH_MAX).optional(),
|
|
7579
|
+
label: external_exports.string().max(CONTACT_LABEL_MAX).transform(normalizeContactLabel).optional(),
|
|
7580
|
+
scope_tag_id: external_exports.string().uuid().optional()
|
|
7581
|
+
});
|
|
7582
|
+
listHubContactBookContactsQuery = contactBookPageQuery.extend({
|
|
7583
|
+
q: external_exports.string().trim().max(CONTACT_SEARCH_MAX).optional()
|
|
7584
|
+
});
|
|
7585
|
+
contactBookLinkCandidatesQuery = contactBookOrgQuery.extend({
|
|
7586
|
+
email: contactEmail
|
|
7587
|
+
});
|
|
7588
|
+
listContactBookListMembersQuery = contactBookOrgQuery.merge(contactBookPageQuery);
|
|
7589
|
+
contactRowFields = {
|
|
7590
|
+
name: contactName,
|
|
7591
|
+
phone: contactPhone.nullish(),
|
|
7592
|
+
email: contactEmail.nullish(),
|
|
7593
|
+
instagram_sid: contactInstagramSid.nullish(),
|
|
7594
|
+
labels: contactLabels.optional(),
|
|
7595
|
+
metadata: contactMetadata.optional()
|
|
7596
|
+
};
|
|
7597
|
+
createContactBookContactBody = external_exports.object({
|
|
7598
|
+
organization_id: external_exports.string().uuid(),
|
|
7599
|
+
...contactRowFields,
|
|
7600
|
+
visibility: contactVisibilitySchema,
|
|
7601
|
+
environment: external_exports.enum(CONTACT_ENVIRONMENTS).optional()
|
|
7602
|
+
}).strict().refine(hasIdentity, IDENTITY_REQUIRED);
|
|
7603
|
+
updateContactBookContactBody = external_exports.object({
|
|
7604
|
+
name: contactName.optional(),
|
|
7605
|
+
phone: contactPhone.nullable().optional(),
|
|
7606
|
+
email: contactEmail.nullable().optional(),
|
|
7607
|
+
instagram_sid: contactInstagramSid.nullable().optional(),
|
|
7608
|
+
labels: contactLabels.optional(),
|
|
7609
|
+
metadata: contactMetadata.optional(),
|
|
7610
|
+
visibility: contactVisibilitySchema.optional(),
|
|
7611
|
+
environment: external_exports.enum(CONTACT_ENVIRONMENTS).optional()
|
|
7612
|
+
}).strict();
|
|
7613
|
+
contactImportRowSchema = external_exports.object(contactRowFields).strict().refine(hasIdentity, IDENTITY_REQUIRED);
|
|
7614
|
+
importContactBookContactsBody = external_exports.object({
|
|
7615
|
+
organization_id: external_exports.string().uuid(),
|
|
7616
|
+
visibility: contactVisibilitySchema,
|
|
7617
|
+
environment: external_exports.enum(CONTACT_ENVIRONMENTS).optional(),
|
|
7618
|
+
labels: contactLabels.optional(),
|
|
7619
|
+
rows: external_exports.array(contactImportRowSchema).min(1).max(CONTACT_IMPORT_BATCH_MAX)
|
|
7620
|
+
}).strict().superRefine((batch, ctx) => {
|
|
7621
|
+
batch.rows.forEach((row, index) => {
|
|
7622
|
+
if (importRowLabels(row, batch.labels).length > CONTACT_LABELS_MAX) {
|
|
7623
|
+
ctx.addIssue({
|
|
7624
|
+
code: external_exports.ZodIssueCode.custom,
|
|
7625
|
+
path: ["rows", index, "labels"],
|
|
7626
|
+
message: `A contact holds at most ${CONTACT_LABELS_MAX} labels, the batch's included`
|
|
7627
|
+
});
|
|
7628
|
+
}
|
|
7629
|
+
});
|
|
7630
|
+
});
|
|
7631
|
+
linkContactBookContactBody = external_exports.object({
|
|
7632
|
+
user_id: external_exports.string().min(1).max(128)
|
|
7633
|
+
}).strict();
|
|
7634
|
+
listName = external_exports.string().trim().min(1).max(CONTACT_LIST_NAME_MAX).regex(CONTACT_LIST_NAME_REGEX, {
|
|
7635
|
+
message: 'Must be lowercase alphanumeric with hyphens (e.g. "vip-customers")'
|
|
7636
|
+
});
|
|
7637
|
+
contactListFilterSchema = external_exports.object({
|
|
7638
|
+
labels: external_exports.array(contactLabel).max(CONTACT_LIST_FILTER_MAX).transform((l) => [...new Set(l)]).default([]),
|
|
7639
|
+
scope_tag_ids: external_exports.array(external_exports.string().uuid()).max(CONTACT_LIST_FILTER_MAX).transform((t) => [...new Set(t)]).default([])
|
|
7640
|
+
}).strict();
|
|
7641
|
+
createContactBookListBody = external_exports.object({
|
|
7642
|
+
organization_id: external_exports.string().uuid(),
|
|
7643
|
+
name: listName,
|
|
7644
|
+
description: external_exports.string().max(CONTACT_LIST_DESCRIPTION_MAX).nullish(),
|
|
7645
|
+
filter: contactListFilterSchema.optional()
|
|
7646
|
+
}).strict();
|
|
7647
|
+
updateContactBookListBody = external_exports.object({
|
|
7648
|
+
name: listName.optional(),
|
|
7649
|
+
description: external_exports.string().max(CONTACT_LIST_DESCRIPTION_MAX).nullable().optional(),
|
|
7650
|
+
filter: contactListFilterSchema.optional()
|
|
7651
|
+
}).strict();
|
|
7652
|
+
updateContactBookListPinsBody = external_exports.object({
|
|
7653
|
+
add: external_exports.array(external_exports.string().uuid()).max(CONTACT_LIST_PINS_PER_REQUEST_MAX).default([]),
|
|
7654
|
+
remove: external_exports.array(external_exports.string().uuid()).max(CONTACT_LIST_PINS_PER_REQUEST_MAX).default([])
|
|
7655
|
+
}).strict().refine((b) => b.add.length + b.remove.length > 0, "Add or remove at least one contact");
|
|
7656
|
+
suppressionIdentitySchema = external_exports.discriminatedUnion("kind", [
|
|
7657
|
+
external_exports.object({ kind: external_exports.literal("phone"), value: contactPhone }).strict(),
|
|
7658
|
+
external_exports.object({ kind: external_exports.literal("email"), value: contactEmail }).strict(),
|
|
7659
|
+
external_exports.object({ kind: external_exports.literal("instagram"), value: contactInstagramSid }).strict()
|
|
7660
|
+
]);
|
|
7661
|
+
createContactBookSuppressionBody = external_exports.object({
|
|
7662
|
+
organization_id: external_exports.string().uuid(),
|
|
7663
|
+
identity: suppressionIdentitySchema,
|
|
7664
|
+
scope: external_exports.enum(SUPPRESSION_SCOPES)
|
|
7665
|
+
}).strict();
|
|
7666
|
+
contactBookSuppressionParam = external_exports.object({
|
|
7667
|
+
suppressionId: external_exports.string().regex(SUPPRESSION_ID_REGEX)
|
|
7668
|
+
});
|
|
7669
|
+
listContactBookSuppressionsQuery = contactBookOrgQuery.merge(contactBookPageQuery);
|
|
7670
|
+
contactBookEmailUnsubscribeTokenSchema = external_exports.string().max(200).regex(/^[0-9a-f-]{36}\.[0-9a-f]{64}\.[0-9a-f]{64}$/i);
|
|
7671
|
+
contactBookEmailUnsubscribeQuery = external_exports.object({ token: contactBookEmailUnsubscribeTokenSchema });
|
|
7672
|
+
orgListReferenceSchema = listName;
|
|
7680
7673
|
}
|
|
7681
7674
|
});
|
|
7682
7675
|
|
|
7683
|
-
// ../../packages/core/dist/chunk-
|
|
7684
|
-
|
|
7685
|
-
|
|
7686
|
-
|
|
7687
|
-
|
|
7688
|
-
|
|
7689
|
-
|
|
7690
|
-
|
|
7691
|
-
|
|
7692
|
-
|
|
7693
|
-
|
|
7694
|
-
|
|
7695
|
-
|
|
7696
|
-
|
|
7697
|
-
opts.onPage?.(page, run.pages);
|
|
7698
|
-
if (page.next_cursor === null) return run;
|
|
7699
|
-
if (seen.has(page.next_cursor)) {
|
|
7700
|
-
throw new Error(`The preview file snapshot repeated its cursor after page ${run.pages}, so it would never end.`);
|
|
7701
|
-
}
|
|
7702
|
-
seen.add(page.next_cursor);
|
|
7703
|
-
cursor = page.next_cursor;
|
|
7676
|
+
// ../../packages/core/dist/chunk-2YEGUQR7.js
|
|
7677
|
+
var PERSON_ID_PATTERN, CONTACT_PERSON_ID_PATTERN, PERSON_ID_FORM_MESSAGE, userPersonIdSchema, personIdSchema;
|
|
7678
|
+
var init_chunk_2YEGUQR7 = __esm({
|
|
7679
|
+
"../../packages/core/dist/chunk-2YEGUQR7.js"() {
|
|
7680
|
+
"use strict";
|
|
7681
|
+
init_zod();
|
|
7682
|
+
PERSON_ID_PATTERN = /^prs_[a-z2-7]{52}$/;
|
|
7683
|
+
CONTACT_PERSON_ID_PATTERN = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;
|
|
7684
|
+
PERSON_ID_FORM_MESSAGE = "Must be a person id (prs_\u2026) or a contact id (a lowercase UUID)";
|
|
7685
|
+
userPersonIdSchema = external_exports.string().regex(PERSON_ID_PATTERN, { message: "Must be a person id (prs_\u2026)" });
|
|
7686
|
+
personIdSchema = external_exports.string().refine(
|
|
7687
|
+
(value) => PERSON_ID_PATTERN.test(value) || CONTACT_PERSON_ID_PATTERN.test(value),
|
|
7688
|
+
{ message: PERSON_ID_FORM_MESSAGE }
|
|
7689
|
+
);
|
|
7704
7690
|
}
|
|
7705
|
-
|
|
7706
|
-
|
|
7707
|
-
|
|
7708
|
-
|
|
7709
|
-
|
|
7710
|
-
|
|
7711
|
-
|
|
7712
|
-
|
|
7713
|
-
|
|
7714
|
-
|
|
7715
|
-
|
|
7716
|
-
|
|
7717
|
-
|
|
7718
|
-
|
|
7719
|
-
}
|
|
7720
|
-
|
|
7691
|
+
});
|
|
7692
|
+
|
|
7693
|
+
// ../../packages/core/dist/chunk-OS6EKEP4.js
|
|
7694
|
+
var PERSON_LINKS_MAX, PERSON_DENY_PAGE_MAX, personParam, personLinkParam, deniedPersonParam, listDeniedPersonsQuery, conversationCustomerPersonParam;
|
|
7695
|
+
var init_chunk_OS6EKEP4 = __esm({
|
|
7696
|
+
"../../packages/core/dist/chunk-OS6EKEP4.js"() {
|
|
7697
|
+
"use strict";
|
|
7698
|
+
init_chunk_UAOHHCW5();
|
|
7699
|
+
init_chunk_2YEGUQR7();
|
|
7700
|
+
init_zod();
|
|
7701
|
+
PERSON_LINKS_MAX = 15;
|
|
7702
|
+
PERSON_DENY_PAGE_MAX = 100;
|
|
7703
|
+
personParam = external_exports.object({
|
|
7704
|
+
personId: userPersonIdSchema
|
|
7705
|
+
});
|
|
7706
|
+
personLinkParam = personParam.extend({
|
|
7707
|
+
targetId: personIdSchema
|
|
7708
|
+
});
|
|
7709
|
+
deniedPersonParam = external_exports.object({
|
|
7710
|
+
personId: personIdSchema
|
|
7711
|
+
});
|
|
7712
|
+
listDeniedPersonsQuery = contactBookOrgQuery.extend({
|
|
7713
|
+
cursor: personIdSchema.optional(),
|
|
7714
|
+
limit: external_exports.coerce.number().int().min(1).max(PERSON_DENY_PAGE_MAX).default(50)
|
|
7715
|
+
});
|
|
7716
|
+
conversationCustomerPersonParam = external_exports.object({
|
|
7717
|
+
hubId: external_exports.string().uuid(),
|
|
7718
|
+
conversationId: external_exports.string().uuid()
|
|
7719
|
+
});
|
|
7721
7720
|
}
|
|
7722
|
-
}
|
|
7723
|
-
|
|
7724
|
-
|
|
7725
|
-
|
|
7721
|
+
});
|
|
7722
|
+
|
|
7723
|
+
// ../../packages/core/dist/chunk-5DGHIY7L.js
|
|
7724
|
+
var rekorBaseChangeMessageSchema;
|
|
7725
|
+
var init_chunk_5DGHIY7L = __esm({
|
|
7726
|
+
"../../packages/core/dist/chunk-5DGHIY7L.js"() {
|
|
7726
7727
|
"use strict";
|
|
7727
|
-
init_chunk_AUD5MVHU();
|
|
7728
|
-
init_chunk_5FO3GNKP();
|
|
7729
7728
|
init_zod();
|
|
7730
|
-
|
|
7731
|
-
|
|
7732
|
-
|
|
7733
|
-
|
|
7734
|
-
|
|
7735
|
-
|
|
7736
|
-
|
|
7737
|
-
|
|
7738
|
-
|
|
7739
|
-
|
|
7729
|
+
rekorBaseChangeMessageSchema = external_exports.object({
|
|
7730
|
+
/** The WayAI org UUID — one id namespace. */
|
|
7731
|
+
org_id: external_exports.string().uuid(),
|
|
7732
|
+
/**
|
|
7733
|
+
* Not a UUID: a preview base id is `{prod_base_id}--{slug}`. Immutable per base — a
|
|
7734
|
+
* preview clone is its OWN base_id — so `(base_id, scope)` keys never collide across
|
|
7735
|
+
* environments. Empty is never a real base id, so it is non-conforming rather than a
|
|
7736
|
+
* frame keyed on nothing.
|
|
7737
|
+
*/
|
|
7738
|
+
base_id: external_exports.string().min(1),
|
|
7739
|
+
/**
|
|
7740
|
+
* Rides along so the client scopes its refetch without a lookup; the inspector scopes
|
|
7741
|
+
* by side.
|
|
7742
|
+
*/
|
|
7743
|
+
environment: external_exports.enum(["production", "preview"]),
|
|
7744
|
+
/** Which pane refetches. `base` covers create/delete/promote/config changes. */
|
|
7745
|
+
scope: external_exports.enum(["records", "record_types", "files", "base"])
|
|
7740
7746
|
});
|
|
7741
|
-
FILE_SNAPSHOT_MAX_PAGES = 1e4;
|
|
7742
|
-
FILE_SNAPSHOT_CONFLICT_ATTEMPTS = 3;
|
|
7743
|
-
FILE_SNAPSHOT_PAGE_SPACING_MS = Math.ceil(
|
|
7744
|
-
6e4 / Math.max(1, Math.floor((getEndpointConfig(`${DATA_PROXY_PREFIX}/files/snapshot`)?.userLimit ?? 60) * 4 / 5))
|
|
7745
|
-
);
|
|
7746
|
-
FILE_SNAPSHOT_CONFLICT_STATUS = 409;
|
|
7747
7747
|
}
|
|
7748
7748
|
});
|
|
7749
7749
|
|
|
@@ -10577,6 +10577,20 @@ var init_chunk_OPETF4GS = __esm({
|
|
|
10577
10577
|
}
|
|
10578
10578
|
});
|
|
10579
10579
|
|
|
10580
|
+
// ../../packages/core/dist/chunk-YULHXJ5M.js
|
|
10581
|
+
var COMMUNITY_LESSON_TREE_MAX_BYTES, COMMUNITY_LESSON_LINK_PROTOCOLS, COMMUNITY_LESSON_TREE_TOO_LARGE_REASON, COMMUNITY_LESSON_TREE_TOO_DEEP_REASON, COMMUNITY_LESSON_LINE_PREFIX_TOO_WIDE_REASON, LINK_SCHEME;
|
|
10582
|
+
var init_chunk_YULHXJ5M = __esm({
|
|
10583
|
+
"../../packages/core/dist/chunk-YULHXJ5M.js"() {
|
|
10584
|
+
"use strict";
|
|
10585
|
+
COMMUNITY_LESSON_TREE_MAX_BYTES = 512 * 1024;
|
|
10586
|
+
COMMUNITY_LESSON_LINK_PROTOCOLS = ["http", "https", "mailto"];
|
|
10587
|
+
COMMUNITY_LESSON_TREE_TOO_LARGE_REASON = "lesson_tree_too_large";
|
|
10588
|
+
COMMUNITY_LESSON_TREE_TOO_DEEP_REASON = "lesson_tree_too_deep";
|
|
10589
|
+
COMMUNITY_LESSON_LINE_PREFIX_TOO_WIDE_REASON = "lesson_line_prefix_too_wide";
|
|
10590
|
+
LINK_SCHEME = new RegExp(`^(${COMMUNITY_LESSON_LINK_PROTOCOLS.join("|")}):`, "i");
|
|
10591
|
+
}
|
|
10592
|
+
});
|
|
10593
|
+
|
|
10580
10594
|
// ../../packages/core/dist/chunk-V4FRPRH5.js
|
|
10581
10595
|
var CONSULT_THREAD_STATUSES, consultThreadStatus, CONSULT_THREAD_TITLE_MAX, consultThreadTitle, consultThreadSummary, listConsultThreadsQuery, listConsultThreadsResponse, createConsultThreadBody, createConsultThreadResponse, consultThreadIdParam, updateConsultThreadBody, updateConsultThreadResponse, CONSULT_AWAIT_TIMEOUT_MS;
|
|
10582
10596
|
var init_chunk_V4FRPRH5 = __esm({
|
|
@@ -13608,20 +13622,6 @@ var init_chunk_JDJ4EUOL = __esm({
|
|
|
13608
13622
|
}
|
|
13609
13623
|
});
|
|
13610
13624
|
|
|
13611
|
-
// ../../packages/core/dist/chunk-YULHXJ5M.js
|
|
13612
|
-
var COMMUNITY_LESSON_TREE_MAX_BYTES, COMMUNITY_LESSON_LINK_PROTOCOLS, COMMUNITY_LESSON_TREE_TOO_LARGE_REASON, COMMUNITY_LESSON_TREE_TOO_DEEP_REASON, COMMUNITY_LESSON_LINE_PREFIX_TOO_WIDE_REASON, LINK_SCHEME;
|
|
13613
|
-
var init_chunk_YULHXJ5M = __esm({
|
|
13614
|
-
"../../packages/core/dist/chunk-YULHXJ5M.js"() {
|
|
13615
|
-
"use strict";
|
|
13616
|
-
COMMUNITY_LESSON_TREE_MAX_BYTES = 512 * 1024;
|
|
13617
|
-
COMMUNITY_LESSON_LINK_PROTOCOLS = ["http", "https", "mailto"];
|
|
13618
|
-
COMMUNITY_LESSON_TREE_TOO_LARGE_REASON = "lesson_tree_too_large";
|
|
13619
|
-
COMMUNITY_LESSON_TREE_TOO_DEEP_REASON = "lesson_tree_too_deep";
|
|
13620
|
-
COMMUNITY_LESSON_LINE_PREFIX_TOO_WIDE_REASON = "lesson_line_prefix_too_wide";
|
|
13621
|
-
LINK_SCHEME = new RegExp(`^(${COMMUNITY_LESSON_LINK_PROTOCOLS.join("|")}):`, "i");
|
|
13622
|
-
}
|
|
13623
|
-
});
|
|
13624
|
-
|
|
13625
13625
|
// ../../packages/core/dist/chunk-VYINA6YP.js
|
|
13626
13626
|
function formatterOf(zone) {
|
|
13627
13627
|
const held = formatters.get(zone);
|
|
@@ -13783,220 +13783,6 @@ var init_chunk_X4IDZLLS = __esm({
|
|
|
13783
13783
|
}
|
|
13784
13784
|
});
|
|
13785
13785
|
|
|
13786
|
-
// ../../packages/core/dist/chunk-M2T55BV6.js
|
|
13787
|
-
function isCaseAttributeDate(text5) {
|
|
13788
|
-
const match = /^(\d{4})-(\d{2})-(\d{2})$/.exec(text5);
|
|
13789
|
-
if (!match) return false;
|
|
13790
|
-
const [year, month, day] = [Number(match[1]), Number(match[2]), Number(match[3])];
|
|
13791
|
-
const leap = year % 4 === 0 && (year % 100 !== 0 || year % 400 === 0);
|
|
13792
|
-
const days = [31, leap ? 29 : 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31][month - 1];
|
|
13793
|
-
return days !== void 0 && day >= 1 && day <= days;
|
|
13794
|
-
}
|
|
13795
|
-
function valueProblem(property, value) {
|
|
13796
|
-
switch (property.type) {
|
|
13797
|
-
case "string":
|
|
13798
|
-
if (typeof value !== "string") return "attribute_wrong_type";
|
|
13799
|
-
break;
|
|
13800
|
-
case "number":
|
|
13801
|
-
if (typeof value !== "number" || !Number.isFinite(value)) return "attribute_wrong_type";
|
|
13802
|
-
break;
|
|
13803
|
-
case "integer":
|
|
13804
|
-
if (typeof value !== "number" || !Number.isInteger(value)) return "attribute_wrong_type";
|
|
13805
|
-
break;
|
|
13806
|
-
case "boolean":
|
|
13807
|
-
if (typeof value !== "boolean") return "attribute_wrong_type";
|
|
13808
|
-
break;
|
|
13809
|
-
default:
|
|
13810
|
-
break;
|
|
13811
|
-
}
|
|
13812
|
-
if (property.format === "date" && typeof value === "string" && !isCaseAttributeDate(value)) return "attribute_not_a_date";
|
|
13813
|
-
return null;
|
|
13814
|
-
}
|
|
13815
|
-
function propertiesOf(schema) {
|
|
13816
|
-
return Object.entries(schema.properties ?? {});
|
|
13817
|
-
}
|
|
13818
|
-
function caseAttributesSchemaProblem(schema) {
|
|
13819
|
-
for (const [key, property] of propertiesOf(schema)) {
|
|
13820
|
-
if (property.type === void 0 && property.enum === void 0) return { reason: "attribute_type_missing", at: key };
|
|
13821
|
-
if (property.format !== void 0 && property.type !== "string") return { reason: "attribute_format_unexpected", at: key };
|
|
13822
|
-
if (property.enum) {
|
|
13823
|
-
if (new Set(property.enum).size !== property.enum.length) return { reason: "attribute_option_repeated", at: key };
|
|
13824
|
-
if (property.enum.some((option) => valueProblem(property, option) !== null)) return { reason: "attribute_option_mismatch", at: key };
|
|
13825
|
-
}
|
|
13826
|
-
}
|
|
13827
|
-
const required = schema.required ?? [];
|
|
13828
|
-
if (new Set(required).size !== required.length) return { reason: "attribute_required_repeated", at: "required" };
|
|
13829
|
-
const unknown = required.find((key) => !Object.hasOwn(schema.properties ?? {}, key));
|
|
13830
|
-
if (unknown !== void 0) return { reason: "attribute_required_unknown", at: unknown };
|
|
13831
|
-
return null;
|
|
13832
|
-
}
|
|
13833
|
-
var CASE_ATTRIBUTE_KEY_PATTERN, CASE_ATTRIBUTE_KEY_MAX_LENGTH, CASE_ATTRIBUTE_TYPES, CASE_ATTRIBUTE_FORMATS, CASE_ATTRIBUTE_PROPERTIES_MAX, CASE_ATTRIBUTE_OPTIONS_MAX, CASE_ATTRIBUTE_TITLE_MAX_LENGTH, CASE_ATTRIBUTE_DESCRIPTION_MAX_LENGTH, CASE_ATTRIBUTE_OPTION_MAX_LENGTH, CASE_ATTRIBUTES_MAX_CHARS, EMPTY_CASE_ATTRIBUTES_SCHEMA, caseAttributePropertySchema, attributeKey, caseAttributesSchemaSchema, caseDateSchema;
|
|
13834
|
-
var init_chunk_M2T55BV6 = __esm({
|
|
13835
|
-
"../../packages/core/dist/chunk-M2T55BV6.js"() {
|
|
13836
|
-
"use strict";
|
|
13837
|
-
init_zod();
|
|
13838
|
-
CASE_ATTRIBUTE_KEY_PATTERN = /^[a-z][a-z0-9_]*$/;
|
|
13839
|
-
CASE_ATTRIBUTE_KEY_MAX_LENGTH = 64;
|
|
13840
|
-
CASE_ATTRIBUTE_TYPES = ["string", "number", "integer", "boolean"];
|
|
13841
|
-
CASE_ATTRIBUTE_FORMATS = ["date"];
|
|
13842
|
-
CASE_ATTRIBUTE_PROPERTIES_MAX = 100;
|
|
13843
|
-
CASE_ATTRIBUTE_OPTIONS_MAX = 100;
|
|
13844
|
-
CASE_ATTRIBUTE_TITLE_MAX_LENGTH = 200;
|
|
13845
|
-
CASE_ATTRIBUTE_DESCRIPTION_MAX_LENGTH = 2e3;
|
|
13846
|
-
CASE_ATTRIBUTE_OPTION_MAX_LENGTH = 200;
|
|
13847
|
-
CASE_ATTRIBUTES_MAX_CHARS = 16 * 1024;
|
|
13848
|
-
EMPTY_CASE_ATTRIBUTES_SCHEMA = { type: "object" };
|
|
13849
|
-
caseAttributePropertySchema = external_exports.object({
|
|
13850
|
-
type: external_exports.enum(CASE_ATTRIBUTE_TYPES).optional(),
|
|
13851
|
-
title: external_exports.string().min(1).max(CASE_ATTRIBUTE_TITLE_MAX_LENGTH).optional(),
|
|
13852
|
-
description: external_exports.string().max(CASE_ATTRIBUTE_DESCRIPTION_MAX_LENGTH).optional(),
|
|
13853
|
-
/** The values it may take, shown as a list to pick from. */
|
|
13854
|
-
enum: external_exports.array(external_exports.union([external_exports.string().max(CASE_ATTRIBUTE_OPTION_MAX_LENGTH), external_exports.number().finite()])).min(1).max(CASE_ATTRIBUTE_OPTIONS_MAX).optional(),
|
|
13855
|
-
/** `date`: a calendar date, `YYYY-MM-DD`. */
|
|
13856
|
-
format: external_exports.enum(CASE_ATTRIBUTE_FORMATS).optional()
|
|
13857
|
-
}).strict();
|
|
13858
|
-
attributeKey = external_exports.string().max(CASE_ATTRIBUTE_KEY_MAX_LENGTH).regex(CASE_ATTRIBUTE_KEY_PATTERN);
|
|
13859
|
-
caseAttributesSchemaSchema = external_exports.object({
|
|
13860
|
-
type: external_exports.literal("object"),
|
|
13861
|
-
properties: external_exports.record(attributeKey, caseAttributePropertySchema).refine((properties) => Object.keys(properties).length <= CASE_ATTRIBUTE_PROPERTIES_MAX, "Too many properties").optional(),
|
|
13862
|
-
required: external_exports.array(attributeKey).max(CASE_ATTRIBUTE_PROPERTIES_MAX).optional()
|
|
13863
|
-
}).strict();
|
|
13864
|
-
caseDateSchema = external_exports.string().refine(isCaseAttributeDate, "Not a date (YYYY-MM-DD)");
|
|
13865
|
-
}
|
|
13866
|
-
});
|
|
13867
|
-
|
|
13868
|
-
// ../../packages/core/dist/chunk-J3HQTL6M.js
|
|
13869
|
-
function withProblem(shape, problemOf) {
|
|
13870
|
-
return shape.superRefine((value, ctx) => {
|
|
13871
|
-
const found = problemOf(value);
|
|
13872
|
-
if (found) {
|
|
13873
|
-
ctx.addIssue({ code: external_exports.ZodIssueCode.custom, message: found.reason, path: found.at.split("."), params: { case_registry_reason: found.reason } });
|
|
13874
|
-
}
|
|
13875
|
-
});
|
|
13876
|
-
}
|
|
13877
|
-
function caseRegistryTypeProblem(type) {
|
|
13878
|
-
const found = caseAttributesSchemaProblem(type.attributes);
|
|
13879
|
-
if (found) return { reason: found.reason, at: `attributes.${found.at}` };
|
|
13880
|
-
if (JSON.stringify(type.attributes).length > CASE_REGISTRY_TYPE_SCHEMA_MAX_CHARS) return { reason: "attributes_schema_too_large", at: "attributes" };
|
|
13881
|
-
return null;
|
|
13882
|
-
}
|
|
13883
|
-
function casePartyProblem(party) {
|
|
13884
|
-
if (party.document_kind === null !== (party.document_number === null)) return { reason: "document_incomplete", at: "document_number" };
|
|
13885
|
-
if (party.document_kind === "cpf" || party.document_kind === "cnpj") {
|
|
13886
|
-
if (party.person_kind !== (party.document_kind === "cpf" ? "natural" : "legal")) return { reason: "document_person_mismatch", at: "document_kind" };
|
|
13887
|
-
if (!(party.document_kind === "cpf" ? /^[0-9]{11}$/ : /^[0-9]{14}$/).test(party.document_number ?? "")) {
|
|
13888
|
-
return { reason: "document_digits", at: "document_number" };
|
|
13889
|
-
}
|
|
13890
|
-
}
|
|
13891
|
-
return null;
|
|
13892
|
-
}
|
|
13893
|
-
function casePartyGroupProblem(group) {
|
|
13894
|
-
return new Set(group.party_ids).size === group.party_ids.length ? null : { reason: "party_repeated", at: "party_ids" };
|
|
13895
|
-
}
|
|
13896
|
-
function caseInstrumentProblem(instrument) {
|
|
13897
|
-
if (instrument.effective_from !== null && instrument.effective_until !== null && instrument.effective_until < instrument.effective_from) {
|
|
13898
|
-
return { reason: "effective_dates_reversed", at: "effective_until" };
|
|
13899
|
-
}
|
|
13900
|
-
const keys = instrument.parties.map((party) => `${party.party_id}
|
|
13901
|
-
${party.role}`);
|
|
13902
|
-
return new Set(keys).size === keys.length ? null : { reason: "instrument_party_repeated", at: "parties" };
|
|
13903
|
-
}
|
|
13904
|
-
var CASE_REGISTRY_TYPE_CODE_PATTERN, CASE_REGISTRY_TYPE_CODE_MAX_LENGTH, CASE_REGISTRY_NAME_MAX_LENGTH, CASE_REGISTRY_TYPE_SCHEMA_MAX_CHARS, CASE_PARTY_ABBREVIATION_PATTERN, CASE_PARTY_PERSON_KINDS, CASE_PARTY_DOCUMENT_KINDS, CASE_PARTY_DOCUMENT_MAX_LENGTH, CASE_PARTY_GROUP_MEMBERS_MAX, CASE_INSTRUMENT_NUMBER_MAX_LENGTH, CASE_INSTRUMENT_ROLE_MAX_LENGTH, CASE_INSTRUMENT_PARTIES_MAX, CASE_REGISTRY_PAGE_MAX, CASE_REGISTRY_QUERY_MAX_LENGTH, trimmedName, dateSchema, attributesValues, registryTypeFields, createCaseRegistryTypeShape, updateCaseRegistryTypeShape, createCaseRegistryTypeBody, updateCaseRegistryTypeBody, saveCasePartyShape, saveCasePartyBody, saveCasePartyGroupShape, saveCasePartyGroupBody, caseInstrumentPartyInput, saveCaseInstrumentShape, saveCaseInstrumentBody, registryPage, searchText, casePartiesQuery, casePartyGroupsQuery, caseInstrumentsQuery, caseRegistryTypeParam, casePartyParam, casePartyGroupParam, caseInstrumentParam;
|
|
13905
|
-
var init_chunk_J3HQTL6M = __esm({
|
|
13906
|
-
"../../packages/core/dist/chunk-J3HQTL6M.js"() {
|
|
13907
|
-
"use strict";
|
|
13908
|
-
init_chunk_M2T55BV6();
|
|
13909
|
-
init_chunk_CLGTGGVN();
|
|
13910
|
-
init_chunk_HZ6CADSY();
|
|
13911
|
-
init_zod();
|
|
13912
|
-
CASE_REGISTRY_TYPE_CODE_PATTERN = /^[a-z0-9]+(_[a-z0-9]+)*$/;
|
|
13913
|
-
CASE_REGISTRY_TYPE_CODE_MAX_LENGTH = 64;
|
|
13914
|
-
CASE_REGISTRY_NAME_MAX_LENGTH = 200;
|
|
13915
|
-
CASE_REGISTRY_TYPE_SCHEMA_MAX_CHARS = 64 * 1024;
|
|
13916
|
-
CASE_PARTY_ABBREVIATION_PATTERN = /^[A-Z0-9]{2,12}$/;
|
|
13917
|
-
CASE_PARTY_PERSON_KINDS = ["natural", "legal"];
|
|
13918
|
-
CASE_PARTY_DOCUMENT_KINDS = ["cpf", "cnpj", "other"];
|
|
13919
|
-
CASE_PARTY_DOCUMENT_MAX_LENGTH = 64;
|
|
13920
|
-
CASE_PARTY_GROUP_MEMBERS_MAX = 2e3;
|
|
13921
|
-
CASE_INSTRUMENT_NUMBER_MAX_LENGTH = 200;
|
|
13922
|
-
CASE_INSTRUMENT_ROLE_MAX_LENGTH = 200;
|
|
13923
|
-
CASE_INSTRUMENT_PARTIES_MAX = 50;
|
|
13924
|
-
CASE_REGISTRY_PAGE_MAX = 100;
|
|
13925
|
-
CASE_REGISTRY_QUERY_MAX_LENGTH = 200;
|
|
13926
|
-
trimmedName = external_exports.string().trim().min(1).max(CASE_REGISTRY_NAME_MAX_LENGTH);
|
|
13927
|
-
dateSchema = caseDateSchema;
|
|
13928
|
-
attributesValues = external_exports.record(external_exports.string(), external_exports.unknown()).default({});
|
|
13929
|
-
registryTypeFields = {
|
|
13930
|
-
name: trimmedName,
|
|
13931
|
-
attributes: caseAttributesSchemaSchema.default(EMPTY_CASE_ATTRIBUTES_SCHEMA),
|
|
13932
|
-
active: external_exports.boolean().default(true)
|
|
13933
|
-
};
|
|
13934
|
-
createCaseRegistryTypeShape = external_exports.object({
|
|
13935
|
-
code: external_exports.string().trim().max(CASE_REGISTRY_TYPE_CODE_MAX_LENGTH).regex(CASE_REGISTRY_TYPE_CODE_PATTERN),
|
|
13936
|
-
...registryTypeFields
|
|
13937
|
-
}).strict();
|
|
13938
|
-
updateCaseRegistryTypeShape = external_exports.object({
|
|
13939
|
-
...registryTypeFields,
|
|
13940
|
-
expected_updated_at: timestampSchema.optional()
|
|
13941
|
-
}).strict();
|
|
13942
|
-
createCaseRegistryTypeBody = withProblem(createCaseRegistryTypeShape, caseRegistryTypeProblem);
|
|
13943
|
-
updateCaseRegistryTypeBody = withProblem(updateCaseRegistryTypeShape, caseRegistryTypeProblem);
|
|
13944
|
-
saveCasePartyShape = external_exports.object({
|
|
13945
|
-
type_id: uuidSchema,
|
|
13946
|
-
name: trimmedName,
|
|
13947
|
-
abbreviation: external_exports.string().trim().transform((value) => value.toUpperCase()).pipe(external_exports.string().regex(CASE_PARTY_ABBREVIATION_PATTERN)).nullable().default(null),
|
|
13948
|
-
person_kind: external_exports.enum(CASE_PARTY_PERSON_KINDS),
|
|
13949
|
-
document_kind: external_exports.enum(CASE_PARTY_DOCUMENT_KINDS).nullable().default(null),
|
|
13950
|
-
document_number: external_exports.string().trim().min(1).max(CASE_PARTY_DOCUMENT_MAX_LENGTH).nullable().default(null),
|
|
13951
|
-
attributes: attributesValues,
|
|
13952
|
-
active: external_exports.boolean().default(true),
|
|
13953
|
-
expected_updated_at: timestampSchema.optional()
|
|
13954
|
-
}).strict();
|
|
13955
|
-
saveCasePartyBody = withProblem(saveCasePartyShape, casePartyProblem);
|
|
13956
|
-
saveCasePartyGroupShape = external_exports.object({
|
|
13957
|
-
name: trimmedName,
|
|
13958
|
-
party_ids: external_exports.array(uuidSchema).max(CASE_PARTY_GROUP_MEMBERS_MAX).default([]),
|
|
13959
|
-
expected_updated_at: timestampSchema.optional()
|
|
13960
|
-
}).strict();
|
|
13961
|
-
saveCasePartyGroupBody = withProblem(saveCasePartyGroupShape, casePartyGroupProblem);
|
|
13962
|
-
caseInstrumentPartyInput = external_exports.object({
|
|
13963
|
-
party_id: uuidSchema,
|
|
13964
|
-
role: external_exports.string().trim().min(1).max(CASE_INSTRUMENT_ROLE_MAX_LENGTH)
|
|
13965
|
-
}).strict();
|
|
13966
|
-
saveCaseInstrumentShape = external_exports.object({
|
|
13967
|
-
type_id: uuidSchema,
|
|
13968
|
-
number: external_exports.string().trim().min(1).max(CASE_INSTRUMENT_NUMBER_MAX_LENGTH),
|
|
13969
|
-
signed_on: dateSchema.nullable().default(null),
|
|
13970
|
-
effective_from: dateSchema.nullable().default(null),
|
|
13971
|
-
effective_until: dateSchema.nullable().default(null),
|
|
13972
|
-
attributes: attributesValues,
|
|
13973
|
-
/** Each party in a role; one party may hold several roles. */
|
|
13974
|
-
parties: external_exports.array(caseInstrumentPartyInput).max(CASE_INSTRUMENT_PARTIES_MAX).default([]),
|
|
13975
|
-
expected_updated_at: timestampSchema.optional()
|
|
13976
|
-
}).strict();
|
|
13977
|
-
saveCaseInstrumentBody = withProblem(saveCaseInstrumentShape, caseInstrumentProblem);
|
|
13978
|
-
registryPage = casePageQuery.extend({
|
|
13979
|
-
limit: external_exports.coerce.number().int().min(1).max(CASE_REGISTRY_PAGE_MAX).optional()
|
|
13980
|
-
});
|
|
13981
|
-
searchText = external_exports.string().trim().min(1).max(CASE_REGISTRY_QUERY_MAX_LENGTH).optional();
|
|
13982
|
-
casePartiesQuery = registryPage.extend({
|
|
13983
|
-
q: searchText,
|
|
13984
|
-
type_id: uuidSchema.optional(),
|
|
13985
|
-
active: external_exports.enum(["true", "false"]).transform((value) => value === "true").optional()
|
|
13986
|
-
});
|
|
13987
|
-
casePartyGroupsQuery = registryPage.extend({ q: searchText });
|
|
13988
|
-
caseInstrumentsQuery = registryPage.extend({
|
|
13989
|
-
q: searchText,
|
|
13990
|
-
type_id: uuidSchema.optional(),
|
|
13991
|
-
party_id: uuidSchema.optional()
|
|
13992
|
-
});
|
|
13993
|
-
caseRegistryTypeParam = caseSpaceParam.extend({ type_id: uuidSchema });
|
|
13994
|
-
casePartyParam = caseSpaceParam.extend({ party_id: uuidSchema });
|
|
13995
|
-
casePartyGroupParam = caseSpaceParam.extend({ group_id: uuidSchema });
|
|
13996
|
-
caseInstrumentParam = caseSpaceParam.extend({ instrument_id: uuidSchema });
|
|
13997
|
-
}
|
|
13998
|
-
});
|
|
13999
|
-
|
|
14000
13786
|
// ../../packages/core/dist/chunk-KWRHZBGU.js
|
|
14001
13787
|
function fold(segment2) {
|
|
14002
13788
|
return segment2.toUpperCase().toLowerCase().replace(/ς/g, "\u03C3").replace(/ß/g, "ss").normalize("NFC");
|
|
@@ -14106,13 +13892,13 @@ var init_chunk_KWRHZBGU = __esm({
|
|
|
14106
13892
|
}
|
|
14107
13893
|
});
|
|
14108
13894
|
|
|
14109
|
-
// ../../packages/core/dist/chunk-
|
|
13895
|
+
// ../../packages/core/dist/chunk-MQQRYOE6.js
|
|
14110
13896
|
var CASE_FILE_SHA_PATTERN, caseFileShaSchema, CASE_REVISION_MESSAGE_MAX_LENGTH, CASE_REVISION_SESSION_MAX_LENGTH, CASE_REVISION_ENTRIES_MAX, caseRevisionEntryShape, caseRevisionShape, CASE_FILE_SEALED_REASON, CASE_UPLOAD_BODY_MAX_BYTES, CASE_UPLOAD_REVISION_FIELD, CASE_FILE_CONFLICT_REASON, CASE_FILES_FULL_REASON, CASE_FILES_QUOTA_REASON, CASE_UPLOADS_BUSY_REASON, isBlob, caseUploadForm, CASE_FILES_PAGE_MAX, caseFilesQuery, caseFileReadPath, CASE_FILE_VERSIONS_PAGE_MAX, caseFileVersionsQuery, caseFileContentQuery, CASE_REVISIONS_PAGE_MAX, caseRevisionsQuery, CASE_FILE_COMPARE_MAX_BYTES, caseFileCompareQuery;
|
|
14111
|
-
var
|
|
14112
|
-
"../../packages/core/dist/chunk-
|
|
13897
|
+
var init_chunk_MQQRYOE6 = __esm({
|
|
13898
|
+
"../../packages/core/dist/chunk-MQQRYOE6.js"() {
|
|
14113
13899
|
"use strict";
|
|
14114
|
-
init_chunk_CLGTGGVN();
|
|
14115
13900
|
init_chunk_KWRHZBGU();
|
|
13901
|
+
init_chunk_CLGTGGVN();
|
|
14116
13902
|
init_chunk_HZ6CADSY();
|
|
14117
13903
|
init_zod();
|
|
14118
13904
|
CASE_FILE_SHA_PATTERN = /^[0-9a-f]{64}$/;
|
|
@@ -14194,12 +13980,12 @@ var init_chunk_HPZOVPVT = __esm({
|
|
|
14194
13980
|
}
|
|
14195
13981
|
});
|
|
14196
13982
|
|
|
14197
|
-
// ../../packages/core/dist/chunk-
|
|
13983
|
+
// ../../packages/core/dist/chunk-A5TJEV6T.js
|
|
14198
13984
|
var CASE_STYLE_KINDS, caseStyleParam, CASE_STYLE_VERSIONS_PAGE_MAX, caseStyleVersionsQuery, caseStyleContentQuery, CASE_STYLE_UPLOAD_BODY_MAX_BYTES, CASE_STYLE_FILE_FIELD, CASE_STYLE_EXPECT_FIELD, caseStyleUploadForm;
|
|
14199
|
-
var
|
|
14200
|
-
"../../packages/core/dist/chunk-
|
|
13985
|
+
var init_chunk_A5TJEV6T = __esm({
|
|
13986
|
+
"../../packages/core/dist/chunk-A5TJEV6T.js"() {
|
|
14201
13987
|
"use strict";
|
|
14202
|
-
|
|
13988
|
+
init_chunk_MQQRYOE6();
|
|
14203
13989
|
init_chunk_CLGTGGVN();
|
|
14204
13990
|
init_chunk_HZ6CADSY();
|
|
14205
13991
|
init_zod();
|
|
@@ -14221,7 +14007,221 @@ var init_chunk_ZJA3UZMG = __esm({
|
|
|
14221
14007
|
}
|
|
14222
14008
|
});
|
|
14223
14009
|
|
|
14224
|
-
// ../../packages/core/dist/chunk-
|
|
14010
|
+
// ../../packages/core/dist/chunk-M2T55BV6.js
|
|
14011
|
+
function isCaseAttributeDate(text5) {
|
|
14012
|
+
const match = /^(\d{4})-(\d{2})-(\d{2})$/.exec(text5);
|
|
14013
|
+
if (!match) return false;
|
|
14014
|
+
const [year, month, day] = [Number(match[1]), Number(match[2]), Number(match[3])];
|
|
14015
|
+
const leap = year % 4 === 0 && (year % 100 !== 0 || year % 400 === 0);
|
|
14016
|
+
const days = [31, leap ? 29 : 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31][month - 1];
|
|
14017
|
+
return days !== void 0 && day >= 1 && day <= days;
|
|
14018
|
+
}
|
|
14019
|
+
function valueProblem(property, value) {
|
|
14020
|
+
switch (property.type) {
|
|
14021
|
+
case "string":
|
|
14022
|
+
if (typeof value !== "string") return "attribute_wrong_type";
|
|
14023
|
+
break;
|
|
14024
|
+
case "number":
|
|
14025
|
+
if (typeof value !== "number" || !Number.isFinite(value)) return "attribute_wrong_type";
|
|
14026
|
+
break;
|
|
14027
|
+
case "integer":
|
|
14028
|
+
if (typeof value !== "number" || !Number.isInteger(value)) return "attribute_wrong_type";
|
|
14029
|
+
break;
|
|
14030
|
+
case "boolean":
|
|
14031
|
+
if (typeof value !== "boolean") return "attribute_wrong_type";
|
|
14032
|
+
break;
|
|
14033
|
+
default:
|
|
14034
|
+
break;
|
|
14035
|
+
}
|
|
14036
|
+
if (property.format === "date" && typeof value === "string" && !isCaseAttributeDate(value)) return "attribute_not_a_date";
|
|
14037
|
+
return null;
|
|
14038
|
+
}
|
|
14039
|
+
function propertiesOf(schema) {
|
|
14040
|
+
return Object.entries(schema.properties ?? {});
|
|
14041
|
+
}
|
|
14042
|
+
function caseAttributesSchemaProblem(schema) {
|
|
14043
|
+
for (const [key, property] of propertiesOf(schema)) {
|
|
14044
|
+
if (property.type === void 0 && property.enum === void 0) return { reason: "attribute_type_missing", at: key };
|
|
14045
|
+
if (property.format !== void 0 && property.type !== "string") return { reason: "attribute_format_unexpected", at: key };
|
|
14046
|
+
if (property.enum) {
|
|
14047
|
+
if (new Set(property.enum).size !== property.enum.length) return { reason: "attribute_option_repeated", at: key };
|
|
14048
|
+
if (property.enum.some((option) => valueProblem(property, option) !== null)) return { reason: "attribute_option_mismatch", at: key };
|
|
14049
|
+
}
|
|
14050
|
+
}
|
|
14051
|
+
const required = schema.required ?? [];
|
|
14052
|
+
if (new Set(required).size !== required.length) return { reason: "attribute_required_repeated", at: "required" };
|
|
14053
|
+
const unknown = required.find((key) => !Object.hasOwn(schema.properties ?? {}, key));
|
|
14054
|
+
if (unknown !== void 0) return { reason: "attribute_required_unknown", at: unknown };
|
|
14055
|
+
return null;
|
|
14056
|
+
}
|
|
14057
|
+
var CASE_ATTRIBUTE_KEY_PATTERN, CASE_ATTRIBUTE_KEY_MAX_LENGTH, CASE_ATTRIBUTE_TYPES, CASE_ATTRIBUTE_FORMATS, CASE_ATTRIBUTE_PROPERTIES_MAX, CASE_ATTRIBUTE_OPTIONS_MAX, CASE_ATTRIBUTE_TITLE_MAX_LENGTH, CASE_ATTRIBUTE_DESCRIPTION_MAX_LENGTH, CASE_ATTRIBUTE_OPTION_MAX_LENGTH, CASE_ATTRIBUTES_MAX_CHARS, EMPTY_CASE_ATTRIBUTES_SCHEMA, caseAttributePropertySchema, attributeKey, caseAttributesSchemaSchema, caseDateSchema;
|
|
14058
|
+
var init_chunk_M2T55BV6 = __esm({
|
|
14059
|
+
"../../packages/core/dist/chunk-M2T55BV6.js"() {
|
|
14060
|
+
"use strict";
|
|
14061
|
+
init_zod();
|
|
14062
|
+
CASE_ATTRIBUTE_KEY_PATTERN = /^[a-z][a-z0-9_]*$/;
|
|
14063
|
+
CASE_ATTRIBUTE_KEY_MAX_LENGTH = 64;
|
|
14064
|
+
CASE_ATTRIBUTE_TYPES = ["string", "number", "integer", "boolean"];
|
|
14065
|
+
CASE_ATTRIBUTE_FORMATS = ["date"];
|
|
14066
|
+
CASE_ATTRIBUTE_PROPERTIES_MAX = 100;
|
|
14067
|
+
CASE_ATTRIBUTE_OPTIONS_MAX = 100;
|
|
14068
|
+
CASE_ATTRIBUTE_TITLE_MAX_LENGTH = 200;
|
|
14069
|
+
CASE_ATTRIBUTE_DESCRIPTION_MAX_LENGTH = 2e3;
|
|
14070
|
+
CASE_ATTRIBUTE_OPTION_MAX_LENGTH = 200;
|
|
14071
|
+
CASE_ATTRIBUTES_MAX_CHARS = 16 * 1024;
|
|
14072
|
+
EMPTY_CASE_ATTRIBUTES_SCHEMA = { type: "object" };
|
|
14073
|
+
caseAttributePropertySchema = external_exports.object({
|
|
14074
|
+
type: external_exports.enum(CASE_ATTRIBUTE_TYPES).optional(),
|
|
14075
|
+
title: external_exports.string().min(1).max(CASE_ATTRIBUTE_TITLE_MAX_LENGTH).optional(),
|
|
14076
|
+
description: external_exports.string().max(CASE_ATTRIBUTE_DESCRIPTION_MAX_LENGTH).optional(),
|
|
14077
|
+
/** The values it may take, shown as a list to pick from. */
|
|
14078
|
+
enum: external_exports.array(external_exports.union([external_exports.string().max(CASE_ATTRIBUTE_OPTION_MAX_LENGTH), external_exports.number().finite()])).min(1).max(CASE_ATTRIBUTE_OPTIONS_MAX).optional(),
|
|
14079
|
+
/** `date`: a calendar date, `YYYY-MM-DD`. */
|
|
14080
|
+
format: external_exports.enum(CASE_ATTRIBUTE_FORMATS).optional()
|
|
14081
|
+
}).strict();
|
|
14082
|
+
attributeKey = external_exports.string().max(CASE_ATTRIBUTE_KEY_MAX_LENGTH).regex(CASE_ATTRIBUTE_KEY_PATTERN);
|
|
14083
|
+
caseAttributesSchemaSchema = external_exports.object({
|
|
14084
|
+
type: external_exports.literal("object"),
|
|
14085
|
+
properties: external_exports.record(attributeKey, caseAttributePropertySchema).refine((properties) => Object.keys(properties).length <= CASE_ATTRIBUTE_PROPERTIES_MAX, "Too many properties").optional(),
|
|
14086
|
+
required: external_exports.array(attributeKey).max(CASE_ATTRIBUTE_PROPERTIES_MAX).optional()
|
|
14087
|
+
}).strict();
|
|
14088
|
+
caseDateSchema = external_exports.string().refine(isCaseAttributeDate, "Not a date (YYYY-MM-DD)");
|
|
14089
|
+
}
|
|
14090
|
+
});
|
|
14091
|
+
|
|
14092
|
+
// ../../packages/core/dist/chunk-J3HQTL6M.js
|
|
14093
|
+
function withProblem(shape, problemOf) {
|
|
14094
|
+
return shape.superRefine((value, ctx) => {
|
|
14095
|
+
const found = problemOf(value);
|
|
14096
|
+
if (found) {
|
|
14097
|
+
ctx.addIssue({ code: external_exports.ZodIssueCode.custom, message: found.reason, path: found.at.split("."), params: { case_registry_reason: found.reason } });
|
|
14098
|
+
}
|
|
14099
|
+
});
|
|
14100
|
+
}
|
|
14101
|
+
function caseRegistryTypeProblem(type) {
|
|
14102
|
+
const found = caseAttributesSchemaProblem(type.attributes);
|
|
14103
|
+
if (found) return { reason: found.reason, at: `attributes.${found.at}` };
|
|
14104
|
+
if (JSON.stringify(type.attributes).length > CASE_REGISTRY_TYPE_SCHEMA_MAX_CHARS) return { reason: "attributes_schema_too_large", at: "attributes" };
|
|
14105
|
+
return null;
|
|
14106
|
+
}
|
|
14107
|
+
function casePartyProblem(party) {
|
|
14108
|
+
if (party.document_kind === null !== (party.document_number === null)) return { reason: "document_incomplete", at: "document_number" };
|
|
14109
|
+
if (party.document_kind === "cpf" || party.document_kind === "cnpj") {
|
|
14110
|
+
if (party.person_kind !== (party.document_kind === "cpf" ? "natural" : "legal")) return { reason: "document_person_mismatch", at: "document_kind" };
|
|
14111
|
+
if (!(party.document_kind === "cpf" ? /^[0-9]{11}$/ : /^[0-9]{14}$/).test(party.document_number ?? "")) {
|
|
14112
|
+
return { reason: "document_digits", at: "document_number" };
|
|
14113
|
+
}
|
|
14114
|
+
}
|
|
14115
|
+
return null;
|
|
14116
|
+
}
|
|
14117
|
+
function casePartyGroupProblem(group) {
|
|
14118
|
+
return new Set(group.party_ids).size === group.party_ids.length ? null : { reason: "party_repeated", at: "party_ids" };
|
|
14119
|
+
}
|
|
14120
|
+
function caseInstrumentProblem(instrument) {
|
|
14121
|
+
if (instrument.effective_from !== null && instrument.effective_until !== null && instrument.effective_until < instrument.effective_from) {
|
|
14122
|
+
return { reason: "effective_dates_reversed", at: "effective_until" };
|
|
14123
|
+
}
|
|
14124
|
+
const keys = instrument.parties.map((party) => `${party.party_id}
|
|
14125
|
+
${party.role}`);
|
|
14126
|
+
return new Set(keys).size === keys.length ? null : { reason: "instrument_party_repeated", at: "parties" };
|
|
14127
|
+
}
|
|
14128
|
+
var CASE_REGISTRY_TYPE_CODE_PATTERN, CASE_REGISTRY_TYPE_CODE_MAX_LENGTH, CASE_REGISTRY_NAME_MAX_LENGTH, CASE_REGISTRY_TYPE_SCHEMA_MAX_CHARS, CASE_PARTY_ABBREVIATION_PATTERN, CASE_PARTY_PERSON_KINDS, CASE_PARTY_DOCUMENT_KINDS, CASE_PARTY_DOCUMENT_MAX_LENGTH, CASE_PARTY_GROUP_MEMBERS_MAX, CASE_INSTRUMENT_NUMBER_MAX_LENGTH, CASE_INSTRUMENT_ROLE_MAX_LENGTH, CASE_INSTRUMENT_PARTIES_MAX, CASE_REGISTRY_PAGE_MAX, CASE_REGISTRY_QUERY_MAX_LENGTH, trimmedName, dateSchema, attributesValues, registryTypeFields, createCaseRegistryTypeShape, updateCaseRegistryTypeShape, createCaseRegistryTypeBody, updateCaseRegistryTypeBody, saveCasePartyShape, saveCasePartyBody, saveCasePartyGroupShape, saveCasePartyGroupBody, caseInstrumentPartyInput, saveCaseInstrumentShape, saveCaseInstrumentBody, registryPage, searchText, casePartiesQuery, casePartyGroupsQuery, caseInstrumentsQuery, caseRegistryTypeParam, casePartyParam, casePartyGroupParam, caseInstrumentParam;
|
|
14129
|
+
var init_chunk_J3HQTL6M = __esm({
|
|
14130
|
+
"../../packages/core/dist/chunk-J3HQTL6M.js"() {
|
|
14131
|
+
"use strict";
|
|
14132
|
+
init_chunk_M2T55BV6();
|
|
14133
|
+
init_chunk_CLGTGGVN();
|
|
14134
|
+
init_chunk_HZ6CADSY();
|
|
14135
|
+
init_zod();
|
|
14136
|
+
CASE_REGISTRY_TYPE_CODE_PATTERN = /^[a-z0-9]+(_[a-z0-9]+)*$/;
|
|
14137
|
+
CASE_REGISTRY_TYPE_CODE_MAX_LENGTH = 64;
|
|
14138
|
+
CASE_REGISTRY_NAME_MAX_LENGTH = 200;
|
|
14139
|
+
CASE_REGISTRY_TYPE_SCHEMA_MAX_CHARS = 64 * 1024;
|
|
14140
|
+
CASE_PARTY_ABBREVIATION_PATTERN = /^[A-Z0-9]{2,12}$/;
|
|
14141
|
+
CASE_PARTY_PERSON_KINDS = ["natural", "legal"];
|
|
14142
|
+
CASE_PARTY_DOCUMENT_KINDS = ["cpf", "cnpj", "other"];
|
|
14143
|
+
CASE_PARTY_DOCUMENT_MAX_LENGTH = 64;
|
|
14144
|
+
CASE_PARTY_GROUP_MEMBERS_MAX = 2e3;
|
|
14145
|
+
CASE_INSTRUMENT_NUMBER_MAX_LENGTH = 200;
|
|
14146
|
+
CASE_INSTRUMENT_ROLE_MAX_LENGTH = 200;
|
|
14147
|
+
CASE_INSTRUMENT_PARTIES_MAX = 50;
|
|
14148
|
+
CASE_REGISTRY_PAGE_MAX = 100;
|
|
14149
|
+
CASE_REGISTRY_QUERY_MAX_LENGTH = 200;
|
|
14150
|
+
trimmedName = external_exports.string().trim().min(1).max(CASE_REGISTRY_NAME_MAX_LENGTH);
|
|
14151
|
+
dateSchema = caseDateSchema;
|
|
14152
|
+
attributesValues = external_exports.record(external_exports.string(), external_exports.unknown()).default({});
|
|
14153
|
+
registryTypeFields = {
|
|
14154
|
+
name: trimmedName,
|
|
14155
|
+
attributes: caseAttributesSchemaSchema.default(EMPTY_CASE_ATTRIBUTES_SCHEMA),
|
|
14156
|
+
active: external_exports.boolean().default(true)
|
|
14157
|
+
};
|
|
14158
|
+
createCaseRegistryTypeShape = external_exports.object({
|
|
14159
|
+
code: external_exports.string().trim().max(CASE_REGISTRY_TYPE_CODE_MAX_LENGTH).regex(CASE_REGISTRY_TYPE_CODE_PATTERN),
|
|
14160
|
+
...registryTypeFields
|
|
14161
|
+
}).strict();
|
|
14162
|
+
updateCaseRegistryTypeShape = external_exports.object({
|
|
14163
|
+
...registryTypeFields,
|
|
14164
|
+
expected_updated_at: timestampSchema.optional()
|
|
14165
|
+
}).strict();
|
|
14166
|
+
createCaseRegistryTypeBody = withProblem(createCaseRegistryTypeShape, caseRegistryTypeProblem);
|
|
14167
|
+
updateCaseRegistryTypeBody = withProblem(updateCaseRegistryTypeShape, caseRegistryTypeProblem);
|
|
14168
|
+
saveCasePartyShape = external_exports.object({
|
|
14169
|
+
type_id: uuidSchema,
|
|
14170
|
+
name: trimmedName,
|
|
14171
|
+
abbreviation: external_exports.string().trim().transform((value) => value.toUpperCase()).pipe(external_exports.string().regex(CASE_PARTY_ABBREVIATION_PATTERN)).nullable().default(null),
|
|
14172
|
+
person_kind: external_exports.enum(CASE_PARTY_PERSON_KINDS),
|
|
14173
|
+
document_kind: external_exports.enum(CASE_PARTY_DOCUMENT_KINDS).nullable().default(null),
|
|
14174
|
+
document_number: external_exports.string().trim().min(1).max(CASE_PARTY_DOCUMENT_MAX_LENGTH).nullable().default(null),
|
|
14175
|
+
attributes: attributesValues,
|
|
14176
|
+
active: external_exports.boolean().default(true),
|
|
14177
|
+
expected_updated_at: timestampSchema.optional()
|
|
14178
|
+
}).strict();
|
|
14179
|
+
saveCasePartyBody = withProblem(saveCasePartyShape, casePartyProblem);
|
|
14180
|
+
saveCasePartyGroupShape = external_exports.object({
|
|
14181
|
+
name: trimmedName,
|
|
14182
|
+
party_ids: external_exports.array(uuidSchema).max(CASE_PARTY_GROUP_MEMBERS_MAX).default([]),
|
|
14183
|
+
expected_updated_at: timestampSchema.optional()
|
|
14184
|
+
}).strict();
|
|
14185
|
+
saveCasePartyGroupBody = withProblem(saveCasePartyGroupShape, casePartyGroupProblem);
|
|
14186
|
+
caseInstrumentPartyInput = external_exports.object({
|
|
14187
|
+
party_id: uuidSchema,
|
|
14188
|
+
role: external_exports.string().trim().min(1).max(CASE_INSTRUMENT_ROLE_MAX_LENGTH)
|
|
14189
|
+
}).strict();
|
|
14190
|
+
saveCaseInstrumentShape = external_exports.object({
|
|
14191
|
+
type_id: uuidSchema,
|
|
14192
|
+
number: external_exports.string().trim().min(1).max(CASE_INSTRUMENT_NUMBER_MAX_LENGTH),
|
|
14193
|
+
signed_on: dateSchema.nullable().default(null),
|
|
14194
|
+
effective_from: dateSchema.nullable().default(null),
|
|
14195
|
+
effective_until: dateSchema.nullable().default(null),
|
|
14196
|
+
attributes: attributesValues,
|
|
14197
|
+
/** Each party in a role; one party may hold several roles. */
|
|
14198
|
+
parties: external_exports.array(caseInstrumentPartyInput).max(CASE_INSTRUMENT_PARTIES_MAX).default([]),
|
|
14199
|
+
expected_updated_at: timestampSchema.optional()
|
|
14200
|
+
}).strict();
|
|
14201
|
+
saveCaseInstrumentBody = withProblem(saveCaseInstrumentShape, caseInstrumentProblem);
|
|
14202
|
+
registryPage = casePageQuery.extend({
|
|
14203
|
+
limit: external_exports.coerce.number().int().min(1).max(CASE_REGISTRY_PAGE_MAX).optional()
|
|
14204
|
+
});
|
|
14205
|
+
searchText = external_exports.string().trim().min(1).max(CASE_REGISTRY_QUERY_MAX_LENGTH).optional();
|
|
14206
|
+
casePartiesQuery = registryPage.extend({
|
|
14207
|
+
q: searchText,
|
|
14208
|
+
type_id: uuidSchema.optional(),
|
|
14209
|
+
active: external_exports.enum(["true", "false"]).transform((value) => value === "true").optional()
|
|
14210
|
+
});
|
|
14211
|
+
casePartyGroupsQuery = registryPage.extend({ q: searchText });
|
|
14212
|
+
caseInstrumentsQuery = registryPage.extend({
|
|
14213
|
+
q: searchText,
|
|
14214
|
+
type_id: uuidSchema.optional(),
|
|
14215
|
+
party_id: uuidSchema.optional()
|
|
14216
|
+
});
|
|
14217
|
+
caseRegistryTypeParam = caseSpaceParam.extend({ type_id: uuidSchema });
|
|
14218
|
+
casePartyParam = caseSpaceParam.extend({ party_id: uuidSchema });
|
|
14219
|
+
casePartyGroupParam = caseSpaceParam.extend({ group_id: uuidSchema });
|
|
14220
|
+
caseInstrumentParam = caseSpaceParam.extend({ instrument_id: uuidSchema });
|
|
14221
|
+
}
|
|
14222
|
+
});
|
|
14223
|
+
|
|
14224
|
+
// ../../packages/core/dist/chunk-6ZLXOCCY.js
|
|
14225
14225
|
function collectionUploadForm(field, shape) {
|
|
14226
14226
|
return external_exports.record(external_exports.string(), external_exports.unknown()).transform((form2, ctx) => {
|
|
14227
14227
|
const refuse2 = (message, path55) => {
|
|
@@ -14261,12 +14261,12 @@ function caseCollectionFileName(sent) {
|
|
|
14261
14261
|
return name || "document";
|
|
14262
14262
|
}
|
|
14263
14263
|
var CASE_COLLECTION_FOLDERS, CASE_COLLECTION_PARTS, isCaseCollectionPart, CASE_COLLECTION_TITLE_MAX_LENGTH, CASE_COLLECTION_TYPE_MAX_LENGTH, CASE_COLLECTION_REASON_MAX_LENGTH, CASE_COLLECTION_FILE_NAME_MAX_LENGTH, caseCollectionDocumentParam, dateOnly, title, registerCaseCollectionDocumentShape, addCaseCollectionVersionShape, CASE_COLLECTION_UPLOAD_BODY_MAX_BYTES, CASE_COLLECTION_DOCUMENT_FIELD, CASE_COLLECTION_VERSION_FIELD, caseCollectionDocumentUploadForm, caseCollectionVersionUploadForm, CASE_COLLECTION_PAGE_MAX, CASE_COLLECTION_CURSOR_MAX_LENGTH, caseCollectionQuery, CASE_COLLECTION_VERSIONS_PAGE_MAX, caseCollectionVersionsQuery, caseCollectionContentQuery;
|
|
14264
|
-
var
|
|
14265
|
-
"../../packages/core/dist/chunk-
|
|
14264
|
+
var init_chunk_6ZLXOCCY = __esm({
|
|
14265
|
+
"../../packages/core/dist/chunk-6ZLXOCCY.js"() {
|
|
14266
14266
|
"use strict";
|
|
14267
|
+
init_chunk_A5TJEV6T();
|
|
14267
14268
|
init_chunk_J3HQTL6M();
|
|
14268
|
-
|
|
14269
|
-
init_chunk_HPZOVPVT();
|
|
14269
|
+
init_chunk_MQQRYOE6();
|
|
14270
14270
|
init_chunk_M2T55BV6();
|
|
14271
14271
|
init_chunk_CLGTGGVN();
|
|
14272
14272
|
init_chunk_HZ6CADSY();
|
|
@@ -14327,7 +14327,7 @@ var init_chunk_YMFTFCT5 = __esm({
|
|
|
14327
14327
|
}
|
|
14328
14328
|
});
|
|
14329
14329
|
|
|
14330
|
-
// ../../packages/core/dist/chunk-
|
|
14330
|
+
// ../../packages/core/dist/chunk-BALYF7RA.js
|
|
14331
14331
|
function resolveItemLink(phaseFolder, target) {
|
|
14332
14332
|
const slash = target.lastIndexOf("/");
|
|
14333
14333
|
const folder = slash < 0 ? phaseFolder : target.slice(0, slash);
|
|
@@ -14552,12 +14552,12 @@ function caseTypeDefinitionReasonOf(error) {
|
|
|
14552
14552
|
return first && reason3 ? { reason: reason3, at: first.path.join(".") } : null;
|
|
14553
14553
|
}
|
|
14554
14554
|
var CASE_CODE_PATTERN, CASE_PHASE_CODE_PATTERN, CASE_PHASE_FOLDER_PATTERN, CASE_INPUT_KEY_PATTERN, CASE_CALCULATION_CODE_PATTERN, CASE_AGENDA_GROUP_CODE_PATTERN, CASE_DECISION_CODE_PATTERN, CASE_DECISION_OPTION_CODE_PATTERN, CASE_DECISION_EFFECT_PATTERN, FILE_PATH_SEGMENT_PATTERN, CASE_REVIEW_MODES, CASE_OUTPUT_FORMATS, CASE_INPUT_ORIGINS, CASE_TEMPLATE_MODES, CASE_AGENDA_QUORUMS, CASE_DECISION_TYPES, CASE_NUMERIC_DECISION_TYPES, CASE_TYPE_NAME_MAX_LENGTH, CASE_CODE_MAX_LENGTH, CASE_FILE_PATH_MAX_LENGTH, CASE_TASK_NAME_MAX_LENGTH, CASE_TASK_DEPENDENCIES_MAX, CASE_FIXED_TEXT_MAX_LENGTH, CASE_TYPE_DEFINITION_MAX_CHARS, CASE_TYPE_DEFINITION_ROWS_MAX, CASE_TYPE_VERSIONS_MAX, CASE_TYPES_PAGE_MAX, code, phaseCode, inputKey, caseAgendaGroupCodeSchema, caseDecisionCodeSchema, decisionCode, label2, optionalText, itemLinkTarget, filePath, caseTypePartyRoleSchema, caseTypeOutcomeSchema, caseItemRequirementsSchema, caseItemLinksSchema, caseOutputItemSchema, casePhaseOutputSchema, casePhaseInputSchema, caseDecisionOptionSchema, decisionBound, caseAgendaDecisionSchema, caseAgendaGroupSchema, caseTypeTaskSchema, caseTypePhaseSchema, caseTypeDefinitionShape, caseValuesRepeated, CHAPTER_PROBE, caseTypeDefinitionSchema, caseTypeAbbreviationSchema, caseTypeNameSchema, createCaseTypeBody, publishCaseTypeVersionBody, setCaseTypeActiveBody, caseTypeParam, caseTypesPageQuery, caseTypeVersionQuery, CASE_TYPE_VERSION_CONFLICT_REASON;
|
|
14555
|
-
var
|
|
14556
|
-
"../../packages/core/dist/chunk-
|
|
14555
|
+
var init_chunk_BALYF7RA = __esm({
|
|
14556
|
+
"../../packages/core/dist/chunk-BALYF7RA.js"() {
|
|
14557
14557
|
"use strict";
|
|
14558
|
+
init_chunk_KWRHZBGU();
|
|
14558
14559
|
init_chunk_M2T55BV6();
|
|
14559
14560
|
init_chunk_CLGTGGVN();
|
|
14560
|
-
init_chunk_KWRHZBGU();
|
|
14561
14561
|
init_chunk_HZ6CADSY();
|
|
14562
14562
|
init_chunk_ZTNFLGW5();
|
|
14563
14563
|
init_zod();
|
|
@@ -14768,7 +14768,7 @@ var init_chunk_MCLSEATL = __esm({
|
|
|
14768
14768
|
}
|
|
14769
14769
|
});
|
|
14770
14770
|
|
|
14771
|
-
// ../../packages/core/dist/chunk-
|
|
14771
|
+
// ../../packages/core/dist/chunk-ASIBSUKC.js
|
|
14772
14772
|
function openCaseProblem(body) {
|
|
14773
14773
|
const pairs = /* @__PURE__ */ new Set();
|
|
14774
14774
|
for (const [index, party] of body.parties.entries()) {
|
|
@@ -14781,10 +14781,10 @@ ${party.role}`;
|
|
|
14781
14781
|
return null;
|
|
14782
14782
|
}
|
|
14783
14783
|
var CASE_RECORD_CODE_PATTERN, CASE_RECORD_CODE_MAX_LENGTH, CASE_RECORD_PARTIES_MAX, CASE_RECORD_INSTRUMENTS_MAX, CASE_RECORD_ROLE_MAX_LENGTH, CASE_RECORDS_PAGE_MAX, CASE_RECORDS_QUERY_MAX_LENGTH, caseRecordPartySchema, openCaseShape, openCaseBody, previewOpenCaseShape, caseRecordParam, CASE_RECORD_STATUSES, caseRecordsQuery, CASE_STATE_SUMMARIES_MAX, caseStatesQuery, CASE_CLOSED_REASON, CASE_CLOSURE_REASON_MAX_LENGTH, closeCaseBody, setCaseConfidentialityBody;
|
|
14784
|
-
var
|
|
14785
|
-
"../../packages/core/dist/chunk-
|
|
14784
|
+
var init_chunk_ASIBSUKC = __esm({
|
|
14785
|
+
"../../packages/core/dist/chunk-ASIBSUKC.js"() {
|
|
14786
14786
|
"use strict";
|
|
14787
|
-
|
|
14787
|
+
init_chunk_BALYF7RA();
|
|
14788
14788
|
init_chunk_CLGTGGVN();
|
|
14789
14789
|
init_chunk_HZ6CADSY();
|
|
14790
14790
|
init_chunk_ZTNFLGW5();
|
|
@@ -14845,7 +14845,7 @@ var init_chunk_UGKJPB2J = __esm({
|
|
|
14845
14845
|
}
|
|
14846
14846
|
});
|
|
14847
14847
|
|
|
14848
|
-
// ../../packages/core/dist/chunk-
|
|
14848
|
+
// ../../packages/core/dist/chunk-LBCPN6IM.js
|
|
14849
14849
|
function caseReceivedFormat(fileName) {
|
|
14850
14850
|
const dot = fileName.lastIndexOf(".");
|
|
14851
14851
|
if (dot < 0) return null;
|
|
@@ -14853,13 +14853,13 @@ function caseReceivedFormat(fileName) {
|
|
|
14853
14853
|
return isCaseReceivedFormat(extension) ? extension : null;
|
|
14854
14854
|
}
|
|
14855
14855
|
var ZIP_SIGNATURE, CASE_RECEIVED_FORMATS, isCaseReceivedFormat, CASE_RECEIVED_PARTS, CASE_RECEIVED_TITLE_MAX_LENGTH, CASE_RECEIVED_TYPE_MAX_LENGTH, CASE_RECEIVED_TEXT_MAX_BYTES, CASE_RECEIVED_UPLOAD_BODY_MAX_BYTES, CASE_RECEIVED_DOCUMENT_FIELD, caseReceivedParam, registerCaseReceivedDocumentShape, caseReceivedUploadForm, caseReceivedFileName, ZIP_DIRECTORY_MAX_BYTES, CONTENT_TYPES_MAX_BYTES, CONTENT_TYPES_INFLATED_MAX_BYTES, CASE_RECEIVED_PAGE_MAX, caseReceivedQuery, caseReceivedContentQuery;
|
|
14856
|
-
var
|
|
14857
|
-
"../../packages/core/dist/chunk-
|
|
14856
|
+
var init_chunk_LBCPN6IM = __esm({
|
|
14857
|
+
"../../packages/core/dist/chunk-LBCPN6IM.js"() {
|
|
14858
14858
|
"use strict";
|
|
14859
|
-
|
|
14860
|
-
|
|
14861
|
-
|
|
14862
|
-
|
|
14859
|
+
init_chunk_6ZLXOCCY();
|
|
14860
|
+
init_chunk_A5TJEV6T();
|
|
14861
|
+
init_chunk_MQQRYOE6();
|
|
14862
|
+
init_chunk_ASIBSUKC();
|
|
14863
14863
|
init_chunk_CLGTGGVN();
|
|
14864
14864
|
init_chunk_HZ6CADSY();
|
|
14865
14865
|
init_zod();
|
|
@@ -14934,25 +14934,14 @@ var init_chunk_BE4ATZB7 = __esm({
|
|
|
14934
14934
|
}
|
|
14935
14935
|
});
|
|
14936
14936
|
|
|
14937
|
-
// ../../packages/core/dist/chunk-
|
|
14938
|
-
var casePhaseParam;
|
|
14939
|
-
var init_chunk_COZBA6Z4 = __esm({
|
|
14940
|
-
"../../packages/core/dist/chunk-COZBA6Z4.js"() {
|
|
14941
|
-
"use strict";
|
|
14942
|
-
init_chunk_UGKJPB2J();
|
|
14943
|
-
init_chunk_HZ6CADSY();
|
|
14944
|
-
casePhaseParam = caseRecordParam.extend({ phase_id: uuidSchema });
|
|
14945
|
-
}
|
|
14946
|
-
});
|
|
14947
|
-
|
|
14948
|
-
// ../../packages/core/dist/chunk-6ITRMGLQ.js
|
|
14937
|
+
// ../../packages/core/dist/chunk-ZIYKQK52.js
|
|
14949
14938
|
var CASE_OFFICIAL_FILE_KINDS, CASE_OFFICIAL_FILE_NAME_PATTERN, publishCaseSubmissionBody, caseOfficialVersionParam, caseOfficialFileQuery;
|
|
14950
|
-
var
|
|
14951
|
-
"../../packages/core/dist/chunk-
|
|
14939
|
+
var init_chunk_ZIYKQK52 = __esm({
|
|
14940
|
+
"../../packages/core/dist/chunk-ZIYKQK52.js"() {
|
|
14952
14941
|
"use strict";
|
|
14953
14942
|
init_chunk_YR7QALGP();
|
|
14954
|
-
|
|
14955
|
-
|
|
14943
|
+
init_chunk_MQQRYOE6();
|
|
14944
|
+
init_chunk_ASIBSUKC();
|
|
14956
14945
|
init_chunk_HZ6CADSY();
|
|
14957
14946
|
init_zod();
|
|
14958
14947
|
CASE_OFFICIAL_FILE_KINDS = [...CASE_SUBMISSION_ISSUED_KINDS, "file"];
|
|
@@ -14966,6 +14955,17 @@ var init_chunk_6ITRMGLQ = __esm({
|
|
|
14966
14955
|
}
|
|
14967
14956
|
});
|
|
14968
14957
|
|
|
14958
|
+
// ../../packages/core/dist/chunk-MXEJT22F.js
|
|
14959
|
+
var casePhaseParam;
|
|
14960
|
+
var init_chunk_MXEJT22F = __esm({
|
|
14961
|
+
"../../packages/core/dist/chunk-MXEJT22F.js"() {
|
|
14962
|
+
"use strict";
|
|
14963
|
+
init_chunk_ASIBSUKC();
|
|
14964
|
+
init_chunk_HZ6CADSY();
|
|
14965
|
+
casePhaseParam = caseRecordParam.extend({ phase_id: uuidSchema });
|
|
14966
|
+
}
|
|
14967
|
+
});
|
|
14968
|
+
|
|
14969
14969
|
// ../../packages/core/dist/chunk-64HCHXKB.js
|
|
14970
14970
|
var CASE_CHECK_CSV_MAX_BYTES, CASE_DECISIONS_CSV_PATH, CASE_CONFIDENTIAL_DECISIONS_CSV_PATH, caseChecksQuery;
|
|
14971
14971
|
var init_chunk_64HCHXKB = __esm({
|
|
@@ -14983,17 +14983,17 @@ var init_chunk_64HCHXKB = __esm({
|
|
|
14983
14983
|
}
|
|
14984
14984
|
});
|
|
14985
14985
|
|
|
14986
|
-
// ../../packages/core/dist/chunk-
|
|
14986
|
+
// ../../packages/core/dist/chunk-OW6A2JRU.js
|
|
14987
14987
|
var CASE_REVIEW_DECISIONS, CASE_ISSUED_FORMATS, CASE_REVIEW_COMMENT_MAX_LENGTH, CASE_REVIEW_JUSTIFICATION_MAX_LENGTH, text2, caseSubmissionParam, decideCaseSubmissionBody, caseIssuedQuery, CASE_APPROVALS_STATES, caseApprovalsQuery, caseCompareDefaultQuery, caseApprovalsAgendaQuery;
|
|
14988
|
-
var
|
|
14989
|
-
"../../packages/core/dist/chunk-
|
|
14988
|
+
var init_chunk_OW6A2JRU = __esm({
|
|
14989
|
+
"../../packages/core/dist/chunk-OW6A2JRU.js"() {
|
|
14990
14990
|
"use strict";
|
|
14991
|
-
|
|
14992
|
-
|
|
14991
|
+
init_chunk_ZIYKQK52();
|
|
14992
|
+
init_chunk_MXEJT22F();
|
|
14993
14993
|
init_chunk_64HCHXKB();
|
|
14994
14994
|
init_chunk_YR7QALGP();
|
|
14995
|
-
|
|
14996
|
-
|
|
14995
|
+
init_chunk_MQQRYOE6();
|
|
14996
|
+
init_chunk_ASIBSUKC();
|
|
14997
14997
|
init_chunk_CLGTGGVN();
|
|
14998
14998
|
init_chunk_HZ6CADSY();
|
|
14999
14999
|
init_zod();
|
|
@@ -15063,15 +15063,15 @@ var init_chunk_26PIYACX = __esm({
|
|
|
15063
15063
|
}
|
|
15064
15064
|
});
|
|
15065
15065
|
|
|
15066
|
-
// ../../packages/core/dist/chunk-
|
|
15066
|
+
// ../../packages/core/dist/chunk-RUESJZ26.js
|
|
15067
15067
|
function addCaseNoteProblem(note) {
|
|
15068
15068
|
return note.origin !== null && note.kind !== "contribution" ? { reason: "origin_not_contribution", at: "origin" } : null;
|
|
15069
15069
|
}
|
|
15070
15070
|
var CASE_NOTE_KINDS, CASE_NOTE_TEXT_MAX_LENGTH, CASE_NOTE_ORIGIN_MAX_LENGTH, CASE_NOTES_PAGE_MAX, addCaseNoteShape, addCaseNoteBody, caseNoteParam, caseTaskParam, caseNotesQuery;
|
|
15071
|
-
var
|
|
15072
|
-
"../../packages/core/dist/chunk-
|
|
15071
|
+
var init_chunk_RUESJZ26 = __esm({
|
|
15072
|
+
"../../packages/core/dist/chunk-RUESJZ26.js"() {
|
|
15073
15073
|
"use strict";
|
|
15074
|
-
|
|
15074
|
+
init_chunk_ASIBSUKC();
|
|
15075
15075
|
init_chunk_CLGTGGVN();
|
|
15076
15076
|
init_chunk_HZ6CADSY();
|
|
15077
15077
|
init_zod();
|
|
@@ -15101,18 +15101,18 @@ var init_chunk_7JYZW5BH = __esm({
|
|
|
15101
15101
|
}
|
|
15102
15102
|
});
|
|
15103
15103
|
|
|
15104
|
-
// ../../packages/core/dist/chunk-
|
|
15104
|
+
// ../../packages/core/dist/chunk-KFKBWZLE.js
|
|
15105
15105
|
function casePassageLines(text5) {
|
|
15106
15106
|
const lines2 = text5.replace(/\r\n/g, "\n").split("\n");
|
|
15107
15107
|
if (lines2.at(-1) === "") lines2.pop();
|
|
15108
15108
|
return lines2;
|
|
15109
15109
|
}
|
|
15110
15110
|
var CASE_COMMENT_TEXT_MAX_LENGTH, CASE_COMMENTS_PAGE_MAX, CASE_COMMENT_LINE_MAX, casePassageLineSchema, lineNumber, addCaseCommentShape, CASE_COMMENT_REVERSED_REASON, addCaseCommentBody, caseCommentsQuery, CASE_COMMENT_OUT_OF_RANGE_REASON, CASE_COMMENT_NOT_TEXT_REASON, CASE_COMMENT_DOCUMENT_TOO_LARGE_REASON;
|
|
15111
|
-
var
|
|
15112
|
-
"../../packages/core/dist/chunk-
|
|
15111
|
+
var init_chunk_KFKBWZLE = __esm({
|
|
15112
|
+
"../../packages/core/dist/chunk-KFKBWZLE.js"() {
|
|
15113
15113
|
"use strict";
|
|
15114
|
-
|
|
15115
|
-
|
|
15114
|
+
init_chunk_RUESJZ26();
|
|
15115
|
+
init_chunk_MQQRYOE6();
|
|
15116
15116
|
init_chunk_CLGTGGVN();
|
|
15117
15117
|
init_chunk_HZ6CADSY();
|
|
15118
15118
|
init_zod();
|
|
@@ -15150,12 +15150,12 @@ var init_chunk_BN7WSDWC = __esm({
|
|
|
15150
15150
|
}
|
|
15151
15151
|
});
|
|
15152
15152
|
|
|
15153
|
-
// ../../packages/core/dist/chunk-
|
|
15153
|
+
// ../../packages/core/dist/chunk-2HOHGYWQ.js
|
|
15154
15154
|
var CASE_VERSION_DECISION_REASON_MAX_LENGTH, CASE_VERSION_DECISIONS, caseVersionDecisionReason, reason, lineNumber2, recordCaseReferenceBody, CASE_PASSAGE_REVERSED_REASON, citeCasePassageBody, decideCaseVersionBody, CASE_PASSAGE_LINK_REQUIRED_REASON, CASE_PASSAGE_LINK_CHANGED_REASON, CASE_PASSAGE_NO_TEXT_REASON, CASE_PASSAGE_TEXT_TOO_LARGE_REASON, CASE_PASSAGE_NOT_TEXT_REASON, CASE_PASSAGE_OUT_OF_RANGE_REASON;
|
|
15155
|
-
var
|
|
15156
|
-
"../../packages/core/dist/chunk-
|
|
15155
|
+
var init_chunk_2HOHGYWQ = __esm({
|
|
15156
|
+
"../../packages/core/dist/chunk-2HOHGYWQ.js"() {
|
|
15157
15157
|
"use strict";
|
|
15158
|
-
|
|
15158
|
+
init_chunk_KFKBWZLE();
|
|
15159
15159
|
init_chunk_HZ6CADSY();
|
|
15160
15160
|
init_zod();
|
|
15161
15161
|
CASE_VERSION_DECISION_REASON_MAX_LENGTH = 2e3;
|
|
@@ -15194,13 +15194,13 @@ var init_chunk_CSHU2GN3 = __esm({
|
|
|
15194
15194
|
}
|
|
15195
15195
|
});
|
|
15196
15196
|
|
|
15197
|
-
// ../../packages/core/dist/chunk-
|
|
15197
|
+
// ../../packages/core/dist/chunk-XE7BAV42.js
|
|
15198
15198
|
var lines, ordered, citeCaseOfficialVersionPassageBody, citeCaseReceivedPassageBody, citeCaseSourcePassageBody, citeCaseInputPassageBody, caseSourceRefSchema;
|
|
15199
|
-
var
|
|
15200
|
-
"../../packages/core/dist/chunk-
|
|
15199
|
+
var init_chunk_XE7BAV42 = __esm({
|
|
15200
|
+
"../../packages/core/dist/chunk-XE7BAV42.js"() {
|
|
15201
15201
|
"use strict";
|
|
15202
|
-
|
|
15203
|
-
|
|
15202
|
+
init_chunk_2HOHGYWQ();
|
|
15203
|
+
init_chunk_KFKBWZLE();
|
|
15204
15204
|
init_chunk_HZ6CADSY();
|
|
15205
15205
|
init_zod();
|
|
15206
15206
|
lines = { line_start: casePassageLineSchema, line_end: casePassageLineSchema };
|
|
@@ -15218,12 +15218,12 @@ var init_chunk_YCVI6W6V = __esm({
|
|
|
15218
15218
|
}
|
|
15219
15219
|
});
|
|
15220
15220
|
|
|
15221
|
-
// ../../packages/core/dist/chunk-
|
|
15221
|
+
// ../../packages/core/dist/chunk-MRSQ7PBE.js
|
|
15222
15222
|
var CASE_RELATION_TYPE_CODE_PATTERN, CASE_RELATION_TYPE_CODE_MAX_LENGTH, CASE_RELATION_TYPE_NAME_MAX_LENGTH, CASE_RELATION_TYPES_PER_SPACE_MAX, CASE_RELATION_DESCRIPTION_MAX_LENGTH, CASE_RELATION_SIDES, CASE_EXTERNAL_SYSTEM_PATTERN, CASE_EXTERNAL_NUMBER_MAX_LENGTH, CASE_EXTERNAL_URL_MAX_LENGTH, trimmedName2, relationTypeFields, createCaseRelationTypeBody, updateCaseRelationTypeBody, relateCasesBody, addCaseExternalReferenceBody, caseRelationTypeParam, caseRelationParam, caseExternalReferenceParam, caseRelationTypesQuery;
|
|
15223
|
-
var
|
|
15224
|
-
"../../packages/core/dist/chunk-
|
|
15223
|
+
var init_chunk_MRSQ7PBE = __esm({
|
|
15224
|
+
"../../packages/core/dist/chunk-MRSQ7PBE.js"() {
|
|
15225
15225
|
"use strict";
|
|
15226
|
-
|
|
15226
|
+
init_chunk_ASIBSUKC();
|
|
15227
15227
|
init_chunk_CLGTGGVN();
|
|
15228
15228
|
init_chunk_HZ6CADSY();
|
|
15229
15229
|
init_zod();
|
|
@@ -15264,12 +15264,12 @@ var init_chunk_4MH4X3D4 = __esm({
|
|
|
15264
15264
|
}
|
|
15265
15265
|
});
|
|
15266
15266
|
|
|
15267
|
-
// ../../packages/core/dist/chunk-
|
|
15267
|
+
// ../../packages/core/dist/chunk-EUDNN2RS.js
|
|
15268
15268
|
var CASE_CHANGE_TOPICS, caseChangedFrameSchema;
|
|
15269
|
-
var
|
|
15270
|
-
"../../packages/core/dist/chunk-
|
|
15269
|
+
var init_chunk_EUDNN2RS = __esm({
|
|
15270
|
+
"../../packages/core/dist/chunk-EUDNN2RS.js"() {
|
|
15271
15271
|
"use strict";
|
|
15272
|
-
|
|
15272
|
+
init_chunk_ASIBSUKC();
|
|
15273
15273
|
init_chunk_HZ6CADSY();
|
|
15274
15274
|
init_zod();
|
|
15275
15275
|
CASE_CHANGE_TOPICS = ["submission", "agenda", "review", "access"];
|
|
@@ -15297,14 +15297,14 @@ var init_chunk_PSY4BJ7E = __esm({
|
|
|
15297
15297
|
}
|
|
15298
15298
|
});
|
|
15299
15299
|
|
|
15300
|
-
// ../../packages/core/dist/chunk-
|
|
15300
|
+
// ../../packages/core/dist/chunk-3P2DTRI4.js
|
|
15301
15301
|
var caseInputLinkParam, caseCollectionDocumentOfCaseParam, linkCaseCollectionInputBody, linkCasePreviousOutputInputBody, linkCaseReceivedInputBody, linkCaseInputBody, CASE_LINK_OFFICIAL_VERSION_UNKNOWN_REASON, CASE_LINK_OUTPUT_NOT_PRIOR_REASON, CASE_LINK_RECEIVED_UNKNOWN_REASON, CASE_LINK_DOCUMENT_TYPE_MISMATCH_REASON, CASE_LINK_VERSION_NOT_CURRENT_REASON, CASE_COLLECTION_CASES_PAGE_MAX, caseCollectionCasesQuery, CASE_REFERENCES_PAGE_MAX, caseReferencesQuery;
|
|
15302
|
-
var
|
|
15303
|
-
"../../packages/core/dist/chunk-
|
|
15302
|
+
var init_chunk_3P2DTRI4 = __esm({
|
|
15303
|
+
"../../packages/core/dist/chunk-3P2DTRI4.js"() {
|
|
15304
15304
|
"use strict";
|
|
15305
|
-
|
|
15306
|
-
|
|
15307
|
-
|
|
15305
|
+
init_chunk_2HOHGYWQ();
|
|
15306
|
+
init_chunk_6ZLXOCCY();
|
|
15307
|
+
init_chunk_ASIBSUKC();
|
|
15308
15308
|
init_chunk_CLGTGGVN();
|
|
15309
15309
|
init_chunk_HZ6CADSY();
|
|
15310
15310
|
init_zod();
|
|
@@ -15467,12 +15467,12 @@ var init_chunk_GCPFVAXX = __esm({
|
|
|
15467
15467
|
}
|
|
15468
15468
|
});
|
|
15469
15469
|
|
|
15470
|
-
// ../../packages/core/dist/chunk-
|
|
15470
|
+
// ../../packages/core/dist/chunk-SPIVW22L.js
|
|
15471
15471
|
var CASE_ADJUSTMENT_REASON_MAX_LENGTH, CASE_ADJUSTMENT_DISPENSATION_KINDS, reason2, activateCasePhaseBody, dispenseCaseBody, addCaseTaskBody, addCaseInputBody, caseOwnItemSchema, addCaseItemBody;
|
|
15472
|
-
var
|
|
15473
|
-
"../../packages/core/dist/chunk-
|
|
15472
|
+
var init_chunk_SPIVW22L = __esm({
|
|
15473
|
+
"../../packages/core/dist/chunk-SPIVW22L.js"() {
|
|
15474
15474
|
"use strict";
|
|
15475
|
-
|
|
15475
|
+
init_chunk_BALYF7RA();
|
|
15476
15476
|
init_chunk_HZ6CADSY();
|
|
15477
15477
|
init_zod();
|
|
15478
15478
|
CASE_ADJUSTMENT_REASON_MAX_LENGTH = 2e3;
|
|
@@ -15503,13 +15503,13 @@ var init_chunk_UMM5CTTH = __esm({
|
|
|
15503
15503
|
}
|
|
15504
15504
|
});
|
|
15505
15505
|
|
|
15506
|
-
// ../../packages/core/dist/chunk-
|
|
15506
|
+
// ../../packages/core/dist/chunk-LMRE5GNU.js
|
|
15507
15507
|
var CASE_AGENDA_VALUE_MAX_LENGTH, CASE_AGENDA_JUSTIFICATION_MAX_LENGTH, CASE_AGENDA_EVIDENCE_MAX_LENGTH, CASE_AGENDA_COMMENT_MAX_LENGTH, CASE_AGENDA_VERDICTS, comment, caseAgendaGroupParam, caseAgendaDecisionParam, caseAgendaQuery, caseApprovedDecisionsQuery, proposeCaseAgendaValueBody, decideCaseAgendaBody, dispenseCaseAgendaBody, addCaseDecisionBody;
|
|
15508
|
-
var
|
|
15509
|
-
"../../packages/core/dist/chunk-
|
|
15508
|
+
var init_chunk_LMRE5GNU = __esm({
|
|
15509
|
+
"../../packages/core/dist/chunk-LMRE5GNU.js"() {
|
|
15510
15510
|
"use strict";
|
|
15511
|
-
|
|
15512
|
-
|
|
15511
|
+
init_chunk_ASIBSUKC();
|
|
15512
|
+
init_chunk_BALYF7RA();
|
|
15513
15513
|
init_chunk_M2T55BV6();
|
|
15514
15514
|
init_chunk_CLGTGGVN();
|
|
15515
15515
|
init_chunk_HZ6CADSY();
|
|
@@ -17405,7 +17405,7 @@ var init_chunk_2ISUBJG7 = __esm({
|
|
|
17405
17405
|
}
|
|
17406
17406
|
});
|
|
17407
17407
|
|
|
17408
|
-
// ../../packages/core/dist/chunk-
|
|
17408
|
+
// ../../packages/core/dist/chunk-NF2TUBZ4.js
|
|
17409
17409
|
function describeRole(role) {
|
|
17410
17410
|
if (typeof role === "string") {
|
|
17411
17411
|
return JSON.stringify(role.length > ROLE_ECHO_MAX ? `${role.slice(0, ROLE_ECHO_MAX)}\u2026` : role);
|
|
@@ -17583,9 +17583,9 @@ function unprovenRunCount(counts) {
|
|
|
17583
17583
|
function terminalRunCount(counts) {
|
|
17584
17584
|
return counts.successful_runs + counts.failed_runs;
|
|
17585
17585
|
}
|
|
17586
|
-
var evalIdParam, sessionIdParam, scenarioSetIdParam, hubIdQuery, EVAL_FIXTURE_NAME_MAX_LENGTH, evalFixtureOverrideSchema, runSessionQuery, runJourneyQuery, EVAL_INPUT_ROLES, EVAL_INPUT_ROLE_LIST, ROLE_ECHO_MAX, EVAL_INITIAL_STATE_SCOPES, MAX_INITIAL_STATE_ENTRIES, evalInitialStateEntry, EVAL_PERSON_MAX, evalPersonSchema, EVAL_PERSON_ALIAS_RETIRED, EVAL_PERSON_ALIAS_REFUSED, evalBody, EVAL_LIST_MAX_LIMIT, evalListLimit, getEvalsQuery, toggleEvalBody, bulkToggleEvalsBody, pacingConfigSchema, EVAL_MAX_SELECTED_SCENARIOS, evalScenarioSelectionEntrySchema, evalScenarioSelectionSchema, sessionConfigSchema, createSessionBody, getSessionsQuery, getSessionResultsQuery, getSessionRunsQuery, evalAnalyticsQuery, getSessionCostQuery, compareSessionsQuery, evalsSqlBody, evalsSqlSchemaQuery, exportResultsQuery, validateEvalBody, hubAgentsQuery, createScenarioSetBody, updateScenarioSetBody, scenarioSetsHubQuery, createScenarioFromConversationBody, createJourneyFromConversationBody, evalAttachmentRef, turnMayCarryAttachments, ATTACHMENTS_USER_ONLY_MESSAGE, journeyIdParam, journeyToolCallSchema, journeyTurnSchema, journeyStepOverrideSchema, fixtureField, createJourneyBody, updateJourneyBody, evalSessionConfigResponseSchema, evalSessionResponseSchema, evalSessionListConfigSchema, evalSessionListItemSchema, seedReleaseStatusSchema, EVAL_SESSION_NOT_QUIESCENT;
|
|
17587
|
-
var
|
|
17588
|
-
"../../packages/core/dist/chunk-
|
|
17586
|
+
var evalIdParam, sessionIdParam, scenarioSetIdParam, hubIdQuery, EVAL_FIXTURE_NAME_MAX_LENGTH, evalFixtureOverrideSchema, runSessionQuery, runJourneyQuery, EVAL_INPUT_ROLES, EVAL_INPUT_ROLE_LIST, ROLE_ECHO_MAX, EVAL_INITIAL_STATE_SCOPES, MAX_INITIAL_STATE_ENTRIES, evalInitialStateEntry, EVAL_PERSON_MAX, evalPersonSchema, EVAL_PERSON_ALIAS_RETIRED, EVAL_PERSON_ALIAS_REFUSED, evalBody, EVAL_LIST_MAX_LIMIT, evalListLimit, getEvalsQuery, toggleEvalBody, bulkToggleEvalsBody, pacingConfigSchema, EVAL_MAX_SELECTED_SCENARIOS, evalScenarioSelectionEntrySchema, evalScenarioSelectionSchema, sessionConfigSchema, createSessionBody, getSessionsQuery, getSessionResultsQuery, getSessionRunsQuery, evalAnalyticsQuery, getSessionCostQuery, compareSessionsQuery, evalsSqlBody, evalsSqlSchemaQuery, exportResultsQuery, validateEvalBody, hubAgentsQuery, createScenarioSetBody, updateScenarioSetBody, scenarioSetsHubQuery, createScenarioFromConversationBody, createJourneyFromConversationBody, evalAttachmentRef, turnMayCarryAttachments, ATTACHMENTS_USER_ONLY_MESSAGE, journeyIdParam, journeyToolCallSchema, evalMessageRoleSchema, journeyTurnSchema, journeyStepOverrideSchema, fixtureField, createJourneyBody, updateJourneyBody, sessionStatusSchema, runStatusSchema, toolCallResponseSchema, messageHistoryItemResponseSchema, expectedResponseDataSchema, evalResponseDataSchema, evalInitialStateResponseEntry, evalResponseSchema, EVAL_RUN_OUTCOME_KINDS, evalWithAgentResponseSchema, evalSessionConfigResponseSchema, evalSessionResponseSchema, evalSessionListConfigSchema, evalSessionListItemSchema, evalSessionResultResponseSchema, evalSessionRunResponseSchema, evalPaginationResponseSchema, getEvalsResponseSchema, getSessionsResponseSchema, createSessionResponseSchema, SEED_LEASE_WARNINGS, runSessionResponseSchema, seedReleaseStatusSchema, stopSessionResponseSchema, EVAL_SESSION_NOT_QUIESCENT, deleteSessionResponseSchema, deleteAllSessionsResponseSchema, getSessionDetailsResponseSchema, getSessionRunsResponseSchema, createScenarioFromConversationResponseSchema;
|
|
17587
|
+
var init_chunk_NF2TUBZ4 = __esm({
|
|
17588
|
+
"../../packages/core/dist/chunk-NF2TUBZ4.js"() {
|
|
17589
17589
|
"use strict";
|
|
17590
17590
|
init_chunk_2YEGUQR7();
|
|
17591
17591
|
init_chunk_AHISKXHA();
|
|
@@ -17792,8 +17792,9 @@ var init_chunk_5YZ3R7KF = __esm({
|
|
|
17792
17792
|
type: external_exports.literal("function"),
|
|
17793
17793
|
function: external_exports.object({ name: external_exports.string(), arguments: external_exports.string() })
|
|
17794
17794
|
});
|
|
17795
|
+
evalMessageRoleSchema = external_exports.enum(["system", "user", "assistant", "tool"]);
|
|
17795
17796
|
journeyTurnSchema = external_exports.object({
|
|
17796
|
-
role:
|
|
17797
|
+
role: evalMessageRoleSchema,
|
|
17797
17798
|
content: external_exports.string().nullable().optional(),
|
|
17798
17799
|
tool_calls: external_exports.array(journeyToolCallSchema).optional(),
|
|
17799
17800
|
tool_call_id: external_exports.string().optional(),
|
|
@@ -17828,6 +17829,93 @@ var init_chunk_5YZ3R7KF = __esm({
|
|
|
17828
17829
|
fixture: fixtureField.nullable().optional(),
|
|
17829
17830
|
target_base: fixtureField.nullable().optional()
|
|
17830
17831
|
});
|
|
17832
|
+
sessionStatusSchema = external_exports.enum(["draft", "agents_responding", "awaiting_review", "completed", "failed", "cancelled"]);
|
|
17833
|
+
runStatusSchema = external_exports.enum(["pending", "running", "agent_responded", "completed", "failed"]);
|
|
17834
|
+
toolCallResponseSchema = journeyToolCallSchema;
|
|
17835
|
+
messageHistoryItemResponseSchema = external_exports.object({
|
|
17836
|
+
role: evalMessageRoleSchema,
|
|
17837
|
+
content: external_exports.string().nullable(),
|
|
17838
|
+
tool_calls: external_exports.array(toolCallResponseSchema).optional(),
|
|
17839
|
+
tool_call_id: external_exports.string().optional(),
|
|
17840
|
+
/** User turns only — see `evalAttachmentRef` / `turnMayCarryAttachments`. */
|
|
17841
|
+
attachments: external_exports.array(evalAttachmentRef).optional()
|
|
17842
|
+
});
|
|
17843
|
+
expectedResponseDataSchema = external_exports.object({
|
|
17844
|
+
role: external_exports.literal("assistant"),
|
|
17845
|
+
content: external_exports.string().nullable(),
|
|
17846
|
+
tool_calls: external_exports.array(toolCallResponseSchema).optional()
|
|
17847
|
+
});
|
|
17848
|
+
evalResponseDataSchema = external_exports.object({
|
|
17849
|
+
role: external_exports.literal("assistant"),
|
|
17850
|
+
content: external_exports.string(),
|
|
17851
|
+
/**
|
|
17852
|
+
* The tool calls the agent made this turn (name + arguments). Present for
|
|
17853
|
+
* tool-call evals so `eval-results --runs` is self-contained — the verdict,
|
|
17854
|
+
* the reasoning, AND the actual call — without opening the conversation
|
|
17855
|
+
* (gh #2597). Omitted when the agent made no tool calls. Same shape as
|
|
17856
|
+
* `ExpectedResponseData.tool_calls` so expected vs. actual can be diffed.
|
|
17857
|
+
*/
|
|
17858
|
+
tool_calls: external_exports.array(toolCallResponseSchema).optional(),
|
|
17859
|
+
/** No route answers it today (`buildSessionRunRows` never sets it); the web still reads it. */
|
|
17860
|
+
metadata: external_exports.object({
|
|
17861
|
+
response_time_ms: external_exports.number().optional(),
|
|
17862
|
+
model_used: external_exports.string().optional(),
|
|
17863
|
+
tokens_used: external_exports.number().optional()
|
|
17864
|
+
}).optional()
|
|
17865
|
+
});
|
|
17866
|
+
evalInitialStateResponseEntry = evalInitialStateEntry.extend({
|
|
17867
|
+
scope: external_exports.enum(EVAL_INITIAL_STATE_SCOPES).optional()
|
|
17868
|
+
});
|
|
17869
|
+
evalResponseSchema = external_exports.object({
|
|
17870
|
+
eval_id: external_exports.string(),
|
|
17871
|
+
eval_name: external_exports.string(),
|
|
17872
|
+
scenario_set_id: external_exports.string(),
|
|
17873
|
+
responder_agent_id: external_exports.string(),
|
|
17874
|
+
/**
|
|
17875
|
+
* Set to the pushing user by the hub-as-code push's create (a branch clone copies it); the REST
|
|
17876
|
+
* create and update store whatever their open record carries; the conversation capture and the
|
|
17877
|
+
* journey materializer leave it null. Not an attribution to rely on.
|
|
17878
|
+
*/
|
|
17879
|
+
user_id: external_exports.string().nullable(),
|
|
17880
|
+
message_history: external_exports.array(messageHistoryItemResponseSchema),
|
|
17881
|
+
message_text: messageHistoryItemResponseSchema,
|
|
17882
|
+
message_expected_response: expectedResponseDataSchema,
|
|
17883
|
+
number_of_runs: external_exports.number().int(),
|
|
17884
|
+
enabled: external_exports.boolean(),
|
|
17885
|
+
evaluator_instructions: external_exports.string().nullable(),
|
|
17886
|
+
created_by: external_exports.string().nullable(),
|
|
17887
|
+
created_at: external_exports.string(),
|
|
17888
|
+
updated_at: external_exports.string().nullable(),
|
|
17889
|
+
/** Non-null for evals derived from an eval journey (server-managed). */
|
|
17890
|
+
journey_id: external_exports.string().nullable(),
|
|
17891
|
+
/** The journey step the eval was derived from (its stable upsert key), with `journey_id`. */
|
|
17892
|
+
journey_step_id: external_exports.string().nullable(),
|
|
17893
|
+
/** 0-based display order of the step within its journey (for step-by-step reports). */
|
|
17894
|
+
journey_step_index: external_exports.number().int().nullable(),
|
|
17895
|
+
/** Per-run variables (gh #3007): each name's values, indexed by run number. */
|
|
17896
|
+
variables: external_exports.record(external_exports.array(external_exports.unknown())).nullable(),
|
|
17897
|
+
/** Eval-session seed fixture this scenario's set depends on (gh #3090). */
|
|
17898
|
+
fixture: external_exports.string().nullable(),
|
|
17899
|
+
/** Rekor base the fixture seeds against — required alongside `fixture` (gh #3090). */
|
|
17900
|
+
target_base: external_exports.string().nullable(),
|
|
17901
|
+
/** User-scope state seeded for the eval's synthetic user before the trigger runs (gh #3430). */
|
|
17902
|
+
initial_state: external_exports.array(evalInitialStateResponseEntry).nullable(),
|
|
17903
|
+
/** The persons the scenario's runs are for, on a preview hub (`evalPersonSchema`, #5473 2-eval); null: none. */
|
|
17904
|
+
person: external_exports.array(external_exports.string()).nullable()
|
|
17905
|
+
});
|
|
17906
|
+
EVAL_RUN_OUTCOME_KINDS = [
|
|
17907
|
+
"pass",
|
|
17908
|
+
"assertion_failure",
|
|
17909
|
+
"execution_error",
|
|
17910
|
+
"evaluation_invalid"
|
|
17911
|
+
];
|
|
17912
|
+
evalWithAgentResponseSchema = evalResponseSchema.extend({
|
|
17913
|
+
agent: external_exports.object({
|
|
17914
|
+
agent_id: external_exports.string(),
|
|
17915
|
+
agent_name: external_exports.string(),
|
|
17916
|
+
agent_role: external_exports.string()
|
|
17917
|
+
}).nullable()
|
|
17918
|
+
});
|
|
17831
17919
|
evalSessionConfigResponseSchema = external_exports.object({
|
|
17832
17920
|
agent: external_exports.custom().optional(),
|
|
17833
17921
|
scenario_set_id: external_exports.string().optional().catch(void 0),
|
|
@@ -17860,7 +17948,7 @@ var init_chunk_5YZ3R7KF = __esm({
|
|
|
17860
17948
|
hub_id: external_exports.string(),
|
|
17861
17949
|
session_name: external_exports.string(),
|
|
17862
17950
|
session_description: external_exports.string().optional(),
|
|
17863
|
-
session_status:
|
|
17951
|
+
session_status: sessionStatusSchema,
|
|
17864
17952
|
started_at: timestampSchema.optional(),
|
|
17865
17953
|
completed_at: timestampSchema.optional(),
|
|
17866
17954
|
total_evals: external_exports.number(),
|
|
@@ -17892,8 +17980,180 @@ var init_chunk_5YZ3R7KF = __esm({
|
|
|
17892
17980
|
scenario_set_id: external_exports.string().optional().catch(void 0)
|
|
17893
17981
|
});
|
|
17894
17982
|
evalSessionListItemSchema = evalSessionResponseSchema.omit({ session_config: true }).extend({ session_config: evalSessionListConfigSchema.optional() }).passthrough();
|
|
17983
|
+
evalSessionResultResponseSchema = external_exports.object({
|
|
17984
|
+
/** The first result row's id; `{session}:{eval}` while no run has a result. */
|
|
17985
|
+
eval_session_result_id: external_exports.string(),
|
|
17986
|
+
/** The latest result row's timestamps; empty while no run has completed. */
|
|
17987
|
+
created_at: external_exports.string(),
|
|
17988
|
+
updated_at: external_exports.string(),
|
|
17989
|
+
eval_session_id: external_exports.string(),
|
|
17990
|
+
eval_id: external_exports.string(),
|
|
17991
|
+
total_runs: external_exports.number().int().nonnegative(),
|
|
17992
|
+
successful_runs: external_exports.number().int().nonnegative(),
|
|
17993
|
+
/** Every terminal run that did NOT pass — unchanged meaning; see the session schema. */
|
|
17994
|
+
failed_runs: external_exports.number().int().nonnegative(),
|
|
17995
|
+
/** The `failed_runs` breakdown by cause (see `EvalRunOutcomeKind`); sums to it. */
|
|
17996
|
+
assertion_failure_runs: external_exports.number().int().nonnegative(),
|
|
17997
|
+
errored_runs: external_exports.number().int().nonnegative(),
|
|
17998
|
+
invalid_runs: external_exports.number().int().nonnegative(),
|
|
17999
|
+
pending_runs: external_exports.number().int().nonnegative(),
|
|
18000
|
+
running_runs: external_exports.number().int().nonnegative(),
|
|
18001
|
+
/** Over the result rows that recorded a time; absent when none did. */
|
|
18002
|
+
avg_execution_time_ms: external_exports.number().optional(),
|
|
18003
|
+
min_execution_time_ms: external_exports.number().optional(),
|
|
18004
|
+
max_execution_time_ms: external_exports.number().optional(),
|
|
18005
|
+
/** Each numeric score dimension over the eval's results; absent when there are none. */
|
|
18006
|
+
aggregated_scores: external_exports.record(external_exports.object({ avg: external_exports.number(), min: external_exports.number(), max: external_exports.number() })).optional(),
|
|
18007
|
+
success_rate: external_exports.number(),
|
|
18008
|
+
eval_status: runStatusSchema,
|
|
18009
|
+
eval: evalResponseSchema.nullable()
|
|
18010
|
+
});
|
|
18011
|
+
evalSessionRunResponseSchema = external_exports.object({
|
|
18012
|
+
eval_session_run_id: external_exports.string(),
|
|
18013
|
+
created_at: external_exports.string(),
|
|
18014
|
+
updated_at: external_exports.string(),
|
|
18015
|
+
eval_session_id: external_exports.string(),
|
|
18016
|
+
eval_id: external_exports.string(),
|
|
18017
|
+
conversation_id: external_exports.string().optional(),
|
|
18018
|
+
/**
|
|
18019
|
+
* The responder's evaluated assistant message id and the message_evaluator's
|
|
18020
|
+
* verdict message id within `conversation_id`. Let consumers (CLI, CI) drill
|
|
18021
|
+
* straight into a turn's LLM observability without listing the conversation
|
|
18022
|
+
* first. Absent on runs that predate this capture, or that never produced the
|
|
18023
|
+
* respective turn (e.g. a failed run has no evaluator message).
|
|
18024
|
+
*/
|
|
18025
|
+
response_message_id: external_exports.string().optional(),
|
|
18026
|
+
evaluator_message_id: external_exports.string().optional(),
|
|
18027
|
+
run_number: external_exports.number().int(),
|
|
18028
|
+
eval_response: evalResponseDataSchema,
|
|
18029
|
+
/**
|
|
18030
|
+
* The expected response frozen on the run's `scenario_snapshot` at
|
|
18031
|
+
* materialize time (NOT the live eval row, which may have drifted since). Lets
|
|
18032
|
+
* consumers render an expected-vs-actual diff for a failing run without a
|
|
18033
|
+
* second fetch (gh #2813). Omitted when the snapshot carried no expected.
|
|
18034
|
+
*/
|
|
18035
|
+
expected_response: expectedResponseDataSchema.optional(),
|
|
18036
|
+
/**
|
|
18037
|
+
* The scenario's frozen multi-turn `message_history`, captured per-run in the
|
|
18038
|
+
* `eval_session_run.scenario_snapshot` at session-launch time and replayed to
|
|
18039
|
+
* the responder ahead of the trigger turn (gh #2625). Surfaced as the
|
|
18040
|
+
* eval-details "conversation so far" block so a reviewer judges the response
|
|
18041
|
+
* against the full thread that preceded the evaluated turn — the live `message`
|
|
18042
|
+
* table only holds the trigger + the agent's reply, never this history. Omitted
|
|
18043
|
+
* when the scenario had no prior turns.
|
|
18044
|
+
*/
|
|
18045
|
+
scenario_history: external_exports.array(messageHistoryItemResponseSchema).optional(),
|
|
18046
|
+
response_match: external_exports.boolean().nullable(),
|
|
18047
|
+
/**
|
|
18048
|
+
* What this run's outcome actually was. Absent while the run is non-terminal
|
|
18049
|
+
* (nothing to classify yet); on a terminal run it distinguishes a behavioral
|
|
18050
|
+
* miss from an infrastructure death or an unusable verdict, which
|
|
18051
|
+
* `response_match: null` alone cannot.
|
|
18052
|
+
*/
|
|
18053
|
+
outcome_kind: external_exports.enum(EVAL_RUN_OUTCOME_KINDS).optional(),
|
|
18054
|
+
response_comment: external_exports.string().optional(),
|
|
18055
|
+
execution_time_ms: external_exports.number().optional(),
|
|
18056
|
+
run_status: runStatusSchema,
|
|
18057
|
+
error_message: external_exports.string().optional(),
|
|
18058
|
+
/** The run row's `updated_at` once the run is terminal: its terminal transition stamps it. */
|
|
18059
|
+
completed_at: external_exports.string().optional(),
|
|
18060
|
+
scores: external_exports.record(external_exports.number()).optional(),
|
|
18061
|
+
eval: evalResponseSchema.pick({ eval_id: true, eval_name: true, responder_agent_id: true }).nullable()
|
|
18062
|
+
});
|
|
18063
|
+
evalPaginationResponseSchema = external_exports.object({
|
|
18064
|
+
limit: external_exports.number().int().nonnegative(),
|
|
18065
|
+
offset: external_exports.number().int().nonnegative(),
|
|
18066
|
+
has_more: external_exports.boolean()
|
|
18067
|
+
});
|
|
18068
|
+
getEvalsResponseSchema = external_exports.object({
|
|
18069
|
+
success: external_exports.literal(true),
|
|
18070
|
+
data: external_exports.object({
|
|
18071
|
+
evals: external_exports.array(evalWithAgentResponseSchema),
|
|
18072
|
+
total_count: external_exports.number().int().nonnegative(),
|
|
18073
|
+
/** Never answered today: the route pages by `limit`/`offset` but echoes no page. The web reads it. */
|
|
18074
|
+
pagination: evalPaginationResponseSchema.optional()
|
|
18075
|
+
})
|
|
18076
|
+
});
|
|
18077
|
+
getSessionsResponseSchema = external_exports.object({
|
|
18078
|
+
success: external_exports.literal(true),
|
|
18079
|
+
data: external_exports.object({
|
|
18080
|
+
/** Slim rows — the launch snapshot's fat fields need `GET /sessions/:id`. */
|
|
18081
|
+
sessions: external_exports.array(evalSessionListItemSchema),
|
|
18082
|
+
total_count: external_exports.number().int().nonnegative(),
|
|
18083
|
+
pagination: evalPaginationResponseSchema.optional()
|
|
18084
|
+
})
|
|
18085
|
+
});
|
|
18086
|
+
createSessionResponseSchema = external_exports.object({
|
|
18087
|
+
success: external_exports.literal(true),
|
|
18088
|
+
data: external_exports.object({ session: evalSessionResponseSchema }),
|
|
18089
|
+
message: external_exports.string()
|
|
18090
|
+
});
|
|
18091
|
+
SEED_LEASE_WARNINGS = [
|
|
18092
|
+
"SEED_LEASE_CAPACITY_80_PERCENT",
|
|
18093
|
+
"SEED_LEASE_CAPACITY_95_PERCENT"
|
|
18094
|
+
];
|
|
18095
|
+
runSessionResponseSchema = external_exports.object({
|
|
18096
|
+
success: external_exports.literal(true),
|
|
18097
|
+
data: external_exports.object({
|
|
18098
|
+
session: evalSessionResponseSchema,
|
|
18099
|
+
/** Present only when Rekor reported ledger-capacity pressure on acquire. */
|
|
18100
|
+
seed_lease_warnings: external_exports.array(external_exports.enum(SEED_LEASE_WARNINGS)).optional()
|
|
18101
|
+
}),
|
|
18102
|
+
message: external_exports.string()
|
|
18103
|
+
});
|
|
17895
18104
|
seedReleaseStatusSchema = external_exports.enum(["not_applicable", "pending", "releasing"]);
|
|
18105
|
+
stopSessionResponseSchema = external_exports.object({
|
|
18106
|
+
success: external_exports.literal(true),
|
|
18107
|
+
data: external_exports.object({
|
|
18108
|
+
session: evalSessionResponseSchema,
|
|
18109
|
+
/**
|
|
18110
|
+
* False when the session had already finished and this call changed
|
|
18111
|
+
* nothing — the signal callers need to avoid reporting a cancellation that
|
|
18112
|
+
* did not happen, and the backend needs to skip fixture teardown.
|
|
18113
|
+
*/
|
|
18114
|
+
stopped: external_exports.boolean(),
|
|
18115
|
+
seed_release_status: seedReleaseStatusSchema
|
|
18116
|
+
}),
|
|
18117
|
+
message: external_exports.string()
|
|
18118
|
+
});
|
|
17896
18119
|
EVAL_SESSION_NOT_QUIESCENT = "session_not_quiescent";
|
|
18120
|
+
deleteSessionResponseSchema = external_exports.object({
|
|
18121
|
+
success: external_exports.literal(true),
|
|
18122
|
+
message: external_exports.string(),
|
|
18123
|
+
/** Number of eval conversations torn down alongside the session. */
|
|
18124
|
+
data: external_exports.object({ deleted_conversations: external_exports.number().int().nonnegative() })
|
|
18125
|
+
});
|
|
18126
|
+
deleteAllSessionsResponseSchema = external_exports.object({
|
|
18127
|
+
success: external_exports.literal(true),
|
|
18128
|
+
message: external_exports.string(),
|
|
18129
|
+
data: external_exports.object({
|
|
18130
|
+
/** Number of eval sessions deleted. */
|
|
18131
|
+
deleted_sessions: external_exports.number().int().nonnegative(),
|
|
18132
|
+
/** Number of eval conversations torn down across all deleted sessions. */
|
|
18133
|
+
deleted_conversations: external_exports.number().int().nonnegative()
|
|
18134
|
+
})
|
|
18135
|
+
});
|
|
18136
|
+
getSessionDetailsResponseSchema = external_exports.object({
|
|
18137
|
+
success: external_exports.literal(true),
|
|
18138
|
+
data: external_exports.object({
|
|
18139
|
+
session: evalSessionResponseSchema.nullable(),
|
|
18140
|
+
results: external_exports.array(evalSessionResultResponseSchema)
|
|
18141
|
+
})
|
|
18142
|
+
});
|
|
18143
|
+
getSessionRunsResponseSchema = external_exports.object({
|
|
18144
|
+
success: external_exports.literal(true),
|
|
18145
|
+
data: external_exports.object({
|
|
18146
|
+
runs: external_exports.array(evalSessionRunResponseSchema),
|
|
18147
|
+
total_count: external_exports.number().int().nonnegative(),
|
|
18148
|
+
session_id: external_exports.string(),
|
|
18149
|
+
pagination: evalPaginationResponseSchema.optional()
|
|
18150
|
+
})
|
|
18151
|
+
});
|
|
18152
|
+
createScenarioFromConversationResponseSchema = external_exports.object({
|
|
18153
|
+
success: external_exports.literal(true),
|
|
18154
|
+
data: external_exports.object({ eval: evalResponseSchema }),
|
|
18155
|
+
message: external_exports.string()
|
|
18156
|
+
});
|
|
17897
18157
|
}
|
|
17898
18158
|
});
|
|
17899
18159
|
|
|
@@ -17910,7 +18170,7 @@ var init_chunk_S4VDZ7PZ = __esm({
|
|
|
17910
18170
|
}
|
|
17911
18171
|
});
|
|
17912
18172
|
|
|
17913
|
-
// ../../packages/core/dist/chunk-
|
|
18173
|
+
// ../../packages/core/dist/chunk-HTB6XZYH.js
|
|
17914
18174
|
function declaresNoConnection(agent) {
|
|
17915
18175
|
return agent.connection === null && !agent.connection_id;
|
|
17916
18176
|
}
|
|
@@ -18642,8 +18902,8 @@ function skillSectionsAsResources(scope) {
|
|
|
18642
18902
|
};
|
|
18643
18903
|
}
|
|
18644
18904
|
var MAX_10MB_BASE64_ENCODED_BYTES, MAX_EVAL_ATTACHMENT_ENCODED_BYTES, MAX_EVAL_ATTACHMENT_CARRIERS, MAX_EVAL_ATTACHMENT_AGGREGATE_ENCODED_BYTES, MAX_RESOURCE_ENCODED_BYTES, MAX_HUB_AS_CODE_RESOURCES, MAX_HUB_AS_CODE_RESOURCE_FILES, MAX_RESOURCE_AGGREGATE_ENCODED_BYTES, MAX_CI_CONFIG_BODY_BYTES, hubAsCodeKanbanFollowupSchema, hubAsCodeKanbanOutcomeSchema, hubAsCodeKanbanStatusSchema, hubAsCodeLaneSchema, hubAsCodePageSchema, MAX_HUB_AS_CODE_PAGE_MANIFEST_CHARS, hubAsCodePagesSchema, hubAsCodeCallOpeningSchema, hubAsCodeCallOpeningFileSchema, MAX_CALL_OPENING_CARRIERS, MAX_CALL_OPENING_AGGREGATE_ENCODED_BYTES, hubAsCodeEvaluationVariableSchema, hubAsCodeNativeToolSchema, hubAsCodeMcpToolSchema, hubAsCodeCustomToolSchema, hubAsCodeStateSchema, hubAsCodeTeamSchema, hubAsCodeResourceFileSchema, hubAsCodeResourceSchema, hubAsCodeAgentResourceSchema, hubAsCodeDelegationToolSchema, hubAsCodeAgentSchema, HUB_AS_CODE_AGENT_KEYS, HUB_AS_CODE_AGENT_TOOL_KEYS, orgAsCodeResourceFolderSchema, orgAsCodeResourceSchema, orgResourcesPayloadSchema, hubAsCodeAutomationSchema, HUB_AS_CODE_AUTOMATION_KEYS, HUB_AS_CODE_AUTOMATION_TRIGGER_KEYS, HUB_AS_CODE_AUTOMATION_TARGET_KEYS, HUB_AS_CODE_AUTOMATION_ACTION_KEYS, HUB_AS_CODE_AUTOMATION_GATE_KEYS, hubAsCodeContactListSchema, HUB_AS_CODE_CONTACT_LIST_KEYS, HUB_AS_CODE_CONTACT_LIST_FILTER_KEYS, hubAsCodeEvalMessageFields, hubAsCodeHistoryTurnSchema, hubAsCodeEvalSchema, hubAsCodeEvalAttachmentFileSchema, hubAsCodeJourneyTurnSchema, hubAsCodeJourneyStepOverrideSchema, hubAsCodeJourneySchema, uuidPattern, ciUuidSchema, flagEntriesOf, boundedHubAsCodeResourcesSchema, isPlainObject, MIN_SKILLS_LAYOUT_CLI, MAX_HUB_AS_CODE_DEPTH, NAMED_DEPTH_SEGMENTS, NAMED_DEPTH_KEY_CHARS, fieldName, hubAsCodeConfigObjectSchema, hubAsCodeConfigSchema, hubAsCodeConnectionSchema, hubAsCodePayloadSchema, ciPullHubIdParam, ciBranchParam, ciPullQuery, ciHubsQuery, ciLookupQuery, ciBranchesQuery, ciDiffDirectionSchema, ciSyncBody, ciPushBody, ciDiffBody, ciPublishBody, ciPublishPreviewBody, ciSyncMcpBody, ciOrgResourcesParam, orgResourcesConfigSchema, ciOrgResourcesPushBody, ciOrgResourcesDiffBody, ciDiffHunkSectionSchema, ciDiffHunkSchema, PAGE_DESIGN_RULES, ciPageDesignFindingSchema, ciDiffResponseFields, ciDiffResponseSchema, ciOrgSkillsDiffResponseSchema, ciHubIdentitySchema, ciLookupResponseSchema, ciOrganizationsResponseSchema, ciCreateOrganizationResponseSchema, ciHubListItemSchema, ciHubListResponseSchema, CI_APPLY_ENTITY_KINDS, CI_APPLY_OPERATIONS, ciApplyErrorBaseSchema, ciApplyErrorSchema, ciSyncCountSchema, ciSyncChangesSchema, ciSyncWarningSchema, CI_SKIPPABLE_TOOL_GROUPS, ciSkippedEntrySchema, ciSyncResponseSchema, ciPublishResponseSchema, ciMcpDriftEntrySchema, ciSyncMcpResponseSchema, ciPublishPreviewResponseSchema, ciBranchInfoSchema, ciBranchListResponseSchema, ciBranchDeleteResponseSchema, ciOrgResourcesPullFileSchema, ciOrgResourcesPullFolderSchema, ciOrgResourcesPullResourceSchema, ciOrgResourcesPullResponseSchema, ciOrgResourcesPushResponseSchema;
|
|
18645
|
-
var
|
|
18646
|
-
"../../packages/core/dist/chunk-
|
|
18905
|
+
var init_chunk_HTB6XZYH = __esm({
|
|
18906
|
+
"../../packages/core/dist/chunk-HTB6XZYH.js"() {
|
|
18647
18907
|
"use strict";
|
|
18648
18908
|
init_chunk_QG3XMUEN();
|
|
18649
18909
|
init_chunk_EBUWHIFV();
|
|
@@ -18655,7 +18915,7 @@ var init_chunk_PTPA35JY = __esm({
|
|
|
18655
18915
|
init_chunk_ZDTX3DG5();
|
|
18656
18916
|
init_chunk_JP7XIMUA();
|
|
18657
18917
|
init_chunk_C2UEA2KW();
|
|
18658
|
-
|
|
18918
|
+
init_chunk_NF2TUBZ4();
|
|
18659
18919
|
init_chunk_4LXDRTO4();
|
|
18660
18920
|
init_chunk_S4VDZ7PZ();
|
|
18661
18921
|
init_chunk_FBV7NLKO();
|
|
@@ -19938,18 +20198,18 @@ var init_contracts = __esm({
|
|
|
19938
20198
|
init_chunk_C7UAGRXF();
|
|
19939
20199
|
init_chunk_IPXBFWUU();
|
|
19940
20200
|
init_chunk_63UWXV4T();
|
|
20201
|
+
init_chunk_WDAXZDJO();
|
|
19941
20202
|
init_chunk_ZC6YGHNX();
|
|
19942
20203
|
init_chunk_HIGKBEPF();
|
|
20204
|
+
init_chunk_2IPHTFV5();
|
|
19943
20205
|
init_chunk_IPDOHAZ5();
|
|
19944
20206
|
init_chunk_PFGVH2CX();
|
|
19945
20207
|
init_chunk_TVUDMGWV();
|
|
19946
20208
|
init_chunk_WTIGECE5();
|
|
19947
|
-
init_chunk_WDAXZDJO();
|
|
19948
20209
|
init_chunk_ZXK6N2HN();
|
|
19949
20210
|
init_chunk_Y7CFCYX4();
|
|
19950
20211
|
init_chunk_OS6EKEP4();
|
|
19951
20212
|
init_chunk_5DGHIY7L();
|
|
19952
|
-
init_chunk_2IPHTFV5();
|
|
19953
20213
|
init_chunk_I3O2RACG();
|
|
19954
20214
|
init_chunk_CMRECH67();
|
|
19955
20215
|
init_chunk_34LE6P7E();
|
|
@@ -19964,6 +20224,7 @@ var init_contracts = __esm({
|
|
|
19964
20224
|
init_chunk_C4HEZ7ZI();
|
|
19965
20225
|
init_chunk_IR2NOSI3();
|
|
19966
20226
|
init_chunk_OPETF4GS();
|
|
20227
|
+
init_chunk_YULHXJ5M();
|
|
19967
20228
|
init_chunk_V4FRPRH5();
|
|
19968
20229
|
init_chunk_LWMLR2WI();
|
|
19969
20230
|
init_chunk_MMVZ65BL();
|
|
@@ -19975,32 +20236,31 @@ var init_contracts = __esm({
|
|
|
19975
20236
|
init_chunk_JDJ4EUOL();
|
|
19976
20237
|
init_chunk_UCYWGWQT();
|
|
19977
20238
|
init_chunk_6AYIXGDT();
|
|
19978
|
-
init_chunk_YULHXJ5M();
|
|
19979
20239
|
init_chunk_ME7AKVSP();
|
|
19980
20240
|
init_chunk_KY3ZNL3E();
|
|
19981
20241
|
init_chunk_X4IDZLLS();
|
|
19982
|
-
|
|
19983
|
-
|
|
19984
|
-
|
|
20242
|
+
init_chunk_LBCPN6IM();
|
|
20243
|
+
init_chunk_OW6A2JRU();
|
|
20244
|
+
init_chunk_ZIYKQK52();
|
|
20245
|
+
init_chunk_MXEJT22F();
|
|
19985
20246
|
init_chunk_2WVZOVEF();
|
|
19986
20247
|
init_chunk_26PIYACX();
|
|
19987
|
-
|
|
19988
|
-
|
|
19989
|
-
|
|
20248
|
+
init_chunk_XE7BAV42();
|
|
20249
|
+
init_chunk_MRSQ7PBE();
|
|
20250
|
+
init_chunk_EUDNN2RS();
|
|
19990
20251
|
init_chunk_PSY4BJ7E();
|
|
19991
|
-
|
|
19992
|
-
|
|
19993
|
-
|
|
19994
|
-
|
|
20252
|
+
init_chunk_3P2DTRI4();
|
|
20253
|
+
init_chunk_2HOHGYWQ();
|
|
20254
|
+
init_chunk_6ZLXOCCY();
|
|
20255
|
+
init_chunk_A5TJEV6T();
|
|
19995
20256
|
init_chunk_J3HQTL6M();
|
|
19996
|
-
init_chunk_ZJA3UZMG();
|
|
19997
20257
|
init_chunk_4GJFEMVI();
|
|
19998
20258
|
init_chunk_YWZFB34T();
|
|
19999
20259
|
init_chunk_PZPOUXJR();
|
|
20000
20260
|
init_chunk_5PKKFSSF();
|
|
20001
20261
|
init_chunk_GCPFVAXX();
|
|
20002
|
-
|
|
20003
|
-
|
|
20262
|
+
init_chunk_SPIVW22L();
|
|
20263
|
+
init_chunk_LMRE5GNU();
|
|
20004
20264
|
init_chunk_NVKU5PPQ();
|
|
20005
20265
|
init_chunk_3DDFBKA2();
|
|
20006
20266
|
init_chunk_FECLIZTY();
|
|
@@ -20014,7 +20274,7 @@ var init_contracts = __esm({
|
|
|
20014
20274
|
init_chunk_R6Y377AW();
|
|
20015
20275
|
init_chunk_UAOHHCW5();
|
|
20016
20276
|
init_chunk_ULQGJUXZ();
|
|
20017
|
-
|
|
20277
|
+
init_chunk_HTB6XZYH();
|
|
20018
20278
|
init_chunk_QG3XMUEN();
|
|
20019
20279
|
init_chunk_EBUWHIFV();
|
|
20020
20280
|
init_chunk_LBDH7LCG();
|
|
@@ -20037,7 +20297,7 @@ var init_contracts = __esm({
|
|
|
20037
20297
|
init_chunk_JP7XIMUA();
|
|
20038
20298
|
init_chunk_RXVBKM44();
|
|
20039
20299
|
init_chunk_C2UEA2KW();
|
|
20040
|
-
|
|
20300
|
+
init_chunk_NF2TUBZ4();
|
|
20041
20301
|
init_chunk_2YEGUQR7();
|
|
20042
20302
|
init_chunk_AHISKXHA();
|
|
20043
20303
|
init_chunk_4LXDRTO4();
|
|
@@ -20050,14 +20310,14 @@ var init_contracts = __esm({
|
|
|
20050
20310
|
init_chunk_2ISUBJG7();
|
|
20051
20311
|
init_chunk_64HCHXKB();
|
|
20052
20312
|
init_chunk_YR7QALGP();
|
|
20053
|
-
|
|
20054
|
-
|
|
20055
|
-
|
|
20056
|
-
|
|
20057
|
-
|
|
20313
|
+
init_chunk_KFKBWZLE();
|
|
20314
|
+
init_chunk_RUESJZ26();
|
|
20315
|
+
init_chunk_MQQRYOE6();
|
|
20316
|
+
init_chunk_ASIBSUKC();
|
|
20317
|
+
init_chunk_BALYF7RA();
|
|
20318
|
+
init_chunk_KWRHZBGU();
|
|
20058
20319
|
init_chunk_M2T55BV6();
|
|
20059
20320
|
init_chunk_CLGTGGVN();
|
|
20060
|
-
init_chunk_KWRHZBGU();
|
|
20061
20321
|
init_chunk_VYINA6YP();
|
|
20062
20322
|
init_chunk_ZVXO3XL6();
|
|
20063
20323
|
init_chunk_FBV7NLKO();
|
|
@@ -20514,7 +20774,7 @@ var init_hub_folder = __esm({
|
|
|
20514
20774
|
"../../packages/core/dist/hub-folder.js"() {
|
|
20515
20775
|
"use strict";
|
|
20516
20776
|
init_chunk_MJRA4O65();
|
|
20517
|
-
|
|
20777
|
+
init_chunk_NF2TUBZ4();
|
|
20518
20778
|
init_chunk_2YEGUQR7();
|
|
20519
20779
|
init_chunk_AHISKXHA();
|
|
20520
20780
|
init_chunk_4LXDRTO4();
|
|
@@ -20833,11 +21093,11 @@ var CASE_TYPE_PACKAGE_REVISIONS_MAX, caseTypeSourceQuery, caseTypePackageParam,
|
|
|
20833
21093
|
var init_case_type_drafts = __esm({
|
|
20834
21094
|
"../../packages/core/dist/contracts/case-type-drafts.js"() {
|
|
20835
21095
|
"use strict";
|
|
20836
|
-
|
|
20837
|
-
|
|
21096
|
+
init_chunk_MQQRYOE6();
|
|
21097
|
+
init_chunk_BALYF7RA();
|
|
21098
|
+
init_chunk_KWRHZBGU();
|
|
20838
21099
|
init_chunk_M2T55BV6();
|
|
20839
21100
|
init_chunk_CLGTGGVN();
|
|
20840
|
-
init_chunk_KWRHZBGU();
|
|
20841
21101
|
init_chunk_VYINA6YP();
|
|
20842
21102
|
init_chunk_ZVXO3XL6();
|
|
20843
21103
|
init_chunk_FBV7NLKO();
|
|
@@ -20909,16 +21169,16 @@ var init_case_type_drafts = __esm({
|
|
|
20909
21169
|
var init_case_received_documents = __esm({
|
|
20910
21170
|
"../../packages/core/dist/contracts/case-received-documents.js"() {
|
|
20911
21171
|
"use strict";
|
|
20912
|
-
|
|
20913
|
-
|
|
21172
|
+
init_chunk_LBCPN6IM();
|
|
21173
|
+
init_chunk_6ZLXOCCY();
|
|
21174
|
+
init_chunk_A5TJEV6T();
|
|
20914
21175
|
init_chunk_J3HQTL6M();
|
|
20915
|
-
|
|
20916
|
-
|
|
20917
|
-
|
|
20918
|
-
|
|
21176
|
+
init_chunk_MQQRYOE6();
|
|
21177
|
+
init_chunk_ASIBSUKC();
|
|
21178
|
+
init_chunk_BALYF7RA();
|
|
21179
|
+
init_chunk_KWRHZBGU();
|
|
20919
21180
|
init_chunk_M2T55BV6();
|
|
20920
21181
|
init_chunk_CLGTGGVN();
|
|
20921
|
-
init_chunk_KWRHZBGU();
|
|
20922
21182
|
init_chunk_VYINA6YP();
|
|
20923
21183
|
init_chunk_ZVXO3XL6();
|
|
20924
21184
|
init_chunk_FBV7NLKO();
|
|
@@ -20934,9 +21194,9 @@ var init_case_received_documents = __esm({
|
|
|
20934
21194
|
var init_case_files = __esm({
|
|
20935
21195
|
"../../packages/core/dist/contracts/case-files.js"() {
|
|
20936
21196
|
"use strict";
|
|
20937
|
-
|
|
20938
|
-
init_chunk_CLGTGGVN();
|
|
21197
|
+
init_chunk_MQQRYOE6();
|
|
20939
21198
|
init_chunk_KWRHZBGU();
|
|
21199
|
+
init_chunk_CLGTGGVN();
|
|
20940
21200
|
init_chunk_VYINA6YP();
|
|
20941
21201
|
init_chunk_ZVXO3XL6();
|
|
20942
21202
|
init_chunk_FBV7NLKO();
|
|
@@ -26901,7 +27161,7 @@ var init_hub_materializer = __esm({
|
|
|
26901
27161
|
var init_ci = __esm({
|
|
26902
27162
|
"../../packages/core/dist/contracts/ci.js"() {
|
|
26903
27163
|
"use strict";
|
|
26904
|
-
|
|
27164
|
+
init_chunk_HTB6XZYH();
|
|
26905
27165
|
init_chunk_QG3XMUEN();
|
|
26906
27166
|
init_chunk_EBUWHIFV();
|
|
26907
27167
|
init_chunk_LBDH7LCG();
|
|
@@ -26916,7 +27176,7 @@ var init_ci = __esm({
|
|
|
26916
27176
|
init_chunk_JP7XIMUA();
|
|
26917
27177
|
init_chunk_RXVBKM44();
|
|
26918
27178
|
init_chunk_C2UEA2KW();
|
|
26919
|
-
|
|
27179
|
+
init_chunk_NF2TUBZ4();
|
|
26920
27180
|
init_chunk_2YEGUQR7();
|
|
26921
27181
|
init_chunk_AHISKXHA();
|
|
26922
27182
|
init_chunk_4LXDRTO4();
|
|
@@ -27432,7 +27692,7 @@ var nativeEntryName, SKIPPABLE_ENTRY_IDENTITY;
|
|
|
27432
27692
|
var init_skipped_tool_entries = __esm({
|
|
27433
27693
|
"../../packages/core/dist/skipped-tool-entries.js"() {
|
|
27434
27694
|
"use strict";
|
|
27435
|
-
|
|
27695
|
+
init_chunk_HTB6XZYH();
|
|
27436
27696
|
init_chunk_QG3XMUEN();
|
|
27437
27697
|
init_chunk_EBUWHIFV();
|
|
27438
27698
|
init_chunk_LBDH7LCG();
|
|
@@ -27447,7 +27707,7 @@ var init_skipped_tool_entries = __esm({
|
|
|
27447
27707
|
init_chunk_JP7XIMUA();
|
|
27448
27708
|
init_chunk_RXVBKM44();
|
|
27449
27709
|
init_chunk_C2UEA2KW();
|
|
27450
|
-
|
|
27710
|
+
init_chunk_NF2TUBZ4();
|
|
27451
27711
|
init_chunk_2YEGUQR7();
|
|
27452
27712
|
init_chunk_AHISKXHA();
|
|
27453
27713
|
init_chunk_4LXDRTO4();
|
|
@@ -32535,10 +32795,10 @@ var init_case_type_packages = __esm({
|
|
|
32535
32795
|
var init_case_types = __esm({
|
|
32536
32796
|
"../../packages/core/dist/contracts/case-types.js"() {
|
|
32537
32797
|
"use strict";
|
|
32538
|
-
|
|
32798
|
+
init_chunk_BALYF7RA();
|
|
32799
|
+
init_chunk_KWRHZBGU();
|
|
32539
32800
|
init_chunk_M2T55BV6();
|
|
32540
32801
|
init_chunk_CLGTGGVN();
|
|
32541
|
-
init_chunk_KWRHZBGU();
|
|
32542
32802
|
init_chunk_VYINA6YP();
|
|
32543
32803
|
init_chunk_ZVXO3XL6();
|
|
32544
32804
|
init_chunk_FBV7NLKO();
|
|
@@ -38835,7 +39095,8 @@ async function showRunDetails(client, hubId, sessionId, evalNameFilter, jsonOutp
|
|
|
38835
39095
|
console.log(JSON.stringify(runsResult.data, null, 2));
|
|
38836
39096
|
return;
|
|
38837
39097
|
}
|
|
38838
|
-
|
|
39098
|
+
const session = details.data.session;
|
|
39099
|
+
console.log(`Session: ${session.session_name} (${session.session_status})
|
|
38839
39100
|
`);
|
|
38840
39101
|
if (runsResult.data.runs.length === 0) {
|
|
38841
39102
|
console.log("No runs found.");
|
|
@@ -43379,11 +43640,11 @@ var CASE_AGENT_REQUEST_TTL_MS, CASE_AGENT_REQUESTS_PER_PERSON_MAX, CASE_AGENT_MA
|
|
|
43379
43640
|
var init_case_agents = __esm({
|
|
43380
43641
|
"../../packages/core/dist/contracts/case-agents.js"() {
|
|
43381
43642
|
"use strict";
|
|
43382
|
-
|
|
43383
|
-
|
|
43643
|
+
init_chunk_ASIBSUKC();
|
|
43644
|
+
init_chunk_BALYF7RA();
|
|
43645
|
+
init_chunk_KWRHZBGU();
|
|
43384
43646
|
init_chunk_M2T55BV6();
|
|
43385
43647
|
init_chunk_CLGTGGVN();
|
|
43386
|
-
init_chunk_KWRHZBGU();
|
|
43387
43648
|
init_chunk_VYINA6YP();
|
|
43388
43649
|
init_chunk_ZVXO3XL6();
|
|
43389
43650
|
init_chunk_FBV7NLKO();
|
|
@@ -43417,11 +43678,11 @@ var init_case_agents = __esm({
|
|
|
43417
43678
|
var init_case_records = __esm({
|
|
43418
43679
|
"../../packages/core/dist/contracts/case-records.js"() {
|
|
43419
43680
|
"use strict";
|
|
43420
|
-
|
|
43421
|
-
|
|
43681
|
+
init_chunk_ASIBSUKC();
|
|
43682
|
+
init_chunk_BALYF7RA();
|
|
43683
|
+
init_chunk_KWRHZBGU();
|
|
43422
43684
|
init_chunk_M2T55BV6();
|
|
43423
43685
|
init_chunk_CLGTGGVN();
|
|
43424
|
-
init_chunk_KWRHZBGU();
|
|
43425
43686
|
init_chunk_VYINA6YP();
|
|
43426
43687
|
init_chunk_ZVXO3XL6();
|
|
43427
43688
|
init_chunk_FBV7NLKO();
|
|
@@ -43438,11 +43699,11 @@ var CASE_REVIEW_ROUNDS_MAX, CASE_REVIEW_REASON_MAX_LENGTH, CASE_REVIEW_PAIR_UNKN
|
|
|
43438
43699
|
var init_case_review = __esm({
|
|
43439
43700
|
"../../packages/core/dist/contracts/case-review.js"() {
|
|
43440
43701
|
"use strict";
|
|
43441
|
-
|
|
43442
|
-
|
|
43702
|
+
init_chunk_MQQRYOE6();
|
|
43703
|
+
init_chunk_BALYF7RA();
|
|
43704
|
+
init_chunk_KWRHZBGU();
|
|
43443
43705
|
init_chunk_M2T55BV6();
|
|
43444
43706
|
init_chunk_CLGTGGVN();
|
|
43445
|
-
init_chunk_KWRHZBGU();
|
|
43446
43707
|
init_chunk_VYINA6YP();
|
|
43447
43708
|
init_chunk_ZVXO3XL6();
|
|
43448
43709
|
init_chunk_FBV7NLKO();
|
|
@@ -43572,14 +43833,14 @@ var init_case_session = __esm({
|
|
|
43572
43833
|
var init_case_comments = __esm({
|
|
43573
43834
|
"../../packages/core/dist/contracts/case-comments.js"() {
|
|
43574
43835
|
"use strict";
|
|
43575
|
-
|
|
43576
|
-
|
|
43577
|
-
|
|
43578
|
-
|
|
43579
|
-
|
|
43836
|
+
init_chunk_KFKBWZLE();
|
|
43837
|
+
init_chunk_RUESJZ26();
|
|
43838
|
+
init_chunk_MQQRYOE6();
|
|
43839
|
+
init_chunk_ASIBSUKC();
|
|
43840
|
+
init_chunk_BALYF7RA();
|
|
43841
|
+
init_chunk_KWRHZBGU();
|
|
43580
43842
|
init_chunk_M2T55BV6();
|
|
43581
43843
|
init_chunk_CLGTGGVN();
|
|
43582
|
-
init_chunk_KWRHZBGU();
|
|
43583
43844
|
init_chunk_VYINA6YP();
|
|
43584
43845
|
init_chunk_ZVXO3XL6();
|
|
43585
43846
|
init_chunk_FBV7NLKO();
|
|
@@ -43595,15 +43856,15 @@ var init_case_comments = __esm({
|
|
|
43595
43856
|
var init_case_collection_citations = __esm({
|
|
43596
43857
|
"../../packages/core/dist/contracts/case-collection-citations.js"() {
|
|
43597
43858
|
"use strict";
|
|
43598
|
-
|
|
43599
|
-
|
|
43600
|
-
|
|
43601
|
-
|
|
43602
|
-
|
|
43603
|
-
|
|
43859
|
+
init_chunk_2HOHGYWQ();
|
|
43860
|
+
init_chunk_KFKBWZLE();
|
|
43861
|
+
init_chunk_RUESJZ26();
|
|
43862
|
+
init_chunk_MQQRYOE6();
|
|
43863
|
+
init_chunk_ASIBSUKC();
|
|
43864
|
+
init_chunk_BALYF7RA();
|
|
43865
|
+
init_chunk_KWRHZBGU();
|
|
43604
43866
|
init_chunk_M2T55BV6();
|
|
43605
43867
|
init_chunk_CLGTGGVN();
|
|
43606
|
-
init_chunk_KWRHZBGU();
|
|
43607
43868
|
init_chunk_VYINA6YP();
|
|
43608
43869
|
init_chunk_ZVXO3XL6();
|
|
43609
43870
|
init_chunk_FBV7NLKO();
|
|
@@ -43619,19 +43880,19 @@ var init_case_collection_citations = __esm({
|
|
|
43619
43880
|
var init_case_collection_links = __esm({
|
|
43620
43881
|
"../../packages/core/dist/contracts/case-collection-links.js"() {
|
|
43621
43882
|
"use strict";
|
|
43622
|
-
|
|
43623
|
-
|
|
43624
|
-
|
|
43883
|
+
init_chunk_3P2DTRI4();
|
|
43884
|
+
init_chunk_2HOHGYWQ();
|
|
43885
|
+
init_chunk_6ZLXOCCY();
|
|
43886
|
+
init_chunk_A5TJEV6T();
|
|
43625
43887
|
init_chunk_J3HQTL6M();
|
|
43626
|
-
|
|
43627
|
-
|
|
43628
|
-
|
|
43629
|
-
|
|
43630
|
-
|
|
43631
|
-
|
|
43888
|
+
init_chunk_KFKBWZLE();
|
|
43889
|
+
init_chunk_RUESJZ26();
|
|
43890
|
+
init_chunk_MQQRYOE6();
|
|
43891
|
+
init_chunk_ASIBSUKC();
|
|
43892
|
+
init_chunk_BALYF7RA();
|
|
43893
|
+
init_chunk_KWRHZBGU();
|
|
43632
43894
|
init_chunk_M2T55BV6();
|
|
43633
43895
|
init_chunk_CLGTGGVN();
|
|
43634
|
-
init_chunk_KWRHZBGU();
|
|
43635
43896
|
init_chunk_VYINA6YP();
|
|
43636
43897
|
init_chunk_ZVXO3XL6();
|
|
43637
43898
|
init_chunk_FBV7NLKO();
|
|
@@ -44398,7 +44659,7 @@ exec wayai cases pull --mirror-only --dir "$(dirname "$0")/.."
|
|
|
44398
44659
|
}
|
|
44399
44660
|
});
|
|
44400
44661
|
|
|
44401
|
-
// ../../packages/core/dist/chunk-
|
|
44662
|
+
// ../../packages/core/dist/chunk-CVYJQEGX.js
|
|
44402
44663
|
function firstAtOrAfter(sorted, from) {
|
|
44403
44664
|
let lo = 0;
|
|
44404
44665
|
let hi = sorted.length;
|
|
@@ -44813,11 +45074,11 @@ function readItems(text5, state) {
|
|
|
44813
45074
|
};
|
|
44814
45075
|
}
|
|
44815
45076
|
var CASE_COMPOSED_COVER, CASE_ITEM_READER_MAX_CHARS, FENCE_OPEN, BLANK_AFTER, CASE_FRONT_MATTER, FRONT_MATTER_OPENING, withoutBom, FENCE, SETEXT_UNDERLINE, DASHES, COLUMNS, patternBody, CALCULATION_MARKER, DECISION_MARKER, DOCUMENT_MARKER, INPUT_MARKER, isSpace2, isTabOrSpace, once, OPENS_FRONT_MATTER;
|
|
44816
|
-
var
|
|
44817
|
-
"../../packages/core/dist/chunk-
|
|
45077
|
+
var init_chunk_CVYJQEGX = __esm({
|
|
45078
|
+
"../../packages/core/dist/chunk-CVYJQEGX.js"() {
|
|
44818
45079
|
"use strict";
|
|
44819
|
-
|
|
44820
|
-
|
|
45080
|
+
init_chunk_KFKBWZLE();
|
|
45081
|
+
init_chunk_BALYF7RA();
|
|
44821
45082
|
CASE_COMPOSED_COVER = "00-cover.md";
|
|
44822
45083
|
CASE_ITEM_READER_MAX_CHARS = 4 * 1024 * 1024;
|
|
44823
45084
|
FENCE_OPEN = / {0,3}(`{3,}|~{3,})([^\n]*)(?:\n|$)/y;
|
|
@@ -44847,15 +45108,15 @@ var init_chunk_QF3ISWMG = __esm({
|
|
|
44847
45108
|
var init_case_item_reader = __esm({
|
|
44848
45109
|
"../../packages/core/dist/case-item-reader.js"() {
|
|
44849
45110
|
"use strict";
|
|
44850
|
-
|
|
44851
|
-
|
|
44852
|
-
|
|
44853
|
-
|
|
44854
|
-
|
|
44855
|
-
|
|
45111
|
+
init_chunk_CVYJQEGX();
|
|
45112
|
+
init_chunk_KFKBWZLE();
|
|
45113
|
+
init_chunk_RUESJZ26();
|
|
45114
|
+
init_chunk_MQQRYOE6();
|
|
45115
|
+
init_chunk_ASIBSUKC();
|
|
45116
|
+
init_chunk_BALYF7RA();
|
|
45117
|
+
init_chunk_KWRHZBGU();
|
|
44856
45118
|
init_chunk_M2T55BV6();
|
|
44857
45119
|
init_chunk_CLGTGGVN();
|
|
44858
|
-
init_chunk_KWRHZBGU();
|
|
44859
45120
|
init_chunk_VYINA6YP();
|
|
44860
45121
|
init_chunk_ZVXO3XL6();
|
|
44861
45122
|
init_chunk_FBV7NLKO();
|
|
@@ -45194,16 +45455,16 @@ ${line}`).join("");
|
|
|
45194
45455
|
var init_case_input_sources = __esm({
|
|
45195
45456
|
"../../packages/core/dist/contracts/case-input-sources.js"() {
|
|
45196
45457
|
"use strict";
|
|
45197
|
-
|
|
45198
|
-
|
|
45199
|
-
|
|
45200
|
-
|
|
45201
|
-
|
|
45202
|
-
|
|
45203
|
-
|
|
45458
|
+
init_chunk_XE7BAV42();
|
|
45459
|
+
init_chunk_2HOHGYWQ();
|
|
45460
|
+
init_chunk_KFKBWZLE();
|
|
45461
|
+
init_chunk_RUESJZ26();
|
|
45462
|
+
init_chunk_MQQRYOE6();
|
|
45463
|
+
init_chunk_ASIBSUKC();
|
|
45464
|
+
init_chunk_BALYF7RA();
|
|
45465
|
+
init_chunk_KWRHZBGU();
|
|
45204
45466
|
init_chunk_M2T55BV6();
|
|
45205
45467
|
init_chunk_CLGTGGVN();
|
|
45206
|
-
init_chunk_KWRHZBGU();
|
|
45207
45468
|
init_chunk_VYINA6YP();
|
|
45208
45469
|
init_chunk_ZVXO3XL6();
|
|
45209
45470
|
init_chunk_FBV7NLKO();
|
|
@@ -45219,12 +45480,12 @@ var init_case_input_sources = __esm({
|
|
|
45219
45480
|
var init_case_notes = __esm({
|
|
45220
45481
|
"../../packages/core/dist/contracts/case-notes.js"() {
|
|
45221
45482
|
"use strict";
|
|
45222
|
-
|
|
45223
|
-
|
|
45224
|
-
|
|
45483
|
+
init_chunk_RUESJZ26();
|
|
45484
|
+
init_chunk_ASIBSUKC();
|
|
45485
|
+
init_chunk_BALYF7RA();
|
|
45486
|
+
init_chunk_KWRHZBGU();
|
|
45225
45487
|
init_chunk_M2T55BV6();
|
|
45226
45488
|
init_chunk_CLGTGGVN();
|
|
45227
|
-
init_chunk_KWRHZBGU();
|
|
45228
45489
|
init_chunk_VYINA6YP();
|
|
45229
45490
|
init_chunk_ZVXO3XL6();
|
|
45230
45491
|
init_chunk_FBV7NLKO();
|