curl --request POST \
--url https://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer \
--header 'Content-Type: application/json' \
--data '
{
"id": 115339282,
"cid": 293847172,
"email": "test.user@test.com",
"phone": "(212) xxx-xxxx"
}
'import requests
url = "https://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer"
payload = {
"id": 115339282,
"cid": 293847172,
"email": "test.user@test.com",
"phone": "(212) xxx-xxxx"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
id: 115339282,
cid: 293847172,
email: 'test.user@test.com',
phone: '(212) xxx-xxxx'
})
};
fetch('https://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer', 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://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer",
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([
'id' => 115339282,
'cid' => 293847172,
'email' => 'test.user@test.com',
'phone' => '(212) xxx-xxxx'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer"
payload := strings.NewReader("{\n \"id\": 115339282,\n \"cid\": 293847172,\n \"email\": \"test.user@test.com\",\n \"phone\": \"(212) xxx-xxxx\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer")
.header("Content-Type", "application/json")
.body("{\n \"id\": 115339282,\n \"cid\": 293847172,\n \"email\": \"test.user@test.com\",\n \"phone\": \"(212) xxx-xxxx\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"id\": 115339282,\n \"cid\": 293847172,\n \"email\": \"test.user@test.com\",\n \"phone\": \"(212) xxx-xxxx\"\n}"
response = http.request(request)
puts response.read_body{
"id": 115339282,
"firstName": "Michael",
"lastName": "Scott",
"email": "test.user@test.com",
"phone": "(212) xxx-xxxx",
"countryCode": "US",
"blocked": false,
"smsOptin": true,
"source": "api",
"created": "January 12, 2021",
"mappings": [
{
"cid": 1234451,
"location": "new horizon",
"bid": 710687,
"businessNumber": 161458406365307
},
{
"cid": 1235452,
"location": "North Carolina",
"bid": 714169,
"businessNumber": 161072537475129
}
],
"tags": [
"Tag One",
"Tag Two"
],
"customFields": [
{
"fieldName": "Company",
"type": "text",
"fieldValue": "Dunder Mifflin"
},
{
"fieldName": "Product",
"type": "text",
"fieldValue": "Paper"
}
],
"externalId": "ABC123",
"emailPreferences": {
"marketingOptin": true,
"feedbackOptin": true,
"serviceOptin": true
},
"smsPreferences": {
"marketingOptin": true,
"feedbackOptin": true,
"serviceOptin": true
}
}{
"code": 5043,
"message": "Contact not found for the given request"
}{
"code": 1161,
"message": "Invalid API key"
}{
"code": 1532,
"message": "Business id is missing or invalid."
}{
"code": 89,
"message": "Rate limit exceeded"
}Retrieve Contact
curl --request POST \
--url https://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer \
--header 'Content-Type: application/json' \
--data '
{
"id": 115339282,
"cid": 293847172,
"email": "test.user@test.com",
"phone": "(212) xxx-xxxx"
}
'import requests
url = "https://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer"
payload = {
"id": 115339282,
"cid": 293847172,
"email": "test.user@test.com",
"phone": "(212) xxx-xxxx"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
id: 115339282,
cid: 293847172,
email: 'test.user@test.com',
phone: '(212) xxx-xxxx'
})
};
fetch('https://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer', 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://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer",
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([
'id' => 115339282,
'cid' => 293847172,
'email' => 'test.user@test.com',
'phone' => '(212) xxx-xxxx'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer"
payload := strings.NewReader("{\n \"id\": 115339282,\n \"cid\": 293847172,\n \"email\": \"test.user@test.com\",\n \"phone\": \"(212) xxx-xxxx\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer")
.header("Content-Type", "application/json")
.body("{\n \"id\": 115339282,\n \"cid\": 293847172,\n \"email\": \"test.user@test.com\",\n \"phone\": \"(212) xxx-xxxx\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.birdeye.com/resources/v1/contact/external/preferences/getCustomer")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"id\": 115339282,\n \"cid\": 293847172,\n \"email\": \"test.user@test.com\",\n \"phone\": \"(212) xxx-xxxx\"\n}"
response = http.request(request)
puts response.read_body{
"id": 115339282,
"firstName": "Michael",
"lastName": "Scott",
"email": "test.user@test.com",
"phone": "(212) xxx-xxxx",
"countryCode": "US",
"blocked": false,
"smsOptin": true,
"source": "api",
"created": "January 12, 2021",
"mappings": [
{
"cid": 1234451,
"location": "new horizon",
"bid": 710687,
"businessNumber": 161458406365307
},
{
"cid": 1235452,
"location": "North Carolina",
"bid": 714169,
"businessNumber": 161072537475129
}
],
"tags": [
"Tag One",
"Tag Two"
],
"customFields": [
{
"fieldName": "Company",
"type": "text",
"fieldValue": "Dunder Mifflin"
},
{
"fieldName": "Product",
"type": "text",
"fieldValue": "Paper"
}
],
"externalId": "ABC123",
"emailPreferences": {
"marketingOptin": true,
"feedbackOptin": true,
"serviceOptin": true
},
"smsPreferences": {
"marketingOptin": true,
"feedbackOptin": true,
"serviceOptin": true
}
}{
"code": 5043,
"message": "Contact not found for the given request"
}{
"code": 1161,
"message": "Invalid API key"
}{
"code": 1532,
"message": "Business id is missing or invalid."
}{
"code": 89,
"message": "Rate limit exceeded"
}Headers
e.g. application/json
e.g. [Required] Partner specific API key provided by Birdeye for data exchange.
e.g. [Required] User assosiated businessNumber
Body
Id of enterprise customer. optional (if cid, phone or email is provided).
Id of customer mapping on a location. optional (if id, phone or email is provided).
Email of customer, optional (if phone, id or cid is provided).
Phone of customer optional (if email, id or cid is provided).
Response
OK
Id of enterprise customer.
First name of the customer.
Last name of the customer.
Email of customer, optional (if phone is provided).
Phone of customer optional (if email is provided).
Country code of the phone number. Default value=US, Other Possible values=AU,CA,MX,PR,VI
SMS Opting flag.
List of locations where customer is mapped. If requested by cid, only that location's mapping is returned.
List of tags.
List of Custom fields.
Unique external identifier of the contact which could be from the CRM or any external system storing your contacts.
Email communication preference flags.
Show child attributes
Show child attributes
SMS communication preference flags.
Show child attributes
Show child attributes

