https://prefect.io logo
#prefect-community
Title
# prefect-community
s

Sandip Viradiya

06/06/2022, 11:43 PM
Hello fellas, I’m looking for a solution that can change a Prefect task state from outside, like using a post request from Postman to change a running Prefect task state from running to Success, do you know there could be a good option for this, thank you.
1
k

Kevin Kho

06/07/2022, 12:40 AM
For 1.0 or 2.0?
s

Sandip Viradiya

06/07/2022, 12:43 AM
2.0
k

Kevin Kho

06/07/2022, 12:46 AM
There is an API route that let’s you change the state but I don’t have an immediate example. I’d need to dig a bit
a

Anna Geller

06/07/2022, 1:17 PM
@Sandip Viradiya could you explain what are you trying to do here? why do you want to do it this way?
s

Sandip Viradiya

06/07/2022, 11:57 PM
Hey fellas, so I was trying to change a state of the flow run from any state to "Success" and trigger another job from AWS. I got a workaround using different approach. But thanks you @Kevin Kho and @Anna Geller for the help. Much appreciated 🙂
k

Kevin Kho

06/07/2022, 11:59 PM
What approach did you end up using? Would like to know
s

Sandip Viradiya

06/08/2022, 12:02 AM
I used the event driven approach with AWS lambda as explained https://medium.com/the-prefect-blog/event-driven-workflows-with-aws-lambda-2ef9d8cc8f1a
k

Kevin Kho

06/08/2022, 12:05 AM
Ah I see
4 Views