---
title: "POST /base/{baseId}/workflow/{workflowId}/action"
method: POST
path: "/base/{baseId}/workflow/{workflowId}/action"
tags: ["automation"]
---

# POST /base/{baseId}/workflow/{workflowId}/action

`POST /base/{baseId}/workflow/{workflowId}/action`

Create a automation workflow action

## Request body

- object
  - `name` string — name of the node
  - `description` string — description of the node
  - `config` unknown
  - `parentNodeId` string, required — witch node this the parent, if not provided, it is a root node
  - `type` 'sendEmail' | 'createRecord' | 'updateRecord' | 'httpRequest' | 'getRecords' | 'aiGenerate' | 'script', required — type of action

## Response `201`

Successful created

- union
  - object
    - `name` string — name of the node
    - `description` string — description of the node
    - `config` object, required
      - `baseId` string — Once this parameter is passed in, the data will be requested as if it were from the creator themselves.
      - `tableId` string, required
      - `loopKey` object, nullable — An array variable to run the action for each item in the array.
        - `resolvable` true, required — Need be resolved to static values before running
        - `type` 'fact', required
        - `path` string — json-path syntax
        - `keyStack` string[] — save select stack
        - `params` object
          - `pipes` string[] — Pipe functions to transform the fact value
        - `fact` string, required — Fact name, actionId or triggerId
      - `fields` object, required — fields data in the record
      - `_fieldsOrder` string[]
    - `id` string, required — node id
    - `category` 'action', required
    - `testResult` object — action test result
      - `spent` number — spent time
      - `inputRaw` unknown
      - `outputRaw` unknown
      - `inputVariables` object — The variables snapshot when executed
      - `outputVariables` object — The variables snapshot when executed
      - `errorMsg` string
      - `createdTime` string, required
    - `outputVariables` object — output variables
    - `inputVariables` object — input variables
    - `createdTime` string, nullable — created time
    - `lastModifiedTime` string, nullable — last modified time
    - `type` 'createRecord', required — This Action will activate when a record is created in a table.
  - object
    - `name` string — name of the node
    - `description` string — description of the node
    - `config` object, required
      - `baseId` string — Once this parameter is passed in, the data will be requested as if it were from the creator themselves.
      - `tableId` string, required — select a table to watch
      - `recordId` union, required
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
      - `loopKey` object, nullable — An array variable to run the action for each item in the array.
        - `resolvable` true, required — Need be resolved to static values before running
        - `type` 'fact', required
        - `path` string — json-path syntax
        - `keyStack` string[] — save select stack
        - `params` object
          - `pipes` string[] — Pipe functions to transform the fact value
        - `fact` string, required — Fact name, actionId or triggerId
      - `fields` object, required — fields to update
      - `_fieldsOrder` string[]
    - `id` string, required — node id
    - `category` 'action', required
    - `testResult` object — action test result
      - `spent` number — spent time
      - `inputRaw` unknown
      - `outputRaw` unknown
      - `inputVariables` object — The variables snapshot when executed
      - `outputVariables` object — The variables snapshot when executed
      - `errorMsg` string
      - `createdTime` string, required
    - `outputVariables` object — output variables
    - `inputVariables` object — input variables
    - `createdTime` string, nullable — created time
    - `lastModifiedTime` string, nullable — last modified time
    - `type` 'updateRecord', required — This Action will activate when a record is updated in a table.
  - object
    - `name` string — name of the node
    - `description` string — description of the node
    - `config` object, required
      - `transportConfig` object — The transporter to use for the email. If not provided, the default transporter will be used.
        - `resolvable` true, required — Need be resolved to static values before running
        - `type` 'literal', required
        - `value` unknown
      - `loopKey` object, nullable — An array variable to run the action for each item in the array.
        - `resolvable` true, required — Need be resolved to static values before running
        - `type` 'fact', required
        - `path` string — json-path syntax
        - `keyStack` string[] — save select stack
        - `params` object
          - `pipes` string[] — Pipe functions to transform the fact value
        - `fact` string, required — Fact name, actionId or triggerId
      - `to` union, required
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
      - `cc` union
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
      - `bcc` union
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
      - `senderName` union
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
      - `replyTo` union
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
      - `subject` union, required
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
      - `body` union, required — Utilize markdown or HTML for rich text formatting: **bold**, _italics_, # Headings, * Bullets, <br> for line breaks.
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
    - `id` string, required — node id
    - `category` 'action', required
    - `testResult` object — action test result
      - `spent` number — spent time
      - `inputRaw` unknown
      - `outputRaw` unknown
      - `inputVariables` object — The variables snapshot when executed
      - `outputVariables` object — The variables snapshot when executed
      - `errorMsg` string
      - `createdTime` string, required
    - `outputVariables` object — output variables
    - `inputVariables` object — input variables
    - `createdTime` string, nullable — created time
    - `lastModifiedTime` string, nullable — last modified time
    - `type` 'sendEmail', required — This Action will activate when a record is created in a table.
  - object
    - `name` string — name of the node
    - `description` string — description of the node
    - `config` object, required
      - `baseId` string — Once this parameter is passed in, the data will be requested as if it were from the creator themselves.
      - `tableId` string, required — select a table to watch
      - `viewId` string — select a view to watch
      - `filter` object — get records with filter conditions
      - `skip` union
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
      - `take` union
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
    - `id` string, required — node id
    - `category` 'action', required
    - `testResult` object — action test result
      - `spent` number — spent time
      - `inputRaw` unknown
      - `outputRaw` unknown
      - `inputVariables` object — The variables snapshot when executed
      - `outputVariables` object — The variables snapshot when executed
      - `errorMsg` string
      - `createdTime` string, required
    - `outputVariables` object — output variables
    - `inputVariables` object — input variables
    - `createdTime` string, nullable — created time
    - `lastModifiedTime` string, nullable — last modified time
    - `type` 'getRecords', required — This Action will activate when a record is created in a table.
  - object
    - `name` string — name of the node
    - `description` string — description of the node
    - `config` object, required
      - `url` union, required
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
      - `method` 'get' | 'post' | 'head' | 'patch' | 'put' | 'delete', required
      - `loopKey` object, nullable — An array variable to run the action for each item in the array.
        - `resolvable` true, required — Need be resolved to static values before running
        - `type` 'fact', required
        - `path` string — json-path syntax
        - `keyStack` string[] — save select stack
        - `params` object
          - `pipes` string[] — Pipe functions to transform the fact value
        - `fact` string, required — Fact name, actionId or triggerId
      - `arrayKey` object, nullable — An array variable to generate the JSON body array for the request.
        - `resolvable` true, required — Need be resolved to static values before running
        - `type` 'fact', required
        - `path` string — json-path syntax
        - `keyStack` string[] — save select stack
        - `params` object
          - `pipes` string[] — Pipe functions to transform the fact value
        - `fact` string, required — Fact name, actionId or triggerId
      - `body` union
        - union
          - object
            - `resolvable` true, required — Need be resolved to static values before running
            - `type` 'literal', required
            - `value` unknown
          - object
            - `resolvable` true, required — Need be resolved to static values before running
            - `type` 'fact', required
            - `path` string — json-path syntax
            - `keyStack` string[] — save select stack
            - `params` object
              - …
            - `fact` string, required — Fact name, actionId or triggerId
          - object
            - `resolvable` true, required — Need be resolved to static values before running
            - `type` 'array', required
            - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
              - …
        - object[]
          - `key` union, required
            - object
              - …
            - object
              - …
            - object
              - …
            - unknown
          - `value` union, required
            - union
              - …
            - object
              - …
            - unknown
        - unknown
      - `contentType` 'multipart/form-data' | 'application/x-www-form-urlencoded' | 'text/plain' | 'application/json'
      - `headers` object[]
        - `key` union, required
          - object
            - `resolvable` true, required — Need be resolved to static values before running
            - `type` 'literal', required
            - `value` unknown
          - object
            - `resolvable` true, required — Need be resolved to static values before running
            - `type` 'fact', required
            - `path` string — json-path syntax
            - `keyStack` string[] — save select stack
            - `params` object
              - …
            - `fact` string, required — Fact name, actionId or triggerId
          - object
            - `resolvable` true, required — Need be resolved to static values before running
            - `type` 'array', required
            - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
              - …
          - unknown
        - `value` union, required
          - object
            - `resolvable` true, required — Need be resolved to static values before running
            - `type` 'literal', required
            - `value` unknown
          - object
            - `resolvable` true, required — Need be resolved to static values before running
            - `type` 'fact', required
            - `path` string — json-path syntax
            - `keyStack` string[] — save select stack
            - `params` object
              - …
            - `fact` string, required — Fact name, actionId or triggerId
          - object
            - `resolvable` true, required — Need be resolved to static values before running
            - `type` 'array', required
            - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
              - …
          - unknown
    - `id` string, required — node id
    - `category` 'action', required
    - `testResult` object — action test result
      - `spent` number — spent time
      - `inputRaw` unknown
      - `outputRaw` unknown
      - `inputVariables` object — The variables snapshot when executed
      - `outputVariables` object — The variables snapshot when executed
      - `errorMsg` string
      - `createdTime` string, required
    - `outputVariables` object — output variables
    - `inputVariables` object — input variables
    - `createdTime` string, nullable — created time
    - `lastModifiedTime` string, nullable — last modified time
    - `type` 'httpRequest', required — This Action will activate when a record is created in a table.
  - object
    - `name` string — name of the node
    - `description` string — description of the node
    - `config` object, required
      - `prompt` union, required — The prompt to be used in the LLM model.
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'literal', required
          - `value` unknown
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'fact', required
          - `path` string — json-path syntax
          - `keyStack` string[] — save select stack
          - `params` object
            - `pipes` string[] — Pipe functions to transform the fact value
          - `fact` string, required — Fact name, actionId or triggerId
        - object
          - `resolvable` true, required — Need be resolved to static values before running
          - `type` 'array', required
          - `nodes` union[], required — Array of literal and fact nodes, all value will be stringify and join together
            - union
              - …
        - unknown
      - `model` string — The model to be used in the LLM model.
      - `temperature` number — The temperature of the LLM model.
      - `attachments` object[] — The attachments to be used in the LLM model.
        - `resolvable` true, required — Need be resolved to static values before running
        - `type` 'fact', required
        - `path` string — json-path syntax
        - `keyStack` string[] — save select stack
        - `params` object
          - `pipes` string[] — Pipe functions to transform the fact value
        - `fact` string, required — Fact name, actionId or triggerId
      - `outputType` 'object' | 'string'
      - `loopKey` object, nullable — An array variable to run the action for each item in the array.
        - `resolvable` true, required — Need be resolved to static values before running
        - `type` 'fact', required
        - `path` string — json-path syntax
        - `keyStack` string[] — save select stack
        - `params` object
          - `pipes` string[] — Pipe functions to transform the fact value
        - `fact` string, required — Fact name, actionId or triggerId
      - `arrayKey` object, nullable — An array variable to generate the JSON body array for the request.
        - `resolvable` true, required — Need be resolved to static values before running
        - `type` 'fact', required
        - `path` string — json-path syntax
        - `keyStack` string[] — save select stack
        - `params` object
          - `pipes` string[] — Pipe functions to transform the fact value
        - `fact` string, required — Fact name, actionId or triggerId
    - `id` string, required — node id
    - `category` 'action', required
    - `testResult` object — action test result
      - `spent` number — spent time
      - `inputRaw` unknown
      - `outputRaw` unknown
      - `inputVariables` object — The variables snapshot when executed
      - `outputVariables` object — The variables snapshot when executed
      - `errorMsg` string
      - `createdTime` string, required
    - `outputVariables` object — output variables
    - `inputVariables` object — input variables
    - `createdTime` string, nullable — created time
    - `lastModifiedTime` string, nullable — last modified time
    - `type` 'aiGenerate', required — This Action will activate when a record is created in a table.
  - object
    - `name` string — name of the node
    - `description` string — description of the node
    - `config` object, required
      - `code` string, required — The script code to execute in the sandbox.
      - `dependencies` object[], nullable — Array of npm dependencies required for the script execution.
        - `name` string, required
        - `version` string, required
      - `fileToken` string, nullable — The compiled code file token.
      - `codeHash` string, nullable — Hash of the source code and dependencies for caching compilation results.
      - `version` number — Script version, starts from 0.
      - `integrations` object[], nullable — Array of integrations required for the script execution.
        - `id` string, required
        - `provider` 'slack', required
      - `flowChart` object, nullable — Flowchart data generated by AI analysis of the script
        - `nodes` object[], required
          - `id` string, required
          - `type` 'start' | 'end' | 'step' | 'condition' | 'loop' | 'tryCatch', required
          - `label` string, required
          - `description` string
        - `edges` object[], required
          - `source` string, required
          - `target` string, required
          - `label` string
          - `type` 'default' | 'true' | 'false' | 'error' | 'loop'
        - `codeHash` string, required
    - `id` string, required — node id
    - `category` 'action', required
    - `testResult` object — action test result
      - `spent` number — spent time
      - `inputRaw` unknown
      - `outputRaw` unknown
      - `inputVariables` object — The variables snapshot when executed
      - `outputVariables` object — The variables snapshot when executed
      - `errorMsg` string
      - `createdTime` string, required
    - `outputVariables` object — output variables
    - `inputVariables` object — input variables
    - `createdTime` string, nullable — created time
    - `lastModifiedTime` string, nullable — last modified time
    - `type` 'script', required — This action will execute script in a secure sandbox.

---

[API](https://skmtc.net/teable/apis/teable-app.md) · [All operations](https://skmtc.net/teable/apis/teable-app/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/teable/teable-app/versions/7515f3b33d79/schema)
