Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
bb1c10b
wip snapshot, decouple logic, split stdio cli, http server and prepare
MQ37 Apr 1, 2025
03d772c
lint
MQ37 Apr 2, 2025
0ccc995
improve
MQ37 Apr 2, 2025
4c1e3df
expose lib
MQ37 Apr 2, 2025
255b91d
split tools, add call for internal tools, prepare toolkits
MQ37 Apr 2, 2025
ffc05ce
Move tool exports to toolkit modules
MQ37 Apr 3, 2025
9241f03
Refactor tool exports and update library entry points
MQ37 Apr 3, 2025
59a9e0a
remove toolkits (move to tools index), pass apify token as arg, clean…
MQ37 Apr 7, 2025
99bee44
fix stdio.js path, get Apify token from env var for stdio and standby…
MQ37 Apr 7, 2025
e0af0b1
export helper functions, fix typos and minor issues
MQ37 Apr 7, 2025
0697fc2
tsconfig remove root dir
MQ37 Apr 7, 2025
e982411
Refactor actor run data handling by moving logic to getActorRunData f…
MQ37 Apr 7, 2025
ca13d54
split actors.ts
MQ37 Apr 7, 2025
2c7edaf
fix test imports
MQ37 Apr 7, 2025
f8ad397
simplify mcp server class, move to actors/call.ts
MQ37 Apr 7, 2025
204b358
decouple processParamsAndUpdateTools
MQ37 Apr 7, 2025
8ed82ab
dataset push only in normal mode for debugging
MQ37 Apr 7, 2025
915faf8
add server tests
MQ37 Apr 7, 2025
f1d630d
update processParamsAndUpdateTools docs
MQ37 Apr 7, 2025
ce711e9
fix: clearly separate Actor related code and rest of the codebase. On…
jirispilka Apr 9, 2025
b78fb6b
fix: Update packages, add TODOs
jirispilka Apr 9, 2025
8735e8f
fix: lint issue
jirispilka Apr 9, 2025
6879923
fix: rename server to ActorsMcpServer
jirispilka Apr 11, 2025
af3eb35
Update src/mcp-server.ts
MQ37 Apr 11, 2025
b665a2c
remove double updateTools main.ts call, extend ApifyClient with MCP u…
MQ37 Apr 11, 2025
90b87f8
fix: deploy to npm
jirispilka Apr 11, 2025
2573e74
add default tools and load tools from url MCP server methods
MQ37 Apr 11, 2025
52ccf0c
fix wf name
MQ37 Apr 11, 2025
b0b558e
bump beta version
MQ37 Apr 11, 2025
d8e7294
chore(release): Update changelog and package version [skip ci]
Apr 11, 2025
0a836c9
move defaults from actors/ to consts in src/
MQ37 Apr 14, 2025
581f096
feat: local apify api base url (#71)
MQ37 Apr 15, 2025
a9d3b65
chore(release): Update changelog and package version [skip ci]
Apr 15, 2025
e918d26
feat: add new specification regarding json response streamable http (…
jirispilka Apr 16, 2025
95c311d
chore(release): Update changelog and package version [skip ci]
Apr 16, 2025
d8514f9
fix: lint issues, disable feat/decouple
jirispilka Apr 16, 2025
b538c04
Merge remote-tracking branch 'origin/feat/decouple' into feat/decouple
jirispilka Apr 16, 2025
28d5621
feat: Actorized MCP servers proxy (#69)
MQ37 Apr 16, 2025
b27a607
fix: merge master
jirispilka Apr 16, 2025
118f049
fix: unit-tests
jirispilka Apr 16, 2025
76eba1c
fix stream not readable and apify api url base for Actor server
MQ37 Apr 16, 2025
f5310a6
fix: logic when starting server
jirispilka Apr 17, 2025
aadd4a0
fix: server.ts
jirispilka Apr 17, 2025
5d0a84a
fix: change port to not collide with inspector
jirispilka Apr 17, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
506 changes: 506 additions & 0 deletions .actor/ACTOR.md

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions .actor/actor.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"description": "Implementation of a Model Context Protocol (MCP) Server for Apify Actors that enables AI applications (and AI agents) to interact with Apify Actors",
"version": "0.1",
"input": "./input_schema.json",
"readme": "./ACTOR.md",
"dockerfile": "./Dockerfile",
"webServerMcpPath": "/sse"
}
6 changes: 3 additions & 3 deletions .github/scripts/before-beta-release.cjs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const { execSync } = require('child_process');
const fs = require('fs');
const path = require('path');
const { execSync } = require('node:child_process');
const fs = require('node:fs');
const path = require('node:path');

const PKG_JSON_PATH = path.join(__dirname, '..', '..', 'package.json');

Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,6 @@ jobs:

- name: Test
run: npm run test

- name: Type checks
run: npm run type-check
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@ storage/key_value_stores/default/*
# Added by Apify CLI
.venv
.env
.aider*
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
22.13.1
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -179,4 +179,4 @@ All notable changes to this project will be documented in this file.
### 🐛 Bug Fixes

- Update express routes to correctly handle GET and HEAD requests, fix CI ([#5](https://github.com/apify/actors-mcp-server/pull/5)) ([ec6e9b0](https://github.com/apify/actors-mcp-server/commit/ec6e9b0a4657f673b3650a5906fe00e66411d7f1)) by [@jirispilka](https://github.com/jirispilka)
- Correct publishing of npm module ([#6](https://github.com/apify/actors-mcp-server/pull/6)) ([4c953e9](https://github.com/apify/actors-mcp-server/commit/4c953e9fe0c735f1690c8356884dd78d8608979f)) by [@jirispilka](https://github.com/jirispilka)
- Correct publishing of npm module ([#6](https://github.com/apify/actors-mcp-server/pull/6)) ([4c953e9](https://github.com/apify/actors-mcp-server/commit/4c953e9fe0c735f1690c8356884dd78d8608979f)) by [@jirispilka](https://github.com/jirispilka)
60 changes: 58 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ The server can be used in two ways:
- **🇦 [MCP Server Actor](https://apify.com/apify/actors-mcp-server)** – HTTP server accessible via Server-Sent Events (SSE), see [guide](#-mcp-server-actor)
- **⾕ MCP Server Stdio** – Local server available via standard input/output (stdio), see [guide](#-mcp-server-at-a-local-host)


You can also interact with the MCP server using a chat-like UI with 💬 [Tester MCP Client](https://apify.com/jiri.spilka/tester-mcp-client)

# 🎯 What does Apify MCP server do?
Expand Down Expand Up @@ -337,6 +336,63 @@ If you want to specify which Actors to load, you can add the `--actors` argument
}
```

#### VS Code

For one-click installation, click one of the install buttons below:

[![Install with NPX in VS Code](https://img.shields.io/badge/VS_Code-NPM-0098FF?style=flat-square&logo=visualstudiocode&logoColor=white)](https://insiders.vscode.dev/redirect/mcp/install?name=actors-mcp-server&config=%7B%22command%22%3A%22npx%22%2C%22args%22%3A%5B%22-y%22%2C%22%40apify%2Factors-mcp-server%22%5D%2C%22env%22%3A%7B%22APIFY_TOKEN%22%3A%22%24%7Binput%3Aapify_token%7D%22%7D%7D&inputs=%5B%7B%22type%22%3A%22promptString%22%2C%22id%22%3A%22apify_token%22%2C%22description%22%3A%22Apify+API+Token%22%2C%22password%22%3Atrue%7D%5D) [![Install with NPX in VS Code Insiders](https://img.shields.io/badge/VS_Code_Insiders-NPM-24bfa5?style=flat-square&logo=visualstudiocode&logoColor=white)](https://insiders.vscode.dev/redirect/mcp/install?name=actors-mcp-server&config=%7B%22command%22%3A%22npx%22%2C%22args%22%3A%5B%22-y%22%2C%22%40apify%2Factors-mcp-server%22%5D%2C%22env%22%3A%7B%22APIFY_TOKEN%22%3A%22%24%7Binput%3Aapify_token%7D%22%7D%7D&inputs=%5B%7B%22type%22%3A%22promptString%22%2C%22id%22%3A%22apify_token%22%2C%22description%22%3A%22Apify+API+Token%22%2C%22password%22%3Atrue%7D%5D&quality=insiders)

##### Manual installation

You can manually install the Apify MCP Server in VS Code. First, click one of the install buttons at the top of this section for a one-click installation.

Alternatively, add the following JSON block to your User Settings (JSON) file in VS Code. You can do this by pressing `Ctrl + Shift + P` and typing `Preferences: Open User Settings (JSON)`.

```json
{
"mcp": {
"inputs": [
{
"type": "promptString",
"id": "apify_token",
"description": "Apify API Token",
"password": true
}
],
"servers": {
"actors-mcp-server": {
"command": "npx",
"args": ["-y", "@apify/actors-mcp-server"],
"env": {
"APIFY_TOKEN": "${input:apify_token}"
}
}
}
}
}
```

Optionally, you can add it to a file called `.vscode/mcp.json` in your workspace - just omit the top-level `mcp {}` key. This will allow you to share the configuration with others.

If you want to specify which Actors to load, you can add the `--actors` argument:

```json
{
"servers": {
"actors-mcp-server": {
"command": "npx",
"args": [
"-y", "@apify/actors-mcp-server",
"--actors", "lukaskrivka/google-maps-with-contact-details,apify/instagram-scraper"
],
"env": {
"APIFY_TOKEN": "${input:apify_token}"
}
}
}
}
```

#### Debugging NPM package @apify/actors-mcp-server with @modelcontextprotocol/inspector

To debug the server, use the [MCP Inspector](https://github.com/modelcontextprotocol/inspector) tool:
Expand Down Expand Up @@ -408,7 +464,7 @@ You can launch the MCP Inspector via [`npm`](https://docs.npmjs.com/downloading-

```bash
export APIFY_TOKEN=your-apify-token
npx @modelcontextprotocol/inspector node ./dist/index.js
npx @modelcontextprotocol/inspector node ./dist/stdio.js
```

Upon launching, the Inspector will display a URL that you can access in your browser to begin debugging.
Expand Down
6 changes: 3 additions & 3 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import apify from '@apify/eslint-config';
import apifyTypeScriptConfig from '@apify/eslint-config/ts.js';

// eslint-disable-next-line import/no-default-export
export default [
{ ignores: ['**/dist', '**/.venv'] }, // Ignores need to happen first
...apify,
{ ignores: ['**/dist'] }, // Ignores need to happen first
...apifyTypeScriptConfig,
{
languageOptions: {
sourceType: 'module',
Expand Down
Loading
Loading