async-matrix 0.1.3 → 1.1.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/discord-api-spec/openapi.json +40404 -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/discord/api/path_tree.rb +130 -0
- data/lib/async/discord/api.rb +156 -0
- data/lib/async/discord/client.rb +286 -0
- data/lib/async/discord/error.rb +88 -0
- data/lib/async/discord/gateway.rb +362 -0
- data/lib/async/discord.rb +16 -0
- data/lib/async/matrix/api/chain.rb +584 -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 +113 -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 +206 -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/bridge/discord/db/connection.rb +143 -0
- data/lib/async/matrix/bridge/discord/db/file.rb +120 -0
- data/lib/async/matrix/bridge/discord/db/guild.rb +122 -0
- data/lib/async/matrix/bridge/discord/db/message.rb +162 -0
- data/lib/async/matrix/bridge/discord/db/migrations/001_create_users.rb +14 -0
- data/lib/async/matrix/bridge/discord/db/migrations/002_create_guilds.rb +14 -0
- data/lib/async/matrix/bridge/discord/db/migrations/003_create_portals.rb +23 -0
- data/lib/async/matrix/bridge/discord/db/migrations/004_create_puppets.rb +19 -0
- data/lib/async/matrix/bridge/discord/db/migrations/005_create_messages.rb +20 -0
- data/lib/async/matrix/bridge/discord/db/migrations/006_create_reactions.rb +19 -0
- data/lib/async/matrix/bridge/discord/db/migrations/007_create_files.rb +18 -0
- data/lib/async/matrix/bridge/discord/db/portal.rb +152 -0
- data/lib/async/matrix/bridge/discord/db/puppet.rb +130 -0
- data/lib/async/matrix/bridge/discord/db/reaction.rb +167 -0
- data/lib/async/matrix/bridge/discord/db/user.rb +114 -0
- data/lib/async/matrix/bridge/discord/db.rb +140 -0
- data/lib/async/matrix/client.rb +919 -179
- data/lib/async/matrix/connection.rb +8 -8
- data/lib/async/matrix/double_puppet_client.rb +84 -0
- 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 +8 -7
- data/lib/async/matrix/stream.rb +7 -7
- data/lib/async/matrix/version.rb +1 -1
- data/lib/async/matrix.rb +4 -2
- metadata +419 -1
|
@@ -0,0 +1,389 @@
|
|
|
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 Client Config API
|
|
17
|
+
version: 1.0.0
|
|
18
|
+
paths:
|
|
19
|
+
"/user/{userId}/account_data/{type}":
|
|
20
|
+
put:
|
|
21
|
+
summary: Set some account data for the user.
|
|
22
|
+
description: |-
|
|
23
|
+
Set some account data for the client. This config is only visible to the user
|
|
24
|
+
that set the account data. The config will be available to clients through the
|
|
25
|
+
top-level `account_data` field in the homeserver response to
|
|
26
|
+
[/sync](/client-server-api/#get_matrixclientv3sync).
|
|
27
|
+
operationId: setAccountData
|
|
28
|
+
security:
|
|
29
|
+
- accessTokenQuery: []
|
|
30
|
+
- accessTokenBearer: []
|
|
31
|
+
parameters:
|
|
32
|
+
- in: path
|
|
33
|
+
name: userId
|
|
34
|
+
required: true
|
|
35
|
+
description: |-
|
|
36
|
+
The ID of the user to set account data for. The access token must be
|
|
37
|
+
authorized to make requests for this user ID.
|
|
38
|
+
example: "@alice:example.com"
|
|
39
|
+
schema:
|
|
40
|
+
type: string
|
|
41
|
+
- in: path
|
|
42
|
+
name: type
|
|
43
|
+
required: true
|
|
44
|
+
description: |-
|
|
45
|
+
The event type of the account data to set. Custom types should be
|
|
46
|
+
namespaced to avoid clashes.
|
|
47
|
+
example: org.example.custom.config
|
|
48
|
+
schema:
|
|
49
|
+
type: string
|
|
50
|
+
requestBody:
|
|
51
|
+
content:
|
|
52
|
+
application/json:
|
|
53
|
+
schema:
|
|
54
|
+
type: object
|
|
55
|
+
example: {
|
|
56
|
+
"custom_account_data_key": "custom_config_value"
|
|
57
|
+
}
|
|
58
|
+
description: The content of the account data.
|
|
59
|
+
required: true
|
|
60
|
+
responses:
|
|
61
|
+
"200":
|
|
62
|
+
description: The account data was successfully added.
|
|
63
|
+
content:
|
|
64
|
+
application/json:
|
|
65
|
+
schema:
|
|
66
|
+
type: object
|
|
67
|
+
examples:
|
|
68
|
+
response:
|
|
69
|
+
value: {}
|
|
70
|
+
"400":
|
|
71
|
+
description: |-
|
|
72
|
+
The request body is not a JSON object. Errcode: `M_BAD_JSON`
|
|
73
|
+
or `M_NOT_JSON`.
|
|
74
|
+
content:
|
|
75
|
+
application/json:
|
|
76
|
+
schema:
|
|
77
|
+
$ref: ../client-server/definitions/errors/error.yaml
|
|
78
|
+
examples:
|
|
79
|
+
response:
|
|
80
|
+
value: {
|
|
81
|
+
"errcode": "M_NOT_JSON",
|
|
82
|
+
"error": "Content must be a JSON object."
|
|
83
|
+
}
|
|
84
|
+
"403":
|
|
85
|
+
description: |-
|
|
86
|
+
The access token provided is not authorized to modify this user's account
|
|
87
|
+
data. Errcode: `M_FORBIDDEN`.
|
|
88
|
+
content:
|
|
89
|
+
application/json:
|
|
90
|
+
schema:
|
|
91
|
+
$ref: ../client-server/definitions/errors/error.yaml
|
|
92
|
+
examples:
|
|
93
|
+
response:
|
|
94
|
+
value: {
|
|
95
|
+
"errcode": "M_FORBIDDEN",
|
|
96
|
+
"error": "Cannot add account data for other users."
|
|
97
|
+
}
|
|
98
|
+
"405":
|
|
99
|
+
description: |-
|
|
100
|
+
This `type` of account data is controlled by the server; it cannot be
|
|
101
|
+
modified by clients. Errcode: `M_BAD_JSON`.
|
|
102
|
+
content:
|
|
103
|
+
application/json:
|
|
104
|
+
schema:
|
|
105
|
+
$ref: ../client-server/definitions/errors/error.yaml
|
|
106
|
+
examples:
|
|
107
|
+
response:
|
|
108
|
+
value: {
|
|
109
|
+
"errcode": "M_BAD_JSON",
|
|
110
|
+
"error": "Cannot set m.fully_read through this API."
|
|
111
|
+
}
|
|
112
|
+
tags:
|
|
113
|
+
- User data
|
|
114
|
+
get:
|
|
115
|
+
summary: Get some account data for the user.
|
|
116
|
+
description: |-
|
|
117
|
+
Get some account data for the client. This config is only visible to the user
|
|
118
|
+
that set the account data.
|
|
119
|
+
operationId: getAccountData
|
|
120
|
+
security:
|
|
121
|
+
- accessTokenQuery: []
|
|
122
|
+
- accessTokenBearer: []
|
|
123
|
+
parameters:
|
|
124
|
+
- in: path
|
|
125
|
+
name: userId
|
|
126
|
+
required: true
|
|
127
|
+
description: |-
|
|
128
|
+
The ID of the user to get account data for. The access token must be
|
|
129
|
+
authorized to make requests for this user ID.
|
|
130
|
+
example: "@alice:example.com"
|
|
131
|
+
schema:
|
|
132
|
+
type: string
|
|
133
|
+
- in: path
|
|
134
|
+
name: type
|
|
135
|
+
required: true
|
|
136
|
+
description: |-
|
|
137
|
+
The event type of the account data to get. Custom types should be
|
|
138
|
+
namespaced to avoid clashes.
|
|
139
|
+
example: org.example.custom.config
|
|
140
|
+
schema:
|
|
141
|
+
type: string
|
|
142
|
+
responses:
|
|
143
|
+
"200":
|
|
144
|
+
description: The account data content for the given type.
|
|
145
|
+
content:
|
|
146
|
+
application/json:
|
|
147
|
+
schema:
|
|
148
|
+
type: object
|
|
149
|
+
example: {
|
|
150
|
+
"custom_account_data_key": "custom_config_value"
|
|
151
|
+
}
|
|
152
|
+
"403":
|
|
153
|
+
description: |-
|
|
154
|
+
The access token provided is not authorized to retrieve this user's account
|
|
155
|
+
data. Errcode: `M_FORBIDDEN`.
|
|
156
|
+
content:
|
|
157
|
+
application/json:
|
|
158
|
+
schema:
|
|
159
|
+
$ref: ../client-server/definitions/errors/error.yaml
|
|
160
|
+
examples:
|
|
161
|
+
response:
|
|
162
|
+
value: {
|
|
163
|
+
"errcode": "M_FORBIDDEN",
|
|
164
|
+
"error": "Cannot add account data for other users."
|
|
165
|
+
}
|
|
166
|
+
"404":
|
|
167
|
+
description: |-
|
|
168
|
+
No account data has been provided for this user with the given `type`.
|
|
169
|
+
Errcode: `M_NOT_FOUND`.
|
|
170
|
+
content:
|
|
171
|
+
application/json:
|
|
172
|
+
schema:
|
|
173
|
+
$ref: ../client-server/definitions/errors/error.yaml
|
|
174
|
+
examples:
|
|
175
|
+
response:
|
|
176
|
+
value: {
|
|
177
|
+
"errcode": "M_NOT_FOUND",
|
|
178
|
+
"error": "Account data not found."
|
|
179
|
+
}
|
|
180
|
+
tags:
|
|
181
|
+
- User data
|
|
182
|
+
"/user/{userId}/rooms/{roomId}/account_data/{type}":
|
|
183
|
+
put:
|
|
184
|
+
summary: Set some account data for the user that is specific to a room.
|
|
185
|
+
description: |-
|
|
186
|
+
Set some account data for the client on a given room. This config is only
|
|
187
|
+
visible to the user that set the account data. The config will be delivered to
|
|
188
|
+
clients in the per-room entries via [/sync](/client-server-api/#get_matrixclientv3sync).
|
|
189
|
+
operationId: setAccountDataPerRoom
|
|
190
|
+
security:
|
|
191
|
+
- accessTokenQuery: []
|
|
192
|
+
- accessTokenBearer: []
|
|
193
|
+
parameters:
|
|
194
|
+
- in: path
|
|
195
|
+
name: userId
|
|
196
|
+
required: true
|
|
197
|
+
description: |-
|
|
198
|
+
The ID of the user to set account data for. The access token must be
|
|
199
|
+
authorized to make requests for this user ID.
|
|
200
|
+
example: "@alice:example.com"
|
|
201
|
+
schema:
|
|
202
|
+
type: string
|
|
203
|
+
- in: path
|
|
204
|
+
name: roomId
|
|
205
|
+
required: true
|
|
206
|
+
description: The ID of the room to set account data on.
|
|
207
|
+
example: "!726s6s6q:example.com"
|
|
208
|
+
schema:
|
|
209
|
+
type: string
|
|
210
|
+
- in: path
|
|
211
|
+
name: type
|
|
212
|
+
required: true
|
|
213
|
+
description: |-
|
|
214
|
+
The event type of the account data to set. Custom types should be
|
|
215
|
+
namespaced to avoid clashes.
|
|
216
|
+
example: org.example.custom.room.config
|
|
217
|
+
schema:
|
|
218
|
+
type: string
|
|
219
|
+
requestBody:
|
|
220
|
+
content:
|
|
221
|
+
application/json:
|
|
222
|
+
schema:
|
|
223
|
+
type: object
|
|
224
|
+
example: {
|
|
225
|
+
"custom_account_data_key": "custom_account_data_value"
|
|
226
|
+
}
|
|
227
|
+
description: The content of the account data.
|
|
228
|
+
required: true
|
|
229
|
+
responses:
|
|
230
|
+
"200":
|
|
231
|
+
description: The account data was successfully added.
|
|
232
|
+
content:
|
|
233
|
+
application/json:
|
|
234
|
+
schema:
|
|
235
|
+
type: object
|
|
236
|
+
examples:
|
|
237
|
+
response:
|
|
238
|
+
value: {}
|
|
239
|
+
"400":
|
|
240
|
+
description: |-
|
|
241
|
+
The request body is not a JSON object (errcode `M_BAD_JSON` or
|
|
242
|
+
`M_NOT_JSON`), or the given `roomID` is not a valid room ID
|
|
243
|
+
(errcode `M_INVALID_PARAM`).
|
|
244
|
+
content:
|
|
245
|
+
application/json:
|
|
246
|
+
schema:
|
|
247
|
+
$ref: ../client-server/definitions/errors/error.yaml
|
|
248
|
+
examples:
|
|
249
|
+
response:
|
|
250
|
+
value: {
|
|
251
|
+
"errcode": "M_NOT_JSON",
|
|
252
|
+
"error": "Content must be a JSON object."
|
|
253
|
+
}
|
|
254
|
+
"403":
|
|
255
|
+
description: |-
|
|
256
|
+
The access token provided is not authorized to modify this user's account
|
|
257
|
+
data. Errcode: `M_FORBIDDEN`.
|
|
258
|
+
content:
|
|
259
|
+
application/json:
|
|
260
|
+
schema:
|
|
261
|
+
$ref: ../client-server/definitions/errors/error.yaml
|
|
262
|
+
examples:
|
|
263
|
+
response:
|
|
264
|
+
value: {
|
|
265
|
+
"errcode": "M_FORBIDDEN",
|
|
266
|
+
"error": "Cannot add account data for other users."
|
|
267
|
+
}
|
|
268
|
+
"405":
|
|
269
|
+
description: |-
|
|
270
|
+
This `type` of account data is controlled by the server; it cannot be
|
|
271
|
+
modified by clients. Errcode: `M_BAD_JSON`.
|
|
272
|
+
content:
|
|
273
|
+
application/json:
|
|
274
|
+
schema:
|
|
275
|
+
$ref: ../client-server/definitions/errors/error.yaml
|
|
276
|
+
examples:
|
|
277
|
+
response:
|
|
278
|
+
value: {
|
|
279
|
+
"errcode": "M_BAD_JSON",
|
|
280
|
+
"error": "Cannot set m.fully_read through this API."
|
|
281
|
+
}
|
|
282
|
+
tags:
|
|
283
|
+
- User data
|
|
284
|
+
get:
|
|
285
|
+
summary: Get some account data for the user that is specific to a room.
|
|
286
|
+
description: |-
|
|
287
|
+
Get some account data for the client on a given room. This config is only
|
|
288
|
+
visible to the user that set the account data.
|
|
289
|
+
operationId: getAccountDataPerRoom
|
|
290
|
+
security:
|
|
291
|
+
- accessTokenQuery: []
|
|
292
|
+
- accessTokenBearer: []
|
|
293
|
+
parameters:
|
|
294
|
+
- in: path
|
|
295
|
+
name: userId
|
|
296
|
+
required: true
|
|
297
|
+
description: |-
|
|
298
|
+
The ID of the user to get account data for. The access token must be
|
|
299
|
+
authorized to make requests for this user ID.
|
|
300
|
+
example: "@alice:example.com"
|
|
301
|
+
schema:
|
|
302
|
+
type: string
|
|
303
|
+
- in: path
|
|
304
|
+
name: roomId
|
|
305
|
+
required: true
|
|
306
|
+
description: The ID of the room to get account data for.
|
|
307
|
+
example: "!726s6s6q:example.com"
|
|
308
|
+
schema:
|
|
309
|
+
type: string
|
|
310
|
+
- in: path
|
|
311
|
+
name: type
|
|
312
|
+
required: true
|
|
313
|
+
description: |-
|
|
314
|
+
The event type of the account data to get. Custom types should be
|
|
315
|
+
namespaced to avoid clashes.
|
|
316
|
+
example: org.example.custom.room.config
|
|
317
|
+
schema:
|
|
318
|
+
type: string
|
|
319
|
+
responses:
|
|
320
|
+
"200":
|
|
321
|
+
description: The account data content for the given type.
|
|
322
|
+
content:
|
|
323
|
+
application/json:
|
|
324
|
+
schema:
|
|
325
|
+
type: object
|
|
326
|
+
example: {
|
|
327
|
+
"custom_account_data_key": "custom_config_value"
|
|
328
|
+
}
|
|
329
|
+
"400":
|
|
330
|
+
description: "The given `roomID` is not a valid room ID. Errcode:
|
|
331
|
+
`M_INVALID_PARAM`."
|
|
332
|
+
content:
|
|
333
|
+
application/json:
|
|
334
|
+
schema:
|
|
335
|
+
$ref: ../client-server/definitions/errors/error.yaml
|
|
336
|
+
examples:
|
|
337
|
+
response:
|
|
338
|
+
value: {
|
|
339
|
+
"errcode": "M_INVALID_PARAM",
|
|
340
|
+
"error": "@notaroomid:example.org is not a valid room ID."
|
|
341
|
+
}
|
|
342
|
+
"403":
|
|
343
|
+
description: |-
|
|
344
|
+
The access token provided is not authorized to retrieve this user's account
|
|
345
|
+
data. Errcode: `M_FORBIDDEN`.
|
|
346
|
+
content:
|
|
347
|
+
application/json:
|
|
348
|
+
schema:
|
|
349
|
+
$ref: ../client-server/definitions/errors/error.yaml
|
|
350
|
+
examples:
|
|
351
|
+
response:
|
|
352
|
+
value: {
|
|
353
|
+
"errcode": "M_FORBIDDEN",
|
|
354
|
+
"error": "Cannot add account data for other users."
|
|
355
|
+
}
|
|
356
|
+
"404":
|
|
357
|
+
description: |-
|
|
358
|
+
No account data has been provided for this user and this room with the
|
|
359
|
+
given `type`. Errcode: `M_NOT_FOUND`.
|
|
360
|
+
content:
|
|
361
|
+
application/json:
|
|
362
|
+
schema:
|
|
363
|
+
$ref: ../client-server/definitions/errors/error.yaml
|
|
364
|
+
examples:
|
|
365
|
+
response:
|
|
366
|
+
value: {
|
|
367
|
+
"errcode": "M_NOT_FOUND",
|
|
368
|
+
"error": "Room account data not found."
|
|
369
|
+
}
|
|
370
|
+
tags:
|
|
371
|
+
- User data
|
|
372
|
+
servers:
|
|
373
|
+
- url: "{protocol}://{hostname}{basePath}"
|
|
374
|
+
variables:
|
|
375
|
+
protocol:
|
|
376
|
+
enum:
|
|
377
|
+
- http
|
|
378
|
+
- https
|
|
379
|
+
default: https
|
|
380
|
+
hostname:
|
|
381
|
+
default: localhost:8008
|
|
382
|
+
basePath:
|
|
383
|
+
default: /_matrix/client/v3
|
|
384
|
+
components:
|
|
385
|
+
securitySchemes:
|
|
386
|
+
accessTokenQuery:
|
|
387
|
+
$ref: definitions/security.yaml#/accessTokenQuery
|
|
388
|
+
accessTokenBearer:
|
|
389
|
+
$ref: definitions/security.yaml#/accessTokenBearer
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
# Copyright 2016 OpenMarket Ltd
|
|
2
|
+
# Copyright 2022 The Matrix.org Foundation C.I.C.
|
|
3
|
+
#
|
|
4
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
# you may not use this file except in compliance with the License.
|
|
6
|
+
# You may obtain a copy of the License at
|
|
7
|
+
#
|
|
8
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
#
|
|
10
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
# See the License for the specific language governing permissions and
|
|
14
|
+
# limitations under the License.
|
|
15
|
+
openapi: 3.1.0
|
|
16
|
+
info:
|
|
17
|
+
title: Matrix Client-Server Account Deactivation API
|
|
18
|
+
version: 1.0.0
|
|
19
|
+
paths:
|
|
20
|
+
/account/deactivate:
|
|
21
|
+
post:
|
|
22
|
+
summary: Deactivate a user's account.
|
|
23
|
+
description: |-
|
|
24
|
+
Deactivate the user's account, removing all ability for the user to
|
|
25
|
+
login again.
|
|
26
|
+
|
|
27
|
+
This API endpoint uses the [User-Interactive Authentication API](/client-server-api/#user-interactive-authentication-api).
|
|
28
|
+
|
|
29
|
+
An access token should be submitted to this endpoint if the client has
|
|
30
|
+
an active session.
|
|
31
|
+
|
|
32
|
+
The homeserver may change the flows available depending on whether a
|
|
33
|
+
valid access token is provided.
|
|
34
|
+
|
|
35
|
+
Unlike other endpoints, this endpoint does not take an `id_access_token`
|
|
36
|
+
parameter because the homeserver is expected to sign the request to the
|
|
37
|
+
identity server instead.
|
|
38
|
+
|
|
39
|
+
{{% boxes/warning %}}
|
|
40
|
+
{{% added-in v="1.18" %}} [OAuth 2.0 aware clients](/client-server-api/#oauth-20-aware-clients)
|
|
41
|
+
MUST NOT use this endpoint when the server supports the [OAuth 2.0 API](/client-server-api/#oauth-20-api).
|
|
42
|
+
Instead they MUST refer the user to the [account management URL](/client-server-api/#oauth-20-account-management),
|
|
43
|
+
if available, and MAY use the `action=org.matrix.account_deactivate`
|
|
44
|
+
parameter.
|
|
45
|
+
{{% /boxes/warning %}}
|
|
46
|
+
security:
|
|
47
|
+
- {}
|
|
48
|
+
- accessTokenQuery: []
|
|
49
|
+
- accessTokenBearer: []
|
|
50
|
+
operationId: deactivateAccount
|
|
51
|
+
requestBody:
|
|
52
|
+
content:
|
|
53
|
+
application/json:
|
|
54
|
+
schema:
|
|
55
|
+
type: object
|
|
56
|
+
properties:
|
|
57
|
+
auth:
|
|
58
|
+
description: Additional authentication information for the user-interactive
|
|
59
|
+
authentication API.
|
|
60
|
+
allOf:
|
|
61
|
+
- $ref: definitions/auth_data.yaml
|
|
62
|
+
id_server:
|
|
63
|
+
type: string
|
|
64
|
+
description: |-
|
|
65
|
+
The identity server to unbind all of the user's 3PIDs from.
|
|
66
|
+
If not provided, the homeserver MUST use the `id_server`
|
|
67
|
+
that was originally use to bind each identifier. If the
|
|
68
|
+
homeserver does not know which `id_server` that was,
|
|
69
|
+
it must return an `id_server_unbind_result` of
|
|
70
|
+
`no-support`.
|
|
71
|
+
example: example.org
|
|
72
|
+
erase:
|
|
73
|
+
x-addedInMatrixVersion: "1.10"
|
|
74
|
+
type: boolean
|
|
75
|
+
description: |-
|
|
76
|
+
Whether the user would like their content to be erased as
|
|
77
|
+
much as possible from the server.
|
|
78
|
+
|
|
79
|
+
Erasure means that any users (or servers) which join the
|
|
80
|
+
room after the erasure request are served redacted copies of
|
|
81
|
+
the events sent by this account. Users which had visibility
|
|
82
|
+
on those events prior to the erasure are still able to see
|
|
83
|
+
unredacted copies. No redactions are sent and the erasure
|
|
84
|
+
request is not shared over federation, so other servers
|
|
85
|
+
might still serve unredacted copies.
|
|
86
|
+
|
|
87
|
+
The server should additionally erase any non-event data
|
|
88
|
+
associated with the user, such as [account data](/client-server-api/#client-config)
|
|
89
|
+
and [contact 3PIDs](/client-server-api/#adding-account-administrative-contact-information).
|
|
90
|
+
|
|
91
|
+
Defaults to `false` if not present.
|
|
92
|
+
required: true
|
|
93
|
+
responses:
|
|
94
|
+
"200":
|
|
95
|
+
description: The account has been deactivated.
|
|
96
|
+
content:
|
|
97
|
+
application/json:
|
|
98
|
+
schema:
|
|
99
|
+
type: object
|
|
100
|
+
properties:
|
|
101
|
+
id_server_unbind_result:
|
|
102
|
+
type: string
|
|
103
|
+
enum:
|
|
104
|
+
- success
|
|
105
|
+
- no-support
|
|
106
|
+
description: |-
|
|
107
|
+
An indicator as to whether or not the homeserver was able to unbind
|
|
108
|
+
the user's 3PIDs from the identity server(s). `success` indicates
|
|
109
|
+
that all identifiers have been unbound from the identity server while
|
|
110
|
+
`no-support` indicates that one or more identifiers failed to unbind
|
|
111
|
+
due to the identity server refusing the request or the homeserver
|
|
112
|
+
being unable to determine an identity server to unbind from. This
|
|
113
|
+
must be `success` if the homeserver has no identifiers to unbind
|
|
114
|
+
for the user.
|
|
115
|
+
example: success
|
|
116
|
+
required:
|
|
117
|
+
- id_server_unbind_result
|
|
118
|
+
"401":
|
|
119
|
+
description: The homeserver requires additional authentication information.
|
|
120
|
+
content:
|
|
121
|
+
application/json:
|
|
122
|
+
schema:
|
|
123
|
+
$ref: definitions/auth_response.yaml
|
|
124
|
+
"429":
|
|
125
|
+
description: This request was rate-limited.
|
|
126
|
+
content:
|
|
127
|
+
application/json:
|
|
128
|
+
schema:
|
|
129
|
+
$ref: definitions/errors/rate_limited.yaml
|
|
130
|
+
tags:
|
|
131
|
+
- Account management
|
|
132
|
+
servers:
|
|
133
|
+
- url: "{protocol}://{hostname}{basePath}"
|
|
134
|
+
variables:
|
|
135
|
+
protocol:
|
|
136
|
+
enum:
|
|
137
|
+
- http
|
|
138
|
+
- https
|
|
139
|
+
default: https
|
|
140
|
+
hostname:
|
|
141
|
+
default: localhost:8008
|
|
142
|
+
basePath:
|
|
143
|
+
default: /_matrix/client/v3
|
|
144
|
+
components:
|
|
145
|
+
securitySchemes:
|
|
146
|
+
accessTokenQuery:
|
|
147
|
+
$ref: definitions/security.yaml#/accessTokenQuery
|
|
148
|
+
accessTokenBearer:
|
|
149
|
+
$ref: definitions/security.yaml#/accessTokenBearer
|