NAV
shell

Introduction

Wecome to Progenda ! Progenda is an appointment booking platform with features such as text message or email reminders and two-way synchronisations with other calendars. This page describes our REST APIs. These allow you to synchronise objects that are at the core of our platform. If you need another concept to be added to our API, do not hesitate to contact us.

Centers

List all centers

curl "https://progenda.be/api/v2/centers?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"

Example Response

{
  "centers": [
    {
      "center": {
        "id": 2,
        "slug": "jorisvh",
        "name": "Centre de Joris Van Hecke"
      }
    }
  ]
}

Returns a list of the centers the user can access.

HTTP Request

GET/api/v2/centers

Calendars

List all calendars

curl "https://progenda.be/api/v2/calendars?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"

Example Response

{
  "calendars": [
    {
      "calendar": {
        "id": 2,
        "center_id": 1,
        "first_name": "Joris",
        "last_name": "Van Hecke",
        "full_name": "Joris Van Hecke",
        "slug": "jorisvh",
        "specialities": [
          { "speciality": { "name": "surgeon_abdominal", "id": 1 } }
        ]
      }
    }
  ]
}

Returns a list of the calendars the user can access.

HTTP Request

GET/api/v2/calendars

Patients

List all patients

curl "https://progenda.be/api/v2/centers/{center_id}/patients?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"

Example Response

{
  "patients": [
    {
      "patient": {
        "id": 3,
        "remote_id": "698",
        "last_name": "Van Hecke",
        "first_name": "Joris",
        "email": "joris.vanhecke@gmail.com",
        "phone_number": "+393883231049",
        "birthdate": "1990-05-16",
        "address": "Rue Brederode, 16, 1000 Brussels",
        "notes": null,
        "status": "active",
        "language_code": null
      }
    }
  ]
}

Returns a list of the patients belonging to the center, paginated with a limit of 1000 patients per page.

HTTP Request

GET/api/v2/centers/{center_id}/patients

URL Parameters

Parameter Details Description
page integer, optional Page number of the list. Each page has a size of 1000 objects. The total number of objects is returned in the HTTP header “X-Total-Count”.
since integer, optional Timestamp of the last update. Only the patients updated after that time will be returned.

Retrieve a patient

curl "https://progenda.be/api/v2/centers/{center_id}/patients/remote_id:{patient_remote_id}?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"

Example Response

{
  "patient": {
    "id": 3,
    "remote_id": "698",
    "last_name": "Van Hecke",
    "first_name": "Joris",
    "email": "joris.vanhecke@gmail.com",
    "phone_number": "+393883231049",
    "birthdate": "1990-05-16",
    "address": "Rue Brederode, 16, 1000 Brussels",
    "notes": null,
    "status": "active",
    "language_code": null
  }
}

Returns the information about a specific patient.

HTTP Request

GET/api/v2/centers/{center_id}/patients/remote_id:{patient_remote_id}

Create a patient

curl -XPOST "https://progenda.be/api/v2/centers/{center_id}/patients?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"
{
  "patient": {
    "remote_id": "698",
    "last_name": "Van Hecke",
    "first_name": "Joris",
    "email": "joris.vanhecke@gmail.com",
    "phone_number": "+393883231049",
    "birthdate": "1990-05-16",
    "address": "Rue Brederode, 16, 1000 Brussels",
    "notes": null,
    "language_code": null
  }
}

Example Response

{
  "patient": {
    "id": 3,
    "remote_id": "698",
    "last_name": "Van Hecke",
    "first_name": "Joris",
    "email": "joris.vanhecke@gmail.com",
    "phone_number": "+393883231049",
    "birthdate": "1990-05-16",
    "address": "Rue Brederode, 16, 1000 Brussels",
    "notes": null,
    "status": "active",
    "language_code": null
  }
}

Creates a new patient.

HTTP Request

POST/api/v2/centers/{center_id}/patients

Body Parameters

Parameter Details Description
patient[remote_id] string, required Your identifier for the patient.
patient[first_name] string, required (can be blank) The patient’s first name.
patient[last_name] string, required (can be blank) The patient’s last name.
patient[email] string, required (can be blank) The patient’s email address.
patient[phone_number] string, required (can be blank) The patient’s phone number. Please use preferably his mobile number, as we send text message reminders.
patient[birthdate] string, optional The patient’s birthdate (yyyy-mm-dd).
patient[address] string, optional The patient’s address.
patient[notes] string, optional Personal notes about the patient.
patient[language_code] string, optional The patient’s language (e.g. en, fr, nl, es).

Assign a remote ID

curl -XPUT "https://progenda.be/api/v2/centers/{center_id}/patients/{patient_id}?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"
{
  "patient": {
    "remote_id": "698"
  }
}

Example Response

{
  "patient": {
    "id": 3,
    "remote_id": "698",
    "last_name": "Van Hecke",
    "first_name": "Joris",
    "email": "joris.vanhecke@gmail.com",
    "phone_number": "+393883231049",
    "birthdate": "1990-05-16",
    "address": "Rue Brederode, 16, 1000 Brussels",
    "notes": null,
    "status": "active",
    "language_code": null
  }
}

Assigns a remote identifier (your identifier) to an existing patient (identified with the Progenda identifier provided in the URL). This request can typically be used after retrieval of the list of new patients.

HTTP Request

PUT/api/v2/centers/{center_id}/patients/{patient_id}

Body Parameters

Parameter Details Description
patient[remote_id] string, required Your identifier for the patient.

Update a patient

curl -XPUT "https://progenda.be/api/v2/centers/{center_id}/patients/remote_id:{patient_remote_id}?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"
{
  "patient": {
    "last_name": "Van Hecke",
    "first_name": "Joris",
    "email": "joris.vanhecke@gmail.com",
    "phone_number": "+393883231049",
    "birthdate": "1990-05-16",
    "address": "Rue Brederode, 16, 1000 Brussels",
    "notes": null,
    "language_code": null
  }
}

Example Response

{
  "patient": {
    "id": 3,
    "remote_id": "698",
    "last_name": "Van Hecke",
    "first_name": "Joris",
    "email": "joris.vanhecke@gmail.com",
    "phone_number": "+393883231049",
    "birthdate": "1990-05-16",
    "address": "Rue Brederode, 16, 1000 Brussels",
    "notes": null,
    "status": "active",
    "language_code": null
  }
}

Updates the patient identified with the remote_id.

HTTP Request

PUT/api/v2/centers/{center_id}/patients/remote_id:{patient_remote_id}

Body Parameters

Parameter Details Description
patient[first_name] string, required (can be blank) Patient’s first name.
patient[last_name] string, required (can be blank) Patient’s last name.
patient[email] string, required (can be blank) Patient’s email address.
patient[phone_number] string, required (can be blank) The patient’s phone number. Please use preferably his mobile number, as we send text message reminders.
patient[birthdate] string, optional The patient’s birthdate (yyyy-mm-dd).
patient[address] string, optional The patient’s address.
patient[notes] string, optional Personal notes about the patient.
patient[language_code] string, optional The patient’s language (e.g. en, fr, nl, es).

Delete a patient

curl -XDELETE "https://progenda.be/api/v2/centers/{center_id}/patients/remote_id:{patient_remote_id}?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"

Deletes a patient.

HTTP Request

DELETE/api/v2/centers/{center_id}/patients/remote_id:{patient_remote_id}

Bulk creation or update of patients

curl -XPOST "https://progenda.be/api/v2/centers/{center_id}/patients_collections?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"
{
  "patients_collection": {
    "patients": [
      {
        "patient": {
          "id": "1",
          "remote_id": "698"
        }
      },
      {
        "patient": {
          "id": "2",
          "remote_id": "999"
        }
      }
    ]
  }
}

Example Response

{
  "patients": [
    {
      "patient": {
        "id": 3,
        "remote_id": "698",
        "last_name": "Van Hecke",
        "first_name": "Joris",
        "email": "joris.vanhecke@gmail.com",
        "phone_number": "+393883231049",
        "birthdate": "1990-05-16",
        "address": "Rue Brederode, 16, 1000 Brussels",
        "notes": null,
        "status": "active",
        "language_code": null
      }
    }
  ]
}

Processes the collection of patients by creating them or updating them if the provided ID or remote ID already exist in our patient database.

HTTP Request

POST/api/v2/centers/{center_id}/patients_collections

Body Parameters

