Method: photos.batchUpdate
Koleksiyonlar ile düzeninizi koruyun
İçeriği tercihlerinize göre kaydedin ve kategorilere ayırın.
Poz, yer ilişkilendirmesi, bağlantılar gibi Photos
meta verilerini günceller. Fotoğrafların piksellerinin değiştirilmesi desteklenmez.
photos.batchUpdate
başarısız olursa kritik alanların eksik olduğunu veya bir kimlik doğrulama hatası olduğunu unutmayın. photos.batchUpdate
başarılı olsa bile, gruptaki tek tek fotoğraflarda hata oluşabilir. Bu hatalar, BatchUpdatePhotosResponse.results
içindeki her bir PhotoResponse.status
içinde belirtilir. Her fotoğrafta oluşabilecek belirli hatalar için photo.update
sayfasına bakın.
Yalnızca updateMask
alanında belirtilen alanlar kullanılır. updateMask
mevcut değilse güncelleme tüm alanlar için geçerli olur.
BatchUpdatePhotosRequest
içindeki UpdatePhotoRequest
mesajlarının sayısı 20'den fazla olmamalıdır.
Not: Pose.altitude
alanının güncellenmesi için Pose.latLngPair
alanının da doldurulması gerekir. Aksi takdirde istek başarısız olur.
HTTP isteği
POST https://streetviewpublish.googleapis.com/v1/photos:batchUpdate
URL, gRPC Kod Dönüştürme söz dizimini kullanır.
İstek içeriği
İstek gövdesi, aşağıdaki yapıya sahip verileri içerir:
JSON gösterimi |
{
"updatePhotoRequests": [
{
"photo": {
object (Photo )
},
"updateMask": string
}
]
} |
Alanlar |
updatePhotoRequests[] |
object
Zorunlu. UpdatePhotoRequests listesi.
|
updatePhotoRequests[].photo |
object (Photo )
Zorunlu. Yeni meta veriyi içeren Photo nesnesi.
|
updatePhotoRequests[].updateMask |
string (FieldMask format)
Zorunlu. Fotoğraf meta verilerindeki güncellenecek alanları tanımlayan maske. Mevcut değilse bu istekte eski Photo meta verisi tamamen yeni Photo meta verisi ile değiştirilir. Geçersiz alanlar belirtilirse güncelleme başarısız olur. Virgülle ayrılmış bir listede birden çok alan belirtilebilir. Şu alanlar geçerlidir:
pose.heading
pose.lat_lng_pair
pose.pitch
pose.roll
pose.level
pose.altitude
connections
places
Not: updateMask yinelenen alanlar içerdiğinde, yinelenen değer kümesinin tamamı yeni içeriklerle değiştirilir. Örneğin, updateMask değeri connections değerini içeriyorsa ve UpdatePhotoRequest.photo.connections boşsa tüm bağlantılar kaldırılır.
|
Yanıt gövdesi
Bir veya daha fazla Photos
öğesinin meta verilerinin toplu güncellemesine verilen yanıt.
Başarılı olursa yanıt metni aşağıdaki yapıyla birlikte verileri içerir:
Alanlar |
results[] |
object (PhotoResponse )
Her Photo için sonuçların listesi, istekle aynı sırada güncellenir.
|
Yetkilendirme kapsamları
Aşağıdaki OAuth kapsamını gerektirir:
https://www.googleapis.com/auth/streetviewpublish
Daha fazla bilgi için OAuth 2.0 Overview (OAuth 2.0'a Genel Bakış) sayfasına 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-10 UTC.
[[["Anlaması kolay","easyToUnderstand","thumb-up"],["Sorunumu çözdü","solvedMyProblem","thumb-up"],["Diğer","otherUp","thumb-up"]],[["İhtiyacım olan bilgiler yok","missingTheInformationINeed","thumb-down"],["Çok karmaşık / çok fazla adım var","tooComplicatedTooManySteps","thumb-down"],["Güncel değil","outOfDate","thumb-down"],["Çeviri sorunu","translationIssue","thumb-down"],["Örnek veya kod sorunu","samplesCodeIssue","thumb-down"],["Diğer","otherDown","thumb-down"]],["Son güncelleme tarihi: 2024-09-10 UTC."],[[["The API updates metadata of photos, such as pose, connections, and place association, but does not change pixel data."],["Requests are submitted as a batch of up to 20 `UpdatePhotoRequest` messages specifying the photo and fields to update."],["If the `updateMask` is not provided, all fields of the Photo resource will be updated with the values provided in the request."],["When updating `Pose.altitude`, `Pose.latLngPair` must also be specified, or the request will fail."],["This API requires the `https://www.googleapis.com/auth/streetviewpublish` OAuth scope for authorization."]]],["This document details the process of updating photo metadata via the `photos:batchUpdate` method. It outlines that you can update fields like pose, place association, and connections, but not photo pixels. The request involves sending `UpdatePhotoRequests` within a `BatchUpdatePhotosRequest` to `POST https://streetviewpublish.googleapis.com/v1/photos:batchUpdate`. An `updateMask` specifies which fields to modify. The response contains a list of `PhotoResponse` objects, indicating the success or failure of each photo update. A maximum of 20 `UpdatePhotoRequest` messages are allowed.\n"]]