pub mod unstable {
use ruma_common::{
OwnedDeviceId,
api::{auth_scheme::AccessToken, request, response},
metadata,
serde::Raw,
};
use crate::dehydrated_device::DehydratedDeviceData;
metadata! {
method: GET,
rate_limited: false,
authentication: AccessToken,
history: {
unstable => "/_matrix/client/unstable/org.matrix.msc3814.v1/dehydrated_device",
}
}
#[request(error = crate::Error)]
pub struct Request {}
#[response(error = crate::Error)]
pub struct Response {
pub device_id: OwnedDeviceId,
pub device_data: Raw<DehydratedDeviceData>,
}
impl Request {
pub fn new() -> Self {
Self {}
}
}
impl Response {
pub fn new(device_id: OwnedDeviceId, device_data: Raw<DehydratedDeviceData>) -> Self {
Self { device_id, device_data }
}
}
}