N8N API Update workflow does not accept executionOrder setting

Describe the problem/error/question

I’m updating a set of workflows. First task is make backup copies of all flows. I’m using “get many” to get all the flows, then “Create Flow” to create the backup with the same nodes and connections with “V2” prepended to the name, and then finally I want to rename the original V1. Create does not require the settings section.

In the Update call, I give it the new name, same nodes, same connections. Settings is required so I include the settings that I retrieved from the original. But that gives me an error.

The request body looks like this:

{ "name": "V1 PROCESS FILE: Load File from S3 and Split to Chunks", <nodes and connections omitted>, "settings": {"executionOrder":"v1"}}

I think the problem is that “executionOrder” is not listed as a valid option in the API call.

IMPORTANT: The create call succeeds with no settings, and the new workflow has a v1 execution order. The update call fails if I don’t provide settings, and if I provide settings": {}, the call succeeds but it sets the executionOrder to v0.

Seems like the API needs a little care & feeding. :slight_smile:

What is the error message (if any)?

{
  "message": "request.body.settings should NOT have additional properties"
}

Please share your workflow

Share the output returned by the last node

Information on your n8n setup

  • n8n version: 1.33.1
  • Database (default: SQLite): Postgres
  • n8n EXECUTIONS_PROCESS setting (default: own, main): Depricated
  • Running n8n via (Docker, npm, n8n cloud, desktop app): Amazon EC2
  • Operating system: Amazon Linux 2023

As far as I know, that should be fixed in v1.37
@Jon correct me if I wrong

I believe that is the case, From 1.37.0 the supported options for WorkflowSettings in the API will be…

saveExecutionProgress
saveManualExecutions
saveDataErrorExecution
saveDataSuccessExecution
executionTimeout
errorWorkflow
timezone
executionOrder

1 Like

Awesome! Hopefully I’ll be able to use that when I have to create V3 from this set of workflows.

It seems however that this same error also occurs with the errorWorkflow setting. If you are here because of that, here you have the discussion about it :blush:

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.