@astrale-domains/services 0.4.5 → 0.4.7

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 (126) hide show
  1. package/README.md +278 -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 +463 -0
  5. package/dist/schema/modules/deployment/classes/cloudflare-deployment.js +30 -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 +189 -0
  11. package/dist/schema/modules/deployment/classes/deployment.js +56 -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/errors/deployment-hosting-unavailable.d.ts +7 -0
  17. package/dist/schema/modules/deployment/errors/deployment-hosting-unavailable.js +8 -0
  18. package/dist/schema/modules/deployment/errors/deployment-label-not-found.d.ts +12 -0
  19. package/dist/schema/modules/deployment/errors/deployment-label-not-found.js +11 -0
  20. package/dist/schema/modules/deployment/errors/deployment-not-found.d.ts +10 -0
  21. package/dist/schema/modules/deployment/errors/deployment-not-found.js +11 -0
  22. package/dist/schema/modules/deployment/errors/deployment-registry-only.d.ts +11 -0
  23. package/dist/schema/modules/deployment/errors/deployment-registry-only.js +12 -0
  24. package/dist/schema/modules/deployment/errors/index.d.ts +4 -0
  25. package/dist/schema/modules/deployment/errors/index.js +4 -0
  26. package/dist/schema/modules/deployment/functions/deploy-cloudflare-deployment.d.ts +170 -0
  27. package/dist/schema/modules/deployment/functions/deploy-cloudflare-deployment.js +14 -0
  28. package/dist/schema/modules/deployment/functions/describe-deployment-hosting.d.ts +8 -0
  29. package/dist/schema/modules/deployment/functions/describe-deployment-hosting.js +11 -0
  30. package/dist/schema/modules/deployment/functions/expire-deployment-previews.d.ts +16 -0
  31. package/dist/schema/modules/deployment/functions/expire-deployment-previews.js +14 -0
  32. package/dist/schema/modules/deployment/functions/index.d.ts +11 -0
  33. package/dist/schema/modules/deployment/functions/index.js +11 -0
  34. package/dist/schema/modules/deployment/functions/list-cloudflare-deployment-secret-names.d.ts +5 -0
  35. package/dist/schema/modules/deployment/functions/list-cloudflare-deployment-secret-names.js +4 -0
  36. package/dist/schema/modules/deployment/functions/list-cloudflare-deployments.d.ts +58 -0
  37. package/dist/schema/modules/deployment/functions/list-cloudflare-deployments.js +10 -0
  38. package/dist/schema/modules/deployment/functions/list-deployment-secret-names.d.ts +4 -0
  39. package/dist/schema/modules/deployment/functions/list-deployment-secret-names.js +6 -0
  40. package/dist/schema/modules/deployment/functions/read-deployment-last-calls.d.ts +10 -0
  41. package/dist/schema/modules/deployment/functions/read-deployment-last-calls.js +13 -0
  42. package/dist/schema/modules/deployment/functions/retain-deployment.d.ts +12 -0
  43. package/dist/schema/modules/deployment/functions/retain-deployment.js +13 -0
  44. package/dist/schema/modules/deployment/functions/retire-deployment.d.ts +23 -0
  45. package/dist/schema/modules/deployment/functions/retire-deployment.js +17 -0
  46. package/dist/schema/modules/deployment/functions/set-cloudflare-deployment-secret.d.ts +18 -0
  47. package/dist/schema/modules/deployment/functions/set-cloudflare-deployment-secret.js +7 -0
  48. package/dist/schema/modules/deployment/functions/set-deployment-secret.d.ts +14 -0
  49. package/dist/schema/modules/deployment/functions/set-deployment-secret.js +3 -0
  50. package/dist/schema/modules/deployment/index.d.ts +8 -0
  51. package/dist/schema/modules/deployment/index.js +6 -0
  52. package/dist/schema/modules/deployment/policies/act-for-organization.d.ts +6 -0
  53. package/dist/schema/modules/deployment/policies/act-for-organization.js +10 -0
  54. package/dist/schema/modules/deployment/policies/index.d.ts +5 -0
  55. package/dist/schema/modules/deployment/policies/index.js +5 -0
  56. package/dist/schema/modules/deployment/policies/own-deployment.d.ts +2 -0
  57. package/dist/schema/modules/deployment/policies/own-deployment.js +12 -0
  58. package/dist/schema/modules/deployment/policies/own-line.d.ts +5 -0
  59. package/dist/schema/modules/deployment/policies/own-line.js +10 -0
  60. package/dist/schema/modules/deployment/policies/traverse-owned-line-deployment.d.ts +2 -0
  61. package/dist/schema/modules/deployment/policies/traverse-owned-line-deployment.js +7 -0
  62. package/dist/schema/modules/deployment/policies/traverse-owned-line.d.ts +2 -0
  63. package/dist/schema/modules/deployment/policies/traverse-owned-line.js +7 -0
  64. package/dist/schema/modules/deployment/states/deployment-lifecycle.d.ts +30 -0
  65. package/dist/schema/modules/deployment/states/deployment-lifecycle.js +19 -0
  66. package/dist/schema/modules/deployment/states/index.d.ts +2 -0
  67. package/dist/schema/modules/deployment/states/index.js +1 -0
  68. package/dist/schema/modules/deployment/types/deployment-hosting.d.ts +94 -0
  69. package/dist/schema/modules/deployment/types/deployment-hosting.js +19 -0
  70. package/dist/schema/modules/deployment/types/deployment-record.d.ts +35 -0
  71. package/dist/schema/modules/deployment/types/deployment-record.js +31 -0
  72. package/dist/schema/modules/deployment/types/deployment-request.d.ts +161 -0
  73. package/dist/schema/modules/deployment/types/deployment-request.js +40 -0
  74. package/dist/schema/modules/deployment/types/deployment-response.d.ts +109 -0
  75. package/dist/schema/modules/deployment/types/deployment-response.js +36 -0
  76. package/dist/schema/modules/deployment/types/deployment-retention.d.ts +49 -0
  77. package/dist/schema/modules/deployment/types/deployment-retention.js +45 -0
  78. package/dist/schema/modules/deployment/types/deployment-retire.d.ts +30 -0
  79. package/dist/schema/modules/deployment/types/deployment-retire.js +18 -0
  80. package/dist/schema/modules/deployment/types/deployment-secret-digest.d.ts +17 -0
  81. package/dist/schema/modules/deployment/types/deployment-secret-digest.js +14 -0
  82. package/dist/schema/modules/deployment/types/deployment-secret.d.ts +59 -0
  83. package/dist/schema/modules/deployment/types/deployment-secret.js +52 -0
  84. package/dist/schema/modules/deployment/types/deployment-summary.d.ts +165 -0
  85. package/dist/schema/modules/deployment/types/deployment-summary.js +38 -0
  86. package/dist/schema/modules/deployment/types/frozen-configuration.d.ts +52 -0
  87. package/dist/schema/modules/deployment/types/frozen-configuration.js +55 -0
  88. package/dist/schema/modules/deployment/types/index.d.ts +20 -0
  89. package/dist/schema/modules/deployment/types/index.js +10 -0
  90. package/dist/schema/modules/service/classes/cloudflare-worker.d.ts +60 -24
  91. package/dist/schema/modules/service/classes/service.d.ts +7 -7
  92. package/dist/schema/modules/service/functions/delete-service-secret.d.ts +1 -1
  93. package/dist/schema/modules/service/functions/delete-service.d.ts +1 -1
  94. package/dist/schema/modules/service/functions/delete-worker-secret.d.ts +1 -1
  95. package/dist/schema/modules/service/functions/delete-worker.d.ts +1 -1
  96. package/dist/schema/modules/service/functions/deploy-cloudflare-worker.d.ts +37 -1
  97. package/dist/schema/modules/service/functions/list-service-logs.d.ts +1 -1
  98. package/dist/schema/modules/service/functions/list-service-schedules.d.ts +1 -1
  99. package/dist/schema/modules/service/functions/list-service-secret-names.d.ts +1 -1
  100. package/dist/schema/modules/service/functions/list-worker-logs.d.ts +1 -1
  101. package/dist/schema/modules/service/functions/list-worker-schedules.d.ts +1 -1
  102. package/dist/schema/modules/service/functions/list-worker-secret-names.d.ts +1 -1
  103. package/dist/schema/modules/service/functions/migrate-worker-ingress.d.ts +1 -1
  104. package/dist/schema/modules/service/functions/replace-service-schedules.d.ts +1 -1
  105. package/dist/schema/modules/service/functions/replace-worker-schedules.d.ts +1 -1
  106. package/dist/schema/modules/service/functions/set-service-secret.d.ts +1 -1
  107. package/dist/schema/modules/service/functions/set-worker-secret.d.ts +3 -3
  108. package/dist/schema/modules/service/index.d.ts +2 -2
  109. package/dist/schema/modules/service/index.js +1 -1
  110. package/dist/schema/modules/service/types/content/index.d.ts +1 -0
  111. package/dist/schema/modules/service/types/content/index.js +1 -0
  112. package/dist/schema/modules/service/types/content/limits.d.ts +7 -0
  113. package/dist/schema/modules/service/types/content/limits.js +7 -0
  114. package/dist/schema/modules/service/types/deploy-cloudflare-worker.d.ts +110 -0
  115. package/dist/schema/modules/service/types/index.d.ts +2 -1
  116. package/dist/schema/modules/service/types/index.js +1 -1
  117. package/dist/schema/modules/service/types/legacy/service-deployment-content.js +22 -0
  118. package/dist/schema/modules/service/types/service-deployment-artifact-module.d.ts +23 -0
  119. package/dist/schema/modules/service/types/service-deployment-artifact-module.js +5 -3
  120. package/dist/schema/modules/service/types/service-deployment-assets.d.ts +36 -0
  121. package/dist/schema/modules/service/types/service-deployment-assets.js +5 -3
  122. package/dist/schema/modules/service/types/service-deployment-content.d.ts +18 -11
  123. package/dist/schema/modules/service/types/service-deployment-content.js +17 -8
  124. package/dist/schema/schema.d.ts +740 -23
  125. package/dist/schema/schema.js +11 -0
  126. package/package.json +15 -11
