Bir mesajı günceller. patch ve update yöntemleri arasında fark vardır. patch yöntemi bir patch isteği, update yöntemi ise bir put isteği kullanır. patch yöntemini kullanmanızı öneririz. Örnek için Mesaj güncelleme bölümüne bakın.
Burada {space}, mesajın yayınlandığı alanın kimliği, {message} ise mesaja sistem tarafından atanan kimliktir. Örneğin, spaces/AAAAAAAAAAA/messages/BBBBBBBBBBB.BBBBBBBBBBB.
Mesaj oluştururken özel bir kimlik ayarlarsanız {message} değerini clientAssignedMessageId alanındaki değerle değiştirerek mesajı bir istekte belirtmek için bu kimliği kullanabilirsiniz. Örneğin, spaces/AAAAAAAAAAA/messages/client-custom-name. Ayrıntılar için Mesajlara ad verme başlıklı makaleyi inceleyin.
İsteğe bağlı. true ve ileti bulunamazsa yeni bir ileti oluşturulur ve updateMask yoksayılır. Belirtilen ileti kimliği istemci tarafından atanmış olmalıdır. Aksi takdirde istek başarısız olur.
İstek içeriği
İstek metni, Message öğesinin bir örneğini içerir.
Yanıt gövdesi
Başarılıysa yanıt metni, Message öğesinin bir örneğini içerir.
[[["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: 2025-02-27 UTC."],[[["Updates a Google Chat message using the `PATCH` method, preferably over the `update` method which uses `PUT`."],["Supports both app and user authentication, with app authentication limited to updating messages created by the calling Chat app."],["Requires specifying the message to update using its resource name in the URL path and the fields to update using the `updateMask` query parameter."],["Allows creation of a new message if the original is not found when `allowMissing` query parameter is set to `true` and a client-assigned message ID is provided."],["Requires authorization with one of the specified OAuth scopes (`chat.bot`, `chat.import`, or `chat.messages`)."]]],["This documentation outlines how to update a message using the `PATCH` method via an HTTP request to `https://chat.googleapis.com/v1/{message.name=spaces/*/messages/*}`. The `message.name` path parameter is required, specifying the message's resource name. The `updateMask` query parameter is mandatory, indicating which fields to update (e.g., text, attachments). Optionally, `allowMissing` creates a new message if one isn't found. The request and response bodies utilize the `Message` resource, and app or user authentication are supported, with specific authentication impacting permissions.\n"]]