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

# ResolveLeadReferencesAPI mirrors the erdo_resolve_lead_references MCP tool.




## OpenAPI

````yaml /api/openapi.json post /v1/datasets/{datasetSlug}/lead-reference-resolutions
openapi: 3.0.0
info:
  title: Erdo API
  description: >-
    Erdo's REST API: query and write datasets, run agents, manage threads,
    integrations, pages, evals, workstreams, experiments, and bounded outreach.
    Authenticate with a Bearer API key (erdo_api_...) or scoped token
    (erdo_token_...).
  version: '2026-11-21'
servers:
  - url: https://api.erdo.ai
    description: Production
security:
  - bearerAuth: []
paths:
  /v1/datasets/{datasetSlug}/lead-reference-resolutions:
    post:
      summary: >
        ResolveLeadReferencesAPI mirrors the erdo_resolve_lead_references MCP
        tool.
      operationId: POST:mcp.ResolveLeadReferencesAPI
      parameters:
        - allowEmptyValue: true
          explode: false
          in: path
          name: datasetSlug
          required: true
          schema:
            type: string
          style: simple
      requestBody:
        content:
          application/json:
            schema:
              properties:
                lead_refs:
                  items:
                    type: string
                  type: array
                  minItems: 1
              type: object
              required:
                - lead_refs
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  invalid:
                    items:
                      type: string
                    type: array
                  not_found:
                    items:
                      type: string
                    type: array
                  resolved:
                    items:
                      $ref: >-
                        #/components/schemas/dataset.ResolvedCanonicalLeadReference
                    type: array
                type: object
          description: Success response
        default:
          $ref: '#/components/responses/APIError'
components:
  schemas:
    dataset.ResolvedCanonicalLeadReference:
      properties:
        lead_ref:
          type: string
        merged:
          type: boolean
        survivor_canonical_lead_id:
          type: string
        survivor_lead_ref:
          type: string
      type: object
  responses:
    APIError:
      content:
        application/json:
          schema:
            externalDocs:
              url: https://pkg.go.dev/encore.dev/beta/errs#Error
            properties:
              code:
                description: Error code
                example: not_found
                externalDocs:
                  url: https://pkg.go.dev/encore.dev/beta/errs#ErrCode
                type: string
              details:
                description: Error details
                type: object
              message:
                description: Error message
                type: string
            title: APIError
            type: object
      description: Error response
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: An Erdo API key (erdo_api_...) or scoped token (erdo_token_...).

````

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