n8n-io/n8n · error · NodeOperationError

The resource "${resource}" is not supported

Error message

The resource "${resource}" is not supported

What it means

Thrown by the AlibabaCloud node router's outer switch default branch when the 'resource' parameter does not match 'text', 'image', or 'video'. This is the top-level dispatch guard: if the resource parameter value is unrecognized, the node cannot determine which sub-operation module to load and throws immediately before processing any items.

Source

Thrown at packages/@n8n/nodes-langchain/nodes/vendors/AlibabaCloud/actions/router.ts:60

			}
			break;
		case 'video':
			switch (operation) {
				case 'textToVideo':
					execute = video.textToVideo.execute;
					break;
				case 'imageToVideo':
					execute = video.imageToVideo.execute;
					break;
				default:
					throw new NodeOperationError(
						this.getNode(),
						`The operation "${operation}" is not supported for resource "${resource}"`,
					);
			}
			break;
		default:
			throw new NodeOperationError(this.getNode(), `The resource "${resource}" is not supported`);
	}

	for (let itemIndex = 0; itemIndex < items.length; itemIndex++) {
		try {
			const executionData = await execute.call(this, itemIndex);
			returnData.push(executionData);
		} catch (error) {
			if (this.continueOnFail()) {
				returnData.push({
					json: {
						error: error instanceof Error ? error.message : String(error),
					},
					pairedItem: { item: itemIndex },
				});
				continue;
			}
			throw new NodeOperationError(this.getNode(), error, {
				itemIndex,

View on GitHub (pinned to 5ac6606e81)

Solutions

  1. Open the AlibabaCloud node in the editor and reselect the Resource dropdown — it must be 'Text', 'Image', or 'Video'.
  2. Inspect the workflow JSON and verify the 'resource' parameter matches one of: 'text', 'image', 'video'.
  3. Delete and recreate the node if the parameter cannot be corrected through the UI.

Example fix

// before — resource value not recognized by any case
// resource: 'chat'

// after — use a supported resource
// resource: 'text'
Defensive patterns

Strategy: validation

Validate before calling

const VALID_RESOURCES = ['text', 'image', 'video'];
const resource = this.getNodeParameter('resource', 0) as string;
if (!VALID_RESOURCES.includes(resource)) {
  throw new Error(`Invalid resource '${resource}'. Valid: ${VALID_RESOURCES.join(', ')}`);
}

Type guard

function isValidAlibabaCloudResource(r: string): r is 'text' | 'image' | 'video' {
  return r === 'text' || r === 'image' || r === 'video';
}

Prevention

When it happens

Trigger: The node's 'resource' parameter is set to any value other than 'text', 'image', or 'video'. This can occur after a node version change that renamed resources, when importing a workflow with a corrupt resource value, or when the resource parameter is set to a value from a different node entirely.

Common situations: Workflow JSON corruption or manual editing; node downgrade/upgrade that changed resource names; copy-paste error when building workflow definitions programmatically.

Related errors


AI-assisted analysis of n8n-io/n8n@5ac6606e81 (2026-08-12). Data as JSON: /api/errors/bdd13bd36106becd. Report an issue: GitHub.