Method: accounts.brands.patch
تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
طلب HTTP
PATCH https://travelpartner.googleapis.com/v3/{brand.name=accounts/*/brands/*}
يستخدم عنوان URL بنية gRPC Transcoding.
معلّمات المسار
المَعلمات |
brand.name |
string
اسم مورد العلامة التجارية بالتنسيق accounts/{account_id}/brands/{brandId} . يجب أن تتطابق السمة brandId مع معرّف العلامة التجارية للشريك الذي تم استخدامه لمطابقة الصفحات المقصودة واستخدامها في قائمة المواقع.
|
معامِلات طلب البحث
المَعلمات |
updateMask |
string (FieldMask format)
مطلوبة. الحقل المطلوب تحديثه. يمكن تعديل الحقلين displayNames وicon_id فقط. استخدِم البنية المعروضة في نموذج معرّف الموارد المنتظم (URI) أدناه وقدِّم القيمة الجديدة في نص الطلب. مثال على عنوان URI للطلب ونص الطلب:
PATCH https://travelpartner.googleapis.com/v3/accounts/123456789/
brands/my-brand?updateMask=brand.display_names
{
"displayNames": [{
"language": "en"
"text": "Gilles' Gites"
}]
}
المعلومات الواردة أعلاه كافية لإنشاء معرف الموارد المنتظم (URI) ونص الطلب. يتم إنشاء الجملة التالية تلقائيًا، وهي معلومات تكميلية حول تنسيق FieldMask بشكل عام. هذه قائمة مفصولة بفواصل للحقول المؤهلة بالكامل. مثال: "user.displayName,photo"
|
نص الطلب
يحتوي نص الطلب على مثال Brand
.
نص الاستجابة
إذا كانت الاستجابة ناجحة، يحتوي نص الاستجابة على مثال Brand
.
نطاقات التفويض
يجب توفير نطاق OAuth التالي:
https://www.googleapis.com/auth/travelpartner
للحصول على مزيد من المعلومات، يُرجى الاطّلاع على نظرة عامة على OAuth 2.0.
جميع الحقوق محفوظة. إنّ Java علامة تجارية مسجَّلة لشركة Oracle و/أو شركائها التابعين.
تاريخ التعديل الأخير: 2022-08-23 (حسب التوقيت العالمي المتفَّق عليه)
[null,null,["تاريخ التعديل الأخير: 2022-08-23 (حسب التوقيت العالمي المتفَّق عليه)"],[[["\u003cp\u003eUpdates an existing brand or creates a new one if it doesn't exist using a PATCH request.\u003c/p\u003e\n"],["\u003cp\u003eRequires specifying the brand name in the URL path and the fields to update using \u003ccode\u003eupdateMask\u003c/code\u003e in the query parameters.\u003c/p\u003e\n"],["\u003cp\u003eThe request body should contain the updated brand information in JSON format as defined by the \u003ccode\u003eBrand\u003c/code\u003e object.\u003c/p\u003e\n"],["\u003cp\u003eSuccessful responses will return the updated \u003ccode\u003eBrand\u003c/code\u003e object, and the request needs \u003ccode\u003ehttps://www.googleapis.com/auth/travelpartner\u003c/code\u003e OAuth scope for authorization.\u003c/p\u003e\n"]]],[],null,["# Method: accounts.brands.patch\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Query parameters](#body.QUERY_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n- [Authorization scopes](#body.aspect)\n\nUpdates a brand.\n\n### HTTP request\n\n`PATCH https://travelpartner.googleapis.com/v3/{brand.name=accounts/*/brands/*}`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|--------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `brand.name` | `string` Output only. The resource name for the brand in the format `accounts/{account_id}/brands/{brandId}`. The `brandId` corresponds to the partner's brand identifier used for landing page matching and the property-level brand identifier. A default brand is applied to properties that do not have a brand. The `brandId` of the default brand is `NO_BRAND_ID`. It can be fetched and updated like any configured brand. |\n\n### Query parameters\n\n| Parameters ||\n|----------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `updateMask` | `string (`[FieldMask](https://protobuf.dev/reference/protobuf/google.protobuf/#field-mask)` format)` Required. The field to update. Only the `displayNames` and `icon` fields can be updated. Use the syntax shown in the example URI below and provide the new value in the request body. Example request URI and request body: PATCH https://travelpartner.googleapis.com/v3/accounts/123456789/ brands/my-brand?updateMask=brand.display_names { \"displayNames\": [{ \"language\": \"en\" \"text\": \"Gilles' Gites\" }] } The information above is sufficient for forming the URI and request body. The sentence below is auto-generated, supplemental information about the `FieldMask` format in general. This is a comma-separated list of fully qualified names of fields. Example: `\"user.displayName,photo\"`. |\n| `allowMissing` | `boolean` When true, and the Brand is not found, a new Brand will be created. In this situation, `updateMask` is ignored. |\n\n### Request body\n\nThe request body contains an instance of [Brand](/hotels/hotel-prices/api-reference/rest/v3/accounts.brands#Brand).\n\n### Response body\n\nIf successful, the response body contains an instance of [Brand](/hotels/hotel-prices/api-reference/rest/v3/accounts.brands#Brand).\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/travelpartner`\n\nFor more information, see the [OAuth 2.0 Overview](/identity/protocols/OAuth2)."]]