# BMC Remedyforce Connector
The BMC Remedyforce connector enables the workflow designer to create, read, and update BMC Remedyforce objects.
# BMC Remedyforce Connector Configuration
To define a Remedyforce instance for workflow usage, begin by adding the connector configuration for Remedyforce. First, access the Connector Configuration from the Workflow Designer menu under "Manage", "Connector Configuration".
If one is not yet defined, add a new Remedyforce connector configuration by specifying the name, "Remedyforce.Config.xml" and clicking "Create".
Below is a template to use for Remedyforce instances.
<connector>
<scenarios>
<scenario name="_scenario_name_" baseurl="https://na91.salesforce.com/services" loginurl="https://login.salesforce.com/services/Soap/u/45.0" apiversion="1.0" salesforceversion="v45.0" username="_username_" password="_method_3_encrypted_password_" tls="true_or_false" tls11="true_or_false" tls12="true_or_false" ssl3="true_or_false)
</scenarios>
</connector>
# Defining Workflow Actions
As Remedyforce entities are configurable, the connector actions allow for specifying the details of the specific instance for the varying instance types.
Actions are managed from the Workflow Designer menu, "Manage", "Actions", "Remedyforce" category.
# Creating Remedyforce Entries
The below XML example defines an action which will call the Remedyforce API to create a Remedyforce entry, in this case an Incident:
<action name="RF.CreateGeneric" displayname="Create Incident" helptemplate="help.aspx?name=RF.CreateGeneric">
<objecttype>BMCServiceDesk__Incident__c</objecttype>
<description>Create Incident in Remedyforce</description>
<image resourcename="remedyforce-post.png" />
<handler classname="PMGSPEUtils.Remedyforce.GenericPost" assembly="Bin\PMGSPEUtils.Remedyforce.dll" />
<properties>
<property name="scenario" displayname="Scenario" type="text" helpstring="Scenario Name" mandatory="true" />
<property name="BMCServiceDesk__incidentDescription__c" includeField="true" displayname="Incident Description" type="text" helpstring="Incident Description" mandatory="true" />
<property name="BMCServiceDesk__FKCategory__c" displayname="Category" includeField="true" type="text" helpstring="Incident Category" mandatory="false" />
<property name="timeout" displayname="Web Timeout" type="text" helpstring="Timeout for web requests"></property>
<property name="results" displayname="Results Variable" type="setvariablevalue" helpstring="Variable for storing the results" mandatory="false">{ "String": true, "XmlVariable": true }</property>
<property name="errorout" displayname="Error Message Variable" type="setvariablevalue" helpstring="Variable for storing any error messages" mandatory="false" />
</properties>
<return>
<value helpstring="Successful">Success</value>
<value helpstring="Unsuccessful">Failure</value>
</return>
</action>
Below is a table of various XML element names and attributes for defining the action
Node | Description |
---|---|
action | Defines the action |
Attribute | Description |
name | A unique identifier for the action |
Attribute | Description |
displayname | The name for the action shown in the designer |
Node | Description |
---|---|
objecttype | The Remedyforce target object for the creation |
Node | Description |
---|---|
property | Any number of properties can be specified which will map to the object to create within Remedyforce. The ‘name’ attribute of the node indicates which Remedyforce field will be set and includeField="true" indicates this is a Remedyforce field to be passed into the call to be set |
# Reading Remedyforce entries
The below XML example defines an activity which will call the Remedyforce API to read an entry, in this case an Incident:
<action name="RF.GetIncident" displayname="Get Incident" helptemplate="help.aspx?name=RF.GetIncident">
<objecttype>BMCServiceDesk__Incident__c</objecttype>
<description>Get Incident in Remedyforce</description>
<image resourcename="remedyforce-get.png"/>
<handler classname="PMGSPEUtils.Remedyforce.GenericGet" assembly="Bin\PMGSPEUtils.Remedyforce.dll"/>
<properties>
<property name="scenario" displayname="Scenario" type="text" helpstring="Scenario Name" mandatory="true"/>
<property name="id" displayname="Id" type="text" helpstring="ID" mandatory="true"/>
<property name="fields" displayname="Fields" includeField="true" type="text" helpstring="csv fields to return, leave blank for all" mandatory="false"/>
<property name="timeout" displayname="Web Timeout" type="text" helpstring="Timeout for web requests"/>
<property name="results" displayname="Results Variable" type="setvariablevalue" helpstring="Variable for storing the results" mandatory="false">{ "String": true, "XmlVariable": true }</property>
<property name="errorout" displayname="Error Message Variable" type="setvariablevalue" helpstring="Variable for storing any error messages" mandatory="false"/>
</properties>
<return>
<value helpstring="Successful">Success</value>
<value helpstring="Unsuccessful">Failure</value>
</return>
</action>
Below is a table of various XML element names and attributes for defining the action
Node | Description |
---|---|
action | Defines the action |
Attribute | Description |
name | A unique identifier for the action |
Attribute | Description |
displayname | The name for the action shown in the designer |
Node | Description |
---|---|
objecttype | The Remedyforce target object for the creation |
# Updating Remedyforce entries
The below XML example defines an action which will call the Remedyforce API to update a Remedyforce entry, in this case an Incident:
<action name="RF.UpdateIncident" displayname="Update Incident" helptemplate="help.aspx?name=RF.UpdateIncident">
<objecttype>BMCServiceDesk__Incident__c</objecttype>
<description>Update Incident in Remedyforce</description>
<image resourcename="remedyforce-patch.png" />
<handler classname="PMGSPEUtils.Remedyforce.GenericPatch" assembly="Bin\PMGSPEUtils.Remedyforce.dll" />
<properties>
<property name="scenario" displayname="Scenario" type="text" helpstring="Scenario Name" mandatory="true" />
<property name="id" displayname="Incident ID" type="text" helpstring="Incident ID" mandatory="true" />
<property name="BMCServiceDesk__incidentDescription__c" includeField="true" displayname="Incident Description" type="text" helpstring="Incident Description" mandatory="false" />
<property name="BMCServiceDesk__FKCategory__c" displayname="Category" includeField="true" type="text" helpstring="Incident Category" mandatory="false" />
<property name="BMCServiceDesk__FKImpact__c" displayname="Impact" includeField="true" type="text" helpstring="Incident Impact" mandatory="false" />
<property name="BMCServiceDesk__FKPriority__c" displayname="Priority" includeField="true" type="text" helpstring="Incident Priority" mandatory="false" />
<property name="BMCServiceDesk__FKUrgency__c" displayname="Urgency" includeField="true" type="text" helpstring="Incident Urgency" mandatory="false" />
<property name="timeout" displayname="Web Timeout" type="text" helpstring="Timeout for web requests"></property>
<property name="results" displayname="Results Variable" type="setvariablevalue" helpstring="Variable for storing the results" mandatory="false">{ "String": true, "XmlVariable": true }</property>
<property name="errorout" displayname="Error Message Variable" type="setvariablevalue" helpstring="Variable for storing any error messages" mandatory="false" />
</properties>
<return>
<value helpstring="Successful">Success</value>
<value helpstring="Unsuccessful">Failure</value>
</return>
</action>
Below is a table of various XML element names and attributes for defining the action
Node | Description |
---|---|
action | Defines the action |
Attribute | Description |
name | A unique identifier for the action |
Attribute | Description |
displayname | The name for the action shown in the designer |
Node | Description |
objecttype | The Remedyforce target object for the creation |
Node | Description |
property | Any number of properties can be specified which will map to the object to update within Remedyforce. The ‘name’ attribute of the node indicates which Remedyforce field will be set and includeField="true" indicates this is a Remedyforce field to be passed into the call to be set |
# Connector Actions
As the actions are defined per above, the workflow designer will provide access from the Workflow Designer Action Palette. Below are examples of the actions which are shipped by default.
# Create Incident
Action Function:
This action will create an incident within Remedyforce.
Action Outputs:
Success
Failure
Action Properties:
Properties for the action are as follows.
Scenario - Specifies the Remedyforce instance for the action to use
By default, the action ships with the below fields to be set for the new incident.
Description
Incident Source
Open DateTime
Due DateTime
Client ID
Results Variable - This property specifies the variable which will contain the ID for newly created incident
# Get Incident
Action Function:
This action will read an incident from Remedyforce.
Action Outputs:
Success
Failure
Action Properties:
Scenario - Specifies the Remedyforce instance for the action to use.
ID - The ID of the Incident to retrieve
Fields - CSV string of fields to retrieve. Leave blank for all
Results Variable - This property specifies the variable which will contain the ID for newly created incident
# Update Incident
Action Function:
This action will update an incident within Remedyforce
Action Outputs:
Success
Failure
Action Properties:
Scenario - Specifies the Remedyforce instance for the action to use
Incident ID - The ID of the incident to update
By default, the action ships with the below fields to be set for the incident:
Incident Description
Category
Impact
Priority
Urgency
Results Variable - This property specifies the variable which will contain the update response