Update Message
curl --request PATCH \
--url https://api.whop.com/api/v1/messages/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"attachments": [
{
"id": "<string>"
}
],
"content": "Edited **message**",
"gifs": [
{
"height": 1073741824,
"original_url": "<string>",
"preview_url": "<string>",
"slug": "<string>",
"title": "<string>",
"url": "<string>",
"width": 1073741824
}
],
"link_previews": [
{
"url": "<string>"
}
]
}
'import requests
url = "https://api.whop.com/api/v1/messages/{id}"
payload = {
"attachments": [{ "id": "<string>" }],
"content": "Edited **message**",
"gifs": [
{
"height": 1073741824,
"original_url": "<string>",
"preview_url": "<string>",
"slug": "<string>",
"title": "<string>",
"url": "<string>",
"width": 1073741824
}
],
"link_previews": [{ "url": "<string>" }]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
attachments: [{id: '<string>'}],
content: 'Edited **message**',
gifs: [
{
height: 1073741824,
original_url: '<string>',
preview_url: '<string>',
slug: '<string>',
title: '<string>',
url: '<string>',
width: 1073741824
}
],
link_previews: [{url: '<string>'}]
})
};
fetch('https://api.whop.com/api/v1/messages/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.whop.com/api/v1/messages/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'attachments' => [
[
'id' => '<string>'
]
],
'content' => 'Edited **message**',
'gifs' => [
[
'height' => 1073741824,
'original_url' => '<string>',
'preview_url' => '<string>',
'slug' => '<string>',
'title' => '<string>',
'url' => '<string>',
'width' => 1073741824
]
],
'link_previews' => [
[
'url' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.whop.com/api/v1/messages/{id}"
payload := strings.NewReader("{\n \"attachments\": [\n {\n \"id\": \"<string>\"\n }\n ],\n \"content\": \"Edited **message**\",\n \"gifs\": [\n {\n \"height\": 1073741824,\n \"original_url\": \"<string>\",\n \"preview_url\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"url\": \"<string>\",\n \"width\": 1073741824\n }\n ],\n \"link_previews\": [\n {\n \"url\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.whop.com/api/v1/messages/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"attachments\": [\n {\n \"id\": \"<string>\"\n }\n ],\n \"content\": \"Edited **message**\",\n \"gifs\": [\n {\n \"height\": 1073741824,\n \"original_url\": \"<string>\",\n \"preview_url\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"url\": \"<string>\",\n \"width\": 1073741824\n }\n ],\n \"link_previews\": [\n {\n \"url\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.whop.com/api/v1/messages/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"attachments\": [\n {\n \"id\": \"<string>\"\n }\n ],\n \"content\": \"Edited **message**\",\n \"gifs\": [\n {\n \"height\": 1073741824,\n \"original_url\": \"<string>\",\n \"preview_url\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"url\": \"<string>\",\n \"width\": 1073741824\n }\n ],\n \"link_previews\": [\n {\n \"url\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"attachments": [
{
"blurhash": null,
"content_type": "application/pdf",
"created_at": "2026-01-01T12:00:00.000Z",
"duration_seconds": null,
"filename": "evidence.pdf",
"height": null,
"id": "file_xxxxxxxxxxxxxx",
"object": "file",
"removed_by_moderation": false,
"size": 9670,
"upload_status": "pending",
"url": "https://whop-assets-example.s3.amazonaws.com/uploads/audio/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"visibility": "private",
"waveform_url": null,
"width": null,
"multipart_chunk_size": 5242880,
"multipart_upload_id": "upload-id",
"multipart_upload_urls": [
{
"part_number": 1,
"url": "https://whop-assets-example.s3.amazonaws.com/uploads/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/application.pdf"
}
],
"upload_headers": {},
"upload_url": "https://whop-assets-example.s3.amazonaws.com/uploads/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/application.pdf"
}
],
"author": {
"id": "user_xxxxxxxxxxxxxx",
"name": "Dana Whitfield",
"profile_picture": {
"url": "https://ui-avatars.com/api/"
},
"username": "danawhitfield"
},
"author_is_team_member": false,
"author_user_id": "user_xxxxxxxxxxxxxx",
"channel_id": "feed_xxxxxxxxxxxxxxxxxxxxxx",
"content": "Content 1",
"created_at": "2026-01-01T12:00:00.000Z",
"custom_author": {
"display_name": "<string>",
"profile_picture": {
"blurhash": null,
"content_type": "application/pdf",
"created_at": "2026-01-01T12:00:00.000Z",
"duration_seconds": null,
"filename": "evidence.pdf",
"height": null,
"id": "file_xxxxxxxxxxxxxx",
"object": "file",
"removed_by_moderation": false,
"size": 9670,
"upload_status": "pending",
"url": "https://whop-assets-example.s3.amazonaws.com/uploads/audio/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"visibility": "private",
"waveform_url": null,
"width": null,
"multipart_chunk_size": 5242880,
"multipart_upload_id": "upload-id",
"multipart_upload_urls": [
{
"part_number": 1,
"url": "https://whop-assets-example.s3.amazonaws.com/uploads/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/application.pdf"
}
],
"upload_headers": {},
"upload_url": "https://whop-assets-example.s3.amazonaws.com/uploads/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/application.pdf"
}
},
"deleted_at": null,
"edited": false,
"embeds": [
{
"color": 123,
"description": "<string>",
"fields": [
{
"inline": true,
"name": "<string>",
"value": "<string>"
}
],
"footer": {
"icon": {
"blurhash": "<string>",
"height": 123,
"url": "<string>",
"width": 123
},
"text": "<string>"
},
"image": {
"blurhash": "<string>",
"height": 123,
"url": "<string>",
"width": 123
},
"thumbnail": {
"blurhash": "<string>",
"height": 123,
"url": "<string>",
"width": 123
},
"timestamp_at": "<string>",
"title": "<string>",
"url": "<string>"
}
],
"gifs": [
{
"height": 123,
"original_url": "<string>",
"preview_url": "<string>",
"slug": "<string>",
"title": "<string>",
"url": "<string>",
"width": 123
}
],
"id": "post_xxxxxxxxxxxxxxxxxxxxxx",
"link_previews": [
{
"description": "<string>",
"favicon_url": "<string>",
"footer": {
"description": "<string>",
"icon_url": "<string>",
"title": "<string>"
},
"image_url": "<string>",
"processing": true,
"title": "<string>",
"url": "<string>"
}
],
"mentioned_user_ids": [
"<string>"
],
"message_type": "regular",
"pinned": false,
"plain_content": "Content 1",
"poll": {
"options": [
{
"id": "1",
"text": "A",
"vote_count": 0,
"voted": false
}
]
},
"reaction_counts": [
{
"kind": "emoji",
"reacted": true,
"total_score": 1,
"user_count": 1,
"value": "❤️"
}
],
"replying_to_message_id": null,
"replying_to_user_id": null,
"updated_at": "2026-01-01T12:00:00.000Z",
"view_count": null,
"replying_to_message": "<unknown>"
}{
"error": {
"message": "account_id is required",
"type": "bad_request",
"code": "<string>"
}
}Messages
Update Message
Updates the author’s message. Use the pin and unpin actions to change its pin state. Omitted fields are preserved; attachment and preview collections replace their previous values.
PATCH
/
messages
/
{id}
Update Message
curl --request PATCH \
--url https://api.whop.com/api/v1/messages/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"attachments": [
{
"id": "<string>"
}
],
"content": "Edited **message**",
"gifs": [
{
"height": 1073741824,
"original_url": "<string>",
"preview_url": "<string>",
"slug": "<string>",
"title": "<string>",
"url": "<string>",
"width": 1073741824
}
],
"link_previews": [
{
"url": "<string>"
}
]
}
'import requests
url = "https://api.whop.com/api/v1/messages/{id}"
payload = {
"attachments": [{ "id": "<string>" }],
"content": "Edited **message**",
"gifs": [
{
"height": 1073741824,
"original_url": "<string>",
"preview_url": "<string>",
"slug": "<string>",
"title": "<string>",
"url": "<string>",
"width": 1073741824
}
],
"link_previews": [{ "url": "<string>" }]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
attachments: [{id: '<string>'}],
content: 'Edited **message**',
gifs: [
{
height: 1073741824,
original_url: '<string>',
preview_url: '<string>',
slug: '<string>',
title: '<string>',
url: '<string>',
width: 1073741824
}
],
link_previews: [{url: '<string>'}]
})
};
fetch('https://api.whop.com/api/v1/messages/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.whop.com/api/v1/messages/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'attachments' => [
[
'id' => '<string>'
]
],
'content' => 'Edited **message**',
'gifs' => [
[
'height' => 1073741824,
'original_url' => '<string>',
'preview_url' => '<string>',
'slug' => '<string>',
'title' => '<string>',
'url' => '<string>',
'width' => 1073741824
]
],
'link_previews' => [
[
'url' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.whop.com/api/v1/messages/{id}"
payload := strings.NewReader("{\n \"attachments\": [\n {\n \"id\": \"<string>\"\n }\n ],\n \"content\": \"Edited **message**\",\n \"gifs\": [\n {\n \"height\": 1073741824,\n \"original_url\": \"<string>\",\n \"preview_url\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"url\": \"<string>\",\n \"width\": 1073741824\n }\n ],\n \"link_previews\": [\n {\n \"url\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.whop.com/api/v1/messages/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"attachments\": [\n {\n \"id\": \"<string>\"\n }\n ],\n \"content\": \"Edited **message**\",\n \"gifs\": [\n {\n \"height\": 1073741824,\n \"original_url\": \"<string>\",\n \"preview_url\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"url\": \"<string>\",\n \"width\": 1073741824\n }\n ],\n \"link_previews\": [\n {\n \"url\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.whop.com/api/v1/messages/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"attachments\": [\n {\n \"id\": \"<string>\"\n }\n ],\n \"content\": \"Edited **message**\",\n \"gifs\": [\n {\n \"height\": 1073741824,\n \"original_url\": \"<string>\",\n \"preview_url\": \"<string>\",\n \"slug\": \"<string>\",\n \"title\": \"<string>\",\n \"url\": \"<string>\",\n \"width\": 1073741824\n }\n ],\n \"link_previews\": [\n {\n \"url\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"attachments": [
{
"blurhash": null,
"content_type": "application/pdf",
"created_at": "2026-01-01T12:00:00.000Z",
"duration_seconds": null,
"filename": "evidence.pdf",
"height": null,
"id": "file_xxxxxxxxxxxxxx",
"object": "file",
"removed_by_moderation": false,
"size": 9670,
"upload_status": "pending",
"url": "https://whop-assets-example.s3.amazonaws.com/uploads/audio/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"visibility": "private",
"waveform_url": null,
"width": null,
"multipart_chunk_size": 5242880,
"multipart_upload_id": "upload-id",
"multipart_upload_urls": [
{
"part_number": 1,
"url": "https://whop-assets-example.s3.amazonaws.com/uploads/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/application.pdf"
}
],
"upload_headers": {},
"upload_url": "https://whop-assets-example.s3.amazonaws.com/uploads/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/application.pdf"
}
],
"author": {
"id": "user_xxxxxxxxxxxxxx",
"name": "Dana Whitfield",
"profile_picture": {
"url": "https://ui-avatars.com/api/"
},
"username": "danawhitfield"
},
"author_is_team_member": false,
"author_user_id": "user_xxxxxxxxxxxxxx",
"channel_id": "feed_xxxxxxxxxxxxxxxxxxxxxx",
"content": "Content 1",
"created_at": "2026-01-01T12:00:00.000Z",
"custom_author": {
"display_name": "<string>",
"profile_picture": {
"blurhash": null,
"content_type": "application/pdf",
"created_at": "2026-01-01T12:00:00.000Z",
"duration_seconds": null,
"filename": "evidence.pdf",
"height": null,
"id": "file_xxxxxxxxxxxxxx",
"object": "file",
"removed_by_moderation": false,
"size": 9670,
"upload_status": "pending",
"url": "https://whop-assets-example.s3.amazonaws.com/uploads/audio/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"visibility": "private",
"waveform_url": null,
"width": null,
"multipart_chunk_size": 5242880,
"multipart_upload_id": "upload-id",
"multipart_upload_urls": [
{
"part_number": 1,
"url": "https://whop-assets-example.s3.amazonaws.com/uploads/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/application.pdf"
}
],
"upload_headers": {},
"upload_url": "https://whop-assets-example.s3.amazonaws.com/uploads/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/application.pdf"
}
},
"deleted_at": null,
"edited": false,
"embeds": [
{
"color": 123,
"description": "<string>",
"fields": [
{
"inline": true,
"name": "<string>",
"value": "<string>"
}
],
"footer": {
"icon": {
"blurhash": "<string>",
"height": 123,
"url": "<string>",
"width": 123
},
"text": "<string>"
},
"image": {
"blurhash": "<string>",
"height": 123,
"url": "<string>",
"width": 123
},
"thumbnail": {
"blurhash": "<string>",
"height": 123,
"url": "<string>",
"width": 123
},
"timestamp_at": "<string>",
"title": "<string>",
"url": "<string>"
}
],
"gifs": [
{
"height": 123,
"original_url": "<string>",
"preview_url": "<string>",
"slug": "<string>",
"title": "<string>",
"url": "<string>",
"width": 123
}
],
"id": "post_xxxxxxxxxxxxxxxxxxxxxx",
"link_previews": [
{
"description": "<string>",
"favicon_url": "<string>",
"footer": {
"description": "<string>",
"icon_url": "<string>",
"title": "<string>"
},
"image_url": "<string>",
"processing": true,
"title": "<string>",
"url": "<string>"
}
],
"mentioned_user_ids": [
"<string>"
],
"message_type": "regular",
"pinned": false,
"plain_content": "Content 1",
"poll": {
"options": [
{
"id": "1",
"text": "A",
"vote_count": 0,
"voted": false
}
]
},
"reaction_counts": [
{
"kind": "emoji",
"reacted": true,
"total_score": 1,
"user_count": 1,
"value": "❤️"
}
],
"replying_to_message_id": null,
"replying_to_user_id": null,
"updated_at": "2026-01-01T12:00:00.000Z",
"view_count": null,
"replying_to_message": "<unknown>"
}{
"error": {
"message": "account_id is required",
"type": "bad_request",
"code": "<string>"
}
}Autorisations
appApiKeyOrAccountUserTokenOrOauthTokenAuthappApiKeyOrAccountUserTokenOrOauthTokenAuthappApiKeyOrAccountUserTokenOrOauthTokenAuth
An App API key, an account-scoped user token, or a user OAuth token. Prepend the key or token with Bearer, for example Bearer ***************************. See Auth & API keys for how to get each one.
Corps
application/json
Réponse
message updated

