/// import { ChannelCredentials, ChannelOptions, UntypedServiceImplementation, handleUnaryCall, Client, ClientUnaryCall, Metadata, CallOptions, ServiceError } from '@grpc/grpc-js'; import _m0 from 'protobufjs/minimal'; import { CronTab, BackupRetentionPolicy } from '../../../../../yandex/cloud/mdb/postgresql/v1/backup_retention_policy'; export declare const protobufPackage = "yandex.cloud.mdb.postgresql.v1"; export interface ListBackupRetentionPoliciesRequest { /** * ID of the PostgreSQL cluster. * To get the PostgreSQL cluster ID use a [ClusterService.List] request. */ clusterId: string; /** * The maximum number of results per page to return. If the number of available * results is larger than [page_size], the service returns a [ListBackupRetentionPoliciesResponse.next_page_token] * that can be used to get the next page of results in subsequent list requests. */ pageSize: number; /** * Page token. To get the next page of results, set [page_token] * to the [ListBackupRetentionPoliciesResponse.next_page_token] returned by the previous list request. */ pageToken: string; } export interface ListBackupRetentionPoliciesResponse { /** List of [BackupRetentionPolicy] associated with the cluster. */ policies: BackupRetentionPolicy[]; /** * This token allows you to get the next page of results for list requests. If the number of results * is larger than [ListBackupRetentionPoliciesRequest.page_size], use the [next_page_token] as the value * for the [ListBackupRetentionPoliciesRequest.page_token] query parameter in the next list request. * Each subsequent list request will have its own [next_page_token] to continue paging through the results. */ nextPageToken: string; } export interface CreateBackupRetentionPolicyRequest { /** * ID of the PostgreSQL cluster. * To get the PostgreSQL cluster ID use a [ClusterService.List] request. */ clusterId: string; /** CronTab schedule. */ cron?: CronTab; /** Retention duration. */ retainForDays: number; /** Policy description. */ description: string; /** Required. Policy name. */ policyName: string; } export interface CreateBackupRetentionPolicyResponse { /** Newly created [BackupRetentionPolicy]. */ policy?: BackupRetentionPolicy; } export interface DeleteBackupRetentionPolicyRequest { /** Unique identifier for the [BackupRetentionPolicy]. */ policyId: string; /** * ID of the PostgreSQL cluster. * To get the PostgreSQL cluster ID use a [ClusterService.List] request. */ clusterId: string; } export interface DeleteBackupRetentionPolicyResponse { } export declare const ListBackupRetentionPoliciesRequest: { encode(message: ListBackupRetentionPoliciesRequest, writer?: _m0.Writer): _m0.Writer; decode(input: _m0.Reader | Uint8Array, length?: number): ListBackupRetentionPoliciesRequest; fromJSON(object: any): ListBackupRetentionPoliciesRequest; toJSON(message: ListBackupRetentionPoliciesRequest): unknown; fromPartial, never>>(object: I): ListBackupRetentionPoliciesRequest; }; export declare const ListBackupRetentionPoliciesResponse: { encode(message: ListBackupRetentionPoliciesResponse, writer?: _m0.Writer): _m0.Writer; decode(input: _m0.Reader | Uint8Array, length?: number): ListBackupRetentionPoliciesResponse; fromJSON(object: any): ListBackupRetentionPoliciesResponse; toJSON(message: ListBackupRetentionPoliciesResponse): unknown; fromPartial, never>) | undefined; retainForDays?: number | undefined; description?: string | undefined; } & Record, never>)[] & Record, never>) | undefined; nextPageToken?: string | undefined; } & Record, never>>(object: I): ListBackupRetentionPoliciesResponse; }; export declare const CreateBackupRetentionPolicyRequest: { encode(message: CreateBackupRetentionPolicyRequest, writer?: _m0.Writer): _m0.Writer; decode(input: _m0.Reader | Uint8Array, length?: number): CreateBackupRetentionPolicyRequest; fromJSON(object: any): CreateBackupRetentionPolicyRequest; toJSON(message: CreateBackupRetentionPolicyRequest): unknown; fromPartial, never>) | undefined; retainForDays?: number | undefined; description?: string | undefined; policyName?: string | undefined; } & Record, never>>(object: I): CreateBackupRetentionPolicyRequest; }; export declare const CreateBackupRetentionPolicyResponse: { encode(message: CreateBackupRetentionPolicyResponse, writer?: _m0.Writer): _m0.Writer; decode(input: _m0.Reader | Uint8Array, length?: number): CreateBackupRetentionPolicyResponse; fromJSON(object: any): CreateBackupRetentionPolicyResponse; toJSON(message: CreateBackupRetentionPolicyResponse): unknown; fromPartial, never>) | undefined; retainForDays?: number | undefined; description?: string | undefined; } & Record, never>) | undefined; } & Record, never>>(object: I): CreateBackupRetentionPolicyResponse; }; export declare const DeleteBackupRetentionPolicyRequest: { encode(message: DeleteBackupRetentionPolicyRequest, writer?: _m0.Writer): _m0.Writer; decode(input: _m0.Reader | Uint8Array, length?: number): DeleteBackupRetentionPolicyRequest; fromJSON(object: any): DeleteBackupRetentionPolicyRequest; toJSON(message: DeleteBackupRetentionPolicyRequest): unknown; fromPartial, never>>(object: I): DeleteBackupRetentionPolicyRequest; }; export declare const DeleteBackupRetentionPolicyResponse: { encode(_: DeleteBackupRetentionPolicyResponse, writer?: _m0.Writer): _m0.Writer; decode(input: _m0.Reader | Uint8Array, length?: number): DeleteBackupRetentionPolicyResponse; fromJSON(_: any): DeleteBackupRetentionPolicyResponse; toJSON(_: DeleteBackupRetentionPolicyResponse): unknown; fromPartial, never>>(_: I): DeleteBackupRetentionPolicyResponse; }; /** A set of methods for managing PostgreSQL Cluster backup retention policies. */ export declare const BackupRetentionPolicyServiceService: { /** List all retention policies. */ readonly list: { readonly path: "/yandex.cloud.mdb.postgresql.v1.BackupRetentionPolicyService/List"; readonly requestStream: false; readonly responseStream: false; readonly requestSerialize: (value: ListBackupRetentionPoliciesRequest) => Buffer; readonly requestDeserialize: (value: Buffer) => ListBackupRetentionPoliciesRequest; readonly responseSerialize: (value: ListBackupRetentionPoliciesResponse) => Buffer; readonly responseDeserialize: (value: Buffer) => ListBackupRetentionPoliciesResponse; }; /** Add a new retention policy. */ readonly create: { readonly path: "/yandex.cloud.mdb.postgresql.v1.BackupRetentionPolicyService/Create"; readonly requestStream: false; readonly responseStream: false; readonly requestSerialize: (value: CreateBackupRetentionPolicyRequest) => Buffer; readonly requestDeserialize: (value: Buffer) => CreateBackupRetentionPolicyRequest; readonly responseSerialize: (value: CreateBackupRetentionPolicyResponse) => Buffer; readonly responseDeserialize: (value: Buffer) => CreateBackupRetentionPolicyResponse; }; /** Delete retention policy. */ readonly delete: { readonly path: "/yandex.cloud.mdb.postgresql.v1.BackupRetentionPolicyService/Delete"; readonly requestStream: false; readonly responseStream: false; readonly requestSerialize: (value: DeleteBackupRetentionPolicyRequest) => Buffer; readonly requestDeserialize: (value: Buffer) => DeleteBackupRetentionPolicyRequest; readonly responseSerialize: (value: DeleteBackupRetentionPolicyResponse) => Buffer; readonly responseDeserialize: (value: Buffer) => DeleteBackupRetentionPolicyResponse; }; }; export interface BackupRetentionPolicyServiceServer extends UntypedServiceImplementation { /** List all retention policies. */ list: handleUnaryCall; /** Add a new retention policy. */ create: handleUnaryCall; /** Delete retention policy. */ delete: handleUnaryCall; } export interface BackupRetentionPolicyServiceClient extends Client { /** List all retention policies. */ list(request: ListBackupRetentionPoliciesRequest, callback: (error: ServiceError | null, response: ListBackupRetentionPoliciesResponse) => void): ClientUnaryCall; list(request: ListBackupRetentionPoliciesRequest, metadata: Metadata, callback: (error: ServiceError | null, response: ListBackupRetentionPoliciesResponse) => void): ClientUnaryCall; list(request: ListBackupRetentionPoliciesRequest, metadata: Metadata, options: Partial, callback: (error: ServiceError | null, response: ListBackupRetentionPoliciesResponse) => void): ClientUnaryCall; /** Add a new retention policy. */ create(request: CreateBackupRetentionPolicyRequest, callback: (error: ServiceError | null, response: CreateBackupRetentionPolicyResponse) => void): ClientUnaryCall; create(request: CreateBackupRetentionPolicyRequest, metadata: Metadata, callback: (error: ServiceError | null, response: CreateBackupRetentionPolicyResponse) => void): ClientUnaryCall; create(request: CreateBackupRetentionPolicyRequest, metadata: Metadata, options: Partial, callback: (error: ServiceError | null, response: CreateBackupRetentionPolicyResponse) => void): ClientUnaryCall; /** Delete retention policy. */ delete(request: DeleteBackupRetentionPolicyRequest, callback: (error: ServiceError | null, response: DeleteBackupRetentionPolicyResponse) => void): ClientUnaryCall; delete(request: DeleteBackupRetentionPolicyRequest, metadata: Metadata, callback: (error: ServiceError | null, response: DeleteBackupRetentionPolicyResponse) => void): ClientUnaryCall; delete(request: DeleteBackupRetentionPolicyRequest, metadata: Metadata, options: Partial, callback: (error: ServiceError | null, response: DeleteBackupRetentionPolicyResponse) => void): ClientUnaryCall; } export declare const BackupRetentionPolicyServiceClient: { new (address: string, credentials: ChannelCredentials, options?: Partial): BackupRetentionPolicyServiceClient; service: typeof BackupRetentionPolicyServiceService; }; type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined; export type DeepPartial = T extends Builtin ? T : T extends Array ? Array> : T extends ReadonlyArray ? ReadonlyArray> : T extends {} ? { [K in keyof T]?: DeepPartial; } : Partial; type KeysOfUnion = T extends T ? keyof T : never; export type Exact = P extends Builtin ? P : P & { [K in keyof P]: Exact; } & Record>, never>; export {};
= P extends Builtin ? P : P & { [K in keyof P]: Exact
; } & Record>, never>; export {};