@hasna/skills 0.5.4 → 0.5.6
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/README.md +72 -7
- package/bin/index.js +2181 -901
- package/bin/mcp.js +1960 -508
- package/bin/migrate.js +176 -4
- package/bin/server.js +419 -195
- package/bin/worker.js +413 -222
- package/dist/admin-contract.js +174 -176
- package/dist/cli/commands/private-publications.d.ts +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +1074 -421
- package/dist/lib/fleet-credentials.d.ts +6 -1
- package/dist/lib/home-adoption.d.ts +2 -7
- package/dist/lib/mcp-contracts.d.ts +1 -0
- package/dist/lib/private-publication-customer.d.ts +10 -0
- package/dist/lib/private-publication-recovery.d.ts +43 -0
- package/dist/lib/remote-account.d.ts +5 -0
- package/dist/lib/remote-auth.d.ts +3 -0
- package/dist/lib/remote-client.d.ts +2 -2
- package/dist/lib/remote-private-publications.d.ts +74 -0
- package/dist/mcp/private-publication-tools.d.ts +2 -0
- package/dist/sdk/execution/dispatchers/ecs.d.ts +25 -14
- package/dist/sdk/index.d.ts +2 -0
- package/dist/sdk/index.js +1291 -617
- package/dist/server/types.d.ts +2 -0
- package/dist/storage.js +39 -37
- package/package.json +1 -1
package/dist/server/types.d.ts
CHANGED
|
@@ -213,6 +213,8 @@ export interface ServerSkillVersion {
|
|
|
213
213
|
createdAt: string;
|
|
214
214
|
}
|
|
215
215
|
export interface PublishSkillInput {
|
|
216
|
+
/** Internal boot-seed precondition: never revive or replace non-bundled records. */
|
|
217
|
+
seedBundledOnly?: true;
|
|
216
218
|
principal: ApiPrincipal;
|
|
217
219
|
slug: string;
|
|
218
220
|
displayName: string;
|
package/dist/storage.js
CHANGED
|
@@ -19,14 +19,12 @@ var __toESM = (mod, isNodeMode, target) => {
|
|
|
19
19
|
}
|
|
20
20
|
target = mod != null ? __create(__getProtoOf(mod)) : {};
|
|
21
21
|
const to = isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target;
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
});
|
|
29
|
-
}
|
|
22
|
+
for (let key of __getOwnPropNames(mod))
|
|
23
|
+
if (!__hasOwnProp.call(to, key))
|
|
24
|
+
__defProp(to, key, {
|
|
25
|
+
get: __accessProp.bind(mod, key),
|
|
26
|
+
enumerable: true
|
|
27
|
+
});
|
|
30
28
|
if (canCache)
|
|
31
29
|
cache.set(mod, to);
|
|
32
30
|
return to;
|
|
@@ -1033,11 +1031,15 @@ function normalizeHeaders(headers) {
|
|
|
1033
1031
|
}
|
|
1034
1032
|
return result;
|
|
1035
1033
|
}
|
|
1034
|
+
function encodeAwsUriComponent(value) {
|
|
1035
|
+
return encodeURIComponent(value).replace(/[!'()*]/g, (char) => `%${char.charCodeAt(0).toString(16).toUpperCase()}`);
|
|
1036
|
+
}
|
|
1036
1037
|
function canonicalizeQuery(params) {
|
|
1037
|
-
|
|
1038
|
+
const compare = (a, b) => a < b ? -1 : a > b ? 1 : 0;
|
|
1039
|
+
return [...params.entries()].map(([key, value]) => [encodeAwsUriComponent(key), encodeAwsUriComponent(value)]).sort(([aKey, aValue], [bKey, bValue]) => compare(aKey, bKey) || compare(aValue, bValue)).map(([key, value]) => `${key}=${value}`).join("&");
|
|
1038
1040
|
}
|
|
1039
1041
|
function encodeUriPath(pathname) {
|
|
1040
|
-
return pathname.split("/").map((segment) =>
|
|
1042
|
+
return pathname.split("/").map((segment) => encodeAwsUriComponent(decodeURIComponent(segment))).join("/");
|
|
1041
1043
|
}
|
|
1042
1044
|
function toAmzDate(date) {
|
|
1043
1045
|
return date.toISOString().replace(/[:-]|\.\d{3}/g, "");
|
|
@@ -1072,32 +1074,32 @@ function toArrayBuffer(bytes) {
|
|
|
1072
1074
|
return buffer;
|
|
1073
1075
|
}
|
|
1074
1076
|
export {
|
|
1075
|
-
|
|
1076
|
-
SKILLS_NATIVE_STORAGE_FALLBACK_ENV,
|
|
1077
|
-
SKILLS_STORAGE_ENV,
|
|
1078
|
-
SKILLS_STORAGE_FALLBACK_ENV,
|
|
1079
|
-
SKILLS_STORAGE_TABLES,
|
|
1080
|
-
STORAGE_TABLES,
|
|
1081
|
-
SkillsPostgresSyncStore,
|
|
1082
|
-
SkillsS3ObjectStore,
|
|
1083
|
-
buildSkillsS3ObjectUrl,
|
|
1084
|
-
createSkillsPostgresSyncStore,
|
|
1085
|
-
createSkillsS3ObjectStore,
|
|
1086
|
-
createSkillsSnapshotSyncRecord,
|
|
1087
|
-
exportSkillsLocalSnapshot,
|
|
1088
|
-
getSkillsNativeStorageStatus,
|
|
1089
|
-
getSkillsStorageDatabaseEnv,
|
|
1090
|
-
getSkillsStorageDatabaseUrl,
|
|
1091
|
-
getSkillsStorageStatus,
|
|
1092
|
-
getStorageDatabaseEnv,
|
|
1093
|
-
getStorageDatabaseUrl,
|
|
1094
|
-
getStorageStatus,
|
|
1095
|
-
importSkillsLocalSnapshot,
|
|
1096
|
-
planSkillsS3SnapshotUpload,
|
|
1097
|
-
resolveSkillsNativeStorageConfig,
|
|
1098
|
-
resolveStorageConfig,
|
|
1099
|
-
signSkillsAwsV4Request,
|
|
1100
|
-
skillsPostgresSyncSchemaSql,
|
|
1077
|
+
uploadSkillsSnapshotFilesToS3,
|
|
1101
1078
|
storageCapabilities,
|
|
1102
|
-
|
|
1079
|
+
skillsPostgresSyncSchemaSql,
|
|
1080
|
+
signSkillsAwsV4Request,
|
|
1081
|
+
resolveStorageConfig,
|
|
1082
|
+
resolveSkillsNativeStorageConfig,
|
|
1083
|
+
planSkillsS3SnapshotUpload,
|
|
1084
|
+
importSkillsLocalSnapshot,
|
|
1085
|
+
getStorageStatus,
|
|
1086
|
+
getStorageDatabaseUrl,
|
|
1087
|
+
getStorageDatabaseEnv,
|
|
1088
|
+
getSkillsStorageStatus,
|
|
1089
|
+
getSkillsStorageDatabaseUrl,
|
|
1090
|
+
getSkillsStorageDatabaseEnv,
|
|
1091
|
+
getSkillsNativeStorageStatus,
|
|
1092
|
+
exportSkillsLocalSnapshot,
|
|
1093
|
+
createSkillsSnapshotSyncRecord,
|
|
1094
|
+
createSkillsS3ObjectStore,
|
|
1095
|
+
createSkillsPostgresSyncStore,
|
|
1096
|
+
buildSkillsS3ObjectUrl,
|
|
1097
|
+
SkillsS3ObjectStore,
|
|
1098
|
+
SkillsPostgresSyncStore,
|
|
1099
|
+
STORAGE_TABLES,
|
|
1100
|
+
SKILLS_STORAGE_TABLES,
|
|
1101
|
+
SKILLS_STORAGE_FALLBACK_ENV,
|
|
1102
|
+
SKILLS_STORAGE_ENV,
|
|
1103
|
+
SKILLS_NATIVE_STORAGE_FALLBACK_ENV,
|
|
1104
|
+
SKILLS_NATIVE_STORAGE_ENV
|
|
1103
1105
|
};
|