GET https://services.leadconnectorhq.com/contacts/{contactId}/appointments
Autorización
Bearer token generado desde el portal Leadway. Ver Autenticación.
Versión de la API.
Path parameters
Contact Id
Respuestas
200 - Successful response
200 - Successful response
Show cada item
Show cada item
{
"events": [
{
"id": "YS3jaqqeehkR2Is80miy",
"calendarId": "YlWd2wuCAZQzh2cH1fVZ",
"status": "booked",
"title": "Test",
"assignedUserId": "YlWd2wuCAZQzh2cH1fVZ",
"notes": "test",
"startTime": "2021-07-16 11:00:00",
"endTime": "2021-07-16 11:30:00",
"address": "Address",
"locationId": "YlWd2wuCAZQzh2cH1fVZ",
"contactId": "YlWd2wuCAZQzh2cH1fVZ",
"groupId": "YlWd2wuCAZQzh2cH1fVZ",
"appointmentStatus": "booked",
"users": [
"YlWd2wuCAZQzh2cH1fVZ",
"YlWd2wuCAZQzh2cH1fVZ"
],
"dateAdded": "2021-07-16 11:00:00",
"dateUpdated": "2021-07-16 11:30:00",
"assignedResources": [
"YlWd2wuCAZQzh2cH1fVZ",
"YlWd2wuCAZQzh2cH1fVZ"
]
}
]
}
400 - Bad Request
400 - Bad Request
{}
401 - Unauthorized
401 - Unauthorized
{}
422 - Unprocessable Entity
422 - Unprocessable Entity
{}
Ejemplo
curl -X GET 'https://services.leadconnectorhq.com/contacts/YOUR_contactId/appointments' \
-H 'Authorization: Bearer YOUR_TOKEN' \
-H 'Version: 2021-07-28'
const response = await fetch('https://services.leadconnectorhq.com/contacts/YOUR_contactId/appointments', {
method: 'GET',
headers: {
Authorization: `Bearer ${process.env.LEADWAY_TOKEN}`,
Version: '2021-07-28',
},
});
const data = await response.json();
import os, requests
response = requests.request(
'GET',
'https://services.leadconnectorhq.com/contacts/YOUR_contactId/appointments',
headers={
'Authorization': f"Bearer {os.environ['LEADWAY_TOKEN']}",
'Version': '2021-07-28',
},
)
data = response.json()
<?php
$ch = curl_init('https://services.leadconnectorhq.com/contacts/YOUR_contactId/appointments');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . getenv('LEADWAY_TOKEN'),
'Version: 2021-07-28',
],
]);
$data = json_decode(curl_exec($ch), true);

