This endpoint will allow clients to search messages within a given conversation.
- Request params (room/group):
:to_id, :to_type, :query. - Request params (user):
:conversation,:query. - If the query parameter is omitted from the request, it should behave exactly like the messages endpoint. Similarly, if the toggle and/or permission are disabled, it'll behave just like the messages endpoint does, without search filtering.
- If the necessary parameters are included: return a
200, with a collection of messages that match the query. The response JSON should match the existing format exactly.