Open iamclaytonray opened 1 year ago
Hi @iamclaytonray Let me know if this works? You can list all triggered events either using https://docs.novu.co/api/get-messages/ or https://docs.novu.co/api/get-activity-feed/ Each item in response array will have transactionId, then you can cancel particular event using https://docs.novu.co/api/cancel-triggered-event/
I think we can find a better way of doing that, maybe allow fetching all "pending" workflows for a particular subscriberId + template identifier instead of all workflows historically. @iamclaytonray will it help you in this case?
@scopsy 's suggestion sounds good to me - I'm assuming that would be a parameter say "status" to filter by?
in this case - when ready would be good to add it to the UI as well (activity). Opening a sub issue.
Would need to do a bit more investigation on this in how best to implement this, will need to think on the technical implementation side before it is ready for work.
Sorry for not responding. Yes, that would be very helpful! I did find a way to bypass this a bit with the current API and passing some extra data to the payload. But anything along these lines would be super helpful! Thanks!
Sounds about right will add to the small batch of April.
π Feature description
I've gone through the API reference and it doesn't seem like there's an API to fetch all triggered events. Because of this, I don't know how to programmatically cancel an event.
π€ Why is this feature needed ?
My use case:
When a student books a lesson, we confirm the lesson with the pro. Then, we schedule a lesson reminder email the day before the lesson is set to take place. On occasion, due to weather or other circumstances, the lesson time has to change. However, I don't see an API to fetch all triggered events to be able to cancel that scheduled event. While the cancellation API works great, I'm sure, it's unusable to me right now.
βοΈ How do you aim to achieve this?
Code sample:
ποΈ Additional Information
I tried reaching out in Discord and Pablo recommended I create an issue here :slig
π Have you spent some time to check if this feature request has been raised before?
π’ Have you read the Code of Conduct?
Are you willing to submit PR?
None
NV-1725