I don't think you've presented enough information about what you're trying to do for people to provide a useful answer.
For example, how do you imagine prefect would be querying? I think it'd be helpful if you explained how exactly you'd need upstream services to interact with your prefect-defined workflow.
You should be able to use jinja with prefect the same way you'd use jinja with python in general, for example.