Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 0 additions & 38 deletions packages/clients/src/api/secret/v1beta1/api.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@ import type {
ListTagsRequest,
ListTagsResponse,
ProtectSecretRequest,
RestoreSecretRequest,
RestoreSecretVersionRequest,
Secret,
SecretVersion,
UnprotectSecretRequest,
Expand Down Expand Up @@ -499,40 +497,4 @@ export class API extends ParentAPI {
*/
listSecretTypes = (request: Readonly<ListSecretTypesRequest> = {}) =>
enrichForPagination('types', this.pageOfListSecretTypes, request)

/**
* Restore a version.. Restore a secret's version specified by the `region`,
* `secret_id` and `revision` parameters.
*
* @param request - The request {@link RestoreSecretVersionRequest}
* @returns A Promise of SecretVersion
*/
restoreSecretVersion = (request: Readonly<RestoreSecretVersionRequest>) =>
this.client.fetch<SecretVersion>(
{
body: '{}',
headers: jsonContentHeaders,
method: 'POST',
path: `/secret-manager/v1beta1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/secrets/${validatePathParam('secretId', request.secretId)}/versions/${validatePathParam('revision', request.revision)}/restore`,
},
unmarshalSecretVersion,
)

/**
* Restore a secret.. Restore a secret and all its versions scheduled for
* deletion specified by the `region` and `secret_id` parameters.
*
* @param request - The request {@link RestoreSecretRequest}
* @returns A Promise of Secret
*/
restoreSecret = (request: Readonly<RestoreSecretRequest>) =>
this.client.fetch<Secret>(
{
body: '{}',
headers: jsonContentHeaders,
method: 'POST',
path: `/secret-manager/v1beta1/regions/${validatePathParam('region', request.region ?? this.client.settings.defaultRegion)}/secrets/${validatePathParam('secretId', request.secretId)}/restore`,
},
unmarshalSecret,
)
}
2 changes: 0 additions & 2 deletions packages/clients/src/api/secret/v1beta1/index.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@ export type {
ListTagsResponse,
Product,
ProtectSecretRequest,
RestoreSecretRequest,
RestoreSecretVersionRequest,
SSHKey,
Secret,
SecretStatus,
Expand Down
19 changes: 0 additions & 19 deletions packages/clients/src/api/secret/v1beta1/types.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -550,25 +550,6 @@ export type ProtectSecretRequest = {
secretId: string
}

export type RestoreSecretRequest = {
/**
* Region to target. If none is passed will use default region from the
* config.
*/
region?: ScwRegion
secretId: string
}

export type RestoreSecretVersionRequest = {
/**
* Region to target. If none is passed will use default region from the
* config.
*/
region?: ScwRegion
secretId: string
revision: string
}

export interface SSHKey {
/** The private SSH key. */
sshPrivateKey: string
Expand Down
Loading