import { ServiceType } from "@protobuf-ts/runtime-rpc"; import type { BinaryWriteOptions } from "@protobuf-ts/runtime"; import type { IBinaryWriter } from "@protobuf-ts/runtime"; import type { BinaryReadOptions } from "@protobuf-ts/runtime"; import type { IBinaryReader } from "@protobuf-ts/runtime"; import type { PartialMessage } from "@protobuf-ts/runtime"; import { MessageType } from "@protobuf-ts/runtime"; import { FieldMask } from "../../../protobuf/field_mask"; import { Key } from "./resources"; /** * Request message for `CreateKey` method. * * @generated from protobuf message google.api.apikeys.v2.CreateKeyRequest */ export interface CreateKeyRequest { /** * Required. The project in which the API key is created. * * @generated from protobuf field: string parent = 1; */ parent: string; /** * Required. The API key fields to set at creation time. * You can configure only the `display_name`, `restrictions`, and * `annotations` fields. * * @generated from protobuf field: google.api.apikeys.v2.Key key = 2; */ key?: Key; /** * User specified key id (optional). If specified, it will become the final * component of the key resource name. * * The id must be unique within the project, must conform with RFC-1034, * is restricted to lower-cased letters, and has a maximum length of 63 * characters. In another word, the id must match the regular * expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`. * * The id must NOT be a UUID-like string. * * @generated from protobuf field: string key_id = 3; */ keyId: string; } /** * Request message for `ListKeys` method. * * @generated from protobuf message google.api.apikeys.v2.ListKeysRequest */ export interface ListKeysRequest { /** * Required. Lists all API keys associated with this project. * * @generated from protobuf field: string parent = 1; */ parent: string; /** * Optional. Specifies the maximum number of results to be returned at a time. * * @generated from protobuf field: int32 page_size = 2; */ pageSize: number; /** * Optional. Requests a specific page of results. * * @generated from protobuf field: string page_token = 3; */ pageToken: string; /** * Optional. Indicate that keys deleted in the past 30 days should also be * returned. * * @generated from protobuf field: bool show_deleted = 6; */ showDeleted: boolean; } /** * Response message for `ListKeys` method. * * @generated from protobuf message google.api.apikeys.v2.ListKeysResponse */ export interface ListKeysResponse { /** * A list of API keys. * * @generated from protobuf field: repeated google.api.apikeys.v2.Key keys = 1; */ keys: Key[]; /** * The pagination token for the next page of results. * * @generated from protobuf field: string next_page_token = 2; */ nextPageToken: string; } /** * Request message for `GetKey` method. * * @generated from protobuf message google.api.apikeys.v2.GetKeyRequest */ export interface GetKeyRequest { /** * Required. The resource name of the API key to get. * * @generated from protobuf field: string name = 1; */ name: string; } /** * Request message for `GetKeyString` method. * * @generated from protobuf message google.api.apikeys.v2.GetKeyStringRequest */ export interface GetKeyStringRequest { /** * Required. The resource name of the API key to be retrieved. * * @generated from protobuf field: string name = 1; */ name: string; } /** * Response message for `GetKeyString` method. * * @generated from protobuf message google.api.apikeys.v2.GetKeyStringResponse */ export interface GetKeyStringResponse { /** * An encrypted and signed value of the key. * * @generated from protobuf field: string key_string = 1; */ keyString: string; } /** * Request message for `UpdateKey` method. * * @generated from protobuf message google.api.apikeys.v2.UpdateKeyRequest */ export interface UpdateKeyRequest { /** * Required. Set the `name` field to the resource name of the API key to be * updated. You can update only the `display_name`, `restrictions`, and * `annotations` fields. * * @generated from protobuf field: google.api.apikeys.v2.Key key = 1; */ key?: Key; /** * The field mask specifies which fields to be updated as part of this * request. All other fields are ignored. * Mutable fields are: `display_name`, `restrictions`, and `annotations`. * If an update mask is not provided, the service treats it as an implied mask * equivalent to all allowed fields that are set on the wire. If the field * mask has a special value "*", the service treats it equivalent to replace * all allowed mutable fields. * * @generated from protobuf field: google.protobuf.FieldMask update_mask = 2; */ updateMask?: FieldMask; } /** * Request message for `DeleteKey` method. * * @generated from protobuf message google.api.apikeys.v2.DeleteKeyRequest */ export interface DeleteKeyRequest { /** * Required. The resource name of the API key to be deleted. * * @generated from protobuf field: string name = 1; */ name: string; /** * Optional. The etag known to the client for the expected state of the key. * This is to be used for optimistic concurrency. * * @generated from protobuf field: string etag = 2; */ etag: string; } /** * Request message for `UndeleteKey` method. * * @generated from protobuf message google.api.apikeys.v2.UndeleteKeyRequest */ export interface UndeleteKeyRequest { /** * Required. The resource name of the API key to be undeleted. * * @generated from protobuf field: string name = 1; */ name: string; } /** * Request message for `LookupKey` method. * * @generated from protobuf message google.api.apikeys.v2.LookupKeyRequest */ export interface LookupKeyRequest { /** * Required. Finds the project that owns the key string value. * * @generated from protobuf field: string key_string = 1; */ keyString: string; } /** * Response message for `LookupKey` method. * * @generated from protobuf message google.api.apikeys.v2.LookupKeyResponse */ export interface LookupKeyResponse { /** * The project that owns the key with the value specified in the request. * * @generated from protobuf field: string parent = 1; */ parent: string; /** * The resource name of the API key. If the API key has been purged, * resource name is empty. * * @generated from protobuf field: string name = 2; */ name: string; } declare class CreateKeyRequest$Type extends MessageType { constructor(); create(value?: PartialMessage): CreateKeyRequest; internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CreateKeyRequest): CreateKeyRequest; internalBinaryWrite(message: CreateKeyRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter; } /** * @generated MessageType for protobuf message google.api.apikeys.v2.CreateKeyRequest */ export declare const CreateKeyRequest: CreateKeyRequest$Type; declare class ListKeysRequest$Type extends MessageType { constructor(); create(value?: PartialMessage): ListKeysRequest; internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListKeysRequest): ListKeysRequest; internalBinaryWrite(message: ListKeysRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter; } /** * @generated MessageType for protobuf message google.api.apikeys.v2.ListKeysRequest */ export declare const ListKeysRequest: ListKeysRequest$Type; declare class ListKeysResponse$Type extends MessageType { constructor(); create(value?: PartialMessage): ListKeysResponse; internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListKeysResponse): ListKeysResponse; internalBinaryWrite(message: ListKeysResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter; } /** * @generated MessageType for protobuf message google.api.apikeys.v2.ListKeysResponse */ export declare const ListKeysResponse: ListKeysResponse$Type; declare class GetKeyRequest$Type extends MessageType { constructor(); create(value?: PartialMessage): GetKeyRequest; internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetKeyRequest): GetKeyRequest; internalBinaryWrite(message: GetKeyRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter; } /** * @generated MessageType for protobuf message google.api.apikeys.v2.GetKeyRequest */ export declare const GetKeyRequest: GetKeyRequest$Type; declare class GetKeyStringRequest$Type extends MessageType { constructor(); create(value?: PartialMessage): GetKeyStringRequest; internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetKeyStringRequest): GetKeyStringRequest; internalBinaryWrite(message: GetKeyStringRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter; } /** * @generated MessageType for protobuf message google.api.apikeys.v2.GetKeyStringRequest */ export declare const GetKeyStringRequest: GetKeyStringRequest$Type; declare class GetKeyStringResponse$Type extends MessageType { constructor(); create(value?: PartialMessage): GetKeyStringResponse; internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetKeyStringResponse): GetKeyStringResponse; internalBinaryWrite(message: GetKeyStringResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter; } /** * @generated MessageType for protobuf message google.api.apikeys.v2.GetKeyStringResponse */ export declare const GetKeyStringResponse: GetKeyStringResponse$Type; declare class UpdateKeyRequest$Type extends MessageType { constructor(); create(value?: PartialMessage): UpdateKeyRequest; internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UpdateKeyRequest): UpdateKeyRequest; internalBinaryWrite(message: UpdateKeyRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter; } /** * @generated MessageType for protobuf message google.api.apikeys.v2.UpdateKeyRequest */ export declare const UpdateKeyRequest: UpdateKeyRequest$Type; declare class DeleteKeyRequest$Type extends MessageType { constructor(); create(value?: PartialMessage): DeleteKeyRequest; internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteKeyRequest): DeleteKeyRequest; internalBinaryWrite(message: DeleteKeyRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter; } /** * @generated MessageType for protobuf message google.api.apikeys.v2.DeleteKeyRequest */ export declare const DeleteKeyRequest: DeleteKeyRequest$Type; declare class UndeleteKeyRequest$Type extends MessageType { constructor(); create(value?: PartialMessage): UndeleteKeyRequest; internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UndeleteKeyRequest): UndeleteKeyRequest; internalBinaryWrite(message: UndeleteKeyRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter; } /** * @generated MessageType for protobuf message google.api.apikeys.v2.UndeleteKeyRequest */ export declare const UndeleteKeyRequest: UndeleteKeyRequest$Type; declare class LookupKeyRequest$Type extends MessageType { constructor(); create(value?: PartialMessage): LookupKeyRequest; internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: LookupKeyRequest): LookupKeyRequest; internalBinaryWrite(message: LookupKeyRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter; } /** * @generated MessageType for protobuf message google.api.apikeys.v2.LookupKeyRequest */ export declare const LookupKeyRequest: LookupKeyRequest$Type; declare class LookupKeyResponse$Type extends MessageType { constructor(); create(value?: PartialMessage): LookupKeyResponse; internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: LookupKeyResponse): LookupKeyResponse; internalBinaryWrite(message: LookupKeyResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter; } /** * @generated MessageType for protobuf message google.api.apikeys.v2.LookupKeyResponse */ export declare const LookupKeyResponse: LookupKeyResponse$Type; /** * @generated ServiceType for protobuf service google.api.apikeys.v2.ApiKeys */ export declare const ApiKeys: ServiceType; export {};