# How to integrate Apify MCP with Claude Code

```json
{
  "title": "How to integrate Apify MCP with Claude Code",
  "toolkit": "Apify",
  "toolkit_slug": "apify",
  "framework": "Claude Code",
  "framework_slug": "claude-code",
  "url": "https://composio.dev/toolkits/apify/framework/claude-code",
  "markdown_url": "https://composio.dev/toolkits/apify/framework/claude-code.md",
  "updated_at": "2026-05-12T10:01:34.828Z"
}
```

## Introduction

Manage your Apify directly from Claude Code with zero worries about OAuth hassles, API-breaking issues, or reliability and security concerns.
You can do this in two different ways:
- Via [Composio Connect](https://dashboard.composio.dev/login?utm_source=toolkits&utm_medium=framework_template&utm_campaign=claude-code&utm_content=composio_connect&next=%2F~%2Forg%2Fconnect%2Fclients%2Fclaude-code) - Direct and easiest approach
- Via [Composio SDK](https://docs.composio.dev/docs?utm_source=toolkits&utm_medium=framework_template&utm_campaign=claude-code&utm_content=composio_sdk) - Programmatic approach with more control

## Also integrate Apify with

- [OpenAI Agents SDK](https://composio.dev/toolkits/apify/framework/open-ai-agents-sdk)
- [Claude Agent SDK](https://composio.dev/toolkits/apify/framework/claude-agents-sdk)
- [Claude Cowork](https://composio.dev/toolkits/apify/framework/claude-cowork)
- [Codex](https://composio.dev/toolkits/apify/framework/codex)
- [OpenClaw](https://composio.dev/toolkits/apify/framework/openclaw)
- [Hermes](https://composio.dev/toolkits/apify/framework/hermes-agent)
- [CLI](https://composio.dev/toolkits/apify/framework/cli)
- [Google ADK](https://composio.dev/toolkits/apify/framework/google-adk)
- [LangChain](https://composio.dev/toolkits/apify/framework/langchain)
- [Vercel AI SDK](https://composio.dev/toolkits/apify/framework/ai-sdk)
- [Mastra AI](https://composio.dev/toolkits/apify/framework/mastra-ai)
- [LlamaIndex](https://composio.dev/toolkits/apify/framework/llama-index)
- [CrewAI](https://composio.dev/toolkits/apify/framework/crew-ai)

## TL;DR

- Only one MCP URL to connect multiple apps with Claude Code with zero auth hassles.
- Programmatic tool calling allows LLMs to write its code in a remote workbench to handle complex tool chaining. Reduces to-and-fro with LLMs for frequent tool calling.
- Handling Large tool responses out of LLM context to minimize context rot.
- Dynamic just-in-time access to 20,000 tools across 1000+ other Apps for cross-app workflows. It loads the tools you need, so LLMs aren't overwhelmed by tools you don't need.

## Connect Apify to Claude Code

### Connecting Apify to Claude Code using Composio
1. Add the Composio MCP to Claude

```bash
claude mcp add --scope user --transport http composio https://connect.composio.dev/mcp
```

## What is Claude Code?

Claude Code is Anthropic's command line developer tool that lets you use Claude directly inside your terminal. Instead of switching between your editor, browser, and chat, you can stay in your project folder and ask Claude to help you build, debug, refactor, and understand code right where you're working.
Key features include:
- Terminal-Native Experience: Work with Claude directly in your command line without switching contexts
- MCP Support: Built-in support for Model Context Protocol servers to extend Claude's capabilities
- Project Context: Claude understands your project structure and can read, write, and modify files
- Interactive Development: Ask questions, debug code, and get help in real-time while coding
- Multi-Platform: Works on macOS, Linux, WSL, and Windows

## What is the Apify MCP server, and what's possible with it?

The Apify MCP server is an implementation of the Model Context Protocol that connects your AI agent and assistants like Claude, Cursor, etc directly to your Apify account. It provides structured and secure access to your web scraping and automation workflows, so your agent can create actors, manage datasets, fetch scraped data, schedule tasks, and maintain webhooks on your behalf.
- Automated Actor Creation and Management: Easily instruct your agent to programmatically create, configure, or delete Apify actors for custom web automation or scraping jobs.
- Dataset Handling and Data Retrieval: Let your agent spin up new datasets, organize scraped results, and pull items from datasets for downstream analysis or reporting.
- Task Scheduling and Automation: Have your agent create and manage recurring actor tasks, making it simple to automate data extraction or browser automation at set intervals.
- Webhook Integration and Event Handling: Direct your agent to set up or remove webhooks for actor tasks, enabling real-time notifications or downstream integrations when a task completes or fails.
- Actor and Build Metadata Access: Empower your agent to fetch detailed metadata about actors, including build information and configuration details, for monitoring or troubleshooting purposes.

## Supported Tools

| Tool slug | Name | Description |
|---|---|---|
| `APIFY_ACT_BUILDS_POST` | Build Actor | Tool to build an Actor with specified configuration. Use when you need to create a new build of an Actor with a specific version. The build process compiles the Actor's source code into a Docker image. |
| `APIFY_ACTOR_BUILD_ABORT_POST` | Abort Actor Build | Tool to abort an Actor build that is starting or running. Use when you need to cancel a build in progress. Builds in terminal states (FINISHED, FAILED, ABORTING, TIMED-OUT) are not affected. |
| `APIFY_ACTOR_BUILD_DELETE` | Delete Actor Build | Tool to delete an Actor build permanently. Use when you need to remove a specific build by its ID. The default build for an Actor cannot be deleted. Only users with build permissions can delete builds. |
| `APIFY_ACTOR_BUILD_GET` | Get Actor Build | Tool to get detailed information about a specific Actor build. Use when you need to retrieve complete build details by build ID. Optionally wait for the build to finish using the waitForFinish parameter to avoid polling. |
| `APIFY_ACTOR_BUILD_LOG_GET` | Get Actor Build Log | Tool to retrieve the log file for a specific Actor build. Use when you need to inspect logs generated during an Actor build process. Only the trailing 5 million characters of the log are stored. |
| `APIFY_ACTOR_BUILDS_GET` | Get user builds list | Tool to get a paginated list of all builds for a user. Use when you need to retrieve build history across all actors. Supports pagination up to 1000 records. |
| `APIFY_ACTOR_RUN_ABORT_POST` | Abort Actor Run | Tool to abort a running or starting Actor run. Use when you need to stop an Actor run that is currently in STARTING or RUNNING status. For runs with status FINISHED, FAILED, ABORTING, and TIMED-OUT this call does nothing. |
| `APIFY_ACTOR_RUN_DELETE` | Delete Actor Run | Tool to delete a finished Actor run. Use when you need to permanently remove a completed run. Only finished runs can be deleted by the initiating user or organization. |
| `APIFY_ACTOR_RUN_GET` | Get Actor Run | Tool to get details about a specific Actor run. Use when you need to retrieve comprehensive information about a run including its execution status, resource usage, storage IDs, and metadata. |
| `APIFY_ACTOR_RUN_PUT` | Update Actor Run Status Message | Tool to update the status message of an Actor run. Use when you need to set progress information or status updates that will be displayed in the Apify Console UI during Actor execution. |
| `APIFY_ACTOR_TASK_DELETE` | Delete Actor Task | Tool to delete an Actor task permanently. Use when you need to remove a task by its ID or username~taskName. Confirm before calling. |
| `APIFY_ACTOR_TASK_GET` | Get Actor Task | Tool to get complete details about an Actor task. Use when you need to retrieve task configuration, input settings, or metadata by task ID or username~task-name. |
| `APIFY_ACTOR_TASK_PUT` | Update Actor Task | Tool to update Actor task settings using JSON payload. Only specified properties are updated; others remain unchanged. Use when you need to modify task configuration, input, or execution options. |
| `APIFY_ACTOR_TASK_RUNS_LAST_GET` | Get last actor task run | Tool to get the most recent run of a specific Actor task. Use when you need to retrieve the last execution details. You can filter by status to get only successful runs using status='SUCCEEDED'. |
| `APIFY_ACTOR_TASK_RUN_SYNC_GET` | Run Task Sync (GET) | Tool to run a specific task synchronously and return its output. Use when immediate task results are needed with pre-configured settings. The run must finish within 300 seconds otherwise the HTTP request fails with a timeout error. |
| `APIFY_ACTOR_TASK_RUN_SYNC_GET_DATASET_ITEMS_GET` | Run Task Sync & Get Dataset Items | Tool to run an actor task synchronously and retrieve its dataset items. Use when immediate access to task run results is needed. The run must finish within 300 seconds otherwise the request times out. For large datasets exceeding the timeout, use `limit`/`offset` pagination to retrieve results in smaller batches or switch to an async run pattern with a separate dataset retrieval call. |
| `APIFY_ACTOR_TASK_RUN_SYNC_GET_DATASET_ITEMS_POST` | Run Task Sync with Input Override & Get Dataset Items | Tool to run an actor task synchronously with input overrides and retrieve its dataset items. Use when you need to override task input configuration and get immediate results. The run must finish within 300 seconds otherwise the request times out. |
| `APIFY_ACTOR_TASK_RUN_SYNC_POST` | Run Task Sync (POST) | Tool to run an Actor task synchronously with input override and return its output. Use when immediate task results are needed with custom input parameters. The run must finish within 300 seconds otherwise the HTTP request fails with a timeout error (though the run continues server-side). |
| `APIFY_ACT_PUT` | Update Actor | Tool to update Actor settings using JSON payload. Only specified fields will be updated. Use when you need to modify Actor configuration, make an Actor public, or update version settings. |
| `APIFY_ACT_RUNS_LAST_GET` | Get last actor run | Tool to get the most recent run of a specific Actor. Use when you need to retrieve the last execution details of an Actor and optionally filter by status (e.g., status='SUCCEEDED' to get only the last successful run). |
| `APIFY_ACT_RUN_SYNC_GET` | Run Actor Sync without Input (GET) | Tool to run a specific Actor synchronously without input and return its output. Use when immediate Actor results are needed without providing input data; the run must finish within 300 seconds otherwise the HTTP request fails with a timeout error. |
| `APIFY_ACT_RUN_SYNC_GET_DATASET_ITEMS_GET` | Run Actor Sync & Get Dataset Items | Tool to run Actor synchronously and get dataset items. Supports both actors that require input and those that don't. Use when immediate access to Actor results is needed. The run must finish within 300 seconds otherwise the request times out. |
| `APIFY_ACTS_GET` | Get list of Actors | Tool to get the list of all Actors that the user created or used. Use when you need to enumerate or browse Actors. Add my=1 to get only user-created Actors. |
| `APIFY_ACT_VERSION_DELETE` | Delete Actor Version | Tool to delete a specific version of an Actor's source code. Use when you need to remove an Actor version by actor ID and version number. Confirm before calling. |
| `APIFY_ACT_VERSION_ENV_VAR_DELETE` | Delete Actor Version Environment Variable | Tool to delete an environment variable from a specific Actor version. Use when removing environment variables from Actor versions. |
| `APIFY_ACT_VERSION_ENV_VAR_GET` | Get Actor Version Environment Variable | Tool to get environment variable details for a specific Actor version. Use when retrieving environment variable information from an Actor version. Returns name, value (if not secret), and secret status. |
| `APIFY_ACT_VERSION_ENV_VAR_PUT` | Update Actor Version Environment Variable | Tool to update environment variable for a specific Actor version using JSON payload. Only specified fields will be updated. Use when modifying existing environment variables in Actor versions. |
| `APIFY_ACT_VERSION_ENV_VARS_GET` | Get list of Actor version environment variables | Tool to get the list of environment variables for a specific Actor version. Use when you need to retrieve environment variable configurations for an Actor version. |
| `APIFY_ACT_VERSION_ENV_VARS_POST` | Create Actor Version Environment Variable | Tool to create an environment variable for a specific Actor version. Use when adding new environment variables to Actor versions. Requires name and value parameters. |
| `APIFY_ACT_VERSION_GET` | Get Actor version | Tool to get details about a specific version of an Actor. Use when you need version metadata including source type, build tag, and configuration details. |
| `APIFY_ACT_VERSION_PUT` | Update Actor Version | Tool to update an Actor version's configuration and source code. Use when modifying version properties such as buildTag, sourceType, or environment variables. Only specified properties will be updated. |
| `APIFY_ACT_VERSIONS_GET` | Get list of Actor versions | Tool to get the list of versions of a specific Actor. Use when you need to retrieve version metadata including source type, version number, and configuration details. |
| `APIFY_ACT_VERSIONS_POST` | Create Actor Version | Tool to create a new version of an Actor. Use when you need to add a new version with specific source code location and configuration. Requires versionNumber and sourceType parameters, plus conditional parameters based on the sourceType. |
| `APIFY_ACT_WEBHOOKS_GET` | Get list of Actor webhooks | Tool to get a list of webhooks for a specific Actor. Use when you need to review or manage webhooks configured for an Actor. |
| `APIFY_CREATE_ACTOR` | Create Actor | Tool to create a new Actor with specified configuration. Use when you need to initialize a fresh Actor programmatically before publishing or running it. |
| `APIFY_CREATE_DATASET` | Create Dataset | Tool to create a new dataset. Use when you need to initialize or retrieve a dataset by name. |
| `APIFY_CREATE_TASK` | Create Actor Task | Tool to create a new Actor task with specified settings. Use when you need to configure or schedule recurring Actor runs programmatically. |
| `APIFY_CREATE_TASK_WEBHOOK` | Create Task Webhook | Tool to create a webhook for an Actor task. Use when you need external notifications about task run events (e.g., completion or failure) in downstream systems. |
| `APIFY_DATASET_DELETE` | Delete Dataset | Tool to delete a dataset permanently. Use when you need to remove a dataset by its ID or username~dataset-name. Confirm before calling. |
| `APIFY_DATASET_GET` | Get Dataset | Tool to retrieve dataset metadata by dataset ID. Use when you need information about a dataset's structure, item counts, or access URLs. This does not return dataset items themselves. |
| `APIFY_DATASET_PUT` | Update Dataset | Tool to update a dataset's name via JSON payload. Use when you need to rename an existing dataset. |
| `APIFY_DATASETS_GET` | Get list of datasets | Tool to get list of datasets for a user. Use when you need to enumerate or browse user's datasets. Supports pagination with up to 1000 items per page. |
| `APIFY_DATASET_STATISTICS_GET` | Get Dataset Statistics | Tool to get dataset field statistics by dataset ID. Use when you need statistical information about dataset fields including min, max, null count, and empty count. Only provides field statistics when dataset schema is configured. |
| `APIFY_DELETE_ACTOR` | Delete Actor | Tool to delete an Actor permanently. Use when you need to remove an Actor by its ID or username~actorName. Confirm before calling. |
| `APIFY_DELETE_WEBHOOK` | Delete Webhook | Tool to delete a webhook by its ID. Use when removing a webhook after confirming the webhook ID. |
| `APIFY_GET_ACTOR` | Get Actor Details | Tool to get details of a specific Actor. Use when you need actor metadata by ID or username/actorName. Response includes `isDeprecated` and `notice` fields indicating deprecation status, and `pricingInfos` for per-unit cost details — review both before scheduling runs. |
| `APIFY_GET_ACTOR_LAST_RUN_DATASET_ITEMS` | Get Actor Last Run Dataset Items | Tool to get dataset items from the last run of an Actor. Use when you need to retrieve output data from the most recent Actor execution, optionally filtered by run status (e.g., status='SUCCEEDED' to get items only from the last successful run). |
| `APIFY_GET_ALL_WEBHOOKS` | Get all webhooks | Tool to get a list of all webhooks created by the user. Use when you need to enumerate webhooks before filtering or maintenance. |
| `APIFY_GET_DATASET_ITEMS` | Get dataset items | Tool to retrieve items from a dataset. Use when you need to fetch data from a specified dataset by pagination or filtering. Only JSON format is fully supported. For datasets larger than 1000 items, issue multiple calls incrementing `offset` by `limit` until the response returns fewer items than `limit`. |
| `APIFY_GET_DEFAULT_BUILD` | Get Default Build | Tool to get the default build for an Actor. Use after specifying the Actor ID; optionally wait for the build to finish before returning. |
| `APIFY_GET_KEY_VALUE_RECORD` | Get Key-Value Record | Tool to retrieve a record from a key-value store. Use when you need to fetch a specific value by key from an Apify Key-Value Store. |
| `APIFY_GET_LIST_OF_BUILDS` | Get list of builds | Tool to get a list of builds for a specific Actor. Use when you need paginated access to an Actor’s build (version) history. |
| `APIFY_GET_LIST_OF_RUNS` | Get list of runs | Tool to get a list of runs for a specific Actor. Use when you need to paginate through runs and optionally filter by status before processing run data. |
| `APIFY_GET_LIST_OF_TASK_RUNS` | Get list of task runs | Tool to get a list of runs for a specific Actor task. Use when you need to paginate through task runs and optionally filter by status. |
| `APIFY_GET_LIST_OF_TASKS` | Get list of tasks | Tool to fetch a paginated list of tasks belonging to the authenticated user. Use when you need to browse or sort tasks created by the user. |
| `APIFY_GET_LIST_OF_TASK_WEBHOOKS` | Get list of task webhooks | Tool to get a list of webhooks for a specific Actor task. Use when you need to review or paginate webhooks after creating or updating a task. |
| `APIFY_GET_LOG` | Get log | Tool to retrieve logs for a specific Actor run or build. Use after a run completes or fails — a run may report success status yet contain only informational messages, making log inspection the only way to confirm actual outcomes. For long runs, log responses can be very large; prioritize error-level entries and recent timestamps to diagnose issues efficiently. |
| `APIFY_GET_OPEN_API_DEFINITION` | Get OpenAPI Definition | Tool to get the OpenAPI definition for a specific Actor build. Use when you need the API schema for code generation or analysis. |
| `APIFY_GET_RUN_DATASET_ITEMS` | Get Run Dataset Items | Tool to get dataset items from a specific Actor run. Use when you need to retrieve the output data from a completed or running Actor run. |
| `APIFY_GET_TASK_INPUT` | Get Task Input | Tool to retrieve the input configuration of a specific task. Use when you need to inspect stored task input before execution or debugging. |
| `APIFY_GET_TASK_LAST_RUN_DATASET_ITEMS` | Get Task Last Run Dataset Items | Tool to get dataset items from the last run of an Actor task. Use when you need to retrieve data from the most recent task execution. Filter by status (e.g., 'SUCCEEDED') to get items from the last successful run only. |
| `APIFY_KEY_VALUE_STORE_DELETE` | Delete Key-Value Store | Tool to delete a key-value store permanently. Use when you need to remove a key-value store by its ID. Confirm before calling. |
| `APIFY_KEY_VALUE_STORE_GET` | Get Key-Value Store | Tool to retrieve key-value store metadata by store ID. Use when you need detailed information about a specific key-value store including stats and access URLs. |
| `APIFY_KEY_VALUE_STORE_KEYS_GET` | Get Key-Value Store Keys | Tool to retrieve a list of keys from a key-value store. Use when you need to list keys in a store with optional filtering and pagination support. |
| `APIFY_KEY_VALUE_STORE_RECORD_DELETE` | Delete Key-Value Store Record | Tool to delete a record from a key-value store. Use when you need to remove a specific record by its key from an Apify Key-Value Store. |
| `APIFY_KEY_VALUE_STORE_RECORD_HEAD` | Check Key-Value Store Record Exists | Tool to check if a record exists in a key-value store. Use when you need to verify whether a specific key exists in an Apify Key-Value Store without retrieving its content. |
| `APIFY_KEY_VALUE_STORES_GET` | Get list of key-value stores | Tool to get the list of key-value stores owned by the user. Use when you need to enumerate or browse available stores. Supports pagination up to 1000 records per request. |
| `APIFY_KEY_VALUE_STORES_POST` | Create Key-Value Store | Tool to create a new key-value store or retrieve an existing one by name. Use when you need to initialize a store for saving data records or files. If a store with the given name already exists, returns that store instead of creating a duplicate. |
| `APIFY_LIST_USER_RUNS` | List User Actor Runs | Tool to get a paginated list of all Actor runs for the authenticated user. Use when you need to browse all runs across all actors, optionally filtered by status or date range. |
| `APIFY_REQUEST_QUEUE_DELETE` | Delete Request Queue | Tool to delete a request queue permanently. Use when you need to remove a request queue by its ID. |
| `APIFY_REQUEST_QUEUE_GET` | Get Request Queue | Tool to retrieve request queue metadata by queue ID. Use when you need information about a specific request queue including its statistics and request counts. |
| `APIFY_REQUEST_QUEUE_HEAD_GET` | Get Request Queue Head | Tool to retrieve first requests from the queue for inspection. Use when you need to examine pending requests without locking them. |
| `APIFY_REQUEST_QUEUE_HEAD_LOCK_POST` | Get Head and Lock Queue Requests | Tool to get and lock head requests from the queue. Returns the given number of first requests from the queue and locks them for the given time, preventing other clients from accessing them during the lock period. Use when you need to process requests exclusively without concurrent access by other clients. |
| `APIFY_REQUEST_QUEUE_PUT` | Update Request Queue | Tool to update request queue name using JSON payload. Use when you need to rename an existing request queue. |
| `APIFY_REQUEST_QUEUE_REQUEST_DELETE` | Delete Request from Queue | Tool to delete a specific request from a request queue. Use when you need to remove a request by its ID from an Apify request queue. |
| `APIFY_REQUEST_QUEUE_REQUEST_GET` | Get Request from Queue | Tool to retrieve a specific request from a request queue by its ID. Use when you need to get detailed information about a request in an Apify request queue. |
| `APIFY_REQUEST_QUEUE_REQUEST_LOCK_DELETE` | Delete Request Lock | Tool to delete a request lock from a request queue. Use when you need to unlock a previously locked request. Only the client that locked the request can delete its lock. |
| `APIFY_REQUEST_QUEUE_REQUEST_LOCK_PUT` | Prolong Request Lock | Tool to prolong request lock in a request queue. Use when you need to extend the lock duration on a previously locked request. Only the client that locked the request can prolong its lock. |
| `APIFY_REQUEST_QUEUE_REQUEST_PUT` | Update Request in Queue | Tool to update a request in a request queue. Use when you need to modify request properties or mark a request as handled by setting handledAt to the current date/time. If handledAt is set, the request will be removed from the head of the queue and unlocked if applicable. |
| `APIFY_REQUEST_QUEUE_REQUESTS_BATCH_DELETE` | Batch Delete Requests from Queue | Tool to batch-delete up to 25 requests from a queue. Use when you need to remove multiple requests efficiently. Failed requests due to rate limits should be retried with exponential backoff. |
| `APIFY_REQUEST_QUEUE_REQUESTS_BATCH_POST` | Batch Add Requests to Queue | Tool to batch-add up to 25 requests to a request queue. Use when you need to add multiple requests efficiently. Failed requests due to rate limits should be retried with exponential backoff. |
| `APIFY_REQUEST_QUEUE_REQUESTS_GET` | List Request Queue Requests | Tool to list requests in a request queue with pagination support. Use when you need to retrieve multiple requests from an Apify request queue. |
| `APIFY_REQUEST_QUEUE_REQUESTS_POST` | Add Request to Queue | Tool to add a request to the queue. Use when you need to add a web page URL to a request queue for crawling. If a request with the same uniqueKey was already present in the queue, returns the ID of the existing request. |
| `APIFY_REQUEST_QUEUE_REQUESTS_UNLOCK_POST` | Unlock Queue Requests | Tool to unlock requests in a request queue that are currently locked by the client. If the client is within an Actor run, unlocks all requests locked by that specific run plus all requests locked by the same clientKey. If the client is outside of an Actor run, unlocks all requests locked using the same clientKey. |
| `APIFY_REQUEST_QUEUES_GET` | Get list of request queues | Tool to get list of request queues for a user. Use when you need to enumerate or browse user's request queues. Supports pagination with up to 1000 items per page. |
| `APIFY_REQUEST_QUEUES_POST` | Create Request Queue | Tool to create a new request queue or retrieve an existing one by name. Use when you need to initialize a queue for storing and managing web scraping requests. If a queue with the given name already exists, returns that queue instead of creating a duplicate. Unnamed queues follow data retention period policies. |
| `APIFY_RUN_ACTOR` | Run Actor Asynchronously | Tool to run a specific Actor asynchronously. Use when you need to trigger an Actor run without waiting for completion and retrieve its run details immediately. |
| `APIFY_RUN_ACTOR_SYNC` | Run Actor Sync | Tool to run a specific Actor synchronously with input and return its output record. Use when immediate Actor results are needed; runs may timeout after 300 seconds. To avoid timeouts, scope inputs to specific URLs rather than broad crawls and request only necessary fields (e.g., text or markdown). |
| `APIFY_RUN_ACTOR_SYNC_GET_DATASET_ITEMS` | Run Actor Sync & Get Dataset Items | Tool to run an Actor synchronously and retrieve its dataset items. Use when immediate access to run results is needed. |
| `APIFY_RUN_TASK` | Run Task Asynchronously | Tool to run a specific Actor task asynchronously. Use when you need to trigger a task run without waiting for completion and immediately retrieve its run details. |
| `APIFY_SCHEDULE_DELETE` | Delete Schedule | Tool to delete a schedule by its ID. Use when you need to remove a schedule from the Apify system. |
| `APIFY_SCHEDULE_GET` | Get Schedule | Tool to get schedule details by ID. Use when you need to retrieve comprehensive information about a schedule including cron expression, timezone, actions, and execution times. |
| `APIFY_SCHEDULE_LOG_GET` | Get Schedule Log | Tool to get schedule log by ID. Use when you need to retrieve execution history for a schedule, including invocation timestamps and status messages. Returns up to 1000 invocations. |
| `APIFY_SCHEDULE_PUT` | Update Schedule | Tool to update an existing schedule with new settings. Use when you need to modify schedule properties like cron expression, timezone, enabled status, or actions. Only specified fields are updated; others remain unchanged. |
| `APIFY_SCHEDULES_GET` | Get list of schedules | Tool to get list of schedules created by the user. Use when you need to browse or enumerate user's schedules. Supports pagination with up to 1000 items per page. |
| `APIFY_SCHEDULES_POST` | Create Schedule | Tool to create a new schedule with specified settings. Use when you need to automate Actor or Actor task execution at specific times using cron expressions. |
| `APIFY_STORE_DATA_IN_DATASET` | Store Data in Dataset | Tool to store data items in a dataset. Use after collecting data when you want to batch-append or update items in an existing dataset. |
| `APIFY_STORE_DATA_IN_KEY_VALUE_STORE` | Store Data in Key-Value Store | Tool to create or update a record in a key-value store. Use after you have the store ID and record key to persist JSON data. |
| `APIFY_STORE_GET` | Get list of Actors in Store | Tool to get list of public Actors from Apify Store. Use when you need to browse or search public Actors available in the store. Supports searching by title, name, description, username, and readme. |
| `APIFY_UPDATE_KEY_VALUE_STORE` | Update Key-Value Store | Tool to update a key-value store's properties. Use when renaming or changing access of the store after confirming the store ID. |
| `APIFY_UPDATE_TASK_INPUT` | Update Task Input | Tool to update the input configuration of a specific Actor task. Use when you need to modify a scheduled tasks input before execution. |
| `APIFY_USER_GET` | Get Public User Data | Tool to get public user data. Use when you need to retrieve publicly accessible information about a specific Apify user account, similar to what can be seen on public profile pages. This operation requires no authentication token. |
| `APIFY_USERS_ME_GET` | Get Current User Account Data | Tool to get private user account information. Use when you need to retrieve comprehensive data about the current user identified by the authentication token, including profile, subscription plan, and proxy settings. Note: 'plan', 'email', and 'profile' fields are omitted when accessed from Actor run. |
| `APIFY_USERS_ME_LIMITS_GET` | Get Account Limits | Tool to get a complete summary of account limits and usage. Use when you need to retrieve information about usage cycles, spending caps, compute resources, data transfer quotas, and other account limits. This shows the same information as the Limits page in Apify console. |
| `APIFY_USERS_ME_LIMITS_PUT` | Update Account Limits | Tool to update account limits manageable on the Limits page. Use when you need to set or modify the monthly spending cap (maxMonthlyUsageUsd) or data retention period (dataRetentionDays). At least one limit parameter must be provided. |
| `APIFY_USERS_ME_USAGE_MONTHLY_GET` | Get Monthly Usage | Tool to get monthly usage summary with daily breakdown. Use when you need detailed usage information including storage, data transfer, and request queue metrics for the current or a specific billing cycle. This shows the same information as the Billing page in Apify console. |
| `APIFY_WEBHOOK_DISPATCHES_GET` | Get list of webhook dispatches | Tool to get list of webhook dispatches for the user. Use when you need to retrieve webhook execution history with pagination support. |
| `APIFY_WEBHOOK_DISPATCH_GET` | Get Webhook Dispatch | Tool to get webhook dispatch object with all details. Use when you need to retrieve information about a specific webhook dispatch including its status, event data, and call history. |
| `APIFY_WEBHOOK_GET` | Get webhook | Tool to get webhook object with all details. Use when you need to retrieve complete information about a specific webhook by its ID. |
| `APIFY_WEBHOOK_PUT` | Update Webhook | Tool to update webhook using JSON payload. Only specified properties are updated; others remain unchanged. Use when you need to modify webhook settings like event types, target URL, or other configuration. |
| `APIFY_WEBHOOK_TEST_POST` | Test Webhook | Tool to test a webhook by creating a test dispatch with a dummy payload. Use when you need to verify webhook configuration before production use. |
| `APIFY_WEBHOOK_WEBHOOK_DISPATCHES_GET` | Get webhook dispatches | Tool to get list of webhook dispatches for a specific webhook. Use when you need to retrieve dispatch history for a particular webhook with pagination support. |

## Supported Triggers

None listed.

## Creating MCP Server - Stand-alone vs Composio SDK

The Apify MCP server is an implementation of the Model Context Protocol that connects Claude Code (and other AI assistants like Claude and Cursor) directly to your Apify account. It provides structured and secure access so Claude can perform Apify operations on your behalf.
With Composio's managed implementation, you don't have to create your own developer app. For production, if you're building an end product, we recommend using your own credentials. The managed server helps you prototype fast and go from 0-1 faster.

## Step-by-step Guide

### 1. Prerequisites

Before starting, make sure you have:
- Claude Pro, Max, or API billing enabled Anthropic account
- Composio API Key
- A Apify account
- Basic knowledge of Python or TypeScript

### 1. Install Claude Code

To install Claude Code, use one of the following methods based on your operating system:
```bash
# macOS, Linux, WSL
curl -fsSL https://claude.ai/install.sh | bash

# Windows PowerShell
irm https://claude.ai/install.ps1 | iex

# Windows CMD
curl -fsSL https://claude.ai/install.cmd -o install.cmd && install.cmd && del install.cmd
```

### 2. Set up Claude Code

Open a terminal, go to your project folder, and start Claude Code:
- Claude Code will open in your terminal
- Follow the prompts to sign in with your Anthropic account
- Complete the authentication flow
- Once authenticated, you can start using Claude Code
```bash
cd your-project-folder
claude
```

### 3. Set up environment variables

Create a .env file in your project root with the following variables:
- COMPOSIO_API_KEY authenticates with Composio (get it from [Composio dashboard](https://dashboard.composio.dev/login?utm_source=toolkits&utm_medium=framework_template&utm_campaign=claude-code&utm_content=api_key&next=%2F~%2Forg%2Fconnect%2Fclients%2Fclaude-code))
- USER_ID identifies the user for session management (use any unique identifier)
```bash
COMPOSIO_API_KEY=your_composio_api_key_here
USER_ID=your_user_id_here
```

### 4. Install Composio library

No description provided.
```python
pip install composio-core python-dotenv
```

```typescript
npm install @composio/core dotenv
```

### 5. Generate Composio MCP URL

No description provided.
```python
import os
from composio import Composio
from dotenv import load_dotenv

load_dotenv()

COMPOSIO_API_KEY = os.getenv("COMPOSIO_API_KEY")
USER_ID = os.getenv("USER_ID")

composio_client = Composio(api_key=COMPOSIO_API_KEY)

composio_session = composio_client.create(
    user_id=USER_ID,
    toolkits=["apify"],
)

COMPOSIO_MCP_URL = composio_session.mcp.url

print(f"MCP URL: {COMPOSIO_MCP_URL}")
print(f"\nUse this command to add to Claude Code:")
print(f'claude mcp add --transport http apify-composio "{COMPOSIO_MCP_URL}" --headers "X-API-Key:{COMPOSIO_API_KEY}"')
```

```typescript
import 'dotenv/config';
import { Composio } from '@composio/core';

const { COMPOSIO_API_KEY, USER_ID } = process.env;

if (!COMPOSIO_API_KEY || !USER_ID) {
  throw new Error('COMPOSIO_API_KEY and USER_ID required in .env');
}

const composioClient = new Composio({ apiKey: COMPOSIO_API_KEY });

const composioSession = await composioClient.create(USER_ID, {
  toolkits: ['apify'],
});

const composioMcpUrl = composioSession?.mcp.url;

console.log(`MCP URL: ${composioMcpUrl}`);
console.log(`\nUse this command to add to Claude Code:`);
console.log(`claude mcp add --transport http apify-composio "${composioMcpUrl}" --headers "X-API-Key:${COMPOSIO_API_KEY}"`);
```

### 6. Run the script and copy the MCP URL

No description provided.
```python
python generate_mcp_url.py
```

```typescript
node --loader ts-node/esm generate_mcp_url.ts
# or if using tsx
tsx generate_mcp_url.ts
```

### 7. Add Apify MCP to Claude Code

In your terminal, add the MCP server using the command from the previous step. The command format is:
- claude mcp add registers a new MCP server with Claude Code
- --transport http specifies that this is an HTTP-based MCP server
- The server name (apify-composio) is how you'll reference it
- The URL points to your Composio Tool Router session
- --headers includes your Composio API key for authentication
After running the command, close the current Claude Code session and start a new one for the changes to take effect.
```bash
claude mcp add --transport http apify-composio "YOUR_MCP_URL_HERE" --headers "X-API-Key:YOUR_COMPOSIO_API_KEY"

# Then restart Claude Code
exit
claude
```

### 8. Verify the installation

Check that your Apify MCP server is properly configured.
- This command lists all MCP servers registered with Claude Code
- You should see your apify-composio entry in the list
- This confirms that Claude Code can now access Apify tools
If everything is wired up, you should see your apify-composio entry listed:
```bash
claude mcp list
```

### 9. Authenticate Apify

The first time you try to use Apify tools, you'll be prompted to authenticate.
- Claude Code will detect that you need to authenticate with Apify
- It will show you an authentication link
- Open the link in your browser (or copy/paste it)
- Complete the Apify authorization flow
- Return to the terminal and start using Apify through Claude Code
Once authenticated, you can ask Claude Code to perform Apify operations in natural language. For example:
- "Create a new dataset for scraped results"
- "Fetch items from a specific Apify dataset"
- "Get details of my latest Apify actor"

## Complete Code

```python
import os
from composio import Composio
from dotenv import load_dotenv

load_dotenv()

COMPOSIO_API_KEY = os.getenv("COMPOSIO_API_KEY")
USER_ID = os.getenv("USER_ID")

composio_client = Composio(api_key=COMPOSIO_API_KEY)

composio_session = composio_client.create(
    user_id=USER_ID,
    toolkits=["apify"],
)

COMPOSIO_MCP_URL = composio_session.mcp.url

print(f"MCP URL: {COMPOSIO_MCP_URL}")
print(f"\nUse this command to add to Claude Code:")
print(f'claude mcp add --transport http apify-composio "{COMPOSIO_MCP_URL}" --headers "X-API-Key:{COMPOSIO_API_KEY}"')
```

```typescript
import 'dotenv/config';
import { Composio } from '@composio/core';

const { COMPOSIO_API_KEY, USER_ID } = process.env;

if (!COMPOSIO_API_KEY || !USER_ID) {
  throw new Error('COMPOSIO_API_KEY and USER_ID required in .env');
}

const composioClient = new Composio({ apiKey: COMPOSIO_API_KEY });

const composioSession = await composioClient.create(USER_ID, {
  toolkits: ['apify'],
});

const composioMcpUrl = composioSession?.mcp.url;

console.log(`MCP URL: ${composioMcpUrl}`);
console.log(`\nUse this command to add to Claude Code:`);
console.log(`claude mcp add --transport http apify-composio "${composioMcpUrl}" --headers "X-API-Key:${COMPOSIO_API_KEY}"`);
```

## Conclusion

You've successfully integrated Apify with Claude Code using Composio's MCP server. Now you can interact with Apify directly from your terminal using natural language commands.
Key features of this setup:
- Terminal-native experience without switching contexts
- Natural language commands for Apify operations
- Secure authentication through Composio's managed MCP
- Tool Router for dynamic tool discovery and execution
Next steps:
- Try asking Claude Code to perform various Apify operations
- Add more toolkits to your Tool Router session for multi-app workflows
- Integrate this setup into your development workflow for increased productivity
You can extend this by adding more toolkits, implementing custom workflows, or building automation scripts that leverage Claude Code's capabilities.

## How to build Apify MCP Agent with another framework

- [OpenAI Agents SDK](https://composio.dev/toolkits/apify/framework/open-ai-agents-sdk)
- [Claude Agent SDK](https://composio.dev/toolkits/apify/framework/claude-agents-sdk)
- [Claude Cowork](https://composio.dev/toolkits/apify/framework/claude-cowork)
- [Codex](https://composio.dev/toolkits/apify/framework/codex)
- [OpenClaw](https://composio.dev/toolkits/apify/framework/openclaw)
- [Hermes](https://composio.dev/toolkits/apify/framework/hermes-agent)
- [CLI](https://composio.dev/toolkits/apify/framework/cli)
- [Google ADK](https://composio.dev/toolkits/apify/framework/google-adk)
- [LangChain](https://composio.dev/toolkits/apify/framework/langchain)
- [Vercel AI SDK](https://composio.dev/toolkits/apify/framework/ai-sdk)
- [Mastra AI](https://composio.dev/toolkits/apify/framework/mastra-ai)
- [LlamaIndex](https://composio.dev/toolkits/apify/framework/llama-index)
- [CrewAI](https://composio.dev/toolkits/apify/framework/crew-ai)

## Related Toolkits

- [Excel](https://composio.dev/toolkits/excel) - Microsoft Excel is a robust spreadsheet application for organizing, analyzing, and visualizing data. It's the go-to tool for calculations, reporting, and flexible data management.
- [21risk](https://composio.dev/toolkits/_21risk) - 21RISK is a web app built for easy checklist, audit, and compliance management. It streamlines risk processes so teams can focus on what matters.
- [Abstract](https://composio.dev/toolkits/abstract) - Abstract provides a suite of APIs for automating data validation and enrichment tasks. It helps developers streamline workflows and ensure data quality with minimal effort.
- [Addressfinder](https://composio.dev/toolkits/addressfinder) - Addressfinder is a data quality platform for verifying addresses, emails, and phone numbers. It helps you ensure accurate customer and contact data every time.
- [Agentql](https://composio.dev/toolkits/agentql) - Agentql is a toolkit that connects AI agents to the web using a specialized query language. It enables structured web interaction and data extraction for smarter automations.
- [Agenty](https://composio.dev/toolkits/agenty) - Agenty is a web scraping and automation platform for extracting data and automating browser tasks—no coding needed. It streamlines data collection, monitoring, and repetitive online actions.
- [Ambee](https://composio.dev/toolkits/ambee) - Ambee is an environmental data platform providing real-time, hyperlocal APIs for air quality, weather, and pollen. Get precise environmental insights to power smarter decisions in your apps and workflows.
- [Ambient weather](https://composio.dev/toolkits/ambient_weather) - Ambient Weather is a platform for personal weather stations with a robust API for accessing local, real-time, and historical weather data. Get detailed environmental insights directly from your own sensors for smarter apps and automations.
- [Anonyflow](https://composio.dev/toolkits/anonyflow) - Anonyflow is a service for encryption-based data anonymization and secure data sharing. It helps organizations meet GDPR, CCPA, and HIPAA data privacy compliance requirements.
- [Api ninjas](https://composio.dev/toolkits/api_ninjas) - Api ninjas offers 120+ public APIs spanning categories like weather, finance, sports, and more. Developers use it to supercharge apps with real-time data and actionable endpoints.
- [Api sports](https://composio.dev/toolkits/api_sports) - Api sports is a comprehensive sports data platform covering 2,000+ competitions with live scores and 15+ years of stats. Instantly access up-to-date sports information for analysis, apps, or chatbots.
- [Autom](https://composio.dev/toolkits/autom) - Autom is a lightning-fast search engine results data platform for Google, Bing, and Brave. Developers use it to access fresh, low-latency SERP data on demand.
- [Beaconchain](https://composio.dev/toolkits/beaconchain) - Beaconchain is a real-time analytics platform for Ethereum 2.0's Beacon Chain. It provides detailed insights into validators, blocks, and overall network performance.
- [Big data cloud](https://composio.dev/toolkits/big_data_cloud) - BigDataCloud provides APIs for geolocation, reverse geocoding, and address validation. Instantly access reliable location intelligence to enhance your applications and workflows.
- [Bigpicture io](https://composio.dev/toolkits/bigpicture_io) - BigPicture.io offers APIs for accessing detailed company and profile data. Instantly enrich your applications with up-to-date insights on 20M+ businesses.
- [Bitquery](https://composio.dev/toolkits/bitquery) - Bitquery is a blockchain data platform offering indexed, real-time, and historical data from 40+ blockchains via GraphQL APIs. Get unified, reliable access to complex on-chain data for analytics, trading, and research.
- [Brightdata](https://composio.dev/toolkits/brightdata) - Brightdata is a leading web data platform offering advanced scraping, SERP APIs, and anti-bot tools. It lets you collect public web data at scale, bypassing blocks and friction.
- [Builtwith](https://composio.dev/toolkits/builtwith) - BuiltWith is a web technology profiler that uncovers the technologies powering any website. Gain actionable insights into analytics, hosting, and content management stacks for smarter research and lead generation.
- [Byteforms](https://composio.dev/toolkits/byteforms) - Byteforms is an all-in-one platform for creating forms, managing submissions, and integrating data. It streamlines workflows by centralizing form data collection and automation.
- [Cabinpanda](https://composio.dev/toolkits/cabinpanda) - Cabinpanda is a data collection platform for building and managing online forms. It helps streamline how you gather, organize, and analyze responses.

## Frequently Asked Questions

### What are the differences in Tool Router MCP and Apify MCP?

With a standalone Apify MCP server, the agents and LLMs can only access a fixed set of Apify tools tied to that server. However, with the Composio Tool Router, agents can dynamically load tools from Apify and many other apps based on the task at hand, all through a single MCP endpoint.

### Can I use Tool Router MCP with Claude Code?

Yes, you can. Claude Code fully supports MCP integration. You get structured tool calling, message history handling, and model orchestration while Tool Router takes care of discovering and serving the right Apify tools.

### Can I manage the permissions and scopes for Apify while using Tool Router?

Yes, absolutely. You can configure which Apify scopes and actions are allowed when connecting your account to Composio. You can also bring your own OAuth credentials or API configuration so you keep full control over what the agent can do.

### How safe is my data with Composio Tool Router?

All sensitive data such as tokens, keys, and configuration is fully encrypted at rest and in transit. Composio is SOC 2 Type 2 compliant and follows strict security practices so your Apify data and credentials are handled as safely as possible.

---
[See all toolkits](https://composio.dev/toolkits) · [Composio docs](https://docs.composio.dev/llms.txt)
