Currently, it seems impossible to filter conversations retrieved via the listConversations method of the @botpress/client library using the botpressId (userId) of a specific user. This creates an issue in scenarios where multiple users interact with the bot because, when I fetch conversations on the client side, I see conversations not only from the targeted user but also from others.
Even when providing the user's access token as a parameter, I still see all conversations from all users, instead of just the ones associated with the specific user linked to the token.
The following workflow highlights this limitation:
I created a user via Botpress and successfully retrieved their associated botpressId.
Using this user, I can initiate conversations with no issues via @botpress/chat.
However, when I try to fetch only the conversations associated with this specific user, there is no parameter available in listConversations to filter by botpressId, and providing the user's access token doesn’t seem to limit the retrieved conversations.
Adding a filtering parameter for botpressId or ensuring that the access token restricts access to the correct conversations would greatly enhance the ability to retrieve user-specific data, improving clarity, security, and efficiency in client-side integrations.
Is there any plan to introduce this feature, or is there an alternative way to achieve such filtering?