fix(chat): support body and content fields in world and DM chat messages; feat(audio): add sound toggle switch and mute controls
checkpoint / checkpoint (push) Successful in 6m11s

This commit is contained in:
2026-09-19 13:38:23 +00:00
parent 7b693899a7
commit 7abf37ea81
13 changed files with 558 additions and 14 deletions
+3 -3
View File
@@ -150,7 +150,7 @@ static func get_dm_messages(api: Node, conversation_id: int, before_id: int = 0,
return await api.request(HTTPClient.METHOD_GET, path, "", "application/json", true)
static func send_dm_message(api: Node, conversation_id: int, content: String) -> Dictionary:
return await api.request(HTTPClient.METHOD_POST, "/api/chat/dm/conversations/%d/messages" % conversation_id, JSON.stringify({"content": content}), "application/json", true)
return await api.request(HTTPClient.METHOD_POST, "/api/chat/dm/conversations/%d/messages" % conversation_id, JSON.stringify({"body": content, "content": content}), "application/json", true)
static func get_world_chat_messages(api: Node, world_id: int, before_id: int = 0, limit: int = 50) -> Dictionary:
var path := "/api/chat/world/%d/messages?limit=%d" % [world_id, limit]
@@ -159,7 +159,7 @@ static func get_world_chat_messages(api: Node, world_id: int, before_id: int = 0
return await api.request(HTTPClient.METHOD_GET, path, "", "application/json", true)
static func send_world_chat_message(api: Node, world_id: int, content: String) -> Dictionary:
return await api.request(HTTPClient.METHOD_POST, "/api/chat/world/%d/messages" % world_id, JSON.stringify({"content": content}), "application/json", true)
return await api.request(HTTPClient.METHOD_POST, "/api/chat/world/%d/messages" % world_id, JSON.stringify({"body": content, "content": content}), "application/json", true)
static func get_room_chat_messages(api: Node, room_id: String, before_id: int = 0, limit: int = 50) -> Dictionary:
var path := "/api/chat/room/%s/messages?limit=%d" % [room_id.uri_encode(), limit]
@@ -168,7 +168,7 @@ static func get_room_chat_messages(api: Node, room_id: String, before_id: int =
return await api.request(HTTPClient.METHOD_GET, path, "", "application/json", true)
static func send_room_chat_message(api: Node, room_id: String, content: String) -> Dictionary:
return await api.request(HTTPClient.METHOD_POST, "/api/chat/room/%s/messages" % room_id.uri_encode(), JSON.stringify({"content": content}), "application/json", true)
return await api.request(HTTPClient.METHOD_POST, "/api/chat/room/%s/messages" % room_id.uri_encode(), JSON.stringify({"body": content, "content": content}), "application/json", true)
static func report_message(api: Node, message_id: int, conversation_type: String, reason: String, context_text: String = "") -> Dictionary:
var payload := {