From 01546bd7d0e42f00b0d406f1080969e4f7c94460 Mon Sep 17 00:00:00 2001 From: Jiri Spilka Date: Thu, 16 Jan 2025 13:51:05 +0100 Subject: [PATCH] Fix Actor input. Do not raise exception when list of Actors is empty. --- .actor/actor.json | 2 +- README.md | 8 ++++---- package.json | 2 +- src/input.ts | 3 --- 4 files changed, 6 insertions(+), 9 deletions(-) diff --git a/.actor/actor.json b/.actor/actor.json index 37f81fd0..789d422b 100644 --- a/.actor/actor.json +++ b/.actor/actor.json @@ -3,7 +3,7 @@ "name": "apify-mcp-server", "title": "Model Context Protocol Server for Apify Actors", "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.0", + "version": "0.1", "input": "./input_schema.json", "dockerfile": "./Dockerfile" } diff --git a/README.md b/README.md index 47615eaa..15450730 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,10 @@ # Apify Model Context Protocol (MCP) Server Implementation of an MCP server for all [Apify Actors](https://apify.com/store). -This server enables interaction with one or more Apify Actors that can be defined in the MCP server configuration. +This server enables interaction with one or more Apify Actors that can be defined in the MCP Server configuration. The server can be used in two ways: -- 🇦 **Apify MCP Server Actor**: runs an HTTP server supporting the MCP protocol via Server-Sent Events. +- 🇦 **Apify MCP Server Actor**: runs an HTTP server with MCP protocol via Server-Sent Events. - ⾕ **Apify MCP Server Stdio**: provides support for the MCP protocol via standard input/output stdio. # 🎯 What does Apify MCP server do? @@ -14,8 +14,8 @@ For example it can: - use [Facebook Posts Scraper](https://apify.com/apify/facebook-posts-scraper) to extract data from Facebook posts from multiple pages/profiles - use [Google Maps Email Extractor](https://apify.com/lukaskrivka/google-maps-with-contact-details) to extract Google Maps contact details - use [Google Search Results Scraper](https://apify.com/apify/google-search-scraper) to scrape Google Search Engine Results Pages (SERPs) -- use [Instagram Scraper](https://apify.com/apify/instagram-scraper) to scrape Instagram posts, profiles, places, hashtags, photos, and comments -- use [RAG Web Browser](https://apify.com/apify/web-scraper) to perform a web search, scrape the top N URLs from the results, and return content +- use [Instagram Scraper](https://apify.com/apify/instagram-scraper) to scrape Instagram posts, profiles, places, photos, and comments +- use [RAG Web Browser](https://apify.com/apify/web-scraper) to search the web, scrape the top N URLs, and return their content To interact with the Apify MCP server, you can use MCP clients such as [Claude Desktop](https://claude.ai/download), [Superinference.ai](https://superinterface.ai/), or [LibreChat](https://www.librechat.ai/). Additionally, you can use simple example clients found in the [examples](https://github.com/apify/actor-mcp-server/tree/main/src/examples) directory. diff --git a/package.json b/package.json index b0da442e..39f67394 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@apify/mcp-server", - "version": "0.1.0", + "version": "0.1.1", "type": "module", "description": "Model Context Protocol Server for Apify Actors", "engines": { diff --git a/src/input.ts b/src/input.ts index c90bbe7a..e4b856db 100644 --- a/src/input.ts +++ b/src/input.ts @@ -12,8 +12,5 @@ export async function processInput(originalInput: Partial): Promise format.trim()) as string[]; } - if (!input.actors || input.actors.length === 0) { - throw new Error('The `actors` parameter must be a non-empty array.'); - } return input; }