Raygun Webhooks Integration: Hook up external systems with Raygun Crash Reporting

| 2 min. (329 words)

Editor’s note: This article was last updated March 2017

Raygun’s Webhooks integration makes it easy for you to hook up external systems with Raygun Crash Reporting.

Webhooks are ‘user-defined HTTP callbacks’ which allow you to take actions based on events from within Raygun. For example, the Webhooks plugin will POST to the specified URL when a regular notification would occur for an error.

If we don’t have the integration you are looking for just yet, the Raygun Webhooks integration is the answer. Once successfully enabled, error notifications will be delivered to the configured URL. The Raygun and Webhooks integration will also surface all custom data and tags that the error payload contains on the Webhook response. With this, you can see, parse and use any extra state you want to send through, or correlate the error with data in your other persistence layers/services.

Here’s where to find our Webhooks integration: (For the setup instructions, head to our documentation here.)

1. Head to your Raygun Crash Reporting ‘Integrations’ menu and click on the ‘Webhook’ icon:

2. Head to the setup tab, enter the URL and hit save changes:

Once you have set a URL and enabled Webhooks for your application, every time we generate an error notification, we will also POST a JSON message to the URL you have set.

If the notification is for a new or just reoccurred error, then the payload will look like the following example:

{

 "event":"error_notification",
 "error": {
   "url":"https://app.raygun.com/error-url",
   "message":"",
   "firstOccurredOn":"2017-01-28T01:49:36Z",
   "lastOccurredOn":"2017-01-28T01:49:36Z",
   "usersAffected":1,
   "totalOccurrences":1,
   "instance": {
     "tags" : ["test", "error-page", "v1.0.1", "env:staging"],
     "affectedUser": {
       "Identifier": "a9b7d84a-c0d3-4e7e-9ded-1ec13d033846",
       "IsAnonymous": true,
       "UUID": "a9b7d84a-c0d3-4e7e-9ded-1ec13d033846"
     },
     "customData": {
       "pageName": "Error Page",
       "userLoggedIn": true
     }
   }
 },

 "application": {
   "name":"application name",
   "url":"https://app.raygun.com/application-url"
 }
}

Do you need help or have any questions about the Raygun Webhooks integration?

Get in touch with a friendly team member here.

Software intelligence benefits – what’s the real value to your team? 

Shine a light on issues in your code base with Raygun