You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
64 lines
2.3 KiB
Plaintext
64 lines
2.3 KiB
Plaintext
10 years ago
|
{
|
||
|
"type": "object",
|
||
|
"title": "FileMessage",
|
||
10 years ago
|
"description": "This message represents a generic file.",
|
||
10 years ago
|
"allOf": [{
|
||
9 years ago
|
"$ref": "core-event-schema/room_event.json"
|
||
10 years ago
|
}],
|
||
|
"properties": {
|
||
|
"content": {
|
||
|
"type": "object",
|
||
|
"properties": {
|
||
|
"msgtype": {
|
||
|
"type": "string",
|
||
|
"enum": ["m.file"]
|
||
|
},
|
||
|
"filename": {
|
||
|
"type": "string",
|
||
|
"description": "The original filename of the uploaded file."
|
||
|
},
|
||
|
"body": {
|
||
|
"type": "string",
|
||
|
"description": "A human-readable description of the file. This is recommended to be the filename of the original upload."
|
||
|
},
|
||
|
"url": {
|
||
|
"type": "string",
|
||
|
"description": "The URL to the file."
|
||
|
},
|
||
|
"info": {
|
||
|
"type": "object",
|
||
|
"title": "FileInfo",
|
||
|
"description": "Information about the file referred to in ``url``.",
|
||
|
"properties": {
|
||
|
"size": {
|
||
|
"type": "integer",
|
||
|
"description": "The size of the file in bytes."
|
||
|
},
|
||
|
"mimetype": {
|
||
|
"type": "string",
|
||
|
"description": "The mimetype of the file e.g. ``application/msword``."
|
||
|
}
|
||
|
}
|
||
|
},
|
||
|
"thumbnail_url": {
|
||
|
"type": "string",
|
||
|
"description": "The URL to the thumbnail of the file."
|
||
|
},
|
||
|
"thumbnail_info": {
|
||
|
"type": "object",
|
||
|
"title": "ImageInfo",
|
||
|
"description": "Metadata about the image referred to in ``thumbnail_url``.",
|
||
10 years ago
|
"allOf": [{
|
||
9 years ago
|
"$ref": "core-event-schema/msgtype_infos/image_info.json"
|
||
10 years ago
|
}]
|
||
10 years ago
|
}
|
||
|
},
|
||
|
"required": ["msgtype", "body", "url", "filename"]
|
||
|
},
|
||
|
"type": {
|
||
|
"type": "string",
|
||
|
"enum": ["m.room.message"]
|
||
|
}
|
||
|
}
|
||
|
}
|