@astrale-domains/services 0.4.5 → 0.4.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.
Files changed (74) hide show
  1. package/README.md +121 -12
  2. package/dist/schema/index.d.ts +2 -0
  3. package/dist/schema/index.js +1 -0
  4. package/dist/schema/modules/deployment/classes/cloudflare-deployment.d.ts +97 -0
  5. package/dist/schema/modules/deployment/classes/cloudflare-deployment.js +10 -0
  6. package/dist/schema/modules/deployment/classes/deployment-line.d.ts +23 -0
  7. package/dist/schema/modules/deployment/classes/deployment-line.js +24 -0
  8. package/dist/schema/modules/deployment/classes/deployment-on-line.d.ts +17 -0
  9. package/dist/schema/modules/deployment/classes/deployment-on-line.js +11 -0
  10. package/dist/schema/modules/deployment/classes/deployment.d.ts +98 -0
  11. package/dist/schema/modules/deployment/classes/deployment.js +32 -0
  12. package/dist/schema/modules/deployment/classes/index.d.ts +5 -0
  13. package/dist/schema/modules/deployment/classes/index.js +5 -0
  14. package/dist/schema/modules/deployment/classes/line-owned-by.d.ts +26 -0
  15. package/dist/schema/modules/deployment/classes/line-owned-by.js +19 -0
  16. package/dist/schema/modules/deployment/index.d.ts +6 -0
  17. package/dist/schema/modules/deployment/index.js +4 -0
  18. package/dist/schema/modules/deployment/policies/index.d.ts +4 -0
  19. package/dist/schema/modules/deployment/policies/index.js +4 -0
  20. package/dist/schema/modules/deployment/policies/own-deployment.d.ts +2 -0
  21. package/dist/schema/modules/deployment/policies/own-deployment.js +12 -0
  22. package/dist/schema/modules/deployment/policies/own-line.d.ts +5 -0
  23. package/dist/schema/modules/deployment/policies/own-line.js +10 -0
  24. package/dist/schema/modules/deployment/policies/traverse-owned-line-deployment.d.ts +2 -0
  25. package/dist/schema/modules/deployment/policies/traverse-owned-line-deployment.js +7 -0
  26. package/dist/schema/modules/deployment/policies/traverse-owned-line.d.ts +2 -0
  27. package/dist/schema/modules/deployment/policies/traverse-owned-line.js +7 -0
  28. package/dist/schema/modules/deployment/states/deployment-lifecycle.d.ts +27 -0
  29. package/dist/schema/modules/deployment/states/deployment-lifecycle.js +17 -0
  30. package/dist/schema/modules/deployment/states/index.d.ts +2 -0
  31. package/dist/schema/modules/deployment/states/index.js +1 -0
  32. package/dist/schema/modules/deployment/types/deployment-record.d.ts +35 -0
  33. package/dist/schema/modules/deployment/types/deployment-record.js +31 -0
  34. package/dist/schema/modules/deployment/types/deployment-retention.d.ts +13 -0
  35. package/dist/schema/modules/deployment/types/deployment-retention.js +5 -0
  36. package/dist/schema/modules/deployment/types/index.d.ts +4 -0
  37. package/dist/schema/modules/deployment/types/index.js +2 -0
  38. package/dist/schema/modules/service/classes/cloudflare-worker.d.ts +56 -20
  39. package/dist/schema/modules/service/classes/service.d.ts +9 -9
  40. package/dist/schema/modules/service/functions/delete-service-secret.d.ts +1 -1
  41. package/dist/schema/modules/service/functions/delete-service.d.ts +1 -1
  42. package/dist/schema/modules/service/functions/delete-worker-secret.d.ts +1 -1
  43. package/dist/schema/modules/service/functions/delete-worker.d.ts +1 -1
  44. package/dist/schema/modules/service/functions/deploy-cloudflare-worker.d.ts +37 -1
  45. package/dist/schema/modules/service/functions/list-service-logs.d.ts +1 -1
  46. package/dist/schema/modules/service/functions/list-service-schedules.d.ts +1 -1
  47. package/dist/schema/modules/service/functions/list-service-secret-names.d.ts +1 -1
  48. package/dist/schema/modules/service/functions/list-worker-logs.d.ts +1 -1
  49. package/dist/schema/modules/service/functions/list-worker-schedules.d.ts +1 -1
  50. package/dist/schema/modules/service/functions/list-worker-secret-names.d.ts +1 -1
  51. package/dist/schema/modules/service/functions/migrate-worker-ingress.d.ts +1 -1
  52. package/dist/schema/modules/service/functions/replace-service-schedules.d.ts +1 -1
  53. package/dist/schema/modules/service/functions/replace-worker-schedules.d.ts +1 -1
  54. package/dist/schema/modules/service/functions/set-service-secret.d.ts +1 -1
  55. package/dist/schema/modules/service/functions/set-worker-secret.d.ts +1 -1
  56. package/dist/schema/modules/service/index.d.ts +2 -2
  57. package/dist/schema/modules/service/index.js +1 -1
  58. package/dist/schema/modules/service/types/content/index.d.ts +1 -0
  59. package/dist/schema/modules/service/types/content/index.js +1 -0
  60. package/dist/schema/modules/service/types/content/limits.d.ts +7 -0
  61. package/dist/schema/modules/service/types/content/limits.js +7 -0
  62. package/dist/schema/modules/service/types/deploy-cloudflare-worker.d.ts +110 -0
  63. package/dist/schema/modules/service/types/index.d.ts +2 -1
  64. package/dist/schema/modules/service/types/index.js +1 -1
  65. package/dist/schema/modules/service/types/legacy/service-deployment-content.js +15 -0
  66. package/dist/schema/modules/service/types/service-deployment-artifact-module.d.ts +23 -0
  67. package/dist/schema/modules/service/types/service-deployment-artifact-module.js +5 -3
  68. package/dist/schema/modules/service/types/service-deployment-assets.d.ts +36 -0
  69. package/dist/schema/modules/service/types/service-deployment-assets.js +5 -3
  70. package/dist/schema/modules/service/types/service-deployment-content.d.ts +18 -11
  71. package/dist/schema/modules/service/types/service-deployment-content.js +17 -8
  72. package/dist/schema/schema.d.ts +308 -35
  73. package/dist/schema/schema.js +10 -0
  74. package/package.json +10 -11
@@ -0,0 +1,2 @@
1
+ /** A deployment's line relationship is visible only to the holder of that line. */
2
+ export declare const TraverseOwnedLineDeployment: import("@astrale-os/sdk/schema").Policy;
@@ -0,0 +1,7 @@
1
+ import { policy } from '@astrale-os/sdk/schema';
2
+ import { line_owned_by } from '../classes/line-owned-by.js';
3
+ /** A deployment's line relationship is visible only to the holder of that line. */
4
+ export const TraverseOwnedLineDeployment = policy({
5
+ description: 'The subject holds the deployment line at the target of this relationship.',
6
+ match: ({ edge, subject, target }) => edge({ source: target, class: () => line_owned_by, target: subject }),
7
+ });
@@ -0,0 +1,2 @@
1
+ /** A line's holder relationship is visible only to the holder of that line. */
2
+ export declare const TraverseOwnedLine: import("@astrale-os/sdk/schema").Policy;
@@ -0,0 +1,7 @@
1
+ import { policy } from '@astrale-os/sdk/schema';
2
+ import { line_owned_by } from '../classes/line-owned-by.js';
3
+ /** A line's holder relationship is visible only to the holder of that line. */
4
+ export const TraverseOwnedLine = policy({
5
+ description: 'The subject holds the deployment line at the source of this relationship.',
6
+ match: ({ edge, source, subject }) => edge({ source, class: () => line_owned_by, target: subject }),
7
+ });
@@ -0,0 +1,27 @@
1
+ import { type EventOf, type StateOf } from '@astrale-os/sdk/state';
2
+ /**
3
+ * Lifecycle of one immutable deployment. A deployment never changes code: it is created
4
+ * `deploying`, becomes `active` once its script serves, and leaves only by retirement. A failed
5
+ * creation can be retried on the same label; an expired retirement can be revived for the same
6
+ * owner and artifact.
7
+ */
8
+ export declare const deploymentLifecycle: import("@astrale-os/sdk/schema").StateMachine<{
9
+ readonly deploying: {
10
+ readonly activate: "active";
11
+ readonly fail: "failed";
12
+ };
13
+ readonly active: {
14
+ readonly retire: "retiring";
15
+ };
16
+ readonly retiring: {
17
+ readonly completeRetirement: "retired";
18
+ };
19
+ readonly retired: {
20
+ readonly revive: "deploying";
21
+ };
22
+ readonly failed: {
23
+ readonly retry: "deploying";
24
+ };
25
+ }, "deploying">;
26
+ export type DeploymentLifecycle = StateOf<typeof deploymentLifecycle>;
27
+ export type DeploymentLifecycleEvent = EventOf<typeof deploymentLifecycle>;
@@ -0,0 +1,17 @@
1
+ import { stateMachine } from '@astrale-os/sdk/state';
2
+ /**
3
+ * Lifecycle of one immutable deployment. A deployment never changes code: it is created
4
+ * `deploying`, becomes `active` once its script serves, and leaves only by retirement. A failed
5
+ * creation can be retried on the same label; an expired retirement can be revived for the same
6
+ * owner and artifact.
7
+ */
8
+ export const deploymentLifecycle = stateMachine({
9
+ initial: 'deploying',
10
+ transitions: {
11
+ deploying: { activate: 'active', fail: 'failed' },
12
+ active: { retire: 'retiring' },
13
+ retiring: { completeRetirement: 'retired' },
14
+ retired: { revive: 'deploying' },
15
+ failed: { retry: 'deploying' },
16
+ },
17
+ });
@@ -0,0 +1,2 @@
1
+ export { deploymentLifecycle } from './deployment-lifecycle.js';
2
+ export type { DeploymentLifecycle, DeploymentLifecycleEvent } from './deployment-lifecycle.js';
@@ -0,0 +1 @@
1
+ export { deploymentLifecycle } from './deployment-lifecycle.js';
@@ -0,0 +1,35 @@
1
+ import { z } from 'zod';
2
+ /** The commit a deployment was built from, as its deployer declared it. */
3
+ export declare const deploymentCommit: z.ZodObject<{
4
+ sha: z.ZodString;
5
+ dirty: z.ZodBoolean;
6
+ base: z.ZodOptional<z.ZodObject<{
7
+ version: z.ZodString;
8
+ distance: z.ZodNumber;
9
+ }, z.core.$strict>>;
10
+ }, z.core.$strict>;
11
+ /**
12
+ * The `DeploymentRecordV1` one deploy declares, stored as declared beside the facts Services
13
+ * knows itself. Services admits it with the SDK's `acceptDeploymentRecord` before storing it, so
14
+ * this shape only bounds what the graph holds; any extension is a new record version.
15
+ */
16
+ export declare const deploymentRecord: z.ZodObject<{
17
+ format: z.ZodLiteral<"astrale.deployment-record">;
18
+ version: z.ZodLiteral<1>;
19
+ origin: z.ZodString;
20
+ environment: z.ZodString;
21
+ releaseDigest: z.ZodString;
22
+ buildDigest: z.ZodString;
23
+ schemaRevision: z.ZodString;
24
+ configuration: z.ZodString;
25
+ providerScript: z.ZodString;
26
+ commit: z.ZodNullable<z.ZodObject<{
27
+ sha: z.ZodString;
28
+ dirty: z.ZodBoolean;
29
+ base: z.ZodOptional<z.ZodObject<{
30
+ version: z.ZodString;
31
+ distance: z.ZodNumber;
32
+ }, z.core.$strict>>;
33
+ }, z.core.$strict>>;
34
+ }, z.core.$strict>;
35
+ export type DeploymentRecord = z.output<typeof deploymentRecord>;
@@ -0,0 +1,31 @@
1
+ import { fullMatch } from '@astrale-os/sdk/schema';
2
+ import { z } from 'zod';
3
+ const digest = z.string().check(fullMatch('sha256:[0-9a-f]{64}'));
4
+ /** The commit a deployment was built from, as its deployer declared it. */
5
+ export const deploymentCommit = z.strictObject({
6
+ sha: z.string().check(fullMatch('[0-9a-fA-F]{40}')),
7
+ dirty: z.boolean(),
8
+ base: z
9
+ .strictObject({
10
+ version: z.string().min(1).max(256),
11
+ distance: z.number().int().min(0),
12
+ })
13
+ .optional(),
14
+ });
15
+ /**
16
+ * The `DeploymentRecordV1` one deploy declares, stored as declared beside the facts Services
17
+ * knows itself. Services admits it with the SDK's `acceptDeploymentRecord` before storing it, so
18
+ * this shape only bounds what the graph holds; any extension is a new record version.
19
+ */
20
+ export const deploymentRecord = z.strictObject({
21
+ format: z.literal('astrale.deployment-record'),
22
+ version: z.literal(1),
23
+ origin: z.string().min(1).max(253),
24
+ environment: z.string().min(1).max(63),
25
+ releaseDigest: digest,
26
+ buildDigest: digest,
27
+ schemaRevision: digest,
28
+ configuration: digest,
29
+ providerScript: z.string().min(1).max(57),
30
+ commit: deploymentCommit.nullable(),
31
+ });
@@ -0,0 +1,13 @@
1
+ import { z } from 'zod';
2
+ /** A preview expires after 30 days without a call; a published deployment is retained. */
3
+ export declare const deploymentRetention: z.ZodEnum<{
4
+ preview: "preview";
5
+ published: "published";
6
+ }>;
7
+ /** Why a deployment left: an expired preview can be revived, a withdrawn one never. */
8
+ export declare const deploymentRetirement: z.ZodEnum<{
9
+ expired: "expired";
10
+ withdrawn: "withdrawn";
11
+ }>;
12
+ export type DeploymentRetention = z.output<typeof deploymentRetention>;
13
+ export type DeploymentRetirement = z.output<typeof deploymentRetirement>;
@@ -0,0 +1,5 @@
1
+ import { z } from 'zod';
2
+ /** A preview expires after 30 days without a call; a published deployment is retained. */
3
+ export const deploymentRetention = z.enum(['preview', 'published']);
4
+ /** Why a deployment left: an expired preview can be revived, a withdrawn one never. */
5
+ export const deploymentRetirement = z.enum(['expired', 'withdrawn']);
@@ -0,0 +1,4 @@
1
+ export { deploymentCommit, deploymentRecord } from './deployment-record.js';
2
+ export type { DeploymentRecord } from './deployment-record.js';
3
+ export { deploymentRetention, deploymentRetirement } from './deployment-retention.js';
4
+ export type { DeploymentRetention, DeploymentRetirement } from './deployment-retention.js';
@@ -0,0 +1,2 @@
1
+ export { deploymentCommit, deploymentRecord } from './deployment-record.js';
2
+ export { deploymentRetention, deploymentRetirement } from './deployment-retention.js';
@@ -66,22 +66,22 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
66
66
  } | {
67
67
  name: string;
68
68
  };
