The example shows how to create a custom operation in a flow service and use it to
generate a Salesforce CRM backend account.
About this task
webMethods Integration
includes predefined connectors that contain SaaS provider-specific information that is necessary to
connect to a particular SaaS provider. Each connector uses an account to establish a connection with
the provider's backend and run tasks. Each connector includes a predefined set of tasks. Custom
tasks can also be created when you create a flow service.
Procedure
- After you log in, select a project or create a new project where you want to create the flow
service.
- Click the Flow services tab, then click
Plus icon.
- Provide a name, such as SalesforceCreateAccountCustom and a description
for the new flow service.
- In the rectangular box, type Salesforce , select Salesforce
CRM, and then select Add Custom Operation.
- On the Connect to account page, select the supported authentication type
and the Salesforce CRM account that is created from the drop-down list. Provide a name and
description of the custom operation.
- Select Create operation.
Note that for REST-based connectors, after selecting the operation, you can click
Headers to add input Headers, if required.
webMethods Integration displays the
default HTTP transport headers for the operation, along with their default values. At run time,
while processing the headers,
webMethods Integration substitutes the values as necessary. To customize the headers, do the following:
You can also customize the parameters for REST-based connectors after
selecting the operation, by clicking the Parameter option. Review the operation parameter details. IBM® webMethods integration displays the parameter Name and Description, the data
type used to represent the kind of information the parameter can hold, the
parameterization type of the request, and the default value that is needed to access the
operation. To specify a default value for the parameter, click the
icon and then type or paste the
default value. The default value is used at run time. You cannot add or delete request parameters.
You can modify the default value of a parameter. All parameters appear in the signature.
Now, go back to our example. 7. After you select the Create operation,
click Next, then select the Business Object Account.
Business Objects appear only for certain connectors and operations.
- Select the data fields and confirm the action to create the custom operation. Data fields appear
only for certain connectors and operations.
- On the Flow Editor, click the I/O icon to
define the input and output fields.
- Create two input fields, AccountName and
CityName.
- Click Mapping icon to edit the flow service mapping. Only fields
that are selected earlier are shown in the input page.
- Save the flow service and click Run. Provide the custom field
values in the AccountName and CityName fields, for
example, Software
What to do next
View the flow service execution results of the flow service after a successful run.