How to deal with human input from API

I have a complex pipeline where, for many steps, i need human input, thing is, this should run on a server and there is an API layer that is used to send messages to the user and get back messages to them, how can i do that? only monkey patching?

You can try using https://www.humanlayer.dev/, not sure if it suits your needs