google-ads-api-client
Version:
A friendly and exhaustive client to the google-ads-api, code generated directly from google's published protobuf schema.
189 lines (188 loc) • 9.21 kB
TypeScript
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 { GeoTargetConstant } from "../resources/geo_target_constant";
/**
* Request message for
* [GeoTargetConstantService.SuggestGeoTargetConstants][google.ads.googleads.v11.services.GeoTargetConstantService.SuggestGeoTargetConstants].
*
* @generated from protobuf message google.ads.googleads.v11.services.SuggestGeoTargetConstantsRequest
*/
export interface SuggestGeoTargetConstantsRequest {
/**
* If possible, returned geo targets are translated using this locale. If not,
* en is used by default. This is also used as a hint for returned geo
* targets.
*
* @generated from protobuf field: optional string locale = 6;
*/
locale?: string;
/**
* Returned geo targets are restricted to this country code.
*
* @generated from protobuf field: optional string country_code = 7;
*/
countryCode?: string;
/**
* @generated from protobuf oneof: query
*/
query: {
oneofKind: "locationNames";
/**
* The location names to search by. At most 25 names can be set.
*
* @generated from protobuf field: google.ads.googleads.v11.services.SuggestGeoTargetConstantsRequest.LocationNames location_names = 1;
*/
locationNames: SuggestGeoTargetConstantsRequest_LocationNames;
} | {
oneofKind: "geoTargets";
/**
* The geo target constant resource names to filter by.
*
* @generated from protobuf field: google.ads.googleads.v11.services.SuggestGeoTargetConstantsRequest.GeoTargets geo_targets = 2;
*/
geoTargets: SuggestGeoTargetConstantsRequest_GeoTargets;
} | {
oneofKind: undefined;
};
}
/**
* A list of location names.
*
* @generated from protobuf message google.ads.googleads.v11.services.SuggestGeoTargetConstantsRequest.LocationNames
*/
export interface SuggestGeoTargetConstantsRequest_LocationNames {
/**
* A list of location names.
*
* @generated from protobuf field: repeated string names = 2;
*/
names: string[];
}
/**
* A list of geo target constant resource names.
*
* @generated from protobuf message google.ads.googleads.v11.services.SuggestGeoTargetConstantsRequest.GeoTargets
*/
export interface SuggestGeoTargetConstantsRequest_GeoTargets {
/**
* A list of geo target constant resource names.
*
* @generated from protobuf field: repeated string geo_target_constants = 2;
*/
geoTargetConstants: string[];
}
/**
* Response message for [GeoTargetConstantService.SuggestGeoTargetConstants][google.ads.googleads.v11.services.GeoTargetConstantService.SuggestGeoTargetConstants].
*
* @generated from protobuf message google.ads.googleads.v11.services.SuggestGeoTargetConstantsResponse
*/
export interface SuggestGeoTargetConstantsResponse {
/**
* Geo target constant suggestions.
*
* @generated from protobuf field: repeated google.ads.googleads.v11.services.GeoTargetConstantSuggestion geo_target_constant_suggestions = 1;
*/
geoTargetConstantSuggestions: GeoTargetConstantSuggestion[];
}
/**
* A geo target constant suggestion.
*
* @generated from protobuf message google.ads.googleads.v11.services.GeoTargetConstantSuggestion
*/
export interface GeoTargetConstantSuggestion {
/**
* The language this GeoTargetConstantSuggestion is currently translated to.
* It affects the name of geo target fields. For example, if locale=en, then
* name=Spain. If locale=es, then name=España. The default locale will be
* returned if no translation exists for the locale in the request.
*
* @generated from protobuf field: optional string locale = 6;
*/
locale?: string;
/**
* Approximate user population that will be targeted, rounded to the
* nearest 100.
*
* @generated from protobuf field: optional int64 reach = 7;
*/
reach?: bigint;
/**
* If the request searched by location name, this is the location name that
* matched the geo target.
*
* @generated from protobuf field: optional string search_term = 8;
*/
searchTerm?: string;
/**
* The GeoTargetConstant result.
*
* @generated from protobuf field: google.ads.googleads.v11.resources.GeoTargetConstant geo_target_constant = 4;
*/
geoTargetConstant?: GeoTargetConstant;
/**
* The list of parents of the geo target constant.
*
* @generated from protobuf field: repeated google.ads.googleads.v11.resources.GeoTargetConstant geo_target_constant_parents = 5;
*/
geoTargetConstantParents: GeoTargetConstant[];
}
declare class SuggestGeoTargetConstantsRequest$Type extends MessageType<SuggestGeoTargetConstantsRequest> {
constructor();
create(value?: PartialMessage<SuggestGeoTargetConstantsRequest>): SuggestGeoTargetConstantsRequest;
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SuggestGeoTargetConstantsRequest): SuggestGeoTargetConstantsRequest;
internalBinaryWrite(message: SuggestGeoTargetConstantsRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
}
/**
* @generated MessageType for protobuf message google.ads.googleads.v11.services.SuggestGeoTargetConstantsRequest
*/
export declare const SuggestGeoTargetConstantsRequest: SuggestGeoTargetConstantsRequest$Type;
declare class SuggestGeoTargetConstantsRequest_LocationNames$Type extends MessageType<SuggestGeoTargetConstantsRequest_LocationNames> {
constructor();
create(value?: PartialMessage<SuggestGeoTargetConstantsRequest_LocationNames>): SuggestGeoTargetConstantsRequest_LocationNames;
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SuggestGeoTargetConstantsRequest_LocationNames): SuggestGeoTargetConstantsRequest_LocationNames;
internalBinaryWrite(message: SuggestGeoTargetConstantsRequest_LocationNames, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
}
/**
* @generated MessageType for protobuf message google.ads.googleads.v11.services.SuggestGeoTargetConstantsRequest.LocationNames
*/
export declare const SuggestGeoTargetConstantsRequest_LocationNames: SuggestGeoTargetConstantsRequest_LocationNames$Type;
declare class SuggestGeoTargetConstantsRequest_GeoTargets$Type extends MessageType<SuggestGeoTargetConstantsRequest_GeoTargets> {
constructor();
create(value?: PartialMessage<SuggestGeoTargetConstantsRequest_GeoTargets>): SuggestGeoTargetConstantsRequest_GeoTargets;
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SuggestGeoTargetConstantsRequest_GeoTargets): SuggestGeoTargetConstantsRequest_GeoTargets;
internalBinaryWrite(message: SuggestGeoTargetConstantsRequest_GeoTargets, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
}
/**
* @generated MessageType for protobuf message google.ads.googleads.v11.services.SuggestGeoTargetConstantsRequest.GeoTargets
*/
export declare const SuggestGeoTargetConstantsRequest_GeoTargets: SuggestGeoTargetConstantsRequest_GeoTargets$Type;
declare class SuggestGeoTargetConstantsResponse$Type extends MessageType<SuggestGeoTargetConstantsResponse> {
constructor();
create(value?: PartialMessage<SuggestGeoTargetConstantsResponse>): SuggestGeoTargetConstantsResponse;
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SuggestGeoTargetConstantsResponse): SuggestGeoTargetConstantsResponse;
internalBinaryWrite(message: SuggestGeoTargetConstantsResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
}
/**
* @generated MessageType for protobuf message google.ads.googleads.v11.services.SuggestGeoTargetConstantsResponse
*/
export declare const SuggestGeoTargetConstantsResponse: SuggestGeoTargetConstantsResponse$Type;
declare class GeoTargetConstantSuggestion$Type extends MessageType<GeoTargetConstantSuggestion> {
constructor();
create(value?: PartialMessage<GeoTargetConstantSuggestion>): GeoTargetConstantSuggestion;
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GeoTargetConstantSuggestion): GeoTargetConstantSuggestion;
internalBinaryWrite(message: GeoTargetConstantSuggestion, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
}
/**
* @generated MessageType for protobuf message google.ads.googleads.v11.services.GeoTargetConstantSuggestion
*/
export declare const GeoTargetConstantSuggestion: GeoTargetConstantSuggestion$Type;
/**
* @generated ServiceType for protobuf service google.ads.googleads.v11.services.GeoTargetConstantService
*/
export declare const GeoTargetConstantService: ServiceType;
export {};