As your other programs will use the API to request (pull) data from your MySocialApp application, the "webhooks" (or "webhook API") is the way for MySocialApp to push data directly on your server when an event occurs on your app. Our example of sending a welcome mail upon user signup uses the "webhooks" feature.
Some use cases
- Send a welcome mail upon user signup
- Save every user in its CRM
- Detect bad content in realtime on every post
- Re-activate (marketing) its inactive users
- Find negative messages and notify administrators
- Know the most visited websites
- Notify administrators as an inapropriate content is published
- Send an email when a user wants to re-initialize its password
How to use "webhooks" ?
Rendez-vous on your console to setup your webhook API (API tab).
This one shares the same console as the API keys generation.
A "webhook" is composed by 3 fields:
- Event type: Type of event to send to the server, which accepts webhooks
- "new user registration": a user has just signed up on the app
- "new comment published": a new comment has just been published on a post
- "new like published": a new "like" has just been published on the post
- "new post published": a new post has just been published on a wall
- "new photo published": a new picture has just been published
- "password lost requested": a user wishes to re-initialize its password
- "new friend added": a user A has just accepted a user B as a friend
- "friend request sent": a user A wishes to be friend with a user B
- "bad content reported": a user has just reported an inapropriate content
- "user account enabled": an account has just been activated
- "user account disabled": an account has just been disactivated
- "user account accepted by an admin": an administrator has just authorized a new user to log in onto the app (option: "admin must valide registration")
- "URL link clicked": a user has just clicked on an external link in the app
- Target URL: That's here you have to add the server URL, which will receive data.
- Description: A description, in order to find out more easily if you use several "webhooks" in your application.