Web Services Before/After Operation Rule
Warning
When creating custom rules, verify that any log events that contain sensitive data are removed. If you add custom log events for testing while creating custom rules, they may expose sensitive data in the log files.
Web Services Connector uses the following operation rules:
You can create Before and After Operation rules through the Create Connector Rule as well as update it through Update Connector Rule.
{
"description": "The Web Services connector will call this rule before performing ANY defined operation.\nThis rule can be used to add/update values in the endpoint object before performing the operation and/or add persistent values to the application's data.",
"type": "WebServiceBeforeOperationRule",
"signature": {
"input": [
{
"name": "application",
"description": "The application associated with the operation being processed.",
"type": null
},
{
"name": "requestEndPoint",
"description": "The current request information containing the header, body, context url, method type, response attribute map, and response code. \nThis object can be modified directly and returned by the rule to update the endpoint information \n that is used by the current operation",
"type": null
},
{
"name": "oldResponseMap",
"description": "earlier response object ",
"type": null
},
{
"name": "restClient",
"description": "REST Client Object",
"type": null
},
{
"name": "provisioningPlan",
"description": "A ProvisioningPlan object containing the payload of the http request. A provisioning plan has an account request which defines the operation to be performed on the account. \n An account request can contain multiple attribute requests and each attribute request represents an operation on a single account attribute.",
"type": null
},
{
"name": "partition",
"description": "If applicable, a Partition object with the current aggregation's partitioning information.",
"type": null
}
],
"output": {
"name": "Map",
"description": "An updated or unmodified 'requestEndPoint' object. If application object modifications are desired, create a map containing keys 'updatedEndPoint' and 'connectorStateMap' and use it as the return value; \n Within the new map, the 'updatedEndPoint' can be set to an updated or unmodified 'requestEndPoint' object. \nThe 'connectorStateMap' will be saved as persistent values in the application definition.",
"type": null
}
},
"sourceCode": {
"version": "1.0",
"script": "// source code"
},
"attributes": null,
"id": "2b9280857b252a16017130d8a7756f24",
"name": "Before Operation Rule Template for Web Services Connector",
"created": "2021-08-10T15:57:58.005Z",
"modified": "2023-01-30T10:47:42.124Z"
}
Note
You need to add the beforeRule
as explained in SailPoint's Rule Guide to use the Web Service Before Operation Rule.
{
"description": "The Web Services connector will call this rule after performing ANY defined operation. \nThis rule can be used to update the parsed resource object and/or add persistent values to the application's data. ",
"type": "WebServiceAfterOperationRule",
"signature": {
"input": [
{
"name": "application",
"description": "The application whose data file is being processed.",
"type": null
},
{
"name": "requestEndPoint",
"description": "The current request information contain header, body ,response object",
"type": null
},
{
"name": "processedResponseObject",
"description": "Response Object processed by the Web services connector",
"type": null
},
{
"name": "rawResponseObject",
"description": "Response Object returned from the end system",
"type": null
},
{
"name": "restClient",
"description": "REST Client Object",
"type": null
}
],
"output": {
"name": "Map",
"description": "A newly created map containing a 'data' key and optionally, a 'connectorStateMap' key. The 'data' value should be set to a map containing a parsed list of accounts/groups.\nThe 'connectorStateMap' value can be set to a map containing values that will be persisted to the application definition.",
"type": null
}
},
"sourceCode": {
"version": "1.0",
"script": "\nimport sailpoint.object.ResourceObject;\nimport java.util.ArrayList;\nimport java.util.Collection;\nimport java.util.Collections;\nimport java.util.HashMap; "
},
"attributes": null,
"id": "2c9180857b252a16017b30c8e75c6e23",
"name": "After Operation Rule Template for Web Services Connector",
"created": "2021-08-10T15:57:57.980Z",
"modified": "2021-08-31T08:14:12.647Z"
}
Note
You need to add the afterRule
as explained in SailPoint's Rule Guide to use Web Service After Operation Rule.