PostHog / posthog

🦔 PostHog provides open-source web & product analytics, session recording, feature flagging and A/B testing that you can self-host. Get started - free.
https://posthog.com
Other
21.82k stars 1.3k forks source link

Workflow triggers feature #3357

Open paolodamico opened 3 years ago

paolodamico commented 3 years ago

In a general sense, this feature refers to the functionality where you can trigger certain actions outside the PostHog environment when certain actions are triggered. It extends on our current messaging webhook & Zapier functionality. This also greatly builds on our plugins functionality. It could even be seen as the data-out part of the plugins functionality.

Context

Currently if you want to create workflows based on actions taken by a user, you would have to connect Zapier (n8n coming soon) and then create workflows in there based on actions triggered on PostHog. Some examples of such workflows include:

In a general sense one key question that needs to be raised for a feature like this is whether it makes sense to build a version ourselves or to strengthen our integrations with other software that focuses on this.

Current numbers

Target user

One thing that it's particularly important to keep in mind is our target user. We're looking for the technical user, and particularly not the marketing or customer success team. The reason this is of particular importance is that for non-technical users, a key value of a feature like this comes from the built-in integrations, and it's definitely not our core to build the myriad integrations that dedicated tools that n8n or Zapier have.

Another important consideration is the question/assumption of whether technical users will have the use case for these integrations. A case could be made that these integrations are mostly targeted for business, CX, marketing, sales teams, ... which in turn require the out-of-the-box integrations previously mentioned.

Initial Ideas

What others are doing

Wireframes

This time I decided to include some wireframes to spice up the discussion and get more ideas/feedback flowing.

Workflow list

Workflow details (UI-based)

Workflow details (code-based)

Twixes commented 3 years ago

This is a cool idea, but right now I'd just… tell a user to write their own plugin. Just the "Initial Ideas" looks like a TON of work. And the first and foremost "Most basic version" point is realized by plugins already. I just don't really see how to fit this into the product right now. Think we should get other things (like actions, webhooks, plugins) right, both product and engineering-wise, before picking this thought up.

paolodamico commented 3 years ago

Re @Twixes. So as a quick preamble, I'm also leaning towards this might not be the best thing to work on right now, however I do think it's important to separate the feature discussion from a prioritization discussion. The goal of this issue is discussing potentially what the feature can do, not whether we should start building it right away (this release [#3287] I'm working on us running through a bunch of features to decide what to build next; from these discussions, we could use our new prioritization framework, to decide what to actually work on, and also depending on what stuff everyone wants to pick up).

A few additional comments,

Twixes commented 3 years ago

I think the biggest point here is making plugins fire on specific actions. That way we could make webhooks a plugin + do a lot of the stuff mentioned above. I'm not sure where to best handle that in the lifecycle of an event though. @mariusandra WDYT?

mariusandra commented 3 years ago

Cool feature, though I do agree with the sentiment that it's probably not the next thing we should work on. Mainly because there are some technical blockers that @Twixes touched upon (actions and webhooks into plugins).

Theoretically this "workflows" could even be implemented as a proper frontend plugin, but we don't have those yet either :).

posthog-bot commented 7 months ago

This issue hasn't seen activity in two years! If you want to keep it open, post a comment or remove the stale label – otherwise this will be closed in two weeks.

keithbrink commented 7 months ago

I'd still like to see this feature eventually.