List contacts
curl --request GET \
--url https://api-contact.beem.africa/public/v1/contacts \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://api-contact.beem.africa/public/v1/contacts"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://api-contact.beem.africa/public/v1/contacts', 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-contact.beem.africa/public/v1/contacts",
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: Basic <encoded-value>"
],
]);
$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://api-contact.beem.africa/public/v1/contacts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-contact.beem.africa/public/v1/contacts")
.header("Authorization", "Basic <encoded-value>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-contact.beem.africa/public/v1/contacts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "604919718fb0191944537663",
"mob_no": "255784021800",
"mob_no2": "",
"title": "Mr.",
"first_name": "Test",
"last_name": "Test",
"gender": "",
"dob": "1970-01-01T00:00:00.000Z",
"address_area": "",
"address_city": "",
"address_country": "",
"email": "test@gmail.com",
"created": "2021-03-10T19:09:39.884Z"
}
],
"pagination": {
"totalItems": 1,
"currentPage": 1,
"pageSize": 25,
"totalPages": 1,
"startPage": 1,
"endPage": 1,
"startIndex": 0,
"endIndex": 0,
"pages": [
1
]
}
}{
"code": 120,
"message": "Invalid Authorization Parameters"
}API Reference
List contacts
GET
/
contacts
List contacts
curl --request GET \
--url https://api-contact.beem.africa/public/v1/contacts \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://api-contact.beem.africa/public/v1/contacts"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://api-contact.beem.africa/public/v1/contacts', 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-contact.beem.africa/public/v1/contacts",
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: Basic <encoded-value>"
],
]);
$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://api-contact.beem.africa/public/v1/contacts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-contact.beem.africa/public/v1/contacts")
.header("Authorization", "Basic <encoded-value>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-contact.beem.africa/public/v1/contacts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "604919718fb0191944537663",
"mob_no": "255784021800",
"mob_no2": "",
"title": "Mr.",
"first_name": "Test",
"last_name": "Test",
"gender": "",
"dob": "1970-01-01T00:00:00.000Z",
"address_area": "",
"address_city": "",
"address_country": "",
"email": "test@gmail.com",
"created": "2021-03-10T19:09:39.884Z"
}
],
"pagination": {
"totalItems": 1,
"currentPage": 1,
"pageSize": 25,
"totalPages": 1,
"startPage": 1,
"endPage": 1,
"startIndex": 0,
"endIndex": 0,
"pages": [
1
]
}
}{
"code": 120,
"message": "Invalid Authorization Parameters"
}Authorizations
basicAuthaccessToken
Beem API credentials: API key as username, API secret as password.
Query Parameters
Address book ID to list contacts from.
Maximum contacts to return per page.
Page number (starts at 1).
Search term to filter contacts by name or number.
Filter contacts by tag name.
⌘I
