PUT https://services.leadconnectorhq.com/calendars/appointments/{appointmentId}/notes/{noteId}
Autorización
string
required
Bearer token generado desde el portal Leadway. Ver Autenticación.
string
default:"2021-07-28"
required
Versión de la API.
Path parameters
string
required
Appointment ID
Body
string
default:"GCs5KuzPqTls7vWclkEV"
string
default:"lorem ipsum"
required
Note body
Respuestas
200 - Successful response
200 - Successful response
object
{
"note": {
"id": "HGPcayliwcdoUFzvbTok",
"body": "lorem ipsum",
"userId": "TUcmRxWrjqzJS8EjkxNK",
"dateAdded": "2021-07-08T12:02:11.285Z",
"contactId": "TUcmRxWrjqzJS8EjkxNK",
"createdBy": {
"id": "TUcmRxWr",
"name": "John Doe"
}
}
}
400 - Bad Request
400 - Bad Request
{}
401 - Unauthorized
401 - Unauthorized
{}
Ejemplo
curl -X PUT 'https://services.leadconnectorhq.com/calendars/appointments/YOUR_appointmentId/notes/YOUR_noteId' \
-H 'Authorization: Bearer YOUR_TOKEN' \
-H 'Version: 2021-07-28' \
-H 'Content-Type: application/json' \
-d '{
"userId": "GCs5KuzPqTls7vWclkEV",
"body": "lorem ipsum"
}'
const response = await fetch('https://services.leadconnectorhq.com/calendars/appointments/YOUR_appointmentId/notes/YOUR_noteId', {
method: 'PUT',
headers: {
Authorization: `Bearer ${process.env.LEADWAY_TOKEN}`,
Version: '2021-07-28',
'Content-Type': 'application/json',
},
body: JSON.stringify({"userId": "GCs5KuzPqTls7vWclkEV", "body": "lorem ipsum"}),
});
const data = await response.json();
import os, requests
response = requests.request(
'PUT',
'https://services.leadconnectorhq.com/calendars/appointments/YOUR_appointmentId/notes/YOUR_noteId',
headers={
'Authorization': f"Bearer {os.environ['LEADWAY_TOKEN']}",
'Version': '2021-07-28',
'Content-Type': 'application/json',
},
json={"userId": "GCs5KuzPqTls7vWclkEV", "body": "lorem ipsum"},
)
data = response.json()
<?php
$ch = curl_init('https://services.leadconnectorhq.com/calendars/appointments/YOUR_appointmentId/notes/YOUR_noteId');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'PUT',
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . getenv('LEADWAY_TOKEN'),
'Version: 2021-07-28',
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => json_encode({'userId': 'GCs5KuzPqTls7vWclkEV', 'body': 'lorem ipsum'}),
]);
$data = json_decode(curl_exec($ch), true);

