Get more leads from a customer list

Send a list of your customers and get new companies that look like them, with the people to call and their phone numbers. Run it again whenever you want more.

Send Blackpearl a list of your customers, or of anyone already in your funnel. It works out what they have in common, finds new companies that look like them, and returns the people to call there, with phone numbers and emails. When you want more, run it again: each run skips the companies you already have.

There is no ideal customer profile to write and no filters to set. If you build a CRM or another sales product, this is how to give your own users a "get me more people to call" button.

This page is the whole path from a list to contacts. These operations are in Preview: see Versioning for what that means, and Audiences for every option.

How it works#

StepYou doBlackpearl does
1. Profile the listSend up to 1,000 contacts and your websiteMatches the list, counts what it has in common, and writes the targeting
2. Find lookalikesStart the runFinds, researches and scores new companies, leaving out the ones on your list
3. Get the contactsRead the resultsReturns the companies, the people to call, and why each one fits
4. Get moreRun the same campaign againRepeats step 2, skipping every company already delivered

Runs take a while, so they happen in the background. You start one, check on it, and read the results when it finishes. If your connection drops, the run carries on.

What you get#

Each result is a company with the people to call there:

{
  "result_shape": "company",
  "company_name": "Acme Corporation",
  "company_domain": "acme.example",
  "contacts": [
    {
      "full_name": "Jordan Reyes",
      "job_title": "VP Revenue Operations",
      "business_email": "jordan.reyes@acme.example",
      "mobile_phone": "+15125550142",
      "direct_number": "+15125550199",
      "other_numbers": ["+15125550177"],
      "is_primary": true,
      "final_score": 91.5,
      "reason": "Owns the workflow the offer improves."
    }
  ]
}

This example is shortened: contacts also carry linkedin_url, location and more scores. is_primary marks the best person to call first, and reason says why they fit, which is useful to show a sales rep.

Phone numbers. Any contact field can be null, so a contact may have a mobile number, a direct number, both, or neither. mobile_phone and direct_number hold one number each, and other_numbers holds any more. Numbers are returned as held in the source data, so some start with + and some do not. Normalise them before dialling.

What to expect. target_size is the most contacts you will get, and runs usually return fewer. In two test runs on real customer lists, a target_size of 100 returned about 60 companies and 70 contacts, and at least 9 in 10 contacts had a phone number. Those runs took 35 to 45 minutes. A campaign's first run takes longer because it also does setup. Your results depend on your market, so treat these numbers as a guide, not a promise.

Before you start#

You need:

  • An API key in BLACKPEARL_API_KEY, and the API address in BLACKPEARL_API_BASE_URL. See Authentication.
  • The audiences capability switched on, which you can check with GET /v1/capabilities. With a company-level key, send Blackpearl-Project on that call. See Capabilities and entitlements.
  • Credit on your account. See Billing.
  • A usage tier with no monthly spend cap, if your customers will run at the same time. On a capped tier your whole company runs one job at a time. See Rate limits.

If you serve many customers, give each one a project and use one company-level API key. Each customer then has their own spending limits and their own charges. See Managing your clients with projects. Name the customer's project once, when you create the seed, as the example below does. Every later call finds the project from the ID in its path. With a project key, leave the Blackpearl-Project header out.

Step 1: Send the list#

A seed is Blackpearl's profile of your list. To create one, save the list as customer-list.json. website_url is your own website, or your customer's if you are running this for them. product_description is optional, but it helps.

{
  "name": "Northstar customers",
  "website_url": "northstar.example",
  "product_name": "Northstar Analytics",
  "product_description": "Revenue-intelligence software for enterprise sales teams.",
  "contacts": [
    {"email": "jane.doe@acme.example"},
    {"full_name": "Sam Lee", "company_name": "Initech"},
    {"full_name": "Priya Shah", "company_domain": "globex.example"}
  ]
}

This list is shortened: send your real one. Each contact needs an email, or a linkedin_url, or a full_name plus a company_name or company_domain. Business emails and LinkedIn URLs match best. Sample anything larger than 1,000 contacts down to 1,000.

Clean the list first. One bad row rejects the whole request with 422 invalid_request, so drop rows with nothing to match on, leave out empty fields rather than sending "", and send only the fields above.

Then create the seed:

export CUSTOMER_PROJECT="client-a"

SEED_ID=$(curl --fail-with-body --silent --show-error \
  --request POST "$BLACKPEARL_API_BASE_URL/v1/audience-seeds" \
  --header "Authorization: Bearer $BLACKPEARL_API_KEY" \
  --header "Blackpearl-Project: $CUSTOMER_PROJECT" \
  --header "Idempotency-Key: seed-$CUSTOMER_PROJECT-1" \
  --header "Content-Type: application/json" \
  --data @customer-list.json | jq -er '.id')

