-
Notifications
You must be signed in to change notification settings - Fork 371
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MSC2929: Interaction events #2929
Conversation
@erkinalp the MSC number is actually |
Signed-off-by: Erkin Alp Güney <erkinalp9035@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I found this MSC confusing, I don't really understand what it wants to solve. It looks likes it targets bots, but I don't think there is any needs for new event just to send commands to bots.
I think you should add some detailed use cases.
Interactions should be responded by `target` users if and only if they understand the interaction | ||
body. | ||
|
||
Presentation of interactions to users are left implementation defined. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the presentation should be specified, so every client implements it in a common way. The users should be able to change their matrix client without having to learn new patterns.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How could I stipulate a common presentation when interaction types are implementation defined?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have now added recommended response targets for interaction responses, which will enable clients to make reasonable presentation decisions. However, as interaction subtypes are left implementation defined, I cannot exhaustively define presentation behaviour for all possible types of interaction events.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was thinking about how available interactions are presented to the user so it can use them, not about what they trigger.
Interactions should be responded by `target` users if and only if they understand the interaction | ||
body. | ||
|
||
Presentation of interactions to users are left implementation defined. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How do the clients know available interactions? We need a way to declare them. Without that this MSC is pretty useless IMHO.
Are interactions specific to a room? or to a user account?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am open to suggestion on how to specify those registration events. As I said, I started with a barebones proposal.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
They are specific to a room and a user (the user responding to the interaction). Notification wording should have clarified that.
@@ -0,0 +1,54 @@ | |||
# MSC2929: Interaction events |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This MSC does not explains how the app reacting to the interaction should be notified. Should it listen to events in the room? So it should have an user that joins the room?
I think this miss a point of slack / discord / and others integrations: their simplicity. You can do an app for slack by just writing a web server that listen on a specific endpoint. Listening to a room's events is a lot more complex.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should it listen to events in the room? So it should have an user that joins the room
Yes, it has to join the room and this is by design. Re. notification thing, I am going to address it by designing a notification system that will not require the bot to listen to all room events, but only to those interactions (bar E2EE rooms, where I deliberately omit that capability and require listening on all events). More on that soon.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it has to join the room and this is by design
So that means bots, and it excludes slash-like commands
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So that means bots, and it excludes slash-like commands
In my proposal, you would send commands to bot's "profile room" to achieve slash-like commands.
Interaction events are intended to create a standardised way for bots or other third party applications | ||
to interact with other users. IRC, Telegram, Discord solve this using slash commands in the user side. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bots and slash command (like /giphy
on slack) are two very different type of application. A bot need to have its own user and needs to join the room, while a slash command could be called from anywhere without knowing about where it is used.
I think the MSC should consider both cases. I even think the MSC should focus on slash commands and define a full protocol for them, while bots already work well (using text messages and command starting with a specific character, like "!dosomething").
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Both problems are readily solvable by clever use of rooms. MSC1769 solves the publicly visible global command thing by enabling you to post to bot's room "wall". OTOH, private commands could be DMd to the bot.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But that means any command have to implement the matrix client-server protocol (managing access token, doing sync, …). I am sure not we need it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I designed interaction events as extensible as possible. Lightweight authentication schemes you suggest will cause security nightmare with that broad capability I propose (mind you, those implementation-defined events will be allowed to target pretty much anything, response flows are also implementation defined). Therefore I cannot allow a shortcut authentication scheme like Slack apps and Discord webhooks use.
Signed-off by: Erkin Alp Güney <erkinalp9035@gmail.com>
…vents Signed-off by: Erkin Alp Güney <erkinalp9035@gmail.com>
Signed-off by: Erkin Alp Güney<erkinalp9035@gmail.com>
i'd like to signal some continued interest on my part with this MSC, as I think interactions brings a lot of power in terms of user interaction with bots. |
This MSC is declared abandoned, so a new MSC would need to be started. For process questions it is generally best to visit #matrix-spec:matrix.org on Matrix rather than asking on MSCs directly (we tend to ignore comments on closed/merged MSCs) |
Extremely simplistic and primitive design of interaction events.
Rendered