ruma_client_api

Module media

Source
Available on crate features client or server only.
Expand description

Endpoints and helpers for the media repository.

Modules§

create_content
POST /_matrix/media/*/upload
create_content_async
PUT /_matrix/media/*/upload/{serverName}/{mediaId}
create_mxc_uri
POST /_matrix/media/*/create
get_content
GET /_matrix/media/*/download/{serverName}/{mediaId}
get_content_as_filename
GET /_matrix/media/*/download/{serverName}/{mediaId}/{fileName}
get_content_thumbnail
GET /_matrix/media/*/thumbnail/{serverName}/{mediaId}
get_media_config
GET /_matrix/media/*/config
get_media_preview
GET /_matrix/media/*/preview_url

Functions§

is_safe_inline_content_type
Checks whether a given Content-Type is considered “safe” for having a Content-Disposition of inline returned on /download, as recommended by the spec.