Idempotency-Key makes retries safe: within 24 hours, repeating a request with the same key returns the first response instead of starting a second run. Sending the same key with a different body returns 409 idempotency_key_reused.

Step 2: Wait, then read what it found#

Seeds and runs are both jobs, so one small function can wait for either. Keep it for the later steps:

wait_for_job () {
  local give_up=$((SECONDS + 86400)) code
  while [ "$SECONDS" -lt "$give_up" ]; do
    code=$(curl --silent --max-time 30 --output job.json --write-out '%{http_code}' \
      "$BLACKPEARL_API_BASE_URL/v1/jobs/$1" \
      --header "Authorization: Bearer $BLACKPEARL_API_KEY" || true)
    case "$code" in
      200)
        case "$(jq -r '.status' job.json)" in
          succeeded) return 0 ;;
          failed|canceled) jq '{status, error_code, error}' job.json; return 1 ;;
        esac ;;
      429|5??|000) ;;
      *) cat job.json; return 1 ;;
    esac
    sleep 30
  done
  echo "Gave up waiting for job $1" >&2
  return 1
}

wait_for_job "$SEED_ID"

curl --fail-with-body --silent --show-error \
  "$BLACKPEARL_API_BASE_URL/v1/audience-seeds/$SEED_ID" \
  --header "Authorization: Bearer $BLACKPEARL_API_KEY" \
  | jq '.result | {match_rate, warnings, objective, icp_description, excluded_domains}'

The function keeps waiting through temporary errors, such as 429 or a 5xx, and stops on anything else. It gives up after 24 hours, by which point the platform will have ended the run.

You will see how much of the list could be used and the targeting written from it:

{
  "match_rate": 0.7667,
  "warnings": [],
  "objective": "Find revenue operations leaders at US software companies with 51-200 staff.",
  "icp_description": "Companies like this list: mainly Software Development (44%) and IT Services And IT Consulting (19%), most often 51-200 staff. Buyers are revenue operations leaders.",
  "excluded_domains": ["acme.example", "globex.example"]
}

excluded_domains are the companies identified on your list, which every run leaves out. A contact with only a personal email and no recognised company adds nothing here, so check results against your CRM. You can review all of this first, or go straight on to step 3 if you are building a one-click button. To change the targeting, send your own objective or icp_description in step 3.

If warnings is not empty, the seed still worked, but read it:

WarningWhat it meansWhat to do
website_onlyFewer than 10 contacts could be used, so the run will work from your website, not your listCarry on, or send more business emails or LinkedIn URLs for a true lookalike
low_match_rateUnder 30% of the list could be usedCheck the list has work emails or LinkedIn URLs
few_companiesThe list covers fewer than 10 companiesAdd more companies if you have them
mixed_industriesThe list spans many industries, so one profile may blur themSplit it and create one seed per type of customer

With website_only, icp_description is null and results are less sharply targeted, so product_description matters more. The run still goes ahead.

Step 3: Find the lookalikes#

RUN=$(curl --fail-with-body --silent --show-error \
  --request POST "$BLACKPEARL_API_BASE_URL/v1/audience-seeds/$SEED_ID/audiences" \
  --header "Authorization: Bearer $BLACKPEARL_API_KEY" \
  --header "Idempotency-Key: run-$SEED_ID" \
  --header "Content-Type: application/json" \
  --data '{"target_size": 100, "max_contacts_per_company": 3}')

JOB_ID=$(printf '%s' "$RUN" | jq -er '.id')
CAMPAIGN_ID=$(printf '%s' "$RUN" | jq -er '.campaign_id')

wait_for_job "$JOB_ID"

Save CAMPAIGN_ID. It is how you get more in step 5, and it keeps working after the seed expires. The API cannot cancel a run once it has started.

Step 4: Read the contacts#

Download everything as a spreadsheet, with one row per contact:

curl --fail-with-body --silent --show-error \
  "$BLACKPEARL_API_BASE_URL/v1/audiences/$JOB_ID/candidates.csv" \
  --header "Authorization: Bearer $BLACKPEARL_API_KEY" \
  --output leads.csv

Or read them page by page, to load into your own product:

