google-ads-api-client
Version:
A friendly and exhaustive client to the google-ads-api, code generated directly from google's published protobuf schema.
161 lines (160 loc) • 6.47 kB
TypeScript
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 { Any } from "../../../protobuf/any";
import { LogEntry } from "./log_entry";
import { MetricValueSet } from "./metric_value";
import { Timestamp } from "../../../protobuf/timestamp";
/**
* Represents information regarding an operation.
*
* @generated from protobuf message google.api.servicecontrol.v1.Operation
*/
export interface Operation {
/**
* Identity of the operation. This must be unique within the scope of the
* service that generated the operation. If the service calls
* Check() and Report() on the same operation, the two calls should carry
* the same id.
*
* UUID version 4 is recommended, though not required.
* In scenarios where an operation is computed from existing information
* and an idempotent id is desirable for deduplication purpose, UUID version 5
* is recommended. See RFC 4122 for details.
*
* @generated from protobuf field: string operation_id = 1;
*/
operationId: string;
/**
* Fully qualified name of the operation. Reserved for future use.
*
* @generated from protobuf field: string operation_name = 2;
*/
operationName: string;
/**
* Identity of the consumer who is using the service.
* This field should be filled in for the operations initiated by a
* consumer, but not for service-initiated operations that are
* not related to a specific consumer.
*
* - This can be in one of the following formats:
* - project:PROJECT_ID,
* - project`_`number:PROJECT_NUMBER,
* - projects/PROJECT_ID or PROJECT_NUMBER,
* - folders/FOLDER_NUMBER,
* - organizations/ORGANIZATION_NUMBER,
* - api`_`key:API_KEY.
*
* @generated from protobuf field: string consumer_id = 3;
*/
consumerId: string;
/**
* Required. Start time of the operation.
*
* @generated from protobuf field: google.protobuf.Timestamp start_time = 4;
*/
startTime?: Timestamp;
/**
* End time of the operation.
* Required when the operation is used in
* [ServiceController.Report][google.api.servicecontrol.v1.ServiceController.Report],
* but optional when the operation is used in
* [ServiceController.Check][google.api.servicecontrol.v1.ServiceController.Check].
*
* @generated from protobuf field: google.protobuf.Timestamp end_time = 5;
*/
endTime?: Timestamp;
/**
* Labels describing the operation. Only the following labels are allowed:
*
* - Labels describing monitored resources as defined in
* the service configuration.
* - Default labels of metric values. When specified, labels defined in the
* metric value override these default.
* - The following labels defined by Google Cloud Platform:
* - `cloud.googleapis.com/location` describing the location where the
* operation happened,
* - `servicecontrol.googleapis.com/user_agent` describing the user agent
* of the API request,
* - `servicecontrol.googleapis.com/service_agent` describing the service
* used to handle the API request (e.g. ESP),
* - `servicecontrol.googleapis.com/platform` describing the platform
* where the API is served, such as App Engine, Compute Engine, or
* Kubernetes Engine.
*
* @generated from protobuf field: map<string, string> labels = 6;
*/
labels: {
[key: string]: string;
};
/**
* Represents information about this operation. Each MetricValueSet
* corresponds to a metric defined in the service configuration.
* The data type used in the MetricValueSet must agree with
* the data type specified in the metric definition.
*
* Within a single operation, it is not allowed to have more than one
* MetricValue instances that have the same metric names and identical
* label value combinations. If a request has such duplicated MetricValue
* instances, the entire request is rejected with
* an invalid argument error.
*
* @generated from protobuf field: repeated google.api.servicecontrol.v1.MetricValueSet metric_value_sets = 7;
*/
metricValueSets: MetricValueSet[];
/**
* Represents information to be logged.
*
* @generated from protobuf field: repeated google.api.servicecontrol.v1.LogEntry log_entries = 8;
*/
logEntries: LogEntry[];
/**
* DO NOT USE. This is an experimental field.
*
* @generated from protobuf field: google.api.servicecontrol.v1.Operation.Importance importance = 11;
*/
importance: Operation_Importance;
/**
* Unimplemented.
*
* @generated from protobuf field: repeated google.protobuf.Any extensions = 16;
*/
extensions: Any[];
}
/**
* Defines the importance of the data contained in the operation.
*
* @generated from protobuf enum google.api.servicecontrol.v1.Operation.Importance
*/
export declare enum Operation_Importance {
/**
* Allows data caching, batching, and aggregation. It provides
* higher performance with higher data loss risk.
*
* @generated from protobuf enum value: LOW = 0;
*/
LOW = 0,
/**
* Disables data aggregation to minimize data loss. It is for operations
* that contains significant monetary value or audit trail. This feature
* only applies to the client libraries.
*
* @generated from protobuf enum value: HIGH = 1;
*/
HIGH = 1
}
declare class Operation$Type extends MessageType<Operation> {
constructor();
create(value?: PartialMessage<Operation>): Operation;
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Operation): Operation;
private binaryReadMap6;
internalBinaryWrite(message: Operation, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
}
/**
* @generated MessageType for protobuf message google.api.servicecontrol.v1.Operation
*/
export declare const Operation: Operation$Type;
export {};