Method: properties.updateDataRetentionSettings
Memperbarui setelan retensi data singleton untuk properti ini.
Permintaan HTTP
PATCH https://analyticsadmin.googleapis.com/v1alpha/{dataRetentionSettings.name=properties/*/dataRetentionSettings}
URL menggunakan sintaksis gRPC Transcoding.
Parameter jalur
Parameter |
dataRetentionSettings.name |
string
Hanya output. Nama resource untuk resource DataRetentionSetting ini. Format: properties/{property}/dataRetentionSettings
|
Parameter kueri
Parameter |
updateMask |
string (FieldMask format)
Wajib. Daftar kolom yang akan diperbarui. Nama kolom harus dalam snake case (misalnya, "field_to_update"). Kolom yang dihilangkan tidak akan diperbarui. Untuk mengganti seluruh entitas, gunakan satu jalur dengan string "*" untuk mencocokkan semua kolom. Ini adalah daftar dipisahkan koma yang berisi nama-nama kolom yang sepenuhnya memenuhi syarat. Contoh: "user.displayName,photo" .
|
Isi permintaan
Isi permintaan memuat instance DataRetentionSettings
.
Isi respons
Jika berhasil, isi respons memuat instance DataRetentionSettings
.
Cakupan otorisasi
Memerlukan cakupan OAuth berikut:
https://www.googleapis.com/auth/analytics.edit
Kecuali dinyatakan lain, konten di halaman ini dilisensikan berdasarkan Lisensi Creative Commons Attribution 4.0, sedangkan contoh kode dilisensikan berdasarkan Lisensi Apache 2.0. Untuk mengetahui informasi selengkapnya, lihat Kebijakan Situs Google Developers. Java adalah merek dagang terdaftar dari Oracle dan/atau afiliasinya.
Terakhir diperbarui pada 2025-01-14 UTC.
[null,null,["Terakhir diperbarui pada 2025-01-14 UTC."],[[["This endpoint updates the data retention settings for a Google Analytics 4 property using an HTTP PATCH request."],["It requires specifying the `dataRetentionSettings.name` as a path parameter to identify the property's settings."],["An `updateMask` query parameter is required to indicate which fields should be updated within the data retention settings."],["The request body should contain the updated `DataRetentionSettings` object, and a successful response will return the updated settings."],["Users need the `https://www.googleapis.com/auth/analytics.edit` OAuth scope to authorize this request."]]],["This document details updating data retention settings for a property using a `PATCH` request to the specified URL. The resource path is defined by `dataRetentionSettings.name`, and the request requires a `updateMask` query parameter specifying fields to update. The request body contains `DataRetentionSettings`, and a successful response also returns `DataRetentionSettings`. This operation requires authorization with the `https://www.googleapis.com/auth/analytics.edit` scope. Additionally, it indicates that there are HTTP requests, path, query, request, and response bodies, and offers a 'try it!' feature.\n"]]