# MCP tool reference

1 callable tools.

Use tools/call at https://mcp.schedulerzero.com/mcp with the exact tool name and arguments below. The /tools/ paths in this view are documentation identifiers, not HTTP endpoints. Request execution is disabled for this reference.

Inputs are shown for personal API keys (bound) and for OAuth/delegated agents. Output schemas describe MCP structuredContent: native objects pass through; arrays, scalars and null use a data wrapper. Text content retains the native JSON result.

[Connect a client](/mcp/connect) · [Authentication and authorization](/authentication) · [Generated auth guide](/auth.md) · [Download tool catalog](/mcp-catalog.json) · [Agent documentation](/llms.txt)

## run_getleads_request

Run a GetLeads request — enrichment, phone lookup, search, count, export, or profile management — in the background.

Call with action=preview first to see the item count and credit estimate. After approval, call with action=execute, pass the exact confirmationToken returned by that preview when the request is billable. The server derives the replay key from the request. Poll the operation for per-item results.

Billable requests spend the customer's GetLeads credits. An execution whose outcome is unknown is never retried automatically — check before re-running.

Use the native preview first and pass its confirmation token unchanged to commit. A token does not bypass current permissions or Workspace checks.

Scopes: integration:read, integration:update

Risk: costly; confirmation: preview_token; idempotency: required.

### Input schema (personal API key)

