Skip to content
gist.link ↗

updateMessage

Mutation Teams API — POST https://teams.api.gist.link/graphql

Edit a chat message’s body. Only the original author.

teams:mutation:updateMessage

The calling IAM key must hold this permission (or a wildcard that covers it: teams:mutation:* or teams:*) and the access token must have been minted with audience=teams. See Permissions.

type Mutation {
updateMessage(id: Int!, body: String!): Message!
}
Argument Type Required Description
id Int! Yes —
body String! Yes —

Message! — see the Teams types reference.

Terminal window
curl https://teams.api.gist.link/graphql \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H 'Content-Type: application/json' \
-d @- <<'JSON'
{
"query": "mutation UpdateMessage($id: Int!, $body: String!) { updateMessage(id: $id, body: $body) { id channel_id conversation_id parent_id author_user_id author_name body pinned_at } }",
"variables": {
"id": 10,
"body": "example"
}
}
JSON