home / skills / composiohq / awesome-claude-skills / phantombuster-automation

phantombuster-automation skill

/phantombuster-automation

This skill automates PhantomBuster workflows for lead generation and data extraction, managing agents, scripts, and resources via Composio MCP.

npx playbooks add skill composiohq/awesome-claude-skills --skill phantombuster-automation

Review the files below or copy the command above to add this skill to your agents.

Files (1)
SKILL.md
4.6 KB
---
name: PhantomBuster Automation
description: "Automate lead generation, web scraping, and social media data extraction workflows through PhantomBuster's cloud platform via Composio"
requires:
  mcp:
    - rube
---

# PhantomBuster Automation

Automate cloud-based data extraction and lead generation -- manage agents and scripts, monitor organization resources and usage, track container execution, and solve captcha challenges -- all orchestrated through the Composio MCP integration.

**Toolkit docs:** [composio.dev/toolkits/phantombuster](https://composio.dev/toolkits/phantombuster)

---

## Setup

1. Connect your PhantomBuster account through the Composio MCP server at `https://rube.app/mcp`
2. The agent will prompt you with an authentication link if no active connection exists
3. Once connected, all `PHANTOMBUSTER_*` tools become available for execution

---

## Core Workflows

### 1. List All Agents
Fetch every agent associated with your account or organization to inventory automation workflows.

**Tool:** `PHANTOMBUSTER_GET_AGENTS_FETCH_ALL`

```
No parameters required -- returns all agents with IDs and metadata.
Authenticate your API key first.
```

Use agent IDs from this response when fetching containers or monitoring specific automations.

---

### 2. List All Scripts
Retrieve all scripts available under your account (without code bodies) for script management.

**Tool:** `PHANTOMBUSTER_GET_SCRIPTS_FETCH_ALL`

```
No parameters required -- returns script metadata without source code.
```

---

### 3. Monitor Organization Resources & Quotas
Check your organization's current resource usage and quota limits to plan automation capacity.

**Tool:** `PHANTOMBUSTER_GET_ORGS_FETCH_RESOURCES`

```
No parameters required -- returns resource allocation and current usage metrics.
```

---

### 4. Retrieve Agent Containers
Fetch all execution containers for a specific agent to monitor run history and status.

**Tool:** `PHANTOMBUSTER_GET_CONTAINERS_FETCH_ALL`

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `agentId` | string | Yes | Agent ID from `PHANTOMBUSTER_GET_AGENTS_FETCH_ALL` |

---

### 5. Export Agent Usage Report
Download a CSV report of all agents' run statistics for your organization.

**Tool:** `PHANTOMBUSTER_GET_ORGS_EXPORT_AGENT_USAGE`

```
Returns a downloadable CSV with comprehensive agent execution statistics.
```

---

### 6. Solve hCaptcha Challenges
Obtain a valid hCaptcha token for automated form submissions or scraping flows that require captcha solving.

**Tool:** `PHANTOMBUSTER_POST_HCAPTCHA`

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `siteKey` | string | Yes | Public site key of the hCaptcha widget |
| `pageUrl` | string | Yes | Full URL of the page with the captcha |
| `proxy` | string | No | Proxy URL (e.g., `http://user:pass@host:port`) |
| `userAgent` | string | No | Custom User-Agent string to simulate |

---

## Known Pitfalls

| Pitfall | Details |
|---------|---------|
| **Agent ID required for containers** | `PHANTOMBUSTER_GET_CONTAINERS_FETCH_ALL` requires a valid `agentId` -- always resolve it first via `PHANTOMBUSTER_GET_AGENTS_FETCH_ALL` |
| **API key authentication** | All PhantomBuster tools require a valid API key connection -- verify authentication before calling any tools |
| **Script bodies not included** | `PHANTOMBUSTER_GET_SCRIPTS_FETCH_ALL` returns metadata only, not source code |
| **Organization scope** | Resource and usage tools operate at the organization level tied to your API key -- ensure the correct org is targeted |
| **Branch operations** | `PHANTOMBUSTER_GET_BRANCHES_FETCH_ALL` and `PHANTOMBUSTER_GET_BRANCHES_DIFF` are for advanced script versioning -- use them to assess staging vs. release changes before deployment |

---

## Quick Reference

| Tool Slug | Purpose |
|-----------|---------|
| `PHANTOMBUSTER_GET_AGENTS_FETCH_ALL` | List all agents in your account |
| `PHANTOMBUSTER_GET_SCRIPTS_FETCH_ALL` | List all scripts (metadata only) |
| `PHANTOMBUSTER_GET_ORGS_FETCH_RESOURCES` | Check organization resource usage and quotas |
| `PHANTOMBUSTER_GET_CONTAINERS_FETCH_ALL` | Get all containers for a specific agent |
| `PHANTOMBUSTER_GET_ORGS_EXPORT_AGENT_USAGE` | Export agent usage as CSV |
| `PHANTOMBUSTER_POST_HCAPTCHA` | Solve hCaptcha challenges for automation |
| `PHANTOMBUSTER_GET_ORGS_FETCH` | Fetch organization details |
| `PHANTOMBUSTER_GET_ORGS_FETCH_AGENT_GROUPS` | Get agent groups and ordering |
| `PHANTOMBUSTER_GET_BRANCHES_FETCH_ALL` | List all script branches |
| `PHANTOMBUSTER_GET_BRANCHES_DIFF` | Compare staging vs. release branches |

---

*Powered by [Composio](https://composio.dev)*

Overview

This skill automates cloud-based lead generation, web scraping, and social media extraction using PhantomBuster through the Composio MCP integration. It provides tools to inventory agents and scripts, monitor organization quotas, track container executions, export usage reports, and solve hCaptcha challenges. Setup requires connecting your PhantomBuster account via the Composio MCP server. Once authenticated, all PHANTOMBUSTER_* tools become available for orchestration.

How this skill works

The skill calls PhantomBuster endpoints exposed via Composio tooling to list agents, list scripts (metadata only), fetch execution containers, and query organization resources. It can export CSV usage reports and request hCaptcha tokens with optional proxy and user-agent parameters. Authentication uses your PhantomBuster API key through the MCP server; tools will prompt for auth if not connected.

When to use it

  • When you need to inventory all PhantomBuster agents and their metadata.
  • To monitor org-level resource usage and quota before scheduling large runs.
  • When tracking run history or troubleshooting specific agent executions via containers.
  • To export comprehensive agent usage reports for billing or analysis.
  • When automated scraping encounters hCaptcha and you need programmatic token solving.

Best practices

  • Authenticate the PhantomBuster API key through the Composio MCP server before running tools.
  • Always call get-agents first to resolve agentId values required by container queries.
  • Use org resource checks to avoid quota overruns and to plan parallel runs responsibly.
  • Respect site terms of service and rate limits; use proxies and custom user-agents only when permitted.
  • Treat script metadata as an index; script bodies are not returned by the metadata-only endpoint.

Example use cases

  • Build a lead-generation pipeline that lists agents, triggers runs, and exports CSVs for CRM ingestion.
  • Audit automation inventory: list all scripts and agents to document ownership and versioning.
  • Monitor usage: run org resource checks daily to detect quota spikes and plan capacity.
  • Debug failed runs: fetch agent containers and run histories to identify flaky scripts or environment issues.
  • Bypass hCaptcha during authorized scraping workflows by requesting tokens with proxy and UA settings.

FAQ

Do script calls return source code?

No. The scripts listing returns metadata only; it does not include script bodies or source code.

What is required to fetch containers for an agent?

You must supply a valid agentId obtained from the get-agents response. Container queries will fail without it.

How do I solve hCaptcha via the skill?

Use the POST hCaptcha tool with siteKey and pageUrl. Optionally include a proxy and userAgent to match the target environment.