Workflow execution API error

1. Tag Update Conflict (409)

Endpoint: PUT /api/v1/tags/{id}

Request:

// Update existing tag with the same name
await axios.put(
  'https://n8n-instance.com/api/v1/tags/12345',
  { name: "Existing Tag Name" },
  { headers: { 'X-N8N-API-KEY': 'api_key_here' } }
);

Actual Response:

Status: 409

  "code": 409,
  "message": "Tag with this name already exists"
}

Expected: Status 200 OK with updated tag data

  1. Workflow Activation Without Valid Trigger (400)
    Endpoint: POST /api/v1/workflows/{id}/activate
    Request:
// Create workflow with manualTrigger
const workflow = {
  name: "Test Workflow",
  nodes: [
    {
      "id": "node_1",
      "name": "Manual Trigger",
      "type": "n8n-nodes-base.manualTrigger",
      "parameters": {},
      "position": [100, 300]
    },
    // Other nodes...
  ],
  "connections": {
    // Connections...
  }
};

// Create then activate
const createResponse = await axios.post(
  'https://n8n-instance.com/api/v1/workflows',
  workflow,
  { headers: { 'X-N8N-API-KEY': 'api_key_here' } }
);

await axios.post(
  `https://n8n-instance.com/api/v1/workflows/${createResponse.data.id}/activate`,
  {},
  { headers: { 'X-N8N-API-KEY': 'api_key_here' } }
);

Actual Response:

Status: 400
{
  "code": 400,
  "message": "Workflow has no node to start the workflow - at least one trigger, poller or webhook node is required"
}
  1. Execution Failures for Webhook and Manual Triggers
    Endpoint: POST /api/v1/workflows/{id}/run
    Request:
// Execute workflow with webhook or manual trigger
await axios.post(
  'https://n8n-instance.com/api/v1/workflows/12345/run',
  {},
  { headers: { 'X-N8N-API-KEY': 'api_key_here' } }
);

Actual Response (webhook):

Status: 404
{
  "code": 404,
  "message": "Not Found"
}

Response:

Status: 404
{
  "code": 404,
  "message": "Not Found"
}

Actual Response (manualTrigger):
No error, but execution does not properly activate the trigger
Expected: Status 200 OK with successful execution for all trigger types

n8n Version Information
API Version: 1.82.3

  • Database (default: SQLite): mysql
  • n8n EXECUTIONS_PROCESS setting (default: own, main): default
  • Running n8n via (Docker, npm, n8n cloud, desktop app): docker
  • Operating system: ubuntu

hello @Ivan_D

didn’t have any issues. n8n v.1.83.2

PS C:\Users\grave> $r2 = Invoke-RestMethod -Method Put -Uri $base"/tags/lKm3WHUNuDADHjoV" -Headers $auth -Body (@{'name' = "newTag2"} | ConvertTo-Json -Depth 2) -ContentType application/json

PS C:\Users\grave> $r2

id               name   
--               ----   
lKm3WHUNuDADHjoV newTag2



PS C:\Users\grave> $r2 = Invoke-RestMethod -Method Put -Uri $base"/tags/lKm3WHUNuDADHjoV" -Headers $auth -Body (@{'name' = "newTag2"} | ConvertTo-Json -Depth 2) -ContentType application/json

PS C:\Users\grave> $r2

id               name   
--               ----   
lKm3WHUNuDADHjoV newTag2



PS C:\Users\grave> $r2 = Invoke-RestMethod -Method Put -Uri $base"/tags/lKm3WHUNuDADHjoV" -Headers $auth -Body (@{'name' = "newTag2112"} | ConvertTo-Json -Depth 2) -ContentType application/json

PS C:\Users\grave> $r2

id               name       updatedAt               
--               ----       ---------               
lKm3WHUNuDADHjoV newTag2112 2025-03-17T19:43:17.077Z

What’s the issue? You can’t activate a workflow if it has only a manual trigger

There is no such endpoint :slight_smile:

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