@keystrokehq/cli 0.1.69 → 0.1.71
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/dist-0KLRARak.mjs +3 -0
- package/dist/{dist-CoQNnzgA.mjs → dist-B8-vsCpf.mjs} +3 -3
- package/dist/{dist-CoQNnzgA.mjs.map → dist-B8-vsCpf.mjs.map} +1 -1
- package/dist/{dist-FSvBEy0q.mjs → dist-Bzry3J_e.mjs} +8 -4
- package/dist/{dist-FSvBEy0q.mjs.map → dist-Bzry3J_e.mjs.map} +1 -1
- package/dist/{dist-DUQegnm2.mjs → dist-Dfp6ywxz.mjs} +2 -2
- package/dist/{dist-DUQegnm2.mjs.map → dist-Dfp6ywxz.mjs.map} +1 -1
- package/dist/{dist-29Z9arBu.mjs → dist-JMNXwH6-.mjs} +19 -18
- package/dist/dist-JMNXwH6-.mjs.map +1 -0
- package/dist/index.mjs +107 -90
- package/dist/index.mjs.map +1 -1
- package/dist/{maybe-auto-update-b1ORh8RQ.mjs → maybe-auto-update-Du4nv2q8.mjs} +95 -21
- package/dist/maybe-auto-update-Du4nv2q8.mjs.map +1 -0
- package/dist/skills-bundle/_AGENTS.md +4 -2
- package/dist/{version-FhdOja-n.mjs → version-DEkbd-OE.mjs} +39 -113
- package/dist/version-DEkbd-OE.mjs.map +1 -0
- package/package.json +5 -4
- package/dist/dist-29Z9arBu.mjs.map +0 -1
- package/dist/dist-LTmhfQex.mjs +0 -3
- package/dist/maybe-auto-update-b1ORh8RQ.mjs.map +0 -1
- package/dist/version-FhdOja-n.mjs.map +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { n as __require, t as __commonJSMin } from "./chunk-DiodbrVj.mjs";
|
|
3
|
-
import { Ar as _null, Br as number, Dr as ZodType, Fr as discriminatedUnion, Gr as string, Kr as union, Lr as lazy, Mr as array, Nr as boolean$1, Or as _enum, Pr as custom, Rr as literal, Ur as preprocess, Vr as object, Wr as record, Xr as toJSONSchema, br as parseStoredRouteManifest, cn as PublicModelsResponseSchema, dn as ROUTE_MANIFEST_REL_PATH, dr as credentialInputSchema, gr as normalizeCredentialList, kr as _function, nt as DEFAULT_CLOUD_PLATFORM_ORIGIN, sn as PromptResponseSchema, xr as requiredDisplayTextSchema } from "./dist-
|
|
4
|
-
import "./dist-
|
|
3
|
+
import { Ar as _null, Br as number, Dr as ZodType, Fr as discriminatedUnion, Gr as string, Kr as union, Lr as lazy, Mr as array, Nr as boolean$1, Or as _enum, Pr as custom, Rr as literal, Ur as preprocess, Vr as object, Wr as record, Xr as toJSONSchema, br as parseStoredRouteManifest, cn as PublicModelsResponseSchema, dn as ROUTE_MANIFEST_REL_PATH, dr as credentialInputSchema, gr as normalizeCredentialList, kr as _function, nt as DEFAULT_CLOUD_PLATFORM_ORIGIN, sn as PromptResponseSchema, xr as requiredDisplayTextSchema } from "./dist-Bzry3J_e.mjs";
|
|
4
|
+
import "./dist-Dfp6ywxz.mjs";
|
|
5
5
|
import "./chunk-BZUGFHVS-CPWRFwK8.mjs";
|
|
6
6
|
import "./chunk-DLL7UR66-BUYgzxnR.mjs";
|
|
7
7
|
import "./chunk-TN7HHBQW-CSB_R-XD.mjs";
|
|
@@ -243,7 +243,7 @@ function isCommentLine(line) {
|
|
|
243
243
|
return line.startsWith("//") || line.startsWith("/*") || line.startsWith("*");
|
|
244
244
|
}
|
|
245
245
|
//#endregion
|
|
246
|
-
//#region ../../packages/sandbox/dist/files-
|
|
246
|
+
//#region ../../packages/sandbox/dist/files-EBXCAi4v.mjs
|
|
247
247
|
const SandboxModeSchema = _enum(["in-process", "vm"]);
|
|
248
248
|
const SandboxFileContentSchema = object({
|
|
249
249
|
path: string(),
|
|
@@ -29677,7 +29677,7 @@ const triggerSourceSchema$1 = preprocess(normalizeLegacySlugFields$1, discrimina
|
|
|
29677
29677
|
kind: literal("webhook"),
|
|
29678
29678
|
...baseSourceShape$1,
|
|
29679
29679
|
endpoint: string().min(1),
|
|
29680
|
-
|
|
29680
|
+
payload: zodSchema$1,
|
|
29681
29681
|
filter: zodSchema$1.optional(),
|
|
29682
29682
|
passes: _function()
|
|
29683
29683
|
}),
|
|
@@ -30204,11 +30204,16 @@ function findNonExportableSchemaNode(schema, path = "schema") {
|
|
|
30204
30204
|
function formatSchemaExportError(cause) {
|
|
30205
30205
|
return /* @__PURE__ */ new Error(`Cannot export schema to JSON Schema: ${cause}. ${EXPORT_FIX}`);
|
|
30206
30206
|
}
|
|
30207
|
-
function schemaToJson(schema) {
|
|
30207
|
+
function schemaToJson(schema, options = {}) {
|
|
30208
30208
|
const issue = findNonExportableSchemaNode(schema);
|
|
30209
30209
|
if (issue) throw formatSchemaExportError(issue);
|
|
30210
30210
|
try {
|
|
30211
|
-
return toJSONSchema(schema, {
|
|
30211
|
+
return toJSONSchema(schema, {
|
|
30212
|
+
target: "openapi-3.0",
|
|
30213
|
+
...options.allowAdditionalProperties ? { override(ctx) {
|
|
30214
|
+
if (ctx.jsonSchema.type === "object") ctx.jsonSchema.additionalProperties = true;
|
|
30215
|
+
} } : {}
|
|
30216
|
+
});
|
|
30212
30217
|
} catch (error) {
|
|
30213
30218
|
throw formatSchemaExportError(error instanceof Error ? error.message : String(error));
|
|
30214
30219
|
}
|
|
@@ -30274,10 +30279,7 @@ function serializeRouteManifest(manifest) {
|
|
|
30274
30279
|
attachmentIds: entry.attachmentIds,
|
|
30275
30280
|
moduleFile: entry.moduleFile,
|
|
30276
30281
|
...entry.sourceHash ? { sourceHash: entry.sourceHash } : {},
|
|
30277
|
-
attachmentSchemas: Object.fromEntries(Object.entries(entry.attachmentSchemas).map(([attachmentSlug, schemas]) => [attachmentSlug, {
|
|
30278
|
-
requestSchema: schemaToJson(schemas.request),
|
|
30279
|
-
...schemas.filter ? { filterSchema: schemaToJson(schemas.filter) } : {}
|
|
30280
|
-
}])),
|
|
30282
|
+
attachmentSchemas: Object.fromEntries(Object.entries(entry.attachmentSchemas).map(([attachmentSlug, schemas]) => [attachmentSlug, { requestSchema: schemaToJson(schemas.request, { allowAdditionalProperties: true }) }])),
|
|
30281
30283
|
...entry.attachmentMeta ? { attachmentMeta: entry.attachmentMeta } : {}
|
|
30282
30284
|
});
|
|
30283
30285
|
break;
|
|
@@ -30374,7 +30376,7 @@ const triggerSourceSchema = preprocess(normalizeLegacySlugFields, discriminatedU
|
|
|
30374
30376
|
kind: literal("webhook"),
|
|
30375
30377
|
...baseSourceShape,
|
|
30376
30378
|
endpoint: string().min(1),
|
|
30377
|
-
|
|
30379
|
+
payload: zodSchema,
|
|
30378
30380
|
filter: zodSchema.optional(),
|
|
30379
30381
|
passes: _function()
|
|
30380
30382
|
}),
|
|
@@ -30478,9 +30480,11 @@ function webhookSchemaEntriesFromBindings(bindings) {
|
|
|
30478
30480
|
return bindings.flatMap((binding) => {
|
|
30479
30481
|
const source = binding.discovered.attachment.source;
|
|
30480
30482
|
if (source.kind !== "webhook") return [];
|
|
30483
|
+
const triggerId = typeof binding.options.triggerId === "string" ? binding.options.triggerId : void 0;
|
|
30481
30484
|
return [{
|
|
30482
30485
|
attachmentSlug: binding.discovered.slug,
|
|
30483
|
-
|
|
30486
|
+
...triggerId ? { triggerId } : {},
|
|
30487
|
+
payload: source.payload,
|
|
30484
30488
|
...source.filter ? { filter: source.filter } : {}
|
|
30485
30489
|
}];
|
|
30486
30490
|
});
|
|
@@ -30488,17 +30492,14 @@ function webhookSchemaEntriesFromBindings(bindings) {
|
|
|
30488
30492
|
function webhookMatchSchemaForBindings(bindings) {
|
|
30489
30493
|
const schemas = bindings.flatMap((binding) => {
|
|
30490
30494
|
const source = binding.discovered.attachment.source;
|
|
30491
|
-
return source.kind === "webhook" ? [source.
|
|
30495
|
+
return source.kind === "webhook" ? [source.payload] : [];
|
|
30492
30496
|
});
|
|
30493
30497
|
if (schemas.length === 0) throw new Error("Webhook bindings require at least one webhook source");
|
|
30494
30498
|
if (schemas.length === 1) return schemas[0];
|
|
30495
30499
|
return union(schemas);
|
|
30496
30500
|
}
|
|
30497
30501
|
function webhookManifestAttachmentSchemasFromBindings(bindings) {
|
|
30498
|
-
return Object.fromEntries(webhookSchemaEntriesFromBindings(bindings).map((entry) => [entry.attachmentSlug, {
|
|
30499
|
-
request: entry.request,
|
|
30500
|
-
...entry.filter ? { filter: entry.filter } : {}
|
|
30501
|
-
}]));
|
|
30502
|
+
return Object.fromEntries(webhookSchemaEntriesFromBindings(bindings).map((entry) => [entry.attachmentSlug, { request: entry.payload }]));
|
|
30502
30503
|
}
|
|
30503
30504
|
async function discoverWorkflowEntries(workflowsDir, options) {
|
|
30504
30505
|
const files = await discoverModuleFileEntries(workflowsDir, {
|
|
@@ -30993,4 +30994,4 @@ async function emitStoredRouteManifestForProject(projectRoot) {
|
|
|
30993
30994
|
//#endregion
|
|
30994
30995
|
export { validatePollGroups as A, attachmentSlugFromRecord as B, pollRouteFromSourceSlug as C, validateAttachmentTargets as D, toStoredRouteManifest as E, webhookManifestAttachmentSchemasFromBindings as F, packAssetDirs as G, computeCallSiteIds as H, webhookMatchSchemaForBindings as I, entryIdFromFile as J, discoverEntries as K, webhookRouteFromEndpoint as L, validateTriggerAttachments as M, validateUniqueAttachmentSlugs as N, validateImportedTriggerAttachment as O, validateUniqueTriggerSourceSlugs as P, walkTypeScriptFiles as Q, workflowKeyForAttachment as R, pollGroupRouteFromId as S, serializeRouteManifest as T, diagnoseWorkflowSource as U, classifyCall as V, locateWorkflow as W, shouldSkipKeystrokeModuleFile as X, readKeystrokeIgnoreDirective as Y, validateUniqueModuleKeys as Z, importAgentDefinition as _, buildStoredRouteManifestForProject as a, persistStoredRouteManifest as b, collectAgentAppSlugs as c, discoverAgentEntries as d, discoverSkillManifestEntries as f, emitStoredRouteManifestForProject as g, discoverWorkflows as h, buildPollGroups as i, validateProjectModules as j, validateImportedWorkflowDefinition as k, collectAgentToolSlugs as l, discoverWorkflowEntries as m, agentManifestEntry as n, buildStoredRouteManifestFromContext as o, discoverTriggerAttachments as p, discoverModuleFileEntries as q, agentRouteFromKey as r, buildWebhookBindingsByRoute as s, agentKeyForAttachment as t, countAgentCredentials as u, importTriggerAttachments as v, schemaToJson as w, pollGroupId as x, importWorkflowDefinition as y, workflowRouteFromKey as z };
|
|
30995
30996
|
|
|
30996
|
-
//# sourceMappingURL=dist-
|
|
30997
|
+
//# sourceMappingURL=dist-JMNXwH6-.mjs.map
|