```json
{
  "type": "object",
  "properties": {
    "workspaceId": {
      "type": "string",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|[fF]{8}-[fF]{4}-[fF]{4}-[fF]{4}-[fF]{12})$",
      "format": "uuid"
    },
    "connectionId": {
      "type": "string",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|[fF]{8}-[fF]{4}-[fF]{4}-[fF]{4}-[fF]{12})$",
      "format": "uuid"
    },
    "request": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "usage"
              ]
            },
            "input": {
              "type": "object",
              "patternProperties": {
                "^[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "not": {}
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "enrich_email"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "items": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "email": {
                        "$ref": "#/$defs/EmailAddress"
                      }
                    },
                    "required": [
                      "email"
                    ],
                    "patternProperties": {
                      "^(?!(?:email)$)[\\s\\S]*$": false
                    },
                    "additionalProperties": true,
                    "propertyNames": {
                      "anyOf": [
                        {
                          "type": "string",
                          "enum": [
                            "email"
                          ]
                        }
                      ]
                    }
                  },
                  "minItems": 1,
                  "maxItems": 100
                }
              },
              "required": [
                "items"
              ],
              "patternProperties": {
                "^(?!(?:items)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "anyOf": [
                  {
                    "type": "string",
                    "enum": [
                      "items"
                    ]
                  }
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "enrich_linkedin"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "items": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "linkedin_url": {
                        "$ref": "#/$defs/HttpUrl"
                      }
                    },
                    "required": [
                      "linkedin_url"
                    ],
                    "patternProperties": {
                      "^(?!(?:linkedin_url)$)[\\s\\S]*$": false
                    },
                    "additionalProperties": true,
                    "propertyNames": {
                      "anyOf": [
                        {
                          "type": "string",
                          "enum": [
                            "linkedin_url"
                          ]
                        }
                      ]
                    }
                  },
                  "minItems": 1,
                  "maxItems": 100
                },
                "limit_per_item": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 10
                }
              },
              "required": [
                "items"
              ],
              "patternProperties": {
                "^(?!(?:items|limit_per_item)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "items",
                  "limit_per_item"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "enrich_person"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "items": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "first_name": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 1000
                      },
                      "last_name": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 1000
                      },
                      "company_name": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 1000
                      },
                      "email_domain": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 1000
                      }
                    },
                    "required": [
                      "first_name",
                      "last_name"
                    ],
                    "patternProperties": {
                      "^(?!(?:first_name|last_name|company_name|email_domain)$)[\\s\\S]*$": false
                    },
                    "additionalProperties": true,
                    "propertyNames": {
                      "type": "string",
                      "enum": [
                        "first_name",
                        "last_name",
                        "company_name",
                        "email_domain"
                      ]
                    }
                  },
                  "minItems": 1,
                  "maxItems": 100
                }
              },
              "required": [
                "items"
              ],
              "patternProperties": {
                "^(?!(?:items)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "anyOf": [
                  {
                    "type": "string",
                    "enum": [
                      "items"
                    ]
                  }
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "lookup_phone"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "items": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "phone": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 1000
                      }
                    },
                    "required": [
                      "phone"
                    ],
                    "patternProperties": {
                      "^(?!(?:phone)$)[\\s\\S]*$": false
                    },
                    "additionalProperties": true,
                    "propertyNames": {
                      "anyOf": [
                        {
                          "type": "string",
                          "enum": [
                            "phone"
                          ]
                        }
                      ]
                    }
                  },
                  "minItems": 1,
                  "maxItems": 100
                },
                "limit_per_item": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 10
                }
              },
              "required": [
                "items"
              ],
              "patternProperties": {
                "^(?!(?:items|limit_per_item)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "items",
                  "limit_per_item"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "search"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "filters": {
                  "type": "object",
                  "additionalProperties": {
                    "$ref": "#/$defs/Union_"
                  },
                  "minProperties": 1,
                  "maxProperties": 100
                },
                "limit": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 5000
                },
                "offset": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 49999
                },
                "max_per_company": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 50
                }
              },
              "required": [
                "filters"
              ],
              "patternProperties": {
                "^(?!(?:filters|limit|offset|max_per_company)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "filters",
                  "limit",
                  "offset",
                  "max_per_company"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "count"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "filters": {
                  "type": "object",
                  "additionalProperties": {
                    "$ref": "#/$defs/Union_"
                  },
                  "minProperties": 1,
                  "maxProperties": 100
                }
              },
              "required": [
                "filters"
              ],
              "patternProperties": {
                "^(?!(?:filters)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "anyOf": [
                  {
                    "type": "string",
                    "enum": [
                      "filters"
                    ]
                  }
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "export"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "filters": {
                  "type": "object",
                  "additionalProperties": {
                    "$ref": "#/$defs/Union_"
                  },
                  "minProperties": 1,
                  "maxProperties": 100
                },
                "max_rows": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 50000
                },
                "max_per_company": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 50
                },
                "confirmed": {
                  "type": "boolean",
                  "enum": [
                    true
                  ]
                }
              },
              "required": [
                "filters",
                "max_rows",
                "confirmed"
              ],
              "patternProperties": {
                "^(?!(?:filters|max_rows|max_per_company|confirmed)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "filters",
                  "max_rows",
                  "max_per_company",
                  "confirmed"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "export_status"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "export_id": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 1000,
                  "pattern": "^[A-Za-z0-9_-]+$"
                }
              },
              "required": [
                "export_id"
              ],
              "patternProperties": {
                "^(?!(?:export_id)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "anyOf": [
                  {
                    "type": "string",
                    "enum": [
                      "export_id"
                    ]
                  }
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "profiles"
              ]
            },
            "input": {
              "type": "object",
              "patternProperties": {
                "^[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "not": {}
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "profile_leads"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "limit": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 100
                },
                "cursor": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 1000
                }
              },
              "patternProperties": {
                "^(?!(?:limit|cursor)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "limit",
                  "cursor"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "set_profile_active"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "profile_id": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 1000,
                  "pattern": "^[A-Za-z0-9_-]+$"
                },
                "active": {
                  "type": "boolean"
                }
              },
              "required": [
                "profile_id",
                "active"
              ],
              "patternProperties": {
                "^(?!(?:profile_id|active)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "profile_id",
                  "active"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        }
      ]
    },
    "action": {
      "type": "string",
      "enum": [
        "preview",
        "execute"
      ]
    },
    "confirmationToken": {
      "$ref": "#/$defs/OpaqueId"
    }
  },
  "required": [
    "workspaceId",
    "connectionId",
    "request",
    "action"
  ],
  "patternProperties": {
    "^(?!(?:workspaceId|connectionId|request|action|confirmationToken)$)[\\s\\S]*$": false
  },
  "additionalProperties": true,
  "propertyNames": {
    "type": "string",
    "enum": [
      "workspaceId",
      "connectionId",
      "request",
      "action",
      "confirmationToken"
    ]
  },
  "$defs": {
    "EmailAddress": {
      "type": "string",
      "minLength": 3,
      "maxLength": 320,
      "pattern": "^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$"
    },
    "HttpUrl": {
      "type": "string",
      "minLength": 1,
      "maxLength": 2048,
      "pattern": "^https?:\\/\\/[^\\s/$.?#][^\\s]*$"
    },
    "Union_": {
      "anyOf": [
        {
          "type": "null"
        },
        {
          "type": "boolean"
        },
        {
          "type": "number"
        },
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "$ref": "#/$defs/Union_"
          }
        },
        {
          "type": "object",
          "additionalProperties": {
            "$ref": "#/$defs/Union_"
          }
        }
      ]
    },
    "OpaqueId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 512
    }
  }
}
```

