Skip to main content
Action represents a single request or query your application wants to make in an external application. For example, “Create a task”, “Get list of users”, or “Send a message”. Here is an example of an action:

Action Structure

Action has the following properties:
  • inputSchemaData Schema describing the payload that will be validated when you run the action.
  • type – action type that maps to a Function Type that implements the run function of this action.
  • config – implementation of the run function.
  • outputSchema - defines expected output of the action.
  • customOutputSchema - overrides the default value of outputSchema. If customOutputSchema is set, outputSchema will always equal customOutputSchema

Run Function

Action interface provides one function: Run. The implementation of this function is configured with two properties: type and config. The run function receives the following arguments:
  • input - action input provided when running the action.
Action types map to Function Types and let you choose how action’s run function is implemented. If not sure what action type to use, Javascript is the most versatile type that lets you do anything, and API Request to External App is commonly used to configure API requests if it’s all that action needs to do.
TypeDescriptionFunction Type
run-javascriptRuns custom JavaScript (or TypeScript) codeJavaScript
api-request-to-external-appMakes API requests to the external app with authentication applied automaticallyAPI Request to External App
api-request-to-your-appMakes API requests to your Internal APIAPI Request to Your App
http-requestMakes arbitrary HTTP requests to any endpointHTTP Request

Using Actions

Action has only one function: run. To run an action, you need to provide an input that matches its inputSchema. As a result, you will get an output that matches its outputSchema. All the action runs are recorded as Action Run Logs. See full API reference here: Actions API Reference.

API Operations

OperationMethodEndpointDescription
ActPOST/actRun an action (canonical run path)
List all actionsGET/actionsRetrieve all workspace actions
Get action by IDGET/actions/{selector}Get specific action details
Create a new actionPOST/actionsCreate a new workspace action
Replace actionPUT/actions/{selector}Replace action configuration
Patch actionPATCH/actions/{selector}Update action partially
Clone actionPOST/actions/{selector}/cloneClone an existing action
Run actionPOST/actions/{selector}/runExecute an action (deprecated — use /act)
Reset actionPOST/actions/{selector}/resetReset action to default state
Export actionGET/actions/{selector}/exportExport action configuration
Get action dependenciesGET/actions/{selector}/dependenciesGet action dependencies
Restore actionPOST/actions/{selector}/restoreRestore archived action
Refresh actionsPOST/actions/refreshRefresh action definitions
Archive actionDELETE/actions/{selector}Archive an action