Kaizala – How to integrate with business applications – Dynamics CRM – part4

I am sure that you have understood how we can call the Kaizala APIs from dynamics CRM along with the webhook concept to get the response from Kaizala on real-time.

As we move further, let us see actual usage of webhook in Kaizala and Dynamics CRM integration. Kaizala provides multiple webhook subscriptions such as

postman webhook

As shown in above screenshot, at the moment Kaizala provides three webhooks/ subscription APIs

  • Subscribe to all events at group level
  • Subscribe to all events at action level
  • Subscribe to all events at action level with action package id

We can subscribe to any of the above APis based on the  requirement. Let us see how to use”Subscribe to all events at group level” webhook. Below is the code we can see in the body of this subscription in Postman. If we read this, it is quite intutve.

{
“objectId”:”{{test-group-id}}”,
“objectType”:”Group”,
“eventTypes”:[
“ActionCreated”,
“ActionResponse”,
“SurveyCreated”,
“JobCreated”,
“SurveyResponse”,
“JobResponse”,
“TextMessageCreated”,
“AttachmentCreated”,
“Announcement”,
“MemberAdded”,
“MemberRemoved”,
“GroupAdded”,
“GroupRemoved”
],
“callBackUrl”:”https://requestb.in/12786un1″,
“callBackToken”:”tokenToBeVerifiedByCallback”,
“callBackContext”:”Any data which is required to be returned in callback. Current webhook data can be seen by refreshing: https://requestb.in/12786un1?inspect”
}

You have to pass the groupID for which you need to get the response. You need to keep the events on which you need a response from Kaizala. If you need response  only  when the survey is responded by anybody, then just keep the “SurveyResponse” event and remove rest of the events. If you keep the unwanted events, you would get the response for each and every event unnecessarily.

You need to replace the callbackUrl with your Url which would be registered in the Kaizala for posting the response. To test the response, you can just register the same Url and try to respond to the survey. This would post the survey response to this url and you can see the output which would get by accessing the Url.

Kaizala would post a Json file containing the data of the response and you need to access this Json file and  get the content as required by your integration.For e,g  you can store these details in Dynamics CRM or create new entity and track the responses etc.

You can view all the webhooks registered for the group by using the API “Get all webhooks” on a group and if required even unsubscribe the registered webhook by using “Unsubscribing a webhook”

we have come to end of the integration series. I am still working on how to create custom actions in Kaizala. I would share my finding about the same in my further posts.

Kindly comment in case you want me to write on something specific on the Kaizala integration, I would definitely try to respond to your comments.

Hit the like button/ follow my blog / share my blog  if you like the content.

Keep reading my blog to know more about latest Microsoft SaaS products.

What is Webhook?

Kaizala – How to integrate with business applications – Dynamics CRM – Part-3

 

 

One thought on “Kaizala – How to integrate with business applications – Dynamics CRM – part4

  1. Could you please let me know about kaizala server . where it locates and how to retrive data from kaizala server and manipulate data from kaizala server . The entire backend process of kaizala DB. Since i am totally new on kaizala app , want to explore my self on this

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.