@@ -0,0 +1,165 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * `DeploymentSummaryV1`: what Services knows of one deployment beside the record its deployer
4
+ * declared. It names a deployment by its label and URL, never by a provider version.
5
+ */
6
+ export declare const deploymentSummary: z.ZodObject<{
7
+ id: z.ZodString;
8
+ url: z.ZodString;
9
+ label: z.ZodString;
10
+ line: z.ZodString;
11
+ owner: z.ZodString;
12
+ state: z.ZodEnum<{
13
+ active: "active";
14
+ deploying: "deploying";
15
+ failed: "failed";
16
+ retired: "retired";
17
+ retiring: "retiring";
18
+ }>;
19
+ retention: z.ZodEnum<{
20
+ preview: "preview";
21
+ published: "published";
22
+ }>;
23
+ createdAt: z.ZodString;
24
+ lastCallAt: z.ZodOptional<z.ZodString>;
25
+ expiresAt: z.ZodOptional<z.ZodString>;
26
+ retiredAt: z.ZodOptional<z.ZodString>;
27
+ retirement: z.ZodOptional<z.ZodEnum<{
28
+ expired: "expired";
29
+ withdrawn: "withdrawn";
30
+ }>>;
31
+ signingKeyId: z.ZodString;
32
+ record: z.ZodObject<{
33
+ format: z.ZodLiteral<"astrale.deployment-record">;
34
+ version: z.ZodLiteral<1>;
35
+ origin: z.ZodString;
36
+ environment: z.ZodString;
37
+ releaseDigest: z.ZodString;
38
+ buildDigest: z.ZodString;
39
+ schemaRevision: z.ZodString;
40
+ configuration: z.ZodString;
41
+ providerScript: z.ZodString;
42
+ commit: z.ZodNullable<z.ZodObject<{
43
+ sha: z.ZodString;
44
+ dirty: z.ZodBoolean;
45
+ base: z.ZodOptional<z.ZodObject<{
46
+ version: z.ZodString;
47
+ distance: z.ZodNumber;
48
+ }, z.core.$strict>>;
49
+ }, z.core.$strict>>;
50
+ }, z.core.$strict>;
51
+ }, z.core.$strict>;
52
+ /**
53
+ * A deployment Services lists although this Services SDK no longer admits the record or the
54
+ * configuration it stores, for instance after a stricter decoder: the facts Services owns, and the
55
+ * record exactly as stored, any JSON value. Its consumer admits that record itself; Services never
56
+ * acts on such a deployment.
57
+ */
58
+ export declare const unadmittedDeploymentSummary: z.ZodObject<{
59
+ id: z.ZodString;
60
+ url: z.ZodString;
61
+ label: z.ZodString;
62
+ line: z.ZodString;
63
+ owner: z.ZodString;
64
+ state: z.ZodEnum<{
65
+ active: "active";
66
+ deploying: "deploying";
67
+ failed: "failed";
68
+ retired: "retired";
69
+ retiring: "retiring";
70
+ }>;
71
+ retention: z.ZodEnum<{
72
+ preview: "preview";
73
+ published: "published";
74
+ }>;
75
+ createdAt: z.ZodString;
76
+ lastCallAt: z.ZodOptional<z.ZodString>;
77
+ expiresAt: z.ZodOptional<z.ZodString>;
78
+ retiredAt: z.ZodOptional<z.ZodString>;
79
+ retirement: z.ZodOptional<z.ZodEnum<{
80
+ expired: "expired";
81
+ withdrawn: "withdrawn";
82
+ }>>;
83
+ signingKeyId: z.ZodString;
84
+ record: z.ZodUnknown;
85
+ }, z.core.$strict>;
86
+ /**
87
+ * One listed deployment: a `DeploymentSummaryV1` whose record Services admits, or an unadmitted one
88
+ * whose record is typed as JSON.
89
+ */
90
+ export declare const listedDeploymentSummary: z.ZodUnion<readonly [z.ZodObject<{
91
+ id: z.ZodString;
92
+ url: z.ZodString;
93
+ label: z.ZodString;
94
+ line: z.ZodString;
95
+ owner: z.ZodString;
96
+ state: z.ZodEnum<{
97
+ active: "active";
98
+ deploying: "deploying";
99
+ failed: "failed";
100
+ retired: "retired";
101
+ retiring: "retiring";
102
+ }>;
103
+ retention: z.ZodEnum<{
104
+ preview: "preview";
105
+ published: "published";
106
+ }>;
107
+ createdAt: z.ZodString;
108
+ lastCallAt: z.ZodOptional<z.ZodString>;
109
+ expiresAt: z.ZodOptional<z.ZodString>;
110
+ retiredAt: z.ZodOptional<z.ZodString>;
111
+ retirement: z.ZodOptional<z.ZodEnum<{
112
+ expired: "expired";
113
+ withdrawn: "withdrawn";
114
+ }>>;
115
+ signingKeyId: z.ZodString;
116
+ record: z.ZodObject<{
117
+ format: z.ZodLiteral<"astrale.deployment-record">;
118
+ version: z.ZodLiteral<1>;
119
+ origin: z.ZodString;
120
+ environment: z.ZodString;
121
+ releaseDigest: z.ZodString;
122
+ buildDigest: z.ZodString;
123
+ schemaRevision: z.ZodString;
124
+ configuration: z.ZodString;
125
+ providerScript: z.ZodString;
126
+ commit: z.ZodNullable<z.ZodObject<{
127
+ sha: z.ZodString;
128
+ dirty: z.ZodBoolean;
129
+ base: z.ZodOptional<z.ZodObject<{
130
+ version: z.ZodString;
131
+ distance: z.ZodNumber;
132
+ }, z.core.$strict>>;
133
+ }, z.core.$strict>>;
134
+ }, z.core.$strict>;
135
+ }, z.core.$strict>, z.ZodObject<{
136
+ id: z.ZodString;
137
+ url: z.ZodString;
138
+ label: z.ZodString;
139
+ line: z.ZodString;
140
+ owner: z.ZodString;
141
+ state: z.ZodEnum<{
142
+ active: "active";
143
+ deploying: "deploying";
144
+ failed: "failed";
145
+ retired: "retired";
146
+ retiring: "retiring";
147
+ }>;
148
+ retention: z.ZodEnum<{
149
+ preview: "preview";
150
+ published: "published";
151
+ }>;
152
+ createdAt: z.ZodString;
153
+ lastCallAt: z.ZodOptional<z.ZodString>;
154
+ expiresAt: z.ZodOptional<z.ZodString>;
155
+ retiredAt: z.ZodOptional<z.ZodString>;
156
+ retirement: z.ZodOptional<z.ZodEnum<{
157
+ expired: "expired";
158
+ withdrawn: "withdrawn";
159
+ }>>;
160
+ signingKeyId: z.ZodString;
161
+ record: z.ZodUnknown;
162
+ }, z.core.$strict>]>;
163
+ export type DeploymentSummary = z.output<typeof deploymentSummary>;
164
+ export type UnadmittedDeploymentSummary = z.output<typeof unadmittedDeploymentSummary>;
165
+ export type ListedDeploymentSummary = z.output<typeof listedDeploymentSummary>;
@@ -0,0 +1,38 @@
1
+ import { z } from 'zod';
2
+ import { deploymentRecord } from './deployment-record.js';
3
+ import { deploymentRetention, deploymentRetirement } from './deployment-retention.js';
4
+ /** An ISO 8601 instant, as the graph's instant values read. */
5
+ const instant = z.string().min(1).max(64);
6
+ /**
7
+ * `DeploymentSummaryV1`: what Services knows of one deployment beside the record its deployer
8
+ * declared. It names a deployment by its label and URL, never by a provider version.
9
+ */
10
+ export const deploymentSummary = z.strictObject({
11
+ id: z.string().min(1),
12
+ url: z.string().min(1).max(2_048),
13
+ label: z.string().min(1).max(63),
14
+ line: z.string().min(1).max(40),
15
+ /** The Identity path of the organisation holding the line. */
16
+ owner: z.string().min(1),
17
+ state: z.enum(['deploying', 'active', 'retiring', 'retired', 'failed']),
18
+ retention: deploymentRetention,
19
+ createdAt: instant,
20
+ lastCallAt: instant.optional(),
21
+ expiresAt: instant.optional(),
22
+ retiredAt: instant.optional(),
23
+ retirement: deploymentRetirement.optional(),
24
+ signingKeyId: z.string().min(1).max(128),
25
+ record: deploymentRecord,
26
+ });
27
+ /**
28
+ * A deployment Services lists although this Services SDK no longer admits the record or the
29
+ * configuration it stores, for instance after a stricter decoder: the facts Services owns, and the
30
+ * record exactly as stored, any JSON value. Its consumer admits that record itself; Services never
31
+ * acts on such a deployment.
32
+ */
33
+ export const unadmittedDeploymentSummary = deploymentSummary.extend({ record: z.unknown() });
34
+ /**
35
+ * One listed deployment: a `DeploymentSummaryV1` whose record Services admits, or an unadmitted one
36
+ * whose record is typed as JSON.
37
+ */
38
+ export const listedDeploymentSummary = z.union([deploymentSummary, unadmittedDeploymentSummary]);
@@ -0,0 +1,52 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * The `FrozenConfigurationV1` (`@astrale-os/sdk/deployment/address`) one deployment freezes beside
4
+ * its build: the author's plain variables, the execution settings and the durable Workflow options
5
+ * it declares, the runtime, the services and dispatch namespaces it binds and the names of the
6
+ * secrets it binds, never their values. Its digest and the build digest make the deployment's
7
+ * address. This shape only bounds what a request and the graph carry; the SDK's
8
+ * `configurationDigest` admits its canonical form, and a hosted deployment's admission decides
9
+ * which bindings Services hosts (`acceptDeploymentRequest`).
10
+ */
11
+ export declare const frozenConfiguration: z.ZodObject<{
12
+ format: z.ZodLiteral<"astrale.deployment.configuration">;
13
+ version: z.ZodLiteral<1>;
14
+ vars: z.ZodRecord<z.ZodString, z.ZodString>;
15
+ settings: z.ZodObject<{
16
+ maximumRequestBytes: z.ZodNumber;
17
+ invocationTimeoutMs: z.ZodNumber;
18
+ tokenExchange: z.ZodUnion<readonly [z.ZodLiteral<false>, z.ZodObject<{
19
+ maximumLifetimeSeconds: z.ZodNumber;
20
+ }, z.core.$strict>]>;
21
+ durableOptions: z.ZodOptional<z.ZodObject<{
22
+ retentionMs: z.ZodOptional<z.ZodNumber>;
23
+ retry: z.ZodOptional<z.ZodObject<{
24
+ initialIntervalMs: z.ZodOptional<z.ZodNumber>;
25
+ maxAttempts: z.ZodOptional<z.ZodNumber>;
26
+ maxIntervalMs: z.ZodOptional<z.ZodNumber>;
27
+ }, z.core.$strict>>;
28
+ stepTimeoutMs: z.ZodOptional<z.ZodNumber>;
29
+ }, z.core.$strict>>;
30
+ }, z.core.$strict>;
31
+ runtime: z.ZodObject<{
32
+ compatibilityDate: z.ZodString;
33
+ compatibilityFlags: z.ZodArray<z.ZodString>;
34
+ }, z.core.$strict>;
35
+ bindings: z.ZodObject<{
36
+ services: z.ZodArray<z.ZodObject<{
37
+ name: z.ZodString;
38
+ service: z.ZodString;
39
+ }, z.core.$strict>>;
40
+ dispatchNamespaces: z.ZodArray<z.ZodObject<{
41
+ name: z.ZodString;
42
+ namespace: z.ZodString;
43
+ }, z.core.$strict>>;
44
+ secrets: z.ZodArray<z.ZodString>;
45
+ }, z.core.$strict>;
46
+ router: z.ZodUnion<readonly [z.ZodLiteral<false>, z.ZodObject<{
47
+ service: z.ZodString;
48
+ hostSuffix: z.ZodString;
49
+ minLabels: z.ZodNumber;
50
+ }, z.core.$strict>]>;
51
+ }, z.core.$strict>;
52
+ export type FrozenConfiguration = z.output<typeof frozenConfiguration>;
@@ -0,0 +1,55 @@
1
+ import { z } from 'zod';
2
+ const name = z.string().min(1).max(128);
3
+ const positive = z.number().int().min(1);
4
+ /**
5
+ * The `FrozenConfigurationV1` (`@astrale-os/sdk/deployment/address`) one deployment freezes beside
6
+ * its build: the author's plain variables, the execution settings and the durable Workflow options
7
+ * it declares, the runtime, the services and dispatch namespaces it binds and the names of the
8
+ * secrets it binds, never their values. Its digest and the build digest make the deployment's
9
+ * address. This shape only bounds what a request and the graph carry; the SDK's
10
+ * `configurationDigest` admits its canonical form, and a hosted deployment's admission decides
11
+ * which bindings Services hosts (`acceptDeploymentRequest`).
12
+ */
13
+ export const frozenConfiguration = z.strictObject({
14
+ format: z.literal('astrale.deployment.configuration'),
15
+ version: z.literal(1),
16
+ vars: z.record(name, z.string().max(64 * 1024)),
17
+ settings: z.strictObject({
18
+ maximumRequestBytes: z.number().int().min(1),
19
+ invocationTimeoutMs: z.number().int().min(1),
20
+ tokenExchange: z.union([
21
+ z.literal(false),
22
+ z.strictObject({ maximumLifetimeSeconds: z.number().int().min(1) }),
23
+ ]),
24
+ durableOptions: z
25
+ .strictObject({
26
+ retentionMs: positive.optional(),
27
+ retry: z
28
+ .strictObject({
29
+ initialIntervalMs: positive.optional(),
30
+ maxAttempts: positive.optional(),
31
+ maxIntervalMs: positive.optional(),
32
+ })
33
+ .optional(),
34
+ stepTimeoutMs: positive.optional(),
35
+ })
36
+ .optional(),
37
+ }),
38
+ runtime: z.strictObject({
39
+ compatibilityDate: z.string().min(1).max(32),
40
+ compatibilityFlags: z.array(name).max(64),
41
+ }),
42
+ bindings: z.strictObject({
43
+ services: z.array(z.strictObject({ name, service: name })).max(32),
44
+ dispatchNamespaces: z.array(z.strictObject({ name, namespace: name })).max(32),
45
+ secrets: z.array(name).max(64),
46
+ }),
47
+ router: z.union([
48
+ z.literal(false),
49
+ z.strictObject({
50
+ service: name,
51
+ hostSuffix: z.string().max(253),
52
+ minLabels: z.number().int().min(0).max(127),
53
+ }),
54
+ ]),
55
+ });
@@ -0,0 +1,20 @@
1
+ export { deploymentHosting, listDeploymentsInput, listDeploymentsOutput, } from './deployment-hosting.js';
2
+ export type { DeploymentHosting } from './deployment-hosting.js';
3
+ export { deploymentCommit, deploymentRecord } from './deployment-record.js';
4
+ export type { DeploymentRecord } from './deployment-record.js';
5
+ export { deploymentRequest } from './deployment-request.js';
6
+ export type { DeploymentRequest } from './deployment-request.js';
7
+ export { deploymentRejection, deploymentRejectionReason, deploymentResponse, } from './deployment-response.js';
8
+ export type { DeploymentRejection, DeploymentRejectionReason, DeploymentResponse, } from './deployment-response.js';
9
+ export { deploymentLabel, deploymentRetention, deploymentRetirement, expirePreviewsInput, expirePreviewsOutput, lastCallsInput, lastCallsOutput, MAXIMUM_LAST_CALL_LABELS, MAXIMUM_PREVIEW_EXPIRY_WRITES, retainInput, retainOutput, } from './deployment-retention.js';
10
+ export type { DeploymentRetention, DeploymentRetirement, ExpirePreviewsResult, } from './deployment-retention.js';
11
+ export { retireDeploymentInput, retireDeploymentOutput } from './deployment-retire.js';
12
+ export type { RetireDeploymentResult } from './deployment-retire.js';
13
+ export { deploymentSecretRejection, listDeploymentSecretNamesContract, setDeploymentSecretContract, } from './deployment-secret.js';
14
+ export type { DeploymentSecretRejection } from './deployment-secret.js';
15
+ export { deploymentSecretDigest, deploymentSecretDigests } from './deployment-secret-digest.js';
16
+ export type { DeploymentSecretDigest } from './deployment-secret-digest.js';
17
+ export { deploymentSummary, listedDeploymentSummary, unadmittedDeploymentSummary, } from './deployment-summary.js';
18
+ export type { DeploymentSummary, ListedDeploymentSummary, UnadmittedDeploymentSummary, } from './deployment-summary.js';
19
+ export { frozenConfiguration } from './frozen-configuration.js';
20
+ export type { FrozenConfiguration } from './frozen-configuration.js';
@@ -0,0 +1,10 @@
1
+ export { deploymentHosting, listDeploymentsInput, listDeploymentsOutput, } from './deployment-hosting.js';
2
+ export { deploymentCommit, deploymentRecord } from './deployment-record.js';
3
+ export { deploymentRequest } from './deployment-request.js';
4
+ export { deploymentRejection, deploymentRejectionReason, deploymentResponse, } from './deployment-response.js';
5
+ export { deploymentLabel, deploymentRetention, deploymentRetirement, expirePreviewsInput, expirePreviewsOutput, lastCallsInput, lastCallsOutput, MAXIMUM_LAST_CALL_LABELS, MAXIMUM_PREVIEW_EXPIRY_WRITES, retainInput, retainOutput, } from './deployment-retention.js';
6
+ export { retireDeploymentInput, retireDeploymentOutput } from './deployment-retire.js';
7
+ export { deploymentSecretRejection, listDeploymentSecretNamesContract, setDeploymentSecretContract, } from './deployment-secret.js';
8
+ export { deploymentSecretDigest, deploymentSecretDigests } from './deployment-secret-digest.js';
9
+ export { deploymentSummary, listedDeploymentSummary, unadmittedDeploymentSummary, } from './deployment-summary.js';
10
+ export { frozenConfiguration } from './frozen-configuration.js';
@@ -61,27 +61,27 @@ export declare const CloudflareWorker: import("@astrale-os/sdk/schema").Authored
61
61
  }, {
62
62
  readonly mode: 'value';
63
63
  readonly value: {
64
+ name: string;
65
+ } | {
64
66
  kind: "rejected";
65
67
  reason: "binding-unavailable" | "invalid-secret-name" | "service-unavailable";
66
- } | {
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,34 +281,34 @@ 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;
252
288
  }, {
253
289
  readonly mode: 'value';
254
290
  readonly value: {
291
+ name: string;
292
+ } | {
255
293
  kind: "rejected";
256
294
  reason: "binding-unavailable" | "invalid-secret-name" | "service-unavailable";
257
- } | {
258
- 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;
@@ -64,7 +64,7 @@ export declare const Service: import("@astrale-os/sdk/schema").AuthoredNodeClass
64
64
  } | {
65
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>>;