Parameter Details Description
patients_collection[patients][patient][id] integer, optional Progenda identifier for the patient.
patients_collection[patients][patient][remote_id] integer, optional Your identifier for the patient.
patients_collection[patients][patient][first_name] string, required (can be blank) Patient’s first name.
patients_collection[patients][patient][last_name] string, required (can be blank) Patient’s last name.
patients_collection[patients][patient][email] string, required (can be blank) Patient’s email address.
patients_collection[patients][patient][phone_number] string, required (can be blank) The patient’s phone number. Please use preferably his mobile number, as we send text message reminders.
patients_collection[patients][patient][birthdate] string, optional Patient’s birthdate (yyyy-mm-dd).
patients_collection[patients][patient][address] string, optional Patient’s address.
patients_collection[patients][patient][notes] string, optional Notes about the patient.
patients_collection[patients][patient][language_code] string, optional Patient’s language (e.g en, fr, nl, es).

Appointments

List all appointments

curl "https://progenda.be/api/v2/calendars/{calendar_id}/appointments?user_email={user_email}&user_token={user_token}&start={start}&stop={stop}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"

Example Response

{
  "appointments": [
    {
      "appointment": {
        "id": "57",
        "remote_id": "8401",
        "start": "1417682400",
        "stop": "1417683600",
        "notes": false,
        "warning": false,
        "color": "#101010",
        "title": "",
        "status": "booked",
        "patient_id": "16",
        "patient_remote_id": "104",
        "service_remote_id": "xyz",
        "noshow": false,
        "patient_arrived_at": null
      }
    }
  ]
}

Returns a list of the appointments belonging to the calendar.

HTTP Request

GET/api/v2/calendars/{calendar_id}/appointments

URL Parameters

Parameter Details Description
since integer, optional Timestamp of the last update. Only the appointments updated after that time will be returned.

Retrieve an appointment

curl "https://progenda.be/api/v2/calendars/{calendar_id}/appointments/remote_id:{appointment_remote_id}?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"

Example Response

{
  "appointment": {
    "id": "57",
    "remote_id": "8401",
    "start": "1417682400",
    "stop": "1417683600",
    "notes": false,
    "warning": false,
    "color": "#101010",
    "title": "",
    "status": "booked",
    "patient_id": "16",
    "patient_remote_id": "104",
    "service_remote_id": "xyz",
    "noshow": false,
    "patient_arrived_at": null
  }
}

Returns the information about a specific appointment.

HTTP Request

GET/api/v2/calendars/{calendar_id}/appointments/remote_id:{appointment_remote_id}

Create an appointment

curl -XPOST "https://progenda.be/api/v2/calendars/{calendar_id}/appointments?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"
{
  "appointment": {
    "remote_id": "8401",
    "start": "1417682400",
    "stop": "1417683600",
    "notes": false,
    "color": "#101010",
    "title": "",
    "status": "booked",
    "patient_remote_id": "104",
    "service_remote_id": "xyz",
    "noshow": false,
    "patient_arrived_at": null
  }
}

Example Response

{
  "appointment": {
    "id": "57",
    "remote_id": "8401",
    "start": "1417682400",
    "stop": "1417683600",
    "notes": false,
    "warning": false,
    "color": "#101010",
    "title": "",
    "status": "booked",
    "patient_id": "16",
    "patient_remote_id": "104",
    "service_remote_id": "xyz",
    "noshow": false,
    "patient_arrived_at": null
  }
}

Creates an appointment.

HTTP Request

POST/api/v2/calendars/{calendar_id}/appointments

Body Parameters

Parameter Details Description
appointment[remote_id] string, required Your identifier for the appointment.
appointment[patient_remote_id] string, optional Your identifier for the patient of the appointment.
appointment[start] timestamp, required The time of the appointment start.
appointment[stop] timestamp, required The time of the appointment end.
appointment[notes] string, optional Personal notes about the appointment.
appointment[color] string formatted as #xxyyzz, optional Color of the appointment on the user’s interface.
appointment[title] string, optional Title of the appointment (e.g. Meeting, Lunch, Break)
appointment[status] string, optional (must be one of : “booked”, “cancelled” or “noshow”) Status of the appointment. A “cancelled” appointment cannot become “booked” again.
appointment[service_remote_id] string, optional Your identifier for the appointment type of the appointment.
appointment[patient_arrived_at] timestamp, optional Time of arrival of the patient for this appointment. If null, the patient has not arrived yet.
appointment[noshow] boolean, optional Set to true if the patient missed his appointment. Defaults to false.

