basically our use case is that we’re looking to create workflows for our end users based on their prompt - we’ll build something on our end that matches actions and triggers from the pipedream component library - that’s not a problem, basically what we want to know is if there’s a way to create workflows programatically from scratch right now, like how n8n does - I notice there’s a Rest API but we need to provide a template to that. Any help or info would be appreciated, Thanks!
Hi @zaidtahir524,
Thanks for your detailed question! Here’s a step-by-step answer based on your use case:
Can you create Pipedream workflows programmatically from scratch (like n8n)?
Short answer:
Currently, Pipedream does not provide a public REST API that allows you to create arbitrary workflows from scratch (i.e., define triggers, actions, and code steps entirely via API) in the same way n8n does. The Pipedream REST API supports creating workflows from templates, but you must provide a template ID or a workflow definition that already exists.
What you can do:
- Templates: You can create workflow templates in Pipedream, then use the API to instantiate new workflows for users based on those templates. This is the main supported programmatic approach today.
- Manual Creation: For fully dynamic workflows (where you define every step on the fly), there is no public API to do this at present. All workflow definitions must be based on existing templates or created via the Pipedream UI.
Reference:
- Pipedream REST API docs – Workflows
- Pipedream Blog: How workflows are built
What does this mean for your use case?
- If you can model your workflow “blueprints” as templates, you can use the API to create new workflows for your users by referencing those templates.
- If you want to build workflows entirely from user prompts (with arbitrary triggers/actions/code), you’d need to pre-create templates for all possible combinations, or use the UI.
Is there a workaround?
- Templates + Parameters: You can make your templates as flexible as possible by using environment variables or props, then fill those in programmatically when creating workflows via the API.
- Feature Requests: If you need true programmatic workflow creation (like n8n’s JSON workflow definition), you can submit a feature request to Pipedream or upvote existing ones.
Summary
- Direct programmatic creation of arbitrary workflows from scratch is not currently supported.
- You can create workflows from templates via the REST API.
- For more dynamic needs, consider submitting a feature request or reaching out to Pipedream support.
If you have more specific requirements or want to discuss possible workarounds, feel free to ask!
For more help or to request this feature, visit Support - Pipedream.
I’m a bot powered by Pipedream and GPT-4. I’m still learning, so please double-check my answers and code! Learn how to build your own.