async-matrix 0.1.3 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +131 -0
- data/data/matrix-spec/api/client-server/account-data.yaml +389 -0
- data/data/matrix-spec/api/client-server/account_deactivation.yaml +149 -0
- data/data/matrix-spec/api/client-server/admin.yaml +512 -0
- data/data/matrix-spec/api/client-server/administrative_contact.yaml +620 -0
- data/data/matrix-spec/api/client-server/appservice_ping.yaml +183 -0
- data/data/matrix-spec/api/client-server/appservice_room_directory.yaml +104 -0
- data/data/matrix-spec/api/client-server/authed-content-repo.yaml +590 -0
- data/data/matrix-spec/api/client-server/banning.yaml +177 -0
- data/data/matrix-spec/api/client-server/capabilities.yaml +235 -0
- data/data/matrix-spec/api/client-server/content-repo.yaml +887 -0
- data/data/matrix-spec/api/client-server/create_room.yaml +306 -0
- data/data/matrix-spec/api/client-server/cross_signing.yaml +300 -0
- data/data/matrix-spec/api/client-server/definitions/auth_data.yaml +34 -0
- data/data/matrix-spec/api/client-server/definitions/auth_response.yaml +62 -0
- data/data/matrix-spec/api/client-server/definitions/client_device.yaml +44 -0
- data/data/matrix-spec/api/client-server/definitions/client_event.yaml +49 -0
- data/data/matrix-spec/api/client-server/definitions/client_event_without_room_id.yaml +147 -0
- data/data/matrix-spec/api/client-server/definitions/cross_signing_key.yaml +57 -0
- data/data/matrix-spec/api/client-server/definitions/device_keys.yaml +70 -0
- data/data/matrix-spec/api/client-server/definitions/errors/error.yaml +26 -0
- data/data/matrix-spec/api/client-server/definitions/errors/rate_limited.yaml +34 -0
- data/data/matrix-spec/api/client-server/definitions/event_batch.yaml +22 -0
- data/data/matrix-spec/api/client-server/definitions/event_filter.yaml +55 -0
- data/data/matrix-spec/api/client-server/definitions/invite_3pid.yaml +45 -0
- data/data/matrix-spec/api/client-server/definitions/key_backup_auth_data.yaml +36 -0
- data/data/matrix-spec/api/client-server/definitions/key_backup_data.yaml +50 -0
- data/data/matrix-spec/api/client-server/definitions/key_backup_session_data.yaml +57 -0
- data/data/matrix-spec/api/client-server/definitions/m.login.terms_params.yaml +83 -0
- data/data/matrix-spec/api/client-server/definitions/m.mentions.yaml +33 -0
- data/data/matrix-spec/api/client-server/definitions/m.oauth_params.yaml +30 -0
- data/data/matrix-spec/api/client-server/definitions/m.relates_to.yaml +45 -0
- data/data/matrix-spec/api/client-server/definitions/megolm_export_session_data.yaml +39 -0
- data/data/matrix-spec/api/client-server/definitions/olm_payload.yaml +88 -0
- data/data/matrix-spec/api/client-server/definitions/one_time_keys.yaml +27 -0
- data/data/matrix-spec/api/client-server/definitions/openid_token.yaml +37 -0
- data/data/matrix-spec/api/client-server/definitions/protocol.yaml +44 -0
- data/data/matrix-spec/api/client-server/definitions/public_rooms_chunk.yaml +74 -0
- data/data/matrix-spec/api/client-server/definitions/public_rooms_response.yaml +59 -0
- data/data/matrix-spec/api/client-server/definitions/push_condition.yaml +53 -0
- data/data/matrix-spec/api/client-server/definitions/push_rule.yaml +53 -0
- data/data/matrix-spec/api/client-server/definitions/push_ruleset.yaml +206 -0
- data/data/matrix-spec/api/client-server/definitions/recent_emoji.yaml +29 -0
- data/data/matrix-spec/api/client-server/definitions/request_email_validation.yaml +36 -0
- data/data/matrix-spec/api/client-server/definitions/request_msisdn_validation.yaml +36 -0
- data/data/matrix-spec/api/client-server/definitions/request_token_response.yaml +46 -0
- data/data/matrix-spec/api/client-server/definitions/room_event_filter.yaml +60 -0
- data/data/matrix-spec/api/client-server/definitions/room_key_backup.yaml +37 -0
- data/data/matrix-spec/api/client-server/definitions/room_summary.yaml +44 -0
- data/data/matrix-spec/api/client-server/definitions/security.yaml +47 -0
- data/data/matrix-spec/api/client-server/definitions/sso_login_flow.yaml +98 -0
- data/data/matrix-spec/api/client-server/definitions/state_event_batch.yaml +21 -0
- data/data/matrix-spec/api/client-server/definitions/sync_filter.yaml +86 -0
- data/data/matrix-spec/api/client-server/definitions/tag.yaml +24 -0
- data/data/matrix-spec/api/client-server/definitions/third_party_signed.yaml +45 -0
- data/data/matrix-spec/api/client-server/definitions/timeline_batch.yaml +36 -0
- data/data/matrix-spec/api/client-server/definitions/user_identifier.yaml +27 -0
- data/data/matrix-spec/api/client-server/definitions/wellknown/full.yaml +38 -0
- data/data/matrix-spec/api/client-server/definitions/wellknown/homeserver.yaml +25 -0
- data/data/matrix-spec/api/client-server/definitions/wellknown/identity_server.yaml +25 -0
- data/data/matrix-spec/api/client-server/device_management.yaml +314 -0
- data/data/matrix-spec/api/client-server/directory.yaml +318 -0
- data/data/matrix-spec/api/client-server/event_context.yaml +161 -0
- data/data/matrix-spec/api/client-server/filter.yaml +224 -0
- data/data/matrix-spec/api/client-server/inviting.yaml +149 -0
- data/data/matrix-spec/api/client-server/joining.yaml +238 -0
- data/data/matrix-spec/api/client-server/key_backup.yaml +993 -0
- data/data/matrix-spec/api/client-server/keys.yaml +482 -0
- data/data/matrix-spec/api/client-server/kicking.yaml +110 -0
- data/data/matrix-spec/api/client-server/knocking.yaml +152 -0
- data/data/matrix-spec/api/client-server/leaving.yaml +163 -0
- data/data/matrix-spec/api/client-server/list_joined_rooms.yaml +68 -0
- data/data/matrix-spec/api/client-server/list_public_rooms.yaml +280 -0
- data/data/matrix-spec/api/client-server/login.yaml +321 -0
- data/data/matrix-spec/api/client-server/login_token.yaml +138 -0
- data/data/matrix-spec/api/client-server/logout.yaml +86 -0
- data/data/matrix-spec/api/client-server/message_pagination.yaml +194 -0
- data/data/matrix-spec/api/client-server/notifications.yaml +152 -0
- data/data/matrix-spec/api/client-server/oauth_server_metadata.yaml +238 -0
- data/data/matrix-spec/api/client-server/old_sync.yaml +379 -0
- data/data/matrix-spec/api/client-server/openid.yaml +98 -0
- data/data/matrix-spec/api/client-server/password_management.yaml +246 -0
- data/data/matrix-spec/api/client-server/peeking_events.yaml +122 -0
- data/data/matrix-spec/api/client-server/policy_server.yaml +82 -0
- data/data/matrix-spec/api/client-server/presence.yaml +169 -0
- data/data/matrix-spec/api/client-server/profile.yaml +366 -0
- data/data/matrix-spec/api/client-server/pusher.yaml +303 -0
- data/data/matrix-spec/api/client-server/pushrules.yaml +633 -0
- data/data/matrix-spec/api/client-server/read_markers.yaml +103 -0
- data/data/matrix-spec/api/client-server/receipts.yaml +139 -0
- data/data/matrix-spec/api/client-server/redaction.yaml +116 -0
- data/data/matrix-spec/api/client-server/refresh.yaml +119 -0
- data/data/matrix-spec/api/client-server/registration.yaml +488 -0
- data/data/matrix-spec/api/client-server/registration_tokens.yaml +93 -0
- data/data/matrix-spec/api/client-server/relations.yaml +382 -0
- data/data/matrix-spec/api/client-server/report_content.yaml +283 -0
- data/data/matrix-spec/api/client-server/room_event_by_timestamp.yaml +147 -0
- data/data/matrix-spec/api/client-server/room_initial_sync.yaml +188 -0
- data/data/matrix-spec/api/client-server/room_send.yaml +130 -0
- data/data/matrix-spec/api/client-server/room_state.yaml +159 -0
- data/data/matrix-spec/api/client-server/room_summary.yaml +138 -0
- data/data/matrix-spec/api/client-server/room_upgrades.yaml +130 -0
- data/data/matrix-spec/api/client-server/rooms.yaml +380 -0
- data/data/matrix-spec/api/client-server/search.yaml +385 -0
- data/data/matrix-spec/api/client-server/space_hierarchy.yaml +237 -0
- data/data/matrix-spec/api/client-server/sso_login_redirect.yaml +135 -0
- data/data/matrix-spec/api/client-server/support.yaml +142 -0
- data/data/matrix-spec/api/client-server/sync.yaml +692 -0
- data/data/matrix-spec/api/client-server/tags.yaml +183 -0
- data/data/matrix-spec/api/client-server/third_party_lookup.yaml +324 -0
- data/data/matrix-spec/api/client-server/third_party_membership.yaml +139 -0
- data/data/matrix-spec/api/client-server/threads_list.yaml +167 -0
- data/data/matrix-spec/api/client-server/to_device.yaml +104 -0
- data/data/matrix-spec/api/client-server/typing.yaml +103 -0
- data/data/matrix-spec/api/client-server/users.yaml +136 -0
- data/data/matrix-spec/api/client-server/versions.yaml +108 -0
- data/data/matrix-spec/api/client-server/voip.yaml +93 -0
- data/data/matrix-spec/api/client-server/wellknown.yaml +60 -0
- data/data/matrix-spec/api/client-server/whoami.yaml +121 -0
- data/data/matrix-spec/event-schemas/examples/core/event.json +6 -0
- data/data/matrix-spec/event-schemas/examples/core/room_edu.json +3 -0
- data/data/matrix-spec/event-schemas/examples/core/room_event.json +11 -0
- data/data/matrix-spec/event-schemas/examples/core/state_event.json +4 -0
- data/data/matrix-spec/event-schemas/examples/invite_room_state.json +18 -0
- data/data/matrix-spec/event-schemas/examples/knock_room_state.json +18 -0
- data/data/matrix-spec/event-schemas/examples/m.accepted_terms.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.call.answer.yaml +21 -0
- data/data/matrix-spec/event-schemas/examples/m.call.candidates.yaml +16 -0
- data/data/matrix-spec/event-schemas/examples/m.call.hangup.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.call.invite.yaml +22 -0
- data/data/matrix-spec/event-schemas/examples/m.call.negotiate.yaml +22 -0
- data/data/matrix-spec/event-schemas/examples/m.call.reject.yaml +9 -0
- data/data/matrix-spec/event-schemas/examples/m.call.sdp_stream_metadata_changed.yaml +16 -0
- data/data/matrix-spec/event-schemas/examples/m.call.select_answer.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.direct.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.dummy.yaml +4 -0
- data/data/matrix-spec/event-schemas/examples/m.forwarded_room_key.yaml +14 -0
- data/data/matrix-spec/event-schemas/examples/m.fully_read.yaml +7 -0
- data/data/matrix-spec/event-schemas/examples/m.identity_server.yaml +7 -0
- data/data/matrix-spec/event-schemas/examples/m.ignored_user_list.yaml +9 -0
- data/data/matrix-spec/event-schemas/examples/m.invite_permission_config.yaml +7 -0
- data/data/matrix-spec/event-schemas/examples/m.key.verification.accept.yaml +12 -0
- data/data/matrix-spec/event-schemas/examples/m.key.verification.cancel.yaml +8 -0
- data/data/matrix-spec/event-schemas/examples/m.key.verification.done.yaml +6 -0
- data/data/matrix-spec/event-schemas/examples/m.key.verification.key.yaml +7 -0
- data/data/matrix-spec/event-schemas/examples/m.key.verification.mac.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.key.verification.ready.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.key.verification.request.yaml +11 -0
- data/data/matrix-spec/event-schemas/examples/m.key.verification.start$m.sas.v1.yaml +12 -0
- data/data/matrix-spec/event-schemas/examples/m.key.verification.start.yaml +8 -0
- data/data/matrix-spec/event-schemas/examples/m.key_backup.yaml +7 -0
- data/data/matrix-spec/event-schemas/examples/m.marked_unread.yaml +7 -0
- data/data/matrix-spec/event-schemas/examples/m.policy.rule.room.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.policy.rule.server.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.policy.rule.user.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.presence.yaml +12 -0
- data/data/matrix-spec/event-schemas/examples/m.push_rules.yaml +177 -0
- data/data/matrix-spec/event-schemas/examples/m.reaction.yaml +11 -0
- data/data/matrix-spec/event-schemas/examples/m.receipt.yaml +18 -0
- data/data/matrix-spec/event-schemas/examples/m.recent_emoji.yaml +16 -0
- data/data/matrix-spec/event-schemas/examples/m.room.avatar.yaml +14 -0
- data/data/matrix-spec/event-schemas/examples/m.room.canonical_alias.yaml +12 -0
- data/data/matrix-spec/event-schemas/examples/m.room.create.yaml +13 -0
- data/data/matrix-spec/event-schemas/examples/m.room.encrypted$megolm.yaml +11 -0
- data/data/matrix-spec/event-schemas/examples/m.room.encrypted$olm.yaml +14 -0
- data/data/matrix-spec/event-schemas/examples/m.room.encryption.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.room.guest_access.yaml +8 -0
- data/data/matrix-spec/event-schemas/examples/m.room.history_visibility.yaml +8 -0
- data/data/matrix-spec/event-schemas/examples/m.room.join_rules$restricted.yaml +18 -0
- data/data/matrix-spec/event-schemas/examples/m.room.join_rules.yaml +8 -0
- data/data/matrix-spec/event-schemas/examples/m.room.member$invite_room_state.yaml +15 -0
- data/data/matrix-spec/event-schemas/examples/m.room.member$join_authorised_via_users_server.yaml +12 -0
- data/data/matrix-spec/event-schemas/examples/m.room.member$knock_room_state.yaml +15 -0
- data/data/matrix-spec/event-schemas/examples/m.room.member$third_party_invite.yaml +20 -0
- data/data/matrix-spec/event-schemas/examples/m.room.member.yaml +12 -0
- data/data/matrix-spec/event-schemas/examples/m.room.message$m.audio.yaml +14 -0
- data/data/matrix-spec/event-schemas/examples/m.room.message$m.emote.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.room.message$m.file.yaml +14 -0
- data/data/matrix-spec/event-schemas/examples/m.room.message$m.image.yaml +16 -0
- data/data/matrix-spec/event-schemas/examples/m.room.message$m.key.verification.request.yaml +19 -0
- data/data/matrix-spec/event-schemas/examples/m.room.message$m.location.yaml +18 -0
- data/data/matrix-spec/event-schemas/examples/m.room.message$m.notice.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.room.message$m.server_notice.yaml +11 -0
- data/data/matrix-spec/event-schemas/examples/m.room.message$m.text.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.room.message$m.video.yaml +23 -0
- data/data/matrix-spec/event-schemas/examples/m.room.name.yaml +8 -0
- data/data/matrix-spec/event-schemas/examples/m.room.pinned_events.yaml +8 -0
- data/data/matrix-spec/event-schemas/examples/m.room.policy.yaml +11 -0
- data/data/matrix-spec/event-schemas/examples/m.room.power_levels.yaml +24 -0
- data/data/matrix-spec/event-schemas/examples/m.room.redaction.yaml +8 -0
- data/data/matrix-spec/event-schemas/examples/m.room.server_acl.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.room.third_party_invite.yaml +14 -0
- data/data/matrix-spec/event-schemas/examples/m.room.tombstone.yaml +9 -0
- data/data/matrix-spec/event-schemas/examples/m.room.topic.yaml +16 -0
- data/data/matrix-spec/event-schemas/examples/m.room_key.withheld.yaml +12 -0
- data/data/matrix-spec/event-schemas/examples/m.room_key.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.room_key_request$cancel_request.yaml +8 -0
- data/data/matrix-spec/event-schemas/examples/m.room_key_request$request.yaml +14 -0
- data/data/matrix-spec/event-schemas/examples/m.secret.request.yaml +9 -0
- data/data/matrix-spec/event-schemas/examples/m.secret.send.yaml +7 -0
- data/data/matrix-spec/event-schemas/examples/m.space.child.yaml +10 -0
- data/data/matrix-spec/event-schemas/examples/m.space.parent.yaml +9 -0
- data/data/matrix-spec/event-schemas/examples/m.sticker.yaml +22 -0
- data/data/matrix-spec/event-schemas/examples/m.tag.yaml +9 -0
- data/data/matrix-spec/event-schemas/examples/m.typing.yaml +7 -0
- data/data/matrix-spec/event-schemas/moderation_policy_rule.yaml +32 -0
- data/data/matrix-spec/event-schemas/schema/components/m_text_content_block.yaml +28 -0
- data/data/matrix-spec/event-schemas/schema/components/sdp_stream_metadata.yaml +43 -0
- data/data/matrix-spec/event-schemas/schema/components/signed_third_party_invite.yaml +48 -0
- data/data/matrix-spec/event-schemas/schema/core-event-schema/call_event.yaml +27 -0
- data/data/matrix-spec/event-schemas/schema/core-event-schema/event.yaml +16 -0
- data/data/matrix-spec/event-schemas/schema/core-event-schema/msgtype_infos/avatar_info.yaml +30 -0
- data/data/matrix-spec/event-schemas/schema/core-event-schema/msgtype_infos/image_info.yaml +52 -0
- data/data/matrix-spec/event-schemas/schema/core-event-schema/msgtype_infos/thumbnail_info.yaml +22 -0
- data/data/matrix-spec/event-schemas/schema/core-event-schema/room_event.yaml +17 -0
- data/data/matrix-spec/event-schemas/schema/core-event-schema/state_event.yaml +8 -0
- data/data/matrix-spec/event-schemas/schema/core-event-schema/stripped_state.yaml +48 -0
- data/data/matrix-spec/event-schemas/schema/core-event-schema/sync_room_event.yaml +49 -0
- data/data/matrix-spec/event-schemas/schema/core-event-schema/sync_state_event.yaml +36 -0
- data/data/matrix-spec/event-schemas/schema/core-event-schema/unsigned_prop.yaml +23 -0
- data/data/matrix-spec/event-schemas/schema/m.accepted_terms.yaml +25 -0
- data/data/matrix-spec/event-schemas/schema/m.call.answer.yaml +44 -0
- data/data/matrix-spec/event-schemas/schema/m.call.candidates.yaml +52 -0
- data/data/matrix-spec/event-schemas/schema/m.call.hangup.yaml +57 -0
- data/data/matrix-spec/event-schemas/schema/m.call.invite.yaml +53 -0
- data/data/matrix-spec/event-schemas/schema/m.call.negotiate.yaml +78 -0
- data/data/matrix-spec/event-schemas/schema/m.call.reject.yaml +29 -0
- data/data/matrix-spec/event-schemas/schema/m.call.sdp_stream_metadata_changed.yaml +24 -0
- data/data/matrix-spec/event-schemas/schema/m.call.select_answer.yaml +29 -0
- data/data/matrix-spec/event-schemas/schema/m.direct.yaml +29 -0
- data/data/matrix-spec/event-schemas/schema/m.dummy.yaml +25 -0
- data/data/matrix-spec/event-schemas/schema/m.forwarded_room_key.yaml +70 -0
- data/data/matrix-spec/event-schemas/schema/m.fully_read.yaml +26 -0
- data/data/matrix-spec/event-schemas/schema/m.identity_server.yaml +28 -0
- data/data/matrix-spec/event-schemas/schema/m.ignored_user_list.yaml +30 -0
- data/data/matrix-spec/event-schemas/schema/m.invite_permission_config.yaml +21 -0
- data/data/matrix-spec/event-schemas/schema/m.key.verification.accept.yaml +63 -0
- data/data/matrix-spec/event-schemas/schema/m.key.verification.cancel.yaml +72 -0
- data/data/matrix-spec/event-schemas/schema/m.key.verification.done.yaml +24 -0
- data/data/matrix-spec/event-schemas/schema/m.key.verification.key.yaml +31 -0
- data/data/matrix-spec/event-schemas/schema/m.key.verification.m.relates_to.yaml +23 -0
- data/data/matrix-spec/event-schemas/schema/m.key.verification.mac.yaml +43 -0
- data/data/matrix-spec/event-schemas/schema/m.key.verification.ready.yaml +41 -0
- data/data/matrix-spec/event-schemas/schema/m.key.verification.request.yaml +47 -0
- data/data/matrix-spec/event-schemas/schema/m.key.verification.start$m.reciprocate.v1.yaml +45 -0
- data/data/matrix-spec/event-schemas/schema/m.key.verification.start$m.sas.v1.yaml +76 -0
- data/data/matrix-spec/event-schemas/schema/m.key.verification.start.yaml +46 -0
- data/data/matrix-spec/event-schemas/schema/m.key_backup.yaml +24 -0
- data/data/matrix-spec/event-schemas/schema/m.marked_unread.yaml +26 -0
- data/data/matrix-spec/event-schemas/schema/m.policy.rule.room.yaml +17 -0
- data/data/matrix-spec/event-schemas/schema/m.policy.rule.server.yaml +17 -0
- data/data/matrix-spec/event-schemas/schema/m.policy.rule.user.yaml +17 -0
- data/data/matrix-spec/event-schemas/schema/m.presence.yaml +50 -0
- data/data/matrix-spec/event-schemas/schema/m.push_rules.yaml +23 -0
- data/data/matrix-spec/event-schemas/schema/m.reaction.yaml +45 -0
- data/data/matrix-spec/event-schemas/schema/m.receipt.yaml +65 -0
- data/data/matrix-spec/event-schemas/schema/m.recent_emoji.yaml +29 -0
- data/data/matrix-spec/event-schemas/schema/m.room.avatar.yaml +29 -0
- data/data/matrix-spec/event-schemas/schema/m.room.canonical_alias.yaml +40 -0
- data/data/matrix-spec/event-schemas/schema/m.room.create.yaml +86 -0
- data/data/matrix-spec/event-schemas/schema/m.room.encrypted.yaml +91 -0
- data/data/matrix-spec/event-schemas/schema/m.room.encryption.yaml +38 -0
- data/data/matrix-spec/event-schemas/schema/m.room.guest_access.yaml +28 -0
- data/data/matrix-spec/event-schemas/schema/m.room.history_visibility.yaml +30 -0
- data/data/matrix-spec/event-schemas/schema/m.room.join_rules.yaml +78 -0
- data/data/matrix-spec/event-schemas/schema/m.room.member.yaml +174 -0
- data/data/matrix-spec/event-schemas/schema/m.room.message$m.audio.yaml +73 -0
- data/data/matrix-spec/event-schemas/schema/m.room.message$m.emote.yaml +36 -0
- data/data/matrix-spec/event-schemas/schema/m.room.message$m.file.yaml +85 -0
- data/data/matrix-spec/event-schemas/schema/m.room.message$m.image.yaml +63 -0
- data/data/matrix-spec/event-schemas/schema/m.room.message$m.key.verification.request.yaml +70 -0
- data/data/matrix-spec/event-schemas/schema/m.room.message$m.location.yaml +50 -0
- data/data/matrix-spec/event-schemas/schema/m.room.message$m.notice.yaml +36 -0
- data/data/matrix-spec/event-schemas/schema/m.room.message$m.server_notice.yaml +41 -0
- data/data/matrix-spec/event-schemas/schema/m.room.message$m.text.yaml +36 -0
- data/data/matrix-spec/event-schemas/schema/m.room.message$m.video.yaml +95 -0
- data/data/matrix-spec/event-schemas/schema/m.room.message.yaml +25 -0
- data/data/matrix-spec/event-schemas/schema/m.room.name.yaml +35 -0
- data/data/matrix-spec/event-schemas/schema/m.room.pinned_events.yaml +27 -0
- data/data/matrix-spec/event-schemas/schema/m.room.policy.yaml +41 -0
- data/data/matrix-spec/event-schemas/schema/m.room.power_levels.yaml +139 -0
- data/data/matrix-spec/event-schemas/schema/m.room.redaction.yaml +29 -0
- data/data/matrix-spec/event-schemas/schema/m.room.server_acl.yaml +88 -0
- data/data/matrix-spec/event-schemas/schema/m.room.third_party_invite.yaml +79 -0
- data/data/matrix-spec/event-schemas/schema/m.room.tombstone.yaml +29 -0
- data/data/matrix-spec/event-schemas/schema/m.room.topic.yaml +53 -0
- data/data/matrix-spec/event-schemas/schema/m.room_key.withheld.yaml +88 -0
- data/data/matrix-spec/event-schemas/schema/m.room_key.yaml +38 -0
- data/data/matrix-spec/event-schemas/schema/m.room_key_request.yaml +73 -0
- data/data/matrix-spec/event-schemas/schema/m.secret.request.yaml +42 -0
- data/data/matrix-spec/event-schemas/schema/m.secret.send.yaml +35 -0
- data/data/matrix-spec/event-schemas/schema/m.space.child.yaml +50 -0
- data/data/matrix-spec/event-schemas/schema/m.space.parent.yaml +36 -0
- data/data/matrix-spec/event-schemas/schema/m.sticker.yaml +36 -0
- data/data/matrix-spec/event-schemas/schema/m.tag.yaml +28 -0
- data/data/matrix-spec/event-schemas/schema/m.typing.yaml +29 -0
- data/lib/async/matrix/api/chain.rb +575 -0
- data/lib/async/matrix/api/concat.rb +105 -0
- data/lib/async/matrix/api/path_tree.rb +208 -0
- data/lib/async/matrix/api.rb +204 -0
- data/lib/async/matrix/application_service/bot.rb +235 -0
- data/lib/async/matrix/application_service/config/schema/analytics.json +21 -0
- data/lib/async/matrix/application_service/config/schema/appservice.json +82 -0
- data/lib/async/matrix/application_service/config/schema/backfill.json +91 -0
- data/lib/async/matrix/application_service/config/schema/bridge.json +209 -0
- data/lib/async/matrix/application_service/config/schema/config.json +61 -0
- data/lib/async/matrix/application_service/config/schema/database.json +38 -0
- data/lib/async/matrix/application_service/config/schema/direct_media.json +35 -0
- data/lib/async/matrix/application_service/config/schema/double_puppet.json +24 -0
- data/lib/async/matrix/application_service/config/schema/encryption.json +164 -0
- data/lib/async/matrix/application_service/config/schema/homeserver.json +58 -0
- data/lib/async/matrix/application_service/config/schema/logging.json +50 -0
- data/lib/async/matrix/application_service/config/schema/management_room_texts.json +25 -0
- data/lib/async/matrix/application_service/config/schema/matrix.json +45 -0
- data/lib/async/matrix/application_service/config/schema/permissions.json +54 -0
- data/lib/async/matrix/application_service/config/schema/provisioning.json +23 -0
- data/lib/async/matrix/application_service/config/schema/public_media.json +39 -0
- data/lib/async/matrix/application_service/config/schema/relay.json +43 -0
- data/lib/async/matrix/application_service/config/vivify.rb +110 -0
- data/lib/async/matrix/application_service/config.rb +214 -123
- data/lib/async/matrix/application_service/dispatcher.rb +115 -113
- data/lib/async/matrix/application_service/error_response.rb +26 -26
- data/lib/async/matrix/application_service/event.rb +217 -1
- data/lib/async/matrix/application_service/server.rb +286 -215
- data/lib/async/matrix/application_service/transaction.rb +52 -52
- data/lib/async/matrix/application_service/transaction_store.rb +62 -62
- data/lib/async/matrix/client.rb +919 -179
- data/lib/async/matrix/connection.rb +8 -8
- data/lib/async/matrix/endpoint.rb +45 -45
- data/lib/async/matrix/error.rb +49 -43
- data/lib/async/matrix/media_client.rb +173 -0
- data/lib/async/matrix/notifier.rb +92 -92
- data/lib/async/matrix/schema/registry.rb +355 -0
- data/lib/async/matrix/schema/validation_error.rb +226 -0
- data/lib/async/matrix/schema.rb +174 -0
- data/lib/async/matrix/server.rb +7 -7
- data/lib/async/matrix/stream.rb +7 -7
- data/lib/async/matrix/version.rb +1 -1
- data/lib/async/matrix.rb +2 -2
- metadata +353 -1
|
@@ -0,0 +1,314 @@
|
|
|
1
|
+
# Copyright 2016 OpenMarket Ltd
|
|
2
|
+
#
|
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
# you may not use this file except in compliance with the License.
|
|
5
|
+
# You may obtain a copy of the License at
|
|
6
|
+
#
|
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
#
|
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
# See the License for the specific language governing permissions and
|
|
13
|
+
# limitations under the License.
|
|
14
|
+
openapi: 3.1.0
|
|
15
|
+
info:
|
|
16
|
+
title: Matrix Client-Server device management API
|
|
17
|
+
version: 1.0.0
|
|
18
|
+
paths:
|
|
19
|
+
/devices:
|
|
20
|
+
get:
|
|
21
|
+
summary: List registered devices for the current user
|
|
22
|
+
description: Gets information about all devices for the current user.
|
|
23
|
+
operationId: getDevices
|
|
24
|
+
security:
|
|
25
|
+
- accessTokenQuery: []
|
|
26
|
+
- accessTokenBearer: []
|
|
27
|
+
responses:
|
|
28
|
+
"200":
|
|
29
|
+
description: Device information
|
|
30
|
+
content:
|
|
31
|
+
application/json:
|
|
32
|
+
schema:
|
|
33
|
+
type: object
|
|
34
|
+
properties:
|
|
35
|
+
devices:
|
|
36
|
+
type: array
|
|
37
|
+
description: A list of all registered devices for this user.
|
|
38
|
+
items:
|
|
39
|
+
$ref: definitions/client_device.yaml
|
|
40
|
+
examples:
|
|
41
|
+
response:
|
|
42
|
+
value: {
|
|
43
|
+
"devices": [
|
|
44
|
+
{
|
|
45
|
+
"device_id": "QBUAZIFURK",
|
|
46
|
+
"display_name": "android",
|
|
47
|
+
"last_seen_ip": "1.2.3.4",
|
|
48
|
+
"last_seen_ts": 1474491775024
|
|
49
|
+
}
|
|
50
|
+
]
|
|
51
|
+
}
|
|
52
|
+
tags:
|
|
53
|
+
- Device management
|
|
54
|
+
"/devices/{deviceId}":
|
|
55
|
+
get:
|
|
56
|
+
summary: Get a single device
|
|
57
|
+
description: Gets information on a single device, by device id.
|
|
58
|
+
operationId: getDevice
|
|
59
|
+
security:
|
|
60
|
+
- accessTokenQuery: []
|
|
61
|
+
- accessTokenBearer: []
|
|
62
|
+
parameters:
|
|
63
|
+
- in: path
|
|
64
|
+
name: deviceId
|
|
65
|
+
description: The device to retrieve.
|
|
66
|
+
required: true
|
|
67
|
+
example: QBUAZIFURK
|
|
68
|
+
schema:
|
|
69
|
+
type: string
|
|
70
|
+
responses:
|
|
71
|
+
"200":
|
|
72
|
+
description: Device information
|
|
73
|
+
content:
|
|
74
|
+
application/json:
|
|
75
|
+
schema:
|
|
76
|
+
$ref: definitions/client_device.yaml
|
|
77
|
+
examples:
|
|
78
|
+
response:
|
|
79
|
+
value: {
|
|
80
|
+
"device_id": "QBUAZIFURK",
|
|
81
|
+
"display_name": "android",
|
|
82
|
+
"last_seen_ip": "1.2.3.4",
|
|
83
|
+
"last_seen_ts": 1474491775024
|
|
84
|
+
}
|
|
85
|
+
"404":
|
|
86
|
+
description: The current user has no device with the given ID.
|
|
87
|
+
tags:
|
|
88
|
+
- Device management
|
|
89
|
+
put:
|
|
90
|
+
summary: Create or update a device
|
|
91
|
+
x-changedInMatrixVersion:
|
|
92
|
+
"1.17": The ability to create new devices was added.
|
|
93
|
+
description: |-
|
|
94
|
+
Updates the metadata on the given device, or creates a new device.
|
|
95
|
+
|
|
96
|
+
The ability to create new devices is only available to application
|
|
97
|
+
services: regular clients may only update existing devices.
|
|
98
|
+
|
|
99
|
+
When a new device was created, the homeserver MUST return a 201 HTTP
|
|
100
|
+
status code. It MUST return a 200 HTTP status code if a device was
|
|
101
|
+
updated.
|
|
102
|
+
|
|
103
|
+
This endpoint is rate-limited for device creation. Servers MAY use login
|
|
104
|
+
rate limits.
|
|
105
|
+
operationId: updateDevice
|
|
106
|
+
security:
|
|
107
|
+
- accessTokenQuery: []
|
|
108
|
+
- accessTokenBearer: []
|
|
109
|
+
parameters:
|
|
110
|
+
- in: path
|
|
111
|
+
name: deviceId
|
|
112
|
+
description: The device to update.
|
|
113
|
+
required: true
|
|
114
|
+
example: QBUAZIFURK
|
|
115
|
+
schema:
|
|
116
|
+
type: string
|
|
117
|
+
requestBody:
|
|
118
|
+
content:
|
|
119
|
+
application/json:
|
|
120
|
+
schema:
|
|
121
|
+
type: object
|
|
122
|
+
properties:
|
|
123
|
+
display_name:
|
|
124
|
+
type: string
|
|
125
|
+
description: |-
|
|
126
|
+
The new display name for this device. If not given, the
|
|
127
|
+
display name is unchanged.
|
|
128
|
+
example: {
|
|
129
|
+
"display_name": "My other phone"
|
|
130
|
+
}
|
|
131
|
+
description: New information for the device.
|
|
132
|
+
required: true
|
|
133
|
+
responses:
|
|
134
|
+
"200":
|
|
135
|
+
description: The device was successfully updated.
|
|
136
|
+
content:
|
|
137
|
+
application/json:
|
|
138
|
+
schema:
|
|
139
|
+
type: object # empty json object
|
|
140
|
+
examples:
|
|
141
|
+
response:
|
|
142
|
+
value: {}
|
|
143
|
+
"201":
|
|
144
|
+
description: |-
|
|
145
|
+
The device was successfully created by the application service.
|
|
146
|
+
content:
|
|
147
|
+
application/json:
|
|
148
|
+
schema:
|
|
149
|
+
type: object
|
|
150
|
+
examples:
|
|
151
|
+
response:
|
|
152
|
+
value: {}
|
|
153
|
+
"404":
|
|
154
|
+
description: The current user has no device with the given ID.
|
|
155
|
+
tags:
|
|
156
|
+
- Device management
|
|
157
|
+
delete:
|
|
158
|
+
summary: Delete a device
|
|
159
|
+
x-changedInMatrixVersion:
|
|
160
|
+
"1.17": |-
|
|
161
|
+
This endpoint no longer requires User-Interactive Authentication when used by an
|
|
162
|
+
application service.
|
|
163
|
+
description: |-
|
|
164
|
+
This API endpoint uses the [User-Interactive Authentication API](/client-server-api/#user-interactive-authentication-api),
|
|
165
|
+
except when used by an application service.
|
|
166
|
+
|
|
167
|
+
Deletes the given device, and invalidates any access token associated with it.
|
|
168
|
+
|
|
169
|
+
{{% boxes/warning %}}
|
|
170
|
+
When this endpoint requires User-Interactive Authentication, it cannot be used when the access token was obtained
|
|
171
|
+
via the [OAuth 2.0 API](/client-server-api/#oauth-20-api).
|
|
172
|
+
{{% /boxes/warning %}}
|
|
173
|
+
|
|
174
|
+
{{% boxes/warning %}}
|
|
175
|
+
{{% added-in v="1.18" %}} [OAuth 2.0 aware clients](/client-server-api/#oauth-20-aware-clients)
|
|
176
|
+
MUST NOT use this endpoint when the server supports the [OAuth 2.0 API](/client-server-api/#oauth-20-api).
|
|
177
|
+
Instead they MUST refer the user to the [account management URL](/client-server-api/#oauth-20-account-management),
|
|
178
|
+
if available, with the `action=org.matrix.device_delete` and `device_id={deviceId}` parameters.
|
|
179
|
+
{{% /boxes/warning %}}
|
|
180
|
+
operationId: deleteDevice
|
|
181
|
+
security:
|
|
182
|
+
- accessTokenQuery: []
|
|
183
|
+
- accessTokenBearer: []
|
|
184
|
+
parameters:
|
|
185
|
+
- in: path
|
|
186
|
+
name: deviceId
|
|
187
|
+
description: The device to delete.
|
|
188
|
+
required: true
|
|
189
|
+
example: QBUAZIFURK
|
|
190
|
+
schema:
|
|
191
|
+
type: string
|
|
192
|
+
requestBody:
|
|
193
|
+
content:
|
|
194
|
+
application/json:
|
|
195
|
+
schema:
|
|
196
|
+
type: object
|
|
197
|
+
properties:
|
|
198
|
+
auth:
|
|
199
|
+
description: |-
|
|
200
|
+
Additional authentication information for the
|
|
201
|
+
user-interactive authentication API.
|
|
202
|
+
allOf:
|
|
203
|
+
- $ref: definitions/auth_data.yaml
|
|
204
|
+
required: true
|
|
205
|
+
responses:
|
|
206
|
+
"200":
|
|
207
|
+
description: |-
|
|
208
|
+
The device was successfully removed, or had been removed
|
|
209
|
+
previously.
|
|
210
|
+
content:
|
|
211
|
+
application/json:
|
|
212
|
+
schema:
|
|
213
|
+
type: object
|
|
214
|
+
examples:
|
|
215
|
+
response:
|
|
216
|
+
value: {}
|
|
217
|
+
"401":
|
|
218
|
+
description: The homeserver requires additional authentication information.
|
|
219
|
+
content:
|
|
220
|
+
application/json:
|
|
221
|
+
schema:
|
|
222
|
+
$ref: definitions/auth_response.yaml
|
|
223
|
+
tags:
|
|
224
|
+
- Device management
|
|
225
|
+
/delete_devices:
|
|
226
|
+
post:
|
|
227
|
+
summary: Bulk deletion of devices
|
|
228
|
+
x-changedInMatrixVersion:
|
|
229
|
+
"1.17": |-
|
|
230
|
+
This endpoint no longer requires User-Interactive Authentication when used by an
|
|
231
|
+
application service.
|
|
232
|
+
description: |-
|
|
233
|
+
This API endpoint uses the [User-Interactive Authentication API](/client-server-api/#user-interactive-authentication-api),
|
|
234
|
+
except when used by an application service.
|
|
235
|
+
|
|
236
|
+
Deletes the given devices, and invalidates any access token associated with them.
|
|
237
|
+
|
|
238
|
+
{{% boxes/warning %}}
|
|
239
|
+
When this endpoint requires User-Interactive Authentication, it cannot be used when the access token was obtained
|
|
240
|
+
via the [OAuth 2.0 API](/client-server-api/#oauth-20-api).
|
|
241
|
+
{{% /boxes/warning %}}
|
|
242
|
+
|
|
243
|
+
{{% boxes/warning %}}
|
|
244
|
+
{{% added-in v="1.18" %}} [OAuth 2.0 aware clients](/client-server-api/#oauth-20-aware-clients)
|
|
245
|
+
MUST NOT use this endpoint when the server supports the [OAuth 2.0 API](/client-server-api/#oauth-20-api).
|
|
246
|
+
Instead they MUST refer the user to the [account management URL](/client-server-api/#oauth-20-account-management),
|
|
247
|
+
if available.
|
|
248
|
+
{{% /boxes/warning %}}
|
|
249
|
+
operationId: deleteDevices
|
|
250
|
+
security:
|
|
251
|
+
- accessTokenQuery: []
|
|
252
|
+
- accessTokenBearer: []
|
|
253
|
+
requestBody:
|
|
254
|
+
content:
|
|
255
|
+
application/json:
|
|
256
|
+
schema:
|
|
257
|
+
type: object
|
|
258
|
+
properties:
|
|
259
|
+
devices:
|
|
260
|
+
type: array
|
|
261
|
+
description: The list of device IDs to delete.
|
|
262
|
+
items:
|
|
263
|
+
type: string
|
|
264
|
+
description: A list of device IDs.
|
|
265
|
+
example:
|
|
266
|
+
- QBUAZIFURK
|
|
267
|
+
- AUIECTSRND
|
|
268
|
+
auth:
|
|
269
|
+
allOf:
|
|
270
|
+
- $ref: definitions/auth_data.yaml
|
|
271
|
+
description: |-
|
|
272
|
+
Additional authentication information for the
|
|
273
|
+
user-interactive authentication API.
|
|
274
|
+
required:
|
|
275
|
+
- devices
|
|
276
|
+
required: true
|
|
277
|
+
responses:
|
|
278
|
+
"200":
|
|
279
|
+
description: |-
|
|
280
|
+
The devices were successfully removed, or had been removed
|
|
281
|
+
previously.
|
|
282
|
+
content:
|
|
283
|
+
application/json:
|
|
284
|
+
schema:
|
|
285
|
+
type: object
|
|
286
|
+
examples:
|
|
287
|
+
response:
|
|
288
|
+
value: {}
|
|
289
|
+
"401":
|
|
290
|
+
description: The homeserver requires additional authentication information.
|
|
291
|
+
content:
|
|
292
|
+
application/json:
|
|
293
|
+
schema:
|
|
294
|
+
$ref: definitions/auth_response.yaml
|
|
295
|
+
tags:
|
|
296
|
+
- Device management
|
|
297
|
+
servers:
|
|
298
|
+
- url: "{protocol}://{hostname}{basePath}"
|
|
299
|
+
variables:
|
|
300
|
+
protocol:
|
|
301
|
+
enum:
|
|
302
|
+
- http
|
|
303
|
+
- https
|
|
304
|
+
default: https
|
|
305
|
+
hostname:
|
|
306
|
+
default: localhost:8008
|
|
307
|
+
basePath:
|
|
308
|
+
default: /_matrix/client/v3
|
|
309
|
+
components:
|
|
310
|
+
securitySchemes:
|
|
311
|
+
accessTokenQuery:
|
|
312
|
+
$ref: definitions/security.yaml#/accessTokenQuery
|
|
313
|
+
accessTokenBearer:
|
|
314
|
+
$ref: definitions/security.yaml#/accessTokenBearer
|
|
@@ -0,0 +1,318 @@
|
|
|
1
|
+
# Copyright 2016 OpenMarket Ltd
|
|
2
|
+
#
|
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
# you may not use this file except in compliance with the License.
|
|
5
|
+
# You may obtain a copy of the License at
|
|
6
|
+
#
|
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
#
|
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
# See the License for the specific language governing permissions and
|
|
13
|
+
# limitations under the License.
|
|
14
|
+
openapi: 3.1.0
|
|
15
|
+
info:
|
|
16
|
+
title: Matrix Client-Server Directory API
|
|
17
|
+
version: 1.0.0
|
|
18
|
+
paths:
|
|
19
|
+
"/directory/room/{roomAlias}":
|
|
20
|
+
put:
|
|
21
|
+
summary: Create a new mapping from room alias to room ID.
|
|
22
|
+
operationId: setRoomAlias
|
|
23
|
+
security:
|
|
24
|
+
- accessTokenQuery: []
|
|
25
|
+
- accessTokenBearer: []
|
|
26
|
+
parameters:
|
|
27
|
+
- in: path
|
|
28
|
+
name: roomAlias
|
|
29
|
+
description: |
|
|
30
|
+
The room alias to set. Its format is defined
|
|
31
|
+
[in the appendices](/appendices/#room-aliases).
|
|
32
|
+
required: true
|
|
33
|
+
example: "#monkeys:matrix.org"
|
|
34
|
+
schema:
|
|
35
|
+
type: string
|
|
36
|
+
requestBody:
|
|
37
|
+
content:
|
|
38
|
+
application/json:
|
|
39
|
+
schema:
|
|
40
|
+
type: object
|
|
41
|
+
properties:
|
|
42
|
+
room_id:
|
|
43
|
+
type: string
|
|
44
|
+
description: The room ID to set.
|
|
45
|
+
required:
|
|
46
|
+
- room_id
|
|
47
|
+
example: {
|
|
48
|
+
"room_id": "!abnjk1jdasj98:capuchins.com"
|
|
49
|
+
}
|
|
50
|
+
description: Information about this room alias.
|
|
51
|
+
required: true
|
|
52
|
+
responses:
|
|
53
|
+
"200":
|
|
54
|
+
description: The mapping was created.
|
|
55
|
+
content:
|
|
56
|
+
application/json:
|
|
57
|
+
schema:
|
|
58
|
+
type: object
|
|
59
|
+
examples:
|
|
60
|
+
response:
|
|
61
|
+
value: {}
|
|
62
|
+
"400":
|
|
63
|
+
description: The given `roomAlias` is not a valid room alias.
|
|
64
|
+
content:
|
|
65
|
+
application/json:
|
|
66
|
+
schema:
|
|
67
|
+
$ref: definitions/errors/error.yaml
|
|
68
|
+
examples:
|
|
69
|
+
response:
|
|
70
|
+
value: {
|
|
71
|
+
"errcode": "M_INVALID_PARAM",
|
|
72
|
+
"error": "Room alias invalid"
|
|
73
|
+
}
|
|
74
|
+
"409":
|
|
75
|
+
description: A room alias with that name already exists.
|
|
76
|
+
content:
|
|
77
|
+
application/json:
|
|
78
|
+
schema:
|
|
79
|
+
$ref: definitions/errors/error.yaml
|
|
80
|
+
examples:
|
|
81
|
+
response:
|
|
82
|
+
value: {
|
|
83
|
+
"errcode": "M_UNKNOWN",
|
|
84
|
+
"error": "Room alias #monkeys:matrix.org already exists."
|
|
85
|
+
}
|
|
86
|
+
tags:
|
|
87
|
+
- Room directory
|
|
88
|
+
get:
|
|
89
|
+
summary: Get the room ID corresponding to this room alias.
|
|
90
|
+
description: |-
|
|
91
|
+
Requests that the server resolve a room alias to a room ID.
|
|
92
|
+
|
|
93
|
+
The server will use the federation API to resolve the alias if the
|
|
94
|
+
domain part of the alias does not correspond to the server's own
|
|
95
|
+
domain.
|
|
96
|
+
operationId: getRoomIdByAlias
|
|
97
|
+
parameters:
|
|
98
|
+
- in: path
|
|
99
|
+
name: roomAlias
|
|
100
|
+
description: |
|
|
101
|
+
The room alias. Its format is defined
|
|
102
|
+
[in the appendices](/appendices/#room-aliases).
|
|
103
|
+
required: true
|
|
104
|
+
example: "#monkeys:matrix.org"
|
|
105
|
+
schema:
|
|
106
|
+
type: string
|
|
107
|
+
responses:
|
|
108
|
+
"200":
|
|
109
|
+
description: The room ID and other information for this alias.
|
|
110
|
+
content:
|
|
111
|
+
application/json:
|
|
112
|
+
schema:
|
|
113
|
+
type: object
|
|
114
|
+
properties:
|
|
115
|
+
room_id:
|
|
116
|
+
type: string
|
|
117
|
+
description: The room ID for this room alias.
|
|
118
|
+
servers:
|
|
119
|
+
type: array
|
|
120
|
+
description: A list of servers that are aware of this room alias.
|
|
121
|
+
items:
|
|
122
|
+
type: string
|
|
123
|
+
description: A server which is aware of this room alias.
|
|
124
|
+
examples:
|
|
125
|
+
response:
|
|
126
|
+
value: {
|
|
127
|
+
"room_id": "!abnjk1jdasj98:capuchins.com",
|
|
128
|
+
"servers": [
|
|
129
|
+
"capuchins.com",
|
|
130
|
+
"matrix.org",
|
|
131
|
+
"another.com"
|
|
132
|
+
]
|
|
133
|
+
}
|
|
134
|
+
"400":
|
|
135
|
+
description: The given `roomAlias` is not a valid room alias.
|
|
136
|
+
content:
|
|
137
|
+
application/json:
|
|
138
|
+
schema:
|
|
139
|
+
$ref: definitions/errors/error.yaml
|
|
140
|
+
examples:
|
|
141
|
+
response:
|
|
142
|
+
value: {
|
|
143
|
+
"errcode": "M_INVALID_PARAM",
|
|
144
|
+
"error": "Room alias invalid"
|
|
145
|
+
}
|
|
146
|
+
"404":
|
|
147
|
+
description: There is no mapped room ID for this room alias.
|
|
148
|
+
content:
|
|
149
|
+
application/json:
|
|
150
|
+
schema:
|
|
151
|
+
$ref: definitions/errors/error.yaml
|
|
152
|
+
examples:
|
|
153
|
+
response:
|
|
154
|
+
value: {
|
|
155
|
+
"errcode": "M_NOT_FOUND",
|
|
156
|
+
"error": "Room alias #monkeys:matrix.org not found."
|
|
157
|
+
}
|
|
158
|
+
tags:
|
|
159
|
+
- Room directory
|
|
160
|
+
delete:
|
|
161
|
+
summary: Remove a mapping of room alias to room ID.
|
|
162
|
+
description: |-
|
|
163
|
+
Remove a mapping of room alias to room ID.
|
|
164
|
+
|
|
165
|
+
Servers may choose to implement additional access control checks here, for instance that
|
|
166
|
+
room aliases can only be deleted by their creator or a server administrator.
|
|
167
|
+
|
|
168
|
+
**Note:**
|
|
169
|
+
Servers may choose to update the `alt_aliases` for the `m.room.canonical_alias`
|
|
170
|
+
state event in the room when an alias is removed. Servers which choose to update the
|
|
171
|
+
canonical alias event are recommended to, in addition to their other relevant permission
|
|
172
|
+
checks, delete the alias and return a successful response even if the user does not
|
|
173
|
+
have permission to update the `m.room.canonical_alias` event.
|
|
174
|
+
operationId: deleteRoomAlias
|
|
175
|
+
security:
|
|
176
|
+
- accessTokenQuery: []
|
|
177
|
+
- accessTokenBearer: []
|
|
178
|
+
parameters:
|
|
179
|
+
- in: path
|
|
180
|
+
name: roomAlias
|
|
181
|
+
description: |
|
|
182
|
+
The room alias to remove. Its format is defined
|
|
183
|
+
[in the appendices](/appendices/#room-aliases).
|
|
184
|
+
required: true
|
|
185
|
+
example: "#monkeys:matrix.org"
|
|
186
|
+
schema:
|
|
187
|
+
type: string
|
|
188
|
+
responses:
|
|
189
|
+
"200":
|
|
190
|
+
description: The mapping was deleted.
|
|
191
|
+
content:
|
|
192
|
+
application/json:
|
|
193
|
+
schema:
|
|
194
|
+
type: object
|
|
195
|
+
examples:
|
|
196
|
+
response:
|
|
197
|
+
value: {}
|
|
198
|
+
"404":
|
|
199
|
+
description: There is no mapped room ID for this room alias.
|
|
200
|
+
content:
|
|
201
|
+
application/json:
|
|
202
|
+
schema:
|
|
203
|
+
$ref: definitions/errors/error.yaml
|
|
204
|
+
examples:
|
|
205
|
+
response:
|
|
206
|
+
value: {
|
|
207
|
+
"errcode": "M_NOT_FOUND",
|
|
208
|
+
"error": "Room alias #monkeys:example.org not found."
|
|
209
|
+
}
|
|
210
|
+
tags:
|
|
211
|
+
- Room directory
|
|
212
|
+
"/rooms/{roomId}/aliases":
|
|
213
|
+
get:
|
|
214
|
+
summary: Get a list of local aliases on a given room.
|
|
215
|
+
description: |-
|
|
216
|
+
Get a list of aliases maintained by the local server for the
|
|
217
|
+
given room.
|
|
218
|
+
|
|
219
|
+
This endpoint can be called by users who are in the room (external
|
|
220
|
+
users receive an `M_FORBIDDEN` error response). If the room's
|
|
221
|
+
`m.room.history_visibility` maps to `world_readable`, any
|
|
222
|
+
user can call this endpoint.
|
|
223
|
+
|
|
224
|
+
Servers may choose to implement additional access control checks here,
|
|
225
|
+
such as allowing server administrators to view aliases regardless of
|
|
226
|
+
membership.
|
|
227
|
+
|
|
228
|
+
**Note:**
|
|
229
|
+
Clients are recommended not to display this list of aliases prominently
|
|
230
|
+
as they are not curated, unlike those listed in the `m.room.canonical_alias`
|
|
231
|
+
state event.
|
|
232
|
+
operationId: getLocalAliases
|
|
233
|
+
security:
|
|
234
|
+
- accessTokenQuery: []
|
|
235
|
+
- accessTokenBearer: []
|
|
236
|
+
parameters:
|
|
237
|
+
- in: path
|
|
238
|
+
name: roomId
|
|
239
|
+
description: The room ID to find local aliases of.
|
|
240
|
+
required: true
|
|
241
|
+
example: "!abc123:example.org"
|
|
242
|
+
schema:
|
|
243
|
+
type: string
|
|
244
|
+
responses:
|
|
245
|
+
"200":
|
|
246
|
+
description: The list of local aliases for the room.
|
|
247
|
+
content:
|
|
248
|
+
application/json:
|
|
249
|
+
schema:
|
|
250
|
+
type: object
|
|
251
|
+
properties:
|
|
252
|
+
aliases:
|
|
253
|
+
type: array
|
|
254
|
+
description: The server's local aliases on the room. Can be empty.
|
|
255
|
+
items:
|
|
256
|
+
type: string
|
|
257
|
+
required:
|
|
258
|
+
- aliases
|
|
259
|
+
examples:
|
|
260
|
+
response:
|
|
261
|
+
value: {
|
|
262
|
+
"aliases": [
|
|
263
|
+
"#somewhere:example.com",
|
|
264
|
+
"#another:example.com",
|
|
265
|
+
"#hat_trick:example.com"
|
|
266
|
+
]
|
|
267
|
+
}
|
|
268
|
+
"400":
|
|
269
|
+
description: The given `roomAlias` is not a valid room alias.
|
|
270
|
+
content:
|
|
271
|
+
application/json:
|
|
272
|
+
schema:
|
|
273
|
+
$ref: definitions/errors/error.yaml
|
|
274
|
+
examples:
|
|
275
|
+
response:
|
|
276
|
+
value: {
|
|
277
|
+
"errcode": "M_INVALID_PARAM",
|
|
278
|
+
"error": "Room alias invalid"
|
|
279
|
+
}
|
|
280
|
+
"403":
|
|
281
|
+
description: The user is not permitted to retrieve the list of local aliases for
|
|
282
|
+
the room.
|
|
283
|
+
content:
|
|
284
|
+
application/json:
|
|
285
|
+
schema:
|
|
286
|
+
$ref: definitions/errors/error.yaml
|
|
287
|
+
examples:
|
|
288
|
+
response:
|
|
289
|
+
value: {
|
|
290
|
+
"errcode": "M_FORBIDDEN",
|
|
291
|
+
"error": "You are not a member of the room."
|
|
292
|
+
}
|
|
293
|
+
"429":
|
|
294
|
+
description: This request was rate-limited.
|
|
295
|
+
content:
|
|
296
|
+
application/json:
|
|
297
|
+
schema:
|
|
298
|
+
$ref: definitions/errors/rate_limited.yaml
|
|
299
|
+
tags:
|
|
300
|
+
- Room directory
|
|
301
|
+
servers:
|
|
302
|
+
- url: "{protocol}://{hostname}{basePath}"
|
|
303
|
+
variables:
|
|
304
|
+
protocol:
|
|
305
|
+
enum:
|
|
306
|
+
- http
|
|
307
|
+
- https
|
|
308
|
+
default: https
|
|
309
|
+
hostname:
|
|
310
|
+
default: localhost:8008
|
|
311
|
+
basePath:
|
|
312
|
+
default: /_matrix/client/v3
|
|
313
|
+
components:
|
|
314
|
+
securitySchemes:
|
|
315
|
+
accessTokenQuery:
|
|
316
|
+
$ref: definitions/security.yaml#/accessTokenQuery
|
|
317
|
+
accessTokenBearer:
|
|
318
|
+
$ref: definitions/security.yaml#/accessTokenBearer
|