2016-06-22 12:03:02 +02:00
|
|
|
---
|
|
|
|
|
allOf:
|
|
|
|
|
- $ref: core-event-schema/room_event.yaml
|
|
|
|
|
description: This message represents a generic file.
|
|
|
|
|
properties:
|
|
|
|
|
content:
|
|
|
|
|
properties:
|
|
|
|
|
body:
|
|
|
|
|
description: A human-readable description of the file. This is recommended to be the filename of the original upload.
|
|
|
|
|
type: string
|
|
|
|
|
filename:
|
|
|
|
|
description: The original filename of the uploaded file.
|
|
|
|
|
type: string
|
|
|
|
|
info:
|
2021-01-27 21:14:31 +01:00
|
|
|
description: Information about the file referred to in `url`.
|
2016-06-22 12:03:02 +02:00
|
|
|
properties:
|
|
|
|
|
mimetype:
|
2021-01-27 21:14:31 +01:00
|
|
|
description: The mimetype of the file e.g. `application/msword`.
|
2016-06-22 12:03:02 +02:00
|
|
|
type: string
|
|
|
|
|
size:
|
|
|
|
|
description: The size of the file in bytes.
|
|
|
|
|
type: integer
|
2016-11-07 15:28:19 +01:00
|
|
|
thumbnail_url:
|
2018-08-31 18:59:57 +02:00
|
|
|
description: |-
|
|
|
|
|
The URL to the thumbnail of the file. Only present if the
|
|
|
|
|
thumbnail is unencrypted.
|
2016-11-07 15:28:19 +01:00
|
|
|
type: string
|
2018-08-31 18:11:27 +02:00
|
|
|
thumbnail_file:
|
|
|
|
|
description: |-
|
|
|
|
|
Information on the encrypted thumbnail file, as specified in
|
2021-01-29 01:00:39 +01:00
|
|
|
[End-to-end encryption](/client-server-api/#sending-encrypted-attachments).
|
|
|
|
|
Only present if the thumbnail is encrypted.
|
2018-08-31 18:11:27 +02:00
|
|
|
title: EncryptedFile
|
|
|
|
|
type: object
|
2016-11-04 15:53:59 +01:00
|
|
|
thumbnail_info:
|
|
|
|
|
allOf:
|
2016-11-07 11:50:52 +01:00
|
|
|
- $ref: core-event-schema/msgtype_infos/thumbnail_info.yaml
|
2021-01-27 21:14:31 +01:00
|
|
|
description: Metadata about the image referred to in `thumbnail_url`.
|
2016-06-22 12:03:02 +02:00
|
|
|
title: FileInfo
|
|
|
|
|
type: object
|
|
|
|
|
msgtype:
|
|
|
|
|
enum:
|
|
|
|
|
- m.file
|
|
|
|
|
type: string
|
|
|
|
|
url:
|
2019-06-11 16:29:50 +02:00
|
|
|
description: |-
|
2021-01-29 01:00:39 +01:00
|
|
|
Required if the file is unencrypted. The URL (typically [MXC URI](/client-server-api/#matrix-content-mxc-uris))
|
2019-06-11 16:29:50 +02:00
|
|
|
to the file.
|
2016-06-22 12:03:02 +02:00
|
|
|
type: string
|
2018-08-31 18:11:27 +02:00
|
|
|
file:
|
|
|
|
|
description: |-
|
|
|
|
|
Required if the file is encrypted. Information on the encrypted
|
2021-01-29 01:00:39 +01:00
|
|
|
file, as specified in
|
|
|
|
|
[End-to-end encryption](/client-server-api/#sending-encrypted-attachments).
|
2018-08-31 18:11:27 +02:00
|
|
|
title: EncryptedFile
|
|
|
|
|
type: object
|
2016-06-22 12:03:02 +02:00
|
|
|
required:
|
|
|
|
|
- msgtype
|
|
|
|
|
- body
|
|
|
|
|
type: object
|
|
|
|
|
type:
|
|
|
|
|
enum:
|
|
|
|
|
- m.room.message
|
|
|
|
|
type: string
|
|
|
|
|
title: FileMessage
|
|
|
|
|
type: object
|