google-ads-api-client
Version:
A friendly and exhaustive client to the google-ads-api, code generated directly from google's published protobuf schema.
193 lines (192 loc) • 9.05 kB
TypeScript
import type { RpcTransport } from "@protobuf-ts/runtime-rpc";
import type { ServiceInfo } from "@protobuf-ts/runtime-rpc";
import type { LookupKeyResponse } from "./apikeys";
import type { LookupKeyRequest } from "./apikeys";
import type { UndeleteKeyRequest } from "./apikeys";
import type { DeleteKeyRequest } from "./apikeys";
import type { UpdateKeyRequest } from "./apikeys";
import type { GetKeyStringResponse } from "./apikeys";
import type { GetKeyStringRequest } from "./apikeys";
import type { Key } from "./resources";
import type { GetKeyRequest } from "./apikeys";
import type { ListKeysResponse } from "./apikeys";
import type { ListKeysRequest } from "./apikeys";
import type { Operation } from "../../../longrunning/operations";
import type { CreateKeyRequest } from "./apikeys";
import type { UnaryCall } from "@protobuf-ts/runtime-rpc";
import type { RpcOptions } from "@protobuf-ts/runtime-rpc";
/**
* Manages the API keys associated with projects.
*
* @generated from protobuf service google.api.apikeys.v2.ApiKeys
*/
export interface IApiKeysClient {
/**
* Creates a new API key.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: CreateKey(google.api.apikeys.v2.CreateKeyRequest) returns (google.longrunning.Operation);
*/
createKey(input: CreateKeyRequest, options?: RpcOptions): UnaryCall<CreateKeyRequest, Operation>;
/**
* Lists the API keys owned by a project. The key string of the API key
* isn't included in the response.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: ListKeys(google.api.apikeys.v2.ListKeysRequest) returns (google.api.apikeys.v2.ListKeysResponse);
*/
listKeys(input: ListKeysRequest, options?: RpcOptions): UnaryCall<ListKeysRequest, ListKeysResponse>;
/**
* Gets the metadata for an API key. The key string of the API key
* isn't included in the response.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: GetKey(google.api.apikeys.v2.GetKeyRequest) returns (google.api.apikeys.v2.Key);
*/
getKey(input: GetKeyRequest, options?: RpcOptions): UnaryCall<GetKeyRequest, Key>;
/**
* Get the key string for an API key.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: GetKeyString(google.api.apikeys.v2.GetKeyStringRequest) returns (google.api.apikeys.v2.GetKeyStringResponse);
*/
getKeyString(input: GetKeyStringRequest, options?: RpcOptions): UnaryCall<GetKeyStringRequest, GetKeyStringResponse>;
/**
* Patches the modifiable fields of an API key.
* The key string of the API key isn't included in the response.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: UpdateKey(google.api.apikeys.v2.UpdateKeyRequest) returns (google.longrunning.Operation);
*/
updateKey(input: UpdateKeyRequest, options?: RpcOptions): UnaryCall<UpdateKeyRequest, Operation>;
/**
* Deletes an API key. Deleted key can be retrieved within 30 days of
* deletion. Afterward, key will be purged from the project.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: DeleteKey(google.api.apikeys.v2.DeleteKeyRequest) returns (google.longrunning.Operation);
*/
deleteKey(input: DeleteKeyRequest, options?: RpcOptions): UnaryCall<DeleteKeyRequest, Operation>;
/**
* Undeletes an API key which was deleted within 30 days.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: UndeleteKey(google.api.apikeys.v2.UndeleteKeyRequest) returns (google.longrunning.Operation);
*/
undeleteKey(input: UndeleteKeyRequest, options?: RpcOptions): UnaryCall<UndeleteKeyRequest, Operation>;
/**
* Find the parent project and resource name of the API
* key that matches the key string in the request. If the API key has been
* purged, resource name will not be set.
* The service account must have the `apikeys.keys.lookup` permission
* on the parent project.
*
* @generated from protobuf rpc: LookupKey(google.api.apikeys.v2.LookupKeyRequest) returns (google.api.apikeys.v2.LookupKeyResponse);
*/
lookupKey(input: LookupKeyRequest, options?: RpcOptions): UnaryCall<LookupKeyRequest, LookupKeyResponse>;
}
/**
* Manages the API keys associated with projects.
*
* @generated from protobuf service google.api.apikeys.v2.ApiKeys
*/
export declare class ApiKeysClient implements IApiKeysClient, ServiceInfo {
private readonly _transport;
typeName: string;
methods: import("@protobuf-ts/runtime-rpc").MethodInfo<any, any>[];
options: {
[extensionName: string]: import("@protobuf-ts/runtime").JsonValue;
};
constructor(_transport: RpcTransport);
/**
* Creates a new API key.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: CreateKey(google.api.apikeys.v2.CreateKeyRequest) returns (google.longrunning.Operation);
*/
createKey(input: CreateKeyRequest, options?: RpcOptions): UnaryCall<CreateKeyRequest, Operation>;
/**
* Lists the API keys owned by a project. The key string of the API key
* isn't included in the response.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: ListKeys(google.api.apikeys.v2.ListKeysRequest) returns (google.api.apikeys.v2.ListKeysResponse);
*/
listKeys(input: ListKeysRequest, options?: RpcOptions): UnaryCall<ListKeysRequest, ListKeysResponse>;
/**
* Gets the metadata for an API key. The key string of the API key
* isn't included in the response.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: GetKey(google.api.apikeys.v2.GetKeyRequest) returns (google.api.apikeys.v2.Key);
*/
getKey(input: GetKeyRequest, options?: RpcOptions): UnaryCall<GetKeyRequest, Key>;
/**
* Get the key string for an API key.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: GetKeyString(google.api.apikeys.v2.GetKeyStringRequest) returns (google.api.apikeys.v2.GetKeyStringResponse);
*/
getKeyString(input: GetKeyStringRequest, options?: RpcOptions): UnaryCall<GetKeyStringRequest, GetKeyStringResponse>;
/**
* Patches the modifiable fields of an API key.
* The key string of the API key isn't included in the response.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: UpdateKey(google.api.apikeys.v2.UpdateKeyRequest) returns (google.longrunning.Operation);
*/
updateKey(input: UpdateKeyRequest, options?: RpcOptions): UnaryCall<UpdateKeyRequest, Operation>;
/**
* Deletes an API key. Deleted key can be retrieved within 30 days of
* deletion. Afterward, key will be purged from the project.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: DeleteKey(google.api.apikeys.v2.DeleteKeyRequest) returns (google.longrunning.Operation);
*/
deleteKey(input: DeleteKeyRequest, options?: RpcOptions): UnaryCall<DeleteKeyRequest, Operation>;
/**
* Undeletes an API key which was deleted within 30 days.
*
* NOTE: Key is a global resource; hence the only supported value for
* location is `global`.
*
* @generated from protobuf rpc: UndeleteKey(google.api.apikeys.v2.UndeleteKeyRequest) returns (google.longrunning.Operation);
*/
undeleteKey(input: UndeleteKeyRequest, options?: RpcOptions): UnaryCall<UndeleteKeyRequest, Operation>;
/**
* Find the parent project and resource name of the API
* key that matches the key string in the request. If the API key has been
* purged, resource name will not be set.
* The service account must have the `apikeys.keys.lookup` permission
* on the parent project.
*
* @generated from protobuf rpc: LookupKey(google.api.apikeys.v2.LookupKeyRequest) returns (google.api.apikeys.v2.LookupKeyResponse);
*/
lookupKey(input: LookupKeyRequest, options?: RpcOptions): UnaryCall<LookupKeyRequest, LookupKeyResponse>;
}