CURSOR=""
while true; do
  PAGE=$(curl --fail-with-body --silent --show-error --get \
    "$BLACKPEARL_API_BASE_URL/v1/audiences/$JOB_ID/candidates" \
    --header "Authorization: Bearer $BLACKPEARL_API_KEY" \
    --data-urlencode "limit=100" \
    ${CURSOR:+--data-urlencode "cursor=$CURSOR"})

  printf '%s' "$PAGE" | jq -c '.candidates[] | . as $row | (.contacts // [$row])[]
    | {company: $row.company_name, domain: $row.company_domain, name: .full_name,
       title: .job_title, mobile_phone, direct_number, other_numbers, business_email}'

  CURSOR=$(printf '%s' "$PAGE" | jq -r '.next_cursor // empty')
  [ -n "$CURSOR" ] || break
done

Pass each next_cursor back unchanged, and stop when it is null. Candidates can also come back as flat contacts with result_shape: "contact", which the // [$row] above handles.

Step 5: Get more#

Run the same campaign again:

RUN=$(curl --fail-with-body --silent --show-error \
  --request POST "$BLACKPEARL_API_BASE_URL/v1/campaigns/$CAMPAIGN_ID/cycles" \
  --header "Authorization: Bearer $BLACKPEARL_API_KEY" \
  --header "Idempotency-Key: more-$CAMPAIGN_ID-2")

JOB_ID=$(printf '%s' "$RUN" | jq -er '.id')

wait_for_job "$JOB_ID"

Then read the contacts as in step 4. Each run skips every company this campaign has already delivered, matched by website domain. That means new companies, not more people at companies you already have. It also reuses the first run's targeting, so it skips setup and finishes sooner. Use a new Idempotency-Key each time you want another run.

A narrow market can run out. Each run works from what is left, so results may get smaller over time, and a run can return none. An empty run is still charged for the work it did.

Building this into your product#

  • Save three things per customer: their project, their campaign_id, and each run's job ID.
  • Copy contacts into your own system. Results stay readable for 30 days, then return 410 job_expired.
  • Reuse the campaign for "more". A new seed starts a new campaign with no delivery history, so it can return companies an earlier campaign delivered. To change the list or the targeting, create a new seed.
  • Leave out everyone already in your CRM. Step 3 only leaves out the companies on the list. To leave out more, start the run with POST /v1/audiences instead, sending Blackpearl-Project, the seed's objective and icp_description, your website_url, and excluded_domains with the seed's domains plus your own, up to 3,000. See Audiences.
  • Allow one run per campaign at a time. Starting another returns 409 cycle_in_progress, so disable the button while a run is going.
  • Check every 30 seconds. Polling faster does not speed up a run. See Jobs and resumable polling.
  • Set a spending limit per customer. See Managing your clients with projects.

What it costs#

StepCharged for
SeedA small data fee per usable contact, plus the cost of writing the targeting
Seed with website_onlyThe data fee only
Each runThe work the run did, plus a data fee for each delivered contact with an email, phone number or LinkedIn URL
A failed run or seedNothing

The first run on a campaign also pays a one-time setup cost. After a job finishes, its usage.cost_usd is exactly what it was charged. GET /v1/pricing-estimates returns typical run charges at your rates once there are enough recent runs to estimate from, and does not list seeds. See Billing.

If something goes wrong#

CodeStatusWhat to do
invalid_request422Fix the request. For a list, see step 1
insufficient_credits402Add credit, then start again
capability_disabled403Ask for audiences to be switched on
project_required400Send Blackpearl-Project, or use a project key
project_not_found404Check the project's id or slug
idempotency_key_reused409Use a new Idempotency-Key for a different request
audience_seed_not_ready409Wait for the seed to succeed. A failed seed needs a new one
cycle_in_progress409Wait for the current run to finish
budget_exceeded429If details.scope is usage_tier and reserved_usd is above zero, another job holds your tier's capacity, so submit again when it finishes. Otherwise a spending limit was reached: raise it, top up, or wait for it to reset
quota_exceeded429A usage quota was reached. Do not retry until it resets
job_expired410The 30-day window has passed

A job that fails reports why in error_code and error, and it is free. To try again, start a new one with a new Idempotency-Key. See Errors for every code.

Your data and your responsibilities#

  • Your list. The contacts you send are kept with the seed for 30 days, then deleted. The API never returns them: it returns counts across the list, plus excluded_domains. Those company domains stay on the campaign after that, so later runs keep leaving them out.
  • Names and emails are used to match the list. They are never sent to the AI model that writes the targeting.
  • Outreach is yours. Blackpearl finds contacts and does not call or email anyone. Following calling and email rules, including do-not-call lists, is up to you.

See Security and data handling.