Caution: You are viewing documentation for the API's REST interface. Most of our official client libraries use gRPC. See the
REST Introduction for details.
Other Methods
While Mutate
, Search
, and SearchStream
are the most common methods
in the Google Ads API, there are many others for specific purposes. All services and
their APIs are documented in the
REST reference documentation.
Protocol buffer RPC to REST mappings
All the service endpoints (whether using REST and gRPC) are ultimately defined
in the
.proto files of the services package
using the
proto3 Interface Definition Language.
Example: ListAccessibleCustomers
For example, the customer_service.proto
file
defines a ListAccessibleCustomers
method, in addition to the standard Mutate
. Its google.api.http
annotation describes
how the method maps to HTTP. It uses an HTTP GET
with the custom verb
listAccessibleCustomers
:
rpc ListAccessibleCustomers(ListAccessibleCustomersRequest)
returns (ListAccessibleCustomersResponse) {
option (google.api.http) = {
get: "/v19/customers:listAccessibleCustomers"
};
}
This maps to the
customers.listAccessibleCustomers
REST method.
Example: CreateCustomerClient
Another example from customer_service.proto
is
the CreateCustomerClient
method. Its google.api.http
annotation describes an
HTTP POST
using the custom verb createCustomerClient
:
rpc CreateCustomerClient(CreateCustomerClientRequest)
returns (CreateCustomerClientResponse) {
option (google.api.http) = {
post: "/v19/customers/{customer_id=*}:createCustomerClient"
body: "*"
};
option (google.api.method_signature) = "customer_id,customer_client";
}
This maps to the customers.createCustomerClient
REST method.
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-03-03 UTC.
[null,null,["Last updated 2025-03-03 UTC."],[[["While `Mutate`, `Search`, and `SearchStream` are commonly used, the Google Ads API offers a wide range of methods for specific tasks, all documented in the REST reference documentation."],["All Google Ads API service endpoints, including REST and gRPC, are defined in .proto files using the proto3 Interface Definition Language."],["The `google.api.http` annotation within these .proto files details how each method maps to HTTP for RESTful interactions, including examples like `ListAccessibleCustomers` and `CreateCustomerClient`."]]],["The Google Ads API includes various methods beyond `Mutate`, `Search`, and `SearchStream`, all detailed in REST documentation. Service endpoints are defined in `.proto` files using proto3. `ListAccessibleCustomers` is a GET method, mapped using the `google.api.http` annotation in the `customer_service.proto` file, and uses custom verb `listAccessibleCustomers`. Similarly, `CreateCustomerClient`, a POST method, uses custom verb `createCustomerClient`, also defined in the same file.\n"]]