Skip to content

API reference / RivetMSP

Contacts

GET /contacts Bearer token or API key

List contacts (paged, filterable by client)

Parameters

NameInTypeDescription
client_idqueryinteger
searchquerystring
pagequeryinteger
limitqueryinteger

Example request

curl "https://YOUR-HOST/api/v1/contacts" \
  -H "Authorization: Bearer $TOKEN"
import requests

response = requests.get(
    "https://YOUR-HOST/api/v1/contacts",
    headers={"Authorization": f"Bearer {TOKEN}"},
)
print(response.json())
const response = await fetch("https://YOUR-HOST/api/v1/contacts", {
  method: "GET",
  headers: { "Authorization": `Bearer ${TOKEN}` },
});
const data = await response.json();
$ch = curl_init("https://YOUR-HOST/api/v1/contacts");
curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_CUSTOMREQUEST => "GET",
    CURLOPT_HTTPHEADER => ["Authorization: Bearer $token"],
]);
$data = json_decode(curl_exec($ch), true);

Responses

200Paged contact list

FieldTypeDescription
data array of object
data[].id integer
data[].name string
data[].title string
data[].email string
data[].phone string
data[].extension string
data[].client string
total integer
Example response
json
{
    "data": [
        {
            "id": 1,
            "name": "string",
            "title": "string",
            "email": "string",
            "phone": "string",
            "extension": "string",
            "client": "string"
        }
    ],
    "total": 1
}