Skip to content

Workspace

Workspace-level tools — identity, generation, scraping, and diagnostics.

Full name: campaignstack_whoami

No scope required Read-only Idempotent

Returns information about the current API key: workspace name, available scopes, and key prefix. Useful for debugging permission issues.


Full name: campaignstack_start_workspace_generation

campaigns:write

Start a workspace generation pipeline for a single workspace. Requires a valid LinkedIn cookie and user agent string for the client. Creates a LinkedIn account record, then runs the full generation pipeline: cookie validation, workspace setup, profile enrichment, website scraping, goal synthesis, campaign creation, workflow generation, and lead search. Returns a generationId to track progress.

NameTypeRequiredDefaultDescription
workspaceIdstringYes(min length: 1)
linkedInCookiestringYes(min length: 1)
userAgentstringYes(min length: 1)

Full name: campaignstack_get_generation_status

campaigns:read Read-only Idempotent

Get the status of a workspace generation pipeline. Returns the full generation record including all step statuses, current step, completion percentage (completedSteps / totalSteps), and any error details. Use after campaignstack_start_workspace_generation to poll progress.

NameTypeRequiredDefaultDescription
generationIdstringYes(min length: 1)

Full name: campaignstack_retry_generation

campaigns:write Idempotent

Retry a failed workspace generation from the failed step. Only works when the generation is in ‘failed’ status. If the failure was due to an expired LinkedIn session, provide newCookie with a fresh li_at value. Use campaignstack_get_generation_status to check status first.

NameTypeRequiredDefaultDescription
generationIdstringYes(min length: 1)
newCookiestringNo(min length: 1)

Full name: campaignstack_scrape_website

campaigns:read Read-only Idempotent

Scrape and analyze a website to extract structured company intelligence. Returns company name, description, services, target market, industry, team size, tech stack, and positioning. Results are cached for 7 days per domain. Use this to gather context about a lead’s company before creating campaigns.

NameTypeRequiredDefaultDescription
urlstringYes

Full name: campaignstack_synthesize_goal

campaigns:read Read-only Idempotent

Synthesize a campaign goal from the workspace owner’s enriched LinkedIn profile and optional website context. Requires a connected LinkedIn account with completed enrichment. Use campaignstack_scrape_website first to verify website accessibility, then pass the URL here for integrated goal synthesis.

NameTypeRequiredDefaultDescription
workspaceIdstringYes(min length: 1)
linkedInAccountIdstringNo
websiteUrlstringNo

Full name: campaignstack_auto_select_option

campaigns:write Read-only Idempotent

Auto-select the best campaign option from a generated set based on profile and company context alignment. Input an array of CampaignOption objects (with title, description, icpPreview) plus profileContext and optional companyContext. Returns the selected option and a rationale explaining the choice. Use after generating campaign options to automatically pick the best fit.

NameTypeRequiredDefaultDescription
optionsobject[]Yes
profileContextobjectYes
companyContextobjectNo

Full name: campaignstack_finalize_campaign

campaigns:write

Create all campaign DB records from an expanded campaign in one call. Creates: campaign, ICP (with async variant generation), personas, default lead list, campaign phases (roadmap), and signal weights. Returns the new campaign ID, ICP ID, and lead list ID. Use after AI campaign expansion to persist the full campaign structure. Use campaignstack_get_campaign to inspect the created campaign.

NameTypeRequiredDefaultDescription
workspaceIdstringYes(min length: 1)
expandedCampaignobjectYes
goalstringYes(min length: 1)

Full name: campaignstack_diagnose_lead_sourcing

leads:read Read-only Idempotent

Diagnose why a specific lead was or wasn’t sourced into a workflow. Accepts a workflowId plus either a leadId or linkedInUrl. Returns a diagnostic report covering: lead existence, ICP score, score threshold checks, dedup status (same-workflow and cross-workflow), exclusion list matches, per-provider filter evaluation, and a human-readable verdict explaining the sourcing outcome. Use campaignstack_list_workflows to find valid workflowId values. Use campaignstack_search_leads to find valid leadId values.