Skip to content
EN
Get API key
Browse documentation

Integrations

OpenClaw

Give your OpenClaw agent Google Search and YouTube tools for research and recurring briefings.

On this page

Before you start

Have OpenClaw installed and working. This hosted MCP setup uses OAuth for Google Search, YouTube Search, Metadata and Transcripts. You can create a FlashData account during sign-in.

1. Add the MCP server

Run this on the machine and OpenClaw profile that runs your gateway. It saves the server configuration; the login and tool call below verify that your agent can actually use it. Use the same profile for every command on this page.

Bash / PowerShell 7
openclaw mcp set flashdata '{
  "url": "https://data.flashdata.dev/mcp",
  "transport": "streamable-http",
  "auth": "oauth",
  "oauth": {
    "scope": "mcp:research",
    "clientMetadataUrl": "https://api.flashdata.dev/oauth/clients/openclaw.json"
  }
}'

2. Sign in

Run the login command. In the browser, sign in or create and verify an account, then approve access. Wait for the terminal to confirm login. Queries use that account's credits.

Sign in
openclaw mcp login flashdata
openclaw mcp doctor flashdata --probe

Check the connection for free

Open a new conversation in the Control UI or your connected chat channel. Send this prompt; both calls should succeed. A successful registry probe alone does not prove that this conversation can use the tools.

Paste into your agent
Use the flashdata MCP connection.
Call get_balance with {} and get_pricing with {"source":"google_search","request_count":1}.
Report available credits and the estimated price. Do not run a search.

3. Run your first task

Send this to your connected agent. The checks are free; the single search uses credits.

First task prompt
Use the flashdata MCP server. Check my balance and the price of one Google search.
If funded, call google_search once with query "battery recycling research", num 5 and mode "realtime".
Give me a short briefing with source titles, URLs and excerpts.
Cite sources and report actual credits used. Stop after this task.

What you should see

Look for a completed google_search tool call with status: done, source links from results[].organic and an answer based on those sources. Usage comes from usage.credits; it is not the number of results. Empty results should be reported as empty.

What you can ask for

This OAuth connection covers research tools. YouTube Download uses an owner API key and destination storage through the API or CLI.

TaskMCP tool
Find web sources for an answer or implementationgoogle_search
Find relevant YouTube videosyoutube_search
Read video titles, channels and metadatayoutube_metadata
Retrieve a video's transcript for a summaryyoutube_transcript
Check available credits and request costget_balance · get_pricing

Reuse access for recurring tasks

Use the OpenClaw profile and agent that passed the first task. The gateway's scheduled runs must have the same MCP connection and tool permissions as your chat.

Verify saved access

Run this free check in a fresh session in the scheduled environment. Both calls should succeed without a new browser login.

Reuse check
Reuse the existing flashdata MCP connection.
Call get_balance with {} and get_pricing with {"source":"google_search","request_count":1}.
Report whether both succeeded. Do not search or create new access.

Create the recurring task

In your host's scheduler, choose a time and time zone, for example daily at 09:00 Asia/Shanghai. Use this as the task body. Run it once there and check the saved report before enabling recurrence.

Task body
Reuse the existing flashdata MCP connection. Check get_balance and get_pricing for one Google search.
If permitted and funded, run google_search once for "battery recycling research" with num 5 and mode "realtime".
Save a dated report with source URLs, excerpts and actual credits used.
Stop on revoked access or insufficient credits; respect Retry-After. Do not create a trial, request new authorization or repeat a request whose outcome is unknown.

Credential storage and refresh

This configuration uses the OpenClaw operator's shared OAuth connection. Allowed chat participants and scheduled runs use that FlashData account and its balance. It does not provision a separate account for each sender.

The host refreshes one-hour OAuth access tokens using rotating refresh tokens. Reconnect when the 90-day grant expires or is revoked. Each installation owns its token store; do not share refresh-token files between hosts.

Revoke or reconnect

  1. Pause scheduled tasks, then revoke the named OAuth connection in FlashData Settings → Connected apps.
  2. Ask the agent to call get_balance once with the saved connection. It should fail authentication or ask to reconnect. Do not approve a new login during this check.
  3. Remove the local OAuth credentials with the command below. To reconnect later, repeat step 2 with owner approval and run the free connection check.
Remove saved OAuth credentials
openclaw mcp logout flashdata

More setup options

Add workflow skills to your MCP connection, or choose CLI access or a local MCP server.

Add the MCP skill

The flashdata-mcp skill teaches your agent how to use the connected tools. It reuses the connection above.

With Node.js 22.20+ and npm, run this in the active OpenClaw workspace. The complete skill is saved to skills/flashdata-mcp. Start a new conversation and ask to use flashdata-mcp.

