girlbossceo / conduwuit

a very cool, featureful fork of conduit
https://conduwuit.puppyirl.gay/
Apache License 2.0
395 stars 48 forks source link

Please implement more client/v3/search filters: senders, not_senders #596

Open grinapo opened 4 days ago

grinapo commented 4 days ago

POST /_matrix/client/v3/search is used by Rust SDK, when doing room.messages(options) with MessagesOption and RoomEventFilter with senders field (or at least I think that's the API call).

I would use the call for the Robot to collect all past messages for deletion of a user to be very kickbanned. (The method would be searching backwards in loop until either reaching the top or the bot getting bored scrolling back without success.)

This would need working senders (and possibly its inverse: not_senders) in the filter.

(Other filters may not be hard to code the same time, but my focus is on that one now.)

(Sidenote: it seems conduwuit does not even log unsupported (and thus dropped) filter attributes. Is this intentional?)

girlbossceo commented 4 days ago

The lack of filters is an inherited thing from Conduit, it's not intentional.

grinapo commented 4 days ago

I think the same stands for GET /_matrix/client/v3/rooms/{roomId}/messages API call, using the same filtering framework. Or maybe the SDK uses this call instead, I don't know.