Bulk Verification (v0.7)
Last updated
Last updated
The default Reacher API only exposes one endpoint, /v0/check_email
, which allows verifying one email at a time. The optional Bulk Verification API allows you to queue up a list of emails in one go.
A self-hosted setup, see Install Reacher in 20min.
A PostgreSQL database, you can start for free with (no affiliation).
When running the Reacher backend, set two new environment variables:
RCH_ENABLE_BULK=1
DATABASE_URL=<your_postgres_db>
For example, if running with docker, run
The DATABASE_URL
value should look like postgres://<user>:<password>@<hostname>/<db_name>
.You should see the backend running with the following logs:
Bulk email verification is done in 3 steps:
POST /v0/bulk
The body of the request contains the list of emails, as well as a couple of configuration options.
If successful, this endpoint will return a unique job ID, used to track the progress of the bulk verification job and fetch its results.
GET /v0/bulk/{job_id}
If the list of emails is long, then the bulk verification job can take some time. Ping regularly on the endpoint above to see the status of the job.When the job is still running, the job_status
will be Running
:
And when the job is finished, we get job_status = Completed
, and the finished_at
field will be populated with the job’s end time.
GET /v0/bulk/{job_id}/results
Once the job_status
field in from the previous step is Completed
, this endpoint will show the results of all the emails in the list.
To avoid returning a huge JSON payload, the results
array by default only returns the first 50 email results. We recommend using pagination on the client side, using the 2 following query parameters:
?offset=<n>
: The offset from which we return the results, which is equivalent to the number of elements in the array to skip. Defaults to 0
.
?limit=<n>
: The number of results to return. Defaults to 50
.
For example, if your initial input has 100 emails to verify, and you want the results for emails #61-#70, you should add the query parameters: GET /v0/bulk/{job_id}/results?offset=60&limit=10
.
Pro Tip: You can also download the results as CSV, by passing the ?format=csv
query paramter: GET /v0/bulk/{job_id}/results?format=csv
.
This Bulk email verification feature is still new, so feel free to send me an email .