> **Building with AI coding agents?** Install the authstack plugin with one command. This equips your agent with accurate Scalekit implementation patterns.
>
> **Recommended** (the `-y` flags skip prompts, so the command runs without an interactive terminal):
> ```bash
> npx -y @scalekit-inc/cli setup -y
> ```
>
> Global:
> ```bash
> npm install -g @scalekit-inc/cli
> scalekit setup -y
> ```
>
> Supports Claude Code, Cursor, GitHub Copilot, Codex + skills for other Agent Skills-compatible agents in `~/.agents/skills`.
> Skills: integrate-agentkit, implement-saaskit, add-mcp-oauth, implement-sso, implement-scim.
> [Full setup guide](https://docs.scalekit.com/dev-kit/build-with-ai/)

---

# Connect AI agents to the PhantomBuster MCP server

The PhantomBuster MCP connector routes your AI agent's tool calls to PhantomBuster's own MCP server through Scalekit. Each user signs in to PhantomBuster once, and Scalekit stores and refreshes their tokens, so your agent never handles credentials. It comes with 62 tools.

**Authentication:** OAuth 2.1/DCR
**Categories:** AI, Automation
**Tools:** 62: 27 read, 29 write, 6 destructive
**Users sign in with:** OAuth
**OAuth app:** Scalekit's or your own
**Built by:** Vendor MCP
**Try it:** [Playground in the Scalekit dashboard](https://app.scalekit.com/ws/signup?sk_intent=playground&provider=PHANTOMBUSTERMCP)

## What you can do

- **Run automation agents**: launch, schedule, stop, and fetch the output of PhantomBuster agents
- **Manage agents**: create, update, delete, and group agents across the organization
- **Store leads and companies**: save, search, and delete leads and company profiles in organization storage
- **Organize lead lists**: create, update, fetch, and delete lead lists and fetch leads by list
- **Review run results**: fetch run history, output data, and result objects for each agent execution
- **Sync contacts to your CRM**: save contacts with LinkedIn profile details to a connected HubSpot account

## Setup

1. ### Install the SDK

   **Node.js**

   ```bash
   npm install @scalekit-sdk/node dotenv
   ```

   **Python**

   ```bash
   pip install scalekit-sdk-python python-dotenv
   ```

2. ### Set your credentials

   Add your Scalekit credentials to your `.env` file. Find values in **[app.scalekit.com](https://app.scalekit.com)** > **Developers** > **API Credentials**.

   ```sh title=".env"
   SCALEKIT_ENVIRONMENT_URL=<your-environment-url>
   SCALEKIT_CLIENT_ID=<your-client-id>
   SCALEKIT_CLIENT_SECRET=<your-client-secret>
   ```

3. ### Create the PhantomBuster MCP connection

   In **AgentKit > Connections**, create a PhantomBuster MCP connection. The name you give it is the `connection_name` your code passes. See [Configure connections](/agentkit/connections/).

   Scalekit credentials are available for PhantomBuster, so you don't need to register an OAuth app.

4. ### Authorize a user and make your first call

   **Node.js** (`quickstart.mts`)

   ```typescript
   import { ScalekitClient } from '@scalekit-sdk/node'
   import 'dotenv/config'
   import { createInterface } from 'node:readline/promises'

   const scalekit = new ScalekitClient(
     process.env.SCALEKIT_ENVIRONMENT_URL,
     process.env.SCALEKIT_CLIENT_ID,
     process.env.SCALEKIT_CLIENT_SECRET,
   )
   const actions = scalekit.actions

   const connector = 'phantombustermcp'
   const identifier = 'user_123'

   // Generate an authorization link for the user
   const { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })
   console.log('Authorize PhantomBuster MCP:', link)
   const rl = createInterface({ input: process.stdin, output: process.stdout })
   await rl.question('Press Enter after authorizing...')
   rl.close()

   // Make your first call
   const result = await actions.executeTool({
     connector,
     identifier,
     toolName: 'phantombustermcp_users_fetch_me',
     toolInput: {},
   })
   console.log(result)
   ```

   ```bash
   npx tsx quickstart.mts
   ```

   **Python** (`quickstart.py`)

   ```python
   import os
   from scalekit import ScalekitClient
   from dotenv import load_dotenv
   load_dotenv()

   scalekit_client = ScalekitClient(
       env_url=os.getenv("SCALEKIT_ENVIRONMENT_URL"),
       client_id=os.getenv("SCALEKIT_CLIENT_ID"),
       client_secret=os.getenv("SCALEKIT_CLIENT_SECRET"),
   )
   actions = scalekit_client.actions

   connection_name = "phantombustermcp"
   identifier = "user_123"

   # Generate an authorization link for the user
   link_response = actions.get_authorization_link(
       connection_name=connection_name,
       identifier=identifier,
   )
   print("Authorize PhantomBuster MCP:", link_response.link)
   input("Press Enter after authorizing...")

   # Make your first call
   result = actions.execute_tool(
       tool_input={},
       tool_name="phantombustermcp_users_fetch_me",
       connection_name=connection_name,
       identifier=identifier,
   )
   print(result)
   ```

   ```bash
   python quickstart.py
   ```

   Each user signs in once. See [Authorize a user](/agentkit/tools/authorize/) for the full flow and statuses.

## Tools

Pass the exact name to `execute_tool`, with an input like each tool's example. To ask for a tool that's missing, use the [request form](https://scalekitsupport.portal.usepylon.com/forms/request-a-connector-tool).

**Node.js**

```typescript
const result = await actions.executeTool({
  toolName: 'phantombustermcp_agents_fetch',
  toolInput: {
    id: '1234567890',
  },
  connector: 'phantombustermcp',
  identifier: 'user_123',
})
```

**Python**

```python
result = actions.execute_tool(
    tool_name="phantombustermcp_agents_fetch",
    tool_input={
        "id": "1234567890",
    },
    connection_name="phantombustermcp",
    identifier="user_123",
)
```

`result.data` is the app's response as JSON, and `result.execution_id` (`executionId` in Node.js) is the ID of the call.

### `phantombustermcp_agents_fetch`

GetAgentById · Read-only

Retrieve a PhantomBuster agent by its unique ID. Returns agent metadata and optionally includes the agent's manifest, object definition, script code, slave agents, and sub-slave agents depending on the query flags provided.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `id` (`string`, required): The unique identifier of the PhantomBuster agent to fetch. Required. Example: '1234567890'.
- `withAgentObject` (`string`, optional): Set to "true" to include the full agent_object definition in the response. Useful when you need the agent's configuration object. Example: "true".
- `withCode` (`string`, optional): Set to "true" to include the agent's script source code in the response. Example: "true".
- `withManifest` (`string`, optional): Set to "true" to include the agent's manifest (capabilities and configuration schema) in the response. Example: "true".
- `withSlaves` (`string`, optional): Set to "true" to include the agent's slave agents (sub-automation agents linked to this agent) in the response. Example: "true".
- `withSubSlaves` (`string`, optional): Set to "true" to include the agent's sub-slave agents in the response. Requires withSlaves to also be set to "true". Example: "true".

Example input: `{"id":"1234567890"}`

### `phantombustermcp_agents_fetch_all`

FetchAllAgents · Read-only

Retrieves all agents belonging to the current user's organization on PhantomBuster. Supports filtering by input types, output types, and specific agent IDs.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `agentIds` (`string`, optional): If set, only the agents with the provided IDs will be returned. Can be a single ID or an array of IDs (max 100).
- `inputTypes` (`string`, optional): Filter agents by input types they consume (e.g. 'profileUrl', 'companyUrl'). Can be a single string or an array of strings.
- `outputTypes` (`string`, optional): Filter agents by output types they produce (e.g. 'fullName', 'job', 'company'). Can be a single string or an array of strings.
- `withAgentSlotsFactor` (`string`, optional): Set to 'true' to include the agent's reservedAgentSlotsFactor from the script branch configuration in the response.
- `withArgument` (`string`, optional): Set to 'true' to include each agent's default argument in the response.

Example input: `{}`

### `phantombustermcp_agents_fetch_deleted`

FetchDeletedAgents · Read-only

Retrieves all deleted agents belonging to the current user's organization on PhantomBuster. Useful for auditing or recovering information about previously deleted automations.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs: none.

Example input: `{}`

### `phantombustermcp_agents_fetch_output`

FetchAgentOutput · Read-only

Gets the output of the most recent container of an agent. Designed for incremental data retrieval — use fromOutputPos and prevContainerId to fetch only new output since your last call.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `id` (`string`, required): The unique identifier of the agent to fetch output from.
- `fromOutputPos` (`number`, optional): If set, the returned output will start from the specified position, enabling incremental output fetching.
- `prevContainerId` (`string`, optional): If set, the output will be retrieved from the container that ran after the specified previous container ID.
- `prevRuntimeEventIndex` (`number`, optional): If set, the container's runtime events will be returned starting from the specified index, enabling incremental event fetching.
- `prevStatus` (`string`, optional): If set, defines the container status that was previously observed on the client side. Accepted values: 'starting', 'running', 'finished', 'unknown', 'launch error', 'never launched'.

Example input: `{"id":"1234567890"}`

### `phantombustermcp_branches_fetch_all`

ListOrgBranches · Read-only

Retrieve all script branches associated with the authenticated organization. Branches represent different versions (staging vs. release) of PhantomBuster agent scripts and are used for managing deployments.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs: none.

Example input: `{}`

### `phantombustermcp_buyers_personas_fetch_all`

BuyersPersonasFetchAll · Read-only

Fetch all buyer personas defined for the organization. Returns the full list of buyer persona records without requiring any input parameters.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs: none.

Example input: `{}`

### `phantombustermcp_containers_fetch`

GetContainerById · Read-only

Retrieve a PhantomBuster container by its unique ID. Optionally include the result object, output data, runtime events, and navigation links to adjacent containers in the response.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `id` (`string`, required): The unique identifier of the container to retrieve. Required.
- `withNewerAndOlderContainerId` (`string`, optional): If set, the response will include the IDs of the next newer and next older containers relative to this one.
- `withOutput` (`string`, optional): If set, the output produced by the container will be included in the response.
- `withResultObject` (`string`, optional): If set, the container's result object will be included in the response.
- `withRuntimeEvents` (`string`, optional): If set, the runtime events associated with the container will be included in the response.

Example input: `{"id":"1234567890"}`

### `phantombustermcp_containers_fetch_all`

ListContainersForAgent · Read-only

Retrieve all containers associated with a specified PhantomBuster agent. Supports filtering by completion date, limiting result count, and optionally including runtime events. Containers represent individual executions of an agent.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `agentId` (`string`, required): The unique identifier of the agent whose containers to retrieve. Required.
- `beforeEndedAt` (`string`, optional): If set, only containers that ended before this date will be returned. Use ISO 8601 date format.
- `limit` (`string`, optional): If set, limits the number of containers returned to this value.
- `mode` (`string`, optional): Filter containers by status. 'all' returns all containers; 'finalized' returns only completed containers. One of: `all`, `finalized`.
- `withRuntimeEvents` (`string`, optional): If set, the response will include runtime events for each container.

Example input: `{"agentId":"<agentId>"}`

### `phantombustermcp_containers_fetch_output`

GetContainerOutput · Read-only

Retrieve the output data produced by a specific PhantomBuster container execution. The output can be returned as structured JSON or as raw plain text depending on the mode parameter.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `id` (`string`, required): The unique identifier of the container whose output to retrieve. Required.
- `mode` (`string`, optional): Output format mode. Set to 'json' (default) to receive structured JSON output, or 'raw' to receive the output as plain text. One of: `json`, `raw`.

Example input: `{"id":"1234567890"}`

### `phantombustermcp_containers_fetch_result_object`

GetContainerResultObject · Read-only

Retrieve the result object associated with a specific PhantomBuster container execution. The result object contains structured data about the outcome of the container run, including extracted data and execution summary.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `id` (`string`, required): The unique identifier of the container whose result object to retrieve. Required.

Example input: `{"id":"1234567890"}`

### `phantombustermcp_icps_fetch_all`

FetchAllIcps · Read-only

Fetch all Ideal Customer Profiles (ICPs) configured for the authenticated organization. Returns the complete list of ICP definitions used for lead scoring and targeting.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs: none.

Example input: `{}`

### `phantombustermcp_identities_search`

SearchIdentities · Read-only

Search for identities by ID, session cookie, profile ID, or identity type. Returns matching identity records. Defaults to LinkedIn identity type when type is omitted.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `id` (`string`, optional): The internal id of the identity to search.
- `profileId` (`string`, optional): The profile id of the identity to search.
- `sessionCookie` (`string`, optional): Session cookie to search by.
- `type` (`string`, optional): The type of identity to search. Defaults to 'linkedin' when omitted. One of: `linkedin`, `google`.

Example input: `{}`

### `phantombustermcp_org_storage_companies_objects_search`

SearchCompanyObjects · Read-only

Search company objects in org storage using a filter expression and optional pagination. Supports complex AND/OR filter trees. Use the org_storage_filter_help tool for the full operator and field reference.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `filter` (`object`, required): Filter object for querying company objects. ALWAYS wrap in a top-level { "and": [ ... ] }, even for a single condition. Company entity filter keys are mostly camelCase (e.g. employeeCount, websiteUrl). For the full operator reference, call the org_storage_filter_help tool. Required.
- `paginationOptions` (`object`, optional): Pagination options for the search results.

Example input: `{"filter":{}}`

### `phantombustermcp_org_storage_filter_help`

OrgStorageFilterHelp · Read-only

Returns the full reference for constructing org-storage filter objects: operator table, field lists for lead and company entities, lead-object property-change patterns, social-signal patterns, common pitfalls (boolean fields, regions, multi-field property changes), and worked examples. Call this when you need to build or edit the `filter` field on any org-storage tool (e.g. org_storage_lists_save, org_storage_leads_objects_search, org_storage_companies_objects_search) and the short pointer description on that field is not enough.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs: none.

Example input: `{}`

### `phantombustermcp_org_storage_leads_by_list_listid`

OrgStorageLeadsByListListId · Read-only

Fetch leads by their list id.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `listId` (`string`, required): Id of the lead list.
- `paginationOptions` (`object`, optional): Options for pagination
- `withCompanies` (`boolean`, optional): Option for retrieving the company associated to the lead
- `withLeadObjectsOfTypes` (`array`, optional): Array of lead object types

Example input: `{"listId":"<listId>"}`

### `phantombustermcp_org_storage_leads_objects_search`

OrgStorageLeadsObjectsSearch · Read-only

Search leads objects.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `filter` (`string`, required): Filter object for org-storage queries (leads, companies, lead_objects, company_objects). ALWAYS wrap in a top-level { "and": [ ... ] }, even for a single condition (bare { filter: ... } at the top will not render). Field keys are plain identifiers — write "location", not "lead.location"; the entity is set via the entity property inside the operator clause. Casing matters: lead/lead_object filter keys are snake_case (linkedin_job_title, NOT linkedinJobTitle); company entity filter keys are mostly camelCase (employeeCount, websiteUrl). For the full operator reference, field lists, frontend-compat rules, and worked examples, call the org_storage_filter_help tool.
- `paginationOptions` (`object`, optional): Pagination options
- `withLeads` (`boolean`, optional): Whether to include the parent lead data in the result

Example input: `{"filter":"<filter>"}`

### `phantombustermcp_org_storage_lists_fetch`

OrgStorageListsFetch · Read-only

Get one list by ID (Beta).

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `id` (`string`, required): Id of the lead list to fetch.

Example input: `{"id":"1234567890"}`

### `phantombustermcp_org_storage_lists_fetch_all`

OrgStorageListsFetchAll · Read-only

Get all the lists (Beta).

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs: none.

Example input: `{}`

### `phantombustermcp_orgs_fetch`

GetCurrentOrganization · Read-only

Retrieves the current organization's details including account information, settings, and plan data. Optionally returns the organization's global object, proxy configurations, CRM integrations, and custom AI prompts.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `withCrmIntegrations` (`string`, optional): If set, the organization's CRM integration configurations will be returned in the response.
- `withCustomPrompts` (`string`, optional): If set, the organization's custom AI prompt (customPromptOrg) will be returned in the response.
- `withGlobalObject` (`string`, optional): If set, the organization's globalObject will be returned in the response.
- `withProxies` (`string`, optional): If set, the organization's proxy pool configurations will be returned in the response.

Example input: `{}`

### `phantombustermcp_orgs_fetch_agent_groups`

GetOrganizationAgentGroups · Read-only

Retrieves the agent groups and their ordering for the current user's organization. Returns the full list of agent groups with their names, IDs, and the agents assigned to each group.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs: none.

Example input: `{}`

### `phantombustermcp_orgs_fetch_crm_access`

GetOrgCrmAccess · Read-only

Retrieve the CRM access credentials and connection details for the authenticated organization. Use this to verify CRM connectivity before attempting to fetch CRM resources.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs: none.

Example input: `{}`

### `phantombustermcp_orgs_fetch_crm_resources`

GetOrgCrmResources · Read-only

Retrieve a specific type of CRM resource for the authenticated organization. Supports fetching account info, contact lists, or contact properties depending on the specified resource type.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `resourceType` (`string`, required): The type of CRM resource to retrieve from the organization. Must be one of: 'account_info', 'contact_lists', or 'contact_properties'. One of: `account_info`, `contact_lists`, `contact_properties`.

Example input: `{"resourceType":"account_info"}`

### `phantombustermcp_orgs_fetch_resources`

GetOrganizationResources · Read-only

Retrieves the current organization's resource allocations and usage statistics. Returns information about available and consumed resources such as agent execution time, storage, and other plan-based limits.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs: none.

Example input: `{}`

### `phantombustermcp_orgs_fetch_running_containers`

GetOrgRunningContainers · Read-only

Retrieve all currently running containers for the authenticated organization. Returns a list of active container instances, including their IDs, statuses, and associated agent information.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs: none.

Example input: `{}`

### `phantombustermcp_scripts_fetch`

FetchScript · Read-only

Gets a PhantomBuster script by its ID. Optionally retrieve the script from a specific branch or environment, and include the script's source code in the response.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `id` (`string`, required): The unique identifier of the script to fetch.
- `branch` (`string`, optional): If set, the script will be retrieved from the specified branch. Must be 1-50 characters of word characters and hyphens.
- `environment` (`string`, optional): If set, the script will be retrieved from the specified environment. Accepted values: 'staging', 'release'. One of: `staging`, `release`.
- `withCode` (`string`, optional): If set, the script's source code will be included in the response. Accepted values: 'staging', 'release'. One of: `staging`, `release`.

Example input: `{"id":"1234567890"}`

### `phantombustermcp_scripts_fetch_all`

FetchAllScripts · Read-only

Gets all scripts associated with the current user. Optionally filter by organization, branch, script type (modules vs non-modules), or specific script IDs.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `branch` (`string`, optional): If set, only scripts from the specified branch will be fetched. Must be 1-50 word characters or hyphens.
- `exclude` (`string`, optional): Filter script types to return. Set to 'modules' to exclude module scripts, or 'non-modules' to return only module scripts. One of: `modules`, `non-modules`.
- `org` (`string`, optional): Name of the organization to fetch scripts from. If not set, scripts from the current user's default organization are returned.
- `scriptIds` (`array`, optional): If set, only the specified script IDs will be retrieved. Accepts an array (0-100 items) or a comma-separated string of IDs.

Example input: `{}`

### `phantombustermcp_users_fetch_me`

GetCurrentUser · Read-only

Retrieves the current authenticated user's profile information including account details and session data. If a sessionId is not provided, the endpoint will create a new session and return the newly created session ID. Optionally returns detailed organization info and custom AI prompts.

Read only: yes. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `detailedOrgId` (`string`, optional): If set, the corresponding detailed organization object will be returned in the response.
- `withCustomPrompts` (`string`, optional): If set to "true", includes customPromptUser and customPromptOrg fields in the response.

Example input: `{}`

### `phantombustermcp_agents_launch`

LaunchAgent · Write

Add a PhantomBuster agent to the launch queue to trigger a new execution. Supports passing arguments, bonus arguments (single-use overrides), controlling instance limits, and tagging the resulting container with metadata.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `id` (`string`, required): The unique identifier of the agent to launch. Required.
- `argument` (`string`, optional): Agent argument passed to the execution. Can be a JSON string or a plain object. Accessible in the agent's script via buster.argument.
- `arguments` (`string`, optional): Agent argument (alias for 'argument'). Can be a JSON string or a plain object. Accessible in the agent's script via buster.argument.
- `bonusArgument` (`string`, optional): Single-use bonus argument for this launch only. Can be a JSON string or a plain object. Merged with the main argument to form the effective argument available via buster.argument in the agent's script.
- `internalMetadata` (`string`, optional): PhantomBuster-managed key-value pairs used for internal container tagging. Can be null.
- `manualLaunch` (`boolean`, optional): If true, the agent will be marked as 'launched manually' rather than via automation.
- `maxInstanceCount` (`number`, optional): If set, the agent will only be launched if the current number of running instances is below this threshold. Minimum value: 1.
- `saveArgument` (`boolean`, optional): If true, the provided argument will be saved as the default launch options for this agent.
- `saveArguments` (`boolean`, optional): Alias for 'saveArgument'. If true, the provided argument will be saved as the default launch options for this agent.
- `userCustomMetadata` (`string`, optional): User-defined key-value pairs for tagging the resulting container. Can be null.

Example input: `{"id":"1234567890"}`

### `phantombustermcp_agents_launch_soon`

ScheduleAgentLaunch · Write

Schedules an agent to launch before a specific time. The agent will automatically start within the specified number of minutes unless it is launched manually before then.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `id` (`string`, required): The unique identifier of the agent to schedule for launch.
- `minutes` (`integer`, required): Number of minutes from now before the agent will automatically launch. If the agent is launched manually before this time, the automatic launch will not occur.
- `argument` (`string`, optional): Agent argument to pass at launch. Can be a JSON string or a plain object. Accessible in the agent's script via buster.argument.
- `arguments` (`string`, optional): Agent argument (plural form). Can be a JSON string or a plain object. Accessible in the agent's script via buster.argument.
- `saveArgument` (`boolean`, optional): If true, the provided argument will be saved as the default launch options for the agent.
- `saveArguments` (`boolean`, optional): If true, the provided argument will be saved as the default launch options for the agent (plural form).

Example input: `{"id":"1234567890","minutes":1}`

### `phantombustermcp_agents_save`

SaveAgent · Write

Creates a new PhantomBuster agent or updates an existing one. If an id is provided the corresponding agent will be updated. Otherwise a new agent will be created. Supports configuring script assignment, scheduling, notifications, proxy settings, and more.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `agentObject` (`string`, optional): JSON string representing the agent's object configuration.
- `applyScriptManifestDefaultSettings` (`boolean`, optional): If true, the script manifest's default settings will be applied to the agent.
- `argument` (`string`, optional): Default argument used to launch the agent. Can be a JSON string or a JSON object.
- `branch` (`string`, optional): If set, the upserted agent will be assigned to the specified branch.
- `environment` (`string`, optional): If set, the upserted agent will be assigned to the specified environment: 'staging' or 'release'.
- `executionTimeLimit` (`number`, optional): Maximum execution time in seconds. If exceeded, the agent will be stopped.
- `expireAt` (`number`, optional): Unix timestamp (milliseconds) for when the agent will be automatically deleted.
- `fileMgmt` (`string`, optional): File management type: 'folders' creates new files, 'mix' combines new and previous, 'delete' removes previous files. One of: `folders`, `mix`, `delete`.
- `fileMgmtMaxFolders` (`number`, optional): Maximum number of folders to keep for file management when fileMgmt is set to 'folders'.
- `id` (`string`, optional): If set, the agent with the corresponding id will be updated. Omit to create a new agent.
- `idempotencyKey` (`string`, optional): Optional key to ensure idempotent agent creation. Only applies when creating a new agent.
- `internalMetadata` (`object`, optional): Key-value pairs reserved for PhantomBuster internal use.
- `launchAfterAgentId` (`string`, optional): ID of the agent whose completion triggers this agent's launch. Required when launchType is 'after agent'.
- `launchOnceAt` (`number`, optional): Unix timestamp for when to launch the agent once. Required when launchType is 'once'.
- `launchType` (`string`, optional): Sets how the agent will be launched: 'manually', 'repeatedly', 'once', or 'after agent'. One of: `manually`, `repeatedly`, `once`, `after agent`.
- `masterAgentLaunchAfter` (`number`, optional): Number of minutes to wait before this agent launches once a slave agent finishes. When not set, the platform chooses a value between 10 and 15 minutes randomly.
- `masterAgentLaunchOnExitCodes` (`array`, optional): Exit codes of the finishing slave agent that trigger this agent's launch, or the string 'all' to trigger on any exit code.
- `maxParallelism` (`number`, optional): Maximum number of concurrent executions for this agent.
- `maxRetryNumber` (`number`, optional): Maximum number of retry attempts before the agent aborts.
- `name` (`string`, optional): Display name for the agent. Maximum 100 characters.
- `notifications` (`object`, optional): Notification settings for the agent, controlling email, Slack, and webhook alerts on run success/failure.
- `org` (`string`, optional): If set, the upserted agent will be linked to the specified organization slug.
- `proxyAddress` (`string`, optional): HTTP proxy address when proxyType is 'http', or proxy pool name when proxyType is 'pool'.
- `proxyPassword` (`string`, optional): Password for proxy authentication. Used when proxyType is 'http'.
- `proxyType` (`string`, optional): Proxy type to use: 'none', 'http', 'pool', or 'squid lease'. One of: `none`, `http`, `pool`, `squid lease`.
- `proxyUsername` (`string`, optional): Username for proxy authentication. Used when proxyType is 'http'.
- `repeatedLaunchPreset` (`string`, optional): Automatically sets the agent's launch schedule according to a named preset (e.g. 'Once per day'). One of: `Once every other day`, `Once per day`, `Once per day, at the start of the day`, `Twice per day`, `Thrice per day`, `4 times per day`, `6 times per day`, `8 times per day`, `Once every other hour`, `Once per hour`, `Twice per hour`, `Thrice per hour`, `4 times per hour`, `Once every other working hour`, `Once per working hour`, `Twice per working hour`, `Thrice per working hour`, `4 times per working hour`, `Once every other working hour, excluding weekends`, `Once per working hour, excluding weekends`, `Twice per working hour, excluding weekends`, `Thrice per working hour, excluding weekends`, `4 times per working hour, excluding weekends`.
- `repeatedLaunchTimes` (`object`, optional): Detailed schedule for repeated launches. Required when launchType is 'repeatedly' and a preset is not used. Provide timezone, minute, hour, day, dow, and month arrays.
- `script` (`string`, optional): If set, the upserted agent will be assigned to the specified script filename.
- `shouldPropagateUpdatedSettingsToWorkersRegardlessOfSessionType` (`boolean`, optional): If true, updated agent settings will be propagated to running workers regardless of the session type.
- `squidLeaseIdentifier` (`object`, optional): Squid proxy lease configuration for the agent, including group slug, refresh rate, location, and sublocation.
- `userCustomMetadata` (`object`, optional): User-defined key-value pairs for tagging and filtering agents.
- `wasSetupValidWhenSubmittedByTheFrontend` (`boolean`, optional): If true, indicates the agent's setup was considered complete/valid when submitted by the frontend.

Example input: `{}`

### `phantombustermcp_agents_stop`

StopAgent · Write

Stops a running PhantomBuster agent. Supports soft abort, cascading stop to slave agents, disabling next scheduled launch, and switching to manual launch mode.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `id` (`string`, required): The unique identifier of the agent to stop.
- `cascadeToAllSlaves` (`boolean`, optional): If true, all slave agents linked to this agent will also be recursively stopped, including nested slaves.
- `dontLaunchSoon` (`boolean`, optional): If true, disables the next scheduled 'launch soon' for this agent after stopping.
- `softAbort` (`boolean`, optional): If true, attempts to softly abort the agent rather than forcefully stopping it.
- `switchToManualLaunch` (`boolean`, optional): If true, switches the agent to manual launch mode after stopping.

Example input: `{"id":"1234567890"}`

### `phantombustermcp_agents_unschedule_all`

UnscheduleAllAgents · Write

Disables the automatic launch schedule for all agents in the current organization. After calling this, no agents will launch automatically until re-scheduled.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs: none.

Example input: `{}`

### `phantombustermcp_branches_create`

CreateBranch · Write

Creates a new script branch in PhantomBuster. Branches allow you to develop and test script changes in isolation before releasing them to production.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `name` (`string`, required): Name of the branch to create. Must be 1-50 characters and contain only word characters and hyphens (matching pattern ^[\w-]{1,50}$).

Example input: `{"name":"<name>"}`

### `phantombustermcp_branches_diff`

GetBranchDiff · Write

Retrieve the length difference between the staging and release branches for all scripts in the organization, optionally filtered by a specific script branch name. Use this to understand what changes are pending deployment.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `name` (`string`, optional): The name of the script branch to fetch the diff for. Must be 1-50 characters, containing only word characters and hyphens.

Example input: `{}`

### `phantombustermcp_branches_release`

ReleaseBranch · Write

Releases one or more scripts from a named branch to production. Scripts listed in scriptIds will be promoted from the specified branch into the release environment.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `name` (`string`, required): Name of the branch to release. Must be 1-50 characters and contain only word characters and hyphens.
- `scriptIds` (`array`, required): Array of script IDs to release from the specified branch.

Example input: `{"name":"<name>","scriptIds":[]}`

### `phantombustermcp_identities_events_save`

SaveIdentityEvent · Write

Save an event associated with an identity. Records an event of a specific type for a given profile ID, with arbitrary event data and an optional timestamp.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `event_data` (`object`, required): The event data of the identity event. Required. A free-form key-value map with event details.
- `event_type` (`string`, required): The type of the identity event. Required.
- `identity_type` (`string`, required): The identity type of the identity event. Required.
- `profile_id` (`string`, required): The profile id of the identity event. Must be non-empty and not whitespace-only. Required.
- `timestamp` (`number`, optional): Optional timestamp of the identity event in milliseconds since epoch. Must be between 1000000000000 and 9999999999999.

Example input: `{"event_data":{},"event_type":"<event_type>","identity_type":"<identity_type>","profile_id":"<profile_id>"}`

### `phantombustermcp_identities_generate_token`

GenerateIdentityToken · Write

Generate a new identity token for the authenticated session. This token can be used with the identities_save_with_token tool to associate a session token with an identity record.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs: none.

Example input: `{}`

### `phantombustermcp_identities_save`

SaveIdentity · Write

Save an identity record. Creates or updates a LinkedIn or Google identity with profile information such as name, profile URL, headline, and subscription titles.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `profileId` (`string`, required): The profile id of the identity to save. Required. Maximum 475 characters.
- `type` (`string`, required): The type of the identity to save. Either 'linkedin' or 'google'. Required. One of: `linkedin`, `google`.
- `firstName` (`string`, optional): The first name of the identity to save.
- `headline` (`string`, optional): The headline of the identity to save.
- `id` (`string`, optional): The internal id of the identity to save.
- `lastName` (`string`, optional): The last name of the identity to save.
- `profilePictureUrl` (`string`, optional): The profile picture URL of the identity to save.
- `profileUrl` (`string`, optional): The profile URL of the identity to save.
- `subscriptionTitles` (`array`, optional): Subscription titles of the identity to save. Can be a list of strings or null.
- `userId` (`string`, optional): The user id of the identity to save.

Example input: `{"profileId":"<profileId>","type":"linkedin"}`

### `phantombustermcp_identities_save_with_token`

SaveIdentityWithToken · Write

Save an identity record along with its authentication token and active credentials. Use this after generating a token with identities_generate_token to persist the full identity including session cookies.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `orgId` (`string`, required): The org_id of the identity to save. Required.
- `profileId` (`string`, required): The profile id of the identity to save. Required. Maximum 475 characters.
- `token` (`string`, required): The identity token. Required. Obtain from identities_generate_token.
- `type` (`string`, required): The type of the identity to save. Either 'linkedin' or 'google'. Required. One of: `linkedin`, `google`.
- `activeCredential` (`object`, optional): The active credential of the identity. Will replace activeCredentials in future versions.
- `activeCredentials` (`array`, optional): Active credentials of the identity to save. Deprecated — will be removed soon. Use activeCredential instead.
- `firstName` (`string`, optional): The first name of the identity to save.
- `headline` (`string`, optional): The headline of the identity to save.
- `id` (`string`, optional): The internal id of the identity to save.
- `lastName` (`string`, optional): The last name of the identity to save.
- `profilePictureUrl` (`string`, optional): The profile picture URL of the identity to save.
- `profileUrl` (`string`, optional): The profile URL of the identity to save.
- `subscriptionTitles` (`array`, optional): Subscription titles of the identity to save. Can be a list of strings or null.
- `userId` (`string`, optional): The user id of the identity to save.

Example input: `{"orgId":"<orgId>","profileId":"<profileId>","token":"<token>","type":"linkedin"}`

### `phantombustermcp_org_storage_companies_objects_save`

SaveCompanyObject · Write

Save one company object to org storage. Creates or updates a single company record identified by its LinkedIn company ID, type, and slug.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `linkedinCompanyId` (`string`, required): The external id of the company scraped from LinkedIn. Required.
- `properties` (`object`, required): The properties of the company object. Required. A free-form key-value map of company attributes.
- `slug` (`string`, required): The slug of the company object. Maximum 470 characters. Required.
- `type` (`string`, required): The type of company object. Maximum 500 characters. Required.
- `id` (`string`, optional): The internal id of the company object.
- `orgId` (`string`, optional): The org id associated with the company object.

Example input: `{"linkedinCompanyId":"<linkedinCompanyId>","properties":{},"slug":"<slug>","type":"<type>"}`

### `phantombustermcp_org_storage_companies_objects_save_many`

SaveManyCompanyObjects · Write

Save many company objects to org storage in a single batch operation. Each item in the array represents a company record to create or update.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `items` (`array`, required): Array of company objects to insert or update. Required.

Example input: `{"items":[]}`

### `phantombustermcp_org_storage_leads_objects_save`

OrgStorageLeadsObjectsSave · Write

Save one lead object.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `agentId` (`string`, required): id of an agent
- `properties` (`object`, required): properties of the object
- `slug` (`string`, required): slug of the object to save
- `type` (`string`, required): type of object to save
- `leadId` (`string`, optional): id of a lead
- `leadObjectId` (`string`, optional): id of a lead object
- `leadSlug` (`string`, optional): slug of a lead
- `leadUrn` (`string`, optional): urn of a lead

Example input: `{"agentId":"<agentId>","properties":{},"slug":"<slug>","type":"<type>"}`

### `phantombustermcp_org_storage_leads_objects_save_many`

OrgStorageLeadsObjectsSaveMany · Write

Save many lead objects.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `agentId` (`string`, required): id of an agent
- `properties` (`object`, required): properties of the object
- `slug` (`string`, required): slug of the object to save
- `type` (`string`, required): type of object to save
- `leadId` (`string`, optional): id of a lead
- `leadObjectId` (`string`, optional): id of a lead object
- `leadSlug` (`string`, optional): slug of a lead
- `leadUrn` (`string`, optional): urn of a lead

Example input: `{"agentId":"<agentId>","properties":{},"slug":"<slug>","type":"<type>"}`

### `phantombustermcp_org_storage_leads_save`

SaveLead · Write

Saves a single lead to PhantomBuster organization storage (Beta). Requires a LinkedIn profile URL. Supports enrichment fields including contact info, company details, CRM account mappings, and AI-generated properties.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `linkedinProfileUrl` (`string`, required): LinkedIn profile URL of the lead. Required.
- `aiGeneratedProperties` (`object`, optional): AI-generated properties for the lead, as a map of property name to string value.
- `audienceOfLeads` (`array`, optional): List of lead IDs that this lead is an audience of.
- `civility` (`string`, optional): Lead's civility/title (e.g. Mr, Ms, Dr).
- `companyIndustry` (`string`, optional): Industry of the lead's company.
- `companyName` (`string`, optional): Lead's current company name.
- `companyWebsite` (`string`, optional): Lead's company website URL.
- `crmAccountRelativeProperties` (`array`, optional): Collection of CRM-related properties grouped by CRM name (one item per CRM: hubspot, pipedrive, or salesforce).
- `customResultsFileName` (`string`, optional): Custom name for the results file associated with this lead.
- `error` (`string`, optional): Error message from the agent script, if any.
- `firstName` (`string`, optional): Lead's first name.
- `lastName` (`string`, optional): Lead's last name.
- `linkedinAccountRelativeProperties` (`array`, optional): Collection of lead LinkedIn properties grouped by the scraping LinkedIn user (source account), including connection degree.
- `linkedinCompanyId` (`string`, optional): LinkedIn company ID for the lead's employer.
- `linkedinCompanySlug` (`string`, optional): Lead's company LinkedIn slug identifier.
- `linkedinCompanyUrl` (`string`, optional): LinkedIn company URL (deprecated, use linkedinCompanySlug instead).
- `linkedinDescription` (`string`, optional): Lead's LinkedIn profile description/summary.
- `linkedinFollowersCount` (`number`, optional): Number of followers the lead has on LinkedIn.
- `linkedinHeadline` (`string`, optional): Lead's LinkedIn profile headline.
- `linkedinIsHiringBadge` (`boolean`, optional): Whether the lead has the 'hiring' badge on LinkedIn.
- `linkedinIsOpenToWorkBadge` (`boolean`, optional): Whether the lead has the 'open to work' badge on LinkedIn.
- `linkedinJobDateRange` (`string`, optional): Date range of the lead's current LinkedIn job.
- `linkedinJobDescription` (`string`, optional): Description of the lead's current LinkedIn job.
- `linkedinJobLocation` (`string`, optional): Location associated with the lead's current LinkedIn job.
- `linkedinJobTitle` (`string`, optional): Lead's current job title from LinkedIn.
- `linkedinOpenProfile` (`boolean`, optional): Whether the lead's LinkedIn profile is an Open Profile.
- `linkedinPreviousCompanyUrl` (`string`, optional): LinkedIn URL of the lead's previous company.
- `linkedinPreviousJobDateRange` (`string`, optional): Date range of the lead's previous LinkedIn job.
- `linkedinPreviousJobDescription` (`string`, optional): Description of the lead's previous LinkedIn job.
- `linkedinPreviousJobLocation` (`string`, optional): Location associated with the lead's previous LinkedIn job.
- `linkedinPreviousJobTitle` (`string`, optional): Lead's previous job title on LinkedIn.
- `linkedinPreviousSchoolCompanyUrl` (`string`, optional): LinkedIn company URL of the lead's previous school.
- `linkedinPreviousSchoolDateRange` (`string`, optional): Date range of the lead's previous school on LinkedIn.
- `linkedinPreviousSchoolDegree` (`string`, optional): Degree obtained by the lead at their previous school on LinkedIn.
- `linkedinPreviousSchoolDescription` (`string`, optional): Description of the lead's previous school on LinkedIn.
- `linkedinPreviousSchoolName` (`string`, optional): Name of the lead's previous school on LinkedIn.
- `linkedinProfileId` (`string`, optional): Lead's LinkedIn profile ID.
- `linkedinProfileImageUrl` (`string`, optional): URL of the lead's LinkedIn profile picture.
- `linkedinProfileImageUrn` (`string`, optional): LinkedIn URN of the lead's profile picture image.
- `linkedinProfileUrn` (`string`, optional): LinkedIn URN of the lead's profile.
- `linkedinSchoolCompanyUrl` (`string`, optional): LinkedIn company URL of the lead's current school.
- `linkedinSchoolDateRange` (`string`, optional): Date range of the lead's current school on LinkedIn.
- `linkedinSchoolDegree` (`string`, optional): Degree obtained by the lead at their current school on LinkedIn.
- `linkedinSchoolDescription` (`string`, optional): Description of the lead's current school on LinkedIn.
- `linkedinSchoolName` (`string`, optional): Name of the lead's current school on LinkedIn.
- `linkedinSkillsLabel` (`string`, optional): Label summarizing the lead's LinkedIn skills.
- `location` (`string`, optional): Lead's geographic location.
- `metadata` (`object`, optional): Metadata from the agent script, wrapped in a 'data' object.
- `personalEmails` (`array`, optional): Lead's personal email addresses.
- `phoneNumbers` (`array`, optional): Lead's phone numbers.
- `previousCompanyName` (`string`, optional): Name of the lead's previous company.
- `professionalEmails` (`array`, optional): Lead's professional email addresses.
- `salesNavigatorProfileUrl` (`string`, optional): Lead's LinkedIn Sales Navigator profile URL.
- `twitterProfileUrl` (`string`, optional): Lead's Twitter/X profile URL.
- `websites` (`array`, optional): Lead's associated websites.

Example input: `{"linkedinProfileUrl":"<linkedinProfileUrl>"}`

### `phantombustermcp_org_storage_leads_save_many`

SaveManyLeads · Write

Saves multiple leads to PhantomBuster organization storage (Beta). Accepts a batch of 1-20 leads with LinkedIn profile URLs and associated metadata. Each lead must include a LinkedIn profile URL.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `leads` (`array`, required): Array of 1-20 lead objects to save. Each lead must have a linkedinProfileUrl.

Example input: `{"leads":[]}`

### `phantombustermcp_org_storage_lists_save`

OrgStorageListsSave · Write

Save a list (Beta). Creates a new list or updates an existing one. For more information, see the Creating and updating leads lists using filters page in the Developer Guides.

Read only: no. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `filter` (`string`, required): Filter object for org-storage queries (leads, companies, lead_objects, company_objects). ALWAYS wrap in a top-level { "and": [ ... ] }, even for a single condition (bare { filter: ... } at the top will not render). Field keys are plain identifiers — write "location", not "lead.location"; the entity is set via the entity property inside the operator clause. Casing matters: lead/lead_object filter keys are snake_case (linkedin_job_title, NOT linkedinJobTitle); company entity filter keys are mostly camelCase (employeeCount, websiteUrl). For the full operator reference, field lists, frontend-compat rules, and worked examples, call the org_storage_filter_help tool.
- `name` (`string`, required): Name of the list (1-100 chars)
- `description` (`string`, optional): Description of the list
- `id` (`string`, optional): ID of an existing list (omit to create a new one)
- `listProcessorConfiguration` (`object`, optional): List processor configuration object (free-form)
- `tags` (`array`, optional): Tags for the list

Example input: `{"filter":"<filter>","name":"<name>"}`

### `phantombustermcp_orgs_export_agent_usage`

ExportOrganizationAgentUsage · Write

Exports a CSV file containing agent usage data for the current user's organization. The export includes details on how agents have been used over the specified number of days. The number of days should not exceed 6 months (approximately 180 days).

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `days` (`string`, required): Number of days of agent usage data to export. Must not exceed 6 months (approximately 180 days).

Example input: `{"days":"<days>"}`

### `phantombustermcp_orgs_export_container_usage`

ExportOrganizationContainerUsage · Write

Exports a CSV file containing container usage data for the current user's organization. The export includes details on container execution over the specified number of days. Optionally filter by a specific agent ID. The number of days should not exceed 6 months (approximately 180 days).

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `days` (`string`, required): Number of days of container usage data to export. Must not exceed 6 months (approximately 180 days).
- `agentId` (`string`, optional): If set, the data will only be exported for this specific agent ID.

Example input: `{"days":"<days>"}`

### `phantombustermcp_orgs_save`

UpdateCurrentOrganization · Write

Updates the current organization's profile and settings. Allows modifying the organization name, display name, timezone, company info, billing details, proxy pools, CRM integration options, and custom AI prompt. Only web or MCP sessions are allowed to call this endpoint. Do not include the X-Phantombuster-Org header when calling this endpoint.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `additionalInvoiceInformation` (`string`, optional): Additional information to include on invoices (max 100 characters). Set to null to clear.
- `billingAddress` (`string`, optional): New billing address for the organization. Provide an object with street, city, zip, and countryCode, or null to clear.
- `billingFirstName` (`string`, optional): New billing contact first name for the organization. Set to null to clear.
- `billingLastName` (`string`, optional): New billing contact last name for the organization. Set to null to clear.
- `billingMail` (`string`, optional): New billing email address for the organization. Set to null to clear.
- `company` (`string`, optional): New company name for the organization (max 100 characters). Set to null to clear.
- `crmIntegrationOptions` (`object`, optional): CRM integration options for the organization.
- `customPromptOrg` (`string`, optional): Custom AI prompt at the workspace/organization level (max 10000 characters). Set to null to clear.
- `displayName` (`string`, optional): New display name for the organization (max 100 characters).
- `globalObject` (`string`, optional): New global object for the organization shared across all agents. Set to null to clear.
- `name` (`string`, optional): New internal organization name (max 100 characters).
- `proxies` (`string`, optional): New proxy pool configuration for the organization. Set to null to clear.
- `timezone` (`string`, optional): New timezone for the organization (max 100 characters). Changing the timezone affects automatic agent scheduling.
- `vatId` (`string`, optional): New VAT ID for the organization (max 100 characters). Set to null to clear.

Example input: `{}`

### `phantombustermcp_orgs_save_agent_groups`

SaveOrganizationAgentGroups · Write

Updates the agent groups and their ordering for the current user's organization. The order of the groups and agents within each group will be preserved as provided. Each group can be referenced either by its string ID or as a full object with id, name, and agents array.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `agentGroups` (`array`, required): New agent groups configuration. Order of groups and agents within each group will be preserved. Each item can be a group ID string or a full group object with id, name, and agents.

Example input: `{"agentGroups":[]}`

### `phantombustermcp_orgs_save_crm_contact`

SaveCrmContact · Write

Save a new contact to a connected CRM integration (currently HubSpot). Creates or updates a contact record with profile information such as name, LinkedIn URL, email, phone, job title, and company.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `contact` (`object`, required): Contact information for creation or update. Required.
- `crmName` (`string`, required): The CRM integration name. Currently only 'hubspot' is supported. Required.

Example input: `{"contact":{},"crmName":"<crmName>"}`

### `phantombustermcp_scripts_access_list`

UpdateScriptAccessList · Write

Updates the access list of a script branch on PhantomBuster. Allows adding or removing an organization or user from the script's access list.

Read only: no. Destructive: no. Idempotent (safe to retry): yes.

Inputs:

- `branch` (`string`, required): Name of the branch to update the access list for.
- `name` (`string`, required): Name of the script to update the access list for. Must match pattern like 'myscript.js'.
- `add` (`string`, optional): Organization or user slug to add to the access list. Optional.
- `remove` (`string`, optional): Organization or user slug to remove from the access list. Optional.

Example input: `{"branch":"<branch>","name":"<name>"}`

### `phantombustermcp_scripts_code`

FetchScriptCode · Write

Gets the source code of a PhantomBuster script by name. Optionally fetch from a specific organization, branch, or environment (staging or release).

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `script` (`string`, required): Name of the script file to fetch, including extension. Must match the pattern for .js or .coffee files (e.g. 'my-script.js').
- `branch` (`string`, optional): If set, the specified branch will be used to fetch the script code.
- `environment` (`string`, optional): If set, the specified environment will be used to fetch the script code. Accepted values: 'staging', 'release'. One of: `staging`, `release`.
- `org` (`string`, optional): If set, the specified organization will be used to fetch the script code.

Example input: `{"script":"my-script.js"}`

### `phantombustermcp_scripts_save`

SaveScript · Write

Creates a new script or updates an existing one on PhantomBuster. If an id is provided, the corresponding script will be updated. Otherwise, a new script will be created.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `branch` (`string`, optional): Name of the branch to associate with the script. Optional.
- `code` (`string`, optional): JavaScript source code of the script. Maximum 600,000 characters.
- `id` (`string`, optional): If set, the script with the corresponding id will be updated. Leave blank to create a new script.
- `manifest` (`object`, optional): JSON script manifest describing the script's slug, description, argument schema, default settings, and other metadata used by PhantomBuster.
- `markdown` (`string`, optional): Markdown documentation for the script. Maximum 200,000 characters.
- `name` (`string`, optional): Name of the script file. Prepend with 'lib-' to define as a module. Must end in .js or .coffee.

Example input: `{}`

### `phantombustermcp_scripts_visibility`

UpdateScriptVisibility · Write

Updates the visibility of a script branch on PhantomBuster. Controls whether the script is private, semi-public, public, semi open source, or open source.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `branch` (`string`, required): Name of the branch to change visibility for.
- `name` (`string`, required): Name of the script to change visibility for. Must match pattern like 'myscript.js' or 'my-script.coffee'.
- `visibility` (`string`, required): New visibility level to set for the branch. Options: private, semi public, public, semi open source, open source. One of: `private`, `semi public`, `public`, `semi open source`, `open source`.

Example input: `{"branch":"<branch>","name":"<name>","visibility":"private"}`

### `phantombustermcp_users_update_me`

UpdateCurrentUser · Write

Updates the current authenticated user's profile information. Allows modifying personal details such as name, phone, company, job title, team, and preferences including newsletter subscription, developer mode, and beta experiments. Also supports setting a custom AI prompt at the user level.

Read only: no. Destructive: no. Idempotent (safe to retry): no.

Inputs:

- `company` (`string`, optional): New company name for the user (max 100 characters). Set to null to clear.
- `customPromptUser` (`string`, optional): Custom AI prompt at the user level (max 10000 characters). Set to null to clear.
- `developerMode` (`boolean`, optional): If set to true, developer-specific features will be enabled for the user.
- `enabledExperiments` (`string`, optional): List of beta experiments to enable on the user's account. Valid values: hubspotWidget, stepSetup, myPhantoms, navbar, seeBetaPhantoms, showCompatiblePhantomsLink, advancedChat. Set to null to clear.
- `firstName` (`string`, optional): New first name for the user (max 100 characters).
- `job` (`string`, optional): New job title for the user (max 100 characters). Set to null to clear.
- `lastName` (`string`, optional): New last name for the user (max 100 characters).
- `newsletter` (`boolean`, optional): If set to true, the user agrees to subscribe to the PhantomBuster newsletter.
- `phone` (`string`, optional): New phone number for the user (max 100 characters). Set to null to clear.
- `userCompanySize` (`string`, optional): New company size for the user (max 100 characters). Set to null to clear.
- `userGoal` (`string`, optional): New primary goal for the user (max 100 characters). Set to null to clear.
- `userMainPlatform` (`string`, optional): New main platform for the user (max 100 characters). Set to null to clear.
- `userReferralSource` (`string`, optional): How the user heard about PhantomBuster (max 100 characters). Set to null to clear.
- `userTeam` (`string`, optional): New team name for the user (max 100 characters). Set to null to clear.

Example input: `{}`

### `phantombustermcp_agents_delete`

DeleteAgent · Destructive

Permanently deletes a PhantomBuster agent by its unique ID. This action is irreversible and will remove the agent and all associated data.

Read only: no. Destructive: yes. Idempotent (safe to retry): no.

Inputs:

- `id` (`string`, required): Unique ID of the agent to delete.

Example input: `{"id":"1234567890"}`

### `phantombustermcp_branches_delete`

DeleteBranch · Destructive

Permanently deletes a script branch by its ID. This action cannot be undone — all scripts associated with the branch will be removed from that branch.

Read only: no. Destructive: yes. Idempotent (safe to retry): no.

Inputs:

- `id` (`string`, required): The unique identifier of the branch to delete.

Example input: `{"id":"1234567890"}`

### `phantombustermcp_org_storage_leads_delete_many`

OrgStorageLeadsDeleteMany · Destructive

Delete many leads.

Read only: no. Destructive: yes. Idempotent (safe to retry): no.

Inputs:

- `ids` (`array`, required): Ids of the leads to delete

Example input: `{"ids":[]}`

### `phantombustermcp_org_storage_leads_objects_delete`

OrgStorageLeadsObjectsDelete · Destructive

Delete one or more leads objects.

Read only: no. Destructive: yes. Idempotent (safe to retry): no.

Inputs:

- `leadObjectId` (`string`, optional): id of a lead object to delete
- `slug` (`string`, optional): slug of the object to delete
- `type` (`string`, optional): type of object to delete

Example input: `{}`

### `phantombustermcp_org_storage_lists_delete`

OrgStorageListsDelete · Destructive

Delete a list (Beta).

Read only: no. Destructive: yes. Idempotent (safe to retry): yes.

Inputs:

- `id` (`string`, required): Id of the list to delete

Example input: `{"id":"1234567890"}`

### `phantombustermcp_scripts_delete`

DeleteScript · Destructive

Deletes a PhantomBuster script by its ID. This action is irreversible. Optionally specify a branch and environment to target a specific version.

Read only: no. Destructive: yes. Idempotent (safe to retry): no.

Inputs:

- `id` (`string`, required): ID of the script to delete.
- `branch` (`string`, optional): Branch of the script to delete. Optional.
- `environment` (`string`, optional): Environment of the script to delete. Either 'staging' or 'release'. One of: `staging`, `release`.

Example input: `{"id":"1234567890"}`

## Related

Other ways to connect PhantomBuster:

- [API key](/agentkit/connectors/phantombuster/): Scalekit connector, API key, 56 tools

Other AI connectors ([all 116](/agentkit/connectors/?category=ai)):

- [Chorus](/agentkit/connectors/chorus/): Scalekit connector, Username and password, 9 tools
- [Gong](/agentkit/connectors/gong/): Scalekit connector, OAuth, 49 tools
- [Jiminny](/agentkit/connectors/jiminny/): Scalekit connector, Access token, 27 tools


---

## More Scalekit documentation

| Resource | What it contains | When to use it |
|----------|-----------------|----------------|
| [/llms.txt](/llms.txt) | Structured index with routing hints per product area | Start here — find which documentation set covers your topic before loading full content |
| [/llms-full.txt](/llms-full.txt) | Complete documentation for all Scalekit products in one file | Use when you need exhaustive context across multiple products or when the topic spans several areas |
| [sitemap-0.xml](https://docs.scalekit.com/sitemap-0.xml) | Full URL list of every documentation page | Use to discover specific page URLs you can fetch for targeted, page-level answers |
