Skip to content
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

Bulk sending messages to things/features via search (RQL) filter #1420

Open
thjaeckle opened this issue Jul 27, 2022 · 0 comments
Open

Bulk sending messages to things/features via search (RQL) filter #1420

thjaeckle opened this issue Jul 27, 2022 · 0 comments
Labels
outlook something which could be done in the future

Comments

@thjaeckle
Copy link
Member

Similar to #1419 it could be quite easy to formulate and perform a "bulk" message sending API call which:
a) selects a set of targeted things or features
b) sends the same message to all of them

Example:

  • toggle all of the "switchable" features currently being "on" of things in a home ("leaving home" use case)

Example HTTP API

POST /api/2/bulk/features/inbox/messages/toggle?filter=
  and(
    eq(/attributes/homeName,'My-At-Home'),
    eq(definition,'https://eclipse.github.io/ditto-examples/wot/models/switchable-1.0.0.tm.jsonld'),
    eq(properties/on,true)
  )

This API would need a way to search on features and not on things.
And the filter would have to be able to address both things payload (maybe in an absolute way like /attributes/homeName) and relative feature payload (maybe in a relative way like definition or properties/on).

@thjaeckle thjaeckle added the outlook something which could be done in the future label Jul 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
outlook something which could be done in the future
Projects
None yet
Development

No branches or pull requests

1 participant