69
- }, "authorized", false, true>>;
69
+ }, "authorized", false, true, undefined>>;
70
70
  deleteSecret: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
71
71
  name: string;
72
72
  }, {
73
73
  readonly mode: 'value';
74
74
  readonly value: {
75
- ok: true;
76
- } | {
77
75
  kind: "rejected";
78
76
  reason: "binding-unavailable" | "invalid-secret-name" | "service-unavailable";
77
+ } | {
78
+ ok: true;
79
79
  };
80
- }, "authorized", false, true>>;
80
+ }, "authorized", false, true, undefined>>;
81
81
  secrets: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
82
82
  readonly mode: 'value';
83
83
  readonly value: string[];
84
- }, "authorized", false, true>>;
84
+ }, "authorized", false, true, undefined>>;
85
85
  setSchedule: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
86
86
  crons: string[];
87
87
  }, {
@@ -92,11 +92,11 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
92
92
  kind: "rejected";
93
93
  reason: "invalid-schedule" | "service-unavailable";
94
94
  };
95
- }, "authorized", false, true>>;
95
+ }, "authorized", false, true, undefined>>;
96
96
  schedules: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
97
97
  readonly mode: 'value';
98
98
  readonly value: string[];
99
- }, "authorized", false, true>>;
99
+ }, "authorized", false, true, undefined>>;
100
100
  logs: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
101
101
  tail?: number | undefined;
102
102
  since?: number | undefined;
@@ -108,7 +108,7 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
108
108
  level: string;
109
109
  line: string;
110
110
  }[];
111
- }, "authorized", false, true>>;
111
+ }, "authorized", false, true, undefined>>;
112
112
  delete: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
113
113
  readonly mode: 'value';
114
114
  readonly value: {
@@ -117,7 +117,7 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
117
117
  kind: "deleting";
118
118
  retryAfterMs: number;
119
119
  };
120
- }, "authorized", false, true>>;
120
+ }, "authorized", false, true, undefined>>;
121
121
  };
122
122
  }>];
123
123
  readonly properties: {
@@ -153,6 +153,18 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
153
153
  name?: string | undefined;
154
154
  entry?: string | undefined;
155
155
  modules?: ({
156
+ name: string;
157
+ kind?: "data" | "esm" | "text" | "wasm" | undefined;
158
+ content: {
159
+ encoding: "gzip" | "identity";
160
+ decodedSize: number;
161
+ contentBase64: string;
162
+ } | {
163
+ encoding: "gzip" | "identity";
164
+ decodedSize: number;
165
+ contentBase64Chunks: string[];
166
+ };
167
+ } | {
156
168
  contentBase64: string;
157
169
  name: string;
158
170
  kind?: "data" | "esm" | "text" | "wasm" | undefined;
@@ -166,6 +178,18 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
166
178
  release: {
167
179
  entry: string;
168
180
  modules: ({
181
+ name: string;
182
+ kind?: "data" | "esm" | "text" | "wasm" | undefined;
183
+ content: {
184
+ encoding: "gzip" | "identity";
185
+ decodedSize: number;
186
+ contentBase64: string;
187
+ } | {
188
+ encoding: "gzip" | "identity";
189
+ decodedSize: number;
190
+ contentBase64Chunks: string[];
191
+ };
192
+ } | {
169
193
  contentBase64: string;
170
194
  name: string;
171
195
  kind?: "data" | "esm" | "text" | "wasm" | undefined;
@@ -190,6 +214,18 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
190
214
  secrets?: Record<string, string> | undefined;
191
215
  assets?: {
192
216
  files: ({
217
+ path: string;
218
+ contentType?: string | undefined;
219
+ content: {
220
+ encoding: "gzip" | "identity";
221
+ decodedSize: number;
222
+ contentBase64: string;
223
+ } | {
224
+ encoding: "gzip" | "identity";
225
+ decodedSize: number;
226
+ contentBase64Chunks: string[];
227
+ };
228
+ } | {
193
229
  contentBase64: string;
194
230
  path: string;
195
231
  contentType?: string | undefined;
@@ -221,7 +257,7 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
221
257
  reason: "artifact-mode-conflict" | "invalid-deployment" | "service-unavailable";
222
258
  message: string;
223
259
  };
224
- }, "authenticated", true, false>>;
260
+ }, "authenticated", true, false, undefined>>;
225
261
  migrateIngress: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
226
262
  action: "complete" | "detach" | "restore";
227
263
  probe: {
@@ -245,7 +281,7 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
245
281
  kind: "rejected";
246
282
  reason: "missing-location" | "not-detached" | "service-unavailable";
247
283
  };
248
- }, "authorized", false, false>>;
284
+ }, "authorized", false, false, undefined>>;
249
285
  setSecret: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
250
286
  name: string;
251
287
  value: string;
@@ -257,22 +293,22 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
257
293
  } | {
258
294
  name: string;
259
295
  };
260
- }, "authorized", false, false>>;
296
+ }, "authorized", false, false, undefined>>;
261
297
  deleteSecret: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
262
298
  name: string;
263
299
  }, {
264
300
  readonly mode: 'value';
265
301
  readonly value: {
266
- ok: true;
267
- } | {
268
302
  kind: "rejected";
269
303
  reason: "binding-unavailable" | "invalid-secret-name" | "service-unavailable";
304
+ } | {
305
+ ok: true;
270
306
  };
271
- }, "authorized", false, false>>;
307
+ }, "authorized", false, false, undefined>>;
272
308
  secrets: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