### Input schema (OAuth / delegated agent)

```json
{
  "type": "object",
  "properties": {
    "workspaceId": {
      "type": "string",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|[fF]{8}-[fF]{4}-[fF]{4}-[fF]{4}-[fF]{12})$",
      "format": "uuid"
    },
    "connectionId": {
      "type": "string",
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|[fF]{8}-[fF]{4}-[fF]{4}-[fF]{4}-[fF]{12})$",
      "format": "uuid"
    },
    "request": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "usage"
              ]
            },
            "input": {
              "type": "object",
              "patternProperties": {
                "^[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "not": {}
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "enrich_email"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "items": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "email": {
                        "$ref": "#/$defs/EmailAddress"
                      }
                    },
                    "required": [
                      "email"
                    ],
                    "patternProperties": {
                      "^(?!(?:email)$)[\\s\\S]*$": false
                    },
                    "additionalProperties": true,
                    "propertyNames": {
                      "anyOf": [
                        {
                          "type": "string",
                          "enum": [
                            "email"
                          ]
                        }
                      ]
                    }
                  },
                  "minItems": 1,
                  "maxItems": 100
                }
              },
              "required": [
                "items"
              ],
              "patternProperties": {
                "^(?!(?:items)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "anyOf": [
                  {
                    "type": "string",
                    "enum": [
                      "items"
                    ]
                  }
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "enrich_linkedin"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "items": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "linkedin_url": {
                        "$ref": "#/$defs/HttpUrl"
                      }
                    },
                    "required": [
                      "linkedin_url"
                    ],
                    "patternProperties": {
                      "^(?!(?:linkedin_url)$)[\\s\\S]*$": false
                    },
                    "additionalProperties": true,
                    "propertyNames": {
                      "anyOf": [
                        {
                          "type": "string",
                          "enum": [
                            "linkedin_url"
                          ]
                        }
                      ]
                    }
                  },
                  "minItems": 1,
                  "maxItems": 100
                },
                "limit_per_item": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 10
                }
              },
              "required": [
                "items"
              ],
              "patternProperties": {
                "^(?!(?:items|limit_per_item)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "items",
                  "limit_per_item"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "enrich_person"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "items": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "first_name": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 1000
                      },
                      "last_name": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 1000
                      },
                      "company_name": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 1000
                      },
                      "email_domain": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 1000
                      }
                    },
                    "required": [
                      "first_name",
                      "last_name"
                    ],
                    "patternProperties": {
                      "^(?!(?:first_name|last_name|company_name|email_domain)$)[\\s\\S]*$": false
                    },
                    "additionalProperties": true,
                    "propertyNames": {
                      "type": "string",
                      "enum": [
                        "first_name",
                        "last_name",
                        "company_name",
                        "email_domain"
                      ]
                    }
                  },
                  "minItems": 1,
                  "maxItems": 100
                }
              },
              "required": [
                "items"
              ],
              "patternProperties": {
                "^(?!(?:items)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "anyOf": [
                  {
                    "type": "string",
                    "enum": [
                      "items"
                    ]
                  }
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "lookup_phone"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "items": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "phone": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 1000
                      }
                    },
                    "required": [
                      "phone"
                    ],
                    "patternProperties": {
                      "^(?!(?:phone)$)[\\s\\S]*$": false
                    },
                    "additionalProperties": true,
                    "propertyNames": {
                      "anyOf": [
                        {
                          "type": "string",
                          "enum": [
                            "phone"
                          ]
                        }
                      ]
                    }
                  },
                  "minItems": 1,
                  "maxItems": 100
                },
                "limit_per_item": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 10
                }
              },
              "required": [
                "items"
              ],
              "patternProperties": {
                "^(?!(?:items|limit_per_item)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "items",
                  "limit_per_item"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "search"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "filters": {
                  "type": "object",
                  "additionalProperties": {
                    "$ref": "#/$defs/Union_"
                  },
                  "minProperties": 1,
                  "maxProperties": 100
                },
                "limit": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 5000
                },
                "offset": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 49999
                },
                "max_per_company": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 50
                }
              },
              "required": [
                "filters"
              ],
              "patternProperties": {
                "^(?!(?:filters|limit|offset|max_per_company)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "filters",
                  "limit",
                  "offset",
                  "max_per_company"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "count"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "filters": {
                  "type": "object",
                  "additionalProperties": {
                    "$ref": "#/$defs/Union_"
                  },
                  "minProperties": 1,
                  "maxProperties": 100
                }
              },
              "required": [
                "filters"
              ],
              "patternProperties": {
                "^(?!(?:filters)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "anyOf": [
                  {
                    "type": "string",
                    "enum": [
                      "filters"
                    ]
                  }
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "export"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "filters": {
                  "type": "object",
                  "additionalProperties": {
                    "$ref": "#/$defs/Union_"
                  },
                  "minProperties": 1,
                  "maxProperties": 100
                },
                "max_rows": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 50000
                },
                "max_per_company": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 50
                },
                "confirmed": {
                  "type": "boolean",
                  "enum": [
                    true
                  ]
                }
              },
              "required": [
                "filters",
                "max_rows",
                "confirmed"
              ],
              "patternProperties": {
                "^(?!(?:filters|max_rows|max_per_company|confirmed)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "filters",
                  "max_rows",
                  "max_per_company",
                  "confirmed"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "export_status"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "export_id": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 1000,
                  "pattern": "^[A-Za-z0-9_-]+$"
                }
              },
              "required": [
                "export_id"
              ],
              "patternProperties": {
                "^(?!(?:export_id)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "anyOf": [
                  {
                    "type": "string",
                    "enum": [
                      "export_id"
                    ]
                  }
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "profiles"
              ]
            },
            "input": {
              "type": "object",
              "patternProperties": {
                "^[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "not": {}
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "profile_leads"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "limit": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 100
                },
                "cursor": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 1000
                }
              },
              "patternProperties": {
                "^(?!(?:limit|cursor)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "limit",
                  "cursor"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "operation": {
              "type": "string",
              "enum": [
                "set_profile_active"
              ]
            },
            "input": {
              "type": "object",
              "properties": {
                "profile_id": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 1000,
                  "pattern": "^[A-Za-z0-9_-]+$"
                },
                "active": {
                  "type": "boolean"
                }
              },
              "required": [
                "profile_id",
                "active"
              ],
              "patternProperties": {
                "^(?!(?:profile_id|active)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "profile_id",
                  "active"
                ]
              }
            }
          },
          "required": [
            "operation",
            "input"
          ],
          "patternProperties": {
            "^(?!(?:operation|input)$)[\\s\\S]*$": false
          },
          "additionalProperties": true,
          "propertyNames": {
            "type": "string",
            "enum": [
              "operation",
              "input"
            ]
          }
        }
      ]
    },
    "action": {
      "type": "string",
      "enum": [
        "preview",
        "execute"
      ]
    },
    "confirmationToken": {
      "$ref": "#/$defs/OpaqueId"
    }
  },
  "required": [
    "workspaceId",
    "connectionId",
    "request",
    "action"
  ],
  "patternProperties": {
    "^(?!(?:workspaceId|connectionId|request|action|confirmationToken)$)[\\s\\S]*$": false
  },
  "additionalProperties": true,
  "propertyNames": {
    "type": "string",
    "enum": [
      "workspaceId",
      "connectionId",
      "request",
      "action",
      "confirmationToken"
    ]
  },
  "$defs": {
    "EmailAddress": {
      "type": "string",
      "minLength": 3,
      "maxLength": 320,
      "pattern": "^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$"
    },
    "HttpUrl": {
      "type": "string",
      "minLength": 1,
      "maxLength": 2048,
      "pattern": "^https?:\\/\\/[^\\s/$.?#][^\\s]*$"
    },
    "Union_": {
      "anyOf": [
        {
          "type": "null"
        },
        {
          "type": "boolean"
        },
        {
          "type": "number"
        },
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "$ref": "#/$defs/Union_"
          }
        },
        {
          "type": "object",
          "additionalProperties": {
            "$ref": "#/$defs/Union_"
          }
        }
      ]
    },
    "OpaqueId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 512
    }
  }
}
```

