Skip to content

MCP server fails to fetch Figma file data due to missing fetch in Node.js environment #67

@chienchuanw

Description

@chienchuanw

Describe the bug
When attempting to fetch Figma file data using the MCP server, the operation fails with the following error message:
Error fetching file: Error: The MCP server is being run in a Node.js environment where fetch is not available. You won't be able to access any data related to the Figma file.

To Reproduce
Steps to reproduce the behavior:

  1. Start the MCP server using Node.js
  2. Trigger a Figma-related action (e.g., fetching file or node)
  3. Observe the error in the console output

Expected behavior
The MCP server should successfully fetch the Figma file data, given a valid fileKey and nodeId.

Screenshots
Image
Image

Server Configuration
Provide your MCP JSON configuration, if applicable. E.g.

   "figma-developer-mcp": {
  "command": "npx",
  "args": [
    "figma-developer-mcp",
    "--figma-api-key=REDACTED",
    "--stdio"
  ]
}

Command Line Logs

> npx figma-developer-mcp --figma-api-key=REDACTED

Configuration:
- FIGMA_API_KEY: ****8pXg (source: cli)
- PORT: 3333 (source: default)

Initializing Figma MCP Server in HTTP mode on port 3333...
HTTP server listening on port 3333
SSE endpoint available at http://localhost:3333/sse
Message endpoint available at http://localhost:3333/messages
New SSE connection established

MCP Logs
mcp-server-Framelink Figma MCP.log

Additional context
Add any other context about the problem here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions