{
  "openapi": "3.0.1",
  "info": {
    "title": "Retention API",
    "version": "v1",
    "description": "Retention.com identity & data resolution APIs."
  },
  "servers": [
    {
      "url": "https://api.rb2b.com"
    }
  ],
  "components": {
    "securitySchemes": {
      "api_key": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Api-Key",
        "description": "Per-account API key. Also accepted as `Api-Key` or `Authorization: Bearer <key>`."
      }
    },
    "schemas": {
      "AuthError": {
        "type": "object",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "string",
            "enum": [
              "missing_api_key",
              "invalid_api_key_format",
              "invalid_api_key"
            ],
            "description": "`missing_api_key`: no key supplied. `invalid_api_key_format`: key does not match the expected format. `invalid_api_key`: key does not belong to any account."
          }
        }
      },
      "InsufficientCreditsError": {
        "type": "object",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "string",
            "enum": [
              "insufficient_api_credits"
            ]
          },
          "required": {
            "type": "string",
            "description": "Credits needed for this request.",
            "example": "1.0"
          },
          "remaining": {
            "type": "string",
            "description": "Credits currently remaining on the account.",
            "example": "0.0"
          }
        }
      },
      "ServiceDisabledError": {
        "type": "object",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "string",
            "enum": [
              "service_unavailable_for_key"
            ]
          }
        }
      },
      "Hem": {
        "type": "object",
        "description": "Hashed email (HEM) pair for the same underlying address.",
        "properties": {
          "md5": {
            "type": "string",
            "example": "5d41402abc4b2a76b9719d911017c592"
          },
          "sha256": {
            "type": "string",
            "example": "2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824"
          }
        }
      },
      "Maid": {
        "type": "object",
        "description": "Mobile advertising ID (MAID) entry. Either field can be null when only one side of the pair is known.",
        "properties": {
          "device_id": {
            "type": "string",
            "nullable": true,
            "example": "6D92078A-8246-4BA4-AE5B-76104861E7DC"
          },
          "device_type": {
            "type": "string",
            "nullable": true,
            "example": "idfa"
          }
        }
      }
    }
  },
  "paths": {
    "/api/v1/business_email_to_personal_hem": {
      "post": {
        "summary": "Work Email → Personal Email",
        "tags": [
          "Email"
        ],
        "operationId": "businessEmailToPersonalHem",
        "description": "Match a work email to a hashed personal email.\n\nProvide a valid plaintext work `email`. On a match, the response contains the person's personal email addresses as SHA-256 hashes; on a miss the `personal_email_sha256s` array is empty.\n\n**Billing:** 1 credit per successful match (HTTP 200). Misses (404) and request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Personal hashed emails found (1 credit charged)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "type": "object",
                      "required": [
                        "personal_email_sha256s"
                      ],
                      "properties": {
                        "personal_email_sha256s": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "example": "2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824"
                          },
                          "description": "SHA-256 hashes of the personal email addresses matched to the supplied work email. Deduplicated; at least one entry on HTTP 200."
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing email",
                        "invalid email",
                        "unexpected connection error",
                        "unexpected error"
                      ],
                      "description": "`missing email`: no email was provided. `invalid email`: the input is not a valid email address. `unexpected connection error` / `unexpected error`: temporary error; safe to retry."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No match found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "type": "object",
                      "required": [
                        "personal_email_sha256s"
                      ],
                      "properties": {
                        "personal_email_sha256s": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "maxItems": 0,
                          "description": "Always empty; no personal emails matched the supplied work email."
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "email"
                ],
                "properties": {
                  "email": {
                    "type": "string",
                    "format": "email",
                    "description": "Plaintext work email address. Must be a valid email address.",
                    "example": "alice@acme.com"
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/credits": {
      "get": {
        "summary": "Get remaining API credits",
        "tags": [
          "Account"
        ],
        "operationId": "getCredits",
        "description": "Returns the account's remaining API credit balance.\n\nAuthenticates with the API key only; no per-service enablement or minimum credit balance is required. When the optional `Api-Origin-Key` header identifies a partner account, the endpoint instead returns a partner usage report aggregating API call counts across every account that shares the partner's custom origin, over the `start_date`/`end_date` range (defaults: beginning of the current month through today). An unknown origin key returns 401 `invalid_origin_key`; a partner account without a configured custom origin returns 400 `no_custom_origin_configured`.\n\n**Billing:** never billed; this endpoint does not consume credits.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [
          {
            "name": "Api-Origin-Key",
            "in": "header",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Partner origin key. When present, switches the response to a partner usage report covering all accounts that share the partner's custom origin. Also accepted as `X-Api-Origin-Key`."
          },
          {
            "name": "start_date",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date"
            },
            "description": "Start of the partner usage report range (ISO 8601 date, e.g. `2026-06-01`). Defaults to the beginning of the current month. Only used with `Api-Origin-Key`."
          },
          {
            "name": "end_date",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "format": "date"
            },
            "description": "End of the partner usage report range (ISO 8601 date, e.g. `2026-06-10`). Defaults to today. Only used with `Api-Origin-Key`."
          }
        ],
        "responses": {
          "200": {
            "description": "Credits returned",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "credits_remaining"
                  ],
                  "properties": {
                    "credits_remaining": {
                      "type": "number",
                      "format": "float",
                      "description": "API credits currently remaining on the account. (When `Api-Origin-Key` is supplied, the body is a partner usage report instead: `partner_origin`, `date_range`, `summary`, and per-account `accounts` usage breakdowns.)",
                      "example": 1000
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing_api_key",
                        "invalid_api_key_format",
                        "invalid_api_key",
                        "invalid_origin_key"
                      ],
                      "description": "`missing_api_key`: no key supplied. `invalid_api_key_format`: key does not match the expected format. `invalid_api_key`: key does not belong to any account. `invalid_origin_key`: the `Api-Origin-Key` header does not match any partner account."
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/email_to_activity": {
      "post": {
        "summary": "Email Activity Check",
        "tags": [
          "Email"
        ],
        "operationId": "emailToActivity",
        "description": "See when an email was last active online. Send one email address per request, or an array of up to 1,000 addresses in a single request.\n\nBatch endpoint: provide `emails` (an array of up to 1,000 plaintext addresses) or a single `email`. Duplicate addresses count once (matching is case-insensitive and ignores surrounding whitespace). The response lists only the addresses with known activity, each with its `last_active` date; addresses with no match are omitted from `results`.\n\n**Billing:** 1 credit per matched email. Misses are free. Matches are billed in input order until the account's credit balance runs out; any further matches are dropped from the response and `credits_exhausted` is returned as `true`. `match_count` and `credits_charged` both reflect the number of matches actually returned and billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Activity results for matched emails (1 credit per match)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results",
                    "match_count",
                    "credits_charged",
                    "credits_exhausted"
                  ],
                  "properties": {
                    "results": {
                      "type": "array",
                      "description": "One entry per matched (and billed) email, in input order. Emails with no known activity are omitted.",
                      "items": {
                        "type": "object",
                        "required": [
                          "email",
                          "last_active"
                        ],
                        "properties": {
                          "email": {
                            "type": "string",
                            "format": "email",
                            "description": "The input email address, echoed back as supplied.",
                            "example": "alice@example.com"
                          },
                          "last_active": {
                            "type": "string",
                            "format": "date",
                            "description": "Date the email was last seen active online (ISO 8601).",
                            "example": "2026-05-01"
                          }
                        }
                      }
                    },
                    "match_count": {
                      "type": "integer",
                      "description": "Number of matched emails returned in `results`.",
                      "example": 1
                    },
                    "credits_charged": {
                      "type": "integer",
                      "description": "Credits charged for this request; equal to the number of matches returned (1 credit per match).",
                      "example": 1
                    },
                    "credits_exhausted": {
                      "type": "boolean",
                      "description": "`true` when the account ran out of credits before all matches could be billed; the unbilled matches are not returned.",
                      "example": false
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing emails",
                        "too_many_emails",
                        "invalid email",
                        "unexpected error"
                      ],
                      "description": "`missing emails`: neither `emails` nor `email` was provided (or all entries were blank). `too_many_emails`: more than 1,000 addresses were submitted; see `max`. `invalid email`: at least one entry is not a valid email address. `unexpected error`: temporary error; safe to retry."
                    },
                    "max": {
                      "type": "integer",
                      "description": "Maximum batch size. Present only with `too_many_emails`.",
                      "example": 1000
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "description": "Provide `emails` (preferred, up to 1,000 addresses) or a single `email`. When both are present, `emails` wins.",
                "properties": {
                  "emails": {
                    "type": "array",
                    "maxItems": 1000,
                    "items": {
                      "type": "string",
                      "format": "email"
                    },
                    "description": "Email addresses to check, up to 1,000 per request. Blank entries are ignored; duplicates count once (matching is case-insensitive and ignores surrounding whitespace).",
                    "example": [
                      "alice@example.com",
                      "bob@example.com"
                    ]
                  },
                  "email": {
                    "type": "string",
                    "format": "email",
                    "description": "Single email address (alternative to the `emails` array).",
                    "example": "alice@example.com"
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/hem_to_best_linkedin": {
      "post": {
        "summary": "Email → Best LinkedIn",
        "tags": [
          "HEM"
        ],
        "operationId": "hemToBestLinkedin",
        "description": "Return the most reliable and active LinkedIn profile tied to an email. Accepts a hashed or plaintext email.\n\nProvide either a pre-computed `md5` (32-character hex digest of the lowercased, trimmed email) or a plaintext `email`. Returns the full URL of the most reliable and active LinkedIn profile for the hashed email.\n\n**Billing:** 1 credit per successful match (HTTP 200). Misses (404) and request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Best LinkedIn URL found (1 credit charged)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "type": "object",
                      "required": [
                        "linkedin_url"
                      ],
                      "properties": {
                        "linkedin_url": {
                          "type": "string",
                          "description": "Full URL of the most reliable and active LinkedIn profile for the supplied hashed email.",
                          "example": "https://linkedin.com/in/alice"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing md5_or_email",
                        "invalid md5",
                        "unexpected connection error",
                        "unexpected error"
                      ],
                      "description": "`missing md5_or_email`: neither `md5` nor `email` was provided. `invalid md5`: the MD5 is not a 32-character hex digest. `unexpected connection error` / `unexpected error`: temporary error; safe to retry."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No LinkedIn profile found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "type": "object",
                      "required": [
                        "linkedin_url"
                      ],
                      "properties": {
                        "linkedin_url": {
                          "type": "string",
                          "nullable": true,
                          "description": "Always `null`; no LinkedIn profile matched the supplied hashed email."
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "description": "At least one of `md5` or `email` is required.",
                "properties": {
                  "md5": {
                    "type": "string",
                    "pattern": "^[a-fA-F0-9]{32}$",
                    "description": "MD5 hash of the lowercased, trimmed email address.",
                    "example": "5d41402abc4b2a76b9719d911017c592"
                  },
                  "email": {
                    "type": "string",
                    "format": "email",
                    "description": "Plaintext email address. Used only when `md5` is absent.",
                    "example": "alice@example.com"
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/hem_to_business_profile": {
      "post": {
        "summary": "Email → Business Profile",
        "tags": [
          "HEM"
        ],
        "operationId": "hemToBusinessProfile",
        "description": "Enrich an email into a full work profile: name, title, company, seniority. Accepts a hashed or plaintext email.\n\nProvide either a pre-computed `md5` (32-character hex digest of the lowercased, trimmed email) or a plaintext `email`. Email fields are MD5-hashed unless you send a plaintext `email`.\n\n**Billing:** 2 credits per successful match (HTTP 200). Misses (404) and request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Profile found (2 credits charged)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "description": "Work profile for the matched contact. Only fields known for the contact are present.",
                      "additionalProperties": true,
                      "properties": {
                        "first_name": {
                          "type": "string",
                          "example": "Alice"
                        },
                        "last_name": {
                          "type": "string",
                          "example": "Smith"
                        },
                        "title": {
                          "type": "string",
                          "example": "VP of Marketing"
                        },
                        "seniority": {
                          "type": "string",
                          "example": "vp"
                        },
                        "functional_area": {
                          "type": "string",
                          "example": "Marketing"
                        },
                        "current_company": {
                          "type": "string",
                          "description": "Company name (title-cased).",
                          "example": "Acme"
                        },
                        "current_industry": {
                          "type": "string",
                          "example": "Computer Software"
                        },
                        "country": {
                          "type": "string",
                          "example": "United States"
                        },
                        "linkedin_slug": {
                          "type": "string",
                          "description": "LinkedIn public profile slug.",
                          "example": "alice-123"
                        },
                        "company_employee_range": {
                          "type": "string",
                          "nullable": true,
                          "example": "51-200"
                        },
                        "company_revenue_range": {
                          "type": "string",
                          "nullable": true,
                          "example": "$10M-$50M"
                        },
                        "work_email_confirmed": {
                          "type": "string",
                          "description": "Confirmed work email. MD5-hashed unless you send a plaintext `email`.",
                          "example": "alice@acme.com"
                        },
                        "personal_emails": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Personal email addresses. MD5-hashed unless you send a plaintext `email`."
                        },
                        "mobile_phone": {
                          "type": "string",
                          "nullable": true,
                          "description": "Mobile phone number. Present only when `include_mobile_phone` was requested.",
                          "example": "+14155550123"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing md5_or_email",
                        "invalid md5",
                        "unexpected connection error",
                        "unexpected error"
                      ],
                      "description": "`missing md5_or_email`: neither `md5` nor `email` was provided. `invalid md5`: the MD5 is not a 32-character hex digest. `unexpected connection error` / `unexpected error`: temporary error; safe to retry."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No profile found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "description": "Empty object; no match for the supplied hashed email.",
                      "maxProperties": 0
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "description": "At least one of `md5` or `email` is required.",
                "properties": {
                  "md5": {
                    "type": "string",
                    "pattern": "^[a-fA-F0-9]{32}$",
                    "description": "MD5 hash of the lowercased, trimmed email address.",
                    "example": "5d41402abc4b2a76b9719d911017c592"
                  },
                  "email": {
                    "type": "string",
                    "format": "email",
                    "description": "Plaintext email address. When present, email fields in the response are returned in plaintext.",
                    "example": "alice@example.com"
                  },
                  "include_mobile_phone": {
                    "type": "boolean",
                    "default": false,
                    "description": "Also look up the contact's mobile phone number and include it as `mobile_phone` in the result."
                  },
                  "require_email": {
                    "type": "boolean",
                    "default": false,
                    "description": "Only return and bill for profiles that contain an email address."
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/hem_to_linkedin": {
      "post": {
        "summary": "Email → LinkedIn",
        "tags": [
          "HEM"
        ],
        "operationId": "hemToLinkedin",
        "description": "Find the LinkedIn profile that belongs to an email. Accepts a hashed or plaintext email.\n\nProvide either a pre-computed `md5` (32-character hex digest of the lowercased, trimmed email) or a plaintext `email`. Returns the LinkedIn public profile slug matched to the hashed email.\n\n**Billing:** 1 credit per successful match (HTTP 200). Misses (404) and request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "LinkedIn slug found (1 credit charged)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "type": "object",
                      "required": [
                        "linkedin_slug"
                      ],
                      "properties": {
                        "linkedin_slug": {
                          "type": "string",
                          "description": "LinkedIn public profile slug matched to the supplied hashed email (the part after `linkedin.com/in/`).",
                          "example": "alice-123"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing md5_or_email",
                        "invalid md5",
                        "unexpected error"
                      ],
                      "description": "`missing md5_or_email`: neither `md5` nor `email` was provided. `invalid md5`: the MD5 is not a 32-character hex digest. `unexpected error`: temporary error; safe to retry."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No LinkedIn profile found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "type": "object",
                      "required": [
                        "linkedin_slug"
                      ],
                      "properties": {
                        "linkedin_slug": {
                          "type": "string",
                          "nullable": true,
                          "description": "Always `null`; no LinkedIn profile matched the supplied hashed email."
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "description": "At least one of `md5` or `email` is required.",
                "properties": {
                  "md5": {
                    "type": "string",
                    "pattern": "^[a-fA-F0-9]{32}$",
                    "description": "MD5 hash of the lowercased, trimmed email address.",
                    "example": "5d41402abc4b2a76b9719d911017c592"
                  },
                  "email": {
                    "type": "string",
                    "format": "email",
                    "description": "Plaintext email address. Used only when `md5` is absent.",
                    "example": "alice@example.com"
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/identity/business": {
      "post": {
        "summary": "Full Business Enrichment",
        "tags": [
          "Identity"
        ],
        "operationId": "identityBusiness",
        "description": "One call returns everything for a contact: work profile, device IDs, hashed emails. Send a hashed or plaintext email, an IP address, or a batch of up to 1,000 values.\n\nSingle mode: provide a pre-computed `md5`, a plaintext `email`, or an IPv4 or IPv6 `ip_address` with an optional `user_agent`. USA IPs only! Choose exactly one identifier family. The response combines the business profile (same field names as `/hem_to_business_profile`) with the contact's mobile advertising IDs. `work_email_confirmed` is always plaintext, with `work_email_confirmed_md5` and `work_email_confirmed_sha256` alongside so callers have all three forms; no personal email data is returned. The `maid` key is always present (`null` when no MAID data is found), and when the profile lookup misses but MAID data exists the full profile shape is still returned with `null` values. A match returns HTTP 200 `{ result: {...} }`; a miss returns HTTP 404 `{ result: {} }`.\n\nBatch mode: send an `md5s` or `ips` array (max 1,000). MD5s are lowercased and de-duplicated; equivalent IP spellings are de-duplicated while preserving the first input. One malformed MD5 fails the whole request with HTTP 400 before any lookups run. Otherwise the response is always HTTP 200 with `results`, `match_count`, `credits_charged`, and `credits_exhausted`. Every matched result returns `md5`; IP batch results also echo `ip_address`. Inputs with no data are omitted. Processing stops once the account's remaining credits are exhausted (`credits_exhausted: true`).\n\n**Billing:** the full configured per-record cost when both the business profile and MAID data match; 1 credit when only one of the two sources resolves (partial data); 0 credits for a miss (single-mode 404, or omitted from batch `results`). IP-sourced matches add 1 credit (full 4, partial 2 at the default price). Request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Business identity found",
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "type": "object",
                      "required": [
                        "result"
                      ],
                      "description": "Single-lookup response (`md5`, `email`, or `ip_address` input).",
                      "properties": {
                        "result": {
                          "type": "object",
                          "description": "Business profile plus MAID data for the matched contact. Additional fields may appear as new data becomes available.",
                          "additionalProperties": true,
                          "properties": {
                            "md5": {
                              "type": "string",
                              "nullable": true,
                              "description": "Matched HEM. For IP input, this is the winning resolved HEM.",
                              "example": "5d41402abc4b2a76b9719d911017c592"
                            },
                            "first_name": {
                              "type": "string",
                              "nullable": true,
                              "example": "Alice"
                            },
                            "last_name": {
                              "type": "string",
                              "nullable": true,
                              "example": "Smith"
                            },
                            "title": {
                              "type": "string",
                              "nullable": true,
                              "example": "VP of Marketing"
                            },
                            "seniority": {
                              "type": "string",
                              "nullable": true,
                              "example": "vp"
                            },
                            "functional_area": {
                              "type": "string",
                              "nullable": true,
                              "example": "Marketing"
                            },
                            "current_industry": {
                              "type": "string",
                              "nullable": true,
                              "example": "Computer Software"
                            },
                            "country": {
                              "type": "string",
                              "nullable": true,
                              "example": "United States"
                            },
                            "linkedinurl": {
                              "type": "string",
                              "nullable": true,
                              "description": "LinkedIn public profile URL.",
                              "example": "https://www.linkedin.com/in/alice-123"
                            },
                            "current_company": {
                              "type": "string",
                              "nullable": true,
                              "description": "Company name (title-cased).",
                              "example": "Acme"
                            },
                            "current_company_linkedinurl": {
                              "type": "string",
                              "nullable": true,
                              "example": "https://www.linkedin.com/company/acme"
                            },
                            "current_company_url": {
                              "type": "string",
                              "nullable": true,
                              "example": "https://acme.com"
                            },
                            "company_employee_count": {
                              "type": "string",
                              "nullable": true,
                              "example": "120"
                            },
                            "company_employee_range": {
                              "type": "string",
                              "nullable": true,
                              "example": "51-200"
                            },
                            "company_revenue_range": {
                              "type": "string",
                              "nullable": true,
                              "example": "$10M-$50M"
                            },
                            "work_email_confirmed": {
                              "type": "string",
                              "nullable": true,
                              "description": "Confirmed work email, always returned in plaintext.",
                              "example": "alice@acme.com"
                            },
                            "work_email_confirmed_md5": {
                              "type": "string",
                              "nullable": true,
                              "description": "MD5 hash of `work_email_confirmed`.",
                              "example": "4eb2eb38f58a848b48244e95b1e88bff"
                            },
                            "work_email_confirmed_sha256": {
                              "type": "string",
                              "nullable": true,
                              "description": "SHA-256 hash of `work_email_confirmed`.",
                              "example": "973dfe463ec85785f5f95af5ba3906eedb2d931c24e69824a89ea65dba4e813b"
                            },
                            "work_email_confirmed_status": {
                              "type": "string",
                              "description": "Date the work email was last confirmed. Only present when a confirmation date is known.",
                              "example": "2025-11-03"
                            },
                            "maid": {
                              "type": "array",
                              "nullable": true,
                              "description": "Mobile advertising IDs linked to the contact. The key is always present; `null` when no MAID data was found.",
                              "items": {
                                "$ref": "#/components/schemas/Maid"
                              }
                            }
                          }
                        }
                      }
                    },
                    {
                      "type": "object",
                      "required": [
                        "results",
                        "match_count",
                        "credits_charged",
                        "credits_exhausted"
                      ],
                      "description": "Batch response (`md5s` or `ips` input). Always HTTP 200.",
                      "properties": {
                        "results": {
                          "type": "array",
                          "description": "One entry per matched input identifier, in input order. Unmatched inputs are omitted.",
                          "items": {
                            "oneOf": [
                              {
                                "type": "object",
                                "required": [
                                  "md5"
                                ],
                                "not": {
                                  "required": [
                                    "ip_address"
                                  ]
                                },
                                "additionalProperties": true,
                                "properties": {
                                  "md5": {
                                    "type": "string",
                                    "description": "Input MD5 correlation key."
                                  },
                                  "first_name": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "Alice"
                                  },
                                  "last_name": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "Smith"
                                  },
                                  "title": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "VP of Marketing"
                                  },
                                  "seniority": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "vp"
                                  },
                                  "functional_area": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "Marketing"
                                  },
                                  "current_industry": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "Computer Software"
                                  },
                                  "country": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "United States"
                                  },
                                  "linkedinurl": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "LinkedIn public profile URL.",
                                    "example": "https://www.linkedin.com/in/alice-123"
                                  },
                                  "current_company": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "Company name (title-cased).",
                                    "example": "Acme"
                                  },
                                  "current_company_linkedinurl": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "https://www.linkedin.com/company/acme"
                                  },
                                  "current_company_url": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "https://acme.com"
                                  },
                                  "company_employee_count": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "120"
                                  },
                                  "company_employee_range": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "51-200"
                                  },
                                  "company_revenue_range": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "$10M-$50M"
                                  },
                                  "work_email_confirmed": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "Confirmed work email, always returned in plaintext.",
                                    "example": "alice@acme.com"
                                  },
                                  "work_email_confirmed_md5": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "MD5 hash of `work_email_confirmed`.",
                                    "example": "4eb2eb38f58a848b48244e95b1e88bff"
                                  },
                                  "work_email_confirmed_sha256": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "SHA-256 hash of `work_email_confirmed`.",
                                    "example": "973dfe463ec85785f5f95af5ba3906eedb2d931c24e69824a89ea65dba4e813b"
                                  },
                                  "work_email_confirmed_status": {
                                    "type": "string",
                                    "description": "Date the work email was last confirmed. Only present when a confirmation date is known.",
                                    "example": "2025-11-03"
                                  },
                                  "maid": {
                                    "type": "array",
                                    "nullable": true,
                                    "description": "Mobile advertising IDs linked to the contact. The key is always present; `null` when no MAID data was found.",
                                    "items": {
                                      "$ref": "#/components/schemas/Maid"
                                    }
                                  }
                                }
                              },
                              {
                                "type": "object",
                                "required": [
                                  "md5",
                                  "ip_address"
                                ],
                                "additionalProperties": true,
                                "properties": {
                                  "md5": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "Matched HEM. For IP input, this is the winning resolved HEM.",
                                    "example": "5d41402abc4b2a76b9719d911017c592"
                                  },
                                  "first_name": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "Alice"
                                  },
                                  "last_name": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "Smith"
                                  },
                                  "title": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "VP of Marketing"
                                  },
                                  "seniority": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "vp"
                                  },
                                  "functional_area": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "Marketing"
                                  },
                                  "current_industry": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "Computer Software"
                                  },
                                  "country": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "United States"
                                  },
                                  "linkedinurl": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "LinkedIn public profile URL.",
                                    "example": "https://www.linkedin.com/in/alice-123"
                                  },
                                  "current_company": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "Company name (title-cased).",
                                    "example": "Acme"
                                  },
                                  "current_company_linkedinurl": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "https://www.linkedin.com/company/acme"
                                  },
                                  "current_company_url": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "https://acme.com"
                                  },
                                  "company_employee_count": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "120"
                                  },
                                  "company_employee_range": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "51-200"
                                  },
                                  "company_revenue_range": {
                                    "type": "string",
                                    "nullable": true,
                                    "example": "$10M-$50M"
                                  },
                                  "work_email_confirmed": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "Confirmed work email, always returned in plaintext.",
                                    "example": "alice@acme.com"
                                  },
                                  "work_email_confirmed_md5": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "MD5 hash of `work_email_confirmed`.",
                                    "example": "4eb2eb38f58a848b48244e95b1e88bff"
                                  },
                                  "work_email_confirmed_sha256": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "SHA-256 hash of `work_email_confirmed`.",
                                    "example": "973dfe463ec85785f5f95af5ba3906eedb2d931c24e69824a89ea65dba4e813b"
                                  },
                                  "work_email_confirmed_status": {
                                    "type": "string",
                                    "description": "Date the work email was last confirmed. Only present when a confirmation date is known.",
                                    "example": "2025-11-03"
                                  },
                                  "maid": {
                                    "type": "array",
                                    "nullable": true,
                                    "description": "Mobile advertising IDs linked to the contact. The key is always present; `null` when no MAID data was found.",
                                    "items": {
                                      "$ref": "#/components/schemas/Maid"
                                    }
                                  },
                                  "ip_address": {
                                    "type": "string",
                                    "description": "Input IP correlation key."
                                  }
                                }
                              }
                            ]
                          }
                        },
                        "match_count": {
                          "type": "integer",
                          "description": "Number of input identifiers that matched and were billed.",
                          "example": 2
                        },
                        "credits_charged": {
                          "type": "number",
                          "description": "Total credits charged for this batch.",
                          "example": 4
                        },
                        "credits_exhausted": {
                          "type": "boolean",
                          "description": "True when processing stopped early because the account ran out of credits; remaining inputs were not processed.",
                          "example": false
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing md5_or_email",
                        "invalid md5",
                        "missing md5s",
                        "too_many_md5s",
                        "missing ip_address",
                        "invalid ip_address",
                        "missing ips",
                        "too_many_ips",
                        "invalid ip",
                        "invalid ips",
                        "conflicting_identifier_inputs",
                        "unexpected connection error",
                        "unexpected error"
                      ],
                      "description": "`missing md5_or_email`: single mode, neither `md5` nor `email` was provided. `invalid md5`: an MD5 is not a 32-character hex digest (in batch mode `invalid` and `index` identify the offending value). `missing md5s`: batch mode with an empty `md5s` array. `too_many_md5s`: more than 1,000 MD5s (see `max`). `unexpected connection error` / `unexpected error`: temporary error; safe to retry."
                    },
                    "max": {
                      "type": "integer",
                      "description": "Present on `too_many_md5s` or `too_many_ips`: the batch size limit.",
                      "example": 1000
                    },
                    "invalid": {
                      "type": "string",
                      "description": "Present on batch `invalid md5` or `invalid ip`: the offending input value.",
                      "example": "not-an-md5"
                    },
                    "index": {
                      "type": "integer",
                      "description": "Present on batch `invalid md5` or `invalid ip`: zero-based position.",
                      "example": 3
                    },
                    "conflicting": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Identifier fields supplied together when `conflicting_identifier_inputs` is returned."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No data found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "description": "Empty object; neither business profile nor MAID data matched the supplied identifier.",
                      "maxProperties": 0
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "description": "Choose exactly one single or batch identifier mode: `md5`/`email`, `md5s`, `ip_address`, or `ips`.",
                "properties": {
                  "md5": {
                    "type": "string",
                    "pattern": "^[a-fA-F0-9]{32}$",
                    "description": "MD5 hash of the lowercased, trimmed email address.",
                    "example": "5d41402abc4b2a76b9719d911017c592"
                  },
                  "email": {
                    "type": "string",
                    "format": "email",
                    "description": "Plaintext email address. Alternative to `md5`.",
                    "example": "alice@example.com"
                  },
                  "md5s": {
                    "type": "array",
                    "minItems": 1,
                    "maxItems": 1000,
                    "items": {
                      "type": "string",
                      "pattern": "^[a-fA-F0-9]{32}$"
                    },
                    "description": "Batch lookup: up to 1,000 MD5 hashes. When present, the request is processed in batch mode. Cannot be combined with IP inputs."
                  },
                  "ip_address": {
                    "type": "string",
                    "description": "Single IPv4 or IPv6 address. USA IPs only! Cannot be combined with email inputs.",
                    "example": "203.0.113.42"
                  },
                  "user_agent": {
                    "type": "string",
                    "description": "Optional browser user agent for a single IP lookup."
                  },
                  "ips": {
                    "type": "array",
                    "minItems": 1,
                    "maxItems": 1000,
                    "items": {
                      "type": "string"
                    },
                    "description": "Batch lookup of up to 1,000 IPv4 or IPv6 addresses. USA IPs only! Cannot be combined with email inputs."
                  }
                },
                "oneOf": [
                  {
                    "anyOf": [
                      {
                        "required": [
                          "md5"
                        ]
                      },
                      {
                        "required": [
                          "email"
                        ]
                      }
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5s"
                          ]
                        },
                        {
                          "required": [
                            "ip_address"
                          ]
                        },
                        {
                          "required": [
                            "ips"
                          ]
                        }
                      ]
                    }
                  },
                  {
                    "required": [
                      "md5s"
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5"
                          ]
                        },
                        {
                          "required": [
                            "email"
                          ]
                        },
                        {
                          "required": [
                            "ip_address"
                          ]
                        },
                        {
                          "required": [
                            "ips"
                          ]
                        }
                      ]
                    }
                  },
                  {
                    "required": [
                      "ip_address"
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5"
                          ]
                        },
                        {
                          "required": [
                            "email"
                          ]
                        },
                        {
                          "required": [
                            "md5s"
                          ]
                        },
                        {
                          "required": [
                            "ips"
                          ]
                        }
                      ]
                    }
                  },
                  {
                    "required": [
                      "ips"
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5"
                          ]
                        },
                        {
                          "required": [
                            "email"
                          ]
                        },
                        {
                          "required": [
                            "md5s"
                          ]
                        },
                        {
                          "required": [
                            "ip_address"
                          ]
                        }
                      ]
                    }
                  }
                ]
              },
              "examples": {
                "single": {
                  "summary": "Single lookup",
                  "value": {
                    "md5": "5d41402abc4b2a76b9719d911017c592"
                  }
                },
                "batch": {
                  "summary": "Batch lookup (up to 1,000)",
                  "value": {
                    "md5s": [
                      "5d41402abc4b2a76b9719d911017c592",
                      "098f6bcd4621d373cade4e832627b4f6"
                    ]
                  }
                },
                "ip": {
                  "summary": "Single IP lookup",
                  "value": {
                    "ip_address": "203.0.113.42",
                    "user_agent": "Mozilla/5.0"
                  }
                },
                "ip_batch": {
                  "summary": "Batch IP lookup (up to 1,000)",
                  "value": {
                    "ips": [
                      "203.0.113.42",
                      "2001:db8::42"
                    ]
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/identity/consumer": {
      "post": {
        "summary": "Personal Identity",
        "tags": [
          "Identity"
        ],
        "operationId": "identityConsumer",
        "description": "B2C consumer identity: personal hashed emails, device IDs, location, and last-seen activity. Accepts hashed or plaintext email and IP address inputs.\n\nSingle mode: provide a pre-computed `md5`, a plaintext `email`, or an IPv4 or IPv6 `ip_address` with an optional `user_agent`. USA IPs only! Choose exactly one identifier family. The response carries the consumer's personal hashed emails (`hems`), mobile advertising IDs (`maids`), `personal_emails`, coarse `location`, and `last_seen_at` activity. `personal_emails` are MD5-hashed unless you send a plaintext `email`. A match returns HTTP 200 `{ result: {...} }`; a miss returns HTTP 404 `{ result: {} }`.\n\nBatch mode: send an `md5s` or `ips` array (max 1,000). MD5s are lowercased and de-duplicated; equivalent IP spellings are de-duplicated while preserving the first input. One malformed MD5 fails the whole request with HTTP 400 before any lookups run. Otherwise the response is always HTTP 200 with `results`, `match_count`, `credits_charged`, and `credits_exhausted`. Every matched result returns `md5`; IP batch results also echo `ip_address`. Inputs with no data are omitted; email fields are always MD5-hashed in batch results. Processing stops once the account's remaining credits are exhausted (`credits_exhausted: true`).\n\n**Billing:** the full configured per-record cost when both the profile and MAID data match; 1 credit when only one of the two sources resolves (partial data); 0 credits for a miss (single-mode 404, or omitted from batch `results`). `last_seen_at` and `location` are supplemental and never affect billing. IP-sourced matches add 1 credit (full 4, partial 2 at the default price). Request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Consumer identity found",
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "type": "object",
                      "required": [
                        "result"
                      ],
                      "description": "Single-lookup response (`md5`, `email`, or `ip_address` input).",
                      "properties": {
                        "result": {
                          "type": "object",
                          "description": "Consumer identity signals for the matched person.",
                          "properties": {
                            "md5": {
                              "type": "string",
                              "nullable": true,
                              "description": "Matched HEM. For IP input, this is the winning resolved HEM.",
                              "example": "5d41402abc4b2a76b9719d911017c592"
                            },
                            "ip_address": {
                              "type": "string",
                              "description": "Input IP correlation key on IP batch results. Omitted for email input.",
                              "example": "203.0.113.42"
                            },
                            "hems": {
                              "type": "array",
                              "description": "Hashed email variants for every known personal email (personal emails only; no work emails on this endpoint).",
                              "items": {
                                "$ref": "#/components/schemas/Hem"
                              }
                            },
                            "maids": {
                              "type": "array",
                              "description": "Mobile advertising IDs linked to the consumer. Always present; empty array when no MAID data was found.",
                              "items": {
                                "$ref": "#/components/schemas/Maid"
                              }
                            },
                            "personal_emails": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              },
                              "description": "Personal email addresses. MD5-hashed unless you send a plaintext `email`; batch results are always MD5-hashed."
                            },
                            "location": {
                              "type": "object",
                              "description": "Coarse consumer location. V1: `country` is always \"US\" and `city`/`state` are null (no consumer-geo source yet).",
                              "properties": {
                                "city": {
                                  "type": "string",
                                  "nullable": true,
                                  "example": null
                                },
                                "state": {
                                  "type": "string",
                                  "nullable": true,
                                  "example": null
                                },
                                "country": {
                                  "type": "string",
                                  "example": "US"
                                }
                              }
                            },
                            "last_seen_at": {
                              "type": "string",
                              "nullable": true,
                              "description": "ISO 8601 timestamp of the consumer's most recent observed online activity. Supplemental; null when no activity is known; never affects billing.",
                              "example": "2026-05-28T14:03:11Z"
                            }
                          }
                        }
                      }
                    },
                    {
                      "type": "object",
                      "required": [
                        "results",
                        "match_count",
                        "credits_charged",
                        "credits_exhausted"
                      ],
                      "description": "Batch response (`md5s` or `ips` input). Always HTTP 200.",
                      "properties": {
                        "results": {
                          "type": "array",
                          "description": "One entry per matched input identifier, in input order. Unmatched inputs are omitted. Email fields are always MD5-hashed.",
                          "items": {
                            "oneOf": [
                              {
                                "type": "object",
                                "required": [
                                  "md5"
                                ],
                                "not": {
                                  "required": [
                                    "ip_address"
                                  ]
                                },
                                "properties": {
                                  "md5": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "Matched HEM. For IP input, this is the winning resolved HEM.",
                                    "example": "5d41402abc4b2a76b9719d911017c592"
                                  },
                                  "hems": {
                                    "type": "array",
                                    "description": "Hashed email variants for every known personal email (personal emails only; no work emails on this endpoint).",
                                    "items": {
                                      "$ref": "#/components/schemas/Hem"
                                    }
                                  },
                                  "maids": {
                                    "type": "array",
                                    "description": "Mobile advertising IDs linked to the consumer. Always present; empty array when no MAID data was found.",
                                    "items": {
                                      "$ref": "#/components/schemas/Maid"
                                    }
                                  },
                                  "personal_emails": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    },
                                    "description": "Personal email addresses. MD5-hashed unless you send a plaintext `email`; batch results are always MD5-hashed."
                                  },
                                  "location": {
                                    "type": "object",
                                    "description": "Coarse consumer location. V1: `country` is always \"US\" and `city`/`state` are null (no consumer-geo source yet).",
                                    "properties": {
                                      "city": {
                                        "type": "string",
                                        "nullable": true,
                                        "example": null
                                      },
                                      "state": {
                                        "type": "string",
                                        "nullable": true,
                                        "example": null
                                      },
                                      "country": {
                                        "type": "string",
                                        "example": "US"
                                      }
                                    }
                                  },
                                  "last_seen_at": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "ISO 8601 timestamp of the consumer's most recent observed online activity. Supplemental; null when no activity is known; never affects billing.",
                                    "example": "2026-05-28T14:03:11Z"
                                  }
                                }
                              },
                              {
                                "type": "object",
                                "required": [
                                  "md5",
                                  "ip_address"
                                ],
                                "properties": {
                                  "md5": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "Matched HEM. For IP input, this is the winning resolved HEM.",
                                    "example": "5d41402abc4b2a76b9719d911017c592"
                                  },
                                  "ip_address": {
                                    "type": "string",
                                    "description": "Input IP correlation key on IP batch results. Omitted for email input.",
                                    "example": "203.0.113.42"
                                  },
                                  "hems": {
                                    "type": "array",
                                    "description": "Hashed email variants for every known personal email (personal emails only; no work emails on this endpoint).",
                                    "items": {
                                      "$ref": "#/components/schemas/Hem"
                                    }
                                  },
                                  "maids": {
                                    "type": "array",
                                    "description": "Mobile advertising IDs linked to the consumer. Always present; empty array when no MAID data was found.",
                                    "items": {
                                      "$ref": "#/components/schemas/Maid"
                                    }
                                  },
                                  "personal_emails": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    },
                                    "description": "Personal email addresses. MD5-hashed unless you send a plaintext `email`; batch results are always MD5-hashed."
                                  },
                                  "location": {
                                    "type": "object",
                                    "description": "Coarse consumer location. V1: `country` is always \"US\" and `city`/`state` are null (no consumer-geo source yet).",
                                    "properties": {
                                      "city": {
                                        "type": "string",
                                        "nullable": true,
                                        "example": null
                                      },
                                      "state": {
                                        "type": "string",
                                        "nullable": true,
                                        "example": null
                                      },
                                      "country": {
                                        "type": "string",
                                        "example": "US"
                                      }
                                    }
                                  },
                                  "last_seen_at": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "ISO 8601 timestamp of the consumer's most recent observed online activity. Supplemental; null when no activity is known; never affects billing.",
                                    "example": "2026-05-28T14:03:11Z"
                                  }
                                }
                              }
                            ]
                          }
                        },
                        "match_count": {
                          "type": "integer",
                          "description": "Number of input identifiers that matched and were billed.",
                          "example": 2
                        },
                        "credits_charged": {
                          "type": "number",
                          "description": "Total credits charged for this batch.",
                          "example": 4
                        },
                        "credits_exhausted": {
                          "type": "boolean",
                          "description": "True when processing stopped early because the account ran out of credits; remaining inputs were not processed.",
                          "example": false
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing md5_or_email",
                        "invalid md5",
                        "missing md5s",
                        "too_many_md5s",
                        "missing ip_address",
                        "invalid ip_address",
                        "missing ips",
                        "too_many_ips",
                        "invalid ip",
                        "invalid ips",
                        "conflicting_identifier_inputs",
                        "unexpected connection error",
                        "unexpected error"
                      ],
                      "description": "`missing md5_or_email`: single mode, neither `md5` nor `email` was provided. `invalid md5`: an MD5 is not a 32-character hex digest (in batch mode `invalid` and `index` identify the offending value). `missing md5s`: batch mode with an empty `md5s` array. `too_many_md5s`: more than 1,000 MD5s (see `max`). `unexpected connection error` / `unexpected error`: temporary error; safe to retry."
                    },
                    "max": {
                      "type": "integer",
                      "description": "Present on `too_many_md5s` or `too_many_ips`: the batch size limit.",
                      "example": 1000
                    },
                    "invalid": {
                      "type": "string",
                      "description": "Present on batch `invalid md5` or `invalid ip`: the offending input value.",
                      "example": "not-an-md5"
                    },
                    "index": {
                      "type": "integer",
                      "description": "Present on batch `invalid md5` or `invalid ip`: zero-based position.",
                      "example": 3
                    },
                    "conflicting": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Identifier fields supplied together when `conflicting_identifier_inputs` is returned."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No data found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "description": "Empty object; neither profile nor MAID data matched the supplied identifier.",
                      "maxProperties": 0
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "description": "Choose exactly one single or batch identifier mode: `md5`/`email`, `md5s`, `ip_address`, or `ips`.",
                "properties": {
                  "md5": {
                    "type": "string",
                    "pattern": "^[a-fA-F0-9]{32}$",
                    "description": "MD5 hash of the lowercased, trimmed email address.",
                    "example": "5d41402abc4b2a76b9719d911017c592"
                  },
                  "email": {
                    "type": "string",
                    "format": "email",
                    "description": "Plaintext email address. When present, email fields in the response are returned in plaintext.",
                    "example": "alice@example.com"
                  },
                  "md5s": {
                    "type": "array",
                    "minItems": 1,
                    "maxItems": 1000,
                    "items": {
                      "type": "string",
                      "pattern": "^[a-fA-F0-9]{32}$"
                    },
                    "description": "Batch lookup: up to 1,000 MD5 hashes. When present, the request is processed in batch mode. Cannot be combined with IP inputs."
                  },
                  "ip_address": {
                    "type": "string",
                    "description": "Single IPv4 or IPv6 address. USA IPs only! Cannot be combined with email inputs.",
                    "example": "203.0.113.42"
                  },
                  "user_agent": {
                    "type": "string",
                    "description": "Optional browser user agent for a single IP lookup."
                  },
                  "ips": {
                    "type": "array",
                    "minItems": 1,
                    "maxItems": 1000,
                    "items": {
                      "type": "string"
                    },
                    "description": "Batch lookup of up to 1,000 IPv4 or IPv6 addresses. USA IPs only! Cannot be combined with email inputs."
                  }
                },
                "oneOf": [
                  {
                    "anyOf": [
                      {
                        "required": [
                          "md5"
                        ]
                      },
                      {
                        "required": [
                          "email"
                        ]
                      }
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5s"
                          ]
                        },
                        {
                          "required": [
                            "ip_address"
                          ]
                        },
                        {
                          "required": [
                            "ips"
                          ]
                        }
                      ]
                    }
                  },
                  {
                    "required": [
                      "md5s"
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5"
                          ]
                        },
                        {
                          "required": [
                            "email"
                          ]
                        },
                        {
                          "required": [
                            "ip_address"
                          ]
                        },
                        {
                          "required": [
                            "ips"
                          ]
                        }
                      ]
                    }
                  },
                  {
                    "required": [
                      "ip_address"
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5"
                          ]
                        },
                        {
                          "required": [
                            "email"
                          ]
                        },
                        {
                          "required": [
                            "md5s"
                          ]
                        },
                        {
                          "required": [
                            "ips"
                          ]
                        }
                      ]
                    }
                  },
                  {
                    "required": [
                      "ips"
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5"
                          ]
                        },
                        {
                          "required": [
                            "email"
                          ]
                        },
                        {
                          "required": [
                            "md5s"
                          ]
                        },
                        {
                          "required": [
                            "ip_address"
                          ]
                        }
                      ]
                    }
                  }
                ]
              },
              "examples": {
                "single": {
                  "summary": "Single lookup",
                  "value": {
                    "md5": "5d41402abc4b2a76b9719d911017c592"
                  }
                },
                "batch": {
                  "summary": "Batch lookup (up to 1,000)",
                  "value": {
                    "md5s": [
                      "5d41402abc4b2a76b9719d911017c592",
                      "098f6bcd4621d373cade4e832627b4f6"
                    ]
                  }
                },
                "ip": {
                  "summary": "Single IP lookup",
                  "value": {
                    "ip_address": "203.0.113.42",
                    "user_agent": "Mozilla/5.0"
                  }
                },
                "ip_batch": {
                  "summary": "Batch IP lookup (up to 1,000)",
                  "value": {
                    "ips": [
                      "203.0.113.42",
                      "2001:db8::42"
                    ]
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/identity/person": {
      "post": {
        "summary": "Universal Identity",
        "tags": [
          "Identity"
        ],
        "operationId": "identityPerson",
        "description": "Every identity signal on a person in one call: work and personal emails, device IDs, and hashed emails. Accepts hashed or plaintext email and IP address inputs.\n\nSingle mode: provide a pre-computed `md5`, a plaintext `email`, or an IPv4 or IPv6 `ip_address` with an optional `user_agent`. USA IPs only! Choose exactly one identifier family. The response carries every identity signal on the person: `hems` (MD5 + SHA-256 for each known personal and business email), `maids` (mobile advertising IDs), `personal_emails`, and `business_emails`. Email fields are MD5-hashed unless you send a plaintext `email`. A match returns HTTP 200 `{ result: {...} }`; a miss returns HTTP 404 `{ result: {} }`.\n\nBatch mode: send an `md5s` or `ips` array (max 1,000). MD5s are lowercased and de-duplicated; equivalent IP spellings are de-duplicated while preserving the first input. One malformed MD5 fails the whole request with HTTP 400 before any lookups run. Otherwise the response is always HTTP 200 with `results`, `match_count`, `credits_charged`, and `credits_exhausted`. Every matched result returns `md5`; IP batch results also echo `ip_address`. Inputs with no data are omitted; email fields are always MD5-hashed in batch results. Processing stops once the account's remaining credits are exhausted (`credits_exhausted: true`).\n\n**Billing:** the full configured per-record cost when both the profile and MAID data match; 1 credit when only one of the two sources resolves (partial data); 0 credits for a miss (single-mode 404, or omitted from batch `results`). IP-sourced matches add 1 credit (full 4, partial 2 at the default price). Request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Identity data found",
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "type": "object",
                      "required": [
                        "result"
                      ],
                      "description": "Single-lookup response (`md5`, `email`, or `ip_address` input).",
                      "properties": {
                        "result": {
                          "type": "object",
                          "description": "Every identity signal on the matched person.",
                          "properties": {
                            "md5": {
                              "type": "string",
                              "nullable": true,
                              "description": "Matched HEM. For IP input, this is the winning resolved HEM.",
                              "example": "5d41402abc4b2a76b9719d911017c592"
                            },
                            "ip_address": {
                              "type": "string",
                              "description": "Input IP correlation key on IP batch results. Omitted for email input.",
                              "example": "203.0.113.42"
                            },
                            "hems": {
                              "type": "array",
                              "description": "Hashed email variants for every known email on the person (personal and business). Always hashes, by definition.",
                              "items": {
                                "$ref": "#/components/schemas/Hem"
                              }
                            },
                            "maids": {
                              "type": "array",
                              "description": "Mobile advertising IDs linked to the person. Always present; empty array when no MAID data was found.",
                              "items": {
                                "$ref": "#/components/schemas/Maid"
                              }
                            },
                            "personal_emails": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              },
                              "description": "Personal email addresses. MD5-hashed unless you send a plaintext `email`; batch results are always MD5-hashed."
                            },
                            "business_emails": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              },
                              "description": "Business email addresses (falls back to the single confirmed work email when no business email list is known). MD5-hashed unless you send a plaintext `email`; batch results are always MD5-hashed."
                            }
                          }
                        }
                      }
                    },
                    {
                      "type": "object",
                      "required": [
                        "results",
                        "match_count",
                        "credits_charged",
                        "credits_exhausted"
                      ],
                      "description": "Batch response (`md5s` or `ips` input). Always HTTP 200.",
                      "properties": {
                        "results": {
                          "type": "array",
                          "description": "One entry per matched input identifier, in input order. Unmatched inputs are omitted. Email fields are always MD5-hashed.",
                          "items": {
                            "oneOf": [
                              {
                                "type": "object",
                                "required": [
                                  "md5"
                                ],
                                "not": {
                                  "required": [
                                    "ip_address"
                                  ]
                                },
                                "properties": {
                                  "md5": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "Matched HEM. For IP input, this is the winning resolved HEM.",
                                    "example": "5d41402abc4b2a76b9719d911017c592"
                                  },
                                  "hems": {
                                    "type": "array",
                                    "description": "Hashed email variants for every known email on the person (personal and business). Always hashes, by definition.",
                                    "items": {
                                      "$ref": "#/components/schemas/Hem"
                                    }
                                  },
                                  "maids": {
                                    "type": "array",
                                    "description": "Mobile advertising IDs linked to the person. Always present; empty array when no MAID data was found.",
                                    "items": {
                                      "$ref": "#/components/schemas/Maid"
                                    }
                                  },
                                  "personal_emails": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    },
                                    "description": "Personal email addresses. MD5-hashed unless you send a plaintext `email`; batch results are always MD5-hashed."
                                  },
                                  "business_emails": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    },
                                    "description": "Business email addresses (falls back to the single confirmed work email when no business email list is known). MD5-hashed unless you send a plaintext `email`; batch results are always MD5-hashed."
                                  }
                                }
                              },
                              {
                                "type": "object",
                                "required": [
                                  "md5",
                                  "ip_address"
                                ],
                                "properties": {
                                  "md5": {
                                    "type": "string",
                                    "nullable": true,
                                    "description": "Matched HEM. For IP input, this is the winning resolved HEM.",
                                    "example": "5d41402abc4b2a76b9719d911017c592"
                                  },
                                  "ip_address": {
                                    "type": "string",
                                    "description": "Input IP correlation key on IP batch results. Omitted for email input.",
                                    "example": "203.0.113.42"
                                  },
                                  "hems": {
                                    "type": "array",
                                    "description": "Hashed email variants for every known email on the person (personal and business). Always hashes, by definition.",
                                    "items": {
                                      "$ref": "#/components/schemas/Hem"
                                    }
                                  },
                                  "maids": {
                                    "type": "array",
                                    "description": "Mobile advertising IDs linked to the person. Always present; empty array when no MAID data was found.",
                                    "items": {
                                      "$ref": "#/components/schemas/Maid"
                                    }
                                  },
                                  "personal_emails": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    },
                                    "description": "Personal email addresses. MD5-hashed unless you send a plaintext `email`; batch results are always MD5-hashed."
                                  },
                                  "business_emails": {
                                    "type": "array",
                                    "items": {
                                      "type": "string"
                                    },
                                    "description": "Business email addresses (falls back to the single confirmed work email when no business email list is known). MD5-hashed unless you send a plaintext `email`; batch results are always MD5-hashed."
                                  }
                                }
                              }
                            ]
                          }
                        },
                        "match_count": {
                          "type": "integer",
                          "description": "Number of input identifiers that matched and were billed.",
                          "example": 2
                        },
                        "credits_charged": {
                          "type": "number",
                          "description": "Total credits charged for this batch.",
                          "example": 4
                        },
                        "credits_exhausted": {
                          "type": "boolean",
                          "description": "True when processing stopped early because the account ran out of credits; remaining inputs were not processed.",
                          "example": false
                        }
                      }
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing md5_or_email",
                        "invalid md5",
                        "missing md5s",
                        "too_many_md5s",
                        "missing ip_address",
                        "invalid ip_address",
                        "missing ips",
                        "too_many_ips",
                        "invalid ip",
                        "invalid ips",
                        "conflicting_identifier_inputs",
                        "unexpected connection error",
                        "unexpected error"
                      ],
                      "description": "`missing md5_or_email`: single mode, neither `md5` nor `email` was provided. `invalid md5`: an MD5 is not a 32-character hex digest (in batch mode `invalid` and `index` identify the offending value). `missing md5s`: batch mode with an empty `md5s` array. `too_many_md5s`: more than 1,000 MD5s (see `max`). `unexpected connection error` / `unexpected error`: temporary error; safe to retry."
                    },
                    "max": {
                      "type": "integer",
                      "description": "Present on `too_many_md5s` or `too_many_ips`: the batch size limit.",
                      "example": 1000
                    },
                    "invalid": {
                      "type": "string",
                      "description": "Present on batch `invalid md5` or `invalid ip`: the offending input value.",
                      "example": "not-an-md5"
                    },
                    "index": {
                      "type": "integer",
                      "description": "Present on batch `invalid md5` or `invalid ip`: zero-based position.",
                      "example": 3
                    },
                    "conflicting": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "Identifier fields supplied together when `conflicting_identifier_inputs` is returned."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No data found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "description": "Empty object; neither profile nor MAID data matched the supplied identifier.",
                      "maxProperties": 0
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "description": "Choose exactly one single or batch identifier mode: `md5`/`email`, `md5s`, `ip_address`, or `ips`.",
                "properties": {
                  "md5": {
                    "type": "string",
                    "pattern": "^[a-fA-F0-9]{32}$",
                    "description": "MD5 hash of the lowercased, trimmed email address.",
                    "example": "5d41402abc4b2a76b9719d911017c592"
                  },
                  "email": {
                    "type": "string",
                    "format": "email",
                    "description": "Plaintext email address. When present, email fields in the response are returned in plaintext.",
                    "example": "alice@example.com"
                  },
                  "md5s": {
                    "type": "array",
                    "minItems": 1,
                    "maxItems": 1000,
                    "items": {
                      "type": "string",
                      "pattern": "^[a-fA-F0-9]{32}$"
                    },
                    "description": "Batch lookup: up to 1,000 MD5 hashes. When present, the request is processed in batch mode. Cannot be combined with IP inputs."
                  },
                  "ip_address": {
                    "type": "string",
                    "description": "Single IPv4 or IPv6 address. USA IPs only! Cannot be combined with email inputs.",
                    "example": "203.0.113.42"
                  },
                  "user_agent": {
                    "type": "string",
                    "description": "Optional browser user agent for a single IP lookup."
                  },
                  "ips": {
                    "type": "array",
                    "minItems": 1,
                    "maxItems": 1000,
                    "items": {
                      "type": "string"
                    },
                    "description": "Batch lookup of up to 1,000 IPv4 or IPv6 addresses. USA IPs only! Cannot be combined with email inputs."
                  }
                },
                "oneOf": [
                  {
                    "anyOf": [
                      {
                        "required": [
                          "md5"
                        ]
                      },
                      {
                        "required": [
                          "email"
                        ]
                      }
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5s"
                          ]
                        },
                        {
                          "required": [
                            "ip_address"
                          ]
                        },
                        {
                          "required": [
                            "ips"
                          ]
                        }
                      ]
                    }
                  },
                  {
                    "required": [
                      "md5s"
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5"
                          ]
                        },
                        {
                          "required": [
                            "email"
                          ]
                        },
                        {
                          "required": [
                            "ip_address"
                          ]
                        },
                        {
                          "required": [
                            "ips"
                          ]
                        }
                      ]
                    }
                  },
                  {
                    "required": [
                      "ip_address"
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5"
                          ]
                        },
                        {
                          "required": [
                            "email"
                          ]
                        },
                        {
                          "required": [
                            "md5s"
                          ]
                        },
                        {
                          "required": [
                            "ips"
                          ]
                        }
                      ]
                    }
                  },
                  {
                    "required": [
                      "ips"
                    ],
                    "not": {
                      "anyOf": [
                        {
                          "required": [
                            "md5"
                          ]
                        },
                        {
                          "required": [
                            "email"
                          ]
                        },
                        {
                          "required": [
                            "md5s"
                          ]
                        },
                        {
                          "required": [
                            "ip_address"
                          ]
                        }
                      ]
                    }
                  }
                ]
              },
              "examples": {
                "single": {
                  "summary": "Single lookup",
                  "value": {
                    "md5": "5d41402abc4b2a76b9719d911017c592"
                  }
                },
                "batch": {
                  "summary": "Batch lookup (up to 1,000)",
                  "value": {
                    "md5s": [
                      "5d41402abc4b2a76b9719d911017c592",
                      "098f6bcd4621d373cade4e832627b4f6"
                    ]
                  }
                },
                "ip": {
                  "summary": "Single IP lookup",
                  "value": {
                    "ip_address": "203.0.113.42",
                    "user_agent": "Mozilla/5.0"
                  }
                },
                "ip_batch": {
                  "summary": "Batch IP lookup (up to 1,000)",
                  "value": {
                    "ips": [
                      "203.0.113.42",
                      "2001:db8::42"
                    ]
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/ip_to_business_profile": {
      "post": {
        "summary": "IP → Business Profile",
        "tags": [
          "IP"
        ],
        "operationId": "ipToBusinessProfile",
        "description": "Resolve an IP (and browser details) straight to one work profile: name, title, company, and seniority. You're only charged when a profile is returned.\n\nProvide an IPv4 or IPv6 `ip_address`, optionally with the visitor's `user_agent`. The first available work profile is returned using our proprietary identity resolution technology. Email fields are MD5-hashed by default.\n\n**Billing:** 3 credits per successful match (HTTP 200). Misses (404) and request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Profile found (3 credits charged)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "description": "Work profile for the matched contact. Only fields known for the contact are present.",
                      "additionalProperties": true,
                      "properties": {
                        "first_name": {
                          "type": "string",
                          "example": "Alice"
                        },
                        "last_name": {
                          "type": "string",
                          "example": "Smith"
                        },
                        "title": {
                          "type": "string",
                          "example": "VP of Marketing"
                        },
                        "seniority": {
                          "type": "string",
                          "example": "vp"
                        },
                        "functional_area": {
                          "type": "string",
                          "example": "Marketing"
                        },
                        "current_company": {
                          "type": "string",
                          "description": "Company name (title-cased).",
                          "example": "Acme"
                        },
                        "current_industry": {
                          "type": "string",
                          "example": "Computer Software"
                        },
                        "country": {
                          "type": "string",
                          "example": "United States"
                        },
                        "linkedin_slug": {
                          "type": "string",
                          "description": "LinkedIn public profile slug.",
                          "example": "alice-123"
                        },
                        "company_employee_range": {
                          "type": "string",
                          "nullable": true,
                          "example": "51-200"
                        },
                        "company_revenue_range": {
                          "type": "string",
                          "nullable": true,
                          "example": "$10M-$50M"
                        },
                        "work_email_confirmed": {
                          "type": "string",
                          "description": "Confirmed work email, returned as an MD5 hash.",
                          "example": "5f60af2947b32bde4bc824a30ad3f919"
                        },
                        "personal_emails": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Personal email addresses, returned as MD5 hashes."
                        },
                        "mobile_phone": {
                          "type": "string",
                          "nullable": true,
                          "description": "Mobile phone number. Present only when `include_mobile_phone` was requested.",
                          "example": "+14155550123"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Missing, invalid, or temporarily unavailable",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing ip_address",
                        "invalid ip_address",
                        "unexpected connection error",
                        "unexpected error"
                      ],
                      "description": "`missing ip_address`: no `ip_address` was provided. `invalid ip_address`: the value is not a valid IPv4 or IPv6 address. `unexpected connection error` / `unexpected error`: temporary error; safe to retry."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No profile found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "description": "Empty object; no work profile matched the supplied IP.",
                      "maxProperties": 0
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "ip_address"
                ],
                "properties": {
                  "ip_address": {
                    "type": "string",
                    "description": "IPv4 or IPv6 address of the visitor.",
                    "example": "203.0.113.42"
                  },
                  "user_agent": {
                    "type": "string",
                    "description": "Visitor's browser User-Agent. Optional; improves match confidence when provided.",
                    "example": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36"
                  },
                  "include_mobile_phone": {
                    "type": "boolean",
                    "default": false,
                    "description": "Also look up the contact's mobile phone number and include it as `mobile_phone` in the result."
                  },
                  "require_email": {
                    "type": "boolean",
                    "default": false,
                    "description": "Only return and bill for profiles that contain an email address."
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/ip_to_company": {
      "post": {
        "summary": "IP → Company",
        "tags": [
          "IP"
        ],
        "operationId": "ipToCompany",
        "description": "Identify the company or organization behind an IP address.\n\nProvide an IPv4 or IPv6 `ip_address`. Returns the candidate company domains with their match percentages. When no traffic-share breakdown is available, one domain is returned with `percentage` `\"1.0\"`.\n\n**Billing:** 1 credit per successful lookup (HTTP 200), regardless of how many companies are returned. Misses (404) and request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Company found (1 credit charged)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "type": "array",
                      "description": "Candidate companies resolved for the supplied IP.",
                      "items": {
                        "type": "object",
                        "properties": {
                          "domain": {
                            "type": "string",
                            "nullable": true,
                            "description": "Company website domain. Can be `null` when no domain is known.",
                            "example": "acme.com"
                          },
                          "percentage": {
                            "oneOf": [
                              {
                                "type": "number"
                              },
                              {
                                "type": "string"
                              }
                            ],
                            "description": "Share of traffic from this IP attributed to the company. A number (e.g. `0.9`) when a traffic-share breakdown is available; the string `\"1.0\"` when it is not.",
                            "example": 0.9
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Missing or invalid IP",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing ip_address",
                        "invalid ip_address",
                        "unexpected error"
                      ],
                      "description": "`missing ip_address`: no `ip_address` was provided. `invalid ip_address`: the value is not a valid IPv4 or IPv6 address. `unexpected error`: temporary error; safe to retry."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No company found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "nullable": true,
                      "description": "Always `null`; no company resolved for the supplied IP."
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "ip_address"
                ],
                "properties": {
                  "ip_address": {
                    "type": "string",
                    "description": "IPv4 or IPv6 address to resolve.",
                    "example": "203.0.113.42"
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/ip_to_hem": {
      "post": {
        "summary": "IP → Hashed Email",
        "tags": [
          "IP"
        ],
        "operationId": "ipToHem",
        "description": "Resolve an IP (and browser details) into the visitor's hashed email.\n\nProvide an IPv4 or IPv6 `ip_address` (optionally with the visitor's `user_agent`). We use our proprietary identity resolution technology to derive and return up to 3 matches ordered by descending confidence score; set `include_sha256` to also return each match's SHA-256 hashed email.\n\n**Billing:** 1 credit per successful lookup (HTTP 200), regardless of how many matches are returned. Misses (404) and request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Matches found (1 credit charged)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "type": "array",
                      "description": "Up to 3 hashed-email matches, ordered by descending score.",
                      "items": {
                        "type": "object",
                        "required": [
                          "md5",
                          "score"
                        ],
                        "properties": {
                          "md5": {
                            "type": "string",
                            "pattern": "^[a-fA-F0-9]{32}$",
                            "description": "MD5 hash of the visitor's email address.",
                            "example": "5d41402abc4b2a76b9719d911017c592"
                          },
                          "sha256": {
                            "type": "string",
                            "pattern": "^[a-fA-F0-9]{64}$",
                            "description": "SHA-256 hash of the visitor's email address. Present only when `include_sha256` was requested.",
                            "example": "2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824"
                          },
                          "score": {
                            "type": "number",
                            "description": "Match confidence score; higher is more confident.",
                            "example": 0.9
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Missing or invalid IP",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing ip_address",
                        "invalid ip_address",
                        "unexpected error"
                      ],
                      "description": "`missing ip_address`: no `ip_address` was provided. `invalid ip_address`: the value is not a valid IPv4 or IPv6 address. `unexpected error`: temporary error; safe to retry."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No results (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "type": "array",
                      "description": "Always empty; no hashed emails matched the supplied IP.",
                      "items": {},
                      "maxItems": 0
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "ip_address"
                ],
                "properties": {
                  "ip_address": {
                    "type": "string",
                    "description": "IPv4 or IPv6 address of the visitor.",
                    "example": "203.0.113.42"
                  },
                  "user_agent": {
                    "type": "string",
                    "description": "Visitor's browser User-Agent. Optional; improves match confidence when provided.",
                    "example": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36"
                  },
                  "include_sha256": {
                    "type": "boolean",
                    "default": false,
                    "description": "Also include each match's SHA-256 hashed email as `sha256`."
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/linkedin_to_business_email": {
      "post": {
        "summary": "LinkedIn → Business Email",
        "tags": [
          "LinkedIn"
        ],
        "operationId": "linkedinToBusinessEmail",
        "description": "Get the verified work email address for a LinkedIn profile.\n\nSend either `linkedin_slug` or `linkedin_url`. `linkedin_slug` accepts a bare slug (e.g. `alice-123`); `linkedin_url` accepts a full profile URL (e.g. `https://www.linkedin.com/in/alice-123`). Only a confirmed work email is returned, and only one. On a miss the response still includes the `result` envelope with `email` set to `null`.\n\n**Billing:** 4 credits per successful match (HTTP 200). Misses (404) and request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Work email found (4 credits charged)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "required": [
                        "email"
                      ],
                      "properties": {
                        "email": {
                          "type": "string",
                          "description": "Confirmed work email address for the profile.",
                          "example": "alice@example.com"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing linkedin_slug or linkedin_url",
                        "invalid linkedin_slug",
                        "unexpected connection error",
                        "unexpected error"
                      ],
                      "description": "`missing linkedin_slug or linkedin_url`: neither input was provided. `invalid linkedin_slug`: the input is not a valid LinkedIn profile slug or URL. `unexpected connection error` / `unexpected error`: temporary error; safe to retry."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No work email found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "required": [
                        "email"
                      ],
                      "properties": {
                        "email": {
                          "type": "string",
                          "nullable": true,
                          "description": "Always `null`; no confirmed work email matched the supplied profile."
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "linkedin_slug": {
                    "type": "string",
                    "description": "LinkedIn public profile slug. Provide this or `linkedin_url`.",
                    "example": "alice-123"
                  },
                  "linkedin_url": {
                    "type": "string",
                    "description": "Full LinkedIn profile URL. Used when `linkedin_slug` is omitted.",
                    "example": "https://www.linkedin.com/in/alice-123"
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/linkedin_to_business_profile": {
      "post": {
        "summary": "LinkedIn → Business Profile",
        "tags": [
          "LinkedIn"
        ],
        "operationId": "linkedinToBusinessProfile",
        "description": "Enrich a profile into a full work profile: name, title, company, size.\n\nProvide either `linkedin_slug` or `linkedin_url`; at least one is required, and either field accepts a bare slug (e.g. `alice-123`) or a full profile URL (e.g. `https://www.linkedin.com/in/alice-123`). Set `include_mobile_phone` to also look up the contact's mobile phone number.\n\n**Billing:** 4 credits per successful match (HTTP 200). Misses (404) and request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Profile found (4 credits charged)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "description": "Work profile for the matched contact. Only fields known for the contact are present.",
                      "additionalProperties": true,
                      "properties": {
                        "first_name": {
                          "type": "string",
                          "example": "Alice"
                        },
                        "last_name": {
                          "type": "string",
                          "example": "Smith"
                        },
                        "title": {
                          "type": "string",
                          "example": "VP of Marketing"
                        },
                        "current_company": {
                          "type": "string",
                          "description": "Company name.",
                          "example": "Acme"
                        },
                        "linkedin_slug": {
                          "type": "string",
                          "description": "LinkedIn public profile slug.",
                          "example": "alice-123"
                        },
                        "business_email": {
                          "type": "string",
                          "nullable": true,
                          "description": "Confirmed work email address for the contact. `null` when none is known.",
                          "example": "alice@acme.com"
                        },
                        "business_emails": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Additional work email addresses associated with the contact. These carry lower confidence than `business_email` and are not confirmed; treat them as candidates. Absent when none are known.",
                          "example": [
                            "a.smith@acme.com",
                            "asmith@acme.com"
                          ]
                        },
                        "company_employee_range": {
                          "type": "string",
                          "nullable": true,
                          "description": "Company headcount range. `null` when unknown.",
                          "example": "51-200"
                        },
                        "company_revenue_range": {
                          "type": "string",
                          "nullable": true,
                          "description": "Company revenue range. `null` when unknown.",
                          "example": "$10M-$50M"
                        },
                        "mobile_phone": {
                          "type": "string",
                          "nullable": true,
                          "description": "Mobile phone number. Present only when `include_mobile_phone` was requested; `null` when no phone is known.",
                          "example": "+14155550123"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing linkedin_slug or linkedin_url",
                        "invalid linkedin_slug",
                        "unexpected connection error",
                        "unexpected error"
                      ],
                      "description": "`missing linkedin_slug or linkedin_url`: neither input field was provided. `invalid linkedin_slug`: the input is not a valid LinkedIn profile slug or URL. `unexpected connection error` / `unexpected error`: temporary error; safe to retry."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No profile found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "description": "Empty object; no profile matched the supplied slug.",
                      "maxProperties": 0
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "description": "At least one of `linkedin_slug` or `linkedin_url` is required.",
                "properties": {
                  "linkedin_slug": {
                    "type": "string",
                    "description": "LinkedIn public profile slug. Also accepts a full profile URL.",
                    "example": "alice-123"
                  },
                  "linkedin_url": {
                    "type": "string",
                    "description": "Full LinkedIn profile URL. Used only when `linkedin_slug` is absent.",
                    "example": "https://www.linkedin.com/in/alice-123"
                  },
                  "include_mobile_phone": {
                    "type": "boolean",
                    "default": false,
                    "description": "Also look up the contact's mobile phone number and include it as `mobile_phone` in the result."
                  },
                  "require_email": {
                    "type": "boolean",
                    "default": false,
                    "description": "Only return and bill for profiles that contain an email address."
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/linkedin_to_hashed_emails": {
      "post": {
        "summary": "LinkedIn → Hashed Emails",
        "tags": [
          "LinkedIn"
        ],
        "operationId": "linkedinToHashedEmails",
        "description": "Get hashed email variants for a profile, ready for ad-platform matching.\n\n`linkedin_slug` accepts either a bare slug (e.g. `alice-123`) or a full profile URL (e.g. `https://www.linkedin.com/in/alice-123`). On a match, the response contains the hashed email variants known for the profile (e.g. `md5_1`, `sha256_1`, `md5_2`, …); ready for ad-platform audience matching.\n\n**Billing:** 1 credit per successful match (HTTP 200). Misses (404) and request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Hashed emails found (1 credit charged)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "type": "object",
                      "description": "Hashed email variants for the matched profile. Keys are numbered hash fields (`md5_1`, `sha256_1`, `md5_2`, …) plus the echoed `linkedin_slug`; only hashes known for the profile are present.",
                      "additionalProperties": {
                        "type": "string"
                      },
                      "properties": {
                        "linkedin_slug": {
                          "type": "string",
                          "description": "The matched LinkedIn profile slug.",
                          "example": "alice-123"
                        },
                        "md5_1": {
                          "type": "string",
                          "description": "MD5 hash of an email address linked to the profile.",
                          "example": "5d41402abc4b2a76b9719d911017c592"
                        },
                        "sha256_1": {
                          "type": "string",
                          "description": "SHA-256 hash of an email address linked to the profile.",
                          "example": "2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing linkedin_slug",
                        "invalid linkedin_slug",
                        "unexpected connection error",
                        "unexpected error"
                      ],
                      "description": "`missing linkedin_slug`: no slug was provided. `invalid linkedin_slug`: the input is not a valid LinkedIn profile slug or URL. `unexpected connection error` / `unexpected error`: temporary error; safe to retry."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No hashed emails found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "results"
                  ],
                  "properties": {
                    "results": {
                      "type": "object",
                      "nullable": true,
                      "description": "Always `null`; no hashed emails matched the supplied slug."
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "linkedin_slug"
                ],
                "properties": {
                  "linkedin_slug": {
                    "type": "string",
                    "description": "LinkedIn public profile slug. Also accepts a full profile URL.",
                    "example": "alice-123"
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    },
    "/api/v1/linkedin_to_mobile_phone": {
      "post": {
        "summary": "LinkedIn → Mobile Phone",
        "tags": [
          "LinkedIn"
        ],
        "operationId": "linkedinToMobilePhone",
        "description": "Find the mobile phone number associated with a profile.\n\n`linkedin_slug` accepts either a bare slug (e.g. `alice-123`) or a full profile URL (e.g. `https://www.linkedin.com/in/alice-123`). On a miss the response still includes the `result` envelope with `mobile_phone` set to `null`.\n\n**Billing:** 3 credits per successful match (HTTP 200). Misses (404) and request errors (4xx) are not billed.",
        "security": [
          {
            "api_key": []
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Phone found (3 credits charged)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "required": [
                        "mobile_phone"
                      ],
                      "properties": {
                        "mobile_phone": {
                          "type": "string",
                          "description": "Mobile phone number associated with the profile.",
                          "example": "+14155550123"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid request",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "enum": [
                        "missing linkedin_slug",
                        "invalid linkedin_slug",
                        "unexpected connection error",
                        "unexpected error"
                      ],
                      "description": "`missing linkedin_slug`: no slug was provided. `invalid linkedin_slug`: the input is not a valid LinkedIn profile slug or URL. `unexpected connection error` / `unexpected error`: temporary error; safe to retry."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing, malformed, or unknown API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AuthError"
                }
              }
            }
          },
          "402": {
            "description": "Insufficient credits",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InsufficientCreditsError"
                }
              }
            }
          },
          "403": {
            "description": "Service not enabled for this API key",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ServiceDisabledError"
                }
              }
            }
          },
          "404": {
            "description": "No phone found (not billed)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "result"
                  ],
                  "properties": {
                    "result": {
                      "type": "object",
                      "required": [
                        "mobile_phone"
                      ],
                      "properties": {
                        "mobile_phone": {
                          "type": "string",
                          "nullable": true,
                          "description": "Always `null`; no mobile phone matched the supplied slug."
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "linkedin_slug"
                ],
                "properties": {
                  "linkedin_slug": {
                    "type": "string",
                    "description": "LinkedIn public profile slug. Also accepts a full profile URL.",
                    "example": "alice-123"
                  }
                }
              }
            }
          },
          "required": true
        }
      }
    }
  },
  "tags": [
    {
      "name": "Identity",
      "description": "Core Identity. Resolve a hashed email (or batch) into a shaped person profile."
    }
  ]
}