### Output schema (structuredContent)

```json
{
  "$defs": {
    "OpaqueId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 512
    },
    "UtcDateTimeEncoded": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{3}Z$"
    },
    "HttpUrl": {
      "type": "string",
      "minLength": 1,
      "maxLength": 2048,
      "pattern": "^https?:\\/\\/[^\\s/$.?#][^\\s]*$"
    },
    "HttpResourcePath": {
      "type": "string",
      "minLength": 1,
      "maxLength": 2048,
      "pattern": "^\\/[A-Za-z0-9._~!$&'()*+,;=:@/%-]*$"
    },
    "NonEmptyString": {
      "type": "string",
      "minLength": 1,
      "maxLength": 4096
    }
  },
  "type": "object",
  "anyOf": [
    {
      "allOf": [
        {
          "anyOf": [
            {
              "type": "object",
              "properties": {
                "operation": {
                  "type": "string",
                  "enum": [
                    "usage",
                    "enrich_email",
                    "enrich_linkedin",
                    "enrich_person",
                    "lookup_phone",
                    "search",
                    "count",
                    "export",
                    "export_status",
                    "profiles",
                    "profile_leads",
                    "set_profile_active"
                  ]
                },
                "itemCount": {
                  "type": "integer",
                  "minimum": 0
                },
                "billable": {
                  "type": "boolean"
                },
                "estimatedCredits": {
                  "anyOf": [
                    {
                      "type": "integer",
                      "minimum": 0
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "confirmationToken": {
                  "anyOf": [
                    {
                      "$ref": "#/$defs/OpaqueId"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "expiresAt": {
                  "anyOf": [
                    {
                      "$ref": "#/$defs/UtcDateTimeEncoded"
                    },
                    {
                      "type": "null"
                    }
                  ]
                }
              },
              "required": [
                "operation",
                "itemCount",
                "billable",
                "estimatedCredits",
                "confirmationToken",
                "expiresAt"
              ],
              "patternProperties": {
                "^(?!(?:operation|itemCount|billable|estimatedCredits|confirmationToken|expiresAt)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "operation",
                  "itemCount",
                  "billable",
                  "estimatedCredits",
                  "confirmationToken",
                  "expiresAt"
                ]
              }
            },
            {
              "type": "object",
              "properties": {
                "providerOperation": {
                  "type": "string",
                  "enum": [
                    "usage",
                    "enrich_email",
                    "enrich_linkedin",
                    "enrich_person",
                    "lookup_phone",
                    "search",
                    "count",
                    "export",
                    "export_status",
                    "profiles",
                    "profile_leads",
                    "set_profile_active"
                  ]
                },
                "itemCount": {
                  "type": "integer",
                  "minimum": 0
                },
                "operation": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string",
                      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|[fF]{8}-[fF]{4}-[fF]{4}-[fF]{4}-[fF]{12})$",
                      "format": "uuid"
                    },
                    "statusUrl": {
                      "anyOf": [
                        {
                          "$ref": "#/$defs/HttpUrl"
                        },
                        {
                          "$ref": "#/$defs/HttpResourcePath"
                        }
                      ]
                    },
                    "state": {
                      "type": "string",
                      "enum": [
                        "queued",
                        "running",
                        "waiting_for_user",
                        "succeeded",
                        "partially_succeeded",
                        "failed",
                        "canceled",
                        "canceling"
                      ]
                    },
                    "acceptedAt": {
                      "$ref": "#/$defs/UtcDateTimeEncoded"
                    },
                    "progress": {
                      "type": "object",
                      "properties": {
                        "completed": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "total": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "message": {
                          "$ref": "#/$defs/NonEmptyString"
                        }
                      },
                      "required": [
                        "completed"
                      ],
                      "patternProperties": {
                        "^(?!(?:completed|total|message)$)[\\s\\S]*$": false
                      },
                      "additionalProperties": true,
                      "propertyNames": {
                        "type": "string",
                        "enum": [
                          "completed",
                          "total",
                          "message"
                        ]
                      }
                    },
                    "canCancel": {
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "id",
                    "statusUrl",
                    "state",
                    "acceptedAt",
                    "canCancel"
                  ],
                  "patternProperties": {
                    "^(?!(?:id|statusUrl|state|acceptedAt|progress|canCancel)$)[\\s\\S]*$": false
                  },
                  "additionalProperties": true,
                  "propertyNames": {
                    "type": "string",
                    "enum": [
                      "id",
                      "statusUrl",
                      "state",
                      "acceptedAt",
                      "progress",
                      "canCancel"
                    ]
                  }
                }
              },
              "required": [
                "providerOperation",
                "itemCount",
                "operation"
              ],
              "patternProperties": {
                "^(?!(?:providerOperation|itemCount|operation)$)[\\s\\S]*$": false
              },
              "additionalProperties": true,
              "propertyNames": {
                "type": "string",
                "enum": [
                  "providerOperation",
                  "itemCount",
                  "operation"
                ]
              }
            }
          ]
        },
        {
          "type": "object"
        }
      ]
    },
    {
      "type": "object",
      "properties": {
        "data": {
          "allOf": [
            {
              "anyOf": [
                {
                  "type": "object",
                  "properties": {
                    "operation": {
                      "type": "string",
                      "enum": [
                        "usage",
                        "enrich_email",
                        "enrich_linkedin",
                        "enrich_person",
                        "lookup_phone",
                        "search",
                        "count",
                        "export",
                        "export_status",
                        "profiles",
                        "profile_leads",
                        "set_profile_active"
                      ]
                    },
                    "itemCount": {
                      "type": "integer",
                      "minimum": 0
                    },
                    "billable": {
                      "type": "boolean"
                    },
                    "estimatedCredits": {
                      "anyOf": [
                        {
                          "type": "integer",
                          "minimum": 0
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "confirmationToken": {
                      "anyOf": [
                        {
                          "$ref": "#/$defs/OpaqueId"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "expiresAt": {
                      "anyOf": [
                        {
                          "$ref": "#/$defs/UtcDateTimeEncoded"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "operation",
                    "itemCount",
                    "billable",
                    "estimatedCredits",
                    "confirmationToken",
                    "expiresAt"
                  ],
                  "patternProperties": {
                    "^(?!(?:operation|itemCount|billable|estimatedCredits|confirmationToken|expiresAt)$)[\\s\\S]*$": false
                  },
                  "additionalProperties": true,
                  "propertyNames": {
                    "type": "string",
                    "enum": [
                      "operation",
                      "itemCount",
                      "billable",
                      "estimatedCredits",
                      "confirmationToken",
                      "expiresAt"
                    ]
                  }
                },
                {
                  "type": "object",
                  "properties": {
                    "providerOperation": {
                      "type": "string",
                      "enum": [
                        "usage",
                        "enrich_email",
                        "enrich_linkedin",
                        "enrich_person",
                        "lookup_phone",
                        "search",
                        "count",
                        "export",
                        "export_status",
                        "profiles",
                        "profile_leads",
                        "set_profile_active"
                      ]
                    },
                    "itemCount": {
                      "type": "integer",
                      "minimum": 0
                    },
                    "operation": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string",
                          "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|[fF]{8}-[fF]{4}-[fF]{4}-[fF]{4}-[fF]{12})$",
                          "format": "uuid"
                        },
                        "statusUrl": {
                          "anyOf": [
                            {
                              "$ref": "#/$defs/HttpUrl"
                            },
                            {
                              "$ref": "#/$defs/HttpResourcePath"
                            }
                          ]
                        },
                        "state": {
                          "type": "string",
                          "enum": [
                            "queued",
                            "running",
                            "waiting_for_user",
                            "succeeded",
                            "partially_succeeded",
                            "failed",
                            "canceled",
                            "canceling"
                          ]
                        },
                        "acceptedAt": {
                          "$ref": "#/$defs/UtcDateTimeEncoded"
                        },
                        "progress": {
                          "type": "object",
                          "properties": {
                            "completed": {
                              "type": "integer",
                              "minimum": 0
                            },
                            "total": {
                              "type": "integer",
                              "minimum": 0
                            },
                            "message": {
                              "$ref": "#/$defs/NonEmptyString"
                            }
                          },
                          "required": [
                            "completed"
                          ],
                          "patternProperties": {
                            "^(?!(?:completed|total|message)$)[\\s\\S]*$": false
                          },
                          "additionalProperties": true,
                          "propertyNames": {
                            "type": "string",
                            "enum": [
                              "completed",
                              "total",
                              "message"
                            ]
                          }
                        },
                        "canCancel": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "id",
                        "statusUrl",
                        "state",
                        "acceptedAt",
                        "canCancel"
                      ],
                      "patternProperties": {
                        "^(?!(?:id|statusUrl|state|acceptedAt|progress|canCancel)$)[\\s\\S]*$": false
                      },
                      "additionalProperties": true,
                      "propertyNames": {
                        "type": "string",
                        "enum": [
                          "id",
                          "statusUrl",
                          "state",
                          "acceptedAt",
                          "progress",
                          "canCancel"
                        ]
                      }
                    }
                  },
                  "required": [
                    "providerOperation",
                    "itemCount",
                    "operation"
                  ],
                  "patternProperties": {
                    "^(?!(?:providerOperation|itemCount|operation)$)[\\s\\S]*$": false
                  },
                  "additionalProperties": true,
                  "propertyNames": {
                    "type": "string",
                    "enum": [
                      "providerOperation",
                      "itemCount",
                      "operation"
                    ]
                  }
                }
              ]
            },
            {
              "not": {
                "type": "object"
              }
            }
          ]
        }
      },
      "required": [
        "data"
      ],
      "additionalProperties": false
    }
  ]
}
```

### Underlying API operations

- `getleads.previewExecution`: `POST /v1/workspaces/:workspaceId/integrations/getleads/:connectionId/execute/preview`
- `getleads.execute`: `POST /v1/workspaces/:workspaceId/integrations/getleads/:connectionId/execute`

