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

Click event webhooks #446

Closed
steven-tey opened this issue Nov 6, 2023 · 4 comments · Fixed by #1185
Closed

Click event webhooks #446

steven-tey opened this issue Nov 6, 2023 · 4 comments · Fixed by #1185
Labels
enhancement New feature or request

Comments

@steven-tey
Copy link
Collaborator

steven-tey commented Nov 6, 2023

A webhook callback feature to call any arbitrary API after a click is recorded (with a few defaults like Slack, email etc.)

Preferably customizable on a per-link basis.

Example use cases:

@steven-tey steven-tey added the enhancement New feature or request label Nov 6, 2023
@aakash2330
Copy link
Contributor

May I work on this ?

@VishalMCF
Copy link
Contributor

VishalMCF commented Nov 7, 2023

@steven-tey @aakash2330 Have you started working on this?? @aakash2330 if you have not need something then please free to comment.

@thinkjrs
Copy link

thinkjrs commented Dec 28, 2023

This will be a game-changing feature for our firm's implementation of dub. I'm happy to help develop, let me know.

Meanwhile, here are some initial thoughts/ideas on how I could see us using this feature. I'm just getting familiar with this project as a Dub.co user, so please disregard the following if it doesn't fit!

API interface thoughts

  • POST /links: a callbackUrl parameter that takes a string URL

  • POST /links: a callbackPayload parameter that takes a JSON payload allowing the caller to specify fixed link attributes included in the webhook request. Only including properties available in the GET request is probably the way to go. I could also see this saving bandwidth all around, e.g. we would likely only be interested in a small subset of the data available from the full GET request response such as the key property

  • POST /links/bulk: same as single POST

  • GET /links: return the value of the callbackUrl and callbackPayload parameters above

  • PUT /links: edit the callbackUrl and callbackPayload parameters

UI interface thoughts

It'd be nice to edit this within the "edit" and "create link" modals, below the current Geo Targeting input field:

edit
image

create
image

Additional motivation

I think a few defaults like Zapier and IFTTT (in addition to slack and email) would be awesome, however, they're very much in the "nice to have" bucket. If (Dub) users leverage these platforms they probably know how to copy and paste the webhook from those platforms to set this up themselves.

For us, Dub links sit as part of our ads platform where an asynchronous fan-out strategy using the webhooks would be amazing. I intend to chain some lambda functions that take the webhook request from Dub and add data to our databases, send push notifications to our apps and more generally let our end users interact with their link-data in real time.

@mindninjaX
Copy link

Hi Team,

I've been exploring the functionalities of dub.co for URL shortening and tracking click-through rates. It's been quite effective for monitoring general engagement, but I'm looking to enhance the system with real-time alerts.

Currently, I'm considering integrating AWS SES for the emailing component. My question is: does the existing API support triggering an email notification upon a link click? If such a feature is available, I'd be grateful for a brief rundown on how to set it up or any resources that could guide me through the process.

I'm aiming to streamline my workflow, so having this automated notification would be incredibly beneficial. Looking forward to any insights you might have on this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants