@wayai/cli 0.3.305 → 0.3.307
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 +262 -75
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -5827,10 +5827,10 @@ var init_chunk_IPXBFWUU = __esm({
|
|
|
5827
5827
|
}
|
|
5828
5828
|
});
|
|
5829
5829
|
|
|
5830
|
-
// ../../packages/core/dist/chunk-
|
|
5830
|
+
// ../../packages/core/dist/chunk-SCC6AVLY.js
|
|
5831
5831
|
var PERMISSIONS;
|
|
5832
|
-
var
|
|
5833
|
-
"../../packages/core/dist/chunk-
|
|
5832
|
+
var init_chunk_SCC6AVLY = __esm({
|
|
5833
|
+
"../../packages/core/dist/chunk-SCC6AVLY.js"() {
|
|
5834
5834
|
"use strict";
|
|
5835
5835
|
PERMISSIONS = [
|
|
5836
5836
|
"hub:read",
|
|
@@ -5851,12 +5851,12 @@ var init_chunk_5VL6LBFD = __esm({
|
|
|
5851
5851
|
}
|
|
5852
5852
|
});
|
|
5853
5853
|
|
|
5854
|
-
// ../../packages/core/dist/chunk-
|
|
5854
|
+
// ../../packages/core/dist/chunk-P5GJNS5R.js
|
|
5855
5855
|
var MAX_NAME_LENGTH, MAX_HUBS_PER_GRANT, MAX_HUB_TAGS_PER_GRANT, MAX_GRANTS, permissionEnum, grantScopeSchema, grantSchema, createTokenBody, tokenOrgIdParam;
|
|
5856
|
-
var
|
|
5857
|
-
"../../packages/core/dist/chunk-
|
|
5856
|
+
var init_chunk_P5GJNS5R = __esm({
|
|
5857
|
+
"../../packages/core/dist/chunk-P5GJNS5R.js"() {
|
|
5858
5858
|
"use strict";
|
|
5859
|
-
|
|
5859
|
+
init_chunk_SCC6AVLY();
|
|
5860
5860
|
init_chunk_HZ6CADSY();
|
|
5861
5861
|
init_zod();
|
|
5862
5862
|
MAX_NAME_LENGTH = 100;
|
|
@@ -5892,10 +5892,10 @@ var init_chunk_VEERWOZ6 = __esm({
|
|
|
5892
5892
|
}
|
|
5893
5893
|
});
|
|
5894
5894
|
|
|
5895
|
-
// ../../packages/core/dist/chunk-
|
|
5896
|
-
var REKOR_ACTOR_TYPE_HEADER, REKOR_ACTOR_ID_HEADER, REKOR_ACTOR_LABEL_HEADER, REKOR_ACTOR_ORG_HEADER, REKOR_ACTOR_ADMIN_HEADER, REKOR_CLIENT_HEADER, REKOR_TOOL_ID_HEADER, REKOR_CLIENTS, rekorClientSchema, MAX_REKOR_TOOL_ID_LENGTH, rekorToolIdSchema, REKOR_V1_PREFIX, DATA_PROXY_ORG_QUERY_PARAM, MAX_PROVISIONING_BODY_BYTES, dataProxyQuery, rekorAttestation, REQUIRED_REKOR_ATTESTATION_HEADERS, REKOR_BOUND_BASE_HEADER, REKOR_BOUND_TOOLSET_HEADER, REKOR_BOUND_TOKEN_HEADER, REKOR_BOUND_ACCESS_HEADER, REKOR_BOUND_PAGE_HEADER, REKOR_BOUND_PERSON_HEADER, REKOR_PERSON_AUDIENCE_STAFF, REKOR_PERSON_AUDIENCE_CUSTOMER, REKOR_PERSON_ALL, DATA_BASE_GENERATION_HEADER, REKOR_MAX_ACTOR_ID_LENGTH, REKOR_MAX_ACTOR_LABEL_LENGTH, REKOR_MAX_ACCESS_DIMENSIONS, REKOR_MAX_ACCESS_VALUES, REKOR_MAX_ACCESS_ID_LENGTH, REKOR_MAX_ACCESS_HEADER_LENGTH, REKOR_MAX_PERSON_PARTIES, REKOR_MAX_PERSON_IDS, REKOR_MAX_PERSON_ID_LENGTH, REKOR_MAX_PERSON_HEADER_LENGTH;
|
|
5897
|
-
var
|
|
5898
|
-
"../../packages/core/dist/chunk-
|
|
5895
|
+
// ../../packages/core/dist/chunk-ZU6TSKIJ.js
|
|
5896
|
+
var REKOR_ACTOR_TYPE_HEADER, REKOR_ACTOR_ID_HEADER, REKOR_ACTOR_LABEL_HEADER, REKOR_ACTOR_ORG_HEADER, REKOR_ACTOR_ADMIN_HEADER, REKOR_CLIENT_HEADER, REKOR_TOOL_ID_HEADER, REKOR_CLIENTS, rekorClientSchema, MAX_REKOR_TOOL_ID_LENGTH, rekorToolIdSchema, REKOR_V1_PREFIX, REKOR_LIFECYCLE_PREFIX, REKOR_BASE_VAULT_DRY_RUN_PATH, DATA_PROXY_ORG_QUERY_PARAM, MAX_PROVISIONING_BODY_BYTES, dataProxyQuery, rekorAttestation, REQUIRED_REKOR_ATTESTATION_HEADERS, REKOR_BOUND_BASE_HEADER, REKOR_BOUND_TOOLSET_HEADER, REKOR_BOUND_TOKEN_HEADER, REKOR_BOUND_ACCESS_HEADER, REKOR_BOUND_PAGE_HEADER, REKOR_BOUND_PERSON_HEADER, REKOR_PERSON_AUDIENCE_STAFF, REKOR_PERSON_AUDIENCE_CUSTOMER, REKOR_PERSON_ALL, DATA_BASE_GENERATION_HEADER, REKOR_MAX_ACTOR_ID_LENGTH, REKOR_MAX_ACTOR_LABEL_LENGTH, REKOR_MAX_ACCESS_DIMENSIONS, REKOR_MAX_ACCESS_VALUES, REKOR_MAX_ACCESS_ID_LENGTH, REKOR_MAX_ACCESS_HEADER_LENGTH, REKOR_MAX_PERSON_PARTIES, REKOR_MAX_PERSON_IDS, REKOR_MAX_PERSON_ID_LENGTH, REKOR_MAX_PERSON_HEADER_LENGTH;
|
|
5897
|
+
var init_chunk_ZU6TSKIJ = __esm({
|
|
5898
|
+
"../../packages/core/dist/chunk-ZU6TSKIJ.js"() {
|
|
5899
5899
|
"use strict";
|
|
5900
5900
|
init_zod();
|
|
5901
5901
|
REKOR_ACTOR_TYPE_HEADER = "X-Rekor-Actor-Type";
|
|
@@ -5910,6 +5910,8 @@ var init_chunk_4D6K4P4K = __esm({
|
|
|
5910
5910
|
MAX_REKOR_TOOL_ID_LENGTH = 128;
|
|
5911
5911
|
rekorToolIdSchema = external_exports.string().trim().min(1).max(MAX_REKOR_TOOL_ID_LENGTH);
|
|
5912
5912
|
REKOR_V1_PREFIX = "/v1";
|
|
5913
|
+
REKOR_LIFECYCLE_PREFIX = "/lifecycle";
|
|
5914
|
+
REKOR_BASE_VAULT_DRY_RUN_PATH = `${REKOR_LIFECYCLE_PREFIX}/vault-dry-run`;
|
|
5913
5915
|
DATA_PROXY_ORG_QUERY_PARAM = "org_id";
|
|
5914
5916
|
MAX_PROVISIONING_BODY_BYTES = 256 * 1024;
|
|
5915
5917
|
dataProxyQuery = external_exports.object({
|
|
@@ -5948,7 +5950,7 @@ var init_chunk_4D6K4P4K = __esm({
|
|
|
5948
5950
|
}
|
|
5949
5951
|
});
|
|
5950
5952
|
|
|
5951
|
-
// ../../packages/core/dist/chunk-
|
|
5953
|
+
// ../../packages/core/dist/chunk-NA5MISVT.js
|
|
5952
5954
|
function isPersonAccessAll(lists) {
|
|
5953
5955
|
return lists !== void 0 && lists.read.length === 1 && lists.read[0] === ACCESS_UNRESTRICTED && lists.write.length === 1 && lists.write[0] === ACCESS_UNRESTRICTED;
|
|
5954
5956
|
}
|
|
@@ -5986,10 +5988,10 @@ function assignmentHasUnrestricted(assignment) {
|
|
|
5986
5988
|
return Object.values(assignment).some((lists) => lists.read.includes(ACCESS_UNRESTRICTED) || lists.write.includes(ACCESS_UNRESTRICTED));
|
|
5987
5989
|
}
|
|
5988
5990
|
var ACCESS_UNRESTRICTED, ACCESS_ID_REGEX, ACCESS_ID_MAX_LENGTH, MAX_ACCESS_DIMENSIONS_PER_ORG, MAX_ACCESS_VALUES_PER_DIMENSION, ACCESS_LABEL_MAX_LENGTH, accessIdSchema, accessLabelSchema, accessValueListSchema, accessListsSchema, accessAssignmentSchema, PERSON_ACCESS_KEY, heldAccessKeySchema, heldAccessAssignmentSchema, AGENT_PERSON_ACCESS_REFUSAL, accessSetSchema, accessDimensionParam, accessValueParam, orgMemberParam, orgHubParam, createAccessDimensionBody, updateAccessDimensionBody, createAccessValueBody, updateAccessValueBody, setMemberAccessValuesBody, HUB_PERSON_KINDS, ACCESS_PERSON_KINDS, setHubUserAccessValuesBody, setHubAccessValuesBody, setAgentAccessValuesBody;
|
|
5989
|
-
var
|
|
5990
|
-
"../../packages/core/dist/chunk-
|
|
5991
|
+
var init_chunk_NA5MISVT = __esm({
|
|
5992
|
+
"../../packages/core/dist/chunk-NA5MISVT.js"() {
|
|
5991
5993
|
"use strict";
|
|
5992
|
-
|
|
5994
|
+
init_chunk_ZU6TSKIJ();
|
|
5993
5995
|
init_chunk_HZ6CADSY();
|
|
5994
5996
|
init_chunk_YROEDMVZ();
|
|
5995
5997
|
init_zod();
|
|
@@ -6080,7 +6082,7 @@ var init_chunk_HRKVCI5A = __esm({
|
|
|
6080
6082
|
}
|
|
6081
6083
|
});
|
|
6082
6084
|
|
|
6083
|
-
// ../../packages/core/dist/chunk-
|
|
6085
|
+
// ../../packages/core/dist/chunk-AOORZEAJ.js
|
|
6084
6086
|
function boundCustomerPartyIsValid(audience, parties, customer) {
|
|
6085
6087
|
return audience !== REKOR_PERSON_AUDIENCE_STAFF && customer < parties.length && Array.isArray(parties[customer]);
|
|
6086
6088
|
}
|
|
@@ -6094,11 +6096,11 @@ function isEncodedBoundPerson(raw) {
|
|
|
6094
6096
|
return rekorBoundPersonSchema.safeParse(parsed).success;
|
|
6095
6097
|
}
|
|
6096
6098
|
var TOOLSET_SLUG_PATTERN, REKOR_STRUCTURAL_ID_PATTERN, baseEnvironmentSchema, toolsetFileToolSchema, toolsetSurfaceSchema, toolsetConnectionBindingSchema, rekorToolsetToolsSchema, rekorPersonIdSchema, rekorPersonAudienceSchema, rekorBoundPersonSchema, rekorBoundAttestation, rekorResolvedToolsetSchema, REKOR_TOOL_KINDS_PARAM, REKOR_TOOL_KINDS_RESOLVE_SEARCH, resolvedRecordTypeSchema, reviewWritersSchema, sharedScopeSchema, resolvedFileToolSchema, rekorToolsetFileSchema, rekorToolsetFileUrlAnswerSchema, rekorToolsetFileListSchema, rekorToolsetFileGetSchema, rekorToolsetFilePutSchema, TOOLSET_CUSTOMER_FACING_REFUSAL_MARK, TOOLSET_CUSTOMER_FACING_REFUSAL, BASE_TOOLSET_ONLY_FOR_CUSTOMER_FACING, GENERIC_DATA_MCP_CUSTOMER_FACING_REFUSAL, GENERIC_DATA_API_CUSTOMER_FACING_REFUSAL;
|
|
6097
|
-
var
|
|
6098
|
-
"../../packages/core/dist/chunk-
|
|
6099
|
+
var init_chunk_AOORZEAJ = __esm({
|
|
6100
|
+
"../../packages/core/dist/chunk-AOORZEAJ.js"() {
|
|
6099
6101
|
"use strict";
|
|
6100
|
-
|
|
6101
|
-
|
|
6102
|
+
init_chunk_NA5MISVT();
|
|
6103
|
+
init_chunk_ZU6TSKIJ();
|
|
6102
6104
|
init_zod();
|
|
6103
6105
|
TOOLSET_SLUG_PATTERN = /^[A-Za-z0-9_-]{1,128}$/;
|
|
6104
6106
|
REKOR_STRUCTURAL_ID_PATTERN = TOOLSET_SLUG_PATTERN;
|
|
@@ -6357,13 +6359,13 @@ var init_chunk_2DXRB6DR = __esm({
|
|
|
6357
6359
|
}
|
|
6358
6360
|
});
|
|
6359
6361
|
|
|
6360
|
-
// ../../packages/core/dist/chunk-
|
|
6362
|
+
// ../../packages/core/dist/chunk-I3QUINTR.js
|
|
6361
6363
|
var TOOLSET_ANSWER_PERSON_PARTIES, toolsetAnswerPersonSchema, toolsetAnswerPersonsSchema;
|
|
6362
|
-
var
|
|
6363
|
-
"../../packages/core/dist/chunk-
|
|
6364
|
+
var init_chunk_I3QUINTR = __esm({
|
|
6365
|
+
"../../packages/core/dist/chunk-I3QUINTR.js"() {
|
|
6364
6366
|
"use strict";
|
|
6365
|
-
|
|
6366
|
-
|
|
6367
|
+
init_chunk_AOORZEAJ();
|
|
6368
|
+
init_chunk_ZU6TSKIJ();
|
|
6367
6369
|
init_zod();
|
|
6368
6370
|
TOOLSET_ANSWER_PERSON_PARTIES = ["requester", "originator", "initiator", "delegator"];
|
|
6369
6371
|
toolsetAnswerPersonSchema = external_exports.object({
|
|
@@ -7717,12 +7719,12 @@ var init_chunk_FBV7NLKO = __esm({
|
|
|
7717
7719
|
}
|
|
7718
7720
|
});
|
|
7719
7721
|
|
|
7720
|
-
// ../../packages/core/dist/chunk-
|
|
7722
|
+
// ../../packages/core/dist/chunk-ENZVMH3Y.js
|
|
7721
7723
|
var hubPageWatchParam, pageWatchedBaseSchema, hubPageWatchResponseSchema;
|
|
7722
|
-
var
|
|
7723
|
-
"../../packages/core/dist/chunk-
|
|
7724
|
+
var init_chunk_ENZVMH3Y = __esm({
|
|
7725
|
+
"../../packages/core/dist/chunk-ENZVMH3Y.js"() {
|
|
7724
7726
|
"use strict";
|
|
7725
|
-
|
|
7727
|
+
init_chunk_AOORZEAJ();
|
|
7726
7728
|
init_chunk_FBV7NLKO();
|
|
7727
7729
|
init_chunk_HZ6CADSY();
|
|
7728
7730
|
init_zod();
|
|
@@ -13106,7 +13108,7 @@ var init_chunk_2ISUBJG7 = __esm({
|
|
|
13106
13108
|
}
|
|
13107
13109
|
});
|
|
13108
13110
|
|
|
13109
|
-
// ../../packages/core/dist/chunk-
|
|
13111
|
+
// ../../packages/core/dist/chunk-6VGAJZIK.js
|
|
13110
13112
|
function describeRole(role) {
|
|
13111
13113
|
if (typeof role === "string") {
|
|
13112
13114
|
return JSON.stringify(role.length > ROLE_ECHO_MAX ? `${role.slice(0, ROLE_ECHO_MAX)}\u2026` : role);
|
|
@@ -13285,10 +13287,10 @@ function terminalRunCount(counts) {
|
|
|
13285
13287
|
return counts.successful_runs + counts.failed_runs;
|
|
13286
13288
|
}
|
|
13287
13289
|
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;
|
|
13288
|
-
var
|
|
13289
|
-
"../../packages/core/dist/chunk-
|
|
13290
|
+
var init_chunk_6VGAJZIK = __esm({
|
|
13291
|
+
"../../packages/core/dist/chunk-6VGAJZIK.js"() {
|
|
13290
13292
|
"use strict";
|
|
13291
|
-
|
|
13293
|
+
init_chunk_ZU6TSKIJ();
|
|
13292
13294
|
init_chunk_2YEGUQR7();
|
|
13293
13295
|
init_chunk_4LXDRTO4();
|
|
13294
13296
|
init_chunk_WTOA3ANF();
|
|
@@ -14363,7 +14365,7 @@ var init_chunk_MO23HUAX = __esm({
|
|
|
14363
14365
|
}
|
|
14364
14366
|
});
|
|
14365
14367
|
|
|
14366
|
-
// ../../packages/core/dist/chunk-
|
|
14368
|
+
// ../../packages/core/dist/chunk-Y45EQMIG.js
|
|
14367
14369
|
function declaresNoConnection(agent) {
|
|
14368
14370
|
return agent.connection === null && !agent.connection_id;
|
|
14369
14371
|
}
|
|
@@ -15095,12 +15097,12 @@ function skillSectionsAsResources(scope) {
|
|
|
15095
15097
|
};
|
|
15096
15098
|
}
|
|
15097
15099
|
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, MAX_HUB_AS_CODE_PAGE_MANIFEST_CHARS, hubAsCodePagesSchema, MAX_CALL_OPENING_CARRIERS, MAX_CALL_OPENING_AGGREGATE_ENCODED_BYTES, HUB_AS_CODE_AGENT_TOOL_KEYS, hubAsCodeStateSchema, hubAsCodeResourceFileSchema, hubAsCodeResourceSchema, uuidPattern, ciUuidSchema, flagEntriesOf, boundedHubAsCodeResourcesSchema, isPlainObject, MIN_SKILLS_LAYOUT_CLI, MAX_HUB_AS_CODE_DEPTH, NAMED_DEPTH_SEGMENTS, NAMED_DEPTH_KEY_CHARS, fieldName, hubAsCodeConfigSchema, ciPullHubIdParam, ciBranchParam, ciPullQuery, ciHubsQuery, ciLookupQuery, ciBranchesQuery, ciSyncBody, ciPushBody, ciDiffBody, ciPublishBody, ciPublishPreviewBody, ciSyncMcpBody, ciOrgResourcesParam, orgResourcesConfigSchema, ciOrgResourcesPushBody, ciOrgResourcesDiffBody, CI_APPLY_ENTITY_KINDS, CI_APPLY_OPERATIONS, ciApplyErrorBaseSchema, ciApplyErrorSchema, ciSyncCountSchema, ciSyncChangesSchema, ciSyncWarningSchema, ciSyncResponseSchema;
|
|
15098
|
-
var
|
|
15099
|
-
"../../packages/core/dist/chunk-
|
|
15100
|
+
var init_chunk_Y45EQMIG = __esm({
|
|
15101
|
+
"../../packages/core/dist/chunk-Y45EQMIG.js"() {
|
|
15100
15102
|
"use strict";
|
|
15101
15103
|
init_chunk_YI3ORIXJ();
|
|
15102
|
-
|
|
15103
|
-
|
|
15104
|
+
init_chunk_NA5MISVT();
|
|
15105
|
+
init_chunk_6VGAJZIK();
|
|
15104
15106
|
init_chunk_LBDH7LCG();
|
|
15105
15107
|
init_chunk_4LXDRTO4();
|
|
15106
15108
|
init_chunk_MO23HUAX();
|
|
@@ -15479,10 +15481,10 @@ var init_chunk_BFG4ZWR4 = __esm({
|
|
|
15479
15481
|
}
|
|
15480
15482
|
});
|
|
15481
15483
|
|
|
15482
|
-
// ../../packages/core/dist/chunk-
|
|
15484
|
+
// ../../packages/core/dist/chunk-2R5D4TEX.js
|
|
15483
15485
|
var dataExplorerDebugDoType, DEBUG_READ_MAX_LIMIT, DEBUG_READ_DEFAULT_LIMIT;
|
|
15484
|
-
var
|
|
15485
|
-
"../../packages/core/dist/chunk-
|
|
15486
|
+
var init_chunk_2R5D4TEX = __esm({
|
|
15487
|
+
"../../packages/core/dist/chunk-2R5D4TEX.js"() {
|
|
15486
15488
|
"use strict";
|
|
15487
15489
|
init_zod();
|
|
15488
15490
|
dataExplorerDebugDoType = external_exports.enum(["hub", "org", "conversation", "user", "platform", "thread", "community", "contact_book", "batch"]);
|
|
@@ -15593,7 +15595,7 @@ var init_chunk_OMPT4ZHR = __esm({
|
|
|
15593
15595
|
}
|
|
15594
15596
|
});
|
|
15595
15597
|
|
|
15596
|
-
// ../../packages/core/dist/chunk-
|
|
15598
|
+
// ../../packages/core/dist/chunk-7ILN55YW.js
|
|
15597
15599
|
function refineScopedTarget(data, ctx) {
|
|
15598
15600
|
if (data.scope === "org") {
|
|
15599
15601
|
if (!data.org_id) {
|
|
@@ -15619,12 +15621,12 @@ function refineScopedTarget(data, ctx) {
|
|
|
15619
15621
|
}
|
|
15620
15622
|
}
|
|
15621
15623
|
var adminOrgIdParam, adminOrgAdminIdParam, adminUserIdParam, PRICING_PLAN_ID_RE, adminPlanIdParam, adminOrganizationsQuery, adminUserSearchQuery, kanbanSlugMigrationQuery, adjustQuotaBody, updatePlanBody, addAdminUserBody, MAX_VOICE_CALL_MINUTE_OPS, voiceCallMinuteOps, AUTOMATION_GATE_EVALUATIONS_PER_OPERATION_BOUND, automationGateEvaluationsPerOperation, AUTOMATION_RUN_RETENTION_DAYS_MAX, automationRunRetentionDays, turnDeadlineSeconds, updatePlatformConfigBody, updateFreeOrgLimitBody, adminScopedTargetShape, adminScopedTargetBody, adminDryRunByDefaultTargetBody, BRANCHING_ORPHAN_ENTITY_TYPES, BRANCHING_ORPHAN_MAX_TARGETS, adminRepairBranchingOrphansBody, adminRepairLegacyOrgGrantsBody, adminRepairCompedPlansBody, updatePricingPlanBody, dataExplorerSearchQuery, dataExplorerOrgIdParam, dataExplorerHubIdParam, dataExplorerConvIdParam, dataExplorerDoInstancesQuery, dataExplorerNsIdParam, dataExplorerKvKeysBody, dataExplorerKvKeyBody, uuidOrHexId, dataExplorerDeleteOrgParam, dataExplorerDeleteHubParam, dataExplorerDeleteConvParam, dataExplorerDeleteUserParam, dataExplorerDeleteQuery, dataExplorerKvDeleteBody, pitrDoNamespace, pitrBookmarkParam, pitrRestoreBody, healthSamplingTriggerBody, DEBUG_DO_HEX_PREFIX, debugDoEntityId, debugTableName, dataExplorerDebugTablesParam, dataExplorerDebugRowsParam, dataExplorerDebugRowsQuery, dataExplorerDebugAnalyticsTable, debugUuid, dataExplorerDebugAnalyticsRowsParam, dataExplorerDebugAnalyticsRowsQuery, dataExplorerDebugCountsDoType, dataExplorerDebugCountsParam, debugHubConvParam, debugMessageIdQuery;
|
|
15622
|
-
var
|
|
15623
|
-
"../../packages/core/dist/chunk-
|
|
15624
|
+
var init_chunk_7ILN55YW = __esm({
|
|
15625
|
+
"../../packages/core/dist/chunk-7ILN55YW.js"() {
|
|
15624
15626
|
"use strict";
|
|
15625
15627
|
init_chunk_FECLIZTY();
|
|
15626
15628
|
init_chunk_BFG4ZWR4();
|
|
15627
|
-
|
|
15629
|
+
init_chunk_2R5D4TEX();
|
|
15628
15630
|
init_chunk_MO23HUAX();
|
|
15629
15631
|
init_chunk_OMPT4ZHR();
|
|
15630
15632
|
init_chunk_HZ6CADSY();
|
|
@@ -16266,10 +16268,10 @@ var init_chunk_ELBFOFQD = __esm({
|
|
|
16266
16268
|
}
|
|
16267
16269
|
});
|
|
16268
16270
|
|
|
16269
|
-
// ../../packages/core/dist/chunk-
|
|
16271
|
+
// ../../packages/core/dist/chunk-ULQGJUXZ.js
|
|
16270
16272
|
var baseDestructionConfirmBody, BASE_DESTRUCTION_GRACE_MS, BASE_DESTRUCTION_CONFIRM_TTL_MS, BASE_DESTRUCTION_ORG_QUERY_PARAM, baseDestructionQuery, baseDestructionParam, baseDestructionInitiateBody, baseDestructionStatus, baseDestructionRequest, baseDestructionListResponse, baseDestructionInitiateResponse, baseDestructionConfirmResponse, baseDestructionCancelResponse;
|
|
16271
|
-
var
|
|
16272
|
-
"../../packages/core/dist/chunk-
|
|
16273
|
+
var init_chunk_ULQGJUXZ = __esm({
|
|
16274
|
+
"../../packages/core/dist/chunk-ULQGJUXZ.js"() {
|
|
16273
16275
|
"use strict";
|
|
16274
16276
|
init_zod();
|
|
16275
16277
|
baseDestructionConfirmBody = external_exports.object({
|
|
@@ -16395,16 +16397,16 @@ var init_contracts = __esm({
|
|
|
16395
16397
|
init_chunk_HA7CRZMX();
|
|
16396
16398
|
init_chunk_MF2VVXBR();
|
|
16397
16399
|
init_chunk_IPXBFWUU();
|
|
16398
|
-
|
|
16399
|
-
|
|
16400
|
+
init_chunk_P5GJNS5R();
|
|
16401
|
+
init_chunk_I3QUINTR();
|
|
16400
16402
|
init_chunk_ZC6YGHNX();
|
|
16401
16403
|
init_chunk_5DGHIY7L();
|
|
16402
16404
|
init_chunk_UVGO72D6();
|
|
16403
16405
|
init_chunk_IPDOHAZ5();
|
|
16404
16406
|
init_chunk_PFGVH2CX();
|
|
16405
16407
|
init_chunk_GPM7PE44();
|
|
16406
|
-
|
|
16407
|
-
|
|
16408
|
+
init_chunk_ENZVMH3Y();
|
|
16409
|
+
init_chunk_AOORZEAJ();
|
|
16408
16410
|
init_chunk_ZXK6N2HN();
|
|
16409
16411
|
init_chunk_Y7CFCYX4();
|
|
16410
16412
|
init_chunk_MGBAXT5Y();
|
|
@@ -16434,20 +16436,20 @@ var init_contracts = __esm({
|
|
|
16434
16436
|
init_chunk_E4DIIOOE();
|
|
16435
16437
|
init_chunk_7CYHPF35();
|
|
16436
16438
|
init_chunk_NETRUHZF();
|
|
16437
|
-
|
|
16439
|
+
init_chunk_Y45EQMIG();
|
|
16438
16440
|
init_chunk_YI3ORIXJ();
|
|
16439
|
-
|
|
16440
|
-
|
|
16441
|
-
|
|
16441
|
+
init_chunk_NA5MISVT();
|
|
16442
|
+
init_chunk_6VGAJZIK();
|
|
16443
|
+
init_chunk_ZU6TSKIJ();
|
|
16442
16444
|
init_chunk_2YEGUQR7();
|
|
16443
16445
|
init_chunk_LBDH7LCG();
|
|
16444
16446
|
init_chunk_4LXDRTO4();
|
|
16445
16447
|
init_chunk_JDJ4EUOL();
|
|
16446
16448
|
init_chunk_NVKU5PPQ();
|
|
16447
|
-
|
|
16449
|
+
init_chunk_7ILN55YW();
|
|
16448
16450
|
init_chunk_FECLIZTY();
|
|
16449
16451
|
init_chunk_BFG4ZWR4();
|
|
16450
|
-
|
|
16452
|
+
init_chunk_2R5D4TEX();
|
|
16451
16453
|
init_chunk_MO23HUAX();
|
|
16452
16454
|
init_chunk_X5PZZVTS();
|
|
16453
16455
|
init_chunk_D3EP4TDU();
|
|
@@ -16459,7 +16461,7 @@ var init_contracts = __esm({
|
|
|
16459
16461
|
init_chunk_R6Y377AW();
|
|
16460
16462
|
init_chunk_UAOHHCW5();
|
|
16461
16463
|
init_chunk_FGNMHILL();
|
|
16462
|
-
|
|
16464
|
+
init_chunk_ULQGJUXZ();
|
|
16463
16465
|
init_chunk_OMPT4ZHR();
|
|
16464
16466
|
init_chunk_DWJOFJEA();
|
|
16465
16467
|
init_chunk_SOJMWM63();
|
|
@@ -16469,7 +16471,7 @@ var init_contracts = __esm({
|
|
|
16469
16471
|
init_chunk_S4VDZ7PZ();
|
|
16470
16472
|
init_chunk_KB5RK3RP();
|
|
16471
16473
|
init_chunk_CJ3L46X6();
|
|
16472
|
-
|
|
16474
|
+
init_chunk_SCC6AVLY();
|
|
16473
16475
|
init_chunk_2ISUBJG7();
|
|
16474
16476
|
init_chunk_C2UEA2KW();
|
|
16475
16477
|
init_chunk_6J742GLA();
|
|
@@ -16493,16 +16495,16 @@ var init_contracts = __esm({
|
|
|
16493
16495
|
}
|
|
16494
16496
|
});
|
|
16495
16497
|
|
|
16496
|
-
// ../../packages/core/dist/chunk-
|
|
16498
|
+
// ../../packages/core/dist/chunk-7LILII6I.js
|
|
16497
16499
|
function identifyTokenType(token) {
|
|
16498
16500
|
if (token.startsWith("way_")) return "way_token";
|
|
16499
16501
|
if (token.startsWith("eyJ")) return "jwt";
|
|
16500
16502
|
return "unknown";
|
|
16501
16503
|
}
|
|
16502
|
-
var
|
|
16503
|
-
"../../packages/core/dist/chunk-
|
|
16504
|
+
var init_chunk_7LILII6I = __esm({
|
|
16505
|
+
"../../packages/core/dist/chunk-7LILII6I.js"() {
|
|
16504
16506
|
"use strict";
|
|
16505
|
-
|
|
16507
|
+
init_chunk_SCC6AVLY();
|
|
16506
16508
|
}
|
|
16507
16509
|
});
|
|
16508
16510
|
|
|
@@ -16633,8 +16635,8 @@ var init_dist = __esm({
|
|
|
16633
16635
|
init_chunk_S4VDZ7PZ();
|
|
16634
16636
|
init_chunk_KB5RK3RP();
|
|
16635
16637
|
init_chunk_CJ3L46X6();
|
|
16636
|
-
|
|
16637
|
-
|
|
16638
|
+
init_chunk_7LILII6I();
|
|
16639
|
+
init_chunk_SCC6AVLY();
|
|
16638
16640
|
init_chunk_ERFR7IRY();
|
|
16639
16641
|
init_chunk_2ISUBJG7();
|
|
16640
16642
|
init_chunk_FEOO3UPS();
|
|
@@ -17873,6 +17875,7 @@ var init_utils = __esm({
|
|
|
17873
17875
|
["admin orgs repair-legacy-grants", { positionals: 0, values: ["--org"], dryRun: true }],
|
|
17874
17876
|
["admin vault import", { positionals: 0, values: ["--org", "--connector", "--max-puts", "--approved"] }],
|
|
17875
17877
|
["admin vault revert", { positionals: 0, values: ["--org", "--connector"] }],
|
|
17878
|
+
["admin vault base-dry-run", { positionals: 0, values: ["--org", "--base", "--after"] }],
|
|
17876
17879
|
["admin harness mass-destroy", { positionals: 0, values: ["--org", "--hub"], dryRun: true }],
|
|
17877
17880
|
["admin harness disable", { positionals: 0 }],
|
|
17878
17881
|
["admin harness enable", { positionals: 0 }],
|
|
@@ -19107,6 +19110,13 @@ var init_api_client = __esm({
|
|
|
19107
19110
|
async debugCounts(doType, doId) {
|
|
19108
19111
|
return this.request("GET", `/api/admin/data-explorer/debug/do/${doType}/${encodeURIComponent(doId)}/counts`);
|
|
19109
19112
|
}
|
|
19113
|
+
/** One page of an org's base-secrets dry run, or one base's: numbers, reason codes and ids. */
|
|
19114
|
+
async debugBaseVaultDryRun(query) {
|
|
19115
|
+
const params = new URLSearchParams({ org_id: query.org_id });
|
|
19116
|
+
if (query.base_id) params.set("base_id", query.base_id);
|
|
19117
|
+
if (query.after) params.set("after", query.after);
|
|
19118
|
+
return this.request("GET", `/api/admin/data-explorer/debug/base-vault-dry-run?${params.toString()}`);
|
|
19119
|
+
}
|
|
19110
19120
|
async debugListAnalyticsTables() {
|
|
19111
19121
|
return this.request("GET", "/api/admin/data-explorer/debug/analytics/tables");
|
|
19112
19122
|
}
|
|
@@ -21839,8 +21849,8 @@ var init_pages2 = __esm({
|
|
|
21839
21849
|
var init_evals = __esm({
|
|
21840
21850
|
"../../packages/core/dist/contracts/evals.js"() {
|
|
21841
21851
|
"use strict";
|
|
21842
|
-
|
|
21843
|
-
|
|
21852
|
+
init_chunk_6VGAJZIK();
|
|
21853
|
+
init_chunk_ZU6TSKIJ();
|
|
21844
21854
|
init_chunk_2YEGUQR7();
|
|
21845
21855
|
init_chunk_4LXDRTO4();
|
|
21846
21856
|
init_chunk_WTOA3ANF();
|
|
@@ -22867,11 +22877,11 @@ var init_hub_materializer = __esm({
|
|
|
22867
22877
|
var init_ci = __esm({
|
|
22868
22878
|
"../../packages/core/dist/contracts/ci.js"() {
|
|
22869
22879
|
"use strict";
|
|
22870
|
-
|
|
22880
|
+
init_chunk_Y45EQMIG();
|
|
22871
22881
|
init_chunk_YI3ORIXJ();
|
|
22872
|
-
|
|
22873
|
-
|
|
22874
|
-
|
|
22882
|
+
init_chunk_NA5MISVT();
|
|
22883
|
+
init_chunk_6VGAJZIK();
|
|
22884
|
+
init_chunk_ZU6TSKIJ();
|
|
22875
22885
|
init_chunk_2YEGUQR7();
|
|
22876
22886
|
init_chunk_LBDH7LCG();
|
|
22877
22887
|
init_chunk_4LXDRTO4();
|
|
@@ -37697,6 +37707,107 @@ var init_file_map = __esm({
|
|
|
37697
37707
|
}
|
|
37698
37708
|
});
|
|
37699
37709
|
|
|
37710
|
+
// ../../packages/core/dist/contracts/vault-import.js
|
|
37711
|
+
var VAULT_IMPORT_DEFAULT_PUTS, VAULT_IMPORT_MAX_PUTS, VAULT_IMPORT_MAX_APPROVED, vaultImportRunBody, vaultImportRevertBody, dryRunKey, dryRunCount, dryRunCounts, dryRunTable, baseVaultDryRunReport, BASE_VAULT_DRY_RUN_UNREADABLE, dryRunBaseId, baseVaultDryRunBase, BASE_VAULT_DRY_RUN_LISTINGS, baseVaultDryRunPage, baseVaultDryRunQuery;
|
|
37712
|
+
var init_vault_import = __esm({
|
|
37713
|
+
"../../packages/core/dist/contracts/vault-import.js"() {
|
|
37714
|
+
"use strict";
|
|
37715
|
+
init_chunk_HZ6CADSY();
|
|
37716
|
+
init_zod();
|
|
37717
|
+
VAULT_IMPORT_DEFAULT_PUTS = 25;
|
|
37718
|
+
VAULT_IMPORT_MAX_PUTS = 100;
|
|
37719
|
+
VAULT_IMPORT_MAX_APPROVED = 1e3;
|
|
37720
|
+
vaultImportRunBody = external_exports.object({
|
|
37721
|
+
org_id: uuidSchema,
|
|
37722
|
+
/** A catalog `connector_id` the vault holds fields of. */
|
|
37723
|
+
connector_id: external_exports.string().min(1).max(128),
|
|
37724
|
+
dry_run: external_exports.boolean().optional().default(true),
|
|
37725
|
+
max_puts: external_exports.number().int().min(1).max(VAULT_IMPORT_MAX_PUTS).optional().default(VAULT_IMPORT_DEFAULT_PUTS),
|
|
37726
|
+
/**
|
|
37727
|
+
* REST API, External Resources and MCP Server only, and required for their real run: the `policy_hash` of each
|
|
37728
|
+
* value a dry run listed that the owner approved (`VaultImportPolicyEntry`). Any other value stays (`not_approved`).
|
|
37729
|
+
*/
|
|
37730
|
+
approved_policies: external_exports.array(external_exports.string().regex(/^[0-9a-f]{64}$/)).max(VAULT_IMPORT_MAX_APPROVED).optional()
|
|
37731
|
+
}).strict();
|
|
37732
|
+
vaultImportRevertBody = vaultImportRunBody.omit({ max_puts: true, approved_policies: true });
|
|
37733
|
+
dryRunKey = external_exports.string().regex(/^[a-z][a-z0-9_]{0,63}$/);
|
|
37734
|
+
dryRunCount = external_exports.number().int().nonnegative();
|
|
37735
|
+
dryRunCounts = external_exports.record(dryRunKey, dryRunCount);
|
|
37736
|
+
dryRunTable = external_exports.record(dryRunKey, dryRunCounts);
|
|
37737
|
+
baseVaultDryRunReport = external_exports.strictObject({
|
|
37738
|
+
stores: dryRunTable,
|
|
37739
|
+
would_move: dryRunCounts,
|
|
37740
|
+
would_refuse: dryRunTable
|
|
37741
|
+
});
|
|
37742
|
+
BASE_VAULT_DRY_RUN_UNREADABLE = ["overloaded", "timeout", "error"];
|
|
37743
|
+
dryRunBaseId = external_exports.string().min(1).max(512);
|
|
37744
|
+
baseVaultDryRunBase = external_exports.discriminatedUnion("status", [
|
|
37745
|
+
external_exports.strictObject({ base_id: dryRunBaseId, status: external_exports.literal("read"), report: baseVaultDryRunReport }),
|
|
37746
|
+
external_exports.strictObject({ base_id: dryRunBaseId, status: external_exports.literal("absent") }),
|
|
37747
|
+
external_exports.strictObject({ base_id: dryRunBaseId, status: external_exports.literal("unreadable"), reason: external_exports.enum(BASE_VAULT_DRY_RUN_UNREADABLE) })
|
|
37748
|
+
]);
|
|
37749
|
+
BASE_VAULT_DRY_RUN_LISTINGS = ["named", "registry", "registry_not_seeded"];
|
|
37750
|
+
baseVaultDryRunPage = external_exports.strictObject({
|
|
37751
|
+
org_id: external_exports.string().min(1).max(128),
|
|
37752
|
+
listing: external_exports.enum(BASE_VAULT_DRY_RUN_LISTINGS),
|
|
37753
|
+
bases: external_exports.array(baseVaultDryRunBase).max(50),
|
|
37754
|
+
next_after: dryRunBaseId.nullable()
|
|
37755
|
+
});
|
|
37756
|
+
baseVaultDryRunQuery = external_exports.object({
|
|
37757
|
+
org_id: uuidSchema,
|
|
37758
|
+
/** A base id as the CLI sends one: it names a Durable Object and nothing else. */
|
|
37759
|
+
base_id: external_exports.string().regex(/^(?!\.\.?$)[A-Za-z0-9._-]{1,256}$/).optional(),
|
|
37760
|
+
after: dryRunBaseId.optional()
|
|
37761
|
+
}).refine((query) => !(query.base_id && query.after), { message: "base_id and after cannot be combined" });
|
|
37762
|
+
}
|
|
37763
|
+
});
|
|
37764
|
+
|
|
37765
|
+
// src/lib/base-vault-dry-run.ts
|
|
37766
|
+
function addCounts(into, from) {
|
|
37767
|
+
for (const [key, value] of Object.entries(from)) {
|
|
37768
|
+
if (typeof value === "number") {
|
|
37769
|
+
into[key] = (into[key] ?? 0) + value;
|
|
37770
|
+
} else {
|
|
37771
|
+
into[key] ??= {};
|
|
37772
|
+
addCounts(into[key], value);
|
|
37773
|
+
}
|
|
37774
|
+
}
|
|
37775
|
+
}
|
|
37776
|
+
function summarizeBaseVaultDryRun(input) {
|
|
37777
|
+
const bases = input.pages.flatMap((page) => page.bases);
|
|
37778
|
+
const totals = { stores: {}, would_move: {}, would_refuse: {} };
|
|
37779
|
+
for (const base of bases) {
|
|
37780
|
+
if (base.status === "read") addCounts(totals, base.report);
|
|
37781
|
+
}
|
|
37782
|
+
const count = (status) => bases.filter((base) => base.status === status).length;
|
|
37783
|
+
const nextAfter = input.pages.at(-1)?.next_after ?? null;
|
|
37784
|
+
const reasons = [];
|
|
37785
|
+
if (input.resumedAfter) reasons.push("resumed_from_cursor");
|
|
37786
|
+
if (input.pages.some((page) => page.listing === "named")) reasons.push("single_base");
|
|
37787
|
+
if (nextAfter !== null) reasons.push("listing_truncated");
|
|
37788
|
+
if (count("unreadable") > 0) reasons.push("base_unreadable");
|
|
37789
|
+
if (input.pages.some((page) => page.listing === "registry_not_seeded")) reasons.push("registry_not_seeded");
|
|
37790
|
+
if (input.stop) reasons.push(input.stop);
|
|
37791
|
+
return {
|
|
37792
|
+
org_id: input.orgId,
|
|
37793
|
+
complete: reasons.length === 0,
|
|
37794
|
+
incomplete_reasons: reasons,
|
|
37795
|
+
reads: input.pages.length,
|
|
37796
|
+
bases_listed: bases.length,
|
|
37797
|
+
bases_read: count("read"),
|
|
37798
|
+
bases_absent: count("absent"),
|
|
37799
|
+
bases_unreadable: count("unreadable"),
|
|
37800
|
+
totals,
|
|
37801
|
+
next_after: nextAfter,
|
|
37802
|
+
bases
|
|
37803
|
+
};
|
|
37804
|
+
}
|
|
37805
|
+
var init_base_vault_dry_run = __esm({
|
|
37806
|
+
"src/lib/base-vault-dry-run.ts"() {
|
|
37807
|
+
"use strict";
|
|
37808
|
+
}
|
|
37809
|
+
});
|
|
37810
|
+
|
|
37700
37811
|
// src/commands/admin.ts
|
|
37701
37812
|
var admin_exports = {};
|
|
37702
37813
|
__export(admin_exports, {
|
|
@@ -37919,6 +38030,9 @@ async function adminCommand(args2) {
|
|
|
37919
38030
|
case "revert":
|
|
37920
38031
|
await runVaultRevert(flagArgs);
|
|
37921
38032
|
return;
|
|
38033
|
+
case "base-dry-run":
|
|
38034
|
+
await runVaultBaseDryRun(flagArgs);
|
|
38035
|
+
return;
|
|
37922
38036
|
default:
|
|
37923
38037
|
printHelp2();
|
|
37924
38038
|
process.exit(1);
|
|
@@ -38691,6 +38805,73 @@ async function runVaultImport(flagArgs) {
|
|
|
38691
38805
|
}
|
|
38692
38806
|
printVaultReport(data);
|
|
38693
38807
|
}
|
|
38808
|
+
async function runVaultBaseDryRun(flagArgs) {
|
|
38809
|
+
const USAGE8 = "wayai admin vault base-dry-run --org <org_id> [--base <base_id>] [--after <base_id>] [--json]";
|
|
38810
|
+
let orgId;
|
|
38811
|
+
let baseId;
|
|
38812
|
+
let after;
|
|
38813
|
+
let jsonOutput = false;
|
|
38814
|
+
for (let i = 0; i < flagArgs.length; i++) {
|
|
38815
|
+
const flag = flagArgs[i];
|
|
38816
|
+
if (flag === "--org") orgId = requireFlagValue(flagArgs, ++i, "--org");
|
|
38817
|
+
else if (flag === "--base") baseId = requireFlagValue(flagArgs, ++i, "--base");
|
|
38818
|
+
else if (flag === "--after") after = requireFlagValue(flagArgs, ++i, "--after");
|
|
38819
|
+
else if (flag === "--json") jsonOutput = true;
|
|
38820
|
+
else {
|
|
38821
|
+
console.error(`Unknown flag: ${flag}`);
|
|
38822
|
+
console.error(USAGE8);
|
|
38823
|
+
process.exit(1);
|
|
38824
|
+
}
|
|
38825
|
+
}
|
|
38826
|
+
const query = baseVaultDryRunQuery.safeParse({ org_id: orgId, base_id: baseId, after });
|
|
38827
|
+
if (!query.success) {
|
|
38828
|
+
console.error("--org must be an organization id, --base a base id, and --base and --after cannot be combined.");
|
|
38829
|
+
console.error(USAGE8);
|
|
38830
|
+
process.exit(1);
|
|
38831
|
+
}
|
|
38832
|
+
const { config, accessToken } = await requireAuth();
|
|
38833
|
+
const client = new ApiClient({ apiUrl: config.api_url, accessToken });
|
|
38834
|
+
const pages = [];
|
|
38835
|
+
let stop;
|
|
38836
|
+
let cursor = after;
|
|
38837
|
+
do {
|
|
38838
|
+
try {
|
|
38839
|
+
const { data } = await client.debugBaseVaultDryRun({ ...query.data, after: cursor });
|
|
38840
|
+
pages.push(data);
|
|
38841
|
+
cursor = data.next_after ?? void 0;
|
|
38842
|
+
} catch (err) {
|
|
38843
|
+
const limited = err instanceof ApiError && err.status === 429;
|
|
38844
|
+
if (pages.length === 0 && !limited) {
|
|
38845
|
+
exitOnApiError(err);
|
|
38846
|
+
throw err;
|
|
38847
|
+
}
|
|
38848
|
+
stop = limited ? "rate_limited" : "request_failed";
|
|
38849
|
+
break;
|
|
38850
|
+
}
|
|
38851
|
+
} while (cursor);
|
|
38852
|
+
const summary = summarizeBaseVaultDryRun({ orgId: query.data.org_id, pages, resumedAfter: after, stop });
|
|
38853
|
+
const gotItsBase = summary.bases_read === 1 && summary.incomplete_reasons.every((reason) => reason === "single_base");
|
|
38854
|
+
if (!summary.complete && !gotItsBase) process.exitCode = 1;
|
|
38855
|
+
if (jsonOutput) {
|
|
38856
|
+
console.log(JSON.stringify(summary, null, 2));
|
|
38857
|
+
return;
|
|
38858
|
+
}
|
|
38859
|
+
const notSeeded = summary.incomplete_reasons.includes("registry_not_seeded");
|
|
38860
|
+
console.log(`base vault dry run \u2014 org ${summary.org_id} \u2014 ${summary.complete ? "complete" : `INCOMPLETE, not the org's total (${summary.incomplete_reasons.join(", ")})`}`);
|
|
38861
|
+
console.log(`reads: ${summary.reads} of the 120/hour cap`);
|
|
38862
|
+
console.log(`bases: listed ${summary.bases_listed}, read ${summary.bases_read}, absent ${summary.bases_absent}, unreadable ${summary.bases_unreadable}`);
|
|
38863
|
+
if (notSeeded) console.log("This org's base registry has never been filled; listing its bases once fills it. Re-run after.");
|
|
38864
|
+
if (stop || summary.next_after) {
|
|
38865
|
+
console.log(summary.next_after ? `To continue: --after ${summary.next_after}` : "Nothing read past the start; re-run later.");
|
|
38866
|
+
}
|
|
38867
|
+
const nonZero = (value) => flattenCounts(value).filter((line) => !line.endsWith(": 0"));
|
|
38868
|
+
console.log("totals (non-zero):");
|
|
38869
|
+
for (const line of nonZero(summary.totals)) console.log(` ${line}`);
|
|
38870
|
+
for (const base of summary.bases) {
|
|
38871
|
+
console.log(`${base.base_id}: ${base.status === "unreadable" ? `unreadable (${base.reason})` : base.status}`);
|
|
38872
|
+
if (base.status === "read") for (const line of nonZero(base.report)) console.log(` ${line}`);
|
|
38873
|
+
}
|
|
38874
|
+
}
|
|
38694
38875
|
async function runVaultRevert(flagArgs) {
|
|
38695
38876
|
const USAGE8 = "wayai admin vault revert --org <org_id> --connector <connector_id> [--apply] [--yes] [--json]";
|
|
38696
38877
|
const { orgId, connectorId, apply, yes, jsonOutput } = parseVaultFlags(flagArgs, USAGE8, false);
|
|
@@ -39918,9 +40099,10 @@ Usage:
|
|
|
39918
40099
|
wayai admin do tables <type> <id>
|
|
39919
40100
|
wayai admin do read <type> <id> <table> [--limit N] [--id X] [--json]
|
|
39920
40101
|
wayai admin do counts <hub|org> <id> [--json] Numbers, no text: a hub's toolset connections, knowledge placeholders per stored
|
|
39921
|
-
text, summary and kanban context schemas' verdicts, secret columns' shapes
|
|
39922
|
-
(production) publish state
|
|
39923
|
-
|
|
40102
|
+
text, summary and kanban context schemas' verdicts, secret columns' shapes,
|
|
40103
|
+
(production) publish state and stored_credentials, its values still needing
|
|
40104
|
+
MASTER_KEY or held by the vault, per store; an org's
|
|
40105
|
+
skills, hub links, moved-knowledge registry, credentials' shapes and stored_credentials
|
|
39924
40106
|
|
|
39925
40107
|
wayai admin analytics tables
|
|
39926
40108
|
wayai admin analytics read <table> [--conversation-id X] [--hub-id Y] [--message-id Z] [--limit N] [--json]
|
|
@@ -40007,6 +40189,9 @@ Usage:
|
|
|
40007
40189
|
wayai admin guide clear [--json] Turn the Guide off: nobody new is enrolled and the help entry is hidden
|
|
40008
40190
|
wayai admin guide status [--json] Print which hub is the Guide, and its facts
|
|
40009
40191
|
|
|
40192
|
+
wayai admin vault base-dry-run --org <org_id> [--base <base_id>] [--after <base_id>] [--json]
|
|
40193
|
+
What moving an org's base secrets to the vault would do: counts and reason codes per base, and the sum over the bases read. Reads only. One read per 50 bases (or one for --base), one sleeping base woken per base read: by hand, never scheduled. Marks and exits non-zero on any partial result (a base unreadable, the budget hit, a resumed run)
|
|
40194
|
+
|
|
40010
40195
|
wayai admin vault-gate status [--json] Print the connectors whose new credentials go to the credentials vault
|
|
40011
40196
|
wayai admin vault-gate add <connector> [--yes] [--json]
|
|
40012
40197
|
List a connector: a vault connector's name (e.g. telegram, whatsapp, instagram, or openai for its LLM, STT and TTS ids, never GPT-Live's) or one catalog id (GPT-Live's only so); prints before and after, confirms unless --yes
|
|
@@ -40169,6 +40354,8 @@ var init_admin = __esm({
|
|
|
40169
40354
|
init_file_map();
|
|
40170
40355
|
init_errors3();
|
|
40171
40356
|
init_contracts();
|
|
40357
|
+
init_vault_import();
|
|
40358
|
+
init_base_vault_dry_run();
|
|
40172
40359
|
VALID_TYPES = dataExplorerDebugDoType.options;
|
|
40173
40360
|
VALID_ANALYTICS_TABLES = dataExplorerDebugAnalyticsTable.options;
|
|
40174
40361
|
HARNESS_GATE = {
|