@distilled.cloud/stackit 0.0.0-placeholder → 1.0.0-rc.13
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/LICENSE +201 -0
- package/README.md +34 -0
- package/lib/credentials.d.ts +29 -0
- package/lib/credentials.d.ts.map +1 -0
- package/lib/credentials.js +49 -0
- package/lib/credentials.js.map +1 -0
- package/lib/errors.d.ts +36 -0
- package/lib/errors.d.ts.map +1 -0
- package/lib/errors.js +26 -0
- package/lib/errors.js.map +1 -0
- package/lib/index.d.ts +30 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +30 -0
- package/lib/index.js.map +1 -0
- package/lib/pagination.d.ts +9 -0
- package/lib/pagination.d.ts.map +1 -0
- package/lib/pagination.js +48 -0
- package/lib/pagination.js.map +1 -0
- package/lib/protocol.d.ts +32 -0
- package/lib/protocol.d.ts.map +1 -0
- package/lib/protocol.js +148 -0
- package/lib/protocol.js.map +1 -0
- package/lib/response-validation.test.d.ts +4 -0
- package/lib/response-validation.test.d.ts.map +1 -0
- package/lib/response-validation.test.js +31 -0
- package/lib/response-validation.test.js.map +1 -0
- package/lib/retry.d.ts +31 -0
- package/lib/retry.d.ts.map +1 -0
- package/lib/retry.js +31 -0
- package/lib/retry.js.map +1 -0
- package/lib/services/alb.d.ts +603 -0
- package/lib/services/alb.d.ts.map +1 -0
- package/lib/services/alb.js +562 -0
- package/lib/services/alb.js.map +1 -0
- package/lib/services/alb_waf.d.ts +526 -0
- package/lib/services/alb_waf.d.ts.map +1 -0
- package/lib/services/alb_waf.js +545 -0
- package/lib/services/alb_waf.js.map +1 -0
- package/lib/services/authorization.d.ts +251 -0
- package/lib/services/authorization.d.ts.map +1 -0
- package/lib/services/authorization.js +353 -0
- package/lib/services/authorization.js.map +1 -0
- package/lib/services/automation.d.ts +358 -0
- package/lib/services/automation.d.ts.map +1 -0
- package/lib/services/automation.js +426 -0
- package/lib/services/automation.js.map +1 -0
- package/lib/services/cdn.d.ts +1239 -0
- package/lib/services/cdn.d.ts.map +1 -0
- package/lib/services/cdn.js +992 -0
- package/lib/services/cdn.js.map +1 -0
- package/lib/services/certificates.d.ts +201 -0
- package/lib/services/certificates.d.ts.map +1 -0
- package/lib/services/certificates.js +197 -0
- package/lib/services/certificates.js.map +1 -0
- package/lib/services/cost.d.ts +222 -0
- package/lib/services/cost.d.ts.map +1 -0
- package/lib/services/cost.js +188 -0
- package/lib/services/cost.js.map +1 -0
- package/lib/services/dns.d.ts +875 -0
- package/lib/services/dns.d.ts.map +1 -0
- package/lib/services/dns.js +854 -0
- package/lib/services/dns.js.map +1 -0
- package/lib/services/dremio.d.ts +358 -0
- package/lib/services/dremio.d.ts.map +1 -0
- package/lib/services/dremio.js +339 -0
- package/lib/services/dremio.js.map +1 -0
- package/lib/services/edge.d.ts +312 -0
- package/lib/services/edge.d.ts.map +1 -0
- package/lib/services/edge.js +375 -0
- package/lib/services/edge.js.map +1 -0
- package/lib/services/functions.d.ts +409 -0
- package/lib/services/functions.d.ts.map +1 -0
- package/lib/services/functions.js +423 -0
- package/lib/services/functions.js.map +1 -0
- package/lib/services/git.d.ts +497 -0
- package/lib/services/git.d.ts.map +1 -0
- package/lib/services/git.js +552 -0
- package/lib/services/git.js.map +1 -0
- package/lib/services/iaas.d.ts +2965 -0
- package/lib/services/iaas.d.ts.map +1 -0
- package/lib/services/iaas.js +3768 -0
- package/lib/services/iaas.js.map +1 -0
- package/lib/services/index.d.ts +51 -0
- package/lib/services/index.d.ts.map +1 -0
- package/lib/services/index.js +52 -0
- package/lib/services/index.js.map +1 -0
- package/lib/services/intake.d.ts +555 -0
- package/lib/services/intake.d.ts.map +1 -0
- package/lib/services/intake.js +513 -0
- package/lib/services/intake.js.map +1 -0
- package/lib/services/kms.d.ts +654 -0
- package/lib/services/kms.d.ts.map +1 -0
- package/lib/services/kms.js +703 -0
- package/lib/services/kms.js.map +1 -0
- package/lib/services/lb_ip_lists.d.ts +162 -0
- package/lib/services/lb_ip_lists.d.ts.map +1 -0
- package/lib/services/lb_ip_lists.js +173 -0
- package/lib/services/lb_ip_lists.js.map +1 -0
- package/lib/services/load_balancer.d.ts +563 -0
- package/lib/services/load_balancer.d.ts.map +1 -0
- package/lib/services/load_balancer.js +542 -0
- package/lib/services/load_balancer.js.map +1 -0
- package/lib/services/logme.d.ts +516 -0
- package/lib/services/logme.d.ts.map +1 -0
- package/lib/services/logme.js +636 -0
- package/lib/services/logme.js.map +1 -0
- package/lib/services/logs.d.ts +436 -0
- package/lib/services/logs.d.ts.map +1 -0
- package/lib/services/logs.js +498 -0
- package/lib/services/logs.js.map +1 -0
- package/lib/services/mariadb.d.ts +479 -0
- package/lib/services/mariadb.d.ts.map +1 -0
- package/lib/services/mariadb.js +611 -0
- package/lib/services/mariadb.js.map +1 -0
- package/lib/services/model_experiments.d.ts +306 -0
- package/lib/services/model_experiments.d.ts.map +1 -0
- package/lib/services/model_experiments.js +356 -0
- package/lib/services/model_experiments.js.map +1 -0
- package/lib/services/model_serving.d.ts +289 -0
- package/lib/services/model_serving.d.ts.map +1 -0
- package/lib/services/model_serving.js +319 -0
- package/lib/services/model_serving.js.map +1 -0
- package/lib/services/mongodb_flex.d.ts +826 -0
- package/lib/services/mongodb_flex.d.ts.map +1 -0
- package/lib/services/mongodb_flex.js +889 -0
- package/lib/services/mongodb_flex.js.map +1 -0
- package/lib/services/object_storage.d.ts +446 -0
- package/lib/services/object_storage.d.ts.map +1 -0
- package/lib/services/object_storage.js +577 -0
- package/lib/services/object_storage.js.map +1 -0
- package/lib/services/observability.d.ts +2750 -0
- package/lib/services/observability.d.ts.map +1 -0
- package/lib/services/observability.js +3407 -0
- package/lib/services/observability.js.map +1 -0
- package/lib/services/opensearch.d.ts +505 -0
- package/lib/services/opensearch.d.ts.map +1 -0
- package/lib/services/opensearch.js +623 -0
- package/lib/services/opensearch.js.map +1 -0
- package/lib/services/pim.d.ts +997 -0
- package/lib/services/pim.d.ts.map +1 -0
- package/lib/services/pim.js +789 -0
- package/lib/services/pim.js.map +1 -0
- package/lib/services/postgres_flex.d.ts +854 -0
- package/lib/services/postgres_flex.d.ts.map +1 -0
- package/lib/services/postgres_flex.js +1018 -0
- package/lib/services/postgres_flex.js.map +1 -0
- package/lib/services/pubsub.d.ts +489 -0
- package/lib/services/pubsub.d.ts.map +1 -0
- package/lib/services/pubsub.js +614 -0
- package/lib/services/pubsub.js.map +1 -0
- package/lib/services/rabbitmq.d.ts +523 -0
- package/lib/services/rabbitmq.d.ts.map +1 -0
- package/lib/services/rabbitmq.js +636 -0
- package/lib/services/rabbitmq.js.map +1 -0
- package/lib/services/registry.d.ts +212 -0
- package/lib/services/registry.d.ts.map +1 -0
- package/lib/services/registry.js +221 -0
- package/lib/services/registry.js.map +1 -0
- package/lib/services/resource_manager.d.ts +458 -0
- package/lib/services/resource_manager.d.ts.map +1 -0
- package/lib/services/resource_manager.js +503 -0
- package/lib/services/resource_manager.js.map +1 -0
- package/lib/services/run_command.d.ts +175 -0
- package/lib/services/run_command.d.ts.map +1 -0
- package/lib/services/run_command.js +203 -0
- package/lib/services/run_command.js.map +1 -0
- package/lib/services/sca.d.ts +541 -0
- package/lib/services/sca.d.ts.map +1 -0
- package/lib/services/sca.js +478 -0
- package/lib/services/sca.js.map +1 -0
- package/lib/services/scf.d.ts +498 -0
- package/lib/services/scf.d.ts.map +1 -0
- package/lib/services/scf.js +718 -0
- package/lib/services/scf.js.map +1 -0
- package/lib/services/secrets_manager.d.ts +505 -0
- package/lib/services/secrets_manager.d.ts.map +1 -0
- package/lib/services/secrets_manager.js +659 -0
- package/lib/services/secrets_manager.js.map +1 -0
- package/lib/services/server_backup.d.ts +380 -0
- package/lib/services/server_backup.d.ts.map +1 -0
- package/lib/services/server_backup.js +474 -0
- package/lib/services/server_backup.js.map +1 -0
- package/lib/services/server_update.d.ts +292 -0
- package/lib/services/server_update.d.ts.map +1 -0
- package/lib/services/server_update.js +364 -0
- package/lib/services/server_update.js.map +1 -0
- package/lib/services/service_account.d.ts +465 -0
- package/lib/services/service_account.d.ts.map +1 -0
- package/lib/services/service_account.js +523 -0
- package/lib/services/service_account.js.map +1 -0
- package/lib/services/service_enablement.d.ts +149 -0
- package/lib/services/service_enablement.d.ts.map +1 -0
- package/lib/services/service_enablement.js +159 -0
- package/lib/services/service_enablement.js.map +1 -0
- package/lib/services/sfs.d.ts +721 -0
- package/lib/services/sfs.d.ts.map +1 -0
- package/lib/services/sfs.js +845 -0
- package/lib/services/sfs.js.map +1 -0
- package/lib/services/ske.d.ts +536 -0
- package/lib/services/ske.d.ts.map +1 -0
- package/lib/services/ske.js +598 -0
- package/lib/services/ske.js.map +1 -0
- package/lib/services/sqlserverflex.d.ts +956 -0
- package/lib/services/sqlserverflex.d.ts.map +1 -0
- package/lib/services/sqlserverflex.js +1087 -0
- package/lib/services/sqlserverflex.js.map +1 -0
- package/lib/services/stackit_marketplace.d.ts +288 -0
- package/lib/services/stackit_marketplace.d.ts.map +1 -0
- package/lib/services/stackit_marketplace.js +393 -0
- package/lib/services/stackit_marketplace.js.map +1 -0
- package/lib/services/telemetry_link.d.ts +443 -0
- package/lib/services/telemetry_link.d.ts.map +1 -0
- package/lib/services/telemetry_link.js +550 -0
- package/lib/services/telemetry_link.js.map +1 -0
- package/lib/services/telemetry_router.d.ts +493 -0
- package/lib/services/telemetry_router.d.ts.map +1 -0
- package/lib/services/telemetry_router.js +523 -0
- package/lib/services/telemetry_router.js.map +1 -0
- package/lib/services/ufw.d.ts +295 -0
- package/lib/services/ufw.d.ts.map +1 -0
- package/lib/services/ufw.js +301 -0
- package/lib/services/ufw.js.map +1 -0
- package/lib/services/valkey.d.ts +505 -0
- package/lib/services/valkey.d.ts.map +1 -0
- package/lib/services/valkey.js +627 -0
- package/lib/services/valkey.js.map +1 -0
- package/lib/services/vpn.d.ts +1024 -0
- package/lib/services/vpn.d.ts.map +1 -0
- package/lib/services/vpn.js +1013 -0
- package/lib/services/vpn.js.map +1 -0
- package/lib/services/workflows.d.ts +600 -0
- package/lib/services/workflows.d.ts.map +1 -0
- package/lib/services/workflows.js +556 -0
- package/lib/services/workflows.js.map +1 -0
- package/lib/traits.d.ts +24 -0
- package/lib/traits.d.ts.map +1 -0
- package/lib/traits.js +15 -0
- package/lib/traits.js.map +1 -0
- package/package.json +78 -7
- package/src/credentials.ts +90 -0
- package/src/errors.ts +50 -0
- package/src/index.ts +34 -0
- package/src/pagination.ts +73 -0
- package/src/protocol.ts +243 -0
- package/src/response-validation.test.ts +45 -0
- package/src/retry.ts +53 -0
- package/src/services/alb.ts +1409 -0
- package/src/services/alb_waf.ts +1347 -0
- package/src/services/authorization.ts +740 -0
- package/src/services/automation.ts +966 -0
- package/src/services/cdn.ts +2736 -0
- package/src/services/certificates.ts +450 -0
- package/src/services/cost.ts +484 -0
- package/src/services/dns.ts +2271 -0
- package/src/services/dremio.ts +803 -0
- package/src/services/edge.ts +839 -0
- package/src/services/functions.ts +1010 -0
- package/src/services/git.ts +1275 -0
- package/src/services/iaas.ts +8670 -0
- package/src/services/index.ts +51 -0
- package/src/services/intake.ts +1233 -0
- package/src/services/kms.ts +1638 -0
- package/src/services/lb_ip_lists.ts +377 -0
- package/src/services/load_balancer.ts +1342 -0
- package/src/services/logme.ts +1379 -0
- package/src/services/logs.ts +1150 -0
- package/src/services/mariadb.ts +1293 -0
- package/src/services/model_experiments.ts +797 -0
- package/src/services/model_serving.ts +697 -0
- package/src/services/mongodb_flex.ts +2078 -0
- package/src/services/object_storage.ts +1248 -0
- package/src/services/observability.ts +7856 -0
- package/src/services/opensearch.ts +1354 -0
- package/src/services/pim.ts +2090 -0
- package/src/services/postgres_flex.ts +2326 -0
- package/src/services/pubsub.ts +1336 -0
- package/src/services/rabbitmq.ts +1402 -0
- package/src/services/registry.ts +494 -0
- package/src/services/resource_manager.ts +1155 -0
- package/src/services/run_command.ts +441 -0
- package/src/services/sca.ts +1222 -0
- package/src/services/scf.ts +1537 -0
- package/src/services/secrets_manager.ts +1399 -0
- package/src/services/server_backup.ts +1032 -0
- package/src/services/server_update.ts +767 -0
- package/src/services/service_account.ts +1208 -0
- package/src/services/service_enablement.ts +359 -0
- package/src/services/sfs.ts +1913 -0
- package/src/services/ske.ts +1408 -0
- package/src/services/sqlserverflex.ts +2543 -0
- package/src/services/stackit_marketplace.ts +853 -0
- package/src/services/telemetry_link.ts +1245 -0
- package/src/services/telemetry_router.ts +1205 -0
- package/src/services/ufw.ts +704 -0
- package/src/services/valkey.ts +1357 -0
- package/src/services/vpn.ts +2554 -0
- package/src/services/workflows.ts +1361 -0
- package/src/traits.ts +65 -0
|
@@ -0,0 +1,441 @@
|
|
|
1
|
+
// AUTO-GENERATED by scripts/generate.ts from .generated-specs (specs/spec-mirror-stackit). Do not edit.
|
|
2
|
+
import * as S from "@distilled.cloud/core/schema";
|
|
3
|
+
import * as API from "@distilled.cloud/core/api";
|
|
4
|
+
import * as C from "@distilled.cloud/core/category";
|
|
5
|
+
import * as T from "../traits.ts";
|
|
6
|
+
import {
|
|
7
|
+
StackitProtocol,
|
|
8
|
+
type StackitOpError,
|
|
9
|
+
type StackitOpContext,
|
|
10
|
+
} from "../protocol.ts";
|
|
11
|
+
import { UnknownStackitError } from "../errors.ts";
|
|
12
|
+
import * as Retry from "../retry.ts";
|
|
13
|
+
|
|
14
|
+
export type { StackitOpError, StackitOpContext };
|
|
15
|
+
|
|
16
|
+
export class BadRequest
|
|
17
|
+
extends /*@__PURE__*/ T.applyErrorMatchers(
|
|
18
|
+
/*@__PURE__*/ S.TaggedError<BadRequest>()("BadRequest", {
|
|
19
|
+
code: S.Number,
|
|
20
|
+
message: S.String,
|
|
21
|
+
}).pipe(C.withBadRequestError),
|
|
22
|
+
[{ status: 400 }],
|
|
23
|
+
) {}
|
|
24
|
+
|
|
25
|
+
export class NotFound
|
|
26
|
+
extends /*@__PURE__*/ T.applyErrorMatchers(
|
|
27
|
+
/*@__PURE__*/ S.TaggedError<NotFound>()("NotFound", {
|
|
28
|
+
code: S.Number,
|
|
29
|
+
message: S.String,
|
|
30
|
+
}).pipe(C.withBadRequestError),
|
|
31
|
+
[{ status: 404 }],
|
|
32
|
+
) {}
|
|
33
|
+
|
|
34
|
+
export type CreateCommandRequestParametersMap = {
|
|
35
|
+
[key: string]: string | undefined;
|
|
36
|
+
};
|
|
37
|
+
export const CreateCommandRequestParametersMap = /*@__PURE__*/ S.Record(
|
|
38
|
+
S.String,
|
|
39
|
+
S.String,
|
|
40
|
+
) as any as S.Schema<CreateCommandRequestParametersMap>;
|
|
41
|
+
|
|
42
|
+
export interface CreateCommandRequest {
|
|
43
|
+
/** ID of the project */
|
|
44
|
+
projectId: string;
|
|
45
|
+
/** region */
|
|
46
|
+
region: string;
|
|
47
|
+
/** Server ID of the machine */
|
|
48
|
+
serverId: string;
|
|
49
|
+
commandTemplateName: string;
|
|
50
|
+
parameters?: CreateCommandRequestParametersMap;
|
|
51
|
+
}
|
|
52
|
+
export const CreateCommandRequest = /*@__PURE__*/ S.suspend(() =>
|
|
53
|
+
S.Struct({
|
|
54
|
+
projectId: S.String.pipe(T.Label()),
|
|
55
|
+
region: S.String.pipe(T.Label()),
|
|
56
|
+
serverId: S.String.pipe(T.Label()),
|
|
57
|
+
commandTemplateName: S.String,
|
|
58
|
+
parameters: S.optional(CreateCommandRequestParametersMap),
|
|
59
|
+
}).pipe(
|
|
60
|
+
T.Http({
|
|
61
|
+
method: "POST",
|
|
62
|
+
uri: "/v2/projects/{projectId}/regions/{region}/servers/{serverId}/commands",
|
|
63
|
+
code: 200,
|
|
64
|
+
baseUrl: "https://run-command.api.stackit.cloud",
|
|
65
|
+
}),
|
|
66
|
+
),
|
|
67
|
+
).annotate({
|
|
68
|
+
identifier: "CreateCommandRequest",
|
|
69
|
+
}) as any as S.Schema<CreateCommandRequest>;
|
|
70
|
+
|
|
71
|
+
export interface NewCommandResponse {
|
|
72
|
+
id?: number;
|
|
73
|
+
}
|
|
74
|
+
export const NewCommandResponse = /*@__PURE__*/ S.suspend(() =>
|
|
75
|
+
S.Struct({
|
|
76
|
+
id: S.optional(S.Number),
|
|
77
|
+
}),
|
|
78
|
+
).annotate({
|
|
79
|
+
identifier: "NewCommandResponse",
|
|
80
|
+
}) as any as S.Schema<NewCommandResponse>;
|
|
81
|
+
|
|
82
|
+
export interface GetCommandRequest {
|
|
83
|
+
/** ID of the project */
|
|
84
|
+
projectId: string;
|
|
85
|
+
/** region */
|
|
86
|
+
region: string;
|
|
87
|
+
/** Server ID of the machine */
|
|
88
|
+
serverId: string;
|
|
89
|
+
/** ID of the command */
|
|
90
|
+
commandId: string;
|
|
91
|
+
}
|
|
92
|
+
export const GetCommandRequest = /*@__PURE__*/ S.suspend(() =>
|
|
93
|
+
S.Struct({
|
|
94
|
+
projectId: S.String.pipe(T.Label()),
|
|
95
|
+
region: S.String.pipe(T.Label()),
|
|
96
|
+
serverId: S.String.pipe(T.Label()),
|
|
97
|
+
commandId: S.String.pipe(T.Label()),
|
|
98
|
+
}).pipe(
|
|
99
|
+
T.Http({
|
|
100
|
+
method: "GET",
|
|
101
|
+
uri: "/v2/projects/{projectId}/regions/{region}/servers/{serverId}/commands/{commandId}",
|
|
102
|
+
code: 200,
|
|
103
|
+
baseUrl: "https://run-command.api.stackit.cloud",
|
|
104
|
+
}),
|
|
105
|
+
),
|
|
106
|
+
).annotate({
|
|
107
|
+
identifier: "GetCommandRequest",
|
|
108
|
+
}) as any as S.Schema<GetCommandRequest>;
|
|
109
|
+
|
|
110
|
+
export type CommandDetailsStatus =
|
|
111
|
+
| "pending"
|
|
112
|
+
| "running"
|
|
113
|
+
| "completed"
|
|
114
|
+
| "failed";
|
|
115
|
+
export const CommandDetailsStatus = /*@__PURE__*/ S.String;
|
|
116
|
+
|
|
117
|
+
export interface CommandDetails {
|
|
118
|
+
commandTemplateName?: string;
|
|
119
|
+
commandTemplateTitle?: string;
|
|
120
|
+
exitCode?: number;
|
|
121
|
+
finishedAt?: string;
|
|
122
|
+
id?: number;
|
|
123
|
+
output?: string;
|
|
124
|
+
script?: string;
|
|
125
|
+
startedAt?: string;
|
|
126
|
+
status?: CommandDetailsStatus;
|
|
127
|
+
}
|
|
128
|
+
export const CommandDetails = /*@__PURE__*/ S.suspend(() =>
|
|
129
|
+
S.Struct({
|
|
130
|
+
commandTemplateName: S.optional(S.String),
|
|
131
|
+
commandTemplateTitle: S.optional(S.String),
|
|
132
|
+
exitCode: S.optional(S.Number),
|
|
133
|
+
finishedAt: S.optional(S.String),
|
|
134
|
+
id: S.optional(S.Number),
|
|
135
|
+
output: S.optional(S.String),
|
|
136
|
+
script: S.optional(S.String),
|
|
137
|
+
startedAt: S.optional(S.String),
|
|
138
|
+
status: S.optional(CommandDetailsStatus),
|
|
139
|
+
}),
|
|
140
|
+
).annotate({ identifier: "CommandDetails" }) as any as S.Schema<CommandDetails>;
|
|
141
|
+
|
|
142
|
+
export interface GetCommandTemplateRequest {
|
|
143
|
+
/** ID of the project */
|
|
144
|
+
projectId: string;
|
|
145
|
+
/** region */
|
|
146
|
+
region: string;
|
|
147
|
+
/** Server ID of the machine */
|
|
148
|
+
serverId: string;
|
|
149
|
+
/** Name of the template */
|
|
150
|
+
commandTemplateName: string;
|
|
151
|
+
}
|
|
152
|
+
export const GetCommandTemplateRequest = /*@__PURE__*/ S.suspend(() =>
|
|
153
|
+
S.Struct({
|
|
154
|
+
projectId: S.String.pipe(T.Label()),
|
|
155
|
+
region: S.String.pipe(T.Label()),
|
|
156
|
+
serverId: S.String.pipe(T.Label()),
|
|
157
|
+
commandTemplateName: S.String.pipe(T.Label()),
|
|
158
|
+
}).pipe(
|
|
159
|
+
T.Http({
|
|
160
|
+
method: "GET",
|
|
161
|
+
uri: "/v2/projects/{projectId}/regions/{region}/servers/{serverId}/command-templates/{commandTemplateName}",
|
|
162
|
+
code: 200,
|
|
163
|
+
baseUrl: "https://run-command.api.stackit.cloud",
|
|
164
|
+
}),
|
|
165
|
+
),
|
|
166
|
+
).annotate({
|
|
167
|
+
identifier: "GetCommandTemplateRequest",
|
|
168
|
+
}) as any as S.Schema<GetCommandTemplateRequest>;
|
|
169
|
+
|
|
170
|
+
export type CommandTemplateSchemaOsTypeList = Array<string>;
|
|
171
|
+
export const CommandTemplateSchemaOsTypeList = /*@__PURE__*/ S.Array(
|
|
172
|
+
S.String,
|
|
173
|
+
) as any as S.Schema<CommandTemplateSchemaOsTypeList>;
|
|
174
|
+
|
|
175
|
+
export interface Field {
|
|
176
|
+
default?: string;
|
|
177
|
+
description?: string;
|
|
178
|
+
maxLen?: number;
|
|
179
|
+
minLen?: number;
|
|
180
|
+
readOnly?: boolean;
|
|
181
|
+
title?: string;
|
|
182
|
+
type?: string;
|
|
183
|
+
}
|
|
184
|
+
export const Field = /*@__PURE__*/ S.suspend(() =>
|
|
185
|
+
S.Struct({
|
|
186
|
+
default: S.optional(S.String),
|
|
187
|
+
description: S.optional(S.String),
|
|
188
|
+
maxLen: S.optional(S.Number),
|
|
189
|
+
minLen: S.optional(S.Number),
|
|
190
|
+
readOnly: S.optional(S.Boolean),
|
|
191
|
+
title: S.optional(S.String),
|
|
192
|
+
type: S.optional(S.String),
|
|
193
|
+
}),
|
|
194
|
+
).annotate({ identifier: "Field" }) as any as S.Schema<Field>;
|
|
195
|
+
|
|
196
|
+
export type PropertiesRequiredList = Array<string>;
|
|
197
|
+
export const PropertiesRequiredList = /*@__PURE__*/ S.Array(
|
|
198
|
+
S.String,
|
|
199
|
+
) as any as S.Schema<PropertiesRequiredList>;
|
|
200
|
+
|
|
201
|
+
export interface Properties {
|
|
202
|
+
ConfirmPassword?: Field;
|
|
203
|
+
Password?: Field;
|
|
204
|
+
Script?: Field;
|
|
205
|
+
Username?: Field;
|
|
206
|
+
required?: PropertiesRequiredList;
|
|
207
|
+
type?: string;
|
|
208
|
+
}
|
|
209
|
+
export const Properties = /*@__PURE__*/ S.suspend(() =>
|
|
210
|
+
S.Struct({
|
|
211
|
+
ConfirmPassword: S.optional(Field),
|
|
212
|
+
Password: S.optional(Field),
|
|
213
|
+
Script: S.optional(Field),
|
|
214
|
+
Username: S.optional(Field),
|
|
215
|
+
required: S.optional(PropertiesRequiredList),
|
|
216
|
+
type: S.optional(S.String),
|
|
217
|
+
}),
|
|
218
|
+
).annotate({ identifier: "Properties" }) as any as S.Schema<Properties>;
|
|
219
|
+
|
|
220
|
+
export interface ParametersSchema {
|
|
221
|
+
properties?: Properties;
|
|
222
|
+
}
|
|
223
|
+
export const ParametersSchema = /*@__PURE__*/ S.suspend(() =>
|
|
224
|
+
S.Struct({
|
|
225
|
+
properties: S.optional(Properties),
|
|
226
|
+
}),
|
|
227
|
+
).annotate({
|
|
228
|
+
identifier: "ParametersSchema",
|
|
229
|
+
}) as any as S.Schema<ParametersSchema>;
|
|
230
|
+
|
|
231
|
+
export interface CommandTemplateSchema {
|
|
232
|
+
description?: string;
|
|
233
|
+
name?: string;
|
|
234
|
+
osType?: CommandTemplateSchemaOsTypeList;
|
|
235
|
+
parametersSchema?: ParametersSchema;
|
|
236
|
+
title?: string;
|
|
237
|
+
}
|
|
238
|
+
export const CommandTemplateSchema = /*@__PURE__*/ S.suspend(() =>
|
|
239
|
+
S.Struct({
|
|
240
|
+
description: S.optional(S.String),
|
|
241
|
+
name: S.optional(S.String),
|
|
242
|
+
osType: S.optional(CommandTemplateSchemaOsTypeList),
|
|
243
|
+
parametersSchema: S.optional(ParametersSchema),
|
|
244
|
+
title: S.optional(S.String),
|
|
245
|
+
}),
|
|
246
|
+
).annotate({
|
|
247
|
+
identifier: "CommandTemplateSchema",
|
|
248
|
+
}) as any as S.Schema<CommandTemplateSchema>;
|
|
249
|
+
|
|
250
|
+
export interface ListCommandsRequest {
|
|
251
|
+
/** ID of the project */
|
|
252
|
+
projectId: string;
|
|
253
|
+
/** region */
|
|
254
|
+
region: string;
|
|
255
|
+
/** Server ID of the machine */
|
|
256
|
+
serverId: string;
|
|
257
|
+
}
|
|
258
|
+
export const ListCommandsRequest = /*@__PURE__*/ S.suspend(() =>
|
|
259
|
+
S.Struct({
|
|
260
|
+
projectId: S.String.pipe(T.Label()),
|
|
261
|
+
region: S.String.pipe(T.Label()),
|
|
262
|
+
serverId: S.String.pipe(T.Label()),
|
|
263
|
+
}).pipe(
|
|
264
|
+
T.Http({
|
|
265
|
+
method: "GET",
|
|
266
|
+
uri: "/v2/projects/{projectId}/regions/{region}/servers/{serverId}/commands",
|
|
267
|
+
code: 200,
|
|
268
|
+
baseUrl: "https://run-command.api.stackit.cloud",
|
|
269
|
+
}),
|
|
270
|
+
),
|
|
271
|
+
).annotate({
|
|
272
|
+
identifier: "ListCommandsRequest",
|
|
273
|
+
}) as any as S.Schema<ListCommandsRequest>;
|
|
274
|
+
|
|
275
|
+
export type CommandsStatus = "pending" | "running" | "completed" | "failed";
|
|
276
|
+
export const CommandsStatus = /*@__PURE__*/ S.String;
|
|
277
|
+
|
|
278
|
+
export interface Commands {
|
|
279
|
+
commandTemplateName?: string;
|
|
280
|
+
commandTemplateTitle?: string;
|
|
281
|
+
finishedAt?: string;
|
|
282
|
+
id?: number;
|
|
283
|
+
startedAt?: string;
|
|
284
|
+
status?: CommandsStatus;
|
|
285
|
+
}
|
|
286
|
+
export const Commands = /*@__PURE__*/ S.suspend(() =>
|
|
287
|
+
S.Struct({
|
|
288
|
+
commandTemplateName: S.optional(S.String),
|
|
289
|
+
commandTemplateTitle: S.optional(S.String),
|
|
290
|
+
finishedAt: S.optional(S.String),
|
|
291
|
+
id: S.optional(S.Number),
|
|
292
|
+
startedAt: S.optional(S.String),
|
|
293
|
+
status: S.optional(CommandsStatus),
|
|
294
|
+
}),
|
|
295
|
+
).annotate({ identifier: "Commands" }) as any as S.Schema<Commands>;
|
|
296
|
+
|
|
297
|
+
export type GetCommandsResponseItemsList = Array<Commands>;
|
|
298
|
+
export const GetCommandsResponseItemsList = /*@__PURE__*/ S.Array(
|
|
299
|
+
Commands,
|
|
300
|
+
) as any as S.Schema<GetCommandsResponseItemsList>;
|
|
301
|
+
|
|
302
|
+
export interface GetCommandsResponse {
|
|
303
|
+
items?: GetCommandsResponseItemsList;
|
|
304
|
+
}
|
|
305
|
+
export const GetCommandsResponse = /*@__PURE__*/ S.suspend(() =>
|
|
306
|
+
S.Struct({
|
|
307
|
+
items: S.optional(GetCommandsResponseItemsList),
|
|
308
|
+
}),
|
|
309
|
+
).annotate({
|
|
310
|
+
identifier: "GetCommandsResponse",
|
|
311
|
+
}) as any as S.Schema<GetCommandsResponse>;
|
|
312
|
+
|
|
313
|
+
export interface ListCommandTemplatesRequest {
|
|
314
|
+
/** The type of the Operating System (windows or linux). If not provided will return data for all OS types. */
|
|
315
|
+
osType?: string;
|
|
316
|
+
}
|
|
317
|
+
export const ListCommandTemplatesRequest = /*@__PURE__*/ S.suspend(() =>
|
|
318
|
+
S.Struct({
|
|
319
|
+
osType: S.optional(S.String.pipe(T.Query())),
|
|
320
|
+
}).pipe(
|
|
321
|
+
T.Http({
|
|
322
|
+
method: "GET",
|
|
323
|
+
uri: "/v2/command-templates",
|
|
324
|
+
code: 200,
|
|
325
|
+
baseUrl: "https://run-command.api.stackit.cloud",
|
|
326
|
+
}),
|
|
327
|
+
),
|
|
328
|
+
).annotate({
|
|
329
|
+
identifier: "ListCommandTemplatesRequest",
|
|
330
|
+
}) as any as S.Schema<ListCommandTemplatesRequest>;
|
|
331
|
+
|
|
332
|
+
export type CommandTemplateOsTypeList = Array<string>;
|
|
333
|
+
export const CommandTemplateOsTypeList = /*@__PURE__*/ S.Array(
|
|
334
|
+
S.String,
|
|
335
|
+
) as any as S.Schema<CommandTemplateOsTypeList>;
|
|
336
|
+
|
|
337
|
+
export interface CommandTemplate {
|
|
338
|
+
name?: string;
|
|
339
|
+
osType?: CommandTemplateOsTypeList;
|
|
340
|
+
title?: string;
|
|
341
|
+
}
|
|
342
|
+
export const CommandTemplate = /*@__PURE__*/ S.suspend(() =>
|
|
343
|
+
S.Struct({
|
|
344
|
+
name: S.optional(S.String),
|
|
345
|
+
osType: S.optional(CommandTemplateOsTypeList),
|
|
346
|
+
title: S.optional(S.String),
|
|
347
|
+
}),
|
|
348
|
+
).annotate({
|
|
349
|
+
identifier: "CommandTemplate",
|
|
350
|
+
}) as any as S.Schema<CommandTemplate>;
|
|
351
|
+
|
|
352
|
+
export type CommandTemplateResponseItemsList = Array<CommandTemplate>;
|
|
353
|
+
export const CommandTemplateResponseItemsList = /*@__PURE__*/ S.Array(
|
|
354
|
+
CommandTemplate,
|
|
355
|
+
) as any as S.Schema<CommandTemplateResponseItemsList>;
|
|
356
|
+
|
|
357
|
+
export interface CommandTemplateResponse {
|
|
358
|
+
items?: CommandTemplateResponseItemsList;
|
|
359
|
+
}
|
|
360
|
+
export const CommandTemplateResponse = /*@__PURE__*/ S.suspend(() =>
|
|
361
|
+
S.Struct({
|
|
362
|
+
items: S.optional(CommandTemplateResponseItemsList),
|
|
363
|
+
}),
|
|
364
|
+
).annotate({
|
|
365
|
+
identifier: "CommandTemplateResponse",
|
|
366
|
+
}) as any as S.Schema<CommandTemplateResponse>;
|
|
367
|
+
|
|
368
|
+
export type CreateCommandError = BadRequest | NotFound | StackitOpError;
|
|
369
|
+
/** Creates a new command for execution */
|
|
370
|
+
export const createCommand: API.OperationMethod<
|
|
371
|
+
CreateCommandRequest,
|
|
372
|
+
NewCommandResponse,
|
|
373
|
+
CreateCommandError,
|
|
374
|
+
StackitOpContext
|
|
375
|
+
> = /*@__PURE__*/ API.make(() => ({
|
|
376
|
+
input: CreateCommandRequest,
|
|
377
|
+
output: NewCommandResponse,
|
|
378
|
+
errors: [BadRequest, NotFound, UnknownStackitError],
|
|
379
|
+
protocol: StackitProtocol,
|
|
380
|
+
retry: Retry.Retry,
|
|
381
|
+
}));
|
|
382
|
+
|
|
383
|
+
export type GetCommandError = BadRequest | NotFound | StackitOpError;
|
|
384
|
+
/** Returns details about a command */
|
|
385
|
+
export const getCommand: API.OperationMethod<
|
|
386
|
+
GetCommandRequest,
|
|
387
|
+
CommandDetails,
|
|
388
|
+
GetCommandError,
|
|
389
|
+
StackitOpContext
|
|
390
|
+
> = /*@__PURE__*/ API.make(() => ({
|
|
391
|
+
input: GetCommandRequest,
|
|
392
|
+
output: CommandDetails,
|
|
393
|
+
errors: [BadRequest, NotFound, UnknownStackitError],
|
|
394
|
+
protocol: StackitProtocol,
|
|
395
|
+
retry: Retry.Retry,
|
|
396
|
+
}));
|
|
397
|
+
|
|
398
|
+
export type GetCommandTemplateError = BadRequest | NotFound | StackitOpError;
|
|
399
|
+
/** Returns details about a command template */
|
|
400
|
+
export const getCommandTemplate: API.OperationMethod<
|
|
401
|
+
GetCommandTemplateRequest,
|
|
402
|
+
CommandTemplateSchema,
|
|
403
|
+
GetCommandTemplateError,
|
|
404
|
+
StackitOpContext
|
|
405
|
+
> = /*@__PURE__*/ API.make(() => ({
|
|
406
|
+
input: GetCommandTemplateRequest,
|
|
407
|
+
output: CommandTemplateSchema,
|
|
408
|
+
errors: [BadRequest, NotFound, UnknownStackitError],
|
|
409
|
+
protocol: StackitProtocol,
|
|
410
|
+
retry: Retry.Retry,
|
|
411
|
+
}));
|
|
412
|
+
|
|
413
|
+
export type ListCommandsError = BadRequest | NotFound | StackitOpError;
|
|
414
|
+
/** Returns a list of commands */
|
|
415
|
+
export const listCommands: API.OperationMethod<
|
|
416
|
+
ListCommandsRequest,
|
|
417
|
+
GetCommandsResponse,
|
|
418
|
+
ListCommandsError,
|
|
419
|
+
StackitOpContext
|
|
420
|
+
> = /*@__PURE__*/ API.make(() => ({
|
|
421
|
+
input: ListCommandsRequest,
|
|
422
|
+
output: GetCommandsResponse,
|
|
423
|
+
errors: [BadRequest, NotFound, UnknownStackitError],
|
|
424
|
+
protocol: StackitProtocol,
|
|
425
|
+
retry: Retry.Retry,
|
|
426
|
+
}));
|
|
427
|
+
|
|
428
|
+
export type ListCommandTemplatesError = BadRequest | StackitOpError;
|
|
429
|
+
/** Returns a list of command templates */
|
|
430
|
+
export const listCommandTemplates: API.OperationMethod<
|
|
431
|
+
ListCommandTemplatesRequest,
|
|
432
|
+
CommandTemplateResponse,
|
|
433
|
+
ListCommandTemplatesError,
|
|
434
|
+
StackitOpContext
|
|
435
|
+
> = /*@__PURE__*/ API.make(() => ({
|
|
436
|
+
input: ListCommandTemplatesRequest,
|
|
437
|
+
output: CommandTemplateResponse,
|
|
438
|
+
errors: [BadRequest, UnknownStackitError],
|
|
439
|
+
protocol: StackitProtocol,
|
|
440
|
+
retry: Retry.Retry,
|
|
441
|
+
}));
|