Assign a remote ID

curl -XPUT "https://progenda.be/api/v2/calendars/{calendar_id}/appointments/{appointment_id}?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"
{
  "appointment": {
    "remote_id": "8401"
  }
}

Example Response

{
  "appointment": {
    "id": "57",
    "remote_id": "8401",
    "start": "1417682400",
    "stop": "1417683600",
    "notes": false,
    "warning": false,
    "color": "#101010",
    "title": "",
    "status": "booked",
    "patient_id": "16",
    "patient_remote_id": "104",
    "service_remote_id": "xyz",
    "noshow": false,
    "patient_arrived_at": null
  }
}

Assigns a remote identifier (your identifier) to an existing appointment (identified with the Progenda identifier provided in the URL). This request can typically be used after retrieval of the list of new appointments.

HTTP Request

PUT/api/v2/calendars/{calendar_id}/appointments/{appointment_id}

Body Parameters

Parameter Details Description
appointment[remote_id] string, required Your identifier for the appointment.

Update an appointment

curl -XPUT "https://progenda.be/api/v2/calendars/{calendar_id}/appointments/remote_id:{appointment_remote_id}?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"
{
  "appointment": {
    "start": "1417682400",
    "stop": "1417683600",
    "notes": false,
    "color": "#101010",
    "title": "",
    "patient_remote_id": "104"
  }
}

Example Response

{
  "appointment": {
    "id": "57",
    "remote_id": "8401",
    "start": "1417682400",
    "stop": "1417683600",
    "notes": false,
    "warning": false,
    "color": "#101010",
    "title": "",
    "status": "booked",
    "patient_id": "16",
    "patient_remote_id": "104",
    "service_remote_id": "xyz",
    "noshow": false,
    "patient_arrived_at": null
  }
}

Updates the appointment identified with the remote_id.

HTTP Request

PUT/api/v2/calendars/{calendar_id}/appointments/remote_id:{appointment_remote_id}

Body Parameters

Parameter Details Description
appointment[patient_remote_id] string, optional Your identifier for the appointment.
appointment[start] timestamp, optional The time of the appointment start.
appointment[stop] timestamp, optional The time of the appointment end.
appointment[notes] string, optional Personal notes about the appointment.
appointment[color] string formatted as #xxyyzz, optional Color of the appointment on the user’s interface.
appointment[title] string, optional Title of the appointment (e.g. Meeting, Lunch, Break)
appointment[status] string, optional (must be one of : “booked”, “cancelled” or “noshow”) Status of the appointment. A “cancelled” appointment cannot become “booked” again.
appointment[service_remote_id] string, optional Your identifier for the appointment type of the appointment.
appointment[patient_arrived_at] timestamp, optional Time of arrival of the patient for this appointment. If null, the patient has not arrived yet.
appointment[noshow] boolean, optional Set to true if the patient missed his appointment. Defaults to false.

Delete an appointment

curl -XDELETE "https://progenda.be/api/v2/calendars/{calendar_id}/appointments/remote_id:{appointment_remote_id}?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"

Deletes an appointment

HTTP Request

DELETE/api/v2/calendars/{calendar_id}/appointments/remote_id:{appointment_remote_id}

Bulk creation or update of appointments

curl -XPOST "https://progenda.be/api/v2/calendars/{calendar_id}/appointments_collections?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"
{
  "appointments_collection": {
    "appointments": [
      {
        "appointment": {
          "id": "57",
          "remote_id": "8401",
          "patient_remote_id": "104"
        }
      },
      {
        "appointment": {
          "id": "58",
          "remote_id": "8402",
          "patient_remote_id": "80"
        }
      }
    ]
  }
}

Example Response

{
  "appointments": [
    {
      "appointment": {
        "id": "57",
        "remote_id": "8401",
        "start": "1417682400",
        "stop": "1417683600",
        "notes": false,
        "warning": false,
        "color": "#101010",
        "title": "",
        "status": "booked",
        "patient_id": "16",
        "patient_remote_id": "104",
        "service_remote_id": "xyz",
        "noshow": false,
        "patient_arrived_at": null
      }
    }
  ]
}

Processes the collection of appointments by creating them or updating them if the provided ID or remote ID already exist in our appointment database.

HTTP Request

POST/api/v2/calendars/{calendar_id}/appointments_collections

Body Parameters

Parameter Details Description
appointments_collection[appointments][appointment][id] string, optional Progenda identifier for the appointment.
appointments_collection[appointments][appointment][remote_id] string, optional Your identifier for the appointment.
appointments_collection[appointments][appointment][patient_remote_id] string, optional Your identifier for the patient of the appointment.
appointments_collection[appointments][appointment][start] timestamp, optional The time of the appointment start.
appointments_collection[appointments][appointment][stop] timestamp, optional The time of the appointment end.
appointments_collection[appointments][appointment][notes] string, optional Personal notes about the appointment.
appointments_collection[appointments][appointment][color] string formatted as #xxyyzz, optional Color of the appointment on the user’s interface.
appointments_collection[appointments][appointment][title] string, optional Title of the appointment (e.g. Meeting, Lunch, Break)
appointments_collection[appointments][appointment][status] string, optional (must be one of : “booked”, “cancelled” or “noshow”) Status of the appointment. A “cancelled” appointment cannot become “booked” again. Allows bulk deletion of appointments.
appointments_collection[appointments][appointment][service_remote_id] string, optional Your identifier for the appointment type of the appointment.
appointments_collection[appointments][appointment][patient_arrived_at] timestamp, optional Time of arrival of the patient for this appointment. If null, the patient has not arrived yet.
appointments_collection[appointments][appointment][noshow] boolean, optional Set to true if the patient missed his appointment. Defaults to false.

Services (appointment types)

List all services

curl "https://progenda.be/api/v2/calendars/{calendar_id}/services?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"

Example Response

{
  "services": [
    {
      "service": {
        "id": 32,
        "remote_id": "abc",
        "duration": 60,
        "name": "Long appointment",
        "color": "#FF0000"
      }
    }
  ]
}

Returns a list of the services belonging to the calendar.

HTTP Request

GET/api/v2/calendars/{calendar_id}/services

Bulk creation or update of services

curl -XPOST "https://progenda.be/api/v2/calendars/{calendar_id}/services_collections?user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"
{
  "services_collection": {
    "services": [
      {
        "service": {
          "id": 32,
          "remote_id": "abc",
          "duration": 60,
          "name": "Long appointment",
          "color": "#FF0000"
        }
      },
      {
        "service": {
          "id": 33,
          "remote_id": "xyz",
          "duration": 30,
          "name": "Short appointment",
          "color": "#00FF00"
        }
      }
    ]
  }
}

Example Response

{
  "services": [
    {
      "service": {
        "id": 33,
        "remote_id": "xyz",
        "duration": 30,
        "name": "Short appointment",
        "color": "#00FF00"
      }
    }
  ]
}

Processes the collection of services by creating them or updating them if the provided ID or remote ID already exist in our service database.

HTTP Request

POST/api/v2/calendars/{calendar_id}/services_collections

Body Parameters

Parameter Details Description
services_collection[services][service][id] string, optional Progenda identifier for the service.
services_collection[services][service][remote_id] string, optional Your identifier for the service.
services_collection[services][service][name] string, required Name of the service
services_collection[services][service][duration] integer, required Duration of the service (in minutes)
services_collection[services][service][color] string formatted as #xxyyzz, optional Color of the service on the user’s interface.

Suggestions

Compute suggestions for a calendar

curl "https://progenda.be/api/v2/suggestions?calendar_id=1&service_id=3&user_email={user_email}&user_token={user_token}"
  -H "Accept: application/json"
  -H "Content-Type: application/json"

Example Response

{
  "suggestions": [
    {
      "suggestion": {
        "calendar_id": 1,
        "service_id": 3,
        "start": "2018-02-12T10:00:00+01:00",
        "stop": "2018-02-12T10:20:00+01:00"
      }
    }
  ]
}

Returns a list of the computed suggestions for the calendar with the provided service.

HTTP Request

GET/api/v2/suggestions?calendar_id={calendar_id}&service_id={service_id}