@wayai/cli 0.3.322 → 0.3.324
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 +653 -655
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -5509,171 +5509,64 @@ var init_chunk_MF2VVXBR = __esm({
|
|
|
5509
5509
|
}
|
|
5510
5510
|
});
|
|
5511
5511
|
|
|
5512
|
-
// ../../packages/core/dist/chunk-
|
|
5513
|
-
var
|
|
5514
|
-
var
|
|
5515
|
-
"../../packages/core/dist/chunk-
|
|
5516
|
-
"use strict";
|
|
5517
|
-
init_chunk_MF2VVXBR();
|
|
5518
|
-
init_chunk_HZ6CADSY();
|
|
5519
|
-
init_zod();
|
|
5520
|
-
connectionIdParam = external_exports.object({ id: uuidSchema });
|
|
5521
|
-
connectorIdParam = external_exports.object({ id: uuidSchema });
|
|
5522
|
-
listConnectionsQuery = external_exports.object({ hub_id: uuidSchema });
|
|
5523
|
-
deleteConnectionQuery = external_exports.object({ hub_id: uuidSchema });
|
|
5524
|
-
addConnectionBody = external_exports.object({
|
|
5525
|
-
hub_id: uuidSchema,
|
|
5526
|
-
connector_id: uuidSchema,
|
|
5527
|
-
authentication_type: external_exports.string().optional(),
|
|
5528
|
-
inbound_mode: external_exports.enum(["wayai", "resend"]).optional(),
|
|
5529
|
-
inbound_address: external_exports.string().email().optional(),
|
|
5530
|
-
// Opt out of copying this connection's credentials into production on publish/sync.
|
|
5531
|
-
// Defaults to true at the DB layer.
|
|
5532
|
-
sync_credentials_to_production: external_exports.boolean().optional(),
|
|
5533
|
-
// When the connection's own secret expires; null for none (`credential-expiry.ts`).
|
|
5534
|
-
expires_at: credentialExpiresAtSchema.optional()
|
|
5535
|
-
}).passthrough().superRefine((data, ctx) => {
|
|
5536
|
-
if (data.inbound_mode === "resend" && !data.inbound_address) {
|
|
5537
|
-
ctx.addIssue({
|
|
5538
|
-
code: external_exports.ZodIssueCode.custom,
|
|
5539
|
-
message: "Receiving email address is required when using Resend inbound mode",
|
|
5540
|
-
path: ["inbound_address"]
|
|
5541
|
-
});
|
|
5542
|
-
}
|
|
5543
|
-
});
|
|
5544
|
-
editConnectionBody = external_exports.object({
|
|
5545
|
-
hub_id: uuidSchema,
|
|
5546
|
-
sync_credentials_to_production: external_exports.boolean().optional(),
|
|
5547
|
-
expires_at: credentialExpiresAtSchema.optional()
|
|
5548
|
-
}).passthrough();
|
|
5549
|
-
PRODUCTION_DIRECT_FIELDS = ["username", "api_key", "access_token", "password", "refresh_token", "webhook_secret_token", "webhook_signing_secret", "github_app_id", "github_app_private_key"];
|
|
5550
|
-
BESIDE_LINK_FIELDS = /* @__PURE__ */ new Set(["webhook_secret_token", "github_app_id", "github_app_private_key"]);
|
|
5551
|
-
setProductionCredentialBody = external_exports.object({
|
|
5552
|
-
hub_id: uuidSchema,
|
|
5553
|
-
organization_credential_id: external_exports.string().nullable().optional(),
|
|
5554
|
-
organization_credential_token_id: external_exports.string().nullable().optional(),
|
|
5555
|
-
username: external_exports.string().optional(),
|
|
5556
|
-
api_key: external_exports.string().optional(),
|
|
5557
|
-
access_token: external_exports.string().optional(),
|
|
5558
|
-
password: external_exports.string().optional(),
|
|
5559
|
-
refresh_token: external_exports.string().optional(),
|
|
5560
|
-
webhook_secret_token: external_exports.string().optional(),
|
|
5561
|
-
webhook_signing_secret: external_exports.string().optional(),
|
|
5562
|
-
github_app_id: external_exports.string().optional(),
|
|
5563
|
-
github_app_private_key: external_exports.string().optional(),
|
|
5564
|
-
expires_at: credentialExpiresAtSchema.optional()
|
|
5565
|
-
}).strict().superRefine((data, ctx) => {
|
|
5566
|
-
const hasOrgLink = !!data.organization_credential_id || !!data.organization_credential_token_id;
|
|
5567
|
-
const sets = (f) => data[f] != null && data[f] !== `__USE_EXISTING_${f.toUpperCase()}__`;
|
|
5568
|
-
const hasDirect = PRODUCTION_DIRECT_FIELDS.some(sets);
|
|
5569
|
-
const hasDirectBesideLink = PRODUCTION_DIRECT_FIELDS.some((f) => !BESIDE_LINK_FIELDS.has(f) && sets(f));
|
|
5570
|
-
if (hasOrgLink && hasDirectBesideLink) {
|
|
5571
|
-
ctx.addIssue({ code: external_exports.ZodIssueCode.custom, message: "Provide either an organization credential link or direct credential fields, not both" });
|
|
5572
|
-
}
|
|
5573
|
-
if (hasOrgLink && data.expires_at != null) {
|
|
5574
|
-
ctx.addIssue({ code: external_exports.ZodIssueCode.custom, message: LINKED_EXPIRY_REFUSAL, path: ["expires_at"] });
|
|
5575
|
-
}
|
|
5576
|
-
if (!hasOrgLink && !hasDirect && data.expires_at === void 0) {
|
|
5577
|
-
ctx.addIssue({ code: external_exports.ZodIssueCode.custom, message: "A credential is required: link an organization credential or provide a credential field" });
|
|
5578
|
-
}
|
|
5579
|
-
});
|
|
5580
|
-
registerWhatsappQuery = external_exports.object({ hub_id: uuidSchema });
|
|
5581
|
-
registerWhatsappBody = external_exports.object({
|
|
5582
|
-
pin: external_exports.string().optional()
|
|
5583
|
-
});
|
|
5584
|
-
retryProvisioningQuery = external_exports.object({ hub_id: uuidSchema });
|
|
5585
|
-
resendDomainStatusQuery = external_exports.object({ hub_id: uuidSchema });
|
|
5586
|
-
}
|
|
5587
|
-
});
|
|
5588
|
-
|
|
5589
|
-
// ../../packages/core/dist/chunk-IPXBFWUU.js
|
|
5590
|
-
var variantAiModeSchema, experimentStatusSchema, overlayUpdateSchema, experimentIdParam, variantIdParam, listExperimentsQuery, listVariantsQuery, listOverridesQuery, deleteOverrideQuery, createExperimentBody, updateExperimentBody, setExperimentStatusBody, createVariantBody, updateVariantBody, upsertOverrideBody;
|
|
5591
|
-
var init_chunk_IPXBFWUU = __esm({
|
|
5592
|
-
"../../packages/core/dist/chunk-IPXBFWUU.js"() {
|
|
5512
|
+
// ../../packages/core/dist/chunk-LHTWT6HS.js
|
|
5513
|
+
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, REKOR_S3_CREDENTIAL_COUNT_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_BOUND_CAPABILITY_HEADER, REKOR_BOUND_CAPABILITY_SEED, 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;
|
|
5514
|
+
var init_chunk_LHTWT6HS = __esm({
|
|
5515
|
+
"../../packages/core/dist/chunk-LHTWT6HS.js"() {
|
|
5593
5516
|
"use strict";
|
|
5594
|
-
init_chunk_6TSQ5HXC();
|
|
5595
5517
|
init_zod();
|
|
5596
|
-
|
|
5597
|
-
|
|
5598
|
-
|
|
5599
|
-
|
|
5600
|
-
|
|
5601
|
-
|
|
5602
|
-
|
|
5603
|
-
|
|
5604
|
-
|
|
5605
|
-
|
|
5606
|
-
|
|
5607
|
-
|
|
5608
|
-
|
|
5609
|
-
|
|
5610
|
-
|
|
5611
|
-
|
|
5612
|
-
|
|
5613
|
-
|
|
5614
|
-
|
|
5615
|
-
});
|
|
5616
|
-
deleteOverrideQuery = external_exports.object({
|
|
5617
|
-
hub_id: external_exports.string().uuid(),
|
|
5618
|
-
variant_id: external_exports.string().uuid(),
|
|
5619
|
-
agent_id: external_exports.string().uuid()
|
|
5620
|
-
});
|
|
5621
|
-
createExperimentBody = external_exports.object({
|
|
5622
|
-
hub_id: external_exports.string().uuid(),
|
|
5623
|
-
experiment_slug: slugSchema.optional(),
|
|
5624
|
-
experiment_name: external_exports.string().min(1, "experiment_name is required").max(100, "experiment_name must be 100 characters or fewer"),
|
|
5625
|
-
primary_metric: external_exports.string().max(200).nullish(),
|
|
5626
|
-
status: experimentStatusSchema.default("draft")
|
|
5627
|
-
});
|
|
5628
|
-
updateExperimentBody = external_exports.object({
|
|
5629
|
-
// experiment_slug is immutable after first persist — not accepted here.
|
|
5630
|
-
experiment_name: external_exports.string().min(1).max(100).optional(),
|
|
5631
|
-
primary_metric: external_exports.string().max(200).nullish(),
|
|
5632
|
-
control_variant_id: external_exports.string().uuid().nullish()
|
|
5633
|
-
});
|
|
5634
|
-
setExperimentStatusBody = external_exports.object({
|
|
5635
|
-
status: experimentStatusSchema
|
|
5636
|
-
});
|
|
5637
|
-
createVariantBody = external_exports.object({
|
|
5638
|
-
hub_id: external_exports.string().uuid(),
|
|
5639
|
-
experiment_id: external_exports.string().uuid(),
|
|
5640
|
-
label: external_exports.string().min(1, "label is required").max(100, "label must be 100 characters or fewer"),
|
|
5641
|
-
weight: external_exports.number().positive().default(1),
|
|
5642
|
-
ai_mode: variantAiModeSchema.nullish(),
|
|
5643
|
-
is_control: external_exports.boolean().default(false)
|
|
5644
|
-
});
|
|
5645
|
-
updateVariantBody = external_exports.object({
|
|
5646
|
-
label: external_exports.string().min(1).max(100).optional(),
|
|
5647
|
-
weight: external_exports.number().positive().optional(),
|
|
5648
|
-
ai_mode: variantAiModeSchema.nullish(),
|
|
5649
|
-
is_control: external_exports.boolean().optional()
|
|
5518
|
+
REKOR_ACTOR_TYPE_HEADER = "X-Rekor-Actor-Type";
|
|
5519
|
+
REKOR_ACTOR_ID_HEADER = "X-Rekor-Actor-Id";
|
|
5520
|
+
REKOR_ACTOR_LABEL_HEADER = "X-Rekor-Actor-Label";
|
|
5521
|
+
REKOR_ACTOR_ORG_HEADER = "X-Rekor-Actor-Org";
|
|
5522
|
+
REKOR_ACTOR_ADMIN_HEADER = "X-Rekor-Actor-Admin";
|
|
5523
|
+
REKOR_CLIENT_HEADER = "X-Rekor-Client";
|
|
5524
|
+
REKOR_TOOL_ID_HEADER = "X-Rekor-Tool-Id";
|
|
5525
|
+
REKOR_CLIENTS = ["api", "cli", "mcp"];
|
|
5526
|
+
rekorClientSchema = external_exports.enum(REKOR_CLIENTS);
|
|
5527
|
+
MAX_REKOR_TOOL_ID_LENGTH = 128;
|
|
5528
|
+
rekorToolIdSchema = external_exports.string().trim().min(1).max(MAX_REKOR_TOOL_ID_LENGTH);
|
|
5529
|
+
REKOR_V1_PREFIX = "/v1";
|
|
5530
|
+
REKOR_LIFECYCLE_PREFIX = "/lifecycle";
|
|
5531
|
+
REKOR_BASE_VAULT_DRY_RUN_PATH = `${REKOR_LIFECYCLE_PREFIX}/vault-dry-run`;
|
|
5532
|
+
REKOR_S3_CREDENTIAL_COUNT_PATH = `${REKOR_LIFECYCLE_PREFIX}/s3-credential-count`;
|
|
5533
|
+
DATA_PROXY_ORG_QUERY_PARAM = "org_id";
|
|
5534
|
+
MAX_PROVISIONING_BODY_BYTES = 256 * 1024;
|
|
5535
|
+
dataProxyQuery = external_exports.object({
|
|
5536
|
+
[DATA_PROXY_ORG_QUERY_PARAM]: external_exports.string().uuid().optional()
|
|
5650
5537
|
});
|
|
5651
|
-
|
|
5652
|
-
|
|
5653
|
-
|
|
5654
|
-
|
|
5655
|
-
|
|
5656
|
-
|
|
5657
|
-
|
|
5658
|
-
|
|
5538
|
+
rekorAttestation = external_exports.object({
|
|
5539
|
+
[REKOR_ACTOR_TYPE_HEADER]: external_exports.enum(["user", "token"]),
|
|
5540
|
+
[REKOR_ACTOR_ID_HEADER]: external_exports.string().min(1),
|
|
5541
|
+
[REKOR_ACTOR_LABEL_HEADER]: external_exports.string(),
|
|
5542
|
+
[REKOR_ACTOR_ORG_HEADER]: external_exports.string().uuid(),
|
|
5543
|
+
[REKOR_ACTOR_ADMIN_HEADER]: external_exports.enum(["0", "1"]),
|
|
5544
|
+
[REKOR_CLIENT_HEADER]: rekorClientSchema,
|
|
5545
|
+
[REKOR_TOOL_ID_HEADER]: rekorToolIdSchema.optional()
|
|
5659
5546
|
});
|
|
5660
|
-
|
|
5661
|
-
|
|
5662
|
-
|
|
5663
|
-
|
|
5664
|
-
|
|
5665
|
-
|
|
5666
|
-
|
|
5667
|
-
|
|
5668
|
-
|
|
5669
|
-
|
|
5670
|
-
|
|
5671
|
-
|
|
5672
|
-
|
|
5673
|
-
|
|
5674
|
-
|
|
5675
|
-
|
|
5676
|
-
|
|
5547
|
+
REQUIRED_REKOR_ATTESTATION_HEADERS = Object.entries(rekorAttestation.shape).filter(([, field]) => !field.isOptional()).map(([header]) => header);
|
|
5548
|
+
REKOR_BOUND_BASE_HEADER = "X-Rekor-Bound-Base";
|
|
5549
|
+
REKOR_BOUND_TOOLSET_HEADER = "X-Rekor-Bound-Toolset";
|
|
5550
|
+
REKOR_BOUND_TOKEN_HEADER = "X-Rekor-Bound-Token";
|
|
5551
|
+
REKOR_BOUND_ACCESS_HEADER = "X-Rekor-Bound-Access";
|
|
5552
|
+
REKOR_BOUND_PAGE_HEADER = "X-Rekor-Bound-Page";
|
|
5553
|
+
REKOR_BOUND_PERSON_HEADER = "X-Rekor-Bound-Person";
|
|
5554
|
+
REKOR_BOUND_CAPABILITY_HEADER = "X-Rekor-Bound-Capability";
|
|
5555
|
+
REKOR_BOUND_CAPABILITY_SEED = "seed";
|
|
5556
|
+
REKOR_PERSON_AUDIENCE_STAFF = "staff";
|
|
5557
|
+
REKOR_PERSON_AUDIENCE_CUSTOMER = "customer";
|
|
5558
|
+
REKOR_PERSON_ALL = "*";
|
|
5559
|
+
DATA_BASE_GENERATION_HEADER = "X-Data-Base-Generation";
|
|
5560
|
+
REKOR_MAX_ACTOR_ID_LENGTH = 256;
|
|
5561
|
+
REKOR_MAX_ACTOR_LABEL_LENGTH = 256;
|
|
5562
|
+
REKOR_MAX_ACCESS_DIMENSIONS = 8;
|
|
5563
|
+
REKOR_MAX_ACCESS_VALUES = 100;
|
|
5564
|
+
REKOR_MAX_ACCESS_ID_LENGTH = 32;
|
|
5565
|
+
REKOR_MAX_ACCESS_HEADER_LENGTH = 65536;
|
|
5566
|
+
REKOR_MAX_PERSON_PARTIES = 16;
|
|
5567
|
+
REKOR_MAX_PERSON_IDS = 16;
|
|
5568
|
+
REKOR_MAX_PERSON_ID_LENGTH = 64;
|
|
5569
|
+
REKOR_MAX_PERSON_HEADER_LENGTH = 32768;
|
|
5677
5570
|
}
|
|
5678
5571
|
});
|
|
5679
5572
|
|
|
@@ -5756,313 +5649,6 @@ var init_chunk_ZTNFLGW5 = __esm({
|
|
|
5756
5649
|
}
|
|
5757
5650
|
});
|
|
5758
5651
|
|
|
5759
|
-
// ../../packages/core/dist/chunk-DSKOMKRY.js
|
|
5760
|
-
var orgCredentialIdParam, listOrgCredentialsQuery, ORG_CREDENTIAL_SERVICE_REQUIRED, createOrgCredentialBody, updateOrgCredentialBody;
|
|
5761
|
-
var init_chunk_DSKOMKRY = __esm({
|
|
5762
|
-
"../../packages/core/dist/chunk-DSKOMKRY.js"() {
|
|
5763
|
-
"use strict";
|
|
5764
|
-
init_chunk_MF2VVXBR();
|
|
5765
|
-
init_chunk_ZTNFLGW5();
|
|
5766
|
-
init_zod();
|
|
5767
|
-
orgCredentialIdParam = external_exports.object({
|
|
5768
|
-
id: external_exports.string().uuid()
|
|
5769
|
-
});
|
|
5770
|
-
listOrgCredentialsQuery = external_exports.object({
|
|
5771
|
-
organization_id: external_exports.string().uuid(),
|
|
5772
|
-
hub_id: external_exports.string().uuid().optional()
|
|
5773
|
-
});
|
|
5774
|
-
ORG_CREDENTIAL_SERVICE_REQUIRED = "An organization credential must name the service it is for (connector_id): pick its Service in the console, or run `wayai create-credential --service <name>`, updating the WayAI CLI first if it has no --service. Nothing was created.";
|
|
5775
|
-
createOrgCredentialBody = external_exports.object({
|
|
5776
|
-
organization_id: external_exports.string().uuid(),
|
|
5777
|
-
credential_display_name: external_exports.string().min(1).max(255),
|
|
5778
|
-
credential_description: external_exports.string().max(1e3).nullish(),
|
|
5779
|
-
authentication_type: external_exports.enum(["api_key", "bearer", "basic_auth"]).or(
|
|
5780
|
-
external_exports.enum(["API Key", "Bearer Token", "Basic Auth"]).transform((v) => normalizeAuthType(v))
|
|
5781
|
-
),
|
|
5782
|
-
api_key: external_exports.string().optional(),
|
|
5783
|
-
access_token: external_exports.string().optional(),
|
|
5784
|
-
username: external_exports.string().optional(),
|
|
5785
|
-
password: external_exports.string().optional(),
|
|
5786
|
-
tags: external_exports.array(external_exports.string().uuid()).optional(),
|
|
5787
|
-
environment: external_exports.enum(["preview", "production", "all"]).optional(),
|
|
5788
|
-
expires_at: credentialExpiresAtSchema.optional(),
|
|
5789
|
-
/**
|
|
5790
|
-
* The service the credential is for: a catalog `connector_id` (wayai#5644). Required (owner decision Q2): its value goes
|
|
5791
|
-
* to the credentials vault under that connector, and a credential naming none had nowhere there to go. It links only to
|
|
5792
|
-
* connections of that service, and is fixed for the credential's life. A connector whose host the customer types (REST
|
|
5793
|
-
* API, External Resources, MCP Server) is refused: its value is entered on the connection. A client that sends none (a
|
|
5794
|
-
* CLI from before `--service`) is refused with {@link ORG_CREDENTIAL_SERVICE_REQUIRED}.
|
|
5795
|
-
*/
|
|
5796
|
-
connector_id: external_exports.string({ required_error: ORG_CREDENTIAL_SERVICE_REQUIRED }).uuid()
|
|
5797
|
-
});
|
|
5798
|
-
updateOrgCredentialBody = external_exports.object({
|
|
5799
|
-
credential_display_name: external_exports.string().min(1).max(255).optional(),
|
|
5800
|
-
credential_description: external_exports.string().max(1e3).nullish(),
|
|
5801
|
-
api_key: external_exports.string().optional(),
|
|
5802
|
-
access_token: external_exports.string().optional(),
|
|
5803
|
-
username: external_exports.string().optional(),
|
|
5804
|
-
password: external_exports.string().optional(),
|
|
5805
|
-
tags: external_exports.array(external_exports.string().uuid()).optional(),
|
|
5806
|
-
environment: external_exports.enum(["preview", "production", "all"]).optional(),
|
|
5807
|
-
// Absent keeps the stored date, unless the request stores a new secret, which clears it.
|
|
5808
|
-
expires_at: credentialExpiresAtSchema.optional()
|
|
5809
|
-
});
|
|
5810
|
-
}
|
|
5811
|
-
});
|
|
5812
|
-
|
|
5813
|
-
// ../../packages/core/dist/chunk-HIGKBEPF.js
|
|
5814
|
-
var accessExplainQuery;
|
|
5815
|
-
var init_chunk_HIGKBEPF = __esm({
|
|
5816
|
-
"../../packages/core/dist/chunk-HIGKBEPF.js"() {
|
|
5817
|
-
"use strict";
|
|
5818
|
-
init_chunk_HZ6CADSY();
|
|
5819
|
-
init_zod();
|
|
5820
|
-
accessExplainQuery = external_exports.object({
|
|
5821
|
-
user_id: external_exports.string().regex(USER_ID_REGEX).optional()
|
|
5822
|
-
});
|
|
5823
|
-
}
|
|
5824
|
-
});
|
|
5825
|
-
|
|
5826
|
-
// ../../packages/core/dist/chunk-KEN2DASI.js
|
|
5827
|
-
var SECOND_FACTOR_TIERS, secondFactorTier, META_ENTITY_ID_PATTERN, metaEntityId, whatsappCallbackBody, authMeResponse, wsTicketResponse, sessionCheckResponse, logoutResponse, magicCodeSendBody, magicCodeSendResponse, magicCodeVerifyBody, magicCodeVerifyResponse, passwordLoginBody, normalizeEmail, REVIEW_ACCOUNT_EMAILS;
|
|
5828
|
-
var init_chunk_KEN2DASI = __esm({
|
|
5829
|
-
"../../packages/core/dist/chunk-KEN2DASI.js"() {
|
|
5830
|
-
"use strict";
|
|
5831
|
-
init_zod();
|
|
5832
|
-
SECOND_FACTOR_TIERS = ["off", "settings"];
|
|
5833
|
-
secondFactorTier = external_exports.enum(SECOND_FACTOR_TIERS);
|
|
5834
|
-
META_ENTITY_ID_PATTERN = /^\d{1,32}$/;
|
|
5835
|
-
metaEntityId = external_exports.string().regex(META_ENTITY_ID_PATTERN, "must be a numeric Meta entity id");
|
|
5836
|
-
whatsappCallbackBody = external_exports.object({
|
|
5837
|
-
state: external_exports.string().min(1, "state is required"),
|
|
5838
|
-
code: external_exports.string().optional(),
|
|
5839
|
-
access_token: external_exports.string().optional(),
|
|
5840
|
-
user_id: external_exports.string().optional(),
|
|
5841
|
-
/**
|
|
5842
|
-
* The phone number and WABA the operator actually picked in Meta's Embedded
|
|
5843
|
-
* Signup popup (posted to the opener as `WA_EMBEDDED_SIGNUP`). Optional:
|
|
5844
|
-
* older clients, and the redirect-based flow, never see that event and fall
|
|
5845
|
-
* back to discovery.
|
|
5846
|
-
*/
|
|
5847
|
-
phone_number_id: metaEntityId.optional(),
|
|
5848
|
-
waba_id: metaEntityId.optional()
|
|
5849
|
-
}).refine(
|
|
5850
|
-
(data) => !!data.access_token || !!data.code,
|
|
5851
|
-
{ message: "Missing required parameters: state and either access_token or code" }
|
|
5852
|
-
);
|
|
5853
|
-
authMeResponse = external_exports.object({
|
|
5854
|
-
user_id: external_exports.string(),
|
|
5855
|
-
email: external_exports.string(),
|
|
5856
|
-
org_id: external_exports.string().nullable(),
|
|
5857
|
-
is_platform_admin: external_exports.boolean()
|
|
5858
|
-
});
|
|
5859
|
-
wsTicketResponse = external_exports.object({
|
|
5860
|
-
ticket: external_exports.string(),
|
|
5861
|
-
/** Seconds until the ticket expires if unconsumed. */
|
|
5862
|
-
expires_in: external_exports.number()
|
|
5863
|
-
});
|
|
5864
|
-
sessionCheckResponse = external_exports.object({
|
|
5865
|
-
valid: external_exports.literal(true)
|
|
5866
|
-
});
|
|
5867
|
-
logoutResponse = external_exports.object({
|
|
5868
|
-
success: external_exports.literal(true)
|
|
5869
|
-
});
|
|
5870
|
-
magicCodeSendBody = external_exports.object({
|
|
5871
|
-
email: external_exports.string().email("Invalid email").max(254)
|
|
5872
|
-
// RFC 5321 max; bounds the request payload
|
|
5873
|
-
});
|
|
5874
|
-
magicCodeSendResponse = external_exports.object({
|
|
5875
|
-
success: external_exports.literal(true)
|
|
5876
|
-
});
|
|
5877
|
-
magicCodeVerifyBody = external_exports.object({
|
|
5878
|
-
email: external_exports.string().email("Invalid email").max(254),
|
|
5879
|
-
// RFC 5321 max; bounds the request payload
|
|
5880
|
-
code: external_exports.string().min(1, "Code is required").max(12)
|
|
5881
|
-
// WorkOS sends a 6-digit code; bound the input
|
|
5882
|
-
});
|
|
5883
|
-
magicCodeVerifyResponse = external_exports.object({
|
|
5884
|
-
access_token: external_exports.string(),
|
|
5885
|
-
refresh_token: external_exports.string()
|
|
5886
|
-
});
|
|
5887
|
-
passwordLoginBody = external_exports.object({
|
|
5888
|
-
email: external_exports.string().email("Invalid email").max(254),
|
|
5889
|
-
// RFC 5321 max; bounds the request payload
|
|
5890
|
-
password: external_exports.string().min(1, "Password is required").max(128)
|
|
5891
|
-
// bound the payload; WorkOS validates
|
|
5892
|
-
});
|
|
5893
|
-
normalizeEmail = (email) => email.trim().toLowerCase();
|
|
5894
|
-
REVIEW_ACCOUNT_EMAILS = new Set(
|
|
5895
|
-
["apple.review@wayai.pro", "play.review@wayai.pro", "microsoft.review@wayai.pro", "meta.review@wayai.pro"].map(
|
|
5896
|
-
normalizeEmail
|
|
5897
|
-
)
|
|
5898
|
-
);
|
|
5899
|
-
}
|
|
5900
|
-
});
|
|
5901
|
-
|
|
5902
|
-
// ../../packages/core/dist/chunk-PFGVH2CX.js
|
|
5903
|
-
var secondFactorCode, secondFactorRecoveryCode, secondFactorCodeBody, secondFactorRecoveryBody, secondFactorDisableBody, setOrgSecondFactorBody;
|
|
5904
|
-
var init_chunk_PFGVH2CX = __esm({
|
|
5905
|
-
"../../packages/core/dist/chunk-PFGVH2CX.js"() {
|
|
5906
|
-
"use strict";
|
|
5907
|
-
init_chunk_KEN2DASI();
|
|
5908
|
-
init_zod();
|
|
5909
|
-
secondFactorCode = external_exports.string().regex(/^\d{6}$/, "Enter the 6-digit code");
|
|
5910
|
-
secondFactorRecoveryCode = external_exports.string().min(1, "Enter a recovery code").max(64);
|
|
5911
|
-
secondFactorCodeBody = external_exports.object({ code: secondFactorCode });
|
|
5912
|
-
secondFactorRecoveryBody = external_exports.object({ recovery_code: secondFactorRecoveryCode });
|
|
5913
|
-
secondFactorDisableBody = external_exports.union([
|
|
5914
|
-
external_exports.object({ code: secondFactorCode, recovery_code: external_exports.undefined().optional() }),
|
|
5915
|
-
external_exports.object({ recovery_code: secondFactorRecoveryCode, code: external_exports.undefined().optional() })
|
|
5916
|
-
]);
|
|
5917
|
-
setOrgSecondFactorBody = external_exports.object({ tier: secondFactorTier });
|
|
5918
|
-
}
|
|
5919
|
-
});
|
|
5920
|
-
|
|
5921
|
-
// ../../packages/core/dist/chunk-WE4KMHZK.js
|
|
5922
|
-
var bootstrapQuery;
|
|
5923
|
-
var init_chunk_WE4KMHZK = __esm({
|
|
5924
|
-
"../../packages/core/dist/chunk-WE4KMHZK.js"() {
|
|
5925
|
-
"use strict";
|
|
5926
|
-
init_zod();
|
|
5927
|
-
bootstrapQuery = external_exports.object({
|
|
5928
|
-
active_hub_id: external_exports.string().uuid().optional(),
|
|
5929
|
-
active_conversation_id: external_exports.string().uuid().optional(),
|
|
5930
|
-
active_nav: external_exports.enum(["chat", "task", "support"]).optional(),
|
|
5931
|
-
/**
|
|
5932
|
-
* The people thread the URL names (`/chat/threads/:threadId`, gh #4661): the snapshot
|
|
5933
|
-
* preloads it as `people.active_thread` when the viewer is a member.
|
|
5934
|
-
*/
|
|
5935
|
-
active_thread_id: external_exports.string().uuid().optional()
|
|
5936
|
-
});
|
|
5937
|
-
}
|
|
5938
|
-
});
|
|
5939
|
-
|
|
5940
|
-
// ../../packages/core/dist/chunk-SCC6AVLY.js
|
|
5941
|
-
var PERMISSIONS;
|
|
5942
|
-
var init_chunk_SCC6AVLY = __esm({
|
|
5943
|
-
"../../packages/core/dist/chunk-SCC6AVLY.js"() {
|
|
5944
|
-
"use strict";
|
|
5945
|
-
PERMISSIONS = [
|
|
5946
|
-
"hub:read",
|
|
5947
|
-
"hub:write",
|
|
5948
|
-
"hub:admin",
|
|
5949
|
-
"conversation:read",
|
|
5950
|
-
"conversation:write",
|
|
5951
|
-
"analytics:read",
|
|
5952
|
-
"billing:read",
|
|
5953
|
-
"billing:write",
|
|
5954
|
-
"org:read",
|
|
5955
|
-
"org:write",
|
|
5956
|
-
"org:admin",
|
|
5957
|
-
"contacts:write",
|
|
5958
|
-
"platform:admin",
|
|
5959
|
-
"*"
|
|
5960
|
-
];
|
|
5961
|
-
}
|
|
5962
|
-
});
|
|
5963
|
-
|
|
5964
|
-
// ../../packages/core/dist/chunk-P5GJNS5R.js
|
|
5965
|
-
var MAX_NAME_LENGTH, MAX_HUBS_PER_GRANT, MAX_HUB_TAGS_PER_GRANT, MAX_GRANTS, permissionEnum, grantScopeSchema, grantSchema, createTokenBody, tokenOrgIdParam;
|
|
5966
|
-
var init_chunk_P5GJNS5R = __esm({
|
|
5967
|
-
"../../packages/core/dist/chunk-P5GJNS5R.js"() {
|
|
5968
|
-
"use strict";
|
|
5969
|
-
init_chunk_SCC6AVLY();
|
|
5970
|
-
init_chunk_HZ6CADSY();
|
|
5971
|
-
init_zod();
|
|
5972
|
-
MAX_NAME_LENGTH = 100;
|
|
5973
|
-
MAX_HUBS_PER_GRANT = 50;
|
|
5974
|
-
MAX_HUB_TAGS_PER_GRANT = 20;
|
|
5975
|
-
MAX_GRANTS = 20;
|
|
5976
|
-
permissionEnum = external_exports.enum(PERMISSIONS).refine(
|
|
5977
|
-
(p) => p !== "platform:admin",
|
|
5978
|
-
{ message: "platform:admin cannot be delegated via token creation" }
|
|
5979
|
-
);
|
|
5980
|
-
grantScopeSchema = external_exports.object({
|
|
5981
|
-
// Required: every token grant must declare its org tenancy. The handler
|
|
5982
|
-
// also strict-checks this as defense-in-depth, but failing at the Zod
|
|
5983
|
-
// boundary keeps the generated client type honest (org_id: string).
|
|
5984
|
-
org_id: external_exports.string().min(1),
|
|
5985
|
-
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),
|
|
5986
|
-
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(),
|
|
5987
|
-
environments: external_exports.array(external_exports.enum(["production", "preview"])).min(1, "scope.environments must be a non-empty array if provided").optional()
|
|
5988
|
-
}).strict();
|
|
5989
|
-
grantSchema = external_exports.object({
|
|
5990
|
-
scope: grantScopeSchema,
|
|
5991
|
-
permissions: external_exports.array(permissionEnum).min(1, "Each grant must have permissions as a non-empty array")
|
|
5992
|
-
}).strict();
|
|
5993
|
-
createTokenBody = external_exports.object({
|
|
5994
|
-
name: external_exports.string().trim().min(1, "name is required").max(MAX_NAME_LENGTH, `name must be ${MAX_NAME_LENGTH} characters or fewer`),
|
|
5995
|
-
grants: external_exports.array(grantSchema).min(1, "grants must be a non-empty array").max(MAX_GRANTS),
|
|
5996
|
-
expires_at: external_exports.string().datetime({ message: "expires_at must be a valid ISO 8601 date" }).refine(
|
|
5997
|
-
(s) => new Date(s).getTime() > Date.now(),
|
|
5998
|
-
{ message: "expires_at must be in the future" }
|
|
5999
|
-
).optional()
|
|
6000
|
-
});
|
|
6001
|
-
tokenOrgIdParam = external_exports.object({ orgId: uuidSchema });
|
|
6002
|
-
}
|
|
6003
|
-
});
|
|
6004
|
-
|
|
6005
|
-
// ../../packages/core/dist/chunk-LHTWT6HS.js
|
|
6006
|
-
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, REKOR_S3_CREDENTIAL_COUNT_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_BOUND_CAPABILITY_HEADER, REKOR_BOUND_CAPABILITY_SEED, 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;
|
|
6007
|
-
var init_chunk_LHTWT6HS = __esm({
|
|
6008
|
-
"../../packages/core/dist/chunk-LHTWT6HS.js"() {
|
|
6009
|
-
"use strict";
|
|
6010
|
-
init_zod();
|
|
6011
|
-
REKOR_ACTOR_TYPE_HEADER = "X-Rekor-Actor-Type";
|
|
6012
|
-
REKOR_ACTOR_ID_HEADER = "X-Rekor-Actor-Id";
|
|
6013
|
-
REKOR_ACTOR_LABEL_HEADER = "X-Rekor-Actor-Label";
|
|
6014
|
-
REKOR_ACTOR_ORG_HEADER = "X-Rekor-Actor-Org";
|
|
6015
|
-
REKOR_ACTOR_ADMIN_HEADER = "X-Rekor-Actor-Admin";
|
|
6016
|
-
REKOR_CLIENT_HEADER = "X-Rekor-Client";
|
|
6017
|
-
REKOR_TOOL_ID_HEADER = "X-Rekor-Tool-Id";
|
|
6018
|
-
REKOR_CLIENTS = ["api", "cli", "mcp"];
|
|
6019
|
-
rekorClientSchema = external_exports.enum(REKOR_CLIENTS);
|
|
6020
|
-
MAX_REKOR_TOOL_ID_LENGTH = 128;
|
|
6021
|
-
rekorToolIdSchema = external_exports.string().trim().min(1).max(MAX_REKOR_TOOL_ID_LENGTH);
|
|
6022
|
-
REKOR_V1_PREFIX = "/v1";
|
|
6023
|
-
REKOR_LIFECYCLE_PREFIX = "/lifecycle";
|
|
6024
|
-
REKOR_BASE_VAULT_DRY_RUN_PATH = `${REKOR_LIFECYCLE_PREFIX}/vault-dry-run`;
|
|
6025
|
-
REKOR_S3_CREDENTIAL_COUNT_PATH = `${REKOR_LIFECYCLE_PREFIX}/s3-credential-count`;
|
|
6026
|
-
DATA_PROXY_ORG_QUERY_PARAM = "org_id";
|
|
6027
|
-
MAX_PROVISIONING_BODY_BYTES = 256 * 1024;
|
|
6028
|
-
dataProxyQuery = external_exports.object({
|
|
6029
|
-
[DATA_PROXY_ORG_QUERY_PARAM]: external_exports.string().uuid().optional()
|
|
6030
|
-
});
|
|
6031
|
-
rekorAttestation = external_exports.object({
|
|
6032
|
-
[REKOR_ACTOR_TYPE_HEADER]: external_exports.enum(["user", "token"]),
|
|
6033
|
-
[REKOR_ACTOR_ID_HEADER]: external_exports.string().min(1),
|
|
6034
|
-
[REKOR_ACTOR_LABEL_HEADER]: external_exports.string(),
|
|
6035
|
-
[REKOR_ACTOR_ORG_HEADER]: external_exports.string().uuid(),
|
|
6036
|
-
[REKOR_ACTOR_ADMIN_HEADER]: external_exports.enum(["0", "1"]),
|
|
6037
|
-
[REKOR_CLIENT_HEADER]: rekorClientSchema,
|
|
6038
|
-
[REKOR_TOOL_ID_HEADER]: rekorToolIdSchema.optional()
|
|
6039
|
-
});
|
|
6040
|
-
REQUIRED_REKOR_ATTESTATION_HEADERS = Object.entries(rekorAttestation.shape).filter(([, field]) => !field.isOptional()).map(([header]) => header);
|
|
6041
|
-
REKOR_BOUND_BASE_HEADER = "X-Rekor-Bound-Base";
|
|
6042
|
-
REKOR_BOUND_TOOLSET_HEADER = "X-Rekor-Bound-Toolset";
|
|
6043
|
-
REKOR_BOUND_TOKEN_HEADER = "X-Rekor-Bound-Token";
|
|
6044
|
-
REKOR_BOUND_ACCESS_HEADER = "X-Rekor-Bound-Access";
|
|
6045
|
-
REKOR_BOUND_PAGE_HEADER = "X-Rekor-Bound-Page";
|
|
6046
|
-
REKOR_BOUND_PERSON_HEADER = "X-Rekor-Bound-Person";
|
|
6047
|
-
REKOR_BOUND_CAPABILITY_HEADER = "X-Rekor-Bound-Capability";
|
|
6048
|
-
REKOR_BOUND_CAPABILITY_SEED = "seed";
|
|
6049
|
-
REKOR_PERSON_AUDIENCE_STAFF = "staff";
|
|
6050
|
-
REKOR_PERSON_AUDIENCE_CUSTOMER = "customer";
|
|
6051
|
-
REKOR_PERSON_ALL = "*";
|
|
6052
|
-
DATA_BASE_GENERATION_HEADER = "X-Data-Base-Generation";
|
|
6053
|
-
REKOR_MAX_ACTOR_ID_LENGTH = 256;
|
|
6054
|
-
REKOR_MAX_ACTOR_LABEL_LENGTH = 256;
|
|
6055
|
-
REKOR_MAX_ACCESS_DIMENSIONS = 8;
|
|
6056
|
-
REKOR_MAX_ACCESS_VALUES = 100;
|
|
6057
|
-
REKOR_MAX_ACCESS_ID_LENGTH = 32;
|
|
6058
|
-
REKOR_MAX_ACCESS_HEADER_LENGTH = 65536;
|
|
6059
|
-
REKOR_MAX_PERSON_PARTIES = 16;
|
|
6060
|
-
REKOR_MAX_PERSON_IDS = 16;
|
|
6061
|
-
REKOR_MAX_PERSON_ID_LENGTH = 64;
|
|
6062
|
-
REKOR_MAX_PERSON_HEADER_LENGTH = 32768;
|
|
6063
|
-
}
|
|
6064
|
-
});
|
|
6065
|
-
|
|
6066
5652
|
// ../../packages/core/dist/chunk-2PQCTEDW.js
|
|
6067
5653
|
function isPersonAccessAll(lists) {
|
|
6068
5654
|
return lists !== void 0 && lists.read.length === 1 && lists.read[0] === ACCESS_UNRESTRICTED && lists.write.length === 1 && lists.write[0] === ACCESS_UNRESTRICTED;
|
|
@@ -6195,7 +5781,7 @@ var init_chunk_2PQCTEDW = __esm({
|
|
|
6195
5781
|
}
|
|
6196
5782
|
});
|
|
6197
5783
|
|
|
6198
|
-
// ../../packages/core/dist/chunk-
|
|
5784
|
+
// ../../packages/core/dist/chunk-HVCJ2WAL.js
|
|
6199
5785
|
function boundCustomerPartyIsValid(audience, parties, customer) {
|
|
6200
5786
|
return audience !== REKOR_PERSON_AUDIENCE_STAFF && customer < parties.length && Array.isArray(parties[customer]);
|
|
6201
5787
|
}
|
|
@@ -6209,8 +5795,8 @@ function isEncodedBoundPerson(raw) {
|
|
|
6209
5795
|
return rekorBoundPersonSchema.safeParse(parsed).success;
|
|
6210
5796
|
}
|
|
6211
5797
|
var TOOLSET_SLUG_PATTERN, REKOR_STRUCTURAL_ID_PATTERN, baseEnvironmentSchema, toolsetFileToolSchema, toolsetSurfaceSchema, toolsetConnectionBindingSchema, seedConnectionBindingSchema, rekorSeedBindingSchema, rekorToolsetToolsSchema, rekorPersonIdSchema, rekorPersonAudienceSchema, rekorBoundPersonSchema, STATED_GENERATION_PATTERN, rekorBoundAttestation, rekorSeedAttestation, 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;
|
|
6212
|
-
var
|
|
6213
|
-
"../../packages/core/dist/chunk-
|
|
5798
|
+
var init_chunk_HVCJ2WAL = __esm({
|
|
5799
|
+
"../../packages/core/dist/chunk-HVCJ2WAL.js"() {
|
|
6214
5800
|
"use strict";
|
|
6215
5801
|
init_chunk_2PQCTEDW();
|
|
6216
5802
|
init_chunk_LHTWT6HS();
|
|
@@ -6500,12 +6086,428 @@ var init_chunk_LM27W3HZ = __esm({
|
|
|
6500
6086
|
}
|
|
6501
6087
|
});
|
|
6502
6088
|
|
|
6503
|
-
// ../../packages/core/dist/chunk-
|
|
6089
|
+
// ../../packages/core/dist/chunk-6KMVY2W7.js
|
|
6090
|
+
var connectionIdParam, connectorIdParam, listConnectionsQuery, deleteConnectionQuery, addConnectionBody, editConnectionBody, PRODUCTION_DIRECT_FIELDS, BESIDE_LINK_FIELDS, setProductionCredentialBody, bindSeedConnectionBody, registerWhatsappQuery, registerWhatsappBody, retryProvisioningQuery, resendDomainStatusQuery;
|
|
6091
|
+
var init_chunk_6KMVY2W7 = __esm({
|
|
6092
|
+
"../../packages/core/dist/chunk-6KMVY2W7.js"() {
|
|
6093
|
+
"use strict";
|
|
6094
|
+
init_chunk_MF2VVXBR();
|
|
6095
|
+
init_chunk_HVCJ2WAL();
|
|
6096
|
+
init_chunk_HZ6CADSY();
|
|
6097
|
+
init_zod();
|
|
6098
|
+
connectionIdParam = external_exports.object({ id: uuidSchema });
|
|
6099
|
+
connectorIdParam = external_exports.object({ id: uuidSchema });
|
|
6100
|
+
listConnectionsQuery = external_exports.object({ hub_id: uuidSchema });
|
|
6101
|
+
deleteConnectionQuery = external_exports.object({ hub_id: uuidSchema });
|
|
6102
|
+
addConnectionBody = external_exports.object({
|
|
6103
|
+
hub_id: uuidSchema,
|
|
6104
|
+
connector_id: uuidSchema,
|
|
6105
|
+
authentication_type: external_exports.string().optional(),
|
|
6106
|
+
inbound_mode: external_exports.enum(["wayai", "resend"]).optional(),
|
|
6107
|
+
inbound_address: external_exports.string().email().optional(),
|
|
6108
|
+
// Opt out of copying this connection's credentials into production on publish/sync.
|
|
6109
|
+
// Defaults to true at the DB layer.
|
|
6110
|
+
sync_credentials_to_production: external_exports.boolean().optional(),
|
|
6111
|
+
// When the connection's own secret expires; null for none (`credential-expiry.ts`).
|
|
6112
|
+
expires_at: credentialExpiresAtSchema.optional()
|
|
6113
|
+
}).passthrough().superRefine((data, ctx) => {
|
|
6114
|
+
if (data.inbound_mode === "resend" && !data.inbound_address) {
|
|
6115
|
+
ctx.addIssue({
|
|
6116
|
+
code: external_exports.ZodIssueCode.custom,
|
|
6117
|
+
message: "Receiving email address is required when using Resend inbound mode",
|
|
6118
|
+
path: ["inbound_address"]
|
|
6119
|
+
});
|
|
6120
|
+
}
|
|
6121
|
+
});
|
|
6122
|
+
editConnectionBody = external_exports.object({
|
|
6123
|
+
hub_id: uuidSchema,
|
|
6124
|
+
sync_credentials_to_production: external_exports.boolean().optional(),
|
|
6125
|
+
expires_at: credentialExpiresAtSchema.optional()
|
|
6126
|
+
}).passthrough();
|
|
6127
|
+
PRODUCTION_DIRECT_FIELDS = ["username", "api_key", "access_token", "password", "refresh_token", "webhook_secret_token", "webhook_signing_secret", "github_app_id", "github_app_private_key"];
|
|
6128
|
+
BESIDE_LINK_FIELDS = /* @__PURE__ */ new Set(["webhook_secret_token", "github_app_id", "github_app_private_key"]);
|
|
6129
|
+
setProductionCredentialBody = external_exports.object({
|
|
6130
|
+
hub_id: uuidSchema,
|
|
6131
|
+
organization_credential_id: external_exports.string().nullable().optional(),
|
|
6132
|
+
organization_credential_token_id: external_exports.string().nullable().optional(),
|
|
6133
|
+
username: external_exports.string().optional(),
|
|
6134
|
+
api_key: external_exports.string().optional(),
|
|
6135
|
+
access_token: external_exports.string().optional(),
|
|
6136
|
+
password: external_exports.string().optional(),
|
|
6137
|
+
refresh_token: external_exports.string().optional(),
|
|
6138
|
+
webhook_secret_token: external_exports.string().optional(),
|
|
6139
|
+
webhook_signing_secret: external_exports.string().optional(),
|
|
6140
|
+
github_app_id: external_exports.string().optional(),
|
|
6141
|
+
github_app_private_key: external_exports.string().optional(),
|
|
6142
|
+
expires_at: credentialExpiresAtSchema.optional()
|
|
6143
|
+
}).strict().superRefine((data, ctx) => {
|
|
6144
|
+
const hasOrgLink = !!data.organization_credential_id || !!data.organization_credential_token_id;
|
|
6145
|
+
const sets = (f) => data[f] != null && data[f] !== `__USE_EXISTING_${f.toUpperCase()}__`;
|
|
6146
|
+
const hasDirect = PRODUCTION_DIRECT_FIELDS.some(sets);
|
|
6147
|
+
const hasDirectBesideLink = PRODUCTION_DIRECT_FIELDS.some((f) => !BESIDE_LINK_FIELDS.has(f) && sets(f));
|
|
6148
|
+
if (hasOrgLink && hasDirectBesideLink) {
|
|
6149
|
+
ctx.addIssue({ code: external_exports.ZodIssueCode.custom, message: "Provide either an organization credential link or direct credential fields, not both" });
|
|
6150
|
+
}
|
|
6151
|
+
if (hasOrgLink && data.expires_at != null) {
|
|
6152
|
+
ctx.addIssue({ code: external_exports.ZodIssueCode.custom, message: LINKED_EXPIRY_REFUSAL, path: ["expires_at"] });
|
|
6153
|
+
}
|
|
6154
|
+
if (!hasOrgLink && !hasDirect && data.expires_at === void 0) {
|
|
6155
|
+
ctx.addIssue({ code: external_exports.ZodIssueCode.custom, message: "A credential is required: link an organization credential or provide a credential field" });
|
|
6156
|
+
}
|
|
6157
|
+
});
|
|
6158
|
+
bindSeedConnectionBody = external_exports.object({
|
|
6159
|
+
hub_id: uuidSchema,
|
|
6160
|
+
base_id: external_exports.string().regex(REKOR_STRUCTURAL_ID_PATTERN),
|
|
6161
|
+
token: external_exports.string().min(1).max(1024)
|
|
6162
|
+
}).strict();
|
|
6163
|
+
registerWhatsappQuery = external_exports.object({ hub_id: uuidSchema });
|
|
6164
|
+
registerWhatsappBody = external_exports.object({
|
|
6165
|
+
pin: external_exports.string().optional()
|
|
6166
|
+
});
|
|
6167
|
+
retryProvisioningQuery = external_exports.object({ hub_id: uuidSchema });
|
|
6168
|
+
resendDomainStatusQuery = external_exports.object({ hub_id: uuidSchema });
|
|
6169
|
+
}
|
|
6170
|
+
});
|
|
6171
|
+
|
|
6172
|
+
// ../../packages/core/dist/chunk-IPXBFWUU.js
|
|
6173
|
+
var variantAiModeSchema, experimentStatusSchema, overlayUpdateSchema, experimentIdParam, variantIdParam, listExperimentsQuery, listVariantsQuery, listOverridesQuery, deleteOverrideQuery, createExperimentBody, updateExperimentBody, setExperimentStatusBody, createVariantBody, updateVariantBody, upsertOverrideBody;
|
|
6174
|
+
var init_chunk_IPXBFWUU = __esm({
|
|
6175
|
+
"../../packages/core/dist/chunk-IPXBFWUU.js"() {
|
|
6176
|
+
"use strict";
|
|
6177
|
+
init_chunk_6TSQ5HXC();
|
|
6178
|
+
init_zod();
|
|
6179
|
+
variantAiModeSchema = external_exports.enum(["pilot+copilot", "pilot", "copilot", "turned_off"]);
|
|
6180
|
+
experimentStatusSchema = external_exports.enum(["draft", "running", "stopped"]);
|
|
6181
|
+
overlayUpdateSchema = external_exports.record(external_exports.unknown()).nullish().transform((v) => v === void 0 ? void 0 : v && Object.keys(v).length > 0 ? v : null);
|
|
6182
|
+
experimentIdParam = external_exports.object({
|
|
6183
|
+
id: external_exports.string().uuid()
|
|
6184
|
+
});
|
|
6185
|
+
variantIdParam = external_exports.object({
|
|
6186
|
+
id: external_exports.string().uuid()
|
|
6187
|
+
});
|
|
6188
|
+
listExperimentsQuery = external_exports.object({
|
|
6189
|
+
hub_id: external_exports.string().uuid()
|
|
6190
|
+
});
|
|
6191
|
+
listVariantsQuery = external_exports.object({
|
|
6192
|
+
hub_id: external_exports.string().uuid(),
|
|
6193
|
+
experiment_id: external_exports.string().uuid().optional()
|
|
6194
|
+
});
|
|
6195
|
+
listOverridesQuery = external_exports.object({
|
|
6196
|
+
hub_id: external_exports.string().uuid(),
|
|
6197
|
+
variant_id: external_exports.string().uuid()
|
|
6198
|
+
});
|
|
6199
|
+
deleteOverrideQuery = external_exports.object({
|
|
6200
|
+
hub_id: external_exports.string().uuid(),
|
|
6201
|
+
variant_id: external_exports.string().uuid(),
|
|
6202
|
+
agent_id: external_exports.string().uuid()
|
|
6203
|
+
});
|
|
6204
|
+
createExperimentBody = external_exports.object({
|
|
6205
|
+
hub_id: external_exports.string().uuid(),
|
|
6206
|
+
experiment_slug: slugSchema.optional(),
|
|
6207
|
+
experiment_name: external_exports.string().min(1, "experiment_name is required").max(100, "experiment_name must be 100 characters or fewer"),
|
|
6208
|
+
primary_metric: external_exports.string().max(200).nullish(),
|
|
6209
|
+
status: experimentStatusSchema.default("draft")
|
|
6210
|
+
});
|
|
6211
|
+
updateExperimentBody = external_exports.object({
|
|
6212
|
+
// experiment_slug is immutable after first persist — not accepted here.
|
|
6213
|
+
experiment_name: external_exports.string().min(1).max(100).optional(),
|
|
6214
|
+
primary_metric: external_exports.string().max(200).nullish(),
|
|
6215
|
+
control_variant_id: external_exports.string().uuid().nullish()
|
|
6216
|
+
});
|
|
6217
|
+
setExperimentStatusBody = external_exports.object({
|
|
6218
|
+
status: experimentStatusSchema
|
|
6219
|
+
});
|
|
6220
|
+
createVariantBody = external_exports.object({
|
|
6221
|
+
hub_id: external_exports.string().uuid(),
|
|
6222
|
+
experiment_id: external_exports.string().uuid(),
|
|
6223
|
+
label: external_exports.string().min(1, "label is required").max(100, "label must be 100 characters or fewer"),
|
|
6224
|
+
weight: external_exports.number().positive().default(1),
|
|
6225
|
+
ai_mode: variantAiModeSchema.nullish(),
|
|
6226
|
+
is_control: external_exports.boolean().default(false)
|
|
6227
|
+
});
|
|
6228
|
+
updateVariantBody = external_exports.object({
|
|
6229
|
+
label: external_exports.string().min(1).max(100).optional(),
|
|
6230
|
+
weight: external_exports.number().positive().optional(),
|
|
6231
|
+
ai_mode: variantAiModeSchema.nullish(),
|
|
6232
|
+
is_control: external_exports.boolean().optional()
|
|
6233
|
+
});
|
|
6234
|
+
upsertOverrideBody = external_exports.object({
|
|
6235
|
+
hub_id: external_exports.string().uuid(),
|
|
6236
|
+
variant_id: external_exports.string().uuid(),
|
|
6237
|
+
agent_id: external_exports.string().uuid(),
|
|
6238
|
+
instructions: external_exports.string().nullish(),
|
|
6239
|
+
additional_context_template: external_exports.string().nullish(),
|
|
6240
|
+
connection_id: external_exports.string().uuid().nullish(),
|
|
6241
|
+
agent_settings_overlay: overlayUpdateSchema
|
|
6242
|
+
});
|
|
6243
|
+
}
|
|
6244
|
+
});
|
|
6245
|
+
|
|
6246
|
+
// ../../packages/core/dist/chunk-AYLAGFAD.js
|
|
6247
|
+
var BASE_CREDENTIAL_NAME_MAX, BASE_CREDENTIAL_NAME_PATTERN, BASE_CREDENTIAL_NAME_CHARSET, baseCredentialNameSchema;
|
|
6248
|
+
var init_chunk_AYLAGFAD = __esm({
|
|
6249
|
+
"../../packages/core/dist/chunk-AYLAGFAD.js"() {
|
|
6250
|
+
"use strict";
|
|
6251
|
+
init_zod();
|
|
6252
|
+
BASE_CREDENTIAL_NAME_MAX = 100;
|
|
6253
|
+
BASE_CREDENTIAL_NAME_PATTERN = /^[A-Za-z0-9][A-Za-z0-9._:@+~=-]*$/;
|
|
6254
|
+
BASE_CREDENTIAL_NAME_CHARSET = "letters, digits and '. _ : @ + ~ = -', starting with a letter or digit";
|
|
6255
|
+
baseCredentialNameSchema = external_exports.string().min(1).max(BASE_CREDENTIAL_NAME_MAX).regex(BASE_CREDENTIAL_NAME_PATTERN, `name must use ${BASE_CREDENTIAL_NAME_CHARSET}`);
|
|
6256
|
+
}
|
|
6257
|
+
});
|
|
6258
|
+
|
|
6259
|
+
// ../../packages/core/dist/chunk-DSKOMKRY.js
|
|
6260
|
+
var orgCredentialIdParam, listOrgCredentialsQuery, ORG_CREDENTIAL_SERVICE_REQUIRED, createOrgCredentialBody, updateOrgCredentialBody;
|
|
6261
|
+
var init_chunk_DSKOMKRY = __esm({
|
|
6262
|
+
"../../packages/core/dist/chunk-DSKOMKRY.js"() {
|
|
6263
|
+
"use strict";
|
|
6264
|
+
init_chunk_MF2VVXBR();
|
|
6265
|
+
init_chunk_ZTNFLGW5();
|
|
6266
|
+
init_zod();
|
|
6267
|
+
orgCredentialIdParam = external_exports.object({
|
|
6268
|
+
id: external_exports.string().uuid()
|
|
6269
|
+
});
|
|
6270
|
+
listOrgCredentialsQuery = external_exports.object({
|
|
6271
|
+
organization_id: external_exports.string().uuid(),
|
|
6272
|
+
hub_id: external_exports.string().uuid().optional()
|
|
6273
|
+
});
|
|
6274
|
+
ORG_CREDENTIAL_SERVICE_REQUIRED = "An organization credential must name the service it is for (connector_id): pick its Service in the console, or run `wayai create-credential --service <name>`, updating the WayAI CLI first if it has no --service. Nothing was created.";
|
|
6275
|
+
createOrgCredentialBody = external_exports.object({
|
|
6276
|
+
organization_id: external_exports.string().uuid(),
|
|
6277
|
+
credential_display_name: external_exports.string().min(1).max(255),
|
|
6278
|
+
credential_description: external_exports.string().max(1e3).nullish(),
|
|
6279
|
+
authentication_type: external_exports.enum(["api_key", "bearer", "basic_auth"]).or(
|
|
6280
|
+
external_exports.enum(["API Key", "Bearer Token", "Basic Auth"]).transform((v) => normalizeAuthType(v))
|
|
6281
|
+
),
|
|
6282
|
+
api_key: external_exports.string().optional(),
|
|
6283
|
+
access_token: external_exports.string().optional(),
|
|
6284
|
+
username: external_exports.string().optional(),
|
|
6285
|
+
password: external_exports.string().optional(),
|
|
6286
|
+
tags: external_exports.array(external_exports.string().uuid()).optional(),
|
|
6287
|
+
environment: external_exports.enum(["preview", "production", "all"]).optional(),
|
|
6288
|
+
expires_at: credentialExpiresAtSchema.optional(),
|
|
6289
|
+
/**
|
|
6290
|
+
* The service the credential is for: a catalog `connector_id` (wayai#5644). Required (owner decision Q2): its value goes
|
|
6291
|
+
* to the credentials vault under that connector, and a credential naming none had nowhere there to go. It links only to
|
|
6292
|
+
* connections of that service, and is fixed for the credential's life. A connector whose host the customer types (REST
|
|
6293
|
+
* API, External Resources, MCP Server) is refused: its value is entered on the connection. A client that sends none (a
|
|
6294
|
+
* CLI from before `--service`) is refused with {@link ORG_CREDENTIAL_SERVICE_REQUIRED}.
|
|
6295
|
+
*/
|
|
6296
|
+
connector_id: external_exports.string({ required_error: ORG_CREDENTIAL_SERVICE_REQUIRED }).uuid()
|
|
6297
|
+
});
|
|
6298
|
+
updateOrgCredentialBody = external_exports.object({
|
|
6299
|
+
credential_display_name: external_exports.string().min(1).max(255).optional(),
|
|
6300
|
+
credential_description: external_exports.string().max(1e3).nullish(),
|
|
6301
|
+
api_key: external_exports.string().optional(),
|
|
6302
|
+
access_token: external_exports.string().optional(),
|
|
6303
|
+
username: external_exports.string().optional(),
|
|
6304
|
+
password: external_exports.string().optional(),
|
|
6305
|
+
tags: external_exports.array(external_exports.string().uuid()).optional(),
|
|
6306
|
+
environment: external_exports.enum(["preview", "production", "all"]).optional(),
|
|
6307
|
+
// Absent keeps the stored date, unless the request stores a new secret, which clears it.
|
|
6308
|
+
expires_at: credentialExpiresAtSchema.optional()
|
|
6309
|
+
});
|
|
6310
|
+
}
|
|
6311
|
+
});
|
|
6312
|
+
|
|
6313
|
+
// ../../packages/core/dist/chunk-HIGKBEPF.js
|
|
6314
|
+
var accessExplainQuery;
|
|
6315
|
+
var init_chunk_HIGKBEPF = __esm({
|
|
6316
|
+
"../../packages/core/dist/chunk-HIGKBEPF.js"() {
|
|
6317
|
+
"use strict";
|
|
6318
|
+
init_chunk_HZ6CADSY();
|
|
6319
|
+
init_zod();
|
|
6320
|
+
accessExplainQuery = external_exports.object({
|
|
6321
|
+
user_id: external_exports.string().regex(USER_ID_REGEX).optional()
|
|
6322
|
+
});
|
|
6323
|
+
}
|
|
6324
|
+
});
|
|
6325
|
+
|
|
6326
|
+
// ../../packages/core/dist/chunk-KEN2DASI.js
|
|
6327
|
+
var SECOND_FACTOR_TIERS, secondFactorTier, META_ENTITY_ID_PATTERN, metaEntityId, whatsappCallbackBody, authMeResponse, wsTicketResponse, sessionCheckResponse, logoutResponse, magicCodeSendBody, magicCodeSendResponse, magicCodeVerifyBody, magicCodeVerifyResponse, passwordLoginBody, normalizeEmail, REVIEW_ACCOUNT_EMAILS;
|
|
6328
|
+
var init_chunk_KEN2DASI = __esm({
|
|
6329
|
+
"../../packages/core/dist/chunk-KEN2DASI.js"() {
|
|
6330
|
+
"use strict";
|
|
6331
|
+
init_zod();
|
|
6332
|
+
SECOND_FACTOR_TIERS = ["off", "settings"];
|
|
6333
|
+
secondFactorTier = external_exports.enum(SECOND_FACTOR_TIERS);
|
|
6334
|
+
META_ENTITY_ID_PATTERN = /^\d{1,32}$/;
|
|
6335
|
+
metaEntityId = external_exports.string().regex(META_ENTITY_ID_PATTERN, "must be a numeric Meta entity id");
|
|
6336
|
+
whatsappCallbackBody = external_exports.object({
|
|
6337
|
+
state: external_exports.string().min(1, "state is required"),
|
|
6338
|
+
code: external_exports.string().optional(),
|
|
6339
|
+
access_token: external_exports.string().optional(),
|
|
6340
|
+
user_id: external_exports.string().optional(),
|
|
6341
|
+
/**
|
|
6342
|
+
* The phone number and WABA the operator actually picked in Meta's Embedded
|
|
6343
|
+
* Signup popup (posted to the opener as `WA_EMBEDDED_SIGNUP`). Optional:
|
|
6344
|
+
* older clients, and the redirect-based flow, never see that event and fall
|
|
6345
|
+
* back to discovery.
|
|
6346
|
+
*/
|
|
6347
|
+
phone_number_id: metaEntityId.optional(),
|
|
6348
|
+
waba_id: metaEntityId.optional()
|
|
6349
|
+
}).refine(
|
|
6350
|
+
(data) => !!data.access_token || !!data.code,
|
|
6351
|
+
{ message: "Missing required parameters: state and either access_token or code" }
|
|
6352
|
+
);
|
|
6353
|
+
authMeResponse = external_exports.object({
|
|
6354
|
+
user_id: external_exports.string(),
|
|
6355
|
+
email: external_exports.string(),
|
|
6356
|
+
org_id: external_exports.string().nullable(),
|
|
6357
|
+
is_platform_admin: external_exports.boolean()
|
|
6358
|
+
});
|
|
6359
|
+
wsTicketResponse = external_exports.object({
|
|
6360
|
+
ticket: external_exports.string(),
|
|
6361
|
+
/** Seconds until the ticket expires if unconsumed. */
|
|
6362
|
+
expires_in: external_exports.number()
|
|
6363
|
+
});
|
|
6364
|
+
sessionCheckResponse = external_exports.object({
|
|
6365
|
+
valid: external_exports.literal(true)
|
|
6366
|
+
});
|
|
6367
|
+
logoutResponse = external_exports.object({
|
|
6368
|
+
success: external_exports.literal(true)
|
|
6369
|
+
});
|
|
6370
|
+
magicCodeSendBody = external_exports.object({
|
|
6371
|
+
email: external_exports.string().email("Invalid email").max(254)
|
|
6372
|
+
// RFC 5321 max; bounds the request payload
|
|
6373
|
+
});
|
|
6374
|
+
magicCodeSendResponse = external_exports.object({
|
|
6375
|
+
success: external_exports.literal(true)
|
|
6376
|
+
});
|
|
6377
|
+
magicCodeVerifyBody = external_exports.object({
|
|
6378
|
+
email: external_exports.string().email("Invalid email").max(254),
|
|
6379
|
+
// RFC 5321 max; bounds the request payload
|
|
6380
|
+
code: external_exports.string().min(1, "Code is required").max(12)
|
|
6381
|
+
// WorkOS sends a 6-digit code; bound the input
|
|
6382
|
+
});
|
|
6383
|
+
magicCodeVerifyResponse = external_exports.object({
|
|
6384
|
+
access_token: external_exports.string(),
|
|
6385
|
+
refresh_token: external_exports.string()
|
|
6386
|
+
});
|
|
6387
|
+
passwordLoginBody = external_exports.object({
|
|
6388
|
+
email: external_exports.string().email("Invalid email").max(254),
|
|
6389
|
+
// RFC 5321 max; bounds the request payload
|
|
6390
|
+
password: external_exports.string().min(1, "Password is required").max(128)
|
|
6391
|
+
// bound the payload; WorkOS validates
|
|
6392
|
+
});
|
|
6393
|
+
normalizeEmail = (email) => email.trim().toLowerCase();
|
|
6394
|
+
REVIEW_ACCOUNT_EMAILS = new Set(
|
|
6395
|
+
["apple.review@wayai.pro", "play.review@wayai.pro", "microsoft.review@wayai.pro", "meta.review@wayai.pro"].map(
|
|
6396
|
+
normalizeEmail
|
|
6397
|
+
)
|
|
6398
|
+
);
|
|
6399
|
+
}
|
|
6400
|
+
});
|
|
6401
|
+
|
|
6402
|
+
// ../../packages/core/dist/chunk-PFGVH2CX.js
|
|
6403
|
+
var secondFactorCode, secondFactorRecoveryCode, secondFactorCodeBody, secondFactorRecoveryBody, secondFactorDisableBody, setOrgSecondFactorBody;
|
|
6404
|
+
var init_chunk_PFGVH2CX = __esm({
|
|
6405
|
+
"../../packages/core/dist/chunk-PFGVH2CX.js"() {
|
|
6406
|
+
"use strict";
|
|
6407
|
+
init_chunk_KEN2DASI();
|
|
6408
|
+
init_zod();
|
|
6409
|
+
secondFactorCode = external_exports.string().regex(/^\d{6}$/, "Enter the 6-digit code");
|
|
6410
|
+
secondFactorRecoveryCode = external_exports.string().min(1, "Enter a recovery code").max(64);
|
|
6411
|
+
secondFactorCodeBody = external_exports.object({ code: secondFactorCode });
|
|
6412
|
+
secondFactorRecoveryBody = external_exports.object({ recovery_code: secondFactorRecoveryCode });
|
|
6413
|
+
secondFactorDisableBody = external_exports.union([
|
|
6414
|
+
external_exports.object({ code: secondFactorCode, recovery_code: external_exports.undefined().optional() }),
|
|
6415
|
+
external_exports.object({ recovery_code: secondFactorRecoveryCode, code: external_exports.undefined().optional() })
|
|
6416
|
+
]);
|
|
6417
|
+
setOrgSecondFactorBody = external_exports.object({ tier: secondFactorTier });
|
|
6418
|
+
}
|
|
6419
|
+
});
|
|
6420
|
+
|
|
6421
|
+
// ../../packages/core/dist/chunk-WE4KMHZK.js
|
|
6422
|
+
var bootstrapQuery;
|
|
6423
|
+
var init_chunk_WE4KMHZK = __esm({
|
|
6424
|
+
"../../packages/core/dist/chunk-WE4KMHZK.js"() {
|
|
6425
|
+
"use strict";
|
|
6426
|
+
init_zod();
|
|
6427
|
+
bootstrapQuery = external_exports.object({
|
|
6428
|
+
active_hub_id: external_exports.string().uuid().optional(),
|
|
6429
|
+
active_conversation_id: external_exports.string().uuid().optional(),
|
|
6430
|
+
active_nav: external_exports.enum(["chat", "task", "support"]).optional(),
|
|
6431
|
+
/**
|
|
6432
|
+
* The people thread the URL names (`/chat/threads/:threadId`, gh #4661): the snapshot
|
|
6433
|
+
* preloads it as `people.active_thread` when the viewer is a member.
|
|
6434
|
+
*/
|
|
6435
|
+
active_thread_id: external_exports.string().uuid().optional()
|
|
6436
|
+
});
|
|
6437
|
+
}
|
|
6438
|
+
});
|
|
6439
|
+
|
|
6440
|
+
// ../../packages/core/dist/chunk-SCC6AVLY.js
|
|
6441
|
+
var PERMISSIONS;
|
|
6442
|
+
var init_chunk_SCC6AVLY = __esm({
|
|
6443
|
+
"../../packages/core/dist/chunk-SCC6AVLY.js"() {
|
|
6444
|
+
"use strict";
|
|
6445
|
+
PERMISSIONS = [
|
|
6446
|
+
"hub:read",
|
|
6447
|
+
"hub:write",
|
|
6448
|
+
"hub:admin",
|
|
6449
|
+
"conversation:read",
|
|
6450
|
+
"conversation:write",
|
|
6451
|
+
"analytics:read",
|
|
6452
|
+
"billing:read",
|
|
6453
|
+
"billing:write",
|
|
6454
|
+
"org:read",
|
|
6455
|
+
"org:write",
|
|
6456
|
+
"org:admin",
|
|
6457
|
+
"contacts:write",
|
|
6458
|
+
"platform:admin",
|
|
6459
|
+
"*"
|
|
6460
|
+
];
|
|
6461
|
+
}
|
|
6462
|
+
});
|
|
6463
|
+
|
|
6464
|
+
// ../../packages/core/dist/chunk-P5GJNS5R.js
|
|
6465
|
+
var MAX_NAME_LENGTH, MAX_HUBS_PER_GRANT, MAX_HUB_TAGS_PER_GRANT, MAX_GRANTS, permissionEnum, grantScopeSchema, grantSchema, createTokenBody, tokenOrgIdParam;
|
|
6466
|
+
var init_chunk_P5GJNS5R = __esm({
|
|
6467
|
+
"../../packages/core/dist/chunk-P5GJNS5R.js"() {
|
|
6468
|
+
"use strict";
|
|
6469
|
+
init_chunk_SCC6AVLY();
|
|
6470
|
+
init_chunk_HZ6CADSY();
|
|
6471
|
+
init_zod();
|
|
6472
|
+
MAX_NAME_LENGTH = 100;
|
|
6473
|
+
MAX_HUBS_PER_GRANT = 50;
|
|
6474
|
+
MAX_HUB_TAGS_PER_GRANT = 20;
|
|
6475
|
+
MAX_GRANTS = 20;
|
|
6476
|
+
permissionEnum = external_exports.enum(PERMISSIONS).refine(
|
|
6477
|
+
(p) => p !== "platform:admin",
|
|
6478
|
+
{ message: "platform:admin cannot be delegated via token creation" }
|
|
6479
|
+
);
|
|
6480
|
+
grantScopeSchema = external_exports.object({
|
|
6481
|
+
// Required: every token grant must declare its org tenancy. The handler
|
|
6482
|
+
// also strict-checks this as defense-in-depth, but failing at the Zod
|
|
6483
|
+
// boundary keeps the generated client type honest (org_id: string).
|
|
6484
|
+
org_id: external_exports.string().min(1),
|
|
6485
|
+
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),
|
|
6486
|
+
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(),
|
|
6487
|
+
environments: external_exports.array(external_exports.enum(["production", "preview"])).min(1, "scope.environments must be a non-empty array if provided").optional()
|
|
6488
|
+
}).strict();
|
|
6489
|
+
grantSchema = external_exports.object({
|
|
6490
|
+
scope: grantScopeSchema,
|
|
6491
|
+
permissions: external_exports.array(permissionEnum).min(1, "Each grant must have permissions as a non-empty array")
|
|
6492
|
+
}).strict();
|
|
6493
|
+
createTokenBody = external_exports.object({
|
|
6494
|
+
name: external_exports.string().trim().min(1, "name is required").max(MAX_NAME_LENGTH, `name must be ${MAX_NAME_LENGTH} characters or fewer`),
|
|
6495
|
+
grants: external_exports.array(grantSchema).min(1, "grants must be a non-empty array").max(MAX_GRANTS),
|
|
6496
|
+
expires_at: external_exports.string().datetime({ message: "expires_at must be a valid ISO 8601 date" }).refine(
|
|
6497
|
+
(s) => new Date(s).getTime() > Date.now(),
|
|
6498
|
+
{ message: "expires_at must be in the future" }
|
|
6499
|
+
).optional()
|
|
6500
|
+
});
|
|
6501
|
+
tokenOrgIdParam = external_exports.object({ orgId: uuidSchema });
|
|
6502
|
+
}
|
|
6503
|
+
});
|
|
6504
|
+
|
|
6505
|
+
// ../../packages/core/dist/chunk-OSWY3GQY.js
|
|
6504
6506
|
var TOOLSET_ANSWER_PERSON_PARTIES, toolsetAnswerPersonSchema, toolsetAnswerPersonsSchema;
|
|
6505
|
-
var
|
|
6506
|
-
"../../packages/core/dist/chunk-
|
|
6507
|
+
var init_chunk_OSWY3GQY = __esm({
|
|
6508
|
+
"../../packages/core/dist/chunk-OSWY3GQY.js"() {
|
|
6507
6509
|
"use strict";
|
|
6508
|
-
|
|
6510
|
+
init_chunk_HVCJ2WAL();
|
|
6509
6511
|
init_chunk_LHTWT6HS();
|
|
6510
6512
|
init_zod();
|
|
6511
6513
|
TOOLSET_ANSWER_PERSON_PARTIES = ["requester", "originator", "initiator", "delegator"];
|
|
@@ -8062,12 +8064,12 @@ var init_chunk_FBV7NLKO = __esm({
|
|
|
8062
8064
|
}
|
|
8063
8065
|
});
|
|
8064
8066
|
|
|
8065
|
-
// ../../packages/core/dist/chunk-
|
|
8067
|
+
// ../../packages/core/dist/chunk-TBQYMMC2.js
|
|
8066
8068
|
var hubPageWatchParam, pageWatchedBaseSchema, hubPageWatchResponseSchema;
|
|
8067
|
-
var
|
|
8068
|
-
"../../packages/core/dist/chunk-
|
|
8069
|
+
var init_chunk_TBQYMMC2 = __esm({
|
|
8070
|
+
"../../packages/core/dist/chunk-TBQYMMC2.js"() {
|
|
8069
8071
|
"use strict";
|
|
8070
|
-
|
|
8072
|
+
init_chunk_HVCJ2WAL();
|
|
8071
8073
|
init_chunk_FBV7NLKO();
|
|
8072
8074
|
init_chunk_HZ6CADSY();
|
|
8073
8075
|
init_zod();
|
|
@@ -12884,7 +12886,7 @@ var init_chunk_2ISUBJG7 = __esm({
|
|
|
12884
12886
|
}
|
|
12885
12887
|
});
|
|
12886
12888
|
|
|
12887
|
-
// ../../packages/core/dist/chunk-
|
|
12889
|
+
// ../../packages/core/dist/chunk-LIE6DQT2.js
|
|
12888
12890
|
function describeRole(role) {
|
|
12889
12891
|
if (typeof role === "string") {
|
|
12890
12892
|
return JSON.stringify(role.length > ROLE_ECHO_MAX ? `${role.slice(0, ROLE_ECHO_MAX)}\u2026` : role);
|
|
@@ -13063,8 +13065,8 @@ function terminalRunCount(counts) {
|
|
|
13063
13065
|
return counts.successful_runs + counts.failed_runs;
|
|
13064
13066
|
}
|
|
13065
13067
|
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;
|
|
13066
|
-
var
|
|
13067
|
-
"../../packages/core/dist/chunk-
|
|
13068
|
+
var init_chunk_LIE6DQT2 = __esm({
|
|
13069
|
+
"../../packages/core/dist/chunk-LIE6DQT2.js"() {
|
|
13068
13070
|
"use strict";
|
|
13069
13071
|
init_chunk_2YEGUQR7();
|
|
13070
13072
|
init_chunk_LHTWT6HS();
|
|
@@ -13917,7 +13919,7 @@ var init_chunk_PIZTARVG = __esm({
|
|
|
13917
13919
|
}
|
|
13918
13920
|
});
|
|
13919
13921
|
|
|
13920
|
-
// ../../packages/core/dist/chunk-
|
|
13922
|
+
// ../../packages/core/dist/chunk-XEG3QEIZ.js
|
|
13921
13923
|
function refineLaneReferences(val, ctx) {
|
|
13922
13924
|
const lanes = val.lanes;
|
|
13923
13925
|
const statuses = val.kanban_statuses;
|
|
@@ -13941,8 +13943,8 @@ function describeSyncWarning(warning) {
|
|
|
13941
13943
|
return `${label3}: ${parts.join("; ")}. Promote the base so production's tools match the preview's.`;
|
|
13942
13944
|
}
|
|
13943
13945
|
var hubIdParam, hubAdminIdParam, hubUserIdParam, hubAgentIdParam, hubIdentityIdParam, hubTeamIdParam, hubTeamUserDeleteParam, hubSchemaQuery, HUB_USERS_PAGE_SIZE_MAX, HUB_USERS_SEARCH_MAX, HUB_USERS_CHANNEL_TYPES, getHubUsersQuery, PREVIEW_LABEL_MAX_LENGTH, MAX_ENDED_INDEX_RETENTION_DAYS, MAX_EVAL_RETENTION_DAYS, MAX_END_USER_DAILY_MESSAGE_LIMIT, endUserDailyMessageLimitField, previewLabelField, hubTagsField, createHubBody, updateHubBody, HUB_TAG_CHANGE_REFUSED, hubTagChangeRefusalSchema, addHubAdminBody, addHubIdentityAuthorizationBody, contactDecisionBody, approveContactBody, CONTACT_ACCESS_PAGE_SIZE_MAX, listContactAccessQuery, createHubTeamBody, updateHubTeamBody, addHubTeamUserBody, reassignHubUserBody, replicatePreviewBody, HUB_DIFF_SECTION_SET, HUB_DIFF_SECTIONS, updateChannelTestIdentitiesBody, claimCodeChannelParam, claimCodeDeleteParam;
|
|
13944
|
-
var
|
|
13945
|
-
"../../packages/core/dist/chunk-
|
|
13946
|
+
var init_chunk_XEG3QEIZ = __esm({
|
|
13947
|
+
"../../packages/core/dist/chunk-XEG3QEIZ.js"() {
|
|
13946
13948
|
"use strict";
|
|
13947
13949
|
init_chunk_D3EP4TDU();
|
|
13948
13950
|
init_chunk_YZHCIGDZ();
|
|
@@ -14039,7 +14041,7 @@ var init_chunk_B32UCOKG = __esm({
|
|
|
14039
14041
|
fallback_connection_id: uuidSchema.nullable().optional(),
|
|
14040
14042
|
// Rekor API connection used to reset/clear eval seed fixtures (gh #3090). A
|
|
14041
14043
|
// connection id on this hub (a REST API (custom tool) connection whose base_url
|
|
14042
|
-
// is the
|
|
14044
|
+
// is the data API's origin, bound to its base with no token stored: wayai#5644). Validated at
|
|
14043
14045
|
// set-time on the REST PATCH (setup/hubs.ts). Nullable to clear it.
|
|
14044
14046
|
seed_connection_id: uuidSchema.nullable().optional(),
|
|
14045
14047
|
// Org tag ids, replacing the hub's; null clears them. A change is refused to anyone
|
|
@@ -14141,7 +14143,7 @@ var init_chunk_B32UCOKG = __esm({
|
|
|
14141
14143
|
}
|
|
14142
14144
|
});
|
|
14143
14145
|
|
|
14144
|
-
// ../../packages/core/dist/chunk-
|
|
14146
|
+
// ../../packages/core/dist/chunk-3LM6A6Y3.js
|
|
14145
14147
|
function declaresNoConnection(agent) {
|
|
14146
14148
|
return agent.connection === null && !agent.connection_id;
|
|
14147
14149
|
}
|
|
@@ -14873,16 +14875,16 @@ function skillSectionsAsResources(scope) {
|
|
|
14873
14875
|
};
|
|
14874
14876
|
}
|
|
14875
14877
|
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;
|
|
14876
|
-
var
|
|
14877
|
-
"../../packages/core/dist/chunk-
|
|
14878
|
+
var init_chunk_3LM6A6Y3 = __esm({
|
|
14879
|
+
"../../packages/core/dist/chunk-3LM6A6Y3.js"() {
|
|
14878
14880
|
"use strict";
|
|
14879
14881
|
init_chunk_JSPSTJH4();
|
|
14880
14882
|
init_chunk_2PQCTEDW();
|
|
14881
|
-
|
|
14883
|
+
init_chunk_LIE6DQT2();
|
|
14882
14884
|
init_chunk_WRLPUYS3();
|
|
14883
14885
|
init_chunk_LBDH7LCG();
|
|
14884
14886
|
init_chunk_4LXDRTO4();
|
|
14885
|
-
|
|
14887
|
+
init_chunk_XEG3QEIZ();
|
|
14886
14888
|
init_chunk_YZHCIGDZ();
|
|
14887
14889
|
init_chunk_PIZTARVG();
|
|
14888
14890
|
init_chunk_FBV7NLKO();
|
|
@@ -17082,7 +17084,7 @@ var init_chunk_OMPT4ZHR = __esm({
|
|
|
17082
17084
|
}
|
|
17083
17085
|
});
|
|
17084
17086
|
|
|
17085
|
-
// ../../packages/core/dist/chunk-
|
|
17087
|
+
// ../../packages/core/dist/chunk-3UITNZV5.js
|
|
17086
17088
|
function refineScopedTarget(data, ctx) {
|
|
17087
17089
|
if (data.scope === "org") {
|
|
17088
17090
|
if (!data.org_id) {
|
|
@@ -17108,13 +17110,13 @@ function refineScopedTarget(data, ctx) {
|
|
|
17108
17110
|
}
|
|
17109
17111
|
}
|
|
17110
17112
|
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, casesLimit, updatePlatformConfigBody, updateFreeOrgLimitBody, adminScopedTargetShape, adminScopedTargetBody, adminDryRunByDefaultTargetBody, WAYAI_HOST_TOKEN_TARGET_KINDS, WAYAI_HOST_TOKEN_MAX_TARGETS, adminClearWayaiHostTokensBody, BRANCHING_ORPHAN_ENTITY_TYPES, BRANCHING_ORPHAN_MAX_TARGETS, adminRepairBranchingOrphansBody, adminRepairLegacyOrgGrantsBody, adminRepairCredentialServicesBody, 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;
|
|
17111
|
-
var
|
|
17112
|
-
"../../packages/core/dist/chunk-
|
|
17113
|
+
var init_chunk_3UITNZV5 = __esm({
|
|
17114
|
+
"../../packages/core/dist/chunk-3UITNZV5.js"() {
|
|
17113
17115
|
"use strict";
|
|
17114
17116
|
init_chunk_FECLIZTY();
|
|
17115
17117
|
init_chunk_BFG4ZWR4();
|
|
17116
17118
|
init_chunk_7VJ4SOFF();
|
|
17117
|
-
|
|
17119
|
+
init_chunk_XEG3QEIZ();
|
|
17118
17120
|
init_chunk_OMPT4ZHR();
|
|
17119
17121
|
init_chunk_HZ6CADSY();
|
|
17120
17122
|
init_chunk_MIWZOSPI();
|
|
@@ -17688,7 +17690,7 @@ var init_contracts = __esm({
|
|
|
17688
17690
|
init_chunk_VXEAR36B();
|
|
17689
17691
|
init_chunk_RACEDHG6();
|
|
17690
17692
|
init_chunk_Q7KIQHAZ();
|
|
17691
|
-
|
|
17693
|
+
init_chunk_6KMVY2W7();
|
|
17692
17694
|
init_chunk_IPXBFWUU();
|
|
17693
17695
|
init_chunk_AYLAGFAD();
|
|
17694
17696
|
init_chunk_DSKOMKRY();
|
|
@@ -17697,7 +17699,7 @@ var init_contracts = __esm({
|
|
|
17697
17699
|
init_chunk_PFGVH2CX();
|
|
17698
17700
|
init_chunk_WE4KMHZK();
|
|
17699
17701
|
init_chunk_P5GJNS5R();
|
|
17700
|
-
|
|
17702
|
+
init_chunk_OSWY3GQY();
|
|
17701
17703
|
init_chunk_ZC6YGHNX();
|
|
17702
17704
|
init_chunk_MGBAXT5Y();
|
|
17703
17705
|
init_chunk_5DGHIY7L();
|
|
@@ -17705,8 +17707,8 @@ var init_contracts = __esm({
|
|
|
17705
17707
|
init_chunk_IPDOHAZ5();
|
|
17706
17708
|
init_chunk_34LE6P7E();
|
|
17707
17709
|
init_chunk_FPSDNS2E();
|
|
17708
|
-
|
|
17709
|
-
|
|
17710
|
+
init_chunk_TBQYMMC2();
|
|
17711
|
+
init_chunk_HVCJ2WAL();
|
|
17710
17712
|
init_chunk_ZXK6N2HN();
|
|
17711
17713
|
init_chunk_Y7CFCYX4();
|
|
17712
17714
|
init_chunk_OABSWQ6P();
|
|
@@ -17724,10 +17726,10 @@ var init_contracts = __esm({
|
|
|
17724
17726
|
init_chunk_KSTYTQ7I();
|
|
17725
17727
|
init_chunk_LKBSHANA();
|
|
17726
17728
|
init_chunk_FMB4KA3N();
|
|
17727
|
-
|
|
17729
|
+
init_chunk_3LM6A6Y3();
|
|
17728
17730
|
init_chunk_JSPSTJH4();
|
|
17729
17731
|
init_chunk_2PQCTEDW();
|
|
17730
|
-
|
|
17732
|
+
init_chunk_LIE6DQT2();
|
|
17731
17733
|
init_chunk_2YEGUQR7();
|
|
17732
17734
|
init_chunk_LHTWT6HS();
|
|
17733
17735
|
init_chunk_JDJ4EUOL();
|
|
@@ -17764,11 +17766,11 @@ var init_contracts = __esm({
|
|
|
17764
17766
|
init_chunk_N7TIWXUC();
|
|
17765
17767
|
init_chunk_IZPR5A6I();
|
|
17766
17768
|
init_chunk_NVKU5PPQ();
|
|
17767
|
-
|
|
17769
|
+
init_chunk_3UITNZV5();
|
|
17768
17770
|
init_chunk_FECLIZTY();
|
|
17769
17771
|
init_chunk_BFG4ZWR4();
|
|
17770
17772
|
init_chunk_7VJ4SOFF();
|
|
17771
|
-
|
|
17773
|
+
init_chunk_XEG3QEIZ();
|
|
17772
17774
|
init_chunk_D3EP4TDU();
|
|
17773
17775
|
init_chunk_YZHCIGDZ();
|
|
17774
17776
|
init_chunk_PIZTARVG();
|
|
@@ -19120,6 +19122,7 @@ var init_utils = __esm({
|
|
|
19120
19122
|
["create-credential", { positionals: 0, values: ["--name", "--type", "--service", "--org", "--description", "--tag", "--environment"] }],
|
|
19121
19123
|
["update-credential", { positionals: 0, values: ["--name", "--rename", "--org", "--description", "--tag", "--environment"] }],
|
|
19122
19124
|
["set-connection-credential", { positionals: 0, values: ["--hub", "--connection", "--org-credential", "--field"] }],
|
|
19125
|
+
["bind-seed-connection", { positionals: 0, values: ["--hub", "--connection", "--base"] }],
|
|
19123
19126
|
["org create", { positionals: 1, values: ["--region"] }],
|
|
19124
19127
|
["org pull", { positionals: 0 }],
|
|
19125
19128
|
["org diff", { positionals: 0 }],
|
|
@@ -20221,6 +20224,13 @@ var init_api_client = __esm({
|
|
|
20221
20224
|
async setPreviewConnectionCredential(connectionId, body) {
|
|
20222
20225
|
return this.request("PATCH", `/api/setup/connections/${connectionId}`, body);
|
|
20223
20226
|
}
|
|
20227
|
+
/**
|
|
20228
|
+
* Bind a PREVIEW hub's eval seed connection to one base with that base's `write:seeds` token, which the server uses
|
|
20229
|
+
* once to read its binding and never stores (wayai#5644).
|
|
20230
|
+
*/
|
|
20231
|
+
async bindSeedConnection(connectionId, body) {
|
|
20232
|
+
return this.request("POST", `/api/setup/connections/${connectionId}/seed-binding`, body);
|
|
20233
|
+
}
|
|
20224
20234
|
/** Set a credential on a PRODUCTION connection (the sanctioned carve-out). */
|
|
20225
20235
|
async setProductionConnectionCredential(connectionId, body) {
|
|
20226
20236
|
return this.request("PATCH", `/api/setup/connections/${connectionId}/production-credential`, body);
|
|
@@ -23168,7 +23178,7 @@ var init_pages2 = __esm({
|
|
|
23168
23178
|
var init_evals = __esm({
|
|
23169
23179
|
"../../packages/core/dist/contracts/evals.js"() {
|
|
23170
23180
|
"use strict";
|
|
23171
|
-
|
|
23181
|
+
init_chunk_LIE6DQT2();
|
|
23172
23182
|
init_chunk_2YEGUQR7();
|
|
23173
23183
|
init_chunk_LHTWT6HS();
|
|
23174
23184
|
init_chunk_4LXDRTO4();
|
|
@@ -24196,16 +24206,16 @@ var init_hub_materializer = __esm({
|
|
|
24196
24206
|
var init_ci = __esm({
|
|
24197
24207
|
"../../packages/core/dist/contracts/ci.js"() {
|
|
24198
24208
|
"use strict";
|
|
24199
|
-
|
|
24209
|
+
init_chunk_3LM6A6Y3();
|
|
24200
24210
|
init_chunk_JSPSTJH4();
|
|
24201
24211
|
init_chunk_2PQCTEDW();
|
|
24202
|
-
|
|
24212
|
+
init_chunk_LIE6DQT2();
|
|
24203
24213
|
init_chunk_2YEGUQR7();
|
|
24204
24214
|
init_chunk_LHTWT6HS();
|
|
24205
24215
|
init_chunk_WRLPUYS3();
|
|
24206
24216
|
init_chunk_LBDH7LCG();
|
|
24207
24217
|
init_chunk_4LXDRTO4();
|
|
24208
|
-
|
|
24218
|
+
init_chunk_XEG3QEIZ();
|
|
24209
24219
|
init_chunk_D3EP4TDU();
|
|
24210
24220
|
init_chunk_YZHCIGDZ();
|
|
24211
24221
|
init_chunk_PIZTARVG();
|
|
@@ -36592,6 +36602,63 @@ var init_set_connection_credential = __esm({
|
|
|
36592
36602
|
}
|
|
36593
36603
|
});
|
|
36594
36604
|
|
|
36605
|
+
// src/commands/bind-seed-connection.ts
|
|
36606
|
+
var bind_seed_connection_exports = {};
|
|
36607
|
+
__export(bind_seed_connection_exports, {
|
|
36608
|
+
bindSeedConnectionCommand: () => bindSeedConnectionCommand,
|
|
36609
|
+
parseArgs: () => parseArgs22
|
|
36610
|
+
});
|
|
36611
|
+
function parseArgs22(args2) {
|
|
36612
|
+
let connection;
|
|
36613
|
+
let base;
|
|
36614
|
+
let stdin = false;
|
|
36615
|
+
for (let i = 0; i < args2.length; i++) {
|
|
36616
|
+
if (args2[i] === "--connection" && args2[i + 1]) connection = args2[++i];
|
|
36617
|
+
else if (args2[i] === "--base" && args2[i + 1]) base = args2[++i];
|
|
36618
|
+
else if (args2[i] === "--stdin") stdin = true;
|
|
36619
|
+
}
|
|
36620
|
+
return { connection, base, stdin };
|
|
36621
|
+
}
|
|
36622
|
+
function usage3(msg) {
|
|
36623
|
+
if (msg) console.error(`${msg}
|
|
36624
|
+
`);
|
|
36625
|
+
console.error('Usage: printf %s "$SEED_TOKEN" | wayai bind-seed-connection --hub <id|name> --connection <name|id> --base <base_id> --stdin');
|
|
36626
|
+
console.error(" --connection <name|id> the hub's seed connection (`seed_connection:` in hub.yaml)");
|
|
36627
|
+
console.error(" --base <base_id> the base its evals seed (their `target_base`)");
|
|
36628
|
+
console.error(" --stdin read the base's write:seeds token from stdin (otherwise it is prompted for); it is used once and never stored");
|
|
36629
|
+
process.exit(1);
|
|
36630
|
+
}
|
|
36631
|
+
async function bindSeedConnectionCommand(args2) {
|
|
36632
|
+
const hubId = resolveActiveHubId(args2);
|
|
36633
|
+
const parsed = parseArgs22(args2);
|
|
36634
|
+
if (!parsed.connection) usage3("Missing required flag: --connection <name|id>");
|
|
36635
|
+
if (!parsed.base) usage3("Missing required flag: --base <base_id>");
|
|
36636
|
+
const { config, accessToken } = await requireAuth();
|
|
36637
|
+
const client = new ApiClient({ apiUrl: config.api_url, accessToken });
|
|
36638
|
+
const { connections } = await client.listConnections(hubId);
|
|
36639
|
+
const conn = connections.find(
|
|
36640
|
+
(c) => c.connection_id === parsed.connection || c.connection_display_name === parsed.connection
|
|
36641
|
+
);
|
|
36642
|
+
if (!conn || !conn.connection_id) usage3(`Connection "${parsed.connection}" not found on hub ${hubId}.`);
|
|
36643
|
+
const token = await readSecret(
|
|
36644
|
+
{ stdin: parsed.stdin, prompt: void 0, stdinFlag: "--stdin", promptHint: "omit --stdin to be prompted for the token" },
|
|
36645
|
+
"write:seeds token"
|
|
36646
|
+
);
|
|
36647
|
+
const bound = await client.bindSeedConnection(conn.connection_id, { hub_id: hubId, base_id: parsed.base, token });
|
|
36648
|
+
console.log(
|
|
36649
|
+
`Bound seed connection "${conn.connection_display_name}" to base ${bound.base_id} (incarnation ${bound.base_generation}, token ${bound.token_id}). The token was not stored.`
|
|
36650
|
+
);
|
|
36651
|
+
}
|
|
36652
|
+
var init_bind_seed_connection = __esm({
|
|
36653
|
+
"src/commands/bind-seed-connection.ts"() {
|
|
36654
|
+
"use strict";
|
|
36655
|
+
init_auth();
|
|
36656
|
+
init_api_client();
|
|
36657
|
+
init_workspace();
|
|
36658
|
+
init_helpers();
|
|
36659
|
+
}
|
|
36660
|
+
});
|
|
36661
|
+
|
|
36595
36662
|
// src/lib/org-workspace.ts
|
|
36596
36663
|
import * as fs29 from "fs";
|
|
36597
36664
|
import * as path41 from "path";
|
|
@@ -36887,9 +36954,9 @@ var init_org = __esm({
|
|
|
36887
36954
|
var list_exports = {};
|
|
36888
36955
|
__export(list_exports, {
|
|
36889
36956
|
listCommand: () => listCommand,
|
|
36890
|
-
parseArgs: () =>
|
|
36957
|
+
parseArgs: () => parseArgs23
|
|
36891
36958
|
});
|
|
36892
|
-
function
|
|
36959
|
+
function parseArgs23(args2) {
|
|
36893
36960
|
let orgId;
|
|
36894
36961
|
let json = false;
|
|
36895
36962
|
for (let i = 0; i < args2.length; i++) {
|
|
@@ -36902,7 +36969,7 @@ function parseArgs22(args2) {
|
|
|
36902
36969
|
return { orgId, json };
|
|
36903
36970
|
}
|
|
36904
36971
|
async function listCommand(args2) {
|
|
36905
|
-
const { orgId, json } =
|
|
36972
|
+
const { orgId, json } = parseArgs23(args2);
|
|
36906
36973
|
const { config, accessToken } = await requireAuth();
|
|
36907
36974
|
const client = new ApiClient({ apiUrl: config.api_url, accessToken });
|
|
36908
36975
|
const { organizations } = await client.organizations();
|
|
@@ -37059,10 +37126,10 @@ var communities_exports = {};
|
|
|
37059
37126
|
__export(communities_exports, {
|
|
37060
37127
|
communitiesCommand: () => communitiesCommand
|
|
37061
37128
|
});
|
|
37062
|
-
import { parseArgs as
|
|
37129
|
+
import { parseArgs as parseArgs24 } from "util";
|
|
37063
37130
|
function parse(args2) {
|
|
37064
37131
|
try {
|
|
37065
|
-
const { values, positionals } =
|
|
37132
|
+
const { values, positionals } = parseArgs24({
|
|
37066
37133
|
args: args2,
|
|
37067
37134
|
options: { org: { type: "string" }, json: { type: "boolean" }, yes: { type: "boolean", short: "y" } },
|
|
37068
37135
|
allowPositionals: true,
|
|
@@ -37419,7 +37486,7 @@ var contacts_exports = {};
|
|
|
37419
37486
|
__export(contacts_exports, {
|
|
37420
37487
|
contactsCommand: () => contactsCommand
|
|
37421
37488
|
});
|
|
37422
|
-
import { parseArgs as
|
|
37489
|
+
import { parseArgs as parseArgs25 } from "util";
|
|
37423
37490
|
function usageError3(message) {
|
|
37424
37491
|
return expected(`${message}
|
|
37425
37492
|
|
|
@@ -37427,7 +37494,7 @@ ${USAGE4}`);
|
|
|
37427
37494
|
}
|
|
37428
37495
|
function parse2(args2) {
|
|
37429
37496
|
try {
|
|
37430
|
-
return
|
|
37497
|
+
return parseArgs25({
|
|
37431
37498
|
args: args2,
|
|
37432
37499
|
options: {
|
|
37433
37500
|
org: { type: "string" },
|
|
@@ -37631,7 +37698,7 @@ var dimensions_exports = {};
|
|
|
37631
37698
|
__export(dimensions_exports, {
|
|
37632
37699
|
dimensionsCommand: () => dimensionsCommand
|
|
37633
37700
|
});
|
|
37634
|
-
import { parseArgs as
|
|
37701
|
+
import { parseArgs as parseArgs26 } from "util";
|
|
37635
37702
|
function usageError4(message) {
|
|
37636
37703
|
return expected(`${message}
|
|
37637
37704
|
|
|
@@ -37639,7 +37706,7 @@ ${USAGE5}`);
|
|
|
37639
37706
|
}
|
|
37640
37707
|
function parse3(args2) {
|
|
37641
37708
|
try {
|
|
37642
|
-
return
|
|
37709
|
+
return parseArgs26({
|
|
37643
37710
|
args: args2,
|
|
37644
37711
|
options: {
|
|
37645
37712
|
org: { type: "string" },
|
|
@@ -37793,7 +37860,7 @@ __export(access_exports, {
|
|
|
37793
37860
|
accessCommand: () => accessCommand,
|
|
37794
37861
|
formatExplanation: () => formatExplanation
|
|
37795
37862
|
});
|
|
37796
|
-
import { parseArgs as
|
|
37863
|
+
import { parseArgs as parseArgs27 } from "util";
|
|
37797
37864
|
function usageError5(message) {
|
|
37798
37865
|
return expected(`${message}
|
|
37799
37866
|
|
|
@@ -37801,7 +37868,7 @@ ${USAGE6}`);
|
|
|
37801
37868
|
}
|
|
37802
37869
|
function parse4(args2) {
|
|
37803
37870
|
try {
|
|
37804
|
-
return
|
|
37871
|
+
return parseArgs27({
|
|
37805
37872
|
args: args2,
|
|
37806
37873
|
options: {
|
|
37807
37874
|
hub: { type: "string" },
|
|
@@ -38956,20 +39023,20 @@ __export(knowledge_exports, {
|
|
|
38956
39023
|
knowledgeCommand: () => knowledgeCommand,
|
|
38957
39024
|
parseKnowledgeArgs: () => parseKnowledgeArgs
|
|
38958
39025
|
});
|
|
38959
|
-
import { parseArgs as
|
|
39026
|
+
import { parseArgs as parseArgs28 } from "util";
|
|
38960
39027
|
function usageError6(message) {
|
|
38961
39028
|
return expected(`${message}
|
|
38962
39029
|
${USAGE7}`);
|
|
38963
39030
|
}
|
|
38964
39031
|
function readArgs(args2) {
|
|
38965
39032
|
try {
|
|
38966
|
-
return
|
|
39033
|
+
return parseArgs28({ args: args2, options: OPTIONS2, allowPositionals: true, strict: true });
|
|
38967
39034
|
} catch (err) {
|
|
38968
39035
|
throw usageError6(err instanceof Error ? err.message : String(err));
|
|
38969
39036
|
}
|
|
38970
39037
|
}
|
|
38971
39038
|
function parseKnowledgeArgs(args2) {
|
|
38972
|
-
const [retired] =
|
|
39039
|
+
const [retired] = parseArgs28({ args: args2, options: OPTIONS2, allowPositionals: true, strict: false }).positionals;
|
|
38973
39040
|
if (retired !== void 0 && RETIRED_VERBS.has(retired)) {
|
|
38974
39041
|
throw expected(
|
|
38975
39042
|
`\`wayai knowledge ${retired}\` is retired: knowledge resources are gone, and an organization's documents live in its knowledge base as files (\`wayai files pull\` and \`push\`).`
|
|
@@ -39987,7 +40054,7 @@ async function runSkillInstall(positional) {
|
|
|
39987
40054
|
console.log(`Installed skill "${name}" (${fileCount} file${fileCount === 1 ? "" : "s"}) \u2192 ${relDirs.join(", ")}`);
|
|
39988
40055
|
console.log("Reload your agent (e.g. restart Claude Code) to pick up the skill.");
|
|
39989
40056
|
}
|
|
39990
|
-
function parseScopedTargetFlags(flagArgs,
|
|
40057
|
+
function parseScopedTargetFlags(flagArgs, usage4, opts = {}) {
|
|
39991
40058
|
const scopes = opts.scopes ?? ["all", "org", "hub"];
|
|
39992
40059
|
let all = false;
|
|
39993
40060
|
let orgId;
|
|
@@ -40029,7 +40096,7 @@ function parseScopedTargetFlags(flagArgs, usage3, opts = {}) {
|
|
|
40029
40096
|
const forms = scopes.map((s) => s === "all" ? "--all" : s === "org" ? "--org <org_id>" : "--hub <hub_id>");
|
|
40030
40097
|
const oneOf = forms.length === 2 ? forms.join(" or ") : `${forms.slice(0, -1).join(", ")}, or ${forms[forms.length - 1]}`;
|
|
40031
40098
|
console.error(`Provide exactly ONE of ${oneOf}.`);
|
|
40032
|
-
console.error(
|
|
40099
|
+
console.error(usage4);
|
|
40033
40100
|
process.exit(1);
|
|
40034
40101
|
}
|
|
40035
40102
|
if (all) {
|
|
@@ -40088,12 +40155,12 @@ async function runRepairTeamOrphans(flagArgs) {
|
|
|
40088
40155
|
console.log(`${d.hub_id} | ${d.dangling_team_ids.join(",")} | ${d.team_users_removed}`);
|
|
40089
40156
|
}
|
|
40090
40157
|
}
|
|
40091
|
-
function parseApplyTargetFlags(flagArgs,
|
|
40158
|
+
function parseApplyTargetFlags(flagArgs, usage4, opts = {}) {
|
|
40092
40159
|
const apply = flagArgs.includes("--apply");
|
|
40093
|
-
const target = parseScopedTargetFlags(flagArgs.filter((arg) => arg !== "--apply"),
|
|
40160
|
+
const target = parseScopedTargetFlags(flagArgs.filter((arg) => arg !== "--apply"), usage4, opts);
|
|
40094
40161
|
if (apply && target.dryRun) {
|
|
40095
40162
|
console.error("--apply and --dry-run contradict each other: a run is a dry run unless --apply is given.");
|
|
40096
|
-
console.error(
|
|
40163
|
+
console.error(usage4);
|
|
40097
40164
|
process.exit(1);
|
|
40098
40165
|
}
|
|
40099
40166
|
return { ...target, apply };
|
|
@@ -40303,7 +40370,7 @@ function printVaultReport(data) {
|
|
|
40303
40370
|
console.log(`${data.dry_run ? "Would need" : "Need"} their channel enabled again, on the preview hub (${data.reenable.length}):`);
|
|
40304
40371
|
for (const r of data.reenable) console.log(` hub=${r.hub_id}${r.preview ? " (preview)" : ""} connection=${r.connection_id} bot=${r.bot_username ?? "-"}${r.enabled ? "" : " (disabled)"}`);
|
|
40305
40372
|
}
|
|
40306
|
-
function parseVaultFlags(flagArgs,
|
|
40373
|
+
function parseVaultFlags(flagArgs, usage4, importFlags) {
|
|
40307
40374
|
let orgId;
|
|
40308
40375
|
let connectorId;
|
|
40309
40376
|
let maxPuts;
|
|
@@ -40329,13 +40396,13 @@ function parseVaultFlags(flagArgs, usage3, importFlags) {
|
|
|
40329
40396
|
jsonOutput = true;
|
|
40330
40397
|
} else {
|
|
40331
40398
|
console.error(`Unknown flag: ${flag}`);
|
|
40332
|
-
console.error(
|
|
40399
|
+
console.error(usage4);
|
|
40333
40400
|
process.exit(1);
|
|
40334
40401
|
}
|
|
40335
40402
|
}
|
|
40336
40403
|
if (!orgId || !connectorId) {
|
|
40337
40404
|
console.error("--org and --connector are required.");
|
|
40338
|
-
console.error(
|
|
40405
|
+
console.error(usage4);
|
|
40339
40406
|
process.exit(1);
|
|
40340
40407
|
}
|
|
40341
40408
|
return { orgId, connectorId, maxPuts, approvedFile, apply, yes, jsonOutput };
|
|
@@ -40878,7 +40945,7 @@ function voiceCallPriceLine(data) {
|
|
|
40878
40945
|
return `voice_call_minute_ops: ${value} operation(s) per connected call-minute${value === 0 ? " (calls bill their turns only)" : ""}`;
|
|
40879
40946
|
}
|
|
40880
40947
|
async function runVoiceCallsPrice(flagArgs) {
|
|
40881
|
-
const
|
|
40948
|
+
const usage4 = "wayai admin voice-calls price [--ops-per-minute <n>]";
|
|
40882
40949
|
let raw;
|
|
40883
40950
|
for (let i = 0; i < flagArgs.length; i++) {
|
|
40884
40951
|
if (flagArgs[i] === "--ops-per-minute") {
|
|
@@ -40886,13 +40953,13 @@ async function runVoiceCallsPrice(flagArgs) {
|
|
|
40886
40953
|
i++;
|
|
40887
40954
|
} else {
|
|
40888
40955
|
console.error(`Unknown flag: ${flagArgs[i]}`);
|
|
40889
|
-
console.error(
|
|
40956
|
+
console.error(usage4);
|
|
40890
40957
|
process.exit(1);
|
|
40891
40958
|
}
|
|
40892
40959
|
}
|
|
40893
40960
|
if (raw !== void 0 && (!/^\d+$/.test(raw) || !voiceCallMinuteOps.safeParse(Number(raw)).success)) {
|
|
40894
40961
|
console.error(`--ops-per-minute must be a whole number from 0 to ${MAX_VOICE_CALL_MINUTE_OPS}`);
|
|
40895
|
-
console.error(
|
|
40962
|
+
console.error(usage4);
|
|
40896
40963
|
process.exit(1);
|
|
40897
40964
|
}
|
|
40898
40965
|
const { config, accessToken } = await requireAuth();
|
|
@@ -40924,7 +40991,7 @@ async function runCasesToggle(enable, flagArgs) {
|
|
|
40924
40991
|
console.log(PLATFORM_CONFIG_PROPAGATION_NOTE);
|
|
40925
40992
|
}
|
|
40926
40993
|
async function runCasesCreate(flagArgs) {
|
|
40927
|
-
const
|
|
40994
|
+
const usage4 = "wayai admin cases create --org <org_id> --name <name> [--timezone <zone>] [--json]";
|
|
40928
40995
|
let orgId;
|
|
40929
40996
|
let name;
|
|
40930
40997
|
let timezone;
|
|
@@ -40944,14 +41011,14 @@ async function runCasesCreate(flagArgs) {
|
|
|
40944
41011
|
jsonOutput = true;
|
|
40945
41012
|
} else {
|
|
40946
41013
|
console.error(`Unknown flag: ${flag}`);
|
|
40947
|
-
console.error(
|
|
41014
|
+
console.error(usage4);
|
|
40948
41015
|
process.exit(1);
|
|
40949
41016
|
}
|
|
40950
41017
|
}
|
|
40951
41018
|
const parsed = adminCreateCaseSpaceBody.safeParse({ org_id: orgId, name, ...timezone !== void 0 ? { timezone } : {} });
|
|
40952
41019
|
if (!parsed.success) {
|
|
40953
41020
|
console.error(parsed.error.issues.map((issue) => `--${issue.path[0] === "org_id" ? "org" : issue.path[0]}: ${issue.message}`).join("\n"));
|
|
40954
|
-
console.error(
|
|
41021
|
+
console.error(usage4);
|
|
40955
41022
|
process.exit(1);
|
|
40956
41023
|
}
|
|
40957
41024
|
const { config, accessToken } = await requireAuth();
|
|
@@ -40991,7 +41058,7 @@ async function runCommunitiesToggle(enable, flagArgs) {
|
|
|
40991
41058
|
console.log(PLATFORM_CONFIG_PROPAGATION_NOTE);
|
|
40992
41059
|
}
|
|
40993
41060
|
async function runCommunitiesCreate(flagArgs) {
|
|
40994
|
-
const
|
|
41061
|
+
const usage4 = "wayai admin communities create --org <org_id> --name <name> [--json]";
|
|
40995
41062
|
let orgId;
|
|
40996
41063
|
let name;
|
|
40997
41064
|
let jsonOutput = false;
|
|
@@ -41007,14 +41074,14 @@ async function runCommunitiesCreate(flagArgs) {
|
|
|
41007
41074
|
jsonOutput = true;
|
|
41008
41075
|
} else {
|
|
41009
41076
|
console.error(`Unknown flag: ${flag}`);
|
|
41010
|
-
console.error(
|
|
41077
|
+
console.error(usage4);
|
|
41011
41078
|
process.exit(1);
|
|
41012
41079
|
}
|
|
41013
41080
|
}
|
|
41014
41081
|
const parsed = adminCreateCommunityBody.safeParse({ org_id: orgId, name });
|
|
41015
41082
|
if (!parsed.success) {
|
|
41016
41083
|
console.error(parsed.error.issues.map((issue) => `--${issue.path[0] === "org_id" ? "org" : issue.path[0]}: ${issue.message}`).join("\n"));
|
|
41017
|
-
console.error(
|
|
41084
|
+
console.error(usage4);
|
|
41018
41085
|
process.exit(1);
|
|
41019
41086
|
}
|
|
41020
41087
|
const { config, accessToken } = await requireAuth();
|
|
@@ -41045,7 +41112,7 @@ async function runCommunitiesCreate(flagArgs) {
|
|
|
41045
41112
|
console.log(`Created community ${data.community_id} \u2014 "${data.name}", owned by ${data.org_name} (${data.org_id}).`);
|
|
41046
41113
|
}
|
|
41047
41114
|
async function runCommunitiesDestroy(positional, flagArgs) {
|
|
41048
|
-
const
|
|
41115
|
+
const usage4 = "wayai admin communities destroy <community_id> [--yes] [--json]";
|
|
41049
41116
|
let yes = false;
|
|
41050
41117
|
let jsonOutput = false;
|
|
41051
41118
|
for (const flag of flagArgs) {
|
|
@@ -41055,14 +41122,14 @@ async function runCommunitiesDestroy(positional, flagArgs) {
|
|
|
41055
41122
|
jsonOutput = true;
|
|
41056
41123
|
} else {
|
|
41057
41124
|
console.error(`Unknown flag: ${flag}`);
|
|
41058
|
-
console.error(
|
|
41125
|
+
console.error(usage4);
|
|
41059
41126
|
process.exit(1);
|
|
41060
41127
|
}
|
|
41061
41128
|
}
|
|
41062
41129
|
const parsed = communityIdParam.safeParse({ communityId: positional[0] });
|
|
41063
41130
|
if (positional.length !== 1 || !parsed.success) {
|
|
41064
41131
|
console.error("<community_id> must be one community id (a UUID).");
|
|
41065
|
-
console.error(
|
|
41132
|
+
console.error(usage4);
|
|
41066
41133
|
process.exit(1);
|
|
41067
41134
|
}
|
|
41068
41135
|
const { communityId } = parsed.data;
|
|
@@ -41097,23 +41164,23 @@ async function runCommunitiesDestroy(positional, flagArgs) {
|
|
|
41097
41164
|
function describeGuideHub(hub) {
|
|
41098
41165
|
return `${hub.hub_name ?? "(unnamed)"} (${hub.hub_id}), owned by ${hub.organization_name ?? "(unnamed org)"} (${hub.organization_id})`;
|
|
41099
41166
|
}
|
|
41100
|
-
function parseBooleanFlags(flagArgs,
|
|
41167
|
+
function parseBooleanFlags(flagArgs, usage4, allowed) {
|
|
41101
41168
|
for (const flag of flagArgs) {
|
|
41102
41169
|
if (!allowed.includes(flag)) {
|
|
41103
41170
|
console.error(`Unknown flag: ${flag}`);
|
|
41104
|
-
console.error(
|
|
41171
|
+
console.error(usage4);
|
|
41105
41172
|
process.exit(1);
|
|
41106
41173
|
}
|
|
41107
41174
|
}
|
|
41108
41175
|
return { yes: flagArgs.includes("--yes"), jsonOutput: flagArgs.includes("--json") };
|
|
41109
41176
|
}
|
|
41110
41177
|
async function runGuideSetHub(positional, flagArgs) {
|
|
41111
|
-
const
|
|
41112
|
-
const { yes, jsonOutput } = parseBooleanFlags(flagArgs,
|
|
41178
|
+
const usage4 = "wayai admin guide set-hub <hub_id> [--yes] [--json]";
|
|
41179
|
+
const { yes, jsonOutput } = parseBooleanFlags(flagArgs, usage4, ["--yes", "--json"]);
|
|
41113
41180
|
const parsed = adminSetGuideHubBody.safeParse({ hub_id: positional[0] });
|
|
41114
41181
|
if (positional.length !== 1 || !parsed.success) {
|
|
41115
41182
|
console.error("<hub_id> must be one hub id (a UUID).");
|
|
41116
|
-
console.error(
|
|
41183
|
+
console.error(usage4);
|
|
41117
41184
|
process.exit(1);
|
|
41118
41185
|
}
|
|
41119
41186
|
const hubId = parsed.data.hub_id;
|
|
@@ -41155,12 +41222,12 @@ async function runGuideSetHub(positional, flagArgs) {
|
|
|
41155
41222
|
console.log(PLATFORM_CONFIG_PROPAGATION_NOTE);
|
|
41156
41223
|
}
|
|
41157
41224
|
async function runGuideClear(positional, flagArgs) {
|
|
41158
|
-
const
|
|
41225
|
+
const usage4 = "wayai admin guide clear [--json]";
|
|
41159
41226
|
if (positional.length > 0) {
|
|
41160
|
-
console.error(
|
|
41227
|
+
console.error(usage4);
|
|
41161
41228
|
process.exit(1);
|
|
41162
41229
|
}
|
|
41163
|
-
const { jsonOutput } = parseBooleanFlags(flagArgs,
|
|
41230
|
+
const { jsonOutput } = parseBooleanFlags(flagArgs, usage4, ["--json"]);
|
|
41164
41231
|
const { config, accessToken } = await requireAuth();
|
|
41165
41232
|
const client = new ApiClient({ apiUrl: config.api_url, accessToken });
|
|
41166
41233
|
try {
|
|
@@ -41178,12 +41245,12 @@ async function runGuideClear(positional, flagArgs) {
|
|
|
41178
41245
|
console.log(PLATFORM_CONFIG_PROPAGATION_NOTE);
|
|
41179
41246
|
}
|
|
41180
41247
|
async function runGuideStatus(positional, flagArgs) {
|
|
41181
|
-
const
|
|
41248
|
+
const usage4 = "wayai admin guide status [--json]";
|
|
41182
41249
|
if (positional.length > 0) {
|
|
41183
|
-
console.error(
|
|
41250
|
+
console.error(usage4);
|
|
41184
41251
|
process.exit(1);
|
|
41185
41252
|
}
|
|
41186
|
-
const { jsonOutput } = parseBooleanFlags(flagArgs,
|
|
41253
|
+
const { jsonOutput } = parseBooleanFlags(flagArgs, usage4, ["--json"]);
|
|
41187
41254
|
const { config, accessToken } = await requireAuth();
|
|
41188
41255
|
const client = new ApiClient({ apiUrl: config.api_url, accessToken });
|
|
41189
41256
|
let data;
|
|
@@ -41235,7 +41302,7 @@ function readVaultGateList(data) {
|
|
|
41235
41302
|
}
|
|
41236
41303
|
return parsed;
|
|
41237
41304
|
}
|
|
41238
|
-
function resolveVaultGateConnector(arg,
|
|
41305
|
+
function resolveVaultGateConnector(arg, usage4) {
|
|
41239
41306
|
const wanted = (arg ?? "").trim().toLowerCase();
|
|
41240
41307
|
const ids = VAULT_GATE_CONNECTORS.get(wanted) ?? (vaultGateConnectorName(wanted) ? [wanted] : null);
|
|
41241
41308
|
if (!ids) {
|
|
@@ -41244,7 +41311,7 @@ function resolveVaultGateConnector(arg, usage3) {
|
|
|
41244
41311
|
...[...VAULT_GATE_BY_ID_ONLY].map(([id, name]) => `${id} (${name}, by its id only)`)
|
|
41245
41312
|
].join(", ");
|
|
41246
41313
|
console.error(arg ? `Refused: the credentials vault holds nothing of connector "${arg}". It holds only: ${known}.` : "A connector is required.");
|
|
41247
|
-
console.error(
|
|
41314
|
+
console.error(usage4);
|
|
41248
41315
|
process.exit(1);
|
|
41249
41316
|
}
|
|
41250
41317
|
return ids;
|
|
@@ -41258,12 +41325,12 @@ async function readVaultGateConfig(client) {
|
|
|
41258
41325
|
}
|
|
41259
41326
|
}
|
|
41260
41327
|
async function runVaultGateStatus(positional, flagArgs) {
|
|
41261
|
-
const
|
|
41328
|
+
const usage4 = "wayai admin vault-gate status [--json]";
|
|
41262
41329
|
if (positional.length > 0) {
|
|
41263
|
-
console.error(
|
|
41330
|
+
console.error(usage4);
|
|
41264
41331
|
process.exit(1);
|
|
41265
41332
|
}
|
|
41266
|
-
const { jsonOutput } = parseBooleanFlags(flagArgs,
|
|
41333
|
+
const { jsonOutput } = parseBooleanFlags(flagArgs, usage4, ["--json"]);
|
|
41267
41334
|
const { config, accessToken } = await requireAuth();
|
|
41268
41335
|
const client = new ApiClient({ apiUrl: config.api_url, accessToken });
|
|
41269
41336
|
const ids = await readVaultGateConfig(client);
|
|
@@ -41274,14 +41341,14 @@ async function runVaultGateStatus(positional, flagArgs) {
|
|
|
41274
41341
|
console.log(`vault_connector_ids (platform): ${describeVaultGateList(ids)}`);
|
|
41275
41342
|
}
|
|
41276
41343
|
async function runVaultGateChange(change, positional, flagArgs) {
|
|
41277
|
-
const
|
|
41278
|
-
const { yes, jsonOutput } = parseBooleanFlags(flagArgs,
|
|
41344
|
+
const usage4 = `wayai admin vault-gate ${change} <connector> [--yes] [--json]`;
|
|
41345
|
+
const { yes, jsonOutput } = parseBooleanFlags(flagArgs, usage4, ["--yes", "--json"]);
|
|
41279
41346
|
if (positional.length !== 1) {
|
|
41280
41347
|
console.error("Name one connector.");
|
|
41281
|
-
console.error(
|
|
41348
|
+
console.error(usage4);
|
|
41282
41349
|
process.exit(1);
|
|
41283
41350
|
}
|
|
41284
|
-
const connectorIds = resolveVaultGateConnector(positional[0],
|
|
41351
|
+
const connectorIds = resolveVaultGateConnector(positional[0], usage4);
|
|
41285
41352
|
const entry = connectorIds.map(describeVaultGateEntry).join(", ");
|
|
41286
41353
|
const { config, accessToken } = await requireAuth();
|
|
41287
41354
|
const client = new ApiClient({ apiUrl: config.api_url, accessToken });
|
|
@@ -43324,33 +43391,8 @@ var init_providers = __esm({
|
|
|
43324
43391
|
|
|
43325
43392
|
// src/data/commands/credentials.ts
|
|
43326
43393
|
import { Command as Command6 } from "commander";
|
|
43327
|
-
import { readFileSync as readFileSync21 } from "fs";
|
|
43328
43394
|
function withValueSourceOptions(cmd, what) {
|
|
43329
|
-
return cmd.option(
|
|
43330
|
-
"--file <path>",
|
|
43331
|
-
`Read ${what} from a file and base64-encode it (certificates, keystores, service-account JSON)`
|
|
43332
|
-
).option("--value-stdin", `Read ${what} from stdin (recommended for CI)`).option("--value-prompt", `Prompt for ${what}, masked`);
|
|
43333
|
-
}
|
|
43334
|
-
async function resolveValue(opts, label3) {
|
|
43335
|
-
if (opts.file !== void 0) {
|
|
43336
|
-
if (opts.valueStdin || opts.valuePrompt) {
|
|
43337
|
-
throw expected("--file cannot be combined with --value-stdin or --value-prompt \u2014 pass one.");
|
|
43338
|
-
}
|
|
43339
|
-
try {
|
|
43340
|
-
return readFileSync21(opts.file).toString("base64");
|
|
43341
|
-
} catch (e) {
|
|
43342
|
-
throw expected(`--file ${opts.file}: ${e instanceof Error ? e.message : "could not be read"}`);
|
|
43343
|
-
}
|
|
43344
|
-
}
|
|
43345
|
-
return readSecret(
|
|
43346
|
-
{
|
|
43347
|
-
stdin: opts.valueStdin,
|
|
43348
|
-
prompt: opts.valuePrompt,
|
|
43349
|
-
stdinFlag: "--value-stdin",
|
|
43350
|
-
promptHint: "--value-prompt"
|
|
43351
|
-
},
|
|
43352
|
-
label3
|
|
43353
|
-
);
|
|
43395
|
+
return cmd.option("--file <path>", `Read ${what} from a file (unavailable for now)`).option("--value-stdin", `Read ${what} from stdin (unavailable for now)`).option("--value-prompt", `Prompt for ${what}, masked (unavailable for now)`);
|
|
43354
43396
|
}
|
|
43355
43397
|
function credentialPath(base, id) {
|
|
43356
43398
|
const root = `/v1/${pathSegment(base, "base id")}/credentials`;
|
|
@@ -43361,28 +43403,10 @@ function buildBasesCredentialsCommand() {
|
|
|
43361
43403
|
new Command6("credentials").description("Manage a base's integration credentials")
|
|
43362
43404
|
);
|
|
43363
43405
|
withValueSourceOptions(
|
|
43364
|
-
credentials.command("create").description("Store a credential on this base
|
|
43365
|
-
"--expires-at <date>",
|
|
43366
|
-
"Expiry as ISO-8601 (e.g. 2027-01-01T00:00:00Z) \u2014 informational; nothing is auto-disabled"
|
|
43367
|
-
).option(
|
|
43368
|
-
"--no-sync-to-production",
|
|
43369
|
-
"Do not publish this credential on promote \u2014 production owns its own value"
|
|
43370
|
-
),
|
|
43406
|
+
credentials.command("create").description("Store a credential on this base \u2014 unavailable for now").option("--name <name>", "Credential name").option("--content-type <mime>", "MIME type of the value").option("--expires-at <date>", "Expiry as ISO-8601").option("--no-sync-to-production", "Do not publish this credential on promote (unavailable for now)"),
|
|
43371
43407
|
"the credential value"
|
|
43372
|
-
).action(
|
|
43373
|
-
|
|
43374
|
-
const body = {
|
|
43375
|
-
name: opts.name,
|
|
43376
|
-
value: await resolveValue(opts, "Credential value")
|
|
43377
|
-
};
|
|
43378
|
-
if (opts.contentType) body.content_type = opts.contentType;
|
|
43379
|
-
if (opts.expiresAt) body.expires_at = opts.expiresAt;
|
|
43380
|
-
if (opts.syncToProduction === false) body.sync_to_production = false;
|
|
43381
|
-
const client = await createDataClient();
|
|
43382
|
-
printOutput(
|
|
43383
|
-
await client.request("POST", credentialPath(base), body),
|
|
43384
|
-
outputFormat(this)
|
|
43385
|
-
);
|
|
43408
|
+
).action(() => {
|
|
43409
|
+
throw expected(STORAGE_UNAVAILABLE);
|
|
43386
43410
|
});
|
|
43387
43411
|
credentials.command("list").description("List this base's credentials (values are never returned)").action(async function() {
|
|
43388
43412
|
const base = requireBase(this);
|
|
@@ -43401,42 +43425,13 @@ function buildBasesCredentialsCommand() {
|
|
|
43401
43425
|
);
|
|
43402
43426
|
});
|
|
43403
43427
|
withValueSourceOptions(
|
|
43404
|
-
credentials.command("rotate <id>").description("Install a new
|
|
43428
|
+
credentials.command("rotate <id>").description("Install a new value \u2014 unavailable for now").option("--expires-at <date>", "Set the rotated credential's new expiry (ISO-8601)"),
|
|
43405
43429
|
"the new credential value"
|
|
43406
|
-
).action(
|
|
43407
|
-
|
|
43408
|
-
const client = await createDataClient();
|
|
43409
|
-
const existing = await client.request(
|
|
43410
|
-
"GET",
|
|
43411
|
-
credentialPath(base, id)
|
|
43412
|
-
);
|
|
43413
|
-
if (existing?.managed_by === BASE_CREDENTIAL_MANAGED_BY.ORG_LINK) {
|
|
43414
|
-
throw expected(
|
|
43415
|
-
`"${existing.name ?? id}" mirrors an organization credential, and linking organization credentials into bases is retired. Create a direct credential under another name, and point the references at it; deleting the organization credential removes this row.`
|
|
43416
|
-
);
|
|
43417
|
-
}
|
|
43418
|
-
const body = { value: await resolveValue(opts, "New credential value") };
|
|
43419
|
-
if (opts.expiresAt) body.expires_at = opts.expiresAt;
|
|
43420
|
-
printOutput(
|
|
43421
|
-
await client.request(
|
|
43422
|
-
"POST",
|
|
43423
|
-
`${credentialPath(base, id)}/rotate`,
|
|
43424
|
-
body
|
|
43425
|
-
),
|
|
43426
|
-
outputFormat(this)
|
|
43427
|
-
);
|
|
43430
|
+
).action(() => {
|
|
43431
|
+
throw expected(STORAGE_UNAVAILABLE);
|
|
43428
43432
|
});
|
|
43429
|
-
credentials.command("set-sync <id>").description(
|
|
43430
|
-
"
|
|
43431
|
-
).option("--no-sync-to-production", "Do not publish this credential on promote").action(async function(id, opts) {
|
|
43432
|
-
const base = requireBase(this);
|
|
43433
|
-
const client = await createDataClient();
|
|
43434
|
-
printOutput(
|
|
43435
|
-
await client.request("PUT", credentialPath(base, id), {
|
|
43436
|
-
sync_to_production: opts.syncToProduction
|
|
43437
|
-
}),
|
|
43438
|
-
outputFormat(this)
|
|
43439
|
-
);
|
|
43433
|
+
credentials.command("set-sync <id>").description("Set the promote-time publish flag \u2014 unavailable for now: promotion carries no credential").option("--no-sync-to-production", "Do not publish this credential on promote (unavailable for now)").action(() => {
|
|
43434
|
+
throw expected("Promotion carries no base credential for now, so the publish flag has no effect. Nothing was changed.");
|
|
43440
43435
|
});
|
|
43441
43436
|
credentials.command("delete <id>").description("Delete a direct credential").option("-y, --yes", "Skip confirmation prompt").action(async function(id, opts) {
|
|
43442
43437
|
const base = requireBase(this);
|
|
@@ -43455,6 +43450,7 @@ function buildBasesCredentialsCommand() {
|
|
|
43455
43450
|
});
|
|
43456
43451
|
return credentials;
|
|
43457
43452
|
}
|
|
43453
|
+
var STORAGE_UNAVAILABLE;
|
|
43458
43454
|
var init_credentials = __esm({
|
|
43459
43455
|
"src/data/commands/credentials.ts"() {
|
|
43460
43456
|
"use strict";
|
|
@@ -43463,13 +43459,13 @@ var init_credentials = __esm({
|
|
|
43463
43459
|
init_helpers();
|
|
43464
43460
|
init_utils();
|
|
43465
43461
|
init_expected();
|
|
43466
|
-
|
|
43462
|
+
STORAGE_UNAVAILABLE = "Storing a base credential is unavailable for now: a base's secrets are to be kept in the credentials vault, which does not hold them yet. Nothing was read or stored.";
|
|
43467
43463
|
}
|
|
43468
43464
|
});
|
|
43469
43465
|
|
|
43470
43466
|
// src/data/commands/sql.ts
|
|
43471
43467
|
import { Command as Command7 } from "commander";
|
|
43472
|
-
import { readFileSync as
|
|
43468
|
+
import { readFileSync as readFileSync21 } from "fs";
|
|
43473
43469
|
function buildBasesSqlCommand() {
|
|
43474
43470
|
return withBaseOption(new Command7("sql")).description("Execute a read-only SQL query against base data").argument("[query]", "SQL query (SELECT only)").option("--file <path>", "Read SQL from a file instead of the argument").option(
|
|
43475
43471
|
"--param <kv...>",
|
|
@@ -43479,7 +43475,7 @@ function buildBasesSqlCommand() {
|
|
|
43479
43475
|
let query;
|
|
43480
43476
|
if (opts.file) {
|
|
43481
43477
|
try {
|
|
43482
|
-
query =
|
|
43478
|
+
query = readFileSync21(opts.file, "utf-8").trim();
|
|
43483
43479
|
} catch (e) {
|
|
43484
43480
|
throw expected(`--file ${opts.file}: ${e instanceof Error ? e.message : "could not be read"}`);
|
|
43485
43481
|
}
|
|
@@ -43993,16 +43989,12 @@ function buildBasesCommand() {
|
|
|
43993
43989
|
printOutput(data, outputFormat(this));
|
|
43994
43990
|
const warnings = data?.source_credential_warnings ?? [];
|
|
43995
43991
|
if (warnings.length > 0) {
|
|
43996
|
-
console.warn(
|
|
43997
|
-
"\nINLINE external-source secrets are NOT carried over by promotion \u2014 set these on production before the source will work:"
|
|
43998
|
-
);
|
|
43992
|
+
console.warn("\nSources with an INLINE secret that production will lack:");
|
|
43999
43993
|
for (const w of warnings) console.warn(` - ${sanitizeTerminalText(w.message)}`);
|
|
44000
43994
|
}
|
|
44001
43995
|
const unresolved = data?.unresolved_credentials ?? [];
|
|
44002
43996
|
if (unresolved.length > 0) {
|
|
44003
|
-
console.warn(
|
|
44004
|
-
"\nReferenced credentials production will still lack after this promotion:"
|
|
44005
|
-
);
|
|
43997
|
+
console.warn("\nReferenced credentials production lacks:");
|
|
44006
43998
|
for (const w of unresolved) console.warn(` - ${sanitizeTerminalText(w.message)}`);
|
|
44007
43999
|
}
|
|
44008
44000
|
});
|
|
@@ -44159,7 +44151,7 @@ var init_file_types = __esm({
|
|
|
44159
44151
|
|
|
44160
44152
|
// src/data/commands/files.ts
|
|
44161
44153
|
import { Command as Command11 } from "commander";
|
|
44162
|
-
import { readFileSync as
|
|
44154
|
+
import { readFileSync as readFileSync22, writeFileSync as writeFileSync11 } from "fs";
|
|
44163
44155
|
import { basename as basename29 } from "path";
|
|
44164
44156
|
function renderFileDiff(fileType, filePath3, from, to, d) {
|
|
44165
44157
|
console.log(sanitizeTerminalText(`${fileType}/${filePath3}: v${from} \u2192 v${to}`));
|
|
@@ -44216,7 +44208,7 @@ function buildFilesCommand() {
|
|
|
44216
44208
|
label: opts.label,
|
|
44217
44209
|
metadata: opts.metadata === void 0 ? void 0 : parseData(opts.metadata, "--metadata")
|
|
44218
44210
|
});
|
|
44219
|
-
const body =
|
|
44211
|
+
const body = readFileSync22(opts.file);
|
|
44220
44212
|
const client = await createDataClient();
|
|
44221
44213
|
printOutput(
|
|
44222
44214
|
await client.upload(
|
|
@@ -45305,7 +45297,7 @@ init_errors3();
|
|
|
45305
45297
|
init_mask_secrets();
|
|
45306
45298
|
init_utils();
|
|
45307
45299
|
init_registry();
|
|
45308
|
-
import { readFileSync as
|
|
45300
|
+
import { readFileSync as readFileSync23 } from "fs";
|
|
45309
45301
|
import { fileURLToPath as fileURLToPath2 } from "url";
|
|
45310
45302
|
import { dirname as dirname16, join as join39 } from "path";
|
|
45311
45303
|
|
|
@@ -45463,7 +45455,7 @@ Run \`wayai admin skill install\` to update.`);
|
|
|
45463
45455
|
|
|
45464
45456
|
// src/index.ts
|
|
45465
45457
|
var __dirname = dirname16(fileURLToPath2(import.meta.url));
|
|
45466
|
-
var pkg = JSON.parse(
|
|
45458
|
+
var pkg = JSON.parse(readFileSync23(join39(__dirname, "..", "package.json"), "utf-8"));
|
|
45467
45459
|
var [, , command, ...args] = process.argv;
|
|
45468
45460
|
var isBackgroundRefresh = command === REFRESH_COMMAND;
|
|
45469
45461
|
if (!isBackgroundRefresh) initSentry(command, pkg.version);
|
|
@@ -45647,6 +45639,11 @@ async function main() {
|
|
|
45647
45639
|
await setConnectionCredentialCommand2(args);
|
|
45648
45640
|
break;
|
|
45649
45641
|
}
|
|
45642
|
+
case "bind-seed-connection": {
|
|
45643
|
+
const { bindSeedConnectionCommand: bindSeedConnectionCommand2 } = await Promise.resolve().then(() => (init_bind_seed_connection(), bind_seed_connection_exports));
|
|
45644
|
+
await bindSeedConnectionCommand2(args);
|
|
45645
|
+
break;
|
|
45646
|
+
}
|
|
45650
45647
|
case "org": {
|
|
45651
45648
|
const { orgCommand: orgCommand2 } = await Promise.resolve().then(() => (init_org(), org_exports));
|
|
45652
45649
|
await orgCommand2(args);
|
|
@@ -45744,6 +45741,7 @@ Commands:
|
|
|
45744
45741
|
create-credential Create an organization credential for a service (--service)
|
|
45745
45742
|
update-credential Update / rotate an organization credential (by name)
|
|
45746
45743
|
set-connection-credential Set a connection's credential directly (org link or --field/--stdin), preview or production
|
|
45744
|
+
bind-seed-connection Bind a preview hub's eval seed connection to a base (--connection, --base, token on --stdin; never stored)
|
|
45747
45745
|
pull Fetch config and write local files \u2014 \`hubs/<hub>\`, \`bases/<base>\` or \`communities/<community>\` (also mirrors the linked production hub/base read-only)
|
|
45748
45746
|
push Parse local files, show diff, sync to preview \u2014 \`hubs/<hub>\` or \`bases/<base>\` (creates the hub/base if new); \`communities/<community>\` edits the live community
|
|
45749
45747
|
create [folder] Explicitly create a new hub from an idless folder, then push (--label to name the preview)
|