Method: properties.insert
Bir dosyaya özellik ekler veya dosya zaten varsa özelliği günceller.
HTTP isteği
POST https://www.googleapis.com/drive/v2/files/{fileId}/properties
URL, gRPC Kod Dönüştürme söz dizimini kullanır.
Yol parametreleri
Parametreler |
fileId |
string
Dosyanın kimliği.
|
İstek içeriği
İstek metni, Property
öğesinin bir örneğini içerir.
Yanıt gövdesi
Başarılı olursa yanıt gövdesi, yeni oluşturulan Property
örneğini içerir.
Yetkilendirme kapsamları
Aşağıdaki OAuth kapsamlarından birini gerektirir:
https://www.googleapis.com/auth/docs
https://www.googleapis.com/auth/drive
https://www.googleapis.com/auth/drive.appdata
https://www.googleapis.com/auth/drive.file
https://www.googleapis.com/auth/drive.metadata
Bazı kapsamlar kısıtlanmıştır ve uygulamanızın bunları kullanabilmesi için güvenlik değerlendirmesi yapılması gerekir. Daha fazla bilgi için Yetkilendirme kılavuzuna göz atın.
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: 2024-09-05 UTC.
[null,null,["Son güncelleme tarihi: 2024-09-05 UTC."],[[["Adds or updates a property on a Google Drive file using the provided file ID."],["The request body must contain a `Property` object defining the property to add or update."],["Upon success, the API returns the newly created or updated `Property` object."],["Requires authorization using one of the specified OAuth scopes, some of which might require a security assessment."]]],["This document outlines the process of adding or updating a property on a file via a POST request. The request URL, using gRPC Transcoding syntax, targets a specific file ID. The request body contains a `Property` instance. Upon success, the response body returns the newly created `Property`. Access requires specific OAuth scopes, such as `drive`, `drive.file`, or `drive.metadata`; certain scopes might require a security assessment. The fileId will be included in the URL path.\n"]]