Method: properties.customMetrics.patch
Bir mülkte ÖzelMetrik'i günceller.
HTTP isteği
PATCH https://analyticsadmin.googleapis.com/v1beta/{customMetric.name=properties/*/customMetrics/*}
URL, gRPC Kod Dönüştürme söz dizimini kullanır.
Yol parametreleri
Parametreler |
customMetric.name |
string
Yalnızca çıkış. Bu CustomMetric kaynağının kaynak adı. Format: properties/{property}/customMetrics/{customMetric}
|
Sorgu parametreleri
Parametreler |
updateMask |
string (FieldMask format)
Zorunlu. Güncellenecek alanların listesi. Atlanan alanlar güncellenmez. Öğenin tamamını değiştirmek için tüm alanları eşleştirmek üzere "*" dizesiyle bir yol kullanın. Bu, alanların tam nitelikli adlarının virgülle ayrılmış bir listesidir. Örnek: "user.displayName,photo" .
|
İstek içeriği
İstek metni, CustomMetric
öğesinin bir örneğini içerir.
Yanıt gövdesi
Başarılıysa yanıt metni, CustomMetric
öğesinin bir örneğini içerir.
Yetkilendirme kapsamları
Aşağıdaki OAuth kapsamını gerektirir:
https://www.googleapis.com/auth/analytics.edit
Aksi belirtilmediği sürece bu sayfanın içeriği Creative Commons Atıf 4.0 Lisansı altında ve kod örnekleri Apache 2.0 Lisansı altında lisanslanmıştır. Ayrıntılı bilgi için Google Developers Site Politikaları'na göz atın. Java, Oracle ve/veya satış ortaklarının tescilli ticari markasıdır.
Son güncelleme tarihi: 2025-01-14 UTC.
[null,null,["Son güncelleme tarihi: 2025-01-14 UTC."],[[["This method updates a CustomMetric on a Google Analytics 4 property using an HTTP PATCH request to a specific endpoint with the CustomMetric's name in the path."],["You can specify which fields to update with the `updateMask` query parameter, using FieldMask format."],["The request body should contain the updated CustomMetric data in JSON format, adhering to the CustomMetric schema."],["Upon success, the response body will contain the updated CustomMetric, also formatted according to the CustomMetric schema."],["To use this method, your application needs to be authorized with the `https://www.googleapis.com/auth/analytics.edit` OAuth scope."]]],["This document details updating a CustomMetric on a property using a PATCH request to the specified URL: `https://analyticsadmin.googleapis.com/v1beta/{customMetric.name=properties/*/customMetrics/*}`. The `customMetric.name` is a required path parameter. The `updateMask` query parameter specifies fields to be updated. The request and response bodies both contain an instance of CustomMetric. This action requires the `https://www.googleapis.com/auth/analytics.edit` OAuth scope for authorization.\n"]]