impl EndpointError for Error
Co-authored-by: Jonas Platte <jplatte@users.noreply.github.com>
This commit is contained in:
parent
122097cfef
commit
1e3769a0f1
@ -3,6 +3,7 @@
|
||||
Improvements:
|
||||
|
||||
* Add an `Error` type that represents the well-known errors in the client-server API
|
||||
* the response deserialization code will try to create an instance of this type from http responses that indicate an error
|
||||
* Add OpenID token request endpoint.
|
||||
* Add `r0::client_exchange::send_event_to_device` (introduced in r0.3.0)
|
||||
* Add endpoints to retrieve account_data (introduced in r0.5.0)
|
||||
@ -14,7 +15,7 @@ Improvements:
|
||||
|
||||
Breaking changes:
|
||||
|
||||
* Update ruma-api to 0.14.0
|
||||
* Update ruma-api to 0.15.0
|
||||
* Fix `r0::session::get_login_types`
|
||||
* Add `allow_remote` parameter to `r0::media::get_content`
|
||||
* Add missing parameters for `r0::room::create_room`
|
||||
|
@ -15,10 +15,10 @@ edition = "2018"
|
||||
[dependencies]
|
||||
http = "0.2.0"
|
||||
js_int = { version = "0.1.3", features = ["serde"] }
|
||||
ruma-api = "0.14.0"
|
||||
ruma-api = "0.15.0-dev.1"
|
||||
ruma-events = "0.17.0"
|
||||
ruma-identifiers = "0.14.1"
|
||||
serde = { version = "1.0.104", features = ["derive"] }
|
||||
serde_json = "1.0.48"
|
||||
strum = { version = "0.17.1", features = ["derive"] }
|
||||
strum = { version = "0.18.0", features = ["derive"] }
|
||||
url = { version = "2.1.1", features = ["serde"] }
|
||||
|
12
src/error.rs
12
src/error.rs
@ -1,5 +1,6 @@
|
||||
//! Errors that can be sent from the homeserver.
|
||||
|
||||
use ruma_api::{error::ResponseDeserializationError, EndpointError};
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
/// An enum for the error kind. Items may contain additional information.
|
||||
@ -117,6 +118,17 @@ pub struct Error {
|
||||
pub status_code: http::StatusCode,
|
||||
}
|
||||
|
||||
impl EndpointError for Error {
|
||||
fn try_from_response(
|
||||
response: http::Response<Vec<u8>>,
|
||||
) -> Result<Self, ResponseDeserializationError> {
|
||||
match serde_json::from_slice::<ErrorBody>(response.body()) {
|
||||
Ok(error_body) => Ok(error_body.into_error(response.status())),
|
||||
Err(de_error) => Err(ResponseDeserializationError::new(de_error, response)),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl From<Error> for ErrorBody {
|
||||
fn from(error: Error) -> Self {
|
||||
Self {
|
||||
|
@ -13,3 +13,5 @@ pub mod r0;
|
||||
pub mod unversioned;
|
||||
|
||||
mod serde;
|
||||
|
||||
pub use error::Error;
|
||||
|
@ -26,4 +26,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -22,4 +22,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -28,4 +28,6 @@ ruma_api! {
|
||||
/// Result of unbind operation.
|
||||
pub id_server_unbind_result: ThirdPartyIdRemovalStatus,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -30,4 +30,6 @@ ruma_api! {
|
||||
pub id_server_unbind_result: ThirdPartyIdRemovalStatus,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
|
||||
}
|
||||
|
@ -23,4 +23,6 @@ ruma_api! {
|
||||
/// This should always be true when the server replies with 200 OK.
|
||||
pub available: bool
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -73,6 +73,8 @@ ruma_api! {
|
||||
/// Will be the same as the corresponding parameter in the request, if one was specified.
|
||||
pub device_id: DeviceId,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// The kind of account being registered.
|
||||
|
@ -38,4 +38,6 @@ ruma_api! {
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub submit_url: Option<String>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -40,4 +40,6 @@ ruma_api! {
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub submit_url: Option<String>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -33,6 +33,8 @@ ruma_api! {
|
||||
#[serde(with = "crate::serde::duration::secs")]
|
||||
pub expires_in: Duration,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// Access token types.
|
||||
|
@ -38,4 +38,6 @@ ruma_api! {
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub submit_url: Option<String>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -34,4 +34,6 @@ ruma_api! {
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub submit_url: Option<String>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -38,4 +38,6 @@ ruma_api! {
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub submit_url: Option<String>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -40,4 +40,6 @@ ruma_api! {
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub submit_url: Option<String>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -29,4 +29,6 @@ ruma_api! {
|
||||
/// Result of unbind operation.
|
||||
pub id_server_unbind_result: ThirdPartyIdRemovalStatus,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -18,4 +18,6 @@ ruma_api! {
|
||||
/// The id of the user that owns the access token.
|
||||
pub user_id: String,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -22,4 +22,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -20,4 +20,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -25,4 +25,6 @@ ruma_api! {
|
||||
/// A list of servers that are aware of this room ID.
|
||||
pub servers: Vec<String>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -27,4 +27,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -21,6 +21,8 @@ ruma_api! {
|
||||
/// The capabilities the server supports
|
||||
pub capabilities: Capabilities,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// Contains information about all the capabilities that the server supports.
|
||||
|
@ -33,4 +33,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -29,4 +29,6 @@ ruma_api! {
|
||||
#[wrap_incoming(with EventResult)]
|
||||
pub account_data: only::Event,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -32,4 +32,6 @@ ruma_api! {
|
||||
#[wrap_incoming(with EventResult)]
|
||||
pub account_data: only::Event,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -31,4 +31,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -34,4 +34,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -21,6 +21,8 @@ ruma_api! {
|
||||
/// account.
|
||||
pub threepids: Vec<ThirdPartyIdentifier>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// An identifier external to Matrix.
|
||||
|
@ -26,4 +26,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -56,4 +56,6 @@ ruma_api! {
|
||||
#[wrap_incoming(only::StateEvent with EventResult)]
|
||||
pub state: Vec<only::StateEvent>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -24,4 +24,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -24,4 +24,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -25,4 +25,6 @@ ruma_api! {
|
||||
#[ruma_api(body)]
|
||||
pub device: Device,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -18,4 +18,6 @@ ruma_api! {
|
||||
response {
|
||||
devices: Vec<Device>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -24,4 +24,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -42,4 +42,6 @@ ruma_api! {
|
||||
/// An estimate on the total number of public rooms, if the server has an estimate.
|
||||
pub total_room_count_estimate: Option<UInt>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -44,6 +44,8 @@ ruma_api! {
|
||||
/// An estimate on the total number of public rooms, if the server has an estimate.
|
||||
pub total_room_count_estimate: Option<UInt>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// A filter for public rooms lists
|
||||
|
@ -30,4 +30,6 @@ ruma_api! {
|
||||
/// The ID of the filter that was created.
|
||||
pub filter_id: String,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -29,4 +29,6 @@ ruma_api! {
|
||||
#[ruma_api(body)]
|
||||
pub filter: FilterDefinition,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -39,4 +39,6 @@ ruma_api! {
|
||||
/// One-time keys for the queried devices.
|
||||
pub one_time_keys: HashMap<UserId, HashMap<DeviceId, HashMap<AlgorithmAndDeviceId, OneTimeKey>>>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -33,4 +33,6 @@ ruma_api! {
|
||||
/// encrypted rooms they previously shared with the user.
|
||||
pub left: Vec<UserId>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -43,4 +43,6 @@ ruma_api! {
|
||||
/// Information on the queried devices.
|
||||
pub device_keys: HashMap<UserId, HashMap<DeviceId, DeviceKeys>>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -32,4 +32,6 @@ ruma_api! {
|
||||
/// type currently held on the server for this device.
|
||||
pub one_time_key_counts: HashMap<KeyAlgorithm, UInt>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -29,4 +29,6 @@ ruma_api! {
|
||||
/// The MXC URI for the uploaded content.
|
||||
pub content_uri: String,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -36,4 +36,6 @@ ruma_api! {
|
||||
#[ruma_api(header = CONTENT_DISPOSITION)]
|
||||
pub content_disposition: String,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -39,4 +39,6 @@ ruma_api! {
|
||||
#[ruma_api(header = CONTENT_DISPOSITION)]
|
||||
pub content_disposition: String,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -57,4 +57,6 @@ ruma_api! {
|
||||
#[ruma_api(body)]
|
||||
pub file: Vec<u8>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -20,4 +20,6 @@ ruma_api! {
|
||||
#[serde(rename = "m.upload.size")]
|
||||
pub upload_size: UInt,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -31,4 +31,6 @@ ruma_api! {
|
||||
#[ruma_api(body)]
|
||||
pub data: Option<Value>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -25,4 +25,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -20,4 +20,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -25,4 +25,6 @@ ruma_api! {
|
||||
#[wrap_incoming(MemberEvent with EventResult)]
|
||||
pub chunk: Vec<MemberEvent>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -32,6 +32,8 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// Distinguishes between invititations by Matrix or third party identifiers.
|
||||
|
@ -29,4 +29,6 @@ ruma_api! {
|
||||
/// The room that the user joined.
|
||||
pub room_id: RoomId,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -29,4 +29,6 @@ ruma_api! {
|
||||
/// The room that the user joined.
|
||||
pub room_id: RoomId,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -27,6 +27,8 @@ ruma_api! {
|
||||
/// the ID of each room in which the user has joined membership.
|
||||
pub joined: HashMap<UserId, RoomMember>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
// TODO: Find out whether display_name and avatar_url are optional
|
||||
|
@ -20,4 +20,6 @@ ruma_api! {
|
||||
/// the ID of each room in which the user has joined membership.
|
||||
pub joined_rooms: Vec<RoomId>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -25,4 +25,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -20,4 +20,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -22,4 +22,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -38,4 +38,6 @@ ruma_api! {
|
||||
/// A unique identifier for the event.
|
||||
pub event_id: EventId,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -61,6 +61,8 @@ ruma_api! {
|
||||
/// The token the pagination ends at.
|
||||
pub end: String,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// The direction to return events from.
|
||||
|
@ -36,4 +36,6 @@ ruma_api! {
|
||||
/// The user's presence state.
|
||||
pub presence: PresenceState,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -26,4 +26,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -24,4 +24,6 @@ ruma_api! {
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub avatar_url: Option<String>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -24,4 +24,6 @@ ruma_api! {
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub displayname: Option<String>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -27,4 +27,6 @@ ruma_api! {
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub displayname: Option<String>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -22,4 +22,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -23,4 +23,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -29,4 +29,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -47,6 +47,8 @@ ruma_api! {
|
||||
#[wrap_incoming(Notification)]
|
||||
pub notifications: Vec<Notification>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// Represents a notification
|
||||
|
@ -20,4 +20,6 @@ ruma_api! {
|
||||
/// An array containing the current pushers for the user.
|
||||
pub pushers: Vec<Pusher>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -33,4 +33,6 @@ ruma_api! {
|
||||
#[ruma_api(body)]
|
||||
pub rule: PushRule
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -32,4 +32,6 @@ ruma_api! {
|
||||
/// The actions to perform for this rule.
|
||||
pub actions: Vec<Action>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -32,4 +32,6 @@ ruma_api! {
|
||||
/// Whether the push rule is enabled or not.
|
||||
pub enabled: bool
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -22,4 +22,6 @@ ruma_api! {
|
||||
/// The global ruleset
|
||||
pub global: HashMap<RuleKind, Vec<PushRule>>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -23,4 +23,6 @@ ruma_api! {
|
||||
#[ruma_api(body)]
|
||||
pub global: HashMap<RuleKind, Vec<PushRule>>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -27,4 +27,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -49,4 +49,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -32,4 +32,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -32,4 +32,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -32,4 +32,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -29,6 +29,8 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// The type of receipt.
|
||||
|
@ -34,4 +34,6 @@ ruma_api! {
|
||||
/// The ID of the redacted event.
|
||||
pub event_id: EventId,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -72,6 +72,8 @@ ruma_api! {
|
||||
/// The created room's ID.
|
||||
pub room_id: RoomId,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// Extra options to be added to the `m.room.create` event.
|
||||
|
@ -28,4 +28,6 @@ ruma_api! {
|
||||
#[wrap_incoming(with EventResult)]
|
||||
pub event: all::RoomEvent,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -28,4 +28,6 @@ ruma_api! {
|
||||
}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -25,4 +25,6 @@ ruma_api! {
|
||||
/// ID of the new room.
|
||||
pub replacement_room: RoomId,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -35,6 +35,8 @@ ruma_api! {
|
||||
#[wrap_incoming]
|
||||
pub search_categories: ResultCategories,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// Categories of events that can be searched for.
|
||||
|
@ -29,6 +29,8 @@ ruma_api! {
|
||||
/// A map of the user's device identifiers to information about that device.
|
||||
pub devices: HashMap<String, DeviceInfo>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// Information about a connection in a user session.
|
||||
|
@ -19,6 +19,8 @@ ruma_api! {
|
||||
/// The homeserver's supported login types.
|
||||
pub flows: Vec<LoginType>
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// An authentication mechanism.
|
||||
|
@ -53,6 +53,8 @@ ruma_api! {
|
||||
/// If present, clients SHOULD use the provided object to reconfigure themselves.
|
||||
pub well_known: Option<DiscoveryInfo>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
||||
/// Identification information for the user.
|
||||
|
@ -15,4 +15,6 @@ ruma_api! {
|
||||
request {}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -15,4 +15,6 @@ ruma_api! {
|
||||
request {}
|
||||
|
||||
response {}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -25,4 +25,6 @@ ruma_api! {
|
||||
#[ruma_api(header = LOCATION)]
|
||||
pub location: String,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -31,4 +31,6 @@ ruma_api! {
|
||||
/// A unique identifier for the event.
|
||||
pub event_id: EventId,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -34,4 +34,6 @@ ruma_api! {
|
||||
/// A unique identifier for the event.
|
||||
pub event_id: EventId,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
@ -28,4 +28,6 @@ ruma_api! {
|
||||
#[wrap_incoming(StateEvent with EventResult)]
|
||||
pub room_state: Vec<StateEvent>,
|
||||
}
|
||||
|
||||
error: crate::Error
|
||||
}
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user