---
title: "Validate contact data in QuickMail"
url: "https://lookvalid.com/integrations/quickmail.md"
canonical_url: "https://lookvalid.com/integrations/quickmail"
last_updated: "2026-10-22"
type: "how-to"
summary: "Check phone numbers before they become QuickMail leads and store the result in a custom property on each lead."
related: ["https://lookvalid.com/integrations.md", "https://lookvalid.com/docs/api/phone.md", "https://lookvalid.com/docs/quickstart.md"]
---

# Validate contact data in QuickMail

Check phone numbers before they become QuickMail leads and store the result in a custom property on each lead.

QuickMail runs outreach across several client workspaces, and a lead that is created with a sloppy phone value follows the lead into every workspace report. Agencies then find that one client list uses one phone format and another uses five, which makes it slow to split a list by country or to hand call-ready contacts to a client.

## What LookValid checks

- [Phone Numbering-Plan Validation](https://lookvalid.com/products/phone.md): Returns the E.164 form, the country and the number type the numbering plan assigns for each lead phone. It does not tell you whether the line is active. (1 credit per valid number)
- [Country Calling Codes](https://lookvalid.com/products/country-code.md): Turns a calling code or country name into the dialing rules for that country, which helps when you split leads by region. (1 credit per lookup (an unknown code, country or name is free))
- [Phone Spam Check](https://lookvalid.com/products/phone-spam.md): Shows the count of consumer complaints on file for a number, reported by callers and not checked, before you pass it to a client for calling. (1 credit per number with complaints on record)
- [Email Domain Check](https://lookvalid.com/products/email-domain-check.md): Checks the domain of each lead address for mail servers and throwaway providers. It cannot confirm that the mailbox exists. (1 credit per address checked)

## Connect it in four steps

1. Register with LookValid and create an API key in your account.
2. Place the key in the LOOKVALID_API_KEY environment variable of the script, and keep the QuickMail key, which goes in the Authorization header without a prefix, in a different variable.
3. Run the function on each phone before you create the lead: it posts to the phone endpoint, returns null if there is no result and throws the error code and fix when the API refuses.
4. Create one custom property per returned value with the createCustomProperty mutation, then set it on the new lead ids with setCustomProperty so the values show on each lead in the workspace.

a script that runs before the createLeads mutation of the QuickMail GraphQL API The call is `POST https://YOUR_API_HOST/v1/phone`.

```js
const API_URL = "https://YOUR_API_HOST/v1/phone";

export async function checkQuickmailLeadPhone(value) {
  const response = await fetch(API_URL, {
    method: "POST",
    headers: {
      Authorization: `Bearer ${process.env.LOOKVALID_API_KEY}`,
      "Content-Type": "application/json",
    },
    body: JSON.stringify({
      "phone": value,
    }),
  });
  const result = await response.json();
  if (!response.ok) throw new Error(`${result.error.code}: ${result.error.fix}`);
  if (!result.found) return null;
  return {
      "Phone E164": result.data?.e164 ?? null,
      "Phone type": result.data?.number_type ?? null,
      "Phone valid": result.data?.valid ?? null,
  };
}
```

| Response field | Goes into |
| --- | --- |
| `data.e164` | Phone E164 |
| `data.number_type` | Phone type |
| `data.valid` | Phone valid |

## Without code

QuickMail exposes a GraphQL endpoint that an automation platform can call from a generic HTTP request step. Add one step that posts the lead phone to the phone endpoint with your key in a bearer header, and a second step that sends the setCustomProperty mutation to QuickMail with the returned values. No dedicated app is needed on either side.

## Questions

### What does one phone check cost in credits?

It draws credits from your LookValid balance. The pricing page lists the amount for the phone check.

### Can the check say a lead number is reachable?

No. It confirms that the number fits the numbering plan of its country and returns its type. Reachability needs a call.

### Which key goes where in a QuickMail script?

The LookValid key belongs in LOOKVALID_API_KEY. The QuickMail key is sent in its own Authorization header and should live in a separate variable, since the two services are unrelated.

## Sources

- [QuickMail help: setting up API v2](https://help.quickmail.com/integrations/setting-up-api-v2/), read 2026-10-18

## Related

- [LookValid integrations](https://lookvalid.com/integrations.md)
- [Phone Numbering-Plan Validation reference](https://lookvalid.com/docs/api/phone.md)
- [Quickstart](https://lookvalid.com/docs/quickstart.md)
