mirror of
https://github.com/matrix-org/matrix-spec
synced 2026-02-17 03:23:42 +01:00
Clarify SS API third party invites explanations and add more cross-API links
Signed-off-by: Kévin Commaille <zecakeh@tedomum.fr>
This commit is contained in:
parent
abb5d74a31
commit
a05e2ca182
|
|
@ -970,9 +970,8 @@ the event to other servers in the room.
|
||||||
## Third-party invites
|
## Third-party invites
|
||||||
|
|
||||||
{{% boxes/note %}}
|
{{% boxes/note %}}
|
||||||
More information about third-party invites is available in the
|
More information about third-party invites is available in the Client-Server API
|
||||||
[Client-Server API](/client-server-api) under
|
under the [Third-party invites](/client-server-api/#third-party-invites) module.
|
||||||
the Third-party Invites module.
|
|
||||||
{{% /boxes/note %}}
|
{{% /boxes/note %}}
|
||||||
|
|
||||||
When a user wants to invite another user in a room but doesn't know the
|
When a user wants to invite another user in a room but doesn't know the
|
||||||
|
|
@ -985,38 +984,41 @@ API](/identity-service-api).
|
||||||
|
|
||||||
### Cases where an association exists for a third-party identifier
|
### Cases where an association exists for a third-party identifier
|
||||||
|
|
||||||
If the third-party identifier is already bound to a Matrix ID, a lookup
|
If the third-party identifier is already bound to a Matrix ID, a [lookup
|
||||||
request on the identity server will return it. The invite is then
|
request](/identity-service-api/#post_matrixidentityv2lookup) on the identity
|
||||||
processed by the inviting homeserver as a standard `m.room.member`
|
server will return it. The invite is then processed by the inviting homeserver
|
||||||
invite event. This is the simplest case.
|
as a [standard `m.room.member` invite event](#inviting-to-a-room). This is the
|
||||||
|
simplest case.
|
||||||
|
|
||||||
### Cases where an association doesn't exist for a third-party identifier
|
### Cases where an association doesn't exist for a third-party identifier
|
||||||
|
|
||||||
If the third-party identifier isn't bound to any Matrix ID, the inviting
|
If the third-party identifier isn't bound to any Matrix ID, the inviting
|
||||||
homeserver will request the identity server to store an invite for this
|
homeserver will request the identity server to [store an invite](/identity-service-api/#invitation-storage)
|
||||||
identifier and to deliver it to whoever binds it to its Matrix ID. It
|
for this identifier and to deliver it to whoever binds it to its Matrix ID. It
|
||||||
will also send an `m.room.third_party_invite` event in the room to
|
will also send an [`m.room.third_party_invite`](/client-server-api/#mroomthird_party_invite)
|
||||||
specify a display name, a token and public keys the identity server
|
event in the room to specify a display name, a token and public keys the
|
||||||
provided as a response to the invite storage request.
|
identity server provided as a response to the invite storage request.
|
||||||
|
|
||||||
When a third-party identifier with pending invites gets bound to a
|
When a third-party identifier with pending invites gets bound to a Matrix ID,
|
||||||
Matrix ID, the identity server will send a POST request to the ID's
|
the identity server will send a request to the [`/3pid/onbind`](#put_matrixfederationv13pidonbind)
|
||||||
homeserver as described in the [Invitation
|
endpoint of the the ID's homeserver as described in the [Invitation
|
||||||
Storage](/identity-service-api#invitation-storage)
|
Storage](/identity-service-api#invitation-storage) section of the Identity
|
||||||
section of the Identity Service API.
|
Service API.
|
||||||
|
|
||||||
The following process applies for each invite sent by the identity
|
The following process applies for each invite sent by the identity
|
||||||
server:
|
server:
|
||||||
|
|
||||||
The invited homeserver will create an `m.room.member` invite event
|
The invited homeserver will create an [`m.room.member`](/client-server-api/#mroommember)
|
||||||
containing a special `third_party_invite` section containing the token
|
invite event containing a special `third_party_invite` section containing the
|
||||||
and a signed object, both provided by the identity server.
|
token and a `signed` object, both provided by the identity server.
|
||||||
|
|
||||||
If the invited homeserver is in the room the invite came from, it can
|
If the invited homeserver is in the room the invite came from, it can
|
||||||
auth the event and send it.
|
auth the event and send it.
|
||||||
|
|
||||||
However, if the invited homeserver isn't in the room the invite came
|
However, if the invited homeserver isn't in the room the invite came
|
||||||
from, it will need to request the room's homeserver to auth the event.
|
from, it will need to request the inviting homeserver to auth the event
|
||||||
|
at the [`/exchange_third_party_invite`](#put_matrixfederationv1exchange_third_party_inviteroomid)
|
||||||
|
endpoint.
|
||||||
|
|
||||||
{{% http-api spec="server-server" api="third_party_invite" %}}
|
{{% http-api spec="server-server" api="third_party_invite" %}}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue