Skip to main content
Glama

Import external leads

campaignstack_import_external_leads

Import leads from a provider list, campaign, or portal into CampaignStack. The job may continue server-side; read progress through campaignstack_get_integrations resources.importProgress.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
providerYes
sourceIdYes
campaignIdNo
sourceKindYes
sourceNameNo
workspaceIdNoWorkspace ID. Omit it when this connection reaches one workspace: a workspace key (cs_) is bound to its own, and a user key (csu_) or connected app whose person belongs to exactly one workspace defaults to that one. Required only when the person belongs to several; the error then lists them, and campaignstack_whoami reports them too.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
okNo
failedNo
resultNo
resultsNo
warningsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / workspaceId / description
      Previous value: -"Workspace ID. REQUIRED for a user key (csu_), which spans every workspace you belong to; omitted for a workspace key (cs_), which is bound to one and ignores this argument. campaignstack_whoami reports which kind of key you are holding and, for a user key, the workspaces it can reach."New value: +"Workspace ID. Omit it when this connection reaches one workspace: a workspace key (cs_) is bound to its own, and a user key (csu_) or connected app whose person belongs to exactly one workspace defaults to that one. Required only when the person belongs to several; the error then lists them, and campaignstack_whoami reports them too."
  2. Changed19 schema fields changed
    • removedInput schema / properties / campaignId / description
      Removed value: -"Optional CampaignStack campaign whose default lead list receives the imported leads."
    • removedInput schema / properties / provider / description
      Removed value: -"Integration provider to import from."
    • removedInput schema / properties / sourceId / description
      Removed value: -"Provider-side source id (from campaignstack_list_external_lead_lists or campaignstack_list_external_sequences). Pass \"portal\" for sourceKind portal."
    • removedInput schema / properties / sourceKind / description
      Removed value: -"Whether sourceId is a provider lead list (apollo, instantly, hubspot), a provider campaign (instantly only), or the whole portal (hubspot only: every contact)."
    • removedInput schema / properties / sourceName / description
      Removed value: -"Display name for progress tracking."
    • changedOutput schema / additionalProperties
      Previous value: -trueNew value: +false
    • removedOutput schema / properties / addedToCampaign
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "anyOf": [
      -        {
      -          "not": {}
      -        },
      -        {
      -          "type": "number"
      -        }
      -      ]
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ]
      -}
    • removedOutput schema / properties / errorCode
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "anyOf": [
      -        {
      -          "not": {}
      -        },
      -        {
      -          "type": "string"
      -        }
      -      ]
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ]
      -}
    • removedOutput schema / properties / errors
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "anyOf": [
      -        {
      -          "not": {}
      -        },
      -        {
      -          "items": {
      -            "type": "string"
      -          },
      -          "type": "array"
      -        }
      -      ]
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ]
      -}
    • addedOutput schema / properties / failed
      Added value: +{
      +  "type": "number"
      +}
    • removedOutput schema / properties / imported
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "anyOf": [
      -        {
      -          "not": {}
      -        },
      -        {
      -          "type": "number"
      -        }
      -      ]
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ]
      -}
    • removedOutput schema / properties / leadIds
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "anyOf": [
      -        {
      -          "not": {}
      -        },
      -        {
      -          "items": {
      -            "type": "string"
      -          },
      -          "type": "array"
      -        }
      -      ]
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ]
      -}
    • addedOutput schema / properties / ok
      Added value: +{
      +  "type": "number"
      +}
    • addedOutput schema / properties / result
      Added value: +{}
    • addedOutput schema / properties / results
      Added value: +{
      +  "items": {},
      +  "type": "array"
      +}
    • removedOutput schema / properties / skipped
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "anyOf": [
      -        {
      -          "not": {}
      -        },
      -        {
      -          "type": "number"
      -        }
      -      ]
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ]
      -}
    • removedOutput schema / properties / success
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "anyOf": [
      -        {
      -          "not": {}
      -        },
      -        {
      -          "type": "boolean"
      -        }
      -      ]
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ]
      -}
    • removedOutput schema / properties / total
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "anyOf": [
      -        {
      -          "not": {}
      -        },
      -        {
      -          "type": "number"
      -        }
      -      ]
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ]
      -}
    • addedOutput schema / properties / warnings
      Added value: +{
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
  3. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": true,
      +  "properties": {
      +    "addedToCampaign": {
      +      "anyOf": [
      +        {
      +          "anyOf": [
      +            {
      +              "not": {}
      +            },
      +            {
      +              "type": "number"
      +            }
      +          ]
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "errorCode": {
      +      "anyOf": [
      +        {
      +          "anyOf": [
      +            {
      +              "not": {}
      +            },
      +            {
      +              "type": "string"
      +            }
      +          ]
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "errors": {
      +      "anyOf": [
      +        {
      +          "anyOf": [
      +            {
      +              "not": {}
      +            },
      +            {
      +              "items": {
      +                "type": "string"
      +              },
      +              "type": "array"
      +            }
      +          ]
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "imported": {
      +      "anyOf": [
      +        {
      +          "anyOf": [
      +            {
      +              "not": {}
      +            },
      +            {
      +              "type": "number"
      +            }
      +          ]
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "leadIds": {
      +      "anyOf": [
      +        {
      +          "anyOf": [
      +            {
      +              "not": {}
      +            },
      +            {
      +              "items": {
      +                "type": "string"
      +              },
      +              "type": "array"
      +            }
      +          ]
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "skipped": {
      +      "anyOf": [
      +        {
      +          "anyOf": [
      +            {
      +              "not": {}
      +            },
      +            {
      +              "type": "number"
      +            }
      +          ]
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "success": {
      +      "anyOf": [
      +        {
      +          "anyOf": [
      +            {
      +              "not": {}
      +            },
      +            {
      +              "type": "boolean"
      +            }
      +          ]
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "total": {
      +      "anyOf": [
      +        {
      +          "anyOf": [
      +            {
      +              "not": {}
      +            },
      +            {
      +              "type": "number"
      +            }
      +          ]
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    }
      +  },
      +  "type": "object"
      +}
  4. Changed2 schema fields changed
    • changedInput schema / properties / provider / enum
      Previous value: -[
      -  "instantly",
      -  "hubspot"
      -]New value: +[
      +  "apollo",
      +  "instantly",
      +  "hubspot"
      +]
    • changedInput schema / properties / sourceKind / description
      Previous value: -"Whether sourceId is a provider lead list, a provider campaign (instantly only), or the whole portal (hubspot only: every contact)."New value: +"Whether sourceId is a provider lead list (apollo, instantly, hubspot), a provider campaign (instantly only), or the whole portal (hubspot only: every contact)."
  5. Changed1 schema field changed
    • changedInput schema / properties / workspaceId / description
      Previous value: -"Workspace ID (required for user keys; workspace keys are bound)"New value: +"Workspace ID. REQUIRED for a user key (csu_), which spans every workspace you belong to; omitted for a workspace key (cs_), which is bound to one and ignores this argument. campaignstack_whoami reports which kind of key you are holding and, for a user key, the workspaces it can reach."
  6. Changed1 schema field changed
    • changedInput schema / properties / workspaceId / description
      Previous value: -"Workspace ID (defaults to the bound workspace)"New value: +"Workspace ID (required for user keys; workspace keys are bound)"
  7. First observed

TDQS

A3.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare the safety profile (not read-only, not idempotent, non-destructive, open-world), so the bar is lower. The description adds genuine value by disclosing that the job may continue server-side and naming exactly how to read progress via campaignstack_get_integrations resources.importProgress, which is not derivable from the schema or annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two tight sentences with the purpose front-loaded and the async/progress pointer as the second beat. No filler; every clause carries information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The output schema exists, so return-value detail is not needed, and the async nature is covered. However, with 17% param coverage and an undifferentiated near-twin sibling (campaignstack_import_leads), the definition is only minimally complete for an operationally complex, open-world import tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is only 17% (just workspaceId), so the description must carry the parameter burden. It maps loosely to the sourceKind enum ('list, campaign, portal') but never explains provider values (apollo/instantly/hubspot), sourceId, campaignId, or sourceName semantics, leaving most of the six parameters undocumented in both places.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (Import) and resource (external leads) plus the accepted source kinds (provider list, campaign, portal) and the destination (CampaignStack). It does not, however, distinguish itself from the close sibling campaignstack_import_leads or campaignstack_add_leads_to_external_destination, so an agent cannot tell from the text alone which import path to choose.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies its usage by naming the three source kinds, and it points to where to follow async progress. But it never states when to prefer this over the similar campaignstack_import_leads or export/add-leads siblings, and gives no prerequisites or exclusions, leaving the routing decision to inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources