Open vaibhavkhurana2018 opened 3 years ago
Hey @vaibhavkhurana2018
Are you talking about thread replies?
Hey @stevengill
yes i am referring to thread replies.
Use Case:
Now for getting all the threads on this we have to make multiple api calls as from what i was able to find, that the conversation.replies only takes a single ts
, if that can be taken as a list then also it will help to reduce the network api calls.
@stevengill By any chance you got the time to have a look at the above.
I have added redis as the caching mechanism for the use case tog reduce the number of calls on the api, but this still doesn't solve the purpose as with the increase in number of messages i am still reaching to a point where i am being rate limited by the api.
Description
Describe your issue here.
What type of issue is this? (place an
x
in one of the[ ]
)Requirements (place an
x
in each of the[ ]
)Currently conversation.replies method gives the list of all the replies for a given ts. But there is no way to identify or get the list of messages which have been responded.
The only way to do this at the moment is to get all the parent messages from the conversations.history method and then loop through those messages and call conversation.replies api to check if they have a reply or not. Now following this will mean that we will have to make an api call for every message, which will result in a lot of api calls.
Use case:
We need to get all the messages that someone has responded back in the last X hours.
Possible solution:
In the conversations.history method if we can add a boolean that says
has_reply
that can help in identifying all the messages with replies, then that can help a lot in reducing the number of api calls.Have a way to get all the parent messages along with their replies for a duration the downside of this will be a too heavy response body in case a message has a lot of replies, but that can be controlled by pagination i suppose.