curl --request POST \
--url https://api.brelio.app/v1/appointments/{id}/reschedule \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"id": "6a1e4c2b-8d3f-4e5a-9b7c-0d1e2f3a4b5c",
"expectedVersion": "1",
"start": "2026-11-12T10:00:00Z"
}
'const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
id: '6a1e4c2b-8d3f-4e5a-9b7c-0d1e2f3a4b5c',
expectedVersion: '1',
start: '2026-11-12T10:00:00Z'
})
};
fetch('https://api.brelio.app/v1/appointments/{id}/reschedule', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.brelio.app/v1/appointments/{id}/reschedule"
payload = {
"id": "6a1e4c2b-8d3f-4e5a-9b7c-0d1e2f3a4b5c",
"expectedVersion": "1",
"start": "2026-11-12T10:00:00Z"
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "<string>",
"seriesId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"start": "2023-11-07T05:31:56Z",
"end": "2023-11-07T05:31:56Z",
"durationMinutes": 0,
"status": "scheduled",
"professionalId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"serviceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"patientId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"centerId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"recurring": true,
"version": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}Mover cita
Mueve una cita puntual a otra hora, con las mismas reglas que la agenda de Brelio. No admite citas recurrentes.
curl --request POST \
--url https://api.brelio.app/v1/appointments/{id}/reschedule \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"id": "6a1e4c2b-8d3f-4e5a-9b7c-0d1e2f3a4b5c",
"expectedVersion": "1",
"start": "2026-11-12T10:00:00Z"
}
'const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
id: '6a1e4c2b-8d3f-4e5a-9b7c-0d1e2f3a4b5c',
expectedVersion: '1',
start: '2026-11-12T10:00:00Z'
})
};
fetch('https://api.brelio.app/v1/appointments/{id}/reschedule', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.brelio.app/v1/appointments/{id}/reschedule"
payload = {
"id": "6a1e4c2b-8d3f-4e5a-9b7c-0d1e2f3a4b5c",
"expectedVersion": "1",
"start": "2026-11-12T10:00:00Z"
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "<string>",
"seriesId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"start": "2023-11-07T05:31:56Z",
"end": "2023-11-07T05:31:56Z",
"durationMinutes": 0,
"status": "scheduled",
"professionalId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"serviceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"patientId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"centerId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"recurring": true,
"version": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "<string>",
"detail": "<string>",
"request_id": "<string>",
"params": {},
"hint": "<string>",
"retryAfterSeconds": 123
}Autorizaciones
Clave de API de Brelio (de organización o personal) o un token de acceso de WorkOS.
Encabezados
Único por comando; reutilízala solo para reintentar la misma llamada.
8 - 255Parámetros de ruta
El id que devuelve agenda.list, o el id de la serie de citas.
^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}(:.+)?$Cuerpo
La version de la cita tal como la devolvió appointments.get. No la construyas tú.
^[1-9]\d{0,8}$El nuevo inicio, ISO 8601. Tómalo de availability.search.
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z|([+-](?:[01]\d|2[0-3]):[0-5]\d)))$La nueva duración. Por defecto, la duración actual de la cita.
5 <= x <= 480Respuesta
Correcto
El id de la ocurrencia, tal como lo devuelve agenda.list.
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$ISO 8601, en UTC.
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$ISO 8601, en UTC.
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$-9007199254740991 <= x <= 9007199254740991scheduled, checked_in, in_progress, needs_review, completed, cancelled, no_show, voided ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$El paciente; null cuando quien llama no puede ver datos de pacientes.
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$Forma parte de una serie recurrente; estas citas aún no se pueden cambiar desde la API.
Token de versión opaco. Devuélvelo como expectedVersion para cambiar esta cita; no lo interpretes.
ISO 8601, en UTC.
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$ISO 8601, en UTC.
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$