Skip to content

Either 'milliseconds' or 'selector' must be provided, but not both. #4

@magnus919

Description

@magnus919

When using the scrape tool, all possible fields are given at once without being able to pick and choose what fields get added to the API. As a result, incompatible fields are presented.

Sample node configuration to reproduce the issue:

{
  "nodes": [
    {
      "parameters": {
        "resource": "Default",
        "operation": "Scrape A Url And Get Its Content",
        "url": "=https://arxiv.org/pdf/{{ $json.arxivId }}.pdf",
        "formats": [
          "markdown"
        ],
        "actions": {
          "items": [
            {
              "milliseconds": 5000
            }
          ]
        },
        "requestOptions": {}
      },
      "type": "n8n-nodes-firecrawl.fireCrawl",
      "typeVersion": 1,
      "position": [
        400,
        -100
      ],
      "id": "f6a152e1-2c4d-49b7-8b84-1eb0edd5abf4",
      "name": "Firecrawl Paper Scraper",
      "credentials": {
        "fireCrawlApi": {
          "id": "[redacted]",
          "name": "FireCrawl account"
        }
      }
    }
  ],
  "connections": {},
  "pinData": {},
  "meta": {
    "templateCredsSetupCompleted": true,
    "instanceId": "[redacted]"
  }
}

And the error from Firecrawl:

{
  "errorMessage": "Bad request - please check your parameters [item 0]",
  "errorDescription": "Request failed with status code 400",
  "errorDetails": {
    "rawErrorMessage": [
      "Request failed with status code 400"
    ],
    "httpCode": "400",
    "errorData": {
      "success": false,
      "error": "Bad Request",
      "details": [
        {
          "code": "custom",
          "message": "Either 'milliseconds' or 'selector' must be provided, but not both.",
          "path": [
            "actions",
            0
          ]
        }
      ]
    }
  },
  "n8nDetails": {
    "nodeName": "Firecrawl Paper Scraper",
    "nodeType": "n8n-nodes-firecrawl.fireCrawl",
    "nodeVersion": 1,
    "resource": "Default",
    "operation": "Scrape A Url And Get Its Content",
    "itemIndex": 0,
    "runIndex": 0,
    "time": "6/28/2025, 3:18:58 PM",
    "n8nVersion": "1.98.2 (Self Hosted)",
    "binaryDataMode": "default",
    "stackTrace": [
      "NodeApiError: Bad request - please check your parameters",
      "    at ExecuteSingleContext.httpRequestWithAuthentication (/usr/local/lib/node_modules/n8n/node_modules/.pnpm/n8n-core@file+packages+core_openai@4.78.1_encoding@0.1.13_zod@3.24.1_/node_modules/n8n-core/src/execution-engine/node-execution-context/utils/request-helper-functions.ts:1369:9)",
      "    at processTicksAndRejections (node:internal/process/task_queues:105:5)",
      "    at ExecuteSingleContext.httpRequestWithAuthentication (/usr/local/lib/node_modules/n8n/node_modules/.pnpm/n8n-core@file+packages+core_openai@4.78.1_encoding@0.1.13_zod@3.24.1_/node_modules/n8n-core/src/execution-engine/node-execution-context/utils/request-helper-functions.ts:1741:11)",
      "    at RoutingNode.rawRoutingRequest (/usr/local/lib/node_modules/n8n/node_modules/.pnpm/n8n-core@file+packages+core_openai@4.78.1_encoding@0.1.13_zod@3.24.1_/node_modules/n8n-core/src/execution-engine/routing-node.ts:568:20)",
      "    at RoutingNode.makeRequest (/usr/local/lib/node_modules/n8n/node_modules/.pnpm/n8n-core@file+packages+core_openai@4.78.1_encoding@0.1.13_zod@3.24.1_/node_modules/n8n-core/src/execution-engine/routing-node.ts:762:19)",
      "    at async Promise.allSettled (index 0)",
      "    at RoutingNode.runNode (/usr/local/lib/node_modules/n8n/node_modules/.pnpm/n8n-core@file+packages+core_openai@4.78.1_encoding@0.1.13_zod@3.24.1_/node_modules/n8n-core/src/execution-engine/routing-node.ts:273:29)",
      "    at WorkflowExecute.runNode (/usr/local/lib/node_modules/n8n/node_modules/.pnpm/n8n-core@file+packages+core_openai@4.78.1_encoding@0.1.13_zod@3.24.1_/node_modules/n8n-core/src/execution-engine/workflow-execute.ts:1282:17)",
      "    at /usr/local/lib/node_modules/n8n/node_modules/.pnpm/n8n-core@file+packages+core_openai@4.78.1_encoding@0.1.13_zod@3.24.1_/node_modules/n8n-core/src/execution-engine/workflow-execute.ts:1536:27",
      "    at /usr/local/lib/node_modules/n8n/node_modules/.pnpm/n8n-core@file+packages+core_openai@4.78.1_encoding@0.1.13_zod@3.24.1_/node_modules/n8n-core/src/execution-engine/workflow-execute.ts:2100:11"
    ]
  }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions