Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feature] Campaign action for remote api call (post, put, delete, get) #854

Closed
that0n3guy opened this issue Sep 2, 2015 · 10 comments
Closed
Labels
feature A new feature for inclusion in minor or major releases ready-to-test PR's that are ready to test
Milestone

Comments

@that0n3guy
Copy link

Our current CRM has this and it is very handy. It basically allows you to send info (like a webhook) off to some service. This is very handy when combined with zapier for example.

Here is a screenshot of our CRM:
x2_remoteapicall_sms

You can define a url, method (post, get, etc..) arbitrary attributes/headers. That particular example is posting to zapier and it sends a SMS to the client.

@drmmr763
Copy link
Contributor

drmmr763 commented Sep 2, 2015

I think webhooks can do this. We kind of decided to not do campaigns in webhooks originally because it would have been a lot of repeated events (lead added / updated / points change, etc..)

What type of event would occur JUST in campaigns that we don't currently support in webhooks?

@drmmr763
Copy link
Contributor

drmmr763 commented Sep 2, 2015

Although I do like the idea of adding arbitrary headers. URL params can be done natively in webhooks.

@that0n3guy
Copy link
Author

I've not looked at the webhook functionality yet. But it seemed like a global webhook (like every time x happends, send a webhook) which would be difficult to say "only for Y campaign, do this". If you have it inside campaigns, you can do it after desicions, waits, etc...

It would be much more flexible/specific to the marketing campaign.

@that0n3guy
Copy link
Author

Oh, also. Webhooks are dependent on an event (open email, form submit, etc...). It a campaign context... I may just want to simply send a webhook not depending on anything (ie, not by an event).

@drmmr763
Copy link
Contributor

drmmr763 commented Sep 2, 2015

So a few things:

  1. I can totally see the usefulness of having campaigns interact with webhooks in someway. I'm not sure what it is yet, but definitely can be done.

But it seemed like a global webhook (like every time x happends, send a webhook) which would be difficult to say "only for Y campaign, do this". If you have it inside campaigns, you can do it after desicions, waits, etc...

In a pure context, I would call all of those things "events". A decision (or non-decision) is an event, a wait period is an event, etc... at least in symfony / webhook world.

Webhooks are dependent on an event (open email, form submit, etc...). It a campaign context... I may just want to simply send a webhook not depending on anything (ie, not by an event).

my question here would be... what would trigger the webhook to be sent in the campaign? I think this would still have to be some kind of event, but perhaps not a "user" event, but a system event. Like the examples you mentioned earlier (waits, decisions, actions etc...).

The next question would be, what information do you include in the payload for the webhook? Presumably it would be lead info?

I'm talking through it with alan a bit to see what we can come up with.

@that0n3guy
Copy link
Author

Your right... there would be an event of some kind firing the webhook. So probably a campaign action or type "webhook".

Including things lead info and submitted form data are probably the only things I can think you would want to include at this point.

Just so you know, this mixed w/ zapier is powerful. Examples of how we've used it with zapier:

  • sending SMS
  • adding leads to an excel file (google doc) for a call center to call.
  • signup for gotomeeting/gotowebinar
  • Adding person to google calendar (which then gets sent an SMS 30 min before meeting using parser.zapier.com)
  • letting our 3rd party software (non-zapier) know about lead events.

@that0n3guy
Copy link
Author

I thought I would post this here, but Eriol very generously shared his webhook/client api addon via slack that seems to handle this: https://mautic.slack.com/archives/dev/p1442502295000066

My question for the mautic team: How do you want to do this?

  • Did you want to use the existing webhooks DB for this? Maybe add a "Campaign fired event"?
  • Keep it simple and convert the addon to a plugin?
  • etc...

@alanhartless
Copy link
Contributor

I don't think we would use the existing webhooks database for this because it is structure differently for what a inline campaign action would do. We were thinking though of just making the campaign action be part of the webhooks bundle since it's kind of related. Although finding a way to "template" the campaign webhook action would be nice to prevent form having to recreate the same one over and over.

@alanhartless alanhartless added the feature A new feature for inclusion in minor or major releases label Sep 19, 2015
@mingfang
Copy link

I want to be able to have make external API calls as one of the campaign actions.
Webhooks as it is today can not be used that way.

Ideally we add new concept of API Integrations. We would register them similar to registering webhooks. Registration usually involve entering keys like for Amazon SES or having to authenticate Oauth tokens. After registration, I would then be able to choose an API Integration in the campaign action list.

Basically Mautic has the framework to do it already in the form of the "Push contact to integration" action. We just need to make it generic so that we can do "anything to integration".

@escopecz
Copy link
Sponsor Member

will be in 2.10.0

@escopecz escopecz added this to the 2.10.0 milestone Aug 16, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature A new feature for inclusion in minor or major releases ready-to-test PR's that are ready to test
Projects
None yet
Development

No branches or pull requests

5 participants