curl --request GET \
--url https://app.manypi.com/api/leads \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.manypi.com/api/leads"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.manypi.com/api/leads', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.manypi.com/api/leads",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.manypi.com/api/leads"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.manypi.com/api/leads")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.manypi.com/api/leads")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"leads": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"company": "<string>",
"full_name": "<string>",
"title": "<string>",
"email": "<string>",
"phone": "<string>",
"domain": "<string>",
"linkedin_url": "<string>",
"location": "<string>",
"source_url": "<string>",
"score": 123,
"status": "new",
"custom": {},
"email_status": "valid",
"email_provider": "<string>",
"email_is_role": true,
"email_validated_at": "2023-11-07T05:31:56Z",
"unsubscribed_at": "2023-11-07T05:31:56Z",
"archived_at": "2023-11-07T05:31:56Z",
"agent_run_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"owner_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"brand_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"category": "<string>",
"subcategory": "<string>",
"list_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"import_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"company_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cc_emails": [
"<string>"
],
"bcc_emails": [
"<string>"
],
"avatar_url": "<string>",
"email_status_reason": "<string>",
"phone_e164": "<string>",
"phone_type": "<string>",
"phone_status": "<string>",
"company_description": "<string>",
"reply_summary": {},
"enrollment_summary": {},
"email_guess": {},
"created_at": "2023-11-07T05:31:56Z"
}
],
"total": 123,
"workspaceTotal": 123,
"customColumns": [
"<string>"
],
"customFields": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"key": "<string>",
"label": "<string>",
"type": "text",
"options": [
"<string>"
],
"option_colors": {},
"description": "<string>",
"auto_research": true,
"declared": true,
"position": 123
}
],
"campaigns": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"label": "<string>",
"count": 123,
"created_at": "2023-11-07T05:31:56Z"
}
],
"leadLimit": 123,
"manualLeadLimit": 123,
"filterCapped": true,
"billingLock": {}
}{
"error": "<string>",
"code": "<string>",
"details": "<unknown>"
}List leads
List and filter the workspace’s leads, newest first. Also returns the declared custom columns, the lead searches that saved leads, the workspace total and the plan’s lead limits, so a grid needs one call.
To get the leads one lead search found, pass its run id as campaign.
When the workspace is locked for billing, the response keeps the same shape but carries billingLock, and leads holds placeholder rows rather than real leads. Check for billingLock before you store or act on the rows.
An API key needs Leads & companies: Read (leads:read), or the legacy read permission.
curl --request GET \
--url https://app.manypi.com/api/leads \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.manypi.com/api/leads"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.manypi.com/api/leads', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.manypi.com/api/leads",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.manypi.com/api/leads"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.manypi.com/api/leads")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.manypi.com/api/leads")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"leads": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"company": "<string>",
"full_name": "<string>",
"title": "<string>",
"email": "<string>",
"phone": "<string>",
"domain": "<string>",
"linkedin_url": "<string>",
"location": "<string>",
"source_url": "<string>",
"score": 123,
"status": "new",
"custom": {},
"email_status": "valid",
"email_provider": "<string>",
"email_is_role": true,
"email_validated_at": "2023-11-07T05:31:56Z",
"unsubscribed_at": "2023-11-07T05:31:56Z",
"archived_at": "2023-11-07T05:31:56Z",
"agent_run_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"owner_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"brand_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"category": "<string>",
"subcategory": "<string>",
"list_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"import_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"company_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cc_emails": [
"<string>"
],
"bcc_emails": [
"<string>"
],
"avatar_url": "<string>",
"email_status_reason": "<string>",
"phone_e164": "<string>",
"phone_type": "<string>",
"phone_status": "<string>",
"company_description": "<string>",
"reply_summary": {},
"enrollment_summary": {},
"email_guess": {},
"created_at": "2023-11-07T05:31:56Z"
}
],
"total": 123,
"workspaceTotal": 123,
"customColumns": [
"<string>"
],
"customFields": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"key": "<string>",
"label": "<string>",
"type": "text",
"options": [
"<string>"
],
"option_colors": {},
"description": "<string>",
"auto_research": true,
"declared": true,
"position": 123
}
],
"campaigns": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"label": "<string>",
"count": 123,
"created_at": "2023-11-07T05:31:56Z"
}
],
"leadLimit": 123,
"manualLeadLimit": 123,
"filterCapped": true,
"billingLock": {}
}{
"error": "<string>",
"code": "<string>",
"details": "<unknown>"
}Authorizations
Query Parameters
The run id of a lead search: the run_id that POST /api/leads/research returns, or the id of any agent run that saved leads. Returns only the leads that search saved. campaigns in the GET /api/leads response lists the lead searches that have saved leads. A malformed id is ignored, so the request then returns every lead.
Response
Leads and grid metadata.
