mcp access

Local 2025-09-01 00:17:49 0
Browser Automation @shin-t-o/mcp-access

Enables text extraction from web pages and PDFs, and execution of predefined commands, enhancing content processing and automation capabilities.


tools for personal use
previous: nodejs -> deno

Settings

{
  "mcpServers": {
    "mcp-access-deno": {
      "command": "deno", // OR full-path
      "args": ["run", "-A", "PROJEC_DIR/src/index.ts"],
      "env": {}
    }
  }
}


Tools

List

  • commandExecute
  • Execute a command in the allowed list
  • getUrlToMd
  • Parse a web page into Markdown and return it
  • getPdfContent
  • Text parsing and return of PDF content

Libraries

  • createToolsServer
  • https://jsr.io/@mizchi/mcp-helper
  • https://zenn.dev/mizchi/articles/deno-mcp-server

MCP Inspector

The MCP inspector is a developer tool for testing and debugging MCP servers.

$ npx @modelcontextprotocol/inspector deno run -A src/index.ts


Trouble shooting

Workaround

pdfjs-dist

How to remove Warning: Please use thelegacybuild in Node.js environments. (since this console message inhibits MCP startup)

``js:node_modules/pdfjs-dist/build/pdf.mjs // if (isNodeJS) { // warn("Please use thelegacy` build in Node.js environments."); // }


## Exec locally

```bash
# start locally
$ deno run -A src/index.ts

# exec
$ {"jsonrpc":"2.0","id":"toolcall-1","method":"tools/call","params":{"name":"getUrlToMd","arguments":{"url":"https://code.visualstudio.com/docs/editing/intellisense"}}}

# ---
# start locally + exec + save result
$ echo '{"jsonrpc":"2.0","id":"toolcall-1","method":"tools/call","params":{"name":"getUrlToMd","arguments":{"url":"https://code.visualstudio.com/docs/editing/intellisense"}}}' | 
    deno run -A src/index.ts | 
    grep "result" | 
    jq -r '.result.content[0].text | fromjson' > example.md

[
  {
    "description": "Parses a web page into Markdown and returns it",
    "inputSchema": {
      "properties": {
        "url": {
          "description": "The URL of the web page to parse",
          "type": "string"
        }
      },
      "required": [
        "url"
      ],
      "type": "object"
    },
    "name": "get-webpage-markdown"
  },
  {
    "description": "Text parsing and return of PDF content",
    "inputSchema": {
      "properties": {
        "pdfFilePath": {
          "description": "The filepath of the PDF file to parse",
          "type": "string"
        }
      },
      "required": [
        "pdfFilePath"
      ],
      "type": "object"
    },
    "name": "get-pdf-content"
  },
  {
    "description": "Executes a command in the allowed list: ls / mkdir / cd / npm / npx / node / git / rm",
    "inputSchema": {
      "properties": {
        "command": {
          "description": "The command(command only) to execute on Windows PowerShell",
          "type": "string"
        },
        "cwd": {
          "description": "Working directory at command execution",
          "type": "string"
        }
      },
      "required": [
        "command",
        "cwd"
      ],
      "type": "object"
    },
    "name": "command-execute"
  }
]