federation-api: Use new path metadata fields

This commit is contained in:
Jonas Platte 2022-02-13 11:25:38 +01:00
parent ee99486978
commit c5e396216a
No known key found for this signature in database
GPG Key ID: CC154DE0E30B7C67
33 changed files with 68 additions and 33 deletions

View File

@ -9,9 +9,10 @@ ruma_api! {
description: "Retrieves the complete auth chain for a given event.", description: "Retrieves the complete auth chain for a given event.",
name: "get_event_authorization", name: "get_event_authorization",
method: GET, method: GET,
path: "/_matrix/federation/v1/event_auth/:room_id/:event_id", stable_path: "/_matrix/federation/v1/event_auth/:room_id/:event_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -12,9 +12,10 @@ ruma_api! {
description: "Request more history from another homeserver", description: "Request more history from another homeserver",
name: "get_backfill", name: "get_backfill",
method: GET, method: GET,
path: "/_matrix/federation/v1/backfill/:room_id", stable_path: "/_matrix/federation/v1/backfill/:room_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -12,9 +12,10 @@ ruma_api! {
description: "Gets information on all of the user's devices.", description: "Gets information on all of the user's devices.",
name: "get_devices", name: "get_devices",
method: GET, method: GET,
path: "/_matrix/federation/v1/user/devices/:user_id", stable_path: "/_matrix/federation/v1/user/devices/:user_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -9,9 +9,10 @@ ruma_api! {
description: "Gets all the public rooms for the homeserver.", description: "Gets all the public rooms for the homeserver.",
method: GET, method: GET,
name: "get_public_rooms", name: "get_public_rooms",
path: "/_matrix/federation/v1/publicRooms", stable_path: "/_matrix/federation/v1/publicRooms",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
#[derive(Default)] #[derive(Default)]

View File

@ -11,9 +11,10 @@ ruma_api! {
description: "Get the list of rooms in this homeserver's public directory.", description: "Get the list of rooms in this homeserver's public directory.",
method: POST, method: POST,
name: "get_public_rooms_filtered", name: "get_public_rooms_filtered",
path: "/_matrix/federation/v1/publicRooms", stable_path: "/_matrix/federation/v1/publicRooms",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
#[derive(Default)] #[derive(Default)]

View File

@ -8,9 +8,10 @@ ruma_api! {
description: "Get discovery information about the domain.", description: "Get discovery information about the domain.",
method: GET, method: GET,
name: "discover_homeserver", name: "discover_homeserver",
path: "/.well-known/matrix/server", stable_path: "/.well-known/matrix/server",
rate_limited: false, rate_limited: false,
authentication: None, authentication: None,
added: 1.0,
} }
#[derive(Default)] #[derive(Default)]

View File

@ -13,9 +13,10 @@ ruma_api! {
name: "get_remote_server_keys", name: "get_remote_server_keys",
// Note: The spec has an additional, deprecated path parameter on this. We may want to // Note: The spec has an additional, deprecated path parameter on this. We may want to
// support an additional parameter at the end, even if it is ignored. // support an additional parameter at the end, even if it is ignored.
path: "/_matrix/key/v2/query/:server_name", stable_path: "/_matrix/key/v2/query/:server_name",
rate_limited: false, rate_limited: false,
authentication: None, authentication: None,
added: 1.0,
} }
request: { request: {

View File

@ -14,9 +14,10 @@ ruma_api! {
description: "Query for keys from multiple servers in a batch format.", description: "Query for keys from multiple servers in a batch format.",
method: POST, method: POST,
name: "get_remote_server_keys_batch", name: "get_remote_server_keys_batch",
path: "/_matrix/key/v2/query", stable_path: "/_matrix/key/v2/query",
rate_limited: false, rate_limited: false,
authentication: None, authentication: None,
added: 1.0,
} }
request: { request: {

View File

@ -9,9 +9,10 @@ ruma_api! {
description: "Gets the homeserver's published signing keys.", description: "Gets the homeserver's published signing keys.",
method: GET, method: GET,
name: "get_server_keys", name: "get_server_keys",
path: "/_matrix/key/v2/server", stable_path: "/_matrix/key/v2/server",
rate_limited: false, rate_limited: false,
authentication: None, authentication: None,
added: 1.0,
} }
#[derive(Default)] #[derive(Default)]

View File

@ -8,9 +8,10 @@ ruma_api! {
description: "Get the implementation name and version of this homeserver.", description: "Get the implementation name and version of this homeserver.",
method: GET, method: GET,
name: "get_server_version", name: "get_server_version",
path: "/_matrix/federation/v1/version", stable_path: "/_matrix/federation/v1/version",
rate_limited: false, rate_limited: false,
authentication: None, authentication: None,
added: 1.0,
} }
#[derive(Default)] #[derive(Default)]

View File

@ -11,9 +11,10 @@ ruma_api! {
description: "Retrieves a single event.", description: "Retrieves a single event.",
method: GET, method: GET,
name: "get_event", name: "get_event",
path: "/_matrix/federation/v1/event/:event_id", stable_path: "/_matrix/federation/v1/event/:event_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -11,9 +11,10 @@ ruma_api! {
description: "Retrieves previous events that the sender is missing.", description: "Retrieves previous events that the sender is missing.",
method: POST, method: POST,
name: "get_missing_events", name: "get_missing_events",
path: "/_matrix/federation/v1/get_missing_events/:room_id", stable_path: "/_matrix/federation/v1/get_missing_events/:room_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -10,9 +10,10 @@ ruma_api! {
description: "Retrieves a snapshot of a room's state at a given event.", description: "Retrieves a snapshot of a room's state at a given event.",
method: GET, method: GET,
name: "get_room_state", name: "get_room_state",
path: "/_matrix/federation/v1/state/:room_id", stable_path: "/_matrix/federation/v1/state/:room_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -8,9 +8,10 @@ ruma_api! {
description: "Retrieves a snapshot of a room's state at a given event, in the form of event IDs", description: "Retrieves a snapshot of a room's state at a given event, in the form of event IDs",
method: GET, method: GET,
name: "get_room_state_ids", name: "get_room_state_ids",
path: "/_matrix/federation/v1/state_ids/:room_id", stable_path: "/_matrix/federation/v1/state_ids/:room_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -14,9 +14,10 @@ ruma_api! {
description: "Claims one-time keys for use in pre-key messages.", description: "Claims one-time keys for use in pre-key messages.",
method: POST, method: POST,
name: "claim_keys", name: "claim_keys",
path: "/_matrix/federation/v1/user/keys/claim", stable_path: "/_matrix/federation/v1/user/keys/claim",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -12,9 +12,10 @@ ruma_api! {
description: "Returns the current devices and identity keys for the given users.", description: "Returns the current devices and identity keys for the given users.",
method: POST, method: POST,
name: "get_keys", name: "get_keys",
path: "/_matrix/federation/v1/user/keys/query", stable_path: "/_matrix/federation/v1/user/keys/query",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -9,9 +9,11 @@ ruma_api! {
description: "Send a request for a knock event template to a resident server.", description: "Send a request for a knock event template to a resident server.",
name: "create_knock_event_template", name: "create_knock_event_template",
method: GET, method: GET,
path: "/_matrix/federation/v1/make_knock/:room_id/:user_id", unstable_path: "/_matrix/federation/unstable/xyz.amorgan.knock/make_knock/:room_id/:user_id",
stable_path: "/_matrix/federation/v1/make_knock/:room_id/:user_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.1,
} }
request: { request: {

View File

@ -11,9 +11,11 @@ ruma_api! {
description: "Submits a signed knock event to the resident homeserver for it to accept into the room's graph.", description: "Submits a signed knock event to the resident homeserver for it to accept into the room's graph.",
name: "send_knock", name: "send_knock",
method: PUT, method: PUT,
path: "/_matrix/federation/v1/send_knock/:room_id/:event_id", unstable_path: "/_matrix/federation/unstable/xyz.amorgan.knock/send_knock/:room_id/:event_id",
stable_path: "/_matrix/federation/v1/send_knock/:room_id/:event_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.1,
} }
request: { request: {

View File

@ -13,9 +13,10 @@ ruma_api! {
description: "Invites a remote user to a room.", description: "Invites a remote user to a room.",
method: PUT, method: PUT,
name: "create_invite", name: "create_invite",
path: "/_matrix/federation/v1/invite/:room_id/:event_id", stable_path: "/_matrix/federation/v1/invite/:room_id/:event_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -11,9 +11,10 @@ ruma_api! {
description: "Invites a remote user to a room.", description: "Invites a remote user to a room.",
method: PUT, method: PUT,
name: "create_invite", name: "create_invite",
path: "/_matrix/federation/v2/invite/:room_id/:event_id", stable_path: "/_matrix/federation/v2/invite/:room_id/:event_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -12,9 +12,10 @@ ruma_api! {
description: "Send a join event to a resident server.", description: "Send a join event to a resident server.",
name: "create_join_event", name: "create_join_event",
method: PUT, method: PUT,
path: "/_matrix/federation/v1/send_join/:room_id/:event_id", stable_path: "/_matrix/federation/v1/send_join/:room_id/:event_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -12,9 +12,10 @@ ruma_api! {
description: "Send a join event to a resident server.", description: "Send a join event to a resident server.",
name: "create_join_event", name: "create_join_event",
method: PUT, method: PUT,
path: "/_matrix/federation/v2/send_join/:room_id/:event_id", stable_path: "/_matrix/federation/v2/send_join/:room_id/:event_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -10,9 +10,10 @@ ruma_api! {
description: "Send a request for a join event template to a resident server.", description: "Send a request for a join event template to a resident server.",
name: "create_join_event_template", name: "create_join_event_template",
method: GET, method: GET,
path: "/_matrix/federation/v1/make_join/:room_id/:user_id", stable_path: "/_matrix/federation/v1/make_join/:room_id/:user_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -13,9 +13,10 @@ ruma_api! {
description: "Submits a signed leave event to the receiving server for it to accept it into the room's graph.", description: "Submits a signed leave event to the receiving server for it to accept it into the room's graph.",
name: "create_leave_event", name: "create_leave_event",
method: PUT, method: PUT,
path: "/_matrix/federation/v1/send_leave/:room_id/:event_id", stable_path: "/_matrix/federation/v1/send_leave/:room_id/:event_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -10,9 +10,10 @@ ruma_api! {
description: "Submits a signed leave event to the receiving server for it to accept it into the room's graph.", description: "Submits a signed leave event to the receiving server for it to accept it into the room's graph.",
name: "create_leave_event", name: "create_leave_event",
method: PUT, method: PUT,
path: "/_matrix/federation/v1/send_leave/:room_id/:event_id", stable_path: "/_matrix/federation/v1/send_leave/:room_id/:event_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -10,9 +10,10 @@ ruma_api! {
description: "Asks the receiving server to return information that the sending server will need to prepare a leave event to get out of the room.", description: "Asks the receiving server to return information that the sending server will need to prepare a leave event to get out of the room.",
name: "get_leave_event", name: "get_leave_event",
method: GET, method: GET,
path: "/_matrix/federation/v1/make_leave/:room_id/:user_id", stable_path: "/_matrix/federation/v1/make_leave/:room_id/:user_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -8,9 +8,10 @@ ruma_api! {
description: "Exchanges an OpenID access token for information about the user who generated the token.", description: "Exchanges an OpenID access token for information about the user who generated the token.",
method: GET, method: GET,
name: "get_openid_userinfo", name: "get_openid_userinfo",
path: "/_matrix/federation/v1/openid/userinfo", stable_path: "/_matrix/federation/v1/openid/userinfo",
rate_limited: false, rate_limited: false,
authentication: None, authentication: None,
added: 1.0,
} }
request: { request: {

View File

@ -10,9 +10,10 @@ ruma_api! {
description: "Performs a single query request on the receiving homeserver. The query string arguments are dependent on which type of query is being made.", description: "Performs a single query request on the receiving homeserver. The query string arguments are dependent on which type of query is being made.",
method: GET, method: GET,
name: "get_custom_information", name: "get_custom_information",
path: "/_matrix/federation/v1/query/:query_type", stable_path: "/_matrix/federation/v1/query/:query_type",
rate_limited: false, rate_limited: false,
authentication: AccessToken, authentication: AccessToken,
added: 1.0,
} }
request: { request: {

View File

@ -11,9 +11,10 @@ ruma_api! {
description: "Get profile information, such as a display name or avatar, for a given user.", description: "Get profile information, such as a display name or avatar, for a given user.",
name: "get_profile_information", name: "get_profile_information",
method: GET, method: GET,
path: "/_matrix/federation/v1/query/profile", stable_path: "/_matrix/federation/v1/query/profile",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -8,9 +8,10 @@ ruma_api! {
description: "Get mapped room ID and resident homeservers for a given room alias.", description: "Get mapped room ID and resident homeservers for a given room alias.",
name: "get_room_information", name: "get_room_information",
method: GET, method: GET,
path: "/_matrix/federation/v1/query/directory", stable_path: "/_matrix/federation/v1/query/directory",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {

View File

@ -12,9 +12,10 @@ ruma_api! {
description: "Used by identity servers to notify the homeserver that one of its users has bound a third party identifier successfully", description: "Used by identity servers to notify the homeserver that one of its users has bound a third party identifier successfully",
method: PUT, method: PUT,
name: "bind_callback", name: "bind_callback",
path: "/_matrix/federation/v1/3pid/onbind", stable_path: "/_matrix/federation/v1/3pid/onbind",
rate_limited: false, rate_limited: false,
authentication: None, authentication: None,
added: 1.0,
} }
request: { request: {

View File

@ -9,9 +9,10 @@ ruma_api! {
description: "The receiving server will verify the partial m.room.member event given in the request body.", description: "The receiving server will verify the partial m.room.member event given in the request body.",
method: PUT, method: PUT,
name: "exchange_invite", name: "exchange_invite",
path: "/_matrix/federation/v1/exchange_third_party_invite/:room_id", stable_path: "/_matrix/federation/v1/exchange_third_party_invite/:room_id",
rate_limited: false, rate_limited: false,
authentication: AccessToken, authentication: AccessToken,
added: 1.0,
} }
request: { request: {

View File

@ -15,9 +15,10 @@ ruma_api! {
description: "Send transaction messages to another server", description: "Send transaction messages to another server",
name: "send_transaction_message", name: "send_transaction_message",
method: PUT, method: PUT,
path: "/_matrix/federation/v1/send/:transaction_id", stable_path: "/_matrix/federation/v1/send/:transaction_id",
rate_limited: false, rate_limited: false,
authentication: ServerSignatures, authentication: ServerSignatures,
added: 1.0,
} }
request: { request: {