> ## Documentation Index
> Fetch the complete documentation index at: https://deepline.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# LeadMagic: Company Lookalike

> Find companies similar to a seed company domain or a free-text description, with optional company filters. Includes SDK V2 examples, schemas, and cost.

Find companies similar to a seed company domain or a free-text description, with optional company filters.

> [!NOTE]
>
> Tool ID: `leadmagic_company_lookalike`

## Run this action

Use the TypeScript SDK for one call. Use `ctx.tools.execute(...)` inside a Play for durable calls, scheduled calls, or CSV processing.

```ts theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
import { Deepline } from 'deepline';

const deepline = await Deepline.connect();
const result = await deepline.tools.execute(
  'leadmagic_company_lookalike',
  {
    "company_domain": "example.com",
    "domain": "example.com",
    "website": "https://example.com"
  },
);

console.log(result.toolResponse.raw);
```

### CLI

```bash theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
deepline run leadmagic_company_lookalike --input '{
  "company_domain": "example.com",
  "domain": "example.com",
  "website": "https://example.com"
}'
```

## Example response

The SDK returns this shape at `result.toolResponse.raw`. The example values illustrate the response.

```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
{
  "data": {
    "message": "Example message",
    "companies": [
      {
        "company_domain": "example.com",
        "company_name": "Example Corp",
        "company_website": "https://example.com"
      }
    ],
    "count": 123,
    "returned_count": 123
  }
}
```

Use `deepline describe leadmagic_company_lookalike --json` for the latest machine-readable contract.

## Input reference

Find similar companies from a seed domain or description with full company output. Common aliases (`domain`, `website`, `company_website`, `name`) and misspellings (`companny_domain`, `limmit`, …) are accepted and remapped.

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `payload.company_domain` | `string` | No | — | Seed company domain. Aliases include domain, website, company\_website, seed.domain. Typos like companny\_domain are remapped. |
| `payload.domain` | `string` | No | — | Alias for company\_domain. |
| `payload.website` | `string` | No | — | Seed website URL or domain. |
| `payload.company_website` | `string` | No | — | Alias for website. |
| `payload.company_name` | `string` | No | — | Seed company name used as text intent when no domain is supplied. |
| `payload.name` | `string` | No | — | Alias for company\_name. |
| `payload.description` | `string` | No | — | Free-text seed description. |
| `payload.company_description` | `string` | No | — | Alias for description. |
| `payload.seed` | `object` | No | — | Optional seed object. Prefer seed.domain. |
| `payload.company_filters` | `object` | No | — | Same full company filter family as Company Search. Alias filters. |
| `payload.filters` | `object` | No | — | Alias for company\_filters. |
| `payload.limit` | `integer` | No | `25` | Page size. Typos like limmit are remapped. Minimum: 1. Maximum: 2000. |
| `payload.offset` | `integer` | No | `0` | Offset into the similarity ranking (100, 200, …). Lookalike has no cursor. Deeper pages take longer. Minimum: 0. Maximum: 2000. |

<details>
  <summary>Show raw input schema</summary>

  ### Input JSON Schema

  ```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
  {
    "type": "object",
    "description": "Find similar companies from a seed domain or description with full company output. Common aliases (`domain`, `website`, `company_website`, `name`) and misspellings (`companny_domain`, `limmit`, …) are accepted and remapped.",
    "properties": {
      "company_domain": {
        "type": "string",
        "description": "Seed company domain. Aliases include domain, website, company_website, seed.domain. Typos like companny_domain are remapped."
      },
      "domain": {
        "type": "string",
        "description": "Alias for company_domain."
      },
      "website": {
        "type": "string",
        "description": "Seed website URL or domain."
      },
      "company_website": {
        "type": "string",
        "description": "Alias for website."
      },
      "company_name": {
        "type": "string",
        "description": "Seed company name used as text intent when no domain is supplied."
      },
      "name": {
        "type": "string",
        "description": "Alias for company_name."
      },
      "description": {
        "type": "string",
        "description": "Free-text seed description."
      },
      "company_description": {
        "type": "string",
        "description": "Alias for description."
      },
      "seed": {
        "type": "object",
        "description": "Optional seed object. Prefer seed.domain.",
        "additionalProperties": true
      },
      "company_filters": {
        "type": "object",
        "description": "Same full company filter family as Company Search. Alias filters.",
        "additionalProperties": true
      },
      "filters": {
        "type": "object",
        "description": "Alias for company_filters.",
        "additionalProperties": true
      },
      "limit": {
        "type": "integer",
        "description": "Page size. Typos like limmit are remapped.",
        "default": 25,
        "minimum": 1,
        "maximum": 2000
      },
      "offset": {
        "type": "integer",
        "description": "Offset into the similarity ranking (100, 200, …). Lookalike has no cursor. Deeper pages take longer.",
        "default": 0,
        "minimum": 0,
        "maximum": 2000
      }
    },
    "required": [],
    "additionalProperties": true
  }
  ```
</details>

## Output reference

Standard tool result payload.

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `result.data` | `object` | Yes | — | Provider response payload. |
| `result.data.message` | `string` | Yes | — | — |
| `result.data.companies` | `array` | Yes | — | — |
| `result.data.companies[].company_domain` | `string` | No | — | — |
| `result.data.companies[].company_name` | `string` | No | — | — |
| `result.data.companies[].company_website` | `string` | No | — | — |
| `result.data.companies[].company_industry_linkedin` | `string` | No | — | — |
| `result.data.companies[].employee_range` | `string` | No | — | — |
| `result.data.companies[].employee_min` | `integer` | No | — | — |
| `result.data.companies[].employee_max` | `integer` | No | — | — |
| `result.data.companies[].linkedin_employee_count` | `integer` | No | — | — |
| `result.data.companies[].revenue_range` | `string` | No | — | — |
| `result.data.companies[].revenue_min` | `string` | No | — | — |
| `result.data.companies[].revenue_max` | `string` | No | — | — |
| `result.data.companies[].hq_country` | `string` | No | — | — |
| `result.data.companies[].hq_country_code` | `string` | No | — | — |
| `result.data.companies[].hq_city` | `string` | No | — | — |
| `result.data.companies[].hq_state` | `string` | No | — | — |
| `result.data.companies[].similarity` | `number` | No | — | Lookalike similarity score when available |
| `result.data.companies[].source_seed_domain` | `string` | No | — | — |
| `result.data.companies[].match_context` | `string` | No | — | — |
| `result.data.count` | `integer` | Yes | — | — |
| `result.data.returned_count` | `integer` | Yes | — | — |
| `result.data.limit_applied` | `integer` | No | — | — |
| `result.data.offset` | `integer` | No | — | — |
| `result.data.interpreted_search` | `record` | No | — | Normalized seed and company\_filters used for the query |
| `result.data.metadata` | `object` | No | — | — |
| `result.data.metadata.query_name` | `string` | No | — | — |
| `result.data.metadata.query_path` | `string` | No | — | — |
| `result.data.metadata.preview` | `boolean` | No | — | — |
| `result.data.metadata.has_more` | `boolean` | No | — | True when this page came back full. request metadata.next\_offset next |
| `result.data.metadata.next_offset` | `integer \| null` | No | — | Offset for the next page, or null when has\_more is false |
| `result.data.metadata.limit_clamped` | `boolean` | No | — | Present (true) when the requested limit exceeded the 100-row page |
| `result.data.metadata.requested_limit` | `integer` | No | — | The limit sent, when clamped |
| `result.data.metadata.applied_limit` | `integer` | No | — | The page size used, when clamped |
| `result.data.metadata.degraded` | `boolean` | No | — | True when upstream was briefly unavailable and an empty free response was returned |
| `result.meta` | `object` | No | — | Additional response metadata (status, paging). |

<details>
  <summary>Show raw output schema</summary>

  ### Output JSON Schema

  ```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
  {
    "type": "object",
    "description": "Standard tool result payload.",
    "properties": {
      "data": {
        "type": "object",
        "description": "Provider response payload.",
        "properties": {
          "message": {
            "type": "string"
          },
          "companies": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "company_domain": {
                  "type": "string"
                },
                "company_name": {
                  "type": "string"
                },
                "company_website": {
                  "type": "string"
                },
                "company_industry_linkedin": {
                  "type": "string"
                },
                "employee_range": {
                  "type": "string"
                },
                "employee_min": {
                  "type": "integer"
                },
                "employee_max": {
                  "type": "integer"
                },
                "linkedin_employee_count": {
                  "type": "integer"
                },
                "revenue_range": {
                  "type": "string"
                },
                "revenue_min": {
                  "type": "string"
                },
                "revenue_max": {
                  "type": "string"
                },
                "hq_country": {
                  "type": "string"
                },
                "hq_country_code": {
                  "type": "string"
                },
                "hq_city": {
                  "type": "string"
                },
                "hq_state": {
                  "type": "string"
                },
                "similarity": {
                  "type": "number",
                  "description": "Lookalike similarity score when available"
                },
                "source_seed_domain": {
                  "type": "string"
                },
                "match_context": {
                  "type": "string"
                }
              },
              "additionalProperties": true
            }
          },
          "count": {
            "type": "integer"
          },
          "returned_count": {
            "type": "integer"
          },
          "limit_applied": {
            "type": "integer"
          },
          "offset": {
            "type": "integer"
          },
          "interpreted_search": {
            "type": "object",
            "description": "Normalized seed and company_filters used for the query",
            "additionalProperties": true
          },
          "metadata": {
            "type": "object",
            "properties": {
              "query_name": {
                "type": "string"
              },
              "query_path": {
                "type": "string"
              },
              "preview": {
                "type": "boolean"
              },
              "has_more": {
                "type": "boolean",
                "description": "True when this page came back full; request metadata.next_offset next"
              },
              "next_offset": {
                "type": [
                  "integer",
                  "null"
                ],
                "description": "Offset for the next page, or null when has_more is false"
              },
              "limit_clamped": {
                "type": "boolean",
                "description": "Present (true) when the requested limit exceeded the 100-row page"
              },
              "requested_limit": {
                "type": "integer",
                "description": "The limit sent, when clamped"
              },
              "applied_limit": {
                "type": "integer",
                "description": "The page size used, when clamped"
              },
              "degraded": {
                "type": "boolean",
                "description": "True when upstream was briefly unavailable and an empty free response was returned"
              }
            },
            "additionalProperties": true
          }
        },
        "required": [
          "message",
          "companies",
          "count",
          "returned_count"
        ],
        "additionalProperties": true
      },
      "meta": {
        "type": "object",
        "description": "Additional response metadata (status, paging).",
        "additionalProperties": true
      }
    },
    "required": [
      "data"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Deepline cost

* Pricing model: `per_result` (per result).
* Estimated Deepline credits: `1.68` per pricing unit.

## Related documentation

* [Connect integrations](https://deepline.com/docs/integrations.md)
* [SDK V2 quickstart](https://deepline.com/docs/sdk-v2/quickstart.md)
* [SDK reference](https://deepline.com/docs/sdk-v2/sdk-reference.md)
* [Run tools across a CSV](https://deepline.com/docs/sdk-v2/batch-csv.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.