Name

sn_reacf.DefaultRemedialActionProvider

Description

Implements extension point sn_reacf.RemedialActionEngine

Script

var DefaultRemedialActionProvider = Class.create();
DefaultRemedialActionProvider.prototype = {
  initialize: function() {},

  /**
   * @param String className - class name to check which action is being executed
   **/
  handles: function(className) {
  	return true;
  },

  /**
   * @param Object actionGr - GlideRecord reference to the action record defined in the remedial action
   * @param Object remedialActionGr - GlideRecord reference to the remedial action record
   * @return Boolean value indicating if logged-in user is authorized to execute defined action
   **/
  isAuthorized: function(actionGr, remedialActionGr) {
  	return new RemedialActionHelper().isAuthorized(remedialActionGr);
  },

  /**
   * @param Object actionGr - GlideRecord reference to the action record defined in the remedial action
   * @param Object targetRecordGr - GlideRecord reference to the the target record from remedial action execution record
   * @param JSON object actionParams - params from the remedial action execution record
   * @return JSON with attributes action_execution_table and action_execution_id
   **/
  execute: function(actionGr, targetRecordGr, actionParams) {
  	return "";
  },

  /**
   * @param Object actionRequestGr - GlideRecord reference to the action request record from the remedial action execution record
   * Checks associated action execution status and return response if available
   * @return JSON with attributes state and output Payload
   **/
  getOutput: function(actionRequestGr) {
  	return "";
  },

  type: 'DefaultRemedialActionProvider'
};

Sys ID

d8a8941a43a02110cd5b8beeaab8f28d

Offical Documentation

Official Docs: