@scaleway/sdk 2.35.0 → 2.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/container/v1beta1/index.gen.d.ts +1 -1
- package/dist/api/container/v1beta1/marshalling.gen.cjs +3 -0
- package/dist/api/container/v1beta1/marshalling.gen.js +3 -0
- package/dist/api/container/v1beta1/types.gen.d.ts +7 -0
- package/dist/api/function/v1beta1/index.gen.d.ts +1 -1
- package/dist/api/function/v1beta1/marshalling.gen.cjs +3 -0
- package/dist/api/function/v1beta1/marshalling.gen.js +3 -0
- package/dist/api/function/v1beta1/types.gen.d.ts +7 -0
- package/dist/api/inference/v1beta1/api.gen.d.ts +151 -0
- package/dist/api/inference/v1beta1/content.gen.d.ts +3 -0
- package/dist/api/inference/v1beta1/index.gen.d.ts +4 -0
- package/dist/api/inference/v1beta1/marshalling.gen.d.ts +18 -0
- package/dist/api/inference/v1beta1/types.gen.d.ts +435 -0
- package/dist/api/inference/v1beta1/validation-rules.gen.d.ts +50 -0
- package/dist/api/secret/v1beta1/api.gen.cjs +25 -0
- package/dist/api/secret/v1beta1/api.gen.d.ts +12 -1
- package/dist/api/secret/v1beta1/api.gen.js +26 -1
- package/dist/api/secret/v1beta1/index.gen.d.ts +1 -1
- package/dist/api/secret/v1beta1/marshalling.gen.cjs +12 -0
- package/dist/api/secret/v1beta1/marshalling.gen.d.ts +2 -1
- package/dist/api/secret/v1beta1/marshalling.gen.js +12 -0
- package/dist/api/secret/v1beta1/types.gen.d.ts +17 -0
- package/dist/scw/constants.cjs +1 -1
- package/dist/scw/constants.d.ts +2 -2
- package/dist/scw/constants.js +1 -1
- package/package.json +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export { API } from './api.gen';
|
|
2
2
|
export * from './content.gen';
|
|
3
|
-
export type { Container, ContainerHttpOption, ContainerPrivacy, ContainerProtocol, ContainerStatus, CreateContainerRequest, CreateCronRequest, CreateDomainRequest, CreateNamespaceRequest, CreateTokenRequest, CreateTriggerRequest, CreateTriggerRequestMnqNatsClientConfig, CreateTriggerRequestMnqSqsClientConfig, CreateTriggerRequestSqsClientConfig, Cron, CronStatus, DeleteContainerRequest, DeleteCronRequest, DeleteDomainRequest, DeleteNamespaceRequest, DeleteTokenRequest, DeleteTriggerRequest, DeployContainerRequest, Domain, DomainStatus, GetContainerRequest, GetCronRequest, GetDomainRequest, GetNamespaceRequest, GetTokenRequest, GetTriggerRequest, IssueJWTRequest, ListContainersRequest, ListContainersRequestOrderBy, ListContainersResponse, ListCronsRequest, ListCronsRequestOrderBy, ListCronsResponse, ListDomainsRequest, ListDomainsRequestOrderBy, ListDomainsResponse, ListNamespacesRequest, ListNamespacesRequestOrderBy, ListNamespacesResponse, ListTokensRequest, ListTokensRequestOrderBy, ListTokensResponse, ListTriggersRequest, ListTriggersRequestOrderBy, ListTriggersResponse, Namespace, NamespaceStatus, Secret, SecretHashedValue, Token, TokenStatus, Trigger, TriggerInputType, TriggerMnqNatsClientConfig, TriggerMnqSqsClientConfig, TriggerSqsClientConfig, TriggerStatus, UpdateContainerRequest, UpdateCronRequest, UpdateNamespaceRequest, UpdateTriggerRequest, UpdateTriggerRequestSqsClientConfig, } from './types.gen';
|
|
3
|
+
export type { Container, ContainerHttpOption, ContainerPrivacy, ContainerProtocol, ContainerSandbox, ContainerStatus, CreateContainerRequest, CreateCronRequest, CreateDomainRequest, CreateNamespaceRequest, CreateTokenRequest, CreateTriggerRequest, CreateTriggerRequestMnqNatsClientConfig, CreateTriggerRequestMnqSqsClientConfig, CreateTriggerRequestSqsClientConfig, Cron, CronStatus, DeleteContainerRequest, DeleteCronRequest, DeleteDomainRequest, DeleteNamespaceRequest, DeleteTokenRequest, DeleteTriggerRequest, DeployContainerRequest, Domain, DomainStatus, GetContainerRequest, GetCronRequest, GetDomainRequest, GetNamespaceRequest, GetTokenRequest, GetTriggerRequest, IssueJWTRequest, ListContainersRequest, ListContainersRequestOrderBy, ListContainersResponse, ListCronsRequest, ListCronsRequestOrderBy, ListCronsResponse, ListDomainsRequest, ListDomainsRequestOrderBy, ListDomainsResponse, ListNamespacesRequest, ListNamespacesRequestOrderBy, ListNamespacesResponse, ListTokensRequest, ListTokensRequestOrderBy, ListTokensResponse, ListTriggersRequest, ListTriggersRequestOrderBy, ListTriggersResponse, Namespace, NamespaceStatus, Secret, SecretHashedValue, Token, TokenStatus, Trigger, TriggerInputType, TriggerMnqNatsClientConfig, TriggerMnqSqsClientConfig, TriggerSqsClientConfig, TriggerStatus, UpdateContainerRequest, UpdateCronRequest, UpdateNamespaceRequest, UpdateTriggerRequest, UpdateTriggerRequestSqsClientConfig, } from './types.gen';
|
|
4
4
|
export * as ValidationRules from './validation-rules.gen';
|
|
@@ -39,6 +39,7 @@ const unmarshalContainer = (data) => {
|
|
|
39
39
|
protocol: data.protocol,
|
|
40
40
|
region: data.region,
|
|
41
41
|
registryImage: data.registry_image,
|
|
42
|
+
sandbox: data.sandbox,
|
|
42
43
|
secretEnvironmentVariables: marshalling.unmarshalArrayOfObject(
|
|
43
44
|
data.secret_environment_variables,
|
|
44
45
|
unmarshalSecretHashedValue
|
|
@@ -262,6 +263,7 @@ const marshalCreateContainerRequest = (request, defaults) => ({
|
|
|
262
263
|
privacy: request.privacy,
|
|
263
264
|
protocol: request.protocol,
|
|
264
265
|
registry_image: request.registryImage,
|
|
266
|
+
sandbox: request.sandbox,
|
|
265
267
|
secret_environment_variables: request.secretEnvironmentVariables !== void 0 ? request.secretEnvironmentVariables.map(
|
|
266
268
|
(elt) => marshalSecret(elt)
|
|
267
269
|
) : void 0,
|
|
@@ -350,6 +352,7 @@ const marshalUpdateContainerRequest = (request, defaults) => ({
|
|
|
350
352
|
protocol: request.protocol,
|
|
351
353
|
redeploy: request.redeploy,
|
|
352
354
|
registry_image: request.registryImage,
|
|
355
|
+
sandbox: request.sandbox,
|
|
353
356
|
secret_environment_variables: request.secretEnvironmentVariables !== void 0 ? request.secretEnvironmentVariables.map(
|
|
354
357
|
(elt) => marshalSecret(elt)
|
|
355
358
|
) : void 0,
|
|
@@ -37,6 +37,7 @@ const unmarshalContainer = (data) => {
|
|
|
37
37
|
protocol: data.protocol,
|
|
38
38
|
region: data.region,
|
|
39
39
|
registryImage: data.registry_image,
|
|
40
|
+
sandbox: data.sandbox,
|
|
40
41
|
secretEnvironmentVariables: unmarshalArrayOfObject(
|
|
41
42
|
data.secret_environment_variables,
|
|
42
43
|
unmarshalSecretHashedValue
|
|
@@ -260,6 +261,7 @@ const marshalCreateContainerRequest = (request, defaults) => ({
|
|
|
260
261
|
privacy: request.privacy,
|
|
261
262
|
protocol: request.protocol,
|
|
262
263
|
registry_image: request.registryImage,
|
|
264
|
+
sandbox: request.sandbox,
|
|
263
265
|
secret_environment_variables: request.secretEnvironmentVariables !== void 0 ? request.secretEnvironmentVariables.map(
|
|
264
266
|
(elt) => marshalSecret(elt)
|
|
265
267
|
) : void 0,
|
|
@@ -348,6 +350,7 @@ const marshalUpdateContainerRequest = (request, defaults) => ({
|
|
|
348
350
|
protocol: request.protocol,
|
|
349
351
|
redeploy: request.redeploy,
|
|
350
352
|
registry_image: request.registryImage,
|
|
353
|
+
sandbox: request.sandbox,
|
|
351
354
|
secret_environment_variables: request.secretEnvironmentVariables !== void 0 ? request.secretEnvironmentVariables.map(
|
|
352
355
|
(elt) => marshalSecret(elt)
|
|
353
356
|
) : void 0,
|
|
@@ -2,6 +2,7 @@ import type { Region } from '../../../bridge';
|
|
|
2
2
|
export type ContainerHttpOption = 'unknown_http_option' | 'enabled' | 'redirected';
|
|
3
3
|
export type ContainerPrivacy = 'unknown_privacy' | 'public' | 'private';
|
|
4
4
|
export type ContainerProtocol = 'unknown_protocol' | 'http1' | 'h2c';
|
|
5
|
+
export type ContainerSandbox = 'unknown_sandbox' | 'v1' | 'v2';
|
|
5
6
|
export type ContainerStatus = 'unknown' | 'ready' | 'deleting' | 'error' | 'locked' | 'creating' | 'pending' | 'created';
|
|
6
7
|
export type CronStatus = 'unknown' | 'ready' | 'deleting' | 'error' | 'locked' | 'creating' | 'pending';
|
|
7
8
|
export type DomainStatus = 'unknown' | 'ready' | 'deleting' | 'error' | 'creating' | 'pending';
|
|
@@ -131,6 +132,8 @@ export interface Container {
|
|
|
131
132
|
* - Enabled: Serve both HTTP and HTTPS traffic.
|
|
132
133
|
*/
|
|
133
134
|
httpOption: ContainerHttpOption;
|
|
135
|
+
/** Execution environment of the container. */
|
|
136
|
+
sandbox: ContainerSandbox;
|
|
134
137
|
/** Region in which the container will be deployed. */
|
|
135
138
|
region: Region;
|
|
136
139
|
}
|
|
@@ -302,6 +305,8 @@ export type CreateContainerRequest = {
|
|
|
302
305
|
* - Enabled: Serve both HTTP and HTTPS traffic.
|
|
303
306
|
*/
|
|
304
307
|
httpOption?: ContainerHttpOption;
|
|
308
|
+
/** Execution environment of the container. */
|
|
309
|
+
sandbox?: ContainerSandbox;
|
|
305
310
|
};
|
|
306
311
|
export type CreateCronRequest = {
|
|
307
312
|
/**
|
|
@@ -731,6 +736,8 @@ export type UpdateContainerRequest = {
|
|
|
731
736
|
* - Enabled: Serve both HTTP and HTTPS traffic.
|
|
732
737
|
*/
|
|
733
738
|
httpOption?: ContainerHttpOption;
|
|
739
|
+
/** Execution environment of the container. */
|
|
740
|
+
sandbox?: ContainerSandbox;
|
|
734
741
|
};
|
|
735
742
|
export type UpdateCronRequest = {
|
|
736
743
|
/**
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export { API } from './api.gen';
|
|
2
2
|
export * from './content.gen';
|
|
3
|
-
export type { CreateCronRequest, CreateDomainRequest, CreateFunctionRequest, CreateNamespaceRequest, CreateTokenRequest, CreateTriggerRequest, CreateTriggerRequestMnqNatsClientConfig, CreateTriggerRequestMnqSqsClientConfig, CreateTriggerRequestSqsClientConfig, Cron, CronStatus, DeleteCronRequest, DeleteDomainRequest, DeleteFunctionRequest, DeleteNamespaceRequest, DeleteTokenRequest, DeleteTriggerRequest, DeployFunctionRequest, Domain, DomainStatus, DownloadURL, Function, FunctionHttpOption, FunctionPrivacy, FunctionRuntime, FunctionStatus, GetCronRequest, GetDomainRequest, GetFunctionDownloadURLRequest, GetFunctionRequest, GetFunctionUploadURLRequest, GetNamespaceRequest, GetTokenRequest, GetTriggerRequest, IssueJWTRequest, ListCronsRequest, ListCronsRequestOrderBy, ListCronsResponse, ListDomainsRequest, ListDomainsRequestOrderBy, ListDomainsResponse, ListFunctionRuntimesRequest, ListFunctionRuntimesResponse, ListFunctionsRequest, ListFunctionsRequestOrderBy, ListFunctionsResponse, ListNamespacesRequest, ListNamespacesRequestOrderBy, ListNamespacesResponse, ListTokensRequest, ListTokensRequestOrderBy, ListTokensResponse, ListTriggersRequest, ListTriggersRequestOrderBy, ListTriggersResponse, Namespace, NamespaceStatus, Runtime, RuntimeStatus, Secret, SecretHashedValue, Token, TokenStatus, Trigger, TriggerInputType, TriggerMnqNatsClientConfig, TriggerMnqSqsClientConfig, TriggerSqsClientConfig, TriggerStatus, UpdateCronRequest, UpdateFunctionRequest, UpdateNamespaceRequest, UpdateTriggerRequest, UpdateTriggerRequestSqsClientConfig, UploadURL, } from './types.gen';
|
|
3
|
+
export type { CreateCronRequest, CreateDomainRequest, CreateFunctionRequest, CreateNamespaceRequest, CreateTokenRequest, CreateTriggerRequest, CreateTriggerRequestMnqNatsClientConfig, CreateTriggerRequestMnqSqsClientConfig, CreateTriggerRequestSqsClientConfig, Cron, CronStatus, DeleteCronRequest, DeleteDomainRequest, DeleteFunctionRequest, DeleteNamespaceRequest, DeleteTokenRequest, DeleteTriggerRequest, DeployFunctionRequest, Domain, DomainStatus, DownloadURL, Function, FunctionHttpOption, FunctionPrivacy, FunctionRuntime, FunctionSandbox, FunctionStatus, GetCronRequest, GetDomainRequest, GetFunctionDownloadURLRequest, GetFunctionRequest, GetFunctionUploadURLRequest, GetNamespaceRequest, GetTokenRequest, GetTriggerRequest, IssueJWTRequest, ListCronsRequest, ListCronsRequestOrderBy, ListCronsResponse, ListDomainsRequest, ListDomainsRequestOrderBy, ListDomainsResponse, ListFunctionRuntimesRequest, ListFunctionRuntimesResponse, ListFunctionsRequest, ListFunctionsRequestOrderBy, ListFunctionsResponse, ListNamespacesRequest, ListNamespacesRequestOrderBy, ListNamespacesResponse, ListTokensRequest, ListTokensRequestOrderBy, ListTokensResponse, ListTriggersRequest, ListTriggersRequestOrderBy, ListTriggersResponse, Namespace, NamespaceStatus, Runtime, RuntimeStatus, Secret, SecretHashedValue, Token, TokenStatus, Trigger, TriggerInputType, TriggerMnqNatsClientConfig, TriggerMnqSqsClientConfig, TriggerSqsClientConfig, TriggerStatus, UpdateCronRequest, UpdateFunctionRequest, UpdateNamespaceRequest, UpdateTriggerRequest, UpdateTriggerRequestSqsClientConfig, UploadURL, } from './types.gen';
|
|
4
4
|
export * as ValidationRules from './validation-rules.gen';
|
|
@@ -69,6 +69,7 @@ const unmarshalFunction = (data) => {
|
|
|
69
69
|
region: data.region,
|
|
70
70
|
runtime: data.runtime,
|
|
71
71
|
runtimeMessage: data.runtime_message,
|
|
72
|
+
sandbox: data.sandbox,
|
|
72
73
|
secretEnvironmentVariables: marshalling.unmarshalArrayOfObject(
|
|
73
74
|
data.secret_environment_variables,
|
|
74
75
|
unmarshalSecretHashedValue
|
|
@@ -321,6 +322,7 @@ const marshalCreateFunctionRequest = (request, defaults) => ({
|
|
|
321
322
|
namespace_id: request.namespaceId,
|
|
322
323
|
privacy: request.privacy,
|
|
323
324
|
runtime: request.runtime,
|
|
325
|
+
sandbox: request.sandbox,
|
|
324
326
|
secret_environment_variables: request.secretEnvironmentVariables !== void 0 ? request.secretEnvironmentVariables.map(
|
|
325
327
|
(elt) => marshalSecret(elt)
|
|
326
328
|
) : void 0,
|
|
@@ -402,6 +404,7 @@ const marshalUpdateFunctionRequest = (request, defaults) => ({
|
|
|
402
404
|
privacy: request.privacy,
|
|
403
405
|
redeploy: request.redeploy,
|
|
404
406
|
runtime: request.runtime,
|
|
407
|
+
sandbox: request.sandbox,
|
|
405
408
|
secret_environment_variables: request.secretEnvironmentVariables !== void 0 ? request.secretEnvironmentVariables.map(
|
|
406
409
|
(elt) => marshalSecret(elt)
|
|
407
410
|
) : void 0,
|
|
@@ -67,6 +67,7 @@ const unmarshalFunction = (data) => {
|
|
|
67
67
|
region: data.region,
|
|
68
68
|
runtime: data.runtime,
|
|
69
69
|
runtimeMessage: data.runtime_message,
|
|
70
|
+
sandbox: data.sandbox,
|
|
70
71
|
secretEnvironmentVariables: unmarshalArrayOfObject(
|
|
71
72
|
data.secret_environment_variables,
|
|
72
73
|
unmarshalSecretHashedValue
|
|
@@ -319,6 +320,7 @@ const marshalCreateFunctionRequest = (request, defaults) => ({
|
|
|
319
320
|
namespace_id: request.namespaceId,
|
|
320
321
|
privacy: request.privacy,
|
|
321
322
|
runtime: request.runtime,
|
|
323
|
+
sandbox: request.sandbox,
|
|
322
324
|
secret_environment_variables: request.secretEnvironmentVariables !== void 0 ? request.secretEnvironmentVariables.map(
|
|
323
325
|
(elt) => marshalSecret(elt)
|
|
324
326
|
) : void 0,
|
|
@@ -400,6 +402,7 @@ const marshalUpdateFunctionRequest = (request, defaults) => ({
|
|
|
400
402
|
privacy: request.privacy,
|
|
401
403
|
redeploy: request.redeploy,
|
|
402
404
|
runtime: request.runtime,
|
|
405
|
+
sandbox: request.sandbox,
|
|
403
406
|
secret_environment_variables: request.secretEnvironmentVariables !== void 0 ? request.secretEnvironmentVariables.map(
|
|
404
407
|
(elt) => marshalSecret(elt)
|
|
405
408
|
) : void 0,
|
|
@@ -4,6 +4,7 @@ export type DomainStatus = 'unknown' | 'ready' | 'deleting' | 'error' | 'creatin
|
|
|
4
4
|
export type FunctionHttpOption = 'unknown_http_option' | 'enabled' | 'redirected';
|
|
5
5
|
export type FunctionPrivacy = 'unknown_privacy' | 'public' | 'private';
|
|
6
6
|
export type FunctionRuntime = 'unknown_runtime' | 'golang' | 'python' | 'python3' | 'node8' | 'node10' | 'node14' | 'node16' | 'node17' | 'python37' | 'python38' | 'python39' | 'python310' | 'go113' | 'go117' | 'go118' | 'node18' | 'rust165' | 'go119' | 'python311' | 'php82' | 'node19' | 'go120' | 'node20' | 'go121' | 'node22' | 'python312' | 'php83' | 'go122' | 'rust179';
|
|
7
|
+
export type FunctionSandbox = 'unknown_sandbox' | 'v1' | 'v2';
|
|
7
8
|
export type FunctionStatus = 'unknown' | 'ready' | 'deleting' | 'error' | 'locked' | 'creating' | 'pending' | 'created';
|
|
8
9
|
export type ListCronsRequestOrderBy = 'created_at_asc' | 'created_at_desc';
|
|
9
10
|
export type ListDomainsRequestOrderBy = 'created_at_asc' | 'created_at_desc' | 'hostname_asc' | 'hostname_desc';
|
|
@@ -170,6 +171,8 @@ export interface Function {
|
|
|
170
171
|
*/
|
|
171
172
|
httpOption: FunctionHttpOption;
|
|
172
173
|
runtimeMessage: string;
|
|
174
|
+
/** Execution environment of the function. */
|
|
175
|
+
sandbox: FunctionSandbox;
|
|
173
176
|
}
|
|
174
177
|
export interface Namespace {
|
|
175
178
|
/** UUID of the namespace. */
|
|
@@ -327,6 +330,8 @@ export type CreateFunctionRequest = {
|
|
|
327
330
|
* - Enabled: Serve both HTTP and HTTPS traffic.
|
|
328
331
|
*/
|
|
329
332
|
httpOption?: FunctionHttpOption;
|
|
333
|
+
/** Execution environment of the function. */
|
|
334
|
+
sandbox?: FunctionSandbox;
|
|
330
335
|
};
|
|
331
336
|
export type CreateNamespaceRequest = {
|
|
332
337
|
/**
|
|
@@ -776,6 +781,8 @@ export type UpdateFunctionRequest = {
|
|
|
776
781
|
* - Enabled: Serve both HTTP and HTTPS traffic.
|
|
777
782
|
*/
|
|
778
783
|
httpOption?: FunctionHttpOption;
|
|
784
|
+
/** Execution environment of the function. */
|
|
785
|
+
sandbox?: FunctionSandbox;
|
|
779
786
|
};
|
|
780
787
|
export type UpdateNamespaceRequest = {
|
|
781
788
|
/**
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
import { API as ParentAPI } from '../../../bridge';
|
|
2
|
+
import type { Region, WaitForOptions } from '../../../bridge';
|
|
3
|
+
import type { AddDeploymentACLRulesRequest, AddDeploymentACLRulesResponse, CreateDeploymentRequest, CreateEndpointRequest, DeleteDeploymentACLRuleRequest, DeleteDeploymentRequest, DeleteEndpointRequest, Deployment, Endpoint, Eula, GetDeploymentCertificateRequest, GetDeploymentRequest, GetModelEulaRequest, GetModelRequest, ListDeploymentACLRulesRequest, ListDeploymentACLRulesResponse, ListDeploymentsRequest, ListDeploymentsResponse, ListModelsRequest, ListModelsResponse, ListNodeTypesRequest, ListNodeTypesResponse, Model, SetDeploymentACLRulesRequest, SetDeploymentACLRulesResponse, UpdateDeploymentRequest, UpdateEndpointRequest } from './types.gen';
|
|
4
|
+
/**
|
|
5
|
+
* Managed Inference API.
|
|
6
|
+
*
|
|
7
|
+
* This API allows you to manage your Inference services.
|
|
8
|
+
*/
|
|
9
|
+
export declare class API extends ParentAPI {
|
|
10
|
+
/** Lists the available regions of the API. */
|
|
11
|
+
static readonly LOCALITIES: Region[];
|
|
12
|
+
protected pageOfListDeployments: (request?: Readonly<ListDeploymentsRequest>) => Promise<ListDeploymentsResponse>;
|
|
13
|
+
/**
|
|
14
|
+
* List inference deployments. List all your inference deployments.
|
|
15
|
+
*
|
|
16
|
+
* @param request - The request {@link ListDeploymentsRequest}
|
|
17
|
+
* @returns A Promise of ListDeploymentsResponse
|
|
18
|
+
*/
|
|
19
|
+
listDeployments: (request?: Readonly<ListDeploymentsRequest>) => Promise<ListDeploymentsResponse> & {
|
|
20
|
+
all: () => Promise<Deployment[]>;
|
|
21
|
+
[Symbol.asyncIterator]: () => AsyncGenerator<Deployment[], void, void>;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* Get a deployment. Get the deployment for the given ID.
|
|
25
|
+
*
|
|
26
|
+
* @param request - The request {@link GetDeploymentRequest}
|
|
27
|
+
* @returns A Promise of Deployment
|
|
28
|
+
*/
|
|
29
|
+
getDeployment: (request: Readonly<GetDeploymentRequest>) => Promise<Deployment>;
|
|
30
|
+
/**
|
|
31
|
+
* Waits for {@link Deployment} to be in a final state.
|
|
32
|
+
*
|
|
33
|
+
* @param request - The request {@link GetDeploymentRequest}
|
|
34
|
+
* @param options - The waiting options
|
|
35
|
+
* @returns A Promise of Deployment
|
|
36
|
+
*/
|
|
37
|
+
waitForDeployment: (request: Readonly<GetDeploymentRequest>, options?: Readonly<WaitForOptions<Deployment>>) => Promise<Deployment>;
|
|
38
|
+
/**
|
|
39
|
+
* Create a deployment. Create a new inference deployment related to a
|
|
40
|
+
* specific model.
|
|
41
|
+
*
|
|
42
|
+
* @param request - The request {@link CreateDeploymentRequest}
|
|
43
|
+
* @returns A Promise of Deployment
|
|
44
|
+
*/
|
|
45
|
+
createDeployment: (request: Readonly<CreateDeploymentRequest>) => Promise<Deployment>;
|
|
46
|
+
/**
|
|
47
|
+
* Update a deployment. Update an existing inference deployment.
|
|
48
|
+
*
|
|
49
|
+
* @param request - The request {@link UpdateDeploymentRequest}
|
|
50
|
+
* @returns A Promise of Deployment
|
|
51
|
+
*/
|
|
52
|
+
updateDeployment: (request: Readonly<UpdateDeploymentRequest>) => Promise<Deployment>;
|
|
53
|
+
/**
|
|
54
|
+
* Delete a deployment. Delete an existing inference deployment.
|
|
55
|
+
*
|
|
56
|
+
* @param request - The request {@link DeleteDeploymentRequest}
|
|
57
|
+
* @returns A Promise of Deployment
|
|
58
|
+
*/
|
|
59
|
+
deleteDeployment: (request: Readonly<DeleteDeploymentRequest>) => Promise<Deployment>;
|
|
60
|
+
/**
|
|
61
|
+
* Get the CA certificate. Get the CA certificate used for the deployment of
|
|
62
|
+
* private endpoints. The CA certificate will be returned as a PEM file.
|
|
63
|
+
*
|
|
64
|
+
* @param request - The request {@link GetDeploymentCertificateRequest}
|
|
65
|
+
* @returns A Promise of Blob
|
|
66
|
+
*/
|
|
67
|
+
getDeploymentCertificate: (request: Readonly<GetDeploymentCertificateRequest>) => Promise<Blob>;
|
|
68
|
+
/**
|
|
69
|
+
* Create an endpoint. Create a new Endpoint related to a specific deployment.
|
|
70
|
+
*
|
|
71
|
+
* @param request - The request {@link CreateEndpointRequest}
|
|
72
|
+
* @returns A Promise of Endpoint
|
|
73
|
+
*/
|
|
74
|
+
createEndpoint: (request: Readonly<CreateEndpointRequest>) => Promise<Endpoint>;
|
|
75
|
+
/**
|
|
76
|
+
* Update an endpoint. Update an existing Endpoint.
|
|
77
|
+
*
|
|
78
|
+
* @param request - The request {@link UpdateEndpointRequest}
|
|
79
|
+
* @returns A Promise of Endpoint
|
|
80
|
+
*/
|
|
81
|
+
updateEndpoint: (request: Readonly<UpdateEndpointRequest>) => Promise<Endpoint>;
|
|
82
|
+
/**
|
|
83
|
+
* Delete an endpoint. Delete an existing Endpoint.
|
|
84
|
+
*
|
|
85
|
+
* @param request - The request {@link DeleteEndpointRequest}
|
|
86
|
+
*/
|
|
87
|
+
deleteEndpoint: (request: Readonly<DeleteEndpointRequest>) => Promise<void>;
|
|
88
|
+
protected pageOfListDeploymentACLRules: (request: Readonly<ListDeploymentACLRulesRequest>) => Promise<ListDeploymentACLRulesResponse>;
|
|
89
|
+
/**
|
|
90
|
+
* List your ACLs. List ACLs for a specific deployment.
|
|
91
|
+
*
|
|
92
|
+
* @param request - The request {@link ListDeploymentACLRulesRequest}
|
|
93
|
+
* @returns A Promise of ListDeploymentACLRulesResponse
|
|
94
|
+
*/
|
|
95
|
+
listDeploymentACLRules: (request: Readonly<ListDeploymentACLRulesRequest>) => Promise<ListDeploymentACLRulesResponse> & {
|
|
96
|
+
all: () => Promise<import("./types.gen").ACLRule[]>;
|
|
97
|
+
[Symbol.asyncIterator]: () => AsyncGenerator<import("./types.gen").ACLRule[], void, void>;
|
|
98
|
+
};
|
|
99
|
+
/**
|
|
100
|
+
* Add new ACLs. Add new ACL rules for a specific deployment.
|
|
101
|
+
*
|
|
102
|
+
* @param request - The request {@link AddDeploymentACLRulesRequest}
|
|
103
|
+
* @returns A Promise of AddDeploymentACLRulesResponse
|
|
104
|
+
*/
|
|
105
|
+
addDeploymentACLRules: (request: Readonly<AddDeploymentACLRulesRequest>) => Promise<AddDeploymentACLRulesResponse>;
|
|
106
|
+
/**
|
|
107
|
+
* Set new ACL. Set new ACL rules for a specific deployment.
|
|
108
|
+
*
|
|
109
|
+
* @param request - The request {@link SetDeploymentACLRulesRequest}
|
|
110
|
+
* @returns A Promise of SetDeploymentACLRulesResponse
|
|
111
|
+
*/
|
|
112
|
+
setDeploymentACLRules: (request: Readonly<SetDeploymentACLRulesRequest>) => Promise<SetDeploymentACLRulesResponse>;
|
|
113
|
+
/**
|
|
114
|
+
* Delete an exising ACL.
|
|
115
|
+
*
|
|
116
|
+
* @param request - The request {@link DeleteDeploymentACLRuleRequest}
|
|
117
|
+
*/
|
|
118
|
+
deleteDeploymentACLRule: (request: Readonly<DeleteDeploymentACLRuleRequest>) => Promise<void>;
|
|
119
|
+
protected pageOfListModels: (request?: Readonly<ListModelsRequest>) => Promise<ListModelsResponse>;
|
|
120
|
+
/**
|
|
121
|
+
* List models. List all available models.
|
|
122
|
+
*
|
|
123
|
+
* @param request - The request {@link ListModelsRequest}
|
|
124
|
+
* @returns A Promise of ListModelsResponse
|
|
125
|
+
*/
|
|
126
|
+
listModels: (request?: Readonly<ListModelsRequest>) => Promise<ListModelsResponse> & {
|
|
127
|
+
all: () => Promise<Model[]>;
|
|
128
|
+
[Symbol.asyncIterator]: () => AsyncGenerator<Model[], void, void>;
|
|
129
|
+
};
|
|
130
|
+
/**
|
|
131
|
+
* Get a model. Get the model for the given ID.
|
|
132
|
+
*
|
|
133
|
+
* @param request - The request {@link GetModelRequest}
|
|
134
|
+
* @returns A Promise of Model
|
|
135
|
+
*/
|
|
136
|
+
getModel: (request: Readonly<GetModelRequest>) => Promise<Model>;
|
|
137
|
+
getModelEula: (request: Readonly<GetModelEulaRequest>) => Promise<Eula>;
|
|
138
|
+
protected pageOfListNodeTypes: (request: Readonly<ListNodeTypesRequest>) => Promise<ListNodeTypesResponse>;
|
|
139
|
+
/**
|
|
140
|
+
* List available node types. List all available node types. By default, the
|
|
141
|
+
* node types returned in the list are ordered by creation date in ascending
|
|
142
|
+
* order, though this can be modified via the `order_by` field.
|
|
143
|
+
*
|
|
144
|
+
* @param request - The request {@link ListNodeTypesRequest}
|
|
145
|
+
* @returns A Promise of ListNodeTypesResponse
|
|
146
|
+
*/
|
|
147
|
+
listNodeTypes: (request: Readonly<ListNodeTypesRequest>) => Promise<ListNodeTypesResponse> & {
|
|
148
|
+
all: () => Promise<import("./types.gen").NodeType[]>;
|
|
149
|
+
[Symbol.asyncIterator]: () => AsyncGenerator<import("./types.gen").NodeType[], void, void>;
|
|
150
|
+
};
|
|
151
|
+
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { API } from './api.gen';
|
|
2
|
+
export * from './content.gen';
|
|
3
|
+
export type { ACLRule, ACLRuleRequest, AddDeploymentACLRulesRequest, AddDeploymentACLRulesResponse, CreateDeploymentRequest, CreateEndpointRequest, DeleteDeploymentACLRuleRequest, DeleteDeploymentRequest, DeleteEndpointRequest, Deployment, DeploymentStatus, Endpoint, EndpointPrivateNetworkDetails, EndpointPublicAccessDetails, EndpointSpec, EndpointSpecPrivateNetwork, EndpointSpecPublic, Eula, GetDeploymentCertificateRequest, GetDeploymentRequest, GetModelEulaRequest, GetModelRequest, ListDeploymentACLRulesRequest, ListDeploymentACLRulesResponse, ListDeploymentsRequest, ListDeploymentsRequestOrderBy, ListDeploymentsResponse, ListModelsRequest, ListModelsRequestOrderBy, ListModelsResponse, ListNodeTypesRequest, ListNodeTypesResponse, Model, ModelS3Model, NodeType, NodeTypeStock, SetDeploymentACLRulesRequest, SetDeploymentACLRulesResponse, UpdateDeploymentRequest, UpdateEndpointRequest, } from './types.gen';
|
|
4
|
+
export * as ValidationRules from './validation-rules.gen';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { DefaultValues } from '../../../bridge';
|
|
2
|
+
import type { AddDeploymentACLRulesRequest, AddDeploymentACLRulesResponse, CreateDeploymentRequest, CreateEndpointRequest, Deployment, Endpoint, Eula, ListDeploymentACLRulesResponse, ListDeploymentsResponse, ListModelsResponse, ListNodeTypesResponse, Model, SetDeploymentACLRulesRequest, SetDeploymentACLRulesResponse, UpdateDeploymentRequest, UpdateEndpointRequest } from './types.gen';
|
|
3
|
+
export declare const unmarshalEndpoint: (data: unknown) => Endpoint;
|
|
4
|
+
export declare const unmarshalDeployment: (data: unknown) => Deployment;
|
|
5
|
+
export declare const unmarshalModel: (data: unknown) => Model;
|
|
6
|
+
export declare const unmarshalAddDeploymentACLRulesResponse: (data: unknown) => AddDeploymentACLRulesResponse;
|
|
7
|
+
export declare const unmarshalEula: (data: unknown) => Eula;
|
|
8
|
+
export declare const unmarshalListDeploymentACLRulesResponse: (data: unknown) => ListDeploymentACLRulesResponse;
|
|
9
|
+
export declare const unmarshalListDeploymentsResponse: (data: unknown) => ListDeploymentsResponse;
|
|
10
|
+
export declare const unmarshalListModelsResponse: (data: unknown) => ListModelsResponse;
|
|
11
|
+
export declare const unmarshalListNodeTypesResponse: (data: unknown) => ListNodeTypesResponse;
|
|
12
|
+
export declare const unmarshalSetDeploymentACLRulesResponse: (data: unknown) => SetDeploymentACLRulesResponse;
|
|
13
|
+
export declare const marshalAddDeploymentACLRulesRequest: (request: AddDeploymentACLRulesRequest, defaults: DefaultValues) => Record<string, unknown>;
|
|
14
|
+
export declare const marshalCreateDeploymentRequest: (request: CreateDeploymentRequest, defaults: DefaultValues) => Record<string, unknown>;
|
|
15
|
+
export declare const marshalCreateEndpointRequest: (request: CreateEndpointRequest, defaults: DefaultValues) => Record<string, unknown>;
|
|
16
|
+
export declare const marshalSetDeploymentACLRulesRequest: (request: SetDeploymentACLRulesRequest, defaults: DefaultValues) => Record<string, unknown>;
|
|
17
|
+
export declare const marshalUpdateDeploymentRequest: (request: UpdateDeploymentRequest, defaults: DefaultValues) => Record<string, unknown>;
|
|
18
|
+
export declare const marshalUpdateEndpointRequest: (request: UpdateEndpointRequest, defaults: DefaultValues) => Record<string, unknown>;
|
|
@@ -0,0 +1,435 @@
|
|
|
1
|
+
import type { Region } from '../../../bridge';
|
|
2
|
+
export type DeploymentStatus = 'unknown_status' | 'creating' | 'deploying' | 'ready' | 'error' | 'deleting' | 'locked';
|
|
3
|
+
export type ListDeploymentsRequestOrderBy = 'created_at_desc' | 'created_at_asc' | 'name_asc' | 'name_desc';
|
|
4
|
+
export type ListModelsRequestOrderBy = 'created_at_asc' | 'created_at_desc' | 'name_asc' | 'name_desc';
|
|
5
|
+
export type NodeTypeStock = 'unknown_stock' | 'low_stock' | 'out_of_stock' | 'available';
|
|
6
|
+
export interface EndpointPrivateNetworkDetails {
|
|
7
|
+
/** ID of the Private Network. */
|
|
8
|
+
privateNetworkId: string;
|
|
9
|
+
}
|
|
10
|
+
export interface EndpointPublicAccessDetails {
|
|
11
|
+
}
|
|
12
|
+
export interface EndpointSpecPrivateNetwork {
|
|
13
|
+
/** ID of the Private Network. */
|
|
14
|
+
privateNetworkId: string;
|
|
15
|
+
}
|
|
16
|
+
export interface EndpointSpecPublic {
|
|
17
|
+
}
|
|
18
|
+
export interface Endpoint {
|
|
19
|
+
/** Unique identifier. */
|
|
20
|
+
id: string;
|
|
21
|
+
/**
|
|
22
|
+
* For private endpoints, the URL will be accessible only from the Private
|
|
23
|
+
* Network. In addition, private endpoints will expose a CA certificate that
|
|
24
|
+
* can be used to verify the server's identity. This CA certificate can be
|
|
25
|
+
* retrieved using the `GetDeploymentCertificate` API call.
|
|
26
|
+
*/
|
|
27
|
+
url: string;
|
|
28
|
+
/**
|
|
29
|
+
* Defines whether the endpoint is public.
|
|
30
|
+
*
|
|
31
|
+
* One-of ('details'): at most one of 'publicAccess', 'privateNetwork' could
|
|
32
|
+
* be set.
|
|
33
|
+
*/
|
|
34
|
+
publicAccess?: EndpointPublicAccessDetails;
|
|
35
|
+
/**
|
|
36
|
+
* Details of the Private Network.
|
|
37
|
+
*
|
|
38
|
+
* One-of ('details'): at most one of 'publicAccess', 'privateNetwork' could
|
|
39
|
+
* be set.
|
|
40
|
+
*/
|
|
41
|
+
privateNetwork?: EndpointPrivateNetworkDetails;
|
|
42
|
+
/** Defines whether the authentication is disabled. */
|
|
43
|
+
disableAuth: boolean;
|
|
44
|
+
}
|
|
45
|
+
export interface ModelS3Model {
|
|
46
|
+
s3Url: string;
|
|
47
|
+
pythonDependencies: Record<string, string>;
|
|
48
|
+
nodeType?: string;
|
|
49
|
+
tritonServerVersion?: string;
|
|
50
|
+
}
|
|
51
|
+
export interface ACLRuleRequest {
|
|
52
|
+
/**
|
|
53
|
+
* It can be specified as a single IP address or a range of IP addresses in
|
|
54
|
+
* CIDR notation.
|
|
55
|
+
*/
|
|
56
|
+
ip: string;
|
|
57
|
+
/** Description of the ACL rule. */
|
|
58
|
+
description: string;
|
|
59
|
+
}
|
|
60
|
+
export interface ACLRule {
|
|
61
|
+
/** Unique identifier. */
|
|
62
|
+
id: string;
|
|
63
|
+
/** Allowed IP address or CIDR range. */
|
|
64
|
+
ip: string;
|
|
65
|
+
/** Description of the ACL rule. */
|
|
66
|
+
description: string;
|
|
67
|
+
}
|
|
68
|
+
export interface EndpointSpec {
|
|
69
|
+
/**
|
|
70
|
+
* Set the endpoint as public.
|
|
71
|
+
*
|
|
72
|
+
* One-of ('spec'): at most one of 'public', 'privateNetwork' could be set.
|
|
73
|
+
*/
|
|
74
|
+
public?: EndpointSpecPublic;
|
|
75
|
+
/**
|
|
76
|
+
* Private endpoints are only accessible from the Private Network.
|
|
77
|
+
*
|
|
78
|
+
* One-of ('spec'): at most one of 'public', 'privateNetwork' could be set.
|
|
79
|
+
*/
|
|
80
|
+
privateNetwork?: EndpointSpecPrivateNetwork;
|
|
81
|
+
/**
|
|
82
|
+
* By default, deployments are protected by IAM authentication. When setting
|
|
83
|
+
* this field to true, the authentication will be disabled.
|
|
84
|
+
*/
|
|
85
|
+
disableAuth: boolean;
|
|
86
|
+
}
|
|
87
|
+
export interface Deployment {
|
|
88
|
+
/** Unique identifier. */
|
|
89
|
+
id: string;
|
|
90
|
+
/** Name of the deployment. */
|
|
91
|
+
name: string;
|
|
92
|
+
/** Project ID. */
|
|
93
|
+
projectId: string;
|
|
94
|
+
/** Status of the deployment. */
|
|
95
|
+
status: DeploymentStatus;
|
|
96
|
+
/** List of tags applied to the deployment. */
|
|
97
|
+
tags: string[];
|
|
98
|
+
/** Node type of the deployment. */
|
|
99
|
+
nodeType: string;
|
|
100
|
+
/** List of endpoints. */
|
|
101
|
+
endpoints: Endpoint[];
|
|
102
|
+
/** Current size of the pool. */
|
|
103
|
+
size: number;
|
|
104
|
+
/** Defines the minimum size of the pool. */
|
|
105
|
+
minSize: number;
|
|
106
|
+
/** Defines the maximum size of the pool. */
|
|
107
|
+
maxSize: number;
|
|
108
|
+
/** Displays information if your deployment is in error state. */
|
|
109
|
+
errorMessage?: string;
|
|
110
|
+
/** The inference model used for the deployment. */
|
|
111
|
+
modelName: string;
|
|
112
|
+
/** ID of the model used for the deployment. */
|
|
113
|
+
modelId: string;
|
|
114
|
+
/** Creation date of the deployment. */
|
|
115
|
+
createdAt?: Date;
|
|
116
|
+
/** Last modification date of the deployment. */
|
|
117
|
+
updatedAt?: Date;
|
|
118
|
+
/** Region of the deployment. */
|
|
119
|
+
region: Region;
|
|
120
|
+
}
|
|
121
|
+
export interface Model {
|
|
122
|
+
/** Unique identifier. */
|
|
123
|
+
id: string;
|
|
124
|
+
/** Unique Name identifier. */
|
|
125
|
+
name: string;
|
|
126
|
+
/** Project ID. */
|
|
127
|
+
projectId: string;
|
|
128
|
+
/** Name of the model provider. */
|
|
129
|
+
provider: string;
|
|
130
|
+
/** List of tags applied to the model. */
|
|
131
|
+
tags: string[];
|
|
132
|
+
/** Purpose of the model. */
|
|
133
|
+
description: string;
|
|
134
|
+
/** Defines whether the model has an end user licence agreement. */
|
|
135
|
+
hasEula: boolean;
|
|
136
|
+
/** Creation date of the model. */
|
|
137
|
+
createdAt?: Date;
|
|
138
|
+
/** Last modification date of the model. */
|
|
139
|
+
updatedAt?: Date;
|
|
140
|
+
/** Region of the model. */
|
|
141
|
+
region: Region;
|
|
142
|
+
/**
|
|
143
|
+
* S3 URL pointing to the model source weight.
|
|
144
|
+
*
|
|
145
|
+
* One-of ('source'): at most one of 's3Model' could be set.
|
|
146
|
+
*/
|
|
147
|
+
s3Model?: ModelS3Model;
|
|
148
|
+
/** Defines whether the model is public or not. */
|
|
149
|
+
isPublic: boolean;
|
|
150
|
+
/** Names of the node types compatible with the model. */
|
|
151
|
+
compatibleNodeTypes: string[];
|
|
152
|
+
/** Quantization level of the model. */
|
|
153
|
+
quantizationLevel: string;
|
|
154
|
+
}
|
|
155
|
+
export interface NodeType {
|
|
156
|
+
/** Name of the node type. */
|
|
157
|
+
name: string;
|
|
158
|
+
/** Current stock status for the node type. */
|
|
159
|
+
stockStatus: NodeTypeStock;
|
|
160
|
+
/** Current specs of the offer. */
|
|
161
|
+
description: string;
|
|
162
|
+
/** Number of virtual CPUs. */
|
|
163
|
+
vcpus: number;
|
|
164
|
+
/** Quantity of RAM. */
|
|
165
|
+
memory: number;
|
|
166
|
+
/** Quantity of GPU RAM. */
|
|
167
|
+
vram: number;
|
|
168
|
+
/** The node type is currently disabled. */
|
|
169
|
+
disabled: boolean;
|
|
170
|
+
/** The node type is currently in beta. */
|
|
171
|
+
beta: boolean;
|
|
172
|
+
/** Creation date of the node type. */
|
|
173
|
+
createdAt?: Date;
|
|
174
|
+
/** Last modification date of the node type. */
|
|
175
|
+
updatedAt?: Date;
|
|
176
|
+
/** Number of GPUs. */
|
|
177
|
+
gpus: number;
|
|
178
|
+
/** Region of the node type. */
|
|
179
|
+
region: Region;
|
|
180
|
+
}
|
|
181
|
+
export type AddDeploymentACLRulesRequest = {
|
|
182
|
+
/**
|
|
183
|
+
* Region to target. If none is passed will use default region from the
|
|
184
|
+
* config.
|
|
185
|
+
*/
|
|
186
|
+
region?: Region;
|
|
187
|
+
/** ID of the deployment to add ACL rules to. */
|
|
188
|
+
deploymentId: string;
|
|
189
|
+
/** List of ACL rules to add. */
|
|
190
|
+
acls?: ACLRuleRequest[];
|
|
191
|
+
};
|
|
192
|
+
export interface AddDeploymentACLRulesResponse {
|
|
193
|
+
/** List of ACL rules added. */
|
|
194
|
+
rules: ACLRule[];
|
|
195
|
+
}
|
|
196
|
+
export type CreateDeploymentRequest = {
|
|
197
|
+
/**
|
|
198
|
+
* Region to target. If none is passed will use default region from the
|
|
199
|
+
* config.
|
|
200
|
+
*/
|
|
201
|
+
region?: Region;
|
|
202
|
+
/** Name of the deployment. */
|
|
203
|
+
name?: string;
|
|
204
|
+
/** ID of the Project to create the deployment in. */
|
|
205
|
+
projectId?: string;
|
|
206
|
+
/** Name of the model to use. */
|
|
207
|
+
modelName: string;
|
|
208
|
+
/**
|
|
209
|
+
* If the model has an EULA, you must accept it before proceeding. The terms
|
|
210
|
+
* of the EULA can be retrieved using the `GetModelEula` API call.
|
|
211
|
+
*/
|
|
212
|
+
acceptEula?: boolean;
|
|
213
|
+
/** Name of the node type to use. */
|
|
214
|
+
nodeType: string;
|
|
215
|
+
/** List of tags to apply to the deployment. */
|
|
216
|
+
tags?: string[];
|
|
217
|
+
/** Defines the minimum size of the pool. */
|
|
218
|
+
minSize?: number;
|
|
219
|
+
/** Defines the maximum size of the pool. */
|
|
220
|
+
maxSize?: number;
|
|
221
|
+
/** List of endpoints to create. */
|
|
222
|
+
endpoints: EndpointSpec[];
|
|
223
|
+
};
|
|
224
|
+
export type CreateEndpointRequest = {
|
|
225
|
+
/**
|
|
226
|
+
* Region to target. If none is passed will use default region from the
|
|
227
|
+
* config.
|
|
228
|
+
*/
|
|
229
|
+
region?: Region;
|
|
230
|
+
/** ID of the deployment to create the endpoint for. */
|
|
231
|
+
deploymentId: string;
|
|
232
|
+
/** Specification of the endpoint. */
|
|
233
|
+
endpoint: EndpointSpec;
|
|
234
|
+
};
|
|
235
|
+
export type DeleteDeploymentACLRuleRequest = {
|
|
236
|
+
/**
|
|
237
|
+
* Region to target. If none is passed will use default region from the
|
|
238
|
+
* config.
|
|
239
|
+
*/
|
|
240
|
+
region?: Region;
|
|
241
|
+
/** ID of the ACL rule to delete. */
|
|
242
|
+
aclId: string;
|
|
243
|
+
};
|
|
244
|
+
export type DeleteDeploymentRequest = {
|
|
245
|
+
/**
|
|
246
|
+
* Region to target. If none is passed will use default region from the
|
|
247
|
+
* config.
|
|
248
|
+
*/
|
|
249
|
+
region?: Region;
|
|
250
|
+
/** ID of the deployment to delete. */
|
|
251
|
+
deploymentId: string;
|
|
252
|
+
};
|
|
253
|
+
export type DeleteEndpointRequest = {
|
|
254
|
+
/**
|
|
255
|
+
* Region to target. If none is passed will use default region from the
|
|
256
|
+
* config.
|
|
257
|
+
*/
|
|
258
|
+
region?: Region;
|
|
259
|
+
/** ID of the endpoint to delete. */
|
|
260
|
+
endpointId: string;
|
|
261
|
+
};
|
|
262
|
+
export interface Eula {
|
|
263
|
+
/** Content of the end user licence agreement. */
|
|
264
|
+
content: string;
|
|
265
|
+
}
|
|
266
|
+
export type GetDeploymentCertificateRequest = {
|
|
267
|
+
/**
|
|
268
|
+
* Region to target. If none is passed will use default region from the
|
|
269
|
+
* config.
|
|
270
|
+
*/
|
|
271
|
+
region?: Region;
|
|
272
|
+
deploymentId: string;
|
|
273
|
+
};
|
|
274
|
+
export type GetDeploymentRequest = {
|
|
275
|
+
/**
|
|
276
|
+
* Region to target. If none is passed will use default region from the
|
|
277
|
+
* config.
|
|
278
|
+
*/
|
|
279
|
+
region?: Region;
|
|
280
|
+
/** ID of the deployment to get. */
|
|
281
|
+
deploymentId: string;
|
|
282
|
+
};
|
|
283
|
+
export type GetModelEulaRequest = {
|
|
284
|
+
/**
|
|
285
|
+
* Region to target. If none is passed will use default region from the
|
|
286
|
+
* config.
|
|
287
|
+
*/
|
|
288
|
+
region?: Region;
|
|
289
|
+
modelId: string;
|
|
290
|
+
};
|
|
291
|
+
export type GetModelRequest = {
|
|
292
|
+
/**
|
|
293
|
+
* Region to target. If none is passed will use default region from the
|
|
294
|
+
* config.
|
|
295
|
+
*/
|
|
296
|
+
region?: Region;
|
|
297
|
+
/** ID of the model to get. */
|
|
298
|
+
modelId: string;
|
|
299
|
+
};
|
|
300
|
+
export type ListDeploymentACLRulesRequest = {
|
|
301
|
+
/**
|
|
302
|
+
* Region to target. If none is passed will use default region from the
|
|
303
|
+
* config.
|
|
304
|
+
*/
|
|
305
|
+
region?: Region;
|
|
306
|
+
/** ID of the deployment to list ACL rules for. */
|
|
307
|
+
deploymentId: string;
|
|
308
|
+
/** Page number to return. */
|
|
309
|
+
page?: number;
|
|
310
|
+
/** Maximum number of ACL rules to return per page. */
|
|
311
|
+
pageSize?: number;
|
|
312
|
+
};
|
|
313
|
+
export interface ListDeploymentACLRulesResponse {
|
|
314
|
+
/** List of ACL rules on the current page. */
|
|
315
|
+
rules: ACLRule[];
|
|
316
|
+
/** Total number of ACL rules. */
|
|
317
|
+
totalCount: number;
|
|
318
|
+
}
|
|
319
|
+
export type ListDeploymentsRequest = {
|
|
320
|
+
/**
|
|
321
|
+
* Region to target. If none is passed will use default region from the
|
|
322
|
+
* config.
|
|
323
|
+
*/
|
|
324
|
+
region?: Region;
|
|
325
|
+
/** Page number to return. */
|
|
326
|
+
page?: number;
|
|
327
|
+
/** Maximum number of deployments to return per page. */
|
|
328
|
+
pageSize?: number;
|
|
329
|
+
/** Order in which to return results. */
|
|
330
|
+
orderBy?: ListDeploymentsRequestOrderBy;
|
|
331
|
+
/** Filter by Project ID. */
|
|
332
|
+
projectId?: string;
|
|
333
|
+
/** Filter by Organization ID. */
|
|
334
|
+
organizationId?: string;
|
|
335
|
+
/** Filter by deployment name. */
|
|
336
|
+
name?: string;
|
|
337
|
+
/** Filter by tags. */
|
|
338
|
+
tags?: string[];
|
|
339
|
+
};
|
|
340
|
+
export interface ListDeploymentsResponse {
|
|
341
|
+
/** List of deployments on the current page. */
|
|
342
|
+
deployments: Deployment[];
|
|
343
|
+
/** Total number of deployments. */
|
|
344
|
+
totalCount: number;
|
|
345
|
+
}
|
|
346
|
+
export type ListModelsRequest = {
|
|
347
|
+
/**
|
|
348
|
+
* Region to target. If none is passed will use default region from the
|
|
349
|
+
* config.
|
|
350
|
+
*/
|
|
351
|
+
region?: Region;
|
|
352
|
+
/** Order in which to return results. */
|
|
353
|
+
orderBy?: ListModelsRequestOrderBy;
|
|
354
|
+
/** Page number to return. */
|
|
355
|
+
page?: number;
|
|
356
|
+
/** Maximum number of models to return per page. */
|
|
357
|
+
pageSize?: number;
|
|
358
|
+
/** Filter by Project ID. */
|
|
359
|
+
projectId?: string;
|
|
360
|
+
/** Filter by model name. */
|
|
361
|
+
name?: string;
|
|
362
|
+
/** Filter by tags. */
|
|
363
|
+
tags?: string[];
|
|
364
|
+
};
|
|
365
|
+
export interface ListModelsResponse {
|
|
366
|
+
/** List of models on the current page. */
|
|
367
|
+
models: Model[];
|
|
368
|
+
/** Total number of models. */
|
|
369
|
+
totalCount: number;
|
|
370
|
+
}
|
|
371
|
+
export type ListNodeTypesRequest = {
|
|
372
|
+
/**
|
|
373
|
+
* Region to target. If none is passed will use default region from the
|
|
374
|
+
* config.
|
|
375
|
+
*/
|
|
376
|
+
region?: Region;
|
|
377
|
+
/** Page number to return. */
|
|
378
|
+
page?: number;
|
|
379
|
+
/** Maximum number of node types to return per page. */
|
|
380
|
+
pageSize?: number;
|
|
381
|
+
/** Include disabled node types in the response. */
|
|
382
|
+
includeDisabledTypes: boolean;
|
|
383
|
+
};
|
|
384
|
+
export interface ListNodeTypesResponse {
|
|
385
|
+
/** List of node types. */
|
|
386
|
+
nodeTypes: NodeType[];
|
|
387
|
+
/** Total number of node types. */
|
|
388
|
+
totalCount: number;
|
|
389
|
+
}
|
|
390
|
+
export type SetDeploymentACLRulesRequest = {
|
|
391
|
+
/**
|
|
392
|
+
* Region to target. If none is passed will use default region from the
|
|
393
|
+
* config.
|
|
394
|
+
*/
|
|
395
|
+
region?: Region;
|
|
396
|
+
/** ID of the deployment to set ACL rules for. */
|
|
397
|
+
deploymentId: string;
|
|
398
|
+
/** All existing ACL rules will be replaced by the new ones. */
|
|
399
|
+
acls?: ACLRuleRequest[];
|
|
400
|
+
};
|
|
401
|
+
export interface SetDeploymentACLRulesResponse {
|
|
402
|
+
/** List of ACL rules that were set. */
|
|
403
|
+
rules: ACLRule[];
|
|
404
|
+
}
|
|
405
|
+
export type UpdateDeploymentRequest = {
|
|
406
|
+
/**
|
|
407
|
+
* Region to target. If none is passed will use default region from the
|
|
408
|
+
* config.
|
|
409
|
+
*/
|
|
410
|
+
region?: Region;
|
|
411
|
+
/** ID of the deployment to update. */
|
|
412
|
+
deploymentId: string;
|
|
413
|
+
/** Name of the deployment. */
|
|
414
|
+
name?: string;
|
|
415
|
+
/** List of tags to apply to the deployment. */
|
|
416
|
+
tags?: string[];
|
|
417
|
+
/** Defines the new minimum size of the pool. */
|
|
418
|
+
minSize?: number;
|
|
419
|
+
/** Defines the new maximum size of the pool. */
|
|
420
|
+
maxSize?: number;
|
|
421
|
+
};
|
|
422
|
+
export type UpdateEndpointRequest = {
|
|
423
|
+
/**
|
|
424
|
+
* Region to target. If none is passed will use default region from the
|
|
425
|
+
* config.
|
|
426
|
+
*/
|
|
427
|
+
region?: Region;
|
|
428
|
+
/** ID of the endpoint to update. */
|
|
429
|
+
endpointId: string;
|
|
430
|
+
/**
|
|
431
|
+
* By default, deployments are protected by IAM authentication. When setting
|
|
432
|
+
* this field to true, the authentication will be disabled.
|
|
433
|
+
*/
|
|
434
|
+
disableAuth?: boolean;
|
|
435
|
+
};
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
export declare const CreateDeploymentRequest: {
|
|
2
|
+
maxSize: {
|
|
3
|
+
greaterThanOrEqual: number;
|
|
4
|
+
lessThanOrEqual: number;
|
|
5
|
+
};
|
|
6
|
+
minSize: {
|
|
7
|
+
greaterThanOrEqual: number;
|
|
8
|
+
lessThanOrEqual: number;
|
|
9
|
+
};
|
|
10
|
+
modelName: {
|
|
11
|
+
maxLength: number;
|
|
12
|
+
minLength: number;
|
|
13
|
+
pattern: RegExp;
|
|
14
|
+
};
|
|
15
|
+
name: {
|
|
16
|
+
maxLength: number;
|
|
17
|
+
minLength: number;
|
|
18
|
+
pattern: RegExp;
|
|
19
|
+
};
|
|
20
|
+
nodeType: {
|
|
21
|
+
maxLength: number;
|
|
22
|
+
minLength: number;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
export declare const ListDeploymentsRequest: {
|
|
26
|
+
name: {
|
|
27
|
+
maxLength: number;
|
|
28
|
+
minLength: number;
|
|
29
|
+
};
|
|
30
|
+
};
|
|
31
|
+
export declare const ListModelsRequest: {
|
|
32
|
+
name: {
|
|
33
|
+
maxLength: number;
|
|
34
|
+
minLength: number;
|
|
35
|
+
};
|
|
36
|
+
};
|
|
37
|
+
export declare const UpdateDeploymentRequest: {
|
|
38
|
+
maxSize: {
|
|
39
|
+
greaterThanOrEqual: number;
|
|
40
|
+
lessThanOrEqual: number;
|
|
41
|
+
};
|
|
42
|
+
minSize: {
|
|
43
|
+
greaterThanOrEqual: number;
|
|
44
|
+
lessThanOrEqual: number;
|
|
45
|
+
};
|
|
46
|
+
name: {
|
|
47
|
+
maxLength: number;
|
|
48
|
+
minLength: number;
|
|
49
|
+
};
|
|
50
|
+
};
|
|
@@ -355,5 +355,30 @@ class API extends api.API {
|
|
|
355
355
|
* @returns A Promise of ListTagsResponse
|
|
356
356
|
*/
|
|
357
357
|
listTags = (request = {}) => resourcePaginator.enrichForPagination("tags", this.pageOfListTags, request);
|
|
358
|
+
pageOfListSecretTypes = (request = {}) => this.client.fetch(
|
|
359
|
+
{
|
|
360
|
+
method: "GET",
|
|
361
|
+
path: `/secret-manager/v1beta1/regions/${marshalling.validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/secret-types`,
|
|
362
|
+
urlParams: marshalling.urlParams(
|
|
363
|
+
["page", request.page],
|
|
364
|
+
[
|
|
365
|
+
"page_size",
|
|
366
|
+
request.pageSize ?? this.client.settings.defaultPageSize
|
|
367
|
+
],
|
|
368
|
+
[
|
|
369
|
+
"project_id",
|
|
370
|
+
request.projectId ?? this.client.settings.defaultProjectId
|
|
371
|
+
]
|
|
372
|
+
)
|
|
373
|
+
},
|
|
374
|
+
marshalling_gen.unmarshalListSecretTypesResponse
|
|
375
|
+
);
|
|
376
|
+
/**
|
|
377
|
+
* List secret types. List all secret types created within a given Project.
|
|
378
|
+
*
|
|
379
|
+
* @param request - The request {@link ListSecretTypesRequest}
|
|
380
|
+
* @returns A Promise of ListSecretTypesResponse
|
|
381
|
+
*/
|
|
382
|
+
listSecretTypes = (request = {}) => resourcePaginator.enrichForPagination("types", this.pageOfListSecretTypes, request);
|
|
358
383
|
}
|
|
359
384
|
exports.API = API;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { API as ParentAPI } from '../../../bridge';
|
|
2
2
|
import type { Region } from '../../../bridge';
|
|
3
|
-
import type { AccessSecretVersionByPathRequest, AccessSecretVersionRequest, AccessSecretVersionResponse, AddSecretOwnerRequest, BrowseSecretsRequest, BrowseSecretsResponse, CreateSecretRequest, CreateSecretVersionRequest, DeleteSecretRequest, DeleteSecretVersionRequest, DisableSecretVersionRequest, EnableSecretVersionRequest, GetSecretRequest, GetSecretVersionRequest, ListSecretVersionsRequest, ListSecretVersionsResponse, ListSecretsRequest, ListSecretsResponse, ListTagsRequest, ListTagsResponse, ProtectSecretRequest, Secret, SecretVersion, UnprotectSecretRequest, UpdateSecretRequest, UpdateSecretVersionRequest } from './types.gen';
|
|
3
|
+
import type { AccessSecretVersionByPathRequest, AccessSecretVersionRequest, AccessSecretVersionResponse, AddSecretOwnerRequest, BrowseSecretsRequest, BrowseSecretsResponse, CreateSecretRequest, CreateSecretVersionRequest, DeleteSecretRequest, DeleteSecretVersionRequest, DisableSecretVersionRequest, EnableSecretVersionRequest, GetSecretRequest, GetSecretVersionRequest, ListSecretTypesRequest, ListSecretTypesResponse, ListSecretVersionsRequest, ListSecretVersionsResponse, ListSecretsRequest, ListSecretsResponse, ListTagsRequest, ListTagsResponse, ProtectSecretRequest, Secret, SecretVersion, UnprotectSecretRequest, UpdateSecretRequest, UpdateSecretVersionRequest } from './types.gen';
|
|
4
4
|
/**
|
|
5
5
|
* Secret Manager API.
|
|
6
6
|
*
|
|
@@ -179,4 +179,15 @@ export declare class API extends ParentAPI {
|
|
|
179
179
|
all: () => Promise<string[]>;
|
|
180
180
|
[Symbol.asyncIterator]: () => AsyncGenerator<string[], void, void>;
|
|
181
181
|
};
|
|
182
|
+
protected pageOfListSecretTypes: (request?: Readonly<ListSecretTypesRequest>) => Promise<ListSecretTypesResponse>;
|
|
183
|
+
/**
|
|
184
|
+
* List secret types. List all secret types created within a given Project.
|
|
185
|
+
*
|
|
186
|
+
* @param request - The request {@link ListSecretTypesRequest}
|
|
187
|
+
* @returns A Promise of ListSecretTypesResponse
|
|
188
|
+
*/
|
|
189
|
+
listSecretTypes: (request?: Readonly<ListSecretTypesRequest>) => Promise<ListSecretTypesResponse> & {
|
|
190
|
+
all: () => Promise<import("./types.gen").SecretType[]>;
|
|
191
|
+
[Symbol.asyncIterator]: () => AsyncGenerator<import("./types.gen").SecretType[], void, void>;
|
|
192
|
+
};
|
|
182
193
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { API as API$1 } from "../../../scw/api.js";
|
|
2
2
|
import { validatePathParam, urlParams } from "../../../helpers/marshalling.js";
|
|
3
3
|
import { enrichForPagination } from "../../../scw/fetch/resource-paginator.js";
|
|
4
|
-
import { marshalCreateSecretRequest, unmarshalSecret, marshalUpdateSecretRequest, unmarshalListSecretsResponse, unmarshalBrowseSecretsResponse, marshalAddSecretOwnerRequest, marshalCreateSecretVersionRequest, unmarshalSecretVersion, marshalUpdateSecretVersionRequest, unmarshalListSecretVersionsResponse, unmarshalAccessSecretVersionResponse, unmarshalListTagsResponse } from "./marshalling.gen.js";
|
|
4
|
+
import { marshalCreateSecretRequest, unmarshalSecret, marshalUpdateSecretRequest, unmarshalListSecretsResponse, unmarshalBrowseSecretsResponse, marshalAddSecretOwnerRequest, marshalCreateSecretVersionRequest, unmarshalSecretVersion, marshalUpdateSecretVersionRequest, unmarshalListSecretVersionsResponse, unmarshalAccessSecretVersionResponse, unmarshalListTagsResponse, unmarshalListSecretTypesResponse } from "./marshalling.gen.js";
|
|
5
5
|
const jsonContentHeaders = {
|
|
6
6
|
"Content-Type": "application/json; charset=utf-8"
|
|
7
7
|
};
|
|
@@ -353,6 +353,31 @@ class API extends API$1 {
|
|
|
353
353
|
* @returns A Promise of ListTagsResponse
|
|
354
354
|
*/
|
|
355
355
|
listTags = (request = {}) => enrichForPagination("tags", this.pageOfListTags, request);
|
|
356
|
+
pageOfListSecretTypes = (request = {}) => this.client.fetch(
|
|
357
|
+
{
|
|
358
|
+
method: "GET",
|
|
359
|
+
path: `/secret-manager/v1beta1/regions/${validatePathParam("region", request.region ?? this.client.settings.defaultRegion)}/secret-types`,
|
|
360
|
+
urlParams: urlParams(
|
|
361
|
+
["page", request.page],
|
|
362
|
+
[
|
|
363
|
+
"page_size",
|
|
364
|
+
request.pageSize ?? this.client.settings.defaultPageSize
|
|
365
|
+
],
|
|
366
|
+
[
|
|
367
|
+
"project_id",
|
|
368
|
+
request.projectId ?? this.client.settings.defaultProjectId
|
|
369
|
+
]
|
|
370
|
+
)
|
|
371
|
+
},
|
|
372
|
+
unmarshalListSecretTypesResponse
|
|
373
|
+
);
|
|
374
|
+
/**
|
|
375
|
+
* List secret types. List all secret types created within a given Project.
|
|
376
|
+
*
|
|
377
|
+
* @param request - The request {@link ListSecretTypesRequest}
|
|
378
|
+
* @returns A Promise of ListSecretTypesResponse
|
|
379
|
+
*/
|
|
380
|
+
listSecretTypes = (request = {}) => enrichForPagination("types", this.pageOfListSecretTypes, request);
|
|
356
381
|
}
|
|
357
382
|
export {
|
|
358
383
|
API
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export { API } from './api.gen';
|
|
2
|
-
export type { AccessSecretVersionByPathRequest, AccessSecretVersionRequest, AccessSecretVersionResponse, AddSecretOwnerRequest, BasicCredentials, BrowseSecretsRequest, BrowseSecretsRequestOrderBy, BrowseSecretsResponse, BrowseSecretsResponseItem, BrowseSecretsResponseItemFolderDetails, BrowseSecretsResponseItemSecretDetails, CreateSecretRequest, CreateSecretVersionRequest, DatabaseCredentials, DeleteSecretRequest, DeleteSecretVersionRequest, DisableSecretVersionRequest, EnableSecretVersionRequest, EphemeralPolicy, EphemeralPolicyAction, EphemeralProperties, GetSecretRequest, GetSecretVersionRequest, ListSecretVersionsRequest, ListSecretVersionsResponse, ListSecretsRequest, ListSecretsRequestOrderBy, ListSecretsResponse, ListTagsRequest, ListTagsResponse, Product, ProtectSecretRequest, SSHKey, Secret, SecretStatus, SecretType, SecretVersion, SecretVersionStatus, UnprotectSecretRequest, UpdateSecretRequest, UpdateSecretVersionRequest, } from './types.gen';
|
|
2
|
+
export type { AccessSecretVersionByPathRequest, AccessSecretVersionRequest, AccessSecretVersionResponse, AddSecretOwnerRequest, BasicCredentials, BrowseSecretsRequest, BrowseSecretsRequestOrderBy, BrowseSecretsResponse, BrowseSecretsResponseItem, BrowseSecretsResponseItemFolderDetails, BrowseSecretsResponseItemSecretDetails, CreateSecretRequest, CreateSecretVersionRequest, DatabaseCredentials, DeleteSecretRequest, DeleteSecretVersionRequest, DisableSecretVersionRequest, EnableSecretVersionRequest, EphemeralPolicy, EphemeralPolicyAction, EphemeralProperties, GetSecretRequest, GetSecretVersionRequest, ListSecretTypesRequest, ListSecretTypesResponse, ListSecretVersionsRequest, ListSecretVersionsResponse, ListSecretsRequest, ListSecretsRequestOrderBy, ListSecretsResponse, ListTagsRequest, ListTagsResponse, Product, ProtectSecretRequest, SSHKey, Secret, SecretStatus, SecretType, SecretVersion, SecretVersionStatus, UnprotectSecretRequest, UpdateSecretRequest, UpdateSecretVersionRequest, } from './types.gen';
|
|
3
3
|
export * as ValidationRules from './validation-rules.gen';
|
|
@@ -132,6 +132,17 @@ const unmarshalBrowseSecretsResponse = (data) => {
|
|
|
132
132
|
totalCount: data.total_count
|
|
133
133
|
};
|
|
134
134
|
};
|
|
135
|
+
const unmarshalListSecretTypesResponse = (data) => {
|
|
136
|
+
if (!json.isJSONObject(data)) {
|
|
137
|
+
throw new TypeError(
|
|
138
|
+
`Unmarshalling the type 'ListSecretTypesResponse' failed as data isn't a dictionary.`
|
|
139
|
+
);
|
|
140
|
+
}
|
|
141
|
+
return {
|
|
142
|
+
totalCount: data.total_count,
|
|
143
|
+
types: data.types
|
|
144
|
+
};
|
|
145
|
+
};
|
|
135
146
|
const unmarshalListSecretVersionsResponse = (data) => {
|
|
136
147
|
if (!json.isJSONObject(data)) {
|
|
137
148
|
throw new TypeError(
|
|
@@ -212,6 +223,7 @@ exports.marshalUpdateSecretRequest = marshalUpdateSecretRequest;
|
|
|
212
223
|
exports.marshalUpdateSecretVersionRequest = marshalUpdateSecretVersionRequest;
|
|
213
224
|
exports.unmarshalAccessSecretVersionResponse = unmarshalAccessSecretVersionResponse;
|
|
214
225
|
exports.unmarshalBrowseSecretsResponse = unmarshalBrowseSecretsResponse;
|
|
226
|
+
exports.unmarshalListSecretTypesResponse = unmarshalListSecretTypesResponse;
|
|
215
227
|
exports.unmarshalListSecretVersionsResponse = unmarshalListSecretVersionsResponse;
|
|
216
228
|
exports.unmarshalListSecretsResponse = unmarshalListSecretsResponse;
|
|
217
229
|
exports.unmarshalListTagsResponse = unmarshalListTagsResponse;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import type { DefaultValues } from '../../../bridge';
|
|
2
|
-
import type { AccessSecretVersionResponse, AddSecretOwnerRequest, BrowseSecretsResponse, CreateSecretRequest, CreateSecretVersionRequest, ListSecretVersionsResponse, ListSecretsResponse, ListTagsResponse, Secret, SecretVersion, UpdateSecretRequest, UpdateSecretVersionRequest } from './types.gen';
|
|
2
|
+
import type { AccessSecretVersionResponse, AddSecretOwnerRequest, BrowseSecretsResponse, CreateSecretRequest, CreateSecretVersionRequest, ListSecretTypesResponse, ListSecretVersionsResponse, ListSecretsResponse, ListTagsResponse, Secret, SecretVersion, UpdateSecretRequest, UpdateSecretVersionRequest } from './types.gen';
|
|
3
3
|
export declare const unmarshalSecretVersion: (data: unknown) => SecretVersion;
|
|
4
4
|
export declare const unmarshalSecret: (data: unknown) => Secret;
|
|
5
5
|
export declare const unmarshalAccessSecretVersionResponse: (data: unknown) => AccessSecretVersionResponse;
|
|
6
6
|
export declare const unmarshalBrowseSecretsResponse: (data: unknown) => BrowseSecretsResponse;
|
|
7
|
+
export declare const unmarshalListSecretTypesResponse: (data: unknown) => ListSecretTypesResponse;
|
|
7
8
|
export declare const unmarshalListSecretVersionsResponse: (data: unknown) => ListSecretVersionsResponse;
|
|
8
9
|
export declare const unmarshalListSecretsResponse: (data: unknown) => ListSecretsResponse;
|
|
9
10
|
export declare const unmarshalListTagsResponse: (data: unknown) => ListTagsResponse;
|
|
@@ -130,6 +130,17 @@ const unmarshalBrowseSecretsResponse = (data) => {
|
|
|
130
130
|
totalCount: data.total_count
|
|
131
131
|
};
|
|
132
132
|
};
|
|
133
|
+
const unmarshalListSecretTypesResponse = (data) => {
|
|
134
|
+
if (!isJSONObject(data)) {
|
|
135
|
+
throw new TypeError(
|
|
136
|
+
`Unmarshalling the type 'ListSecretTypesResponse' failed as data isn't a dictionary.`
|
|
137
|
+
);
|
|
138
|
+
}
|
|
139
|
+
return {
|
|
140
|
+
totalCount: data.total_count,
|
|
141
|
+
types: data.types
|
|
142
|
+
};
|
|
143
|
+
};
|
|
133
144
|
const unmarshalListSecretVersionsResponse = (data) => {
|
|
134
145
|
if (!isJSONObject(data)) {
|
|
135
146
|
throw new TypeError(
|
|
@@ -211,6 +222,7 @@ export {
|
|
|
211
222
|
marshalUpdateSecretVersionRequest,
|
|
212
223
|
unmarshalAccessSecretVersionResponse,
|
|
213
224
|
unmarshalBrowseSecretsResponse,
|
|
225
|
+
unmarshalListSecretTypesResponse,
|
|
214
226
|
unmarshalListSecretVersionsResponse,
|
|
215
227
|
unmarshalListSecretsResponse,
|
|
216
228
|
unmarshalListTagsResponse,
|
|
@@ -375,6 +375,23 @@ export type GetSecretVersionRequest = {
|
|
|
375
375
|
*/
|
|
376
376
|
revision: string;
|
|
377
377
|
};
|
|
378
|
+
export type ListSecretTypesRequest = {
|
|
379
|
+
/**
|
|
380
|
+
* Region to target. If none is passed will use default region from the
|
|
381
|
+
* config.
|
|
382
|
+
*/
|
|
383
|
+
region?: Region;
|
|
384
|
+
/** ID of the Project to target. */
|
|
385
|
+
projectId?: string;
|
|
386
|
+
page?: number;
|
|
387
|
+
pageSize?: number;
|
|
388
|
+
};
|
|
389
|
+
export interface ListSecretTypesResponse {
|
|
390
|
+
/** List of secret types. */
|
|
391
|
+
types: SecretType[];
|
|
392
|
+
/** Count of all secret types matching the requested criteria. */
|
|
393
|
+
totalCount: number;
|
|
394
|
+
}
|
|
378
395
|
export type ListSecretVersionsRequest = {
|
|
379
396
|
/**
|
|
380
397
|
* Region to target. If none is passed will use default region from the
|
package/dist/scw/constants.cjs
CHANGED
package/dist/scw/constants.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const version = "v2.
|
|
2
|
-
export declare const userAgent = "scaleway-sdk-js/v2.
|
|
1
|
+
export declare const version = "v2.35.0";
|
|
2
|
+
export declare const userAgent = "scaleway-sdk-js/v2.35.0";
|
package/dist/scw/constants.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@scaleway/sdk",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.36.0",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"description": "Scaleway SDK.",
|
|
6
6
|
"keywords": [
|
|
@@ -39,5 +39,5 @@
|
|
|
39
39
|
"bundledDependencies": [
|
|
40
40
|
"@scaleway/random-name"
|
|
41
41
|
],
|
|
42
|
-
"gitHead": "
|
|
42
|
+
"gitHead": "a911ac4c87debbc8605ce5f33dca19b1ad39c589"
|
|
43
43
|
}
|