273
309
  readonly mode: 'value';
274
310
  readonly value: string[];
275
- }, "authorized", false, false>>;
311
+ }, "authorized", false, false, undefined>>;
276
312
  setSchedule: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
277
313
  crons: string[];
278
314
  }, {
@@ -283,11 +319,11 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
283
319
  kind: "rejected";
284
320
  reason: "invalid-schedule" | "service-unavailable";
285
321
  };
286
- }, "authorized", false, false>>;
322
+ }, "authorized", false, false, undefined>>;
287
323
  schedules: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
288
324
  readonly mode: 'value';
289
325
  readonly value: string[];
290
- }, "authorized", false, false>>;
326
+ }, "authorized", false, false, undefined>>;
291
327
  logs: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
292
328
  tail?: number | undefined;
293
329
  since?: number | undefined;
@@ -299,7 +335,7 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
299
335
  level: string;
300
336
  line: string;
301
337
  }[];
302
- }, "authorized", false, false>>;
338
+ }, "authorized", false, false, undefined>>;
303
339
  delete: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
304
340
  readonly mode: 'value';
305
341
  readonly value: {
@@ -308,7 +344,7 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
308
344
  kind: "deleting";
309
345
  retryAfterMs: number;
310
346
  };
311
- }, "authorized", false, false>>;
347
+ }, "authorized", false, false, undefined>>;
312
348
  };
