Freshservice

Describes how to set up an integration for sending and receiving Freshservice incidents.

Leave Feedback

Introduction

Freshservice is a cloud-based IT Help Desk and service management solution that enables organizations to simplify their IT operations. The solution offers features that include a ticketing system, self-service portal, and knowledge-base.

OpsRamp provides two-way integration between OpsRamp and Freshservice for incidents.

OpsRamp configuration

Configuration involves:

  1. Installing the integration.
  2. Configuring the integration.

Step 1: Install the integration

To install:

  1. From All Clients, select a client.
  2. Go to Setup > Integrations > Integrations.
  3. From Available Integrations, select Collaboration > Freshservice.
  4. Click Install.

Step 2: Configure the integration

Configure the following: - Inbound - Outbound - Monitoring of Integration - Audit Logs

Inbound

To send entities from Freshservice to OpsRamp:

  1. In Authentication, configure the authentication to call Freshservice APIs.
    1. Select Authentication Type Basic from the drop-down and click Save.
    2. Take note of the Tenant Id and Token. These values are used for creating and updating ticket in Freshservice.
      Inbound Configuration

      Inbound Configuration

  2. In Map Attributes, map Freshservice attributes with OpsRamp entity attributes.
    1. Select OpsRamp entity from the drop-down menu.
    2. Click Map against respective attribute, provide the mapping details, and click Save.
      Map Attributes

      Map Attributes

Outbound

To send entities from OpsRamp to Freshservice:

  1. In Integration Basic Configuration, configure notification details to trigger events defined.
    1. Notification Type: REST API
    2. Base URI: https://{subdomain}.com/helpdesk/tickets
    3. Authentication Type: Basic
    4. Click Save.
  2. In Map Attributes, map OpsRamp attributes with Freshservice attributes.
    1. Select OpsRamp entity and then click Map against the required attribute.
    2. Provide mapping values for the entity and click Save.
      Outbound Configuration

      Outbound Configuration

  3. In Integration Events, specify the event. An action performed on an entity is defined as an event. When an event is triggered, notifications are sent to the respective users.
    1. Provide name for the integration event.
    2. Select Service Desk, select Incident and then select the action type.
    3. Select Parent Configuration to assign configured basic integration details to the event.
    4. Provide end point URL.
    5. Select the web method and provide headers and payload.
      • To add additional tokens to the payload, click on the token in Place Holders list.
      •  A custom field that is already configured as response payload attribute for a given integration is not available for configuration in any other integrations. You need to remove the existing mapping from the integration to make the custom field available to map on response payload of any other integration.
    6. To parse a property returned in the response, select the property from the drop-down, provide the parsing value, and click Save.
  4. In Verify Integration, validate whether the integration is successful.
    1. Select event from the drop-down and the select the payload type.
      • JSON: Provide the JSON payloads with the values.
      • Form: Provide only the values.
    2. Provide the payload/values and click Verify.
  5. For Integration Failures: In the case of failure in integration, a message is sent to the configured email address.
    • Select the notification type Email, provide the email address, and click Save.

Integration event payloads

The following are the integration field values and event payloads for creating events.

Create ticket
Field Values
FieldsValues
Endpoint URLhttps://{subdomain}.com/helpdesk/tickets
Headers
  • Accept: application/json
  • Content-Type: application/json
MethodPOST
Authentication TypeBASIC
UsernameFreshservice username
PasswordFreshservice password
Request with hard-coded values

The following is a sample request with hard-coded values:

{
	"helpdesk_ticket" : {
		"description" : "Test ticket to verify integration",
		"subject" : "Test ticket to verify integration",
		"email" : "xxx@domain.com",
		"priority" : 1,
		"status" : 2,
		"source" : 1,
		"category_92437" : "NE NOC",
		"subcategory1_92437" : "Monitoring",
		"group_id" : "25000001317"
	}
}
Request with tokens

The following is a sample request with tokens:

{
	"helpdesk_ticket" : {
		"description" : "$incident.impact",
		"subject" : "$incident.subject",
		"email" : "xxx@domain.com",
		"priority" : "[@$incident.priority.name@]",
		"status" : "[@$incident.status.name@]"
	}
}
Response

The following is a sample response:

{
	"helpdesk_ticket": {
		"cc_email": {
			"cc_emails": [],
			"fwd_emails": [],
			"reply_cc": [],
			"tkt_cc": []
		},
		"created_at": "2014-03-05T17:23:43+05:30",
		"deleted": false,
		"delta": true,
		"description": "Some details on the issue",
		"description_html": "Details on the issue",
		"display_id": 24,
		"due_by": "2014-03-05T18:23:43+05:30",
		"email_config_id": null,
		"frDueBy": "2014-03-05T17:53:43+05:30",
		"fr_escalated": false,
		"group_id": null,
		"id": 55,
		"isescalated": false,
		"notes": [],
		"owner_id": null,
		"priority": 1,
		"requester_id": 216,
		"responder_id": null,
		"source": 2,
		"spam": false,
		"status": 2,
		"subject": "Support needed..",
		"ticket_type": "Incident",
		"to_email": null,
		"trained": false,
		"updated_at": "2014-03-05T17:23:43+05:30",
		"urgent": false,
		"status_name": "Open",
		"requester_status_name": "Being Processed",
		"priority_name": "Low",
		"source_name": "Portal",
		"requester_name": "hulk",
		"responder_name": "No Agent",
		"to_emails": null,
		"department_name": null,
		"assoc_change_id": "Getting ES3 back up to speed1",
		"assoc_problem_id": null,
		"assoc_change_cause_id": null,
		"custom_field": {},
		"attachments": []
	}
}

Freshservice configuration

Workflow Automator is used to configured Freshservice. Workflow Automator enables user to automate the repetitive tasks and manual processes that are performed on daily basis. This includes processes like assigning tickets to the right team, trigger webhooks to integrate with third-party tools, and so on.

Configuration involves creating the following workflow automators:

  1. Configuring a create incident.
  2. Configuring an update incident.

Step 1: Configure a create incident

To configure a create incident workflow automator:

  1. Login to Freshservice and go to Setting > Workflow Automator.
    Workflow Automator

    Workflow Automator

  2. On the New Automator dropdown, click Ticket.
    New Workflow Automator

    New Workflow Automator

  3. Provide required details and click Create.
    • Title: Provide a title. For example: OpsRamp Create Incident Automator
    • Description:  Description of the workflow. For example: This automator triggers the OpsRamp API to create an incident in OpsRamp.
      New Ticket

      New Ticket

  4. On the Workflow Automator page, configure the following:
    • Event: Defines when a workflow needs to be triggered.
    • Condition: Defines the parameters that need to be validated during the execution of a workflow.
    • Action: The outcome of the workflow.

Sub-step 1: Configure event

To configure event:

  1. Click Event.
  2. Provide the following details and click Done.
    • When any of these events occur: Select Incident is Raised
    • These events can be performed by: Select Anyone
Create Incident Event

Create Incident Event

Sub-step 2: Configure condition

Configure condition according to the use case. In this use case, the condition need not be configured since all the incidents from OpsRamp will be integrated.

Sub-step 3: Configure action

To configure action:

  1. Click Action and drag Action below the Event icon.
  2. Provide the following details:
    • Perform these actions on: Select Ticket Webhook
    • Request Type: Select POST
    • Callback URL: Provide the OpsRamp create incident API URL: https://{your OpsRamp domain}/api/basic/tenants/{tenantId}/incidents?vtoken={token} 
      For example: https://integration.api.try.opsramp.com/api/basic/tenants/client_1/incidents?vtoken=d75rcZ6NKdRTMlwHDIJIRCpDqTWhqMIBpUk)
      • {tenantId} – Replace with OpsRamp Tenant Id.
      • {token} – Replace with OpsRamp Token.
    • Requires Authentication: Yes (use the OpsRamp username and password)
    • Encoding: JSON
    • Select Advanced Content and provide payload. The payload is customized based on the use case.

Example payload

{
	"subject": "{{ticket.subject}}",
	"description": "{{ticket.description}}",
	"priority": "{{ticket.priority}}",
	"extTicketId": "{{ticket.id}}"
}
Create Incident

Create Incident

Step 2: Configure an update incident

To configure an update incident workflow automator:

  1. Go to Settings > Workflow Automator.
  2. From the New Automator dropdown, click Ticket.
  3. Provide the following and click Create.
    • Title: Provide a title (Example: OpsRamp Update Incident Automator)
    • Description:  Description of the work flow (Example: This automator trigger OpsRamp API to create incident in OpsRamp)
      Update Incident

      Update Incident

  4. On the Workflow Automator page, configure the following:
    • Event: Defines when a workflow needs to be triggered.
    • Condition: Defines the parameters that need to be validated during the execution of a workflow.
    • Action: The outcome of the workflow.

Sub-step 1: Configure event

To configure event:

  1. Click Event.
  2. Provide the following details and click Done.
    • When any of these events occur: Select Incident is updated
    • These events can be performed by: Select Anyone
Update Incident - Event

Update Incident - Event

Sub-step 2: Configure condition

Configure the condition according to the use case. In this use case, the condition need not be configured since all the incidents from OpsRamp will be integrated.

Sub-step 3: Configure Action

To configure action:

  1. Click Action and drag Action below the Event icon.
  2. Provide the following details:
    • Perform these actions on: Select Trigger Webhook
    • Request Type: Select POST
    • Callback URL: Provide the OpsRamp update incident API URL:  https://{your OpsRamp domain}/api/basic/tenants/{tenantId}/incidents/{{ticket.id}}??vtoken={token}&idType=external 
      For example: https://integration.api.try.opsramp.com/api/basic/tenants/client_1/incidents/{{ticket.id}}??vtoken=d75rcZ6NKdRTMlwHDRCpDqTWhfdfqMIBpUk&idType=external
      • {tenantId} – Replace with OpsRamp Tenant Id.
      • {token} – Replace with OpsRamp Token.
    • Requires Authentication: Yes (use the OpsRamp username and password)
    • Encoding: JSON
    • Select Advanced Content and provide payload. The payload is customized based on the use case.

Example payload

{
	"subject": "{{ticket.subject}}",
	"description": "{{ticket.description}}",
	"priority": "{{ticket.priority}}",
	"extTicketId": "{{ticket.id}}"
}
Action - Update Incident

Action - Update Incident