In your OpenClaw workspace
npx skills add flashdatadev/flashdata-skills --skill flashdata-mcp --agent openclaw --copy
openclaw skills list --eligible

Use CLI skills or start a trial

Install FlashData CLI v1.2.1 and run from the active OpenClaw workspace. Choose one access tab. Examples use the default CLI profile, separate from MCP OAuth; keep your existing --profile and --state-dir if you use custom ones.

Install the two workflow skills below with Node.js 22.20+ and npm. Start a new OpenClaw conversation afterward. The native CLI's setup command does not target OpenClaw.

Install CLI workflow skills
npx skills add flashdatadev/flashdata-skills --skill flashdata google-search --agent openclaw --copy
openclaw skills list --eligible

Paste a key with google_search permission at the hidden prompt. For unattended import, pipe it from your secret manager to auth login --api-key-stdin --non-interactive.

1. Import and verify the key
flashdata auth login
flashdata auth status --json --non-interactive
2. Check balance and cost — no search
flashdata account balance --json --non-interactive
flashdata search "battery recycling research" --num 5 --dry-run --json --non-interactive

# Continue only if accessVerified and estimateAvailable are true,
# google_search is permitted, and availableCredits covers estimatedCredits.
3. Run once → ./openclaw-first-search.json
flashdata search "battery recycling research" --num 5 --run-id openclaw-first-search-001 --output openclaw-first-search.json --json --non-interactive

# Read the saved file: status, results[].organic, usage.credits.
# Terminal JSON reports the output path; keep the run ID for recovery.

Run local MCP with an API key

Requires Node.js 22.18+, npm and an API key with google_search permission for the first task. This runs @flashdata-dev/mcp 0.2.0; it does not read the FlashData CLI's saved key or MCP OAuth tokens.

Set the key in the environment that actually runs the gateway. The prompt below is for a terminal-launched gateway; for a service or container, inject FLASHDATA_API_KEY through its secret/environment configuration and restart it. Exporting a key in another terminal will not update a running service.

After setup, run the free connection-check prompt above in a new agent session. Once both checks pass, use the first-task prompt. API-key access does not require mcp login.

1. Set the key without printing it
# Bash: paste the key into a hidden prompt, not into this command.
read -r -s -p "FlashData API key: " FLASHDATA_API_KEY
printf '\n'
export FLASHDATA_API_KEY
2. Register and probe in the gateway's profile
openclaw mcp set flashdata '{
  "command": "npx",
  "args": [
    "--yes",
    "--package=@flashdata-dev/[email protected]",
    "flashdata-mcp"
  ],
  "env": {
    "FLASHDATA_API_KEY": "${FLASHDATA_API_KEY}"
  }
}'
openclaw mcp doctor flashdata --probe

Troubleshooting

ProblemTry this
No FlashData toolsRun openclaw mcp doctor flashdata --probe. Check the gateway profile and agent's tool policy, then open a fresh conversation.
Skill missingRun openclaw skills list --eligible and openclaw skills check in the active profile. Check workspace skills/ and the skill allowlist.
invalid_client / callbackCompare step 1 exactly. Complete authorization in a browser that can reach the initiating host's callback.
401Check whether the connection or key was revoked or expired. For OAuth, repeat sign-in with owner approval; for CLI, run flashdata auth status. Adding credits will not repair authentication.
403Check the requested source permission. Research OAuth does not include YouTube Download; use its API-key setup. Fix the permission before retrying.
402Check get_balance or flashdata account balance. Add credits in Billing or stop the task; signing in again does not add credits.
429Wait for Retry-After and reduce concurrency. Preserve the current profile and registration proof; do not create replacement trials.
Local MCP cannot read the keySet FLASHDATA_API_KEY where the host process starts and restart it. A key saved by flashdata auth login is not automatically exported to local MCP.
CLI output file already existsRead ./openclaw-first-search.json. To export the saved success again, use flashdata runs show openclaw-first-search-001 --result --output openclaw-first-search-copy.json with the original profile. Use a new run ID only for an intended new search.
Scheduled task failsRun the free reuse check inside that environment. Match the OS user, host profile, credential store and tool permissions.
Timeout or unknown outcomeKeep the request or job ID and check History before resubmitting. Use get_result for returned continuation IDs.

OAuth validation notes

OAuth login, callback, saved credentials, a free pricing call, refresh and revocation were verified on Windows with OpenClaw 2026.10.5 on 2026-10-21. That run did not validate paid queries or scheduled execution. Setup instructions were checked against the host documentation on 2026-11-05.