313
349
  readonly policies: {
314
350
  read: import("@astrale-os/sdk/schema").Policy;
@@ -59,12 +59,12 @@ export declare const Service: import("@astrale-os/sdk/schema").AuthoredNodeClass
59
59
  }, {
60
60
  readonly mode: 'value';
61
61
  readonly value: {
62
+ name: string;
63
+ } | {
62
64
  kind: "rejected";
63
65
  reason: "binding-unavailable" | "invalid-secret-name" | "service-unavailable";
64
- } | {
65
- name: string;
66
66
  };
67
- }, "authorized", false, true>>;
67
+ }, "authorized", false, true, undefined>>;
68
68
  deleteSecret: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
69
69
  name: string;
70
70
  }, {
@@ -75,11 +75,11 @@ export declare const Service: import("@astrale-os/sdk/schema").AuthoredNodeClass
75
75
  } | {
76
76
  ok: true;
77
77
  };
78
- }, "authorized", false, true>>;
78
+ }, "authorized", false, true, undefined>>;
79
79
  secrets: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
80
80
  readonly mode: 'value';
81
81
  readonly value: string[];
82
- }, "authorized", false, true>>;
82
+ }, "authorized", false, true, undefined>>;
83
83
  setSchedule: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
84
84
  crons: string[];
85
85
  }, {
@@ -90,11 +90,11 @@ export declare const Service: import("@astrale-os/sdk/schema").AuthoredNodeClass
90
90
  kind: "rejected";
91
91
  reason: "invalid-schedule" | "service-unavailable";
92
92
  };
93
- }, "authorized", false, true>>;
93
+ }, "authorized", false, true, undefined>>;
94
94
  schedules: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
95
95
  readonly mode: 'value';
96
96
  readonly value: string[];
97
- }, "authorized", false, true>>;
97
+ }, "authorized", false, true, undefined>>;
98
98
  logs: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
99
99
  tail?: number | undefined;
100
100
  since?: number | undefined;
@@ -106,7 +106,7 @@ export declare const Service: import("@astrale-os/sdk/schema").AuthoredNodeClass
106
106
  level: string;
107
107
  line: string;
108
108
  }[];
109
- }, "authorized", false, true>>;
109
+ }, "authorized", false, true, undefined>>;
110
110
  delete: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
111
111
  readonly mode: 'value';
112
112
  readonly value: {
@@ -115,6 +115,6 @@ export declare const Service: import("@astrale-os/sdk/schema").AuthoredNodeClass
115
115
  kind: "deleting";
116
116
  retryAfterMs: number;
117
117
  };
118
- }, "authorized", false, true>>;
118
+ }, "authorized", false, true, undefined>>;
119
119
  };
120
120
  }>;
@@ -8,4 +8,4 @@ export declare const deleteServiceSecret: import("@astrale-os/sdk/schema").Metho
8
8
  kind: "rejected";
9
9
  reason: "binding-unavailable" | "invalid-secret-name" | "service-unavailable";
10
10
  };
11
- }, "authorized", false, true>>;
11
+ }, "authorized", false, true, undefined>>;
@@ -6,4 +6,4 @@ export declare const deleteService: import("@astrale-os/sdk/schema").Method<impo
6
6
  kind: "deleting";
7
7
  retryAfterMs: number;
8
8
  };
9
- }, "authorized", false, true>>;
9
+ }, "authorized", false, true, undefined>>;
@@ -8,4 +8,4 @@ export declare const deleteWorkerSecret: import("@astrale-os/sdk/schema").Method
8
8
  kind: "rejected";
9
9
  reason: "binding-unavailable" | "invalid-secret-name" | "service-unavailable";
10
10
  };
11
- }, "authorized", false, false>>;
11
+ }, "authorized", false, false, undefined>>;
@@ -6,4 +6,4 @@ export declare const deleteWorker: import("@astrale-os/sdk/schema").Method<impor
6
6
  kind: "deleting";
7
7
  retryAfterMs: number;
8
8
  };
9
- }, "authorized", false, false>>;
9
+ }, "authorized", false, false, undefined>>;
@@ -2,6 +2,18 @@ export declare const deployCloudflareWorker: import("@astrale-os/sdk/schema").Me
2
2
  name?: string | undefined;
3
3
  entry?: string | undefined;
4
4
  modules?: ({
5
+ name: string;
6
+ kind?: "data" | "esm" | "text" | "wasm" | undefined;
7
+ content: {
8
+ encoding: "gzip" | "identity";
9
+ decodedSize: number;
10
+ contentBase64: string;
11
+ } | {
12
+ encoding: "gzip" | "identity";
13
+ decodedSize: number;
14
+ contentBase64Chunks: string[];
15
+ };
16
+ } | {
5
17
  contentBase64: string;
6
18
  name: string;
7
19
  kind?: "data" | "esm" | "text" | "wasm" | undefined;
@@ -15,6 +27,18 @@ export declare const deployCloudflareWorker: import("@astrale-os/sdk/schema").Me
15
27
  release: {
16
28
  entry: string;
17
29
  modules: ({
30
+ name: string;
31
+ kind?: "data" | "esm" | "text" | "wasm" | undefined;
32
+ content: {
33
+ encoding: "gzip" | "identity";
34
+ decodedSize: number;
35
+ contentBase64: string;
36
+ } | {
37
+ encoding: "gzip" | "identity";
38
+ decodedSize: number;
39
+ contentBase64Chunks: string[];
40
+ };
41
+ } | {
18
42
  contentBase64: string;
19
43
  name: string;
20
44
  kind?: "data" | "esm" | "text" | "wasm" | undefined;
@@ -39,6 +63,18 @@ export declare const deployCloudflareWorker: import("@astrale-os/sdk/schema").Me
39
63
  secrets?: Record<string, string> | undefined;
40
64
  assets?: {
41
65
  files: ({
66
+ path: string;
67
+ contentType?: string | undefined;
68
+ content: {
69
+ encoding: "gzip" | "identity";
70
+ decodedSize: number;
71
+ contentBase64: string;
72
+ } | {
73
+ encoding: "gzip" | "identity";
74
+ decodedSize: number;
75
+ contentBase64Chunks: string[];
76
+ };
77
+ } | {
42
78
  contentBase64: string;
43
79
  path: string;
44
80
  contentType?: string | undefined;
@@ -70,4 +106,4 @@ export declare const deployCloudflareWorker: import("@astrale-os/sdk/schema").Me
70
106
  reason: "artifact-mode-conflict" | "invalid-deployment" | "service-unavailable";
71
107
  message: string;
72
108
  };
73
- }, "authenticated", true, false>>;
109
+ }, "authenticated", true, false, undefined>>;
@@ -9,4 +9,4 @@ export declare const listServiceLogs: import("@astrale-os/sdk/schema").Method<im
9
9
  level: string;
10
10
  line: string;
11
11
  }[];
12
- }, "authorized", false, true>>;
12
+ }, "authorized", false, true, undefined>>;
@@ -1,4 +1,4 @@
1
1
  export declare const listServiceSchedules: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
2
2
  readonly mode: 'value';
3
3
  readonly value: string[];
4
- }, "authorized", false, true>>;
4
+ }, "authorized", false, true, undefined>>;
@@ -1,4 +1,4 @@
1
1
  export declare const listServiceSecretNames: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
2
2
  readonly mode: 'value';
3
3
  readonly value: string[];
4
- }, "authorized", false, true>>;
4
+ }, "authorized", false, true, undefined>>;
@@ -9,4 +9,4 @@ export declare const listWorkerLogs: import("@astrale-os/sdk/schema").Method<imp
9
9
  level: string;
10
10
  line: string;
11
11
  }[];
12
- }, "authorized", false, false>>;
12
+ }, "authorized", false, false, undefined>>;
@@ -1,4 +1,4 @@
1
1
  export declare const listWorkerSchedules: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
2
2
  readonly mode: 'value';
3
3
  readonly value: string[];
4
- }, "authorized", false, false>>;
4
+ }, "authorized", false, false, undefined>>;
@@ -1,4 +1,4 @@
1
1
  export declare const listWorkerSecretNames: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
2
2
  readonly mode: 'value';
3
3
  readonly value: string[];
4
- }, "authorized", false, false>>;
4
+ }, "authorized", false, false, undefined>>;
@@ -21,4 +21,4 @@ export declare const migrateWorkerIngress: import("@astrale-os/sdk/schema").Meth
21
21
  kind: "rejected";
22
22
  reason: "missing-location" | "not-detached" | "service-unavailable";
23
23
  };
24
- }, "authorized", false, false>>;
24
+ }, "authorized", false, false, undefined>>;
@@ -8,4 +8,4 @@ export declare const replaceServiceSchedules: import("@astrale-os/sdk/schema").M
8
8
  kind: "rejected";
9
9
  reason: "invalid-schedule" | "service-unavailable";
10
10
  };
11
- }, "authorized", false, true>>;
11
+ }, "authorized", false, true, undefined>>;
@@ -8,4 +8,4 @@ export declare const replaceWorkerSchedules: import("@astrale-os/sdk/schema").Me
8
8
  kind: "rejected";
9
9
  reason: "invalid-schedule" | "service-unavailable";
10
10
  };
11
- }, "authorized", false, false>>;
11
+ }, "authorized", false, false, undefined>>;
@@ -9,4 +9,4 @@ export declare const setServiceSecret: import("@astrale-os/sdk/schema").Method<i
9
9
  } | {
10
10
  name: string;
11
11
  };
12
- }, "authorized", false, true>>;
12
+ }, "authorized", false, true, undefined>>;
@@ -9,4 +9,4 @@ export declare const setWorkerSecret: import("@astrale-os/sdk/schema").Method<im
9
9
  kind: "rejected";
10
10
  reason: "binding-unavailable" | "invalid-secret-name" | "service-unavailable";
11
11
  };
12
- }, "authorized", false, false>>;
12
+ }, "authorized", false, false, undefined>>;
@@ -3,5 +3,5 @@ export { deleteService, deleteServiceSecret, deployCloudflareWorker, listService
3
3
  export { OwnService, TraverseOwnedService } from './policies/index.js';
4
4
  export { serviceLifecycle } from './states/index.js';
5
5
  export type { ServiceLifecycle, ServiceLifecycleEvent } from './states/index.js';
6
- export { artifact, artifactModule, assetBundle, assetFile, deployedService, deploymentRejection, deployServiceInput, deployServiceOutput, resourceLimits, revisionedDeployment, PORTABLE_BASE64_CHUNK_SIZE, } from './types/index.js';
7
- export type { ArtifactModule, AssetBundle, DeployServiceInput, DeployServiceOutput, ResourceLimits, } from './types/index.js';
6
+ export { artifact, artifactModule, assetBundle, assetFile, deployedService, deploymentRejection, deployServiceInput, deployServiceOutput, resourceLimits, revisionedDeployment, PORTABLE_BASE64_CHUNK_SIZE, MAX_ASSET_DECODED_SIZE, MAX_DEPLOYMENT_DECODED_SIZE, MAX_MODULE_DECODED_SIZE, } from './types/index.js';
7
+ export type { ArtifactModule, AssetBundle, DeployServiceInput, DeployServiceOutput, ResourceLimits, ServiceDeploymentContent, } from './types/index.js';
@@ -2,4 +2,4 @@ export { CloudflareWorker, Service, service_owned_by } from './classes/index.js'
2
2
  export { deleteService, deleteServiceSecret, deployCloudflareWorker, listServiceLogs, listServiceSchedules, listServiceSecretNames, replaceServiceSchedules, setServiceSecret, } from './functions/index.js';
3
3
  export { OwnService, TraverseOwnedService } from './policies/index.js';
4
4
  export { serviceLifecycle } from './states/index.js';
5
- export { artifact, artifactModule, assetBundle, assetFile, deployedService, deploymentRejection, deployServiceInput, deployServiceOutput, resourceLimits, revisionedDeployment, PORTABLE_BASE64_CHUNK_SIZE, } from './types/index.js';
5
+ export { artifact, artifactModule, assetBundle, assetFile, deployedService, deploymentRejection, deployServiceInput, deployServiceOutput, resourceLimits, revisionedDeployment, PORTABLE_BASE64_CHUNK_SIZE, MAX_ASSET_DECODED_SIZE, MAX_DEPLOYMENT_DECODED_SIZE, MAX_MODULE_DECODED_SIZE, } from './types/index.js';
@@ -0,0 +1 @@
1
+ export { PORTABLE_BASE64_CHUNK_SIZE, MAX_MODULE_BASE64_SIZE, MAX_ASSET_BASE64_SIZE, MAX_MODULE_DECODED_SIZE, MAX_ASSET_DECODED_SIZE, MAX_DEPLOYMENT_DECODED_SIZE, } from './limits.js';
@@ -0,0 +1 @@
1
+ export { PORTABLE_BASE64_CHUNK_SIZE, MAX_MODULE_BASE64_SIZE, MAX_ASSET_BASE64_SIZE, MAX_MODULE_DECODED_SIZE, MAX_ASSET_DECODED_SIZE, MAX_DEPLOYMENT_DECODED_SIZE, } from './limits.js';