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,167 @@
|
|
|
1
|
+
# Copyright 2022 The Matrix.org Foundation C.I.C.
|
|
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 Threads List API
|
|
17
|
+
version: 1.0.0
|
|
18
|
+
paths:
|
|
19
|
+
"/rooms/{roomId}/threads":
|
|
20
|
+
get:
|
|
21
|
+
x-addedInMatrixVersion: "1.4"
|
|
22
|
+
summary: Fetches a list of the threads in a room.
|
|
23
|
+
description: |-
|
|
24
|
+
This API is used to paginate through the list of the thread roots in a given room.
|
|
25
|
+
|
|
26
|
+
Optionally, the returned list may be filtered according to whether the requesting
|
|
27
|
+
user has participated in the thread.
|
|
28
|
+
operationId: getThreadRoots
|
|
29
|
+
security:
|
|
30
|
+
- accessTokenQuery: []
|
|
31
|
+
- accessTokenBearer: []
|
|
32
|
+
parameters:
|
|
33
|
+
- in: path
|
|
34
|
+
name: roomId
|
|
35
|
+
description: The room ID where the thread roots are located.
|
|
36
|
+
required: true
|
|
37
|
+
example: "!room:example.org"
|
|
38
|
+
schema:
|
|
39
|
+
type: string
|
|
40
|
+
- in: query
|
|
41
|
+
name: include
|
|
42
|
+
description: |-
|
|
43
|
+
Optional (default `all`) flag to denote which thread roots are of interest to the caller.
|
|
44
|
+
When `all`, all thread roots found in the room are returned. When `participated`, only
|
|
45
|
+
thread roots for threads the user has [participated in](/client-server-api/#server-side-aggregation-of-mthread-relationships)
|
|
46
|
+
will be returned.
|
|
47
|
+
example: all
|
|
48
|
+
schema:
|
|
49
|
+
type: string
|
|
50
|
+
enum:
|
|
51
|
+
- all
|
|
52
|
+
- participated
|
|
53
|
+
- in: query
|
|
54
|
+
name: limit
|
|
55
|
+
description: |-
|
|
56
|
+
Optional limit for the maximum number of thread roots to include per response. Must be an integer
|
|
57
|
+
greater than zero.
|
|
58
|
+
|
|
59
|
+
Servers should apply a default value, and impose a maximum value to avoid resource exhaustion.
|
|
60
|
+
example: 20
|
|
61
|
+
schema:
|
|
62
|
+
type: integer
|
|
63
|
+
- in: query
|
|
64
|
+
name: from
|
|
65
|
+
description: |-
|
|
66
|
+
A pagination token from a previous result. When not provided, the server starts paginating from
|
|
67
|
+
the most recent event visible to the user (as per history visibility rules; topologically).
|
|
68
|
+
example: next_batch_token
|
|
69
|
+
schema:
|
|
70
|
+
type: string
|
|
71
|
+
responses:
|
|
72
|
+
"200":
|
|
73
|
+
description: A portion of the available thread roots in the room, based on the
|
|
74
|
+
filter criteria.
|
|
75
|
+
content:
|
|
76
|
+
application/json:
|
|
77
|
+
schema:
|
|
78
|
+
type: object
|
|
79
|
+
properties:
|
|
80
|
+
chunk:
|
|
81
|
+
type: array
|
|
82
|
+
description: |-
|
|
83
|
+
The thread roots, ordered by the `latest_event` in each event's aggregated children. All events
|
|
84
|
+
returned include bundled [aggregations](/client-server-api/#aggregations-of-child-events).
|
|
85
|
+
|
|
86
|
+
If the thread root event was sent by an [ignored user](/client-server-api/#ignoring-users), the
|
|
87
|
+
event is returned redacted to the caller. This is to simulate the same behaviour of a client doing
|
|
88
|
+
aggregation locally on the thread.
|
|
89
|
+
items:
|
|
90
|
+
$ref: definitions/client_event.yaml
|
|
91
|
+
next_batch:
|
|
92
|
+
type: string
|
|
93
|
+
description: |-
|
|
94
|
+
A token to supply to `from` to keep paginating the responses. Not present when there are
|
|
95
|
+
no further results.
|
|
96
|
+
required:
|
|
97
|
+
- chunk
|
|
98
|
+
examples:
|
|
99
|
+
response:
|
|
100
|
+
value: {
|
|
101
|
+
"chunk": [
|
|
102
|
+
{
|
|
103
|
+
"$ref": "../../event-schemas/examples/m.room.message$m.text.yaml"
|
|
104
|
+
}
|
|
105
|
+
],
|
|
106
|
+
"next_batch": "next_batch_token"
|
|
107
|
+
}
|
|
108
|
+
"400":
|
|
109
|
+
description: |-
|
|
110
|
+
The request was invalid in some way. A meaningful `errcode`
|
|
111
|
+
and description error text will be returned. Example reasons for rejection are:
|
|
112
|
+
|
|
113
|
+
- The `from` token is unknown to the server.
|
|
114
|
+
content:
|
|
115
|
+
application/json:
|
|
116
|
+
schema:
|
|
117
|
+
$ref: definitions/errors/error.yaml
|
|
118
|
+
examples:
|
|
119
|
+
response:
|
|
120
|
+
value: {
|
|
121
|
+
"errcode": "M_INVALID_PARAM",
|
|
122
|
+
"error": "Unknown pagination token"
|
|
123
|
+
}
|
|
124
|
+
"403":
|
|
125
|
+
description: |-
|
|
126
|
+
The user cannot view or peek on the room. A meaningful `errcode`
|
|
127
|
+
and description error text will be returned. Example reasons for rejection are:
|
|
128
|
+
|
|
129
|
+
- The room is not set up for peeking.
|
|
130
|
+
- The user has been banned from the room.
|
|
131
|
+
- The room does not exist.
|
|
132
|
+
content:
|
|
133
|
+
application/json:
|
|
134
|
+
schema:
|
|
135
|
+
$ref: definitions/errors/error.yaml
|
|
136
|
+
examples:
|
|
137
|
+
response:
|
|
138
|
+
value: {
|
|
139
|
+
"errcode": "M_FORBIDDEN",
|
|
140
|
+
"error": "You are not allowed to view this room."
|
|
141
|
+
}
|
|
142
|
+
"429":
|
|
143
|
+
description: This request was rate-limited.
|
|
144
|
+
content:
|
|
145
|
+
application/json:
|
|
146
|
+
schema:
|
|
147
|
+
$ref: definitions/errors/rate_limited.yaml
|
|
148
|
+
tags:
|
|
149
|
+
- Threads
|
|
150
|
+
servers:
|
|
151
|
+
- url: "{protocol}://{hostname}{basePath}"
|
|
152
|
+
variables:
|
|
153
|
+
protocol:
|
|
154
|
+
enum:
|
|
155
|
+
- http
|
|
156
|
+
- https
|
|
157
|
+
default: https
|
|
158
|
+
hostname:
|
|
159
|
+
default: localhost:8008
|
|
160
|
+
basePath:
|
|
161
|
+
default: /_matrix/client/v1
|
|
162
|
+
components:
|
|
163
|
+
securitySchemes:
|
|
164
|
+
accessTokenQuery:
|
|
165
|
+
$ref: definitions/security.yaml#/accessTokenQuery
|
|
166
|
+
accessTokenBearer:
|
|
167
|
+
$ref: definitions/security.yaml#/accessTokenBearer
|
|
@@ -0,0 +1,104 @@
|
|
|
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 Send-to-device API
|
|
17
|
+
version: 1.0.0
|
|
18
|
+
paths:
|
|
19
|
+
"/sendToDevice/{eventType}/{txnId}":
|
|
20
|
+
put:
|
|
21
|
+
summary: Send an event to a given set of devices.
|
|
22
|
+
description: |-
|
|
23
|
+
This endpoint is used to send send-to-device events to a set of
|
|
24
|
+
client devices.
|
|
25
|
+
operationId: sendToDevice
|
|
26
|
+
security:
|
|
27
|
+
- accessTokenQuery: []
|
|
28
|
+
- accessTokenBearer: []
|
|
29
|
+
parameters:
|
|
30
|
+
- in: path
|
|
31
|
+
name: eventType
|
|
32
|
+
description: The type of event to send.
|
|
33
|
+
required: true
|
|
34
|
+
example: m.new_device
|
|
35
|
+
schema:
|
|
36
|
+
type: string
|
|
37
|
+
- in: path
|
|
38
|
+
name: txnId
|
|
39
|
+
description: |-
|
|
40
|
+
The [transaction ID](/client-server-api/#transaction-identifiers) for this event. Clients should generate an
|
|
41
|
+
ID unique across requests with the same access token; it will be
|
|
42
|
+
used by the server to ensure idempotency of requests.
|
|
43
|
+
required: true
|
|
44
|
+
example: "35"
|
|
45
|
+
schema:
|
|
46
|
+
type: string
|
|
47
|
+
requestBody:
|
|
48
|
+
content:
|
|
49
|
+
application/json:
|
|
50
|
+
schema:
|
|
51
|
+
type: object
|
|
52
|
+
title: body
|
|
53
|
+
properties:
|
|
54
|
+
messages:
|
|
55
|
+
type: object
|
|
56
|
+
description: |-
|
|
57
|
+
The messages to send. A map from user ID, to a map from
|
|
58
|
+
device ID to message body. The device ID may also be `*`,
|
|
59
|
+
meaning all known devices for the user.
|
|
60
|
+
patternProperties:
|
|
61
|
+
"^@":
|
|
62
|
+
x-pattern-format: mx-user-id
|
|
63
|
+
type: object
|
|
64
|
+
additionalProperties:
|
|
65
|
+
type: object
|
|
66
|
+
title: EventContent
|
|
67
|
+
description: Message content
|
|
68
|
+
example:
|
|
69
|
+
"@alice:example.com":
|
|
70
|
+
TLLBEANAAG:
|
|
71
|
+
example_content_key: value
|
|
72
|
+
required:
|
|
73
|
+
- messages
|
|
74
|
+
required: true
|
|
75
|
+
responses:
|
|
76
|
+
"200":
|
|
77
|
+
description: The message was successfully sent.
|
|
78
|
+
content:
|
|
79
|
+
application/json:
|
|
80
|
+
schema:
|
|
81
|
+
type: object
|
|
82
|
+
examples:
|
|
83
|
+
response:
|
|
84
|
+
value: {}
|
|
85
|
+
tags:
|
|
86
|
+
- Send-to-Device messaging
|
|
87
|
+
servers:
|
|
88
|
+
- url: "{protocol}://{hostname}{basePath}"
|
|
89
|
+
variables:
|
|
90
|
+
protocol:
|
|
91
|
+
enum:
|
|
92
|
+
- http
|
|
93
|
+
- https
|
|
94
|
+
default: https
|
|
95
|
+
hostname:
|
|
96
|
+
default: localhost:8008
|
|
97
|
+
basePath:
|
|
98
|
+
default: /_matrix/client/v3
|
|
99
|
+
components:
|
|
100
|
+
securitySchemes:
|
|
101
|
+
accessTokenQuery:
|
|
102
|
+
$ref: definitions/security.yaml#/accessTokenQuery
|
|
103
|
+
accessTokenBearer:
|
|
104
|
+
$ref: definitions/security.yaml#/accessTokenBearer
|
|
@@ -0,0 +1,103 @@
|
|
|
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 Typing API
|
|
17
|
+
version: 1.0.0
|
|
18
|
+
paths:
|
|
19
|
+
"/rooms/{roomId}/typing/{userId}":
|
|
20
|
+
put:
|
|
21
|
+
summary: Informs the server that the user has started or stopped typing.
|
|
22
|
+
description: |-
|
|
23
|
+
This tells the server that the user is typing for the next N
|
|
24
|
+
milliseconds where N is the value specified in the `timeout` key.
|
|
25
|
+
Alternatively, if `typing` is `false`, it tells the server that the
|
|
26
|
+
user has stopped typing.
|
|
27
|
+
operationId: setTyping
|
|
28
|
+
security:
|
|
29
|
+
- accessTokenQuery: []
|
|
30
|
+
- accessTokenBearer: []
|
|
31
|
+
parameters:
|
|
32
|
+
- in: path
|
|
33
|
+
name: userId
|
|
34
|
+
description: The user who has started to type.
|
|
35
|
+
required: true
|
|
36
|
+
example: "@alice:example.com"
|
|
37
|
+
schema:
|
|
38
|
+
type: string
|
|
39
|
+
- in: path
|
|
40
|
+
name: roomId
|
|
41
|
+
description: The room in which the user is typing.
|
|
42
|
+
required: true
|
|
43
|
+
example: "!wefh3sfukhs:example.com"
|
|
44
|
+
schema:
|
|
45
|
+
type: string
|
|
46
|
+
requestBody:
|
|
47
|
+
content:
|
|
48
|
+
application/json:
|
|
49
|
+
schema:
|
|
50
|
+
type: object
|
|
51
|
+
example: {
|
|
52
|
+
"typing": true,
|
|
53
|
+
"timeout": 30000
|
|
54
|
+
}
|
|
55
|
+
properties:
|
|
56
|
+
typing:
|
|
57
|
+
type: boolean
|
|
58
|
+
description: |-
|
|
59
|
+
Whether the user is typing or not. If `false`, the `timeout`
|
|
60
|
+
key can be omitted.
|
|
61
|
+
timeout:
|
|
62
|
+
type: integer
|
|
63
|
+
description: The length of time in milliseconds to mark this user as typing.
|
|
64
|
+
required:
|
|
65
|
+
- typing
|
|
66
|
+
description: The current typing state.
|
|
67
|
+
required: true
|
|
68
|
+
responses:
|
|
69
|
+
"200":
|
|
70
|
+
description: The new typing state was set.
|
|
71
|
+
content:
|
|
72
|
+
application/json:
|
|
73
|
+
schema:
|
|
74
|
+
type: object # empty json object
|
|
75
|
+
examples:
|
|
76
|
+
response:
|
|
77
|
+
value: {}
|
|
78
|
+
"429":
|
|
79
|
+
description: This request was rate-limited.
|
|
80
|
+
content:
|
|
81
|
+
application/json:
|
|
82
|
+
schema:
|
|
83
|
+
$ref: definitions/errors/rate_limited.yaml
|
|
84
|
+
tags:
|
|
85
|
+
- Room participation
|
|
86
|
+
servers:
|
|
87
|
+
- url: "{protocol}://{hostname}{basePath}"
|
|
88
|
+
variables:
|
|
89
|
+
protocol:
|
|
90
|
+
enum:
|
|
91
|
+
- http
|
|
92
|
+
- https
|
|
93
|
+
default: https
|
|
94
|
+
hostname:
|
|
95
|
+
default: localhost:8008
|
|
96
|
+
basePath:
|
|
97
|
+
default: /_matrix/client/v3
|
|
98
|
+
components:
|
|
99
|
+
securitySchemes:
|
|
100
|
+
accessTokenQuery:
|
|
101
|
+
$ref: definitions/security.yaml#/accessTokenQuery
|
|
102
|
+
accessTokenBearer:
|
|
103
|
+
$ref: definitions/security.yaml#/accessTokenBearer
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
# Copyright 2017 New Vector 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 User Directory API
|
|
17
|
+
version: 1.0.0
|
|
18
|
+
paths:
|
|
19
|
+
/user_directory/search:
|
|
20
|
+
post:
|
|
21
|
+
summary: Searches the user directory.
|
|
22
|
+
description: |-
|
|
23
|
+
Performs a search for users. The homeserver may determine which
|
|
24
|
+
subset of users are searched. However, the homeserver MUST at a
|
|
25
|
+
minimum consider users who are visible to the requester based
|
|
26
|
+
on their membership in rooms known to the homeserver. This means:
|
|
27
|
+
|
|
28
|
+
- users that share a room with the requesting user
|
|
29
|
+
- users who are joined to rooms known to the homeserver that have a
|
|
30
|
+
`public` [join rule](#mroomjoin_rules)
|
|
31
|
+
- users who are joined to rooms known to the homeserver that have a
|
|
32
|
+
`world_readable` [history visibility](#room-history-visibility)
|
|
33
|
+
|
|
34
|
+
The search MUST consider local users to the homeserver, and SHOULD
|
|
35
|
+
query remote users as part of the search.
|
|
36
|
+
|
|
37
|
+
The search is performed case-insensitively on user IDs and display
|
|
38
|
+
names preferably using a collation determined based upon the
|
|
39
|
+
`Accept-Language` header provided in the request, if present.
|
|
40
|
+
operationId: searchUserDirectory
|
|
41
|
+
security:
|
|
42
|
+
- accessTokenQuery: []
|
|
43
|
+
- accessTokenBearer: []
|
|
44
|
+
requestBody:
|
|
45
|
+
content:
|
|
46
|
+
application/json:
|
|
47
|
+
schema:
|
|
48
|
+
type: object
|
|
49
|
+
properties:
|
|
50
|
+
search_term:
|
|
51
|
+
type: string
|
|
52
|
+
description: The term to search for
|
|
53
|
+
example: foo
|
|
54
|
+
limit:
|
|
55
|
+
type: integer
|
|
56
|
+
description: The maximum number of results to return. Defaults to 10.
|
|
57
|
+
example: 10
|
|
58
|
+
required:
|
|
59
|
+
- search_term
|
|
60
|
+
required: true
|
|
61
|
+
responses:
|
|
62
|
+
"200":
|
|
63
|
+
description: The results of the search.
|
|
64
|
+
content:
|
|
65
|
+
application/json:
|
|
66
|
+
schema:
|
|
67
|
+
type: object
|
|
68
|
+
required:
|
|
69
|
+
- results
|
|
70
|
+
- limited
|
|
71
|
+
properties:
|
|
72
|
+
results:
|
|
73
|
+
type: array
|
|
74
|
+
description: Ordered by rank and then whether or not profile info is available.
|
|
75
|
+
items:
|
|
76
|
+
title: User
|
|
77
|
+
type: object
|
|
78
|
+
required:
|
|
79
|
+
- user_id
|
|
80
|
+
properties:
|
|
81
|
+
user_id:
|
|
82
|
+
type: string
|
|
83
|
+
example: "@foo:bar.com"
|
|
84
|
+
description: The user's matrix user ID.
|
|
85
|
+
display_name:
|
|
86
|
+
type: string
|
|
87
|
+
example: Foo
|
|
88
|
+
description: The display name of the user, if one exists.
|
|
89
|
+
avatar_url:
|
|
90
|
+
type: string
|
|
91
|
+
format: uri
|
|
92
|
+
example: mxc://bar.com/foo
|
|
93
|
+
description: The avatar url, as an [`mxc://`
|
|
94
|
+
URI](/client-server-api/#matrix-content-mxc-uris),
|
|
95
|
+
if one exists.
|
|
96
|
+
limited:
|
|
97
|
+
type: boolean
|
|
98
|
+
description: Indicates if the result list has been truncated by the limit.
|
|
99
|
+
examples:
|
|
100
|
+
response:
|
|
101
|
+
value: {
|
|
102
|
+
"results": [
|
|
103
|
+
{
|
|
104
|
+
"user_id": "@foo:bar.com",
|
|
105
|
+
"display_name": "Foo",
|
|
106
|
+
"avatar_url": "mxc://bar.com/foo"
|
|
107
|
+
}
|
|
108
|
+
],
|
|
109
|
+
"limited": false
|
|
110
|
+
}
|
|
111
|
+
"429":
|
|
112
|
+
description: This request was rate-limited.
|
|
113
|
+
content:
|
|
114
|
+
application/json:
|
|
115
|
+
schema:
|
|
116
|
+
$ref: definitions/errors/rate_limited.yaml
|
|
117
|
+
tags:
|
|
118
|
+
- User directory
|
|
119
|
+
servers:
|
|
120
|
+
- url: "{protocol}://{hostname}{basePath}"
|
|
121
|
+
variables:
|
|
122
|
+
protocol:
|
|
123
|
+
enum:
|
|
124
|
+
- http
|
|
125
|
+
- https
|
|
126
|
+
default: https
|
|
127
|
+
hostname:
|
|
128
|
+
default: localhost:8008
|
|
129
|
+
basePath:
|
|
130
|
+
default: /_matrix/client/v3
|
|
131
|
+
components:
|
|
132
|
+
securitySchemes:
|
|
133
|
+
accessTokenQuery:
|
|
134
|
+
$ref: definitions/security.yaml#/accessTokenQuery
|
|
135
|
+
accessTokenBearer:
|
|
136
|
+
$ref: definitions/security.yaml#/accessTokenBearer
|
|
@@ -0,0 +1,108 @@
|
|
|
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 Versions API
|
|
17
|
+
version: 1.0.0
|
|
18
|
+
paths:
|
|
19
|
+
/versions:
|
|
20
|
+
get:
|
|
21
|
+
summary: Gets the versions of the specification supported by the server.
|
|
22
|
+
description: |-
|
|
23
|
+
Gets the versions of the specification supported by the server.
|
|
24
|
+
|
|
25
|
+
Values will take the form `vX.Y` or `rX.Y.Z` in historical cases. See
|
|
26
|
+
[the Specification Versioning](../#specification-versions) for more
|
|
27
|
+
information.
|
|
28
|
+
|
|
29
|
+
The server may additionally advertise experimental features it supports
|
|
30
|
+
through `unstable_features`. These features should be namespaced and
|
|
31
|
+
may optionally include version information within their name if desired.
|
|
32
|
+
Features listed here are not for optionally toggling parts of the Matrix
|
|
33
|
+
specification and should only be used to advertise support for a feature
|
|
34
|
+
which has not yet landed in the spec. For example, a feature currently
|
|
35
|
+
undergoing the proposal process may appear here and eventually be taken
|
|
36
|
+
off this list once the feature lands in the spec and the server deems it
|
|
37
|
+
reasonable to do so. Servers can choose to enable some features only for
|
|
38
|
+
some users, so clients should include authentication in the request to
|
|
39
|
+
get all the features available for the logged-in user. If no
|
|
40
|
+
authentication is provided, the server should only return the features
|
|
41
|
+
available to all users. Servers may wish to keep advertising features
|
|
42
|
+
here after they've been released into the spec to give clients a chance
|
|
43
|
+
to upgrade appropriately. Additionally, clients should avoid using
|
|
44
|
+
unstable features in their stable releases.
|
|
45
|
+
operationId: getVersions
|
|
46
|
+
security:
|
|
47
|
+
- {}
|
|
48
|
+
- accessTokenQuery: []
|
|
49
|
+
- accessTokenBearer: []
|
|
50
|
+
x-changedInMatrixVersion:
|
|
51
|
+
"1.10": |
|
|
52
|
+
This endpoint can behave differently when authentication is provided.
|
|
53
|
+
responses:
|
|
54
|
+
"200":
|
|
55
|
+
description: The versions supported by the server.
|
|
56
|
+
content:
|
|
57
|
+
application/json:
|
|
58
|
+
schema:
|
|
59
|
+
type: object
|
|
60
|
+
properties:
|
|
61
|
+
versions:
|
|
62
|
+
type: array
|
|
63
|
+
description: The supported versions.
|
|
64
|
+
items:
|
|
65
|
+
type: string
|
|
66
|
+
description: The supported versions
|
|
67
|
+
unstable_features:
|
|
68
|
+
type: object
|
|
69
|
+
description: |-
|
|
70
|
+
Experimental features the server supports. Features not listed here,
|
|
71
|
+
or the lack of this property all together, indicate that a feature is
|
|
72
|
+
not supported.
|
|
73
|
+
additionalProperties:
|
|
74
|
+
type: boolean
|
|
75
|
+
description: Whether or not the namespaced feature is supported.
|
|
76
|
+
required:
|
|
77
|
+
- versions
|
|
78
|
+
examples:
|
|
79
|
+
response:
|
|
80
|
+
value: {
|
|
81
|
+
"versions": [
|
|
82
|
+
"r0.0.1",
|
|
83
|
+
"v1.1"
|
|
84
|
+
],
|
|
85
|
+
"unstable_features": {
|
|
86
|
+
"org.example.my_feature": true
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
tags:
|
|
90
|
+
- Server administration
|
|
91
|
+
servers:
|
|
92
|
+
- url: "{protocol}://{hostname}{basePath}"
|
|
93
|
+
variables:
|
|
94
|
+
protocol:
|
|
95
|
+
enum:
|
|
96
|
+
- http
|
|
97
|
+
- https
|
|
98
|
+
default: https
|
|
99
|
+
hostname:
|
|
100
|
+
default: localhost:8008
|
|
101
|
+
basePath:
|
|
102
|
+
default: /_matrix/client
|
|
103
|
+
components:
|
|
104
|
+
securitySchemes:
|
|
105
|
+
accessTokenQuery:
|
|
106
|
+
$ref: definitions/security.yaml#/accessTokenQuery
|
|
107
|
+
accessTokenBearer:
|
|
108
|
+
$ref: definitions/security.yaml#/accessTokenBearer
|