<style>p { margin: 0; }span.fr-emoticon.fr-emoticon-img { background-repeat: no-repeat !important; font-size: inherit; height: 1em; width: 1em; min-height: 20px; min-width: 20px; display: inline-block; margin: -0.1em 0.1em 0.1em; line-height: 1; vertical-align: middle; } span.fr-emoticon { font-weight: normal; font-family: "Apple Color Emoji", "Segoe UI Emoji", "NotoColorEmoji", "Segoe UI Symbol", "Android Emoji", "EmojiSymbols"; display: inline; line-height: 0; } blockquote { border-left: solid 2px #5e35b1; color: #5e35b1; margin-left:0; padding-left:5px;}blockquote blockquote{ border-color: #00bcd4; color: #00bcd4;}blockquote blockquote blockquote{ border-color: #43a047; color: #43a047;} table.grid{ border-collapse: collapse;} table.grid td, table.grid th { border: 1px solid #ddd;} .fr-fic.fr-dib{ display: block; margin: 5px auto;}.fr-fic.fr-dib.fr-fir{ text-align: right; margin: 5px 0 5px auto;}.fr-fic.fr-dib.fr-fil{ text-align: left; margin: 5px auto 5px 0;}.fr-fic.fr-dii{ float: none; margin: 5px auto;}.fr-fic.fr-dii.fr-fil{ float: left; margin: 5px auto;}.fr-fic.fr-dii.fr-fir{ float: right; margin: 5px auto;}img.fr-dib.fr-fir { margin-right: 0; text-align: right;}img.fr-dib.fr-fil { margin-left: 0; text-align: left;}img.fr-dib { margin: 5px auto; display: block; float: none;}img.fr-bordered { box-sizing: content-box; border: solid 5px #CCC;}img.fr-shadow { box-shadow: 10px 10px 5px 0px #cccccc;}img.fr-rounded { border-radius: 10px; -moz-border-radius: 10px; -webkit-border-radius: 10px; -moz-background-clip: padding; -webkit-background-clip: padding-box; background-clip: padding-box;}</style><p><strong>In this guide we will cover:</strong></p><p><strong>- What is the Cloudflare Integration?</strong></p><p><strong>- Setting up the Integration</strong></p><p><strong>- Customise the ticket that is logged</strong></p><p><br></p><p><br></p><p><strong><span style="font-size: 14pt;">What is the Cloudflare Integration?</span></strong></p><p>The integration between Halo and Cloudflare allows you to have notifications in Cloudflare log tickets in Halo. Allowing you to manage your Cloudflare notifications from Halo. </p><p><br></p><p>When the module for this integration is enabled in Halo, a Runbook will be added to your Halo instance, which will automate the logging of tickets for each Cloudflare notification. The runbook is already setup for you so no changes need to be made to this. A webhook will need to be created in Cloudflare the notifications you would like to log a ticket as the webhook is used to trigger the runbook in Halo.</p><p><strong><br></strong></p><p><strong>Pre-requisites</strong></p><ul><li style="font-weight: bold;"><strong>You will need a Cloudflare Pro plan to use this integration as this plan is required to use custom webhook notifications. </strong></li></ul><p><br></p><p><strong><span style="font-size: 14pt;">Setting up the Integration</span></strong></p><p>First you will need to enable the integration module. In Halo, head to configuration > integrations and enable the Cloudflare module using the '+' icon. </p><p><img src="https://halo.haloservicedesk.com/api/attachment/image?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjUxODc4M2EyLTI4MDMtNDU1ZS04OTE2LTQ3MjQ3MjViYzM5NiJ9.Phi6wPeGhtw2ld6cVwNPrepND-OL8fKwNJNUc92ShWk" class="fr-fic fr-fil fr-dib" width="321" height="161"><strong><span style="font-size: 10pt;">Fig 1. Enable integration module</span></strong></p><p><br></p><p>Now click into the integration module. </p><p><br></p><p>Here, you will be provided with a URL and secret to use for the webhook. </p><p><img src="https://halo.haloservicedesk.com/api/attachment/image?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjdlMTVjNDI4LTczMjAtNDkzYS04MmFkLWY1NGU0MGEwNjBmZiJ9.dDtZNd1HKWN9fGXP5tWueJk53VEf3On1fq0nNH-kIaU" class="fr-fic fr-fil fr-dib" width="1455" style="width: 1457px; height: 493.485px;" height="493"></p><p><strong><span style="font-size: 10pt;">Fig 2. Webhook details </span></strong></p><p><br></p><p>Copy the URL, generate a secret, then copy this. </p><p><br></p><p>Now navigate to Cloudflare.</p><p><br></p><p>In Cloudflare you will first need to create the webhook, then you can assign this webhook to various notifications to determine when it is triggered.</p><p><br></p><p>To do this, head to Notifications > Destinations > Webhooks > Create. Here give the webhook a name, and enter the URL and secret copied from Halo. </p><p><br></p><p>Now you will need to assign this webhook to a notification. Head to Notifications > Notification Policies > create new or edit an existing policy > Notification Destinations > choose the webhook you just created > Save. </p><p><br></p><p>More information on creating webhooks in Cloudflare can be found <a data-fr-linked="true" href="https://developers.cloudflare.com/notifications/get-started/configure-webhooks/" id="isPasted" target="_blank" rel="noopener noreferrer">here</a>. More information on creating notifications in Cloudflare can be found <a data-fr-linked="true" href="https://developers.cloudflare.com/notifications/get-started/" id="isPasted" target="_blank" rel="noopener noreferrer">here</a>. </p><p><br></p><p>Now when the notification in Cloudflare is triggered > webhook will trigger > runbook in Halo triggered > Ticket created in Halo containing information on the Cloudflare alert. </p><p><br></p><p><strong><span style="font-size: 14pt;">Customise the ticket that is logged</span></strong></p><p>The runbook that is added upon enabling the module will control the details of the ticket that is logged for each Cloudflare notification. This runbook can be used without any further configuration, however, if you would like to customise the properties of the ticket that is logged, you can do this by adjusting the runbook. We will run through how to do this in this section. </p><p><br></p><p>Head to Configuration > Integrations > Cloudflare > Cloudflare Ticket Creation Runbook > Flow Chart > edit the first step. </p><p><img src="https://halo.haloservicedesk.com/api/attachment/image?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjliYTVkNzgzLTUzODYtNDk4ZC1hYzU5LTk2N2Y2NmRkNDgxYiJ9.eQHGFc9a83CAZ9P0mL-z1myX6zx14Ja3K6-h1GGNWiM" class="fr-fic fr-fil fr-dib" width="606" style="width: 608px; height: 449.629px;" height="450"></p><p><strong><span style="font-size: 10pt;">Fig 3. Edit step</span></strong></p><p><br></p><p>Here, the JSON body can be adjusted to define the properties of the ticket that is logged.</p><p><img src="https://halo.haloservicedesk.com/api/attachment/image?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjY4OTBmNTk0LTViZjgtNDc0Ni1hZDI5LTgzZWI2ODljNzBiNSJ9.k3NmbuiPBsW05QH9OaeniEv7LU-U9JE7dRXHm11v7ck" class="fr-fic fr-fil fr-dib" width="1520" style="width: 1522px; height: 757.975px;" height="758"></p><p><strong><span style="font-size: 10pt;">Fig 4. JSON body controlling ticket logged</span></strong></p><p><br></p><ul><li><em>"summary": "XXX"</em> - Here you can enter the summary you would like tickets logged from Cloudflare alerts to have. </li><li><em>"details_html": <<request^text>></em> - Here, you can choose the details you would like tickets logged from Cloudflare alerts to have. By default this uses the text property of the request from Cloudflare. </li><li id="isPasted"><span style="color: rgb(0, 0, 0); font-family: sans-serif; font-size: 14px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; white-space: normal; background-color: rgb(255, 255, 255); text-decoration-thickness: initial; text-decoration-style: initial; text-decoration-color: initial; display: inline !important; float: none;" id="isPasted"><em>"</em></span><em>tickettype_id": X</em><span style="color: rgb(0, 0, 0); font-family: sans-serif; font-size: 14px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; white-space: normal; background-color: rgb(255, 255, 255); text-decoration-thickness: initial; text-decoration-style: initial; text-decoration-color: initial; display: inline !important; float: none;" id="isPasted"><em> </em></span>- Here, you can choose the ticket type you would like tickets logged from Cloudflare alerts to have. By default this uses the ticket type with ID 1. To choose another ticket type, head to the ticket type you would like to be used (under configuration), in the URL you will be able to see the ID of this ticket type. </li></ul><p style="margin-left: 60px;"><img src="https://halo.haloservicedesk.com/api/attachment/image?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjQyNjAxZTAwLTIzZmMtNGVkYS05MGFlLWIyYjJmMjQ5YmNhMSJ9.PkbhQ38FOErZrBRv_tkBA1BSkLzOu3EgQG4qyuNZ3n4" class="fr-fic fr-fil fr-dib" width="520" style="width: 522px; height: 370.656px;" height="371"></p><p style="margin-left: 60px;"><strong><span style="font-size: 10pt;">Fig 5. Ticket type ID</span></strong></p><p style="margin-left: 60px;"><br></p><p style="margin-left: 60px;">Replace the current ID value with this ID value in the JSON body. </p><p><br></p><p>Additional values can be set here too, we have included some key values in the figure 6 example.</p><p><img src="https://halo.haloservicedesk.com/api/attachment/image?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjcxNGJmODgyLTBlMWUtNGU3Ni05YmE5LTNhNjZiYjY1MGI4NyJ9.S9zEwbAFeQnrMD5SKk-DfpkBoZzK_oWqQ7AIt200IoQ" class="fr-fic fr-fil fr-dib" width="473" height="226"></p><p><strong><span style="font-size: 10pt;">Fig 7. Expanded JSON body</span></strong></p><p><br></p><p>In the figure x example the payload includes keys to set the end user of the ticket, the team assigned to the ticket and the agent assigned to the ticket. </p><p><br></p><p><strong><em>Note: Runbook variables can also be used in this payload to have the ticket created with information based on each request from Cloudflare. </em></strong></p><p><br></p><p><br></p>