অন্যান্য পদ্ধতি

অনুসরণ করতে ভুলবেন না।

Google Ads API-তে Mutate, Search ও SearchStream সবচেয়ে সাধারণ পদ্ধতি হলেও, নির্দিষ্ট উদ্দেশ্যে ব্যবহার করার জন্য আরও অনেক পদ্ধতি আছে। সব পরিষেবা এবং তাদের API-এর ডকুমেন্টেশন রেফারেন্স ডকুমেন্টেশন-এ রয়েছে।

প্রোটোকল বাফার RPC থেকে REST ম্যাপিং

সব পরিষেবা এন্ডপয়েন্ট (REST ও gRPC ব্যবহার করা হোক বা না হোক) শেষ পর্যন্ত পরিষেবা প্যাকেজের .proto ফাইলে proto3 ইন্টারফেস ডেফিনিশন ল্যাঙ্গুয়েজ ব্যবহার করে সংজ্ঞায়িত করা হয়।

উদাহরণ: ListAccessibleCustomers

যেমন, customer_service.proto ফাইলটি স্ট্যান্ডার্ড Mutate ছাড়াও একটি ListAccessibleCustomers পদ্ধতি সংজ্ঞায়িত করে। এর google.api.http অ্যানোটেশন বর্ণনা করে কীভাবে পদ্ধতিটি HTTP-তে ম্যাপ করে। এটি কাস্টম ভার্ব সহ HTTP GET ব্যবহার করে listAccessibleCustomers:

rpc ListAccessibleCustomers(ListAccessibleCustomersRequest)
    returns (ListAccessibleCustomersResponse) {
  option (google.api.http) = {
    get: "/v26/customers:listAccessibleCustomers"
  };
}

এটি customers.listAccessibleCustomers REST পদ্ধতিতে ম্যাপ করা হয়।

উদাহরণ: CreateCustomerClient

customer_service.proto থেকে আরেকটি উদাহরণ হল CreateCustomerClient পদ্ধতি। এর google.api.http অ্যানোটেশন কাস্টম ভার্ব createCustomerClient ব্যবহার করে HTTP POST বর্ণনা করে:

rpc CreateCustomerClient(CreateCustomerClientRequest)
    returns (CreateCustomerClientResponse) {
  option (google.api.http) = {
    post: "/v26/customers/{customer_id=*}:createCustomerClient"
    body: "*"
  };
  option (google.api.method_signature) = "customer_id,customer_client";
}

এটি customers.createCustomerClient REST পদ্ধতিতে ম্যাপ করে।