Skip to main content

List Record Actions

GET 

/api/automation/record-actions

List the record-action workflows the current user can run on one type of record, optionally in the context of a specific record.

Required scope: settings:read

Grant this scope to your token under Settings → Developer → Personal Access Tokens.

Requires the workflows.run permission plus view permission on the resource (e.g. suppliers.show for supplier). Only published workflows whose allowed roles include the user are returned.

Query parameters

  • resource (required) - One of supplier, product, sales_order, purchase_order, customer.
  • record_id (optional, integer) - the record the actions would run on. When given, input defaults written as {{ record.<field> }} are resolved against that record, last_run is the latest run on that record, and running_on_this_record is set. Without it, last_run is the workflow's latest record-action run on any record.

Response

  • data[] - runnable workflows. button_label falls back to the workflow name. confirm = the run should be confirmed (and inputs collected) before it starts. max_records = the most records one run request may target by id (up to 500). inputs[] = the values the run accepts in inputs (types: text, number, boolean, select, date; options holds a select's values and option_labels their labels). hands_off_to = {type: "runner", template, runner_name, online, queue_depth} when the workflow hands work to an agent runner, {type: "callback"} when it waits for an external callback, else null. preview_mode = runs are rehearsals that change nothing.
  • hidden - counts only (never names) of workflows on this resource that are not listed: inactive (not published), no_role (role-restricted). preview_mode counts listed workflows that are in preview mode.
  • can_manage - whether the user may also create and edit workflows (workflows.index).
  • automation_enabled - false when automation is turned off for the account (runs will be refused with 423).

Returns 403 without the required permissions, 422 for a missing or unknown resource.

Request​

Responses​

OK

Response Headers
    Content-Type