Skip to main content
PUT
/
consultations
/
update
curl -X PUT https://api.medagenda.com/consultations/update \
  -H "Content-Type: application/json" \
  -d '{
    "consultationId": "550e8400-e29b-41d4-a716-446655440000",
    "dateTime": "2024-03-20T15:00:00",
    "observation": "Rescheduled - Patient requested later time slot"
  }'
{
  "consultationId": "550e8400-e29b-41d4-a716-446655440000",
  "dateTime": "2024-03-20T15:00:00",
  "duracaoMinutos": 60,
  "patient": {
    "cpf": "12345678901",
    "name": "João Silva",
    "email": "[email protected]",
    "dateOfBirth": "1985-06-15",
    "address": "Rua das Flores, 123, São Paulo, SP",
    "medicalHistory": "Hypertension, controlled with medication"
  },
  "doctor": {
    "crm": "123456SP",
    "name": "Dr. Maria Santos",
    "email": "[email protected]",
    "specialty": "Cardiologia",
    "telephone": "+5511987654321",
    "consultationValue": 350.00
  },
  "isUrgent": false,
  "observation": "Rescheduled - Patient requested later time slot"
}
Updates an existing consultation’s scheduling information and observations. This endpoint allows modifying the dateTime and observation fields. Patient and doctor assignments cannot be changed through this endpoint.

Request Body

consultationId
string
required
UUID of the consultation to update (e.g., “550e8400-e29b-41d4-a716-446655440000”)
dateTime
string
required
New consultation date and time in ISO 8601 format (e.g., “2024-03-20T15:00:00”)
observation
string
Updated notes or observations for the consultation
The patient, doctor, isUrgent, and duracaoMinutos fields cannot be modified through this endpoint. Only dateTime and observation can be updated.

Response

consultationId
string
UUID of the updated consultation
dateTime
string
Updated date and time of the consultation
duracaoMinutos
integer
Duration of the consultation in minutes (unchanged)
patient
object
Patient information (unchanged)
doctor
object
Doctor information (unchanged)
isUrgent
boolean
Urgent status (unchanged)
observation
string
Updated observation text
curl -X PUT https://api.medagenda.com/consultations/update \
  -H "Content-Type: application/json" \
  -d '{
    "consultationId": "550e8400-e29b-41d4-a716-446655440000",
    "dateTime": "2024-03-20T15:00:00",
    "observation": "Rescheduled - Patient requested later time slot"
  }'
{
  "consultationId": "550e8400-e29b-41d4-a716-446655440000",
  "dateTime": "2024-03-20T15:00:00",
  "duracaoMinutos": 60,
  "patient": {
    "cpf": "12345678901",
    "name": "João Silva",
    "email": "[email protected]",
    "dateOfBirth": "1985-06-15",
    "address": "Rua das Flores, 123, São Paulo, SP",
    "medicalHistory": "Hypertension, controlled with medication"
  },
  "doctor": {
    "crm": "123456SP",
    "name": "Dr. Maria Santos",
    "email": "[email protected]",
    "specialty": "Cardiologia",
    "telephone": "+5511987654321",
    "consultationValue": 350.00
  },
  "isUrgent": false,
  "observation": "Rescheduled - Patient requested later time slot"
}

Build docs developers (and LLMs) love