ruwuma/tests/ruma_api_macros.rs
2017-05-13 01:56:26 -07:00

28 lines
719 B
Rust

#![feature(associated_consts, proc_macro, try_from)]
extern crate hyper;
extern crate ruma_api;
extern crate ruma_api_macros;
pub mod get_supported_versions {
use ruma_api_macros::ruma_api;
ruma_api! {
metadata {
description: "Get the versions of the client-server API supported by this homeserver.",
method: Method::Get,
name: "api_versions",
path: "/_matrix/client/versions",
rate_limited: false,
requires_authentication: true,
}
request {}
response {
/// A list of Matrix client API protocol versions supported by the homeserver.
pub versions: Vec<String>,
}
}
}