From 7d677f690e028dfe78b1d2f24dcec405d29da7af Mon Sep 17 00:00:00 2001 From: iinuwa Date: Sat, 22 Feb 2020 16:12:34 -0600 Subject: [PATCH] Add unstable_features to version endpoint --- CHANGELOG.md | 1 + src/unversioned/get_supported_versions.rs | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 44529876..4049b6c7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ Improvements: * Add `r0::client_exchange::send_event_to_device` (introduced in r0.3.0) * Add endpoints to retrieve account_data (introduced in r0.5.0) * Add media endpoints: `r0::media::{get_media_config, get_media_preview, get_content_as_filename}` +* Add `unstable_features` to `unversioned::get_supported_versions` (introduced in r0.5.0) Breaking changes: diff --git a/src/unversioned/get_supported_versions.rs b/src/unversioned/get_supported_versions.rs index 5d98b957..fdf98eb5 100644 --- a/src/unversioned/get_supported_versions.rs +++ b/src/unversioned/get_supported_versions.rs @@ -1,4 +1,6 @@ -//! [GET /_matrix/client/versions](https://matrix.org/docs/spec/client_server/r0.4.0.html#get-matrix-client-versions) +//! [GET /_matrix/client/versions](https://matrix.org/docs/spec/client_server/r0.6.0.html#get-matrix-client-versions) + +use std::collections::HashMap; use ruma_api::ruma_api; @@ -17,5 +19,8 @@ ruma_api! { response { /// A list of Matrix client API protocol versions supported by the homeserver. pub versions: Vec, + /// Experimental features supported by the server. + #[serde(default, skip_serializing_if = "HashMap::is_empty")] + pub unstable_features: HashMap } }