Skip to main content Link Menu Expand (external link) Document Search Copy Copied

auth0 actions update

Update an action.

To update interactively, use ‘auth0 actions update’ with no arguments. To update non-interactively, supply the action id, name, code, secrets and dependencies through the flags.

JSON Input (for agents and automation)

Use ‘–schema’ to print the request payload schema, then ‘–data’ to provide update data as JSON:

  • Inline JSON: –data ‘{“name”:”updated-name”,”runtime”:”node22”}’
  • From file: –data @update.json
  • From stdin: pipe data in (e.g. cat update.json auth0 actions update )

The JSON is validated against the OpenAPI schema before sending to the API.

Usage

auth0 actions update [flags]

Examples

  # Interactive mode
  auth0 actions update
  auth0 actions update <action-id>

  # Flag-based mode
  auth0 actions update <action-id> --runtime node18
  auth0 actions update <action-id> --name myaction --code "$(cat path/to/code.js)"
  auth0 actions update <action-id> --module "module_id=mod_123,module_version_id=ver_456" --json
  auth0 actions update <action-id> -n myaction -c "$(cat path/to/code.js)" -d "lodash=4.0.0" --json-compact

  # Discover the payload schema (add --json for machine-readable output)
  auth0 actions update --schema
  auth0 actions update --schema --json

  # JSON input mode (for agents and automation)
  auth0 actions update <action-id> --data '{"name":"updated-name","runtime":"node22"}'
  auth0 actions update <action-id> --data @update.json
  cat update.json | auth0 actions update <action-id>

Flags

  -c, --code string                 Code content for the action.
      --data string                 JSON payload for the operation, as a JSON string or file path (@file.json). Can also be piped via stdin.
  -d, --dependency stringToString   Third party npm module, and its version, that the action depends on. (default [])
      --force                       Skip confirmation.
      --json                        Output in json format.
      --json-compact                Output in compact json format.
  -m, --module stringArray          Action module to associate with the action, as comma-separated key=value pairs matching the API fields: module_id and module_version_id (both required, UUIDs). Can be passed multiple times to associate several modules.
  -n, --name string                 Name of the action.
  -r, --runtime string              Runtime to be used in the action.  Possible values are: node22(recommended), node18, node16, node12
      --schema                      Print the request payload schema for this command and exit. Use with --json or --json-compact for machine-readable output.
  -s, --secret stringToString       Secrets to be used in the action. (default [])

Inherited Flags

      --agent-mode      Output JSON, disable prompts and colors. Auto-enabled for AI agents; set AUTH0_AGENT_MODE=false to disable.
      --debug           Enable debug mode.
      --no-color        Disable colors.
      --no-input        Disable interactivity.
      --tenant string   Specific tenant to use.