# Dataset Verification

Dataset verification is about more than validity checks — it's about understanding your contacts in context. ApexVerify's targeting parameters let you tell the system *who* you're targeting and *why*, enabling more accurate scoring and better-quality results.

***

## When to use dataset verification

<CardGroup cols={2}>
  <Card title="CRM hygiene" icon="fa-regular fa-database">
    Periodically verify your CRM contacts to remove invalid records before they cause deliverability issues, wasted ad spend, or inflated pipeline numbers.
  </Card>

  <Card title="Marketing list cleaning" icon="fa-regular fa-filter">
    Clean subscriber lists before sending campaigns. Reduce bounce rates, protect your sender reputation, and ensure your data complies with email marketing regulations.
  </Card>

  <Card title="Lead generation validation" icon="fa-regular fa-magnet">
    Verify incoming leads from forms, ad platforms, or data providers before they enter your CRM. Stop paying to enrich or engage bad data.
  </Card>

  <Card title="Data provider enrichment" icon="fa-regular fa-chart-network">
    Validate data purchased from third-party providers. Understand exactly what percentage is deliverable before committing to a full integration.
  </Card>
</CardGroup>

***

## Dataset preparation checklist

<Steps>
  <Step title="Choose the correct verification type">
    Decide whether you're verifying **emails** or **phone numbers**. Each batch handles one type. If you have both, create two separate batches.
  </Step>

  <Step title="Normalize your data">
    Before exporting:

    * Trim whitespace from all values
    * Lowercase all email addresses
    * Format phone numbers in E.164 (`+[country code][number]`)
    * Remove empty rows
  </Step>

  <Step title="Export as a TXT file">
    Export your cleaned data as a plain `.txt` file — one entry per line, UTF-8 encoded. Most CRMs and spreadsheet tools can export a single column directly.
  </Step>

  <Step title="Set targeting parameters">
    Targeting parameters aren't required, but they give the verification engine important context. The more accurately you describe your audience, the better the scoring signal.
  </Step>
</Steps>

***

## Targeting parameters explained

Targeting parameters are set via `PUT /v1/batch/{uuid}` after upload. Only `type` and `target_country` are required.

<AccordionGroup>
  <Accordion title="type — Verification type (required)">
    | Value   | Description            |
    | :------ | :--------------------- |
    | `email` | Verify email addresses |
    | `phone` | Verify phone numbers   |
  </Accordion>

  <Accordion title="target_country — Target country (required)">
    An ISO 3166-1 alpha-2 country code representing the country your audience is based in. Examples: `US`, `GB`, `SG`, `AU`, `DE`, `FR`.

    This helps the engine apply country-specific routing rules, carrier lookups, and domain heuristics.
  </Accordion>

  <Accordion title="target_audience — Audience role (optional)">
    Describe the professional role of your target audience. Pass the corresponding integer value:

    | Code | Audience                              |
    | :--- | :------------------------------------ |
    | 1    | Agency / Consultants                  |
    | 2    | Creators & Influencers                |
    | 3    | Customer Support & Success            |
    | 4    | Developers & Technical Leads          |
    | 5    | E-commerce & Retail Managers          |
    | 6    | Enterprise Decision-Makers            |
    | 7    | Finance & Operations Professionals    |
    | 8    | Founders & C-Level Executives         |
    | 9    | Freelancers & Solopreneurs            |
    | 10   | Government & Public Sector Employees  |
    | 11   | HR & Talent Acquisition               |
    | 12   | Healthcare Professionals              |
    | 13   | Hobbyists & Enthusiasts               |
    | 14   | Investors & VCs                       |
    | 15   | Job Seekers                           |
    | 16   | Legal Professionals                   |
    | 17   | Marketing & Sales Professionals       |
    | 18   | Non-Profit Leaders & Staff            |
    | 19   | Parents & Families                    |
    | 20   | Product & Project Managers            |
    | 21   | Real Estate Professionals             |
    | 22   | Small-to-Medium Business (SMB) Owners |
    | 23   | Students & Educators                  |
  </Accordion>

  <Accordion title="target_market_industry — Industry vertical (optional)">
    The industry of your target market. Pass the corresponding integer:

    | Code | Industry                                         |
    | :--- | :----------------------------------------------- |
    | 1    | Accommodation                                    |
    | 5    | Agriculture, Forestry, Fishing and Hunting       |
    | 15   | Chemical Manufacturing                           |
    | 17   | Computer and Electronic Product Manufacturing    |
    | 18   | Construction                                     |
    | 23   | Data Processing, Hosting, and Related Services   |
    | 25   | Educational Services                             |
    | 29   | Finance and Insurance                            |
    | 42   | Health Care and Social Assistance                |
    | 46   | Information                                      |
    | 54   | Manufacturing                                    |
    | 83   | Professional, Scientific, and Technical Services |
    | 86   | Real Estate                                      |
    | 91   | Retail Trade                                     |
    | 101  | Telecommunications                               |
    | 109  | Utilities                                        |

    The full list of 115 industry codes is available in the [API Reference](/api-reference/authentication).
  </Accordion>

  <Accordion title="target_objective — Campaign objective (optional)">
    The goal of the outreach campaign for which this data will be used:

    | Code | Objective                             |
    | :--- | :------------------------------------ |
    | 1    | App Installs / Downloads              |
    | 2    | Audience Building (Email/Community)   |
    | 3    | Brand Awareness & Recall              |
    | 4    | Customer Acquisition / Sales          |
    | 5    | Free Trial or Freemium Signups        |
    | 6    | Lead Generation (Top/Mid-Funnel)      |
    | 7    | Loyalty & Referral Program Growth     |
    | 8    | Market & Customer Research            |
    | 9    | New Market Entry                      |
    | 10   | Partner & Affiliate Recruitment       |
    | 11   | Product Engagement & Feature Adoption |
    | 12   | Sales-Ready Leads (Bottom-Funnel)     |
    | 13   | Upsell / Cross-sell Revenue           |
    | 14   | User Retention & Churn Reduction      |
    | 15   | Waitlist / Pre-order Signups          |
    | 16   | Website / App Traffic Acquisition     |
  </Accordion>

  <Accordion title="Cache settings (optional)">
    Control how aggressively the system reuses prior verification results.

    | Parameter                   | Default   | Description                                        |
    | :-------------------------- | :-------- | :------------------------------------------------- |
    | `use_account_cache`         | `true`    | Reuse your own previous results                    |
    | `max_account_cache_backoff` | `30` days | How far back to look in your account cache (1–180) |
    | `use_global_cache`          | `true`    | Reuse anonymized results from other accounts       |
    | `max_global_cache_backoff`  | `30` days | How far back to look in the global cache (1–180)   |

    Both caches deliver a **50% credit refund** for cache-hit records. Account cache is checked first.
  </Accordion>
</AccordionGroup>

***

## Email vs. phone datasets

<Tabs>
  <Tab title="Email datasets">
    ### What email verification checks

    * **Syntax** — RFC 5321/5322 compliance
    * **Domain** — MX record existence and validity
    * **SMTP** — Mailbox existence probe
    * **Provider flags** — Free provider (Gmail, Yahoo…), role address (info@, admin@…), disposable, catch-all

    ### Key result fields

    | Field                 | What it means                                                    |
    | :-------------------- | :--------------------------------------------------------------- |
    | `quality: "good"`     | Safe to send — deliverable and not flagged                       |
    | `quality: "risky"`    | May deliver but has risk signals (catch-all, role, free)         |
    | `quality: "bad"`      | Do not send — invalid or known bad                               |
    | `is_catch_all: true`  | Domain accepts all addresses — individual deliverability unknown |
    | `is_disposable: true` | One-time inbox service — likely low engagement                   |
  </Tab>

  <Tab title="Phone datasets">
    ### What phone verification checks

    * **Format** — E.164 format validation
    * **Number type** — Mobile, landline, VoIP, toll-free, pager, etc.
    * **HLR lookup** — Live network status, porting detection, current operator

    ### Key result fields

    | Field                         | What it means                                    |
    | :---------------------------- | :----------------------------------------------- |
    | `status: "live"`              | Number is active on the network                  |
    | `status: "dead"`              | Number is no longer in service                   |
    | `status: "absent_subscriber"` | Phone is off or out of coverage at time of check |
    | `type: "mobile"`              | Standard mobile number — best for SMS            |
    | `type: "voip"`                | VoIP number — may not accept SMS                 |
    | `is_ported: true`             | Number has moved to a different carrier          |

    <Warning>
      **Always use E.164 format for phone numbers.** Numbers without a country dialing code (e.g. `07911 123456` instead of `+447911123456`) will fail format validation and be marked as `wrong_phone` during parsing. They will not be verified and credits will not be charged for them.
    </Warning>
  </Tab>
</Tabs>
