Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Next »

Freshservice integration requires a user with a API key with enough permissions and Requester Id to create Change Requests and Incidents. The following steps will assist you getting the integration user agent details from Freshservice to setup in FlexDeploy.

Preparing for Freshservice Integration with FlexDeploy

You need to create an API key for use in FlexDeploy. The API key will be encoded using base64 before used in the request to get change request or create any new request

  1. Log into https://<domainname>.freshservice.com.

  2. Click the profile icon

  3. Click Profile Settings.

Requester Id

The Requester Id which is the id of the user. The id is in the agent url. Browse for the agent in the UI and get it from the URL of the page that you are on.

Roles

To assign the correct role for the integration agent, please follow the below steps

  • From the home screen, click the Admin

  • Under User Management, click the Agents

  • Select the agent setup for FlexDeploy integration

  • Click Edit Agent

  • Scroll down to Roles section and click Associate Roles. Use Problem Manager (Out of Box) role which elevates the user to create Change Request and Incident as well. If there is any custom roles setup in your organization, you can use that as well. Please make sure the role has access to create Change and Incident.

Now setup this user in FlexDeploy and you are all set.

Create Issue Tracking Instance

Property Name

Property Code

Required

Description

Freshservice URL

FDFS_URL

Yes

Freshservice URL (https://<your_helpdesk_domain_name>.http://freshservice.com )

Freshservice API Key

FDFS_API_KEY

Yes

API key for Freshservice

Note that encrypted properties are stored in Credential Store (Local or External) and can be configured using Edit button next to credential name drop down. Alternatively, you can reuse single credential for multiple properties also, in which case you should name that credential appropriately.

Approved Check Script

FDFS_APPROVED_SCRIPT

No

A Groovy expressions which determines whether a task for the change ticket is approved or not.  The expression must return a boolean, and has access to the following variables:

  • TICKET - an object with fields (JSON) contained in the change ticket, as returned by the Freshservice REST API.  Fields are referenced as TICKET.<field name>.<sub-field name>

  • FD_ENVIRONMENT_CODE - The environment for a particular deployment request or associated pipeline stage.

If you want to see values that can be used, enable FINEST log level for flexagon.fd.model.integration.cms.CMSScript using Admin Operations.

Rejected Check Script

FDFS_REJECTED_SCRIPT

No

A Groovy expressions which determines whether a task for a change ticket is rejected or not.  The expression must return a boolean, and as has access to the following variables:

  • TICKET - an object with fields (JSON) contained in the change ticket, as returned by the Freshservice REST API.  Fields are referenced as TICKET.<field name>.<sub-field name>

  • FD_ENVIRONMENT_CODE - The environment for a particular deployment request or associated pipeline stage.

Additional Info Script

FDFS_ADDITIONAL_INFO_SCRIPT

No

A Groovy expression which determines additional information to add to an external approval when it is approved or rejected.  The expression must return a Map<String, String> and have an entry with the key of "notes" for the value to get added to external approval as a task note. Script has access to the following variables:

  • TICKET - an object with fields (JSON) contained in the change ticket, as returned by the ServiceNow REST API.  Fields are referenced as TICKET.<field name>.<sub-field name>

  • FD_ENVIRONMENT_CODE - The environment for a particular deployment request or associated pipeline stage.

Don't poll

FDFS_DONT_POLL

No

Disable automatic polling (every minute) of Freshservice tickets for status changes. Check if using REST API to communicate status changes to FlexDeploy.

Freshservice Requester Id

FDFS_REQUESTER_ID

No

Freshservice agent id for API access(should be a number)

Freshworks Freshservice Available TICKET Variables

Within the script properties on the Freshservice Instance. The following values are available to you via the TICKET object to use in your script logic. For example, TICKETsubject would return the subject of the Freshservice change.

Field Code

Display Name

Description

Data Type

Required

subject

Subject

A subject for the change ticket

String

No

description

Description

A description for the change ticket

String

No

change_type

Change  Type

e.g. 2

Long

Yes

status

Status

e.g. 2

Long

Yes

priority

Priority

e.g. 2

Long

Yes

impact

Impact

e.g. 2

Long

Yes

requester_id

Requester Id

e.g. 21000602644

Long

Yes

risk

Risk

e.g. 2

Long

Yes

planned_start_date

Start Date

e.g. "2022-09-22T19:24:50Z"

String

Yes

planned_end_date

End Date

e.g. "2022-09-22T19:24:50Z"

String

Yes

Configure Folder for Change Management Approvals

Configure Freshservice Change Management Instance on your parent folder. Change management configurations are inherited by sub-folder and projects. This configuration will allow you to integrate Freshservice tickets with your FlexDeploy deployment. See Configure Change Management on Folders for more details.

Linking Jira ITSM with FlexDeploy Deployments

If Auto Create Ticket, is not enabled, then user must specific the change ticket number on the deployment request. See https://flexagon.atlassian.net/wiki/spaces/FD65/pages/10125813121/Link+Change+Ticket+s+with+Deployments . Otherwise, Change Ticket field will be required in the deployment request form. When change ticket number is passed the ticket number is validated on the external application.

  • No labels