docs: endpoint documentation

This commit is contained in:
timokoesters 2020-07-31 14:40:28 +02:00 committed by Timo
parent cfda76860b
commit f40f1d9f75
No known key found for this signature in database
GPG key ID: 24DA7517711A2BA4
6 changed files with 83 additions and 3 deletions

View file

@ -5,6 +5,16 @@ use std::collections::BTreeMap;
#[cfg(feature = "conduit_bin")]
use rocket::get;
/// # `GET /_matrix/client/versions`
///
/// Get the versions of the specification and unstable features supported by this server.
///
/// - Versions take the form MAJOR.MINOR.PATCH
/// - Only the latest PATCH release will be reported for each MAJOR.MINOR value
/// - Unstable features should be namespaced and may include version information in their name
///
/// Note: Unstable features are used while developing new features. Clients should avoid using
/// unstable features in their stable releases
#[cfg_attr(feature = "conduit_bin", get("/_matrix/client/versions"))]
pub fn get_supported_versions_route() -> ConduitResult<get_supported_versions::Response> {
let mut unstable_features = BTreeMap::new();