curl --request POST \
--url https://app.pipecorn.com/api/v2/contacts/report_phone \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"linkedin_url": "https://www.linkedin.com/in/william-hewish",
"phone": "+33612345678",
"find_replacement": true,
"webhook_url": "<string>"
}
'import requests
url = "https://app.pipecorn.com/api/v2/contacts/report_phone"
payload = {
"linkedin_url": "https://www.linkedin.com/in/william-hewish",
"phone": "+33612345678",
"find_replacement": True,
"webhook_url": "<string>"
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
linkedin_url: 'https://www.linkedin.com/in/william-hewish',
phone: '+33612345678',
find_replacement: true,
webhook_url: '<string>'
})
};
fetch('https://app.pipecorn.com/api/v2/contacts/report_phone', 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.pipecorn.com/api/v2/contacts/report_phone",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'linkedin_url' => 'https://www.linkedin.com/in/william-hewish',
'phone' => '+33612345678',
'find_replacement' => true,
'webhook_url' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.pipecorn.com/api/v2/contacts/report_phone"
payload := strings.NewReader("{\n \"linkedin_url\": \"https://www.linkedin.com/in/william-hewish\",\n \"phone\": \"+33612345678\",\n \"find_replacement\": true,\n \"webhook_url\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-KEY", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.pipecorn.com/api/v2/contacts/report_phone")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"linkedin_url\": \"https://www.linkedin.com/in/william-hewish\",\n \"phone\": \"+33612345678\",\n \"find_replacement\": true,\n \"webhook_url\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.pipecorn.com/api/v2/contacts/report_phone")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"linkedin_url\": \"https://www.linkedin.com/in/william-hewish\",\n \"phone\": \"+33612345678\",\n \"find_replacement\": true,\n \"webhook_url\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"enrichment_id": "8f1c2a4e-5b6d-4e7f-9a0b-1c2d3e4f5a6b",
"reported": true,
"replacement": "searching",
"status_url": "https://app.pipecorn.com/api/v2/contacts/8f1c2a4e-5b6d-4e7f-9a0b-1c2d3e4f5a6b"
}{
"error": "Missing required keys: reason"
}{
"error": "Phone not found on this contact"
}{
"error": "A request with this Idempotency-Key is still being processed",
"code": "idempotency_key_in_use"
}{
"error": "Invalid reason, use one of: wrong_person, disconnected"
}Report a wrong phone number
Flag a number Pipecorn returned as wrong and search for another one
curl --request POST \
--url https://app.pipecorn.com/api/v2/contacts/report_phone \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"linkedin_url": "https://www.linkedin.com/in/william-hewish",
"phone": "+33612345678",
"find_replacement": true,
"webhook_url": "<string>"
}
'import requests
url = "https://app.pipecorn.com/api/v2/contacts/report_phone"
payload = {
"linkedin_url": "https://www.linkedin.com/in/william-hewish",
"phone": "+33612345678",
"find_replacement": True,
"webhook_url": "<string>"
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
linkedin_url: 'https://www.linkedin.com/in/william-hewish',
phone: '+33612345678',
find_replacement: true,
webhook_url: '<string>'
})
};
fetch('https://app.pipecorn.com/api/v2/contacts/report_phone', 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.pipecorn.com/api/v2/contacts/report_phone",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'linkedin_url' => 'https://www.linkedin.com/in/william-hewish',
'phone' => '+33612345678',
'find_replacement' => true,
'webhook_url' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.pipecorn.com/api/v2/contacts/report_phone"
payload := strings.NewReader("{\n \"linkedin_url\": \"https://www.linkedin.com/in/william-hewish\",\n \"phone\": \"+33612345678\",\n \"find_replacement\": true,\n \"webhook_url\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-KEY", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.pipecorn.com/api/v2/contacts/report_phone")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"linkedin_url\": \"https://www.linkedin.com/in/william-hewish\",\n \"phone\": \"+33612345678\",\n \"find_replacement\": true,\n \"webhook_url\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.pipecorn.com/api/v2/contacts/report_phone")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"linkedin_url\": \"https://www.linkedin.com/in/william-hewish\",\n \"phone\": \"+33612345678\",\n \"find_replacement\": true,\n \"webhook_url\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"enrichment_id": "8f1c2a4e-5b6d-4e7f-9a0b-1c2d3e4f5a6b",
"reported": true,
"replacement": "searching",
"status_url": "https://app.pipecorn.com/api/v2/contacts/8f1c2a4e-5b6d-4e7f-9a0b-1c2d3e4f5a6b"
}{
"error": "Missing required keys: reason"
}{
"error": "Phone not found on this contact"
}{
"error": "A request with this Idempotency-Key is still being processed",
"code": "idempotency_key_in_use"
}{
"error": "Invalid reason, use one of: wrong_person, disconnected"
}Flow
- Send the contact’s
linkedin_url, the wrongphoneand areason. - The response says whether a new search started (
replacement: "searching"). - Poll
status_urluntilstatusisfinished, or wait for the webhook. It carries the new number inphones, or no number when none was found.
curl -X POST https://app.pipecorn.com/api/v2/contacts/report_phone \
-H "X-API-Key: $PIPECORN_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"linkedin_url": "https://www.linkedin.com/in/william-hewish",
"phone": "+33612345678",
"reason": "wrong_person",
"webhook_url": "https://example.com/pipecorn/phones"
}'
Credits
Reporting is free. The new search costs 30 credits, like any phone enrichment, and only when it finds a number. Send"find_replacement": false to report the
number without searching.Authorizations
Your API key
Headers
A unique value you generate per operation, such as a UUID. Retrying with the same key and the same body returns the stored response instead of running the request again, so a retry after a timeout never charges twice. Successful responses are kept for 24 hours; a failed request is not stored and can be retried with the same key.
255"4f1c2e9a-8a7d-4c1b-9f63-2d6e0b5a7c11"
Body
LinkedIn profile URL of the contact, as sent to the enrichment.
"https://www.linkedin.com/in/william-hewish"
The wrong number, as Pipecorn returned it. Any international format works: spaces, dots, dashes and parentheses are ignored.
"+33612345678"
wrong_person: the number belongs to someone else. disconnected: the number no longer works.
wrong_person, disconnected Search for another number. Send false to only report the number.
Where to send the result of the new search. Defaults to the webhook_url of the original enrichment.
Response
The number is reported
The contact's enrichment ID, for GET /contacts/{id}
Always true
searching: a new phone search is running. other_mobile_kept: the contact still has another mobile, so no search ran. not_allowed: your plan or role does not allow phone enrichment. insufficient_credits: fewer than 30 credits left. skipped: you sent find_replacement: false.
searching, other_mobile_kept, not_allowed, insufficient_credits, skipped GET /contacts/{id} for this contact
Was this page helpful?