EMS (Extra-Mural Studies) API documentation

JSON-RPC calls

RPC calls must be submitted as POST requests to the RPC endpoint, located at: https://ems-api.rcvs.org.uk/json-rpc/.

The request body must be a valid JSON string, taking the form:

{
    "id": /* optional: number */,
    "jsonrpc": "2.0",
    "method": "namespace.methodName",
    "params": /* optional: array or object */
}

If provided, "id" must be a positive integer. This will be included in the response. If no "id" property is included in the request, the call will not return a response.

Where appropriate for the method called, "params" can be supplied either as an array of positional arguments or an object (collection of key/value pairs). If passed as an array, the ordering of the arguments must match their order in the method signature. If passed as an object, the naming of the keys must match the param names in the method signature, but the order is not important.

// Method signature:
// user.authenticate(username: str, password: str)

// Valid requests to this method may pass the two arguments in an array:
{
    "id": 1,
    "jsonrpc": "2.0",
    "method": "user.authenticate",
    "params": ["EmilyJones", "my_passw0rd"]
}

// ... or in an object:
{
    "id": 2,
    "jsonrpc": "2.0",
    "method": "user.authenticate",
    "params": {"password": "my_passw0rd", "username": "EmilyJones"}
}

When an "id" property is provided in the request, the API will send a response in the following format:

{
    "id": /* number */,
    "jsonrpc": "2.0",
    "result": /* any permitted JSON value */
}

If the request could not be handled successfully, the API will send an error response in the following format (for a list of error codes, see the JSON-RPC specification):

{
    "error": {
        "code": /* number */,
        "data": /* optional: any permitted JSON value */,
        "message": /* text */
    }
    "id": /* number */,
    "jsonrpc": "2.0",
}

JSON-RPC methods

Methods are grouped by a 'namespace' prefix.

booking.acceptBooking(booking_id, message, kwargs)

JSON-RPC

Accept an EMS placement booking request.

The booking_id argument is required.

There is no response.

An error is returned if the current booking status is not 'requested' or if the API user has no role association with the placement provider.

Parameters:
  • booking_id (UUID | str) - A unique identifier for the booking
  • message (str | None) - An optional message that will be sent to the student
  • kwargs (Any) - Internal data
Return:
  • None -

booking.approveBooking(booking_id, message, message_to_provider, message_to_student, kwargs)

JSON-RPC

Approve an EMS placement booking.

The booking_id argument is required.

provider.

There is no response.

An error is returned if the current booking status is not 'accepted' or if the API user has no tutor role association with the student's vet school.

Parameters:
  • booking_id (UUID | str) - A unique identifier for the booking
  • message (str | None) - An optional shared message that will be sent to the student and
  • message_to_provider (str | None) - An optional message that will be sent to the provider.
  • message_to_student (str | None) - An optional message that will be sent to the student.
  • kwargs (Any) - Internal data
Return:
  • None -

booking.assignBooking(booking_id, tutor_id, kwargs)

JSON-RPC

Assign an EMS placement booking to a tutor (or remove an assignment).

The booking_id and tutor_id arguments are required, but the latter can be None.

There is no response.

An error is returned if the current booking status is not 'accepted' or if the API user has no tutor role association with the student's vet school.

Parameters:
  • booking_id (UUID | str) - A unique identifier for the booking
  • tutor_id (UUID | str | None) - A unique identifier for the tutor or None if the intention is to remove an existing assignment.
  • kwargs (Any) - Internal data
Return:
  • None -

booking.cancelBooking(booking_id, role_id, message, message_to_provider, message_to_student, kwargs)

JSON-RPC

Cancel an EMS placement booking request.

The booking_id and role_id arguments is required. Either message or *both* message_to_student and message_to_provider are required.

There is no response.

An error is returned if the current booking status is not 'requested', 'accepted' or 'approved' or of the API user does not hold the role indicated by role_id.

Parameters:
  • booking_id (UUID | str) - A unique identifier for the booking
  • role_id (str) - The capacity in which the API user is requesting this cancellation; either "student", "provider", "tutor" or "admin".
  • message (str | None) - A shared message that will be sent to the student and vet school (if booking is cancelled by provider) or provider and vet school (if booking is cancelled by student) or student and provider (if booking is cancelled by tutor).
  • message_to_provider (str | None) - A message that will be sent to the provider (when booking is cancelled by tutor).
  • message_to_student (str | None) - A message that will be sent to the student (when booking is cancelled by tutor).
  • kwargs (Any) - Internal data
Return:
  • None -

booking.createBooking(placement_type_id, provider_id, values, requested, kwargs)

JSON-RPC

Creates an EMS placement booking and returns the details.

The placement_type_id, provider_id and values arguments are required.

Parameters:
  • placement_type_id (str) - Either "animal_husbandry_ems" or "clinical_ems"
  • provider_id (UUID | str) - A unique identifier for the placement provider
  • values (dict) - A collection of key/value pairs (object) representing the values of fields to be set on the booking instance. All fields are optional.
  • requested (bool | None) - True if the booking should be submitted to the provider at the end of the update (optional; default is False).
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) representing the details of the saved booking

booking.declineBooking(booking_id, message, kwargs)

JSON-RPC

Decline an EMS placement booking request.

The booking_id argument is required.

There is no response.

An error is returned if the current booking status is not 'requested' or if the API user has no role association with the placement provider.

Parameters:
  • booking_id (UUID | str) - A unique identifier for the booking
  • message (str | None) - An optional message that will be sent to the student
  • kwargs (Any) - Internal data
Return:
  • None -

booking.deleteBooking(booking_id, kwargs)

JSON-RPC

Delete a 'draft' EMS placement booking.

The booking_id argument is required.

There is no response.

An error is returned if the current booking status is not 'draft' or if the API user is not the student who created the booking.

Parameters:
  • booking_id (UUID | str) - A unique identifier for the booking
  • kwargs (Any) - Internal data
Return:
  • None -

booking.getBooking(booking_id, kwargs)

JSON-RPC

Returns details of an EMS placement booking.

The argument is required.

Parameters:
  • booking_id (UUID | str) - A unique identifier for the booking
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs representing the booking details

booking.getConversations(booking_id, role_id, kwargs)

JSON-RPC

Returns any existing conversations related to the booking in which the given role is a participant.

Both arguments are required.

Parameters:
  • booking_id (UUID | str) - A unique identifier for the booking
  • role_id (str) - The capacity in which the API user is participating in any conversations; either "student", "provider" or "tutor".
  • kwargs (Any) - Internal data
Return:
  • list - An array of booking conversations (object)

booking.updateBooking(booking_id, values, requested, kwargs)

JSON-RPC

Updates an EMS placement booking and returns the new details.

The booking_id and values arguments are required.

Parameters:
  • booking_id (UUID | str) - A unique identifier for the booking
  • values (dict) - A collection of key/value pairs (object) representing the new values of fields to be set on the booking instance. All fields are optional. The values of any omitted fields will not be altered.
  • requested (bool | None) - True if the booking should be submitted to the provider at the end of the update (optional; default is False).
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) representing the updated details of the booking

booking.updateBookingDates(booking_id, dates, kwargs)

JSON-RPC

Updates the dates for an EMS placement booking and returns the new details.

This method can only be used if the booking status is requested, declined, accepted or approved. If the date values provided are different from the ones currently saved, the saved dates will be replaced and the booking status will be reset to 'requested'.

The booking_id and dates arguments are required.

Parameters:
  • booking_id (UUID | str) - A unique identifier for the booking
  • dates (list) - An array of date objects to replace the existing dates that are linked to the booking.
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) representing the updated details of the booking

conversation.markRead(conversation_id, role_id, kwargs)

JSON-RPC

Marks all messages in a booking conversation as 'read' by the relevant role.

Both params are required.

There is no response.

Parameters:
  • conversation_id (UUID | str) - A unique identifier for the booking conversation
  • role_id (str) - The capacity in which the API user is participating in the conversation; either "student", "provider" or "tutor".
  • kwargs (Any) - Internal data
Return:
  • None -

conversation.sendMessage(body, conversation_id, role_id, kwargs)

JSON-RPC

Posts a message to an existing booking conversation in which the given role is a participant.

All arguments are required.

There is no response.

Parameters:
  • body (str) - The text of the message
  • conversation_id (UUID | str) - A unique identifier for the booking conversation
  • role_id (str) - The capacity in which the API user is participating in any conversations; either "student", "provider" or "tutor".
  • kwargs (Any) - Internal data
Return:
  • None -

data.getEmailFrequencies(role_id, order_by)

JSON-RPC

Returns an array of email frequency options that may be offered to EMS users.

Both arguments are optional.

Parameters:
  • role_id (str | None) - Either "provider", "student", "tutor" or None. If supplied, results will be filtered to only include the relevant options.
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "sequence, name").
Return:
  • list - An array of 'email frequency' options (object)

data.getEmailTriggers(role_id, order_by)

JSON-RPC

Returns an array of email triggers that may be enabled by EMS users.

Both arguments are optional.

Parameters:
  • role_id (str | None) - Either "provider", "student", "tutor" or None. If supplied, results will be filtered to only include the relevant options.
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "sequence, name").
Return:
  • list - An array of 'email trigger' options (object)

data.getFacilities(order_by)

JSON-RPC

Returns an array of facilities that may be offered by placement providers.

The order_by argument is optional.

Parameters:
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "sequence, name").
Return:
  • list - An array of 'facility' options (object)

data.getLocations(order_by)

JSON-RPC

Returns an array of cities and counties in the UK.

The order_by argument is optional.

Parameters:
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "name").
Return:
  • list - An array of 'location' options (object)

data.getMaxDistances(order_by)

JSON-RPC

Returns an array of 'max distance' options for location-based searches.

The order_by argument is optional.

Parameters:
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "value").
Return:
  • list - An array of 'max distance' options (object)

data.getOtherOptions(order_by)

JSON-RPC

Returns an array of 'other options' that may be applied in 'advanced search'.

The order_by argument is optional.

Parameters:
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "sequence, name").
Return:
  • list - An array of 'other options' (object)

data.getPremisesTypes(placement_type_id, order_by)

JSON-RPC

Returns an array of premises types.

Both arguments are optional.

Parameters:
  • placement_type_id (str | None) - Either "animal_husbandry_ems", "clinical_ems" or None. If supplied, results will be filtered to only include the relevant values.
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "sequence, name").
Return:
  • list - An array of 'premises type' options (object)

data.getProcedures(order_by)

JSON-RPC

Returns an array of procedures that may be offered by placement providers.

The order_by argument is optional.

Parameters:
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "sequence, name").
Return:
  • list - An array of 'procedure' options (object)

data.getSpecies(order_by)

JSON-RPC

Returns an array of species that may be treated by a placement provider.

The order_by argument is optional.

Parameters:
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "sequence, name").
Return:
  • list - An array of 'species' options (object)

data.getSpeciesByType(species_type_id, order_by)

JSON-RPC

Returns an array of all species types, or a one-member array if a valid species_type_id argument is provided.

Each species type object includes "children": an array of the species associated with the species type.

Both arguments are optional.

Parameters:
  • species_type_id (str | None) - A string identifying a single species type
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "sequence, name").
Return:
  • list - An array of 'species type' objects - either one or all - each containing an array of species objects with the key "children"

data.getSpeciesTypes(order_by)

JSON-RPC

Returns an array of species types that may be treated by a placement provider.

The order_by argument is optional.

Parameters:
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "sequence, name").
Return:
  • list - An array of 'species type' options (object)

data.getStockImages(order_by)

JSON-RPC

Returns an array of stock images available for use in provider profiles.

The order_by argument is optional.

Parameters:
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "sequence, name").
Return:
  • list - An array of 'stock image' options (object)

data.getYearsOfStudy(vet_school_id, order_by)

JSON-RPC

Returns an array of years of study that can be selected in a booking request.

Both arguments are optional.

Parameters:
  • vet_school_id (UUID | str | None) - An optional param to fetch only those years of study that apply at a given vet school (default is to return all potential years).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "sequence, name").
Return:
  • list - An array of 'year of study' options (object)

document.createDocument(document_type_id, values, kwargs)

JSON-RPC

Creates a document from the supplied values and returns the details.

Both arguments are required.

Parameters:
  • document_type_id (str) - The type of document to be created.
  • values (dict) - A collection of key/value pairs (object) representing the values of fields to be set on the document instance. All fields are optional. The values of any omitted fields will not be altered.
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) representing the details of the saved document

document.createVersion(document_id, values, kwargs)

JSON-RPC

Creates a document version from the supplied values and returns the details.

Both arguments are required.

Parameters:
  • document_id (UUID | str) - A unique identifier for the parent document.
  • values (dict) - A collection of key/value pairs (object) representing the values of fields to be set on the document version instance. All fields are optional. The values of any omitted fields will not be altered.
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) representing the details of the saved document version

document.deleteDocument(document_id, kwargs)

JSON-RPC

Delete a specified Document from the database.

The document_id argument is required.

There is no response.

Parameters:
  • document_id (UUID | str) - A unique identifier for the document.
  • kwargs (Any) - Internal data
Return:
  • None -

document.deleteVersion(version_id, kwargs)

JSON-RPC

Delete a specified Document Version from the database.

The version_id argument is required.

There is no response.

Parameters:
  • version_id (UUID | str) - A unique identifier for the document version.
  • kwargs (Any) - Internal data
Return:
  • None -

document.getConsentAgreement()

JSON-RPC

Return an object with details of the current EMS user consent agreement.

Return:
  • dict - A collection of key/value pairs (object) with the title, HTML and other details of the consent agreement.

document.getDocument(document_id, kwargs)

JSON-RPC

Return an object with details of a Document.

The document_id argument is required.

Parameters:
  • document_id (UUID | str) - A unique identifier for the document.
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) with the title and other details of the document.

document.getListOfDocuments(editor_id, page_number, page_size, order_by, kwargs)

JSON-RPC

Return a paginated list of documents.

All arguments are optional.

Parameters:
  • editor_id (UUID | str | None) - An optional filter, taking the unique identifier of the admin user who created or last modified a document.
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "-created").
  • kwargs (Any) - Internal data
Return:
  • dict - A page object, containing an array ('items') of documents (object).

document.getListOfVersions(document_id, editor_id, version_status_ids, page_number, page_size, order_by, kwargs)

JSON-RPC

Return a paginated list of document versions.

The document_id argument is required.

Parameters:
  • document_id (UUID | str) - A unique identifier for the parent document.
  • editor_id (UUID | str | None) - An optional filter, taking the unique identifier of the admin user who created or last modified a document.
  • version_status_ids (list[str] | None) - An optional filter with a list of version statuses, restricting the results to versions whose status is included in this list if applied. Permitted values to include: "draft", "public" and/or "archived".
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "-created").
  • kwargs (Any) - Internal data
Return:
  • dict - A page object, containing an array ('items') of documents (object).

document.getVersion(version_id, kwargs)

JSON-RPC

Return an object with details of a DocumentVersion.

The version_id argument is required.

Parameters:
  • version_id (UUID | str) - A unique identifier for the document version.
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) with the title and other details of the document version.

document.updateDocument(document_id, values, kwargs)

JSON-RPC

Updates the stored details of a document from the supplied values and returns the new details.

Both arguments are required.

Parameters:
  • document_id (UUID | str) - A unique identifier for the document
  • values (dict) - A collection of key/value pairs (object) representing the new values of fields to be set on the document instance. All fields are optional. The values of any omitted fields will not be altered.
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) representing the updated details of the document

document.updateVersion(version_id, values, kwargs)

JSON-RPC

Updates the stored details of a document version from the supplied values and returns the new details.

Both arguments are required.

Parameters:
  • version_id (UUID | str) - A unique identifier for the document version
  • values (dict) - A collection of key/value pairs (object) representing the new values of fields to be set on the document version instance. All fields are optional. The values of any omitted fields will not be altered.
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) representing the updated details of the document version

provider.applyBar(provider_id, kwargs)

JSON-RPC

Bar a placement provider's profile.

The provider_id argument is required.

There is no response.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider
  • kwargs (Any) - Internal data
Return:
  • None -

provider.cancelActiveBookings(provider_id, kwargs)

JSON-RPC

Cancel all active bookings at a placement provider.

The provider_id argument is required.

There is no response.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider
  • kwargs (Any) - Internal data
Return:
  • None -

provider.getBooking(booking_id, kwargs)

JSON-RPC

Returns details of an EMS placement booking sent to the provider.

Unlike booking.getBooking, this method is aimed exclusively at EMS provider users. The student and vet school data will be omitted if the provider has not accepted a booking from the student.

The argument is required.

Parameters:
  • booking_id (UUID | str) - A unique identifier for the booking
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs representing the booking details

provider.getBookingsByDates(provider_id, booking_id, dates, placement_type_ids, status_ids, kwargs)

JSON-RPC

Returns a specified array of dates, today or in the future, each including a 'bookings_count' and 'bookings' array listing a provider's 'active' EMS bookings on that date. (Only bookings that are either requested, accepted or approved will be included in the 'bookings' array.)

It is mandatory to include the ``provider_id`` param and to specify either ``booking_id`` or ``dates``. Do not include both ``booking_id`` and ``dates`` (this will return an error).

If a ``booking_id`` is provided, the dates returned will be the dates within that booking and the specified booking will be excluded from the 'bookings' array for each date (in other words, only bookings that clash with the specified booking will be listed).

Otherwise, provide an array of ``dates`` to specify the desired calendar dates.

Other params are optional filters that can be used to restrict the bookings returned.

Results are always ordered by date. Any nested 'booking' arrays are ordered by booking reference.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider (required).
  • booking_id (UUID | str | None) - Limits the results to the dates of the specified booking and excludes the specified booking from the booking data for each date.
  • dates (list[str] | None) - Limits the results to the specified dates.
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • status_ids (list[str] | None) - An optional filter with a list of statuses, restricting the results to bookings whose status is included in this list if applied. Permitted values to include: "requested", "accepted" and/or "approved".
  • kwargs (Any) - Internal data
Return:
  • list - An array of calendar dates (object) containing a 'bookings_count' (int) and an array of requested, accepted and approved bookings on that date.

provider.getCalendar(provider_id, date_from, date_to, placement_type_ids, status_ids, year, kwargs)

JSON-RPC

Returns an array of calendar dates, today or in the future, with details of any capacity for placement bookings that has been configured by an EMS placement provider, combined with a breakdown of bookings received by that provider that are either requested, accepted or approved.

The provider_id argument is required.

A date range may be specified, either by a combination of 'date_from' and 'date_to' or by a 'year' value.

Other params are optional.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider (required).
  • date_from (datetime.date | None) - In combination with date_to, limits the calendar to the specified range (inclusive of both dates).
  • date_to (datetime.date | None) - In combination with date_from, limits the calendar to the specified range (inclusive of both dates).
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • status_ids (list[str] | None) - An optional filter with a list of statuses, restricting the results to bookings whose status is included in this list if applied. Permitted values to include: "requested", "accepted" and/or "approved".
  • year (int | None) - The year selected for viewing booking data (alternative to specifying both date_from and date_to).
  • kwargs (Any) - Internal data
Return:
  • list - An array of calendar dates (object), with statistics for placement offerings and active bookings.

provider.getDeclarationVersions(provider_id, kwargs)

JSON-RPC

Returns an object keyed by declaration type with values of ``null`` (if the declaration type is not relevant to the provider) or an object containing an array of declaration versions, each enclosing their associated signatures.

The provider_id argument is required.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider
  • kwargs (Any) - Internal data
Return:
  • dict - An object keyed with "ahems_declaration" and "cems_declaration", each mapped either to null or to a nested object containing an array of declaration versions (object) with nested arrays of provider signatures (object).

provider.getListOfBookings(provider_id, keywords, placement_type_ids, status_ids, tab_id, page_number, page_size, order_by, kwargs)

JSON-RPC

Returns an array of summary details for EMS booking requests that have been submitted to a placement provider.

The provider_id argument is required.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider (required).
  • keywords (str | None) - An optional search string of one or more keywords.
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • status_ids (list[str] | None) - An optional filter with a list of statuses, restricting the results to bookings whose status is included in this list if applied. Permitted values to include: "draft", "requested", "declined", "accepted", "approved" and/or "cancelled".
  • tab_id (str | None) - An optional filter for splitting bookings into two lists on the EMS interface: either "active", "inactive" or "upcoming".
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "start_date, reference").
  • kwargs (Any) - Internal data
Return:
  • dict - An array of booking requests (object) containing the key details required for displaying a listing of bookings.

provider.getListOfConversations(provider_id, read_status_id, page_number, page_size, order_by, kwargs)

JSON-RPC

Returns a paginated list of booking conversations, forming the provider's 'messages home'.

The provider_id argument is required.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider (required)
  • read_status_id (str | None) - An optional filter, either "read", "unread" or "all".
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "-last_updated").
  • kwargs (Any) - Internal data
Return:
  • dict -

provider.getListOfMessages(provider_id, keywords, placement_type_ids, read_status_id, sender_role_ids, page_number, page_size, order_by, kwargs)

JSON-RPC

Returns a paginated list of booking conversations in which the provider is a participant.

The provider_id argument is required.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider (required).
  • keywords (str | None) - An optional search string of one or more keywords.
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • read_status_id (str | None) - An optional filter, either "read", "unread" or "all".
  • sender_role_ids (list[str] | None) - An optional filter with a list of sender roles, restricting the results to messages whose sender type is included in this list if applied. Permitted values to include: "provider", "student" and/or "tutor".
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "-sent").
  • kwargs (Any) - Internal data
Return:
  • dict - A page object, containing an array of booking conversations (object).

provider.getListOfProviderAvailability(placement_type_id, search_type_id, provider_name, provider_location, date_from, date_until, location, postcode, postcode_latitude, postcode_longitude, distance_value, species_types, advanced_search, image_size_id, page_number, page_size, order_by, kwargs)

JSON-RPC

Returns an array of placement provider details matching the search criteria, including details of their calendar availability for EMS placement bookings.

The placement_type_id and search_type_id arguments are mandatory. All other arguments are optional.

Parameters:
  • placement_type_id (str) - Determines the scope of the search. Must be specified - either "animal_husbandry_ems" or "clinical_ems".
  • search_type_id (str) - Determines which arguments are relevant to the query. Must be specified - either "by_date" or "by_provider".
  • provider_name (str | None) - If provided, returns "public" provider profiles where the entered value is a substring of the provider name and "hidden" provider profiles where the name is an exact match for the entered value (search_type: "by_provider").
  • provider_location (str | None) - If provided, returns "public" providers profiles where a match for the entered value is found within the full text of the address (search_type: "by_provider").
  • date_from (datetime.date | None) - Must be combined with "date_until". Limits results to providers who have indicated placement availability within the given date range (search_type: "by_date").
  • date_until (datetime.date | None) - Must be combined with "date_from". Limits results to providers who have indicated placement availability within the given date range (search_type: "by_date").
  • location (int | None) - Takes the ID of a UK city or county from the UkLocation table. When combined with "distance_value", limits results to providers whose geographic location is within the given range of proximity to a point assigned to the given location (search_type: "by_date").
  • postcode (str | None) - Takes a UK postcode. Ignored if "postcode_latitude" and "postcode_longitude" are supplied. When combined with "distance_value", limits results to providers whose geographic location is within the given range of proximity to a point assigned to the given postcode (search_type: "by_date").
  • postcode_latitude (float | None) - Takes a geographic latitude (degrees). Ignored unless combined with "postcode_longitude". When combined with "distance_value", limits results to providers whose geographic location is within the given range of proximity to the specified geographic point. Takes precedence over "location" if the latter argument is also supplied (search_type: "by_date").
  • postcode_longitude (float | None) - Takes a geographic longitude (degrees). Ignored unless combined with "postcode_latitude". When combined with "distance_value", limits results to providers whose geographic location is within the given range of proximity to the specified geographic point. Takes precedence over "location" if the latter argument is also supplied (search_type: "by_date").
  • distance_value (int | None) - The max distance in kilometres from the "location" point to the provider's location. Ignored unless either "location" or a combination of "postcode_latitude" and "postcode_longitude" are given. Results are filtered to fall within a circle centred on the location, whose radius equals distance_value (search_type: "by_date").
  • species_types (dict[str, bool] | None) - A dictionary whose keys are the set of species_type IDs with value True if the option was selected in the search and False otherwise. If provided, limits results to those providers tagged with any one of the selected species_type values (search_type: "by_date").
  • advanced_search (dict[str, dict[str, bool]] | None) - A dictionary with the keys "facilities", "other_options", "premises_types", "procedures" and "species", each mapped to a dictionary object whose keys list all the available options in that category with the value True if option was selected in the search and False otherwise. Restricts results to providers who match *one* of the selected options in the case of "premises_types" and "species" or *all* of the selected options for the remaining categories (search_type: "by_date" or "by_provider").
  • image_size_id (str | None) - Determines which version (if any) of the profile image will be returned - either "small", "medium", "large" or "none" (default: "large").
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "name").
  • kwargs (Any) - Internal data
Return:
  • dict - An object with a total count for the list, pagination details and an array of placement provider details (object).

provider.getListOfProviders(provider_name, provider_location, provider_imis_id, page_number, page_size, order_by, kwargs)

JSON-RPC

Returns an array of placement provider details matching the search criteria, regardless of their profile status.

At least one of provider_name, provider_location or provider_imis_id must be provided. All other arguments are optional.

Parameters:
  • provider_name (str | None) - If provided, returns provider details where the the provider name contains at least one of the entered terms.
  • provider_location (str | None) - If provided, returns provider details where the the provider address details contain at least one of the entered terms.
  • provider_imis_id (str | None) - If provided, returns provider details where the the provider's iMIS ID matches the entered term.
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "name").
  • kwargs (Any) - Internal data
Return:
  • dict - An object with a total count for the list, pagination details and an array of placement provider details (object).

provider.getProvider(provider_id, image_size_id, kwargs)

JSON-RPC

Returns an object containing details of a placement provider.

The provider_id argument is required.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider
  • image_size_id (str | None) - Determines which version (if any) of the profile image will be returned - either "small", "medium", "large" or "none" (default: "large").
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) representing the details of the provider

provider.removeBar(provider_id, kwargs)

JSON-RPC

Remove a bar from a placement provider's profile.

The provider_id argument is required.

There is no response.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider
  • kwargs (Any) - Internal data
Return:
  • None -

provider.reportProfile(provider_id, report_details, kwargs)

JSON-RPC

Submits a report about inappropriate content in a placement provider's profile. The report is logged in the EMS database and an email notification is sent to the EMS admin inbox.

Both arguments are required.

There is no response.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider
  • report_details (str) - The details of the issue being reported
  • kwargs (Any) - Internal data
Return:
  • None -

provider.signDeclaration(declaration_agreed, declaration_version_id, provider_id, signed_by_id, kwargs)

JSON-RPC

Records a signature of an EMS provider declaration by the current user on behalf of the provider.

All arguments are required.

additional verification of the signature)

There is no response.

Parameters:
  • declaration_agreed (bool) - Confirms agreement to the text of the declaration
  • declaration_version_id (UUID | str) - A unique identifier for the declaration version
  • provider_id (UUID | str) - A unique identifier for the placement provider
  • signed_by_id (UUID | str) - A unique identifier for the current API user (required as an
  • kwargs (Any) - Internal data
Return:
  • None -

provider.updateCalendar(provider_id, calendar, kwargs)

JSON-RPC

Updates the set of calendar dates on which an EMS placement provider is available for placement bookings.

Both arguments are required.

There is no response.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider
  • calendar (list) - An array of provider date details
  • kwargs (Any) - Internal data
Return:
  • None -

provider.updateImage(provider_id, large_image_data_url, medium_image_data_url, small_image_data_url, kwargs)

JSON-RPC

Updates the profile image data for a placement provider.

All arguments are required.

There is no response.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider
  • large_image_data_url (str) - A data URL for a large version of the profile image.
  • medium_image_data_url (str) - A data URL for a medium version of the profile image.
  • small_image_data_url (str) - A data URL for a small version of the profile image.
  • kwargs (Any) - Internal data
Return:
  • None -

provider.updateProvider(provider_id, values, kwargs)

JSON-RPC

Updates the stored details of a placement provider from the supplied values. Returns the new details for the provider.

Both arguments are required.

Parameters:
  • provider_id (UUID | str) - A unique identifier for the placement provider
  • values (dict) - A collection of key/value pairs (object) representing the new values of fields to be set on the provider instance. All fields are optional. The values of any omitted fields will not be altered.
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) representing the updated details of the provider

system.listMethods(kwargs)

JSON-RPC XML-RPC

Returns a list of all methods available in the current entry point

Parameters:
  • kwargs
No documentation available yet

system.methodHelp(method_name, kwargs)

JSON-RPC XML-RPC

Returns the documentation of the given method name.

Parameters:
  • method_name Name of a method available for current entry point (and protocol)
  • kwargs :return: Documentation text for the RPC method
Return:
  • Documentation text for the RPC method

system.methodSignature(method_name, kwargs)

JSON-RPC XML-RPC

Returns an array describing the signature of the given method name.

The result is an array with: - Return type as first elements - Types of method arguments from element 1 to N

Parameters:
  • method_name Name of a method available for current entry point (and protocol)
  • kwargs :return: An array of arrays describing types of return values and method arguments
Return:
  • An array of arrays describing types of return values and method arguments

system.multicall(calls, kwargs)

XML-RPC

Call multiple RPC methods at once.

Parameters:
  • calls An array of struct like {"methodName": string, "params": array }
  • kwargs Internal data
No documentation available yet

user.authenticate(username, password, kwargs)

JSON-RPC

Returns an authentication token if the user's credentials are valid.

Both arguments are required.

Parameters:
  • username (str) - A string associated with the user's account
  • password (str) - A string used to validate login requests
  • kwargs (Any) - Internal data
Return:
  • dict - A freshly issued authentication token for the user, inserted in an "authorization_header" string, and the ID of the logged-in user, with the key "user_id"

user.getAccessCode(email, kwargs)

JSON-RPC

Triggers an email message to the user containing a random six-digit number that can be used to verify the user's email address.

The email argument is required.

There is no response.

Parameters:
  • email (str) - The user's email address
  • kwargs (Any) - Internal data
Return:
  • None -

user.getBookingsByDates(booking_id, dates, placement_type_ids, provider_id, status_ids, kwargs)

JSON-RPC

Returns a specified array of dates, today or in the future, each including a 'bookings_count' and 'bookings' array listing a user's 'active' EMS bookings on that date. (Only bookings that are either requested, accepted or approved will be included in the 'bookings' array.)

It is mandatory to specify either ``booking_id`` or ``dates``. Do not include both ``booking_id`` and ``dates`` (this will return an error).

If a ``booking_id`` is provided, the dates returned will be the dates within that booking and the specified booking will be excluded from the 'bookings' array for each date (in other words, only bookings that clash with the specified booking will be listed).

Otherwise, provide an array of ``dates`` to specify the desired calendar dates.

Other params are optional filters that can be used to restrict the bookings returned.

Results are always ordered by date. Any nested 'booking' arrays are ordered by booking reference.

Parameters:
  • booking_id (UUID | str | None) - Limits the results to the dates of the specified booking and excludes the specified booking from the booking data for each date.
  • dates (list[str] | None) - Limits the results to the specified dates.
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • provider_id (UUID | str | None) - An optional filter, taking the unique identifier for the EMS placement provider.
  • status_ids (list[str] | None) - An optional filter with a list of statuses, restricting the results to bookings whose status is included in this list if applied. Permitted values to include: "requested", "accepted" and/or "approved".
  • kwargs (Any) - Internal data
Return:
  • list - An array of calendar dates (object) containing a 'bookings_count' (int) and an array of requested, accepted and approved bookings on that date.

user.getCalendar(date_from, date_to, placement_type_ids, provider_id, status_ids, year, kwargs)

JSON-RPC

Returns an array of calendar dates, today or in the future, with a breakdown of a user's EMS bookings on each date that are either requested, accepted or approved.

A date range may be specified, either by a combination of 'date_from' and 'date_to' or by a 'year' value.

All params are optional.

Parameters:
  • date_from (datetime.date | None) - In combination with date_to, limits the calendar to the specified range (inclusive of both dates).
  • date_to (datetime.date | None) - In combination with date_from, limits the calendar to the specified range (inclusive of both dates).
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • provider_id (UUID | str | None) - An optional filter, taking the unique identifier for the EMS placement provider.
  • status_ids (list[str] | None) - An optional filter with a list of statuses, restricting the results to bookings whose status is included in this list if applied. Permitted values to include: "requested", "accepted" and/or "approved".
  • year (int | None) - The year selected for viewing booking data (alternative to specifying both date_from and date_to).
  • kwargs (Any) - Internal data
Return:
  • list - An array of calendar dates (object) containing the counts for the user's requested, accepted and approved bookings on that date.

user.getListOfBookings(keywords, placement_type_ids, provider_id, status_ids, tab_id, page_number, page_size, order_by, kwargs)

JSON-RPC

Returns an array of summary details for EMS booking requests that have been submitted by the API user.

All arguments are optional.

Parameters:
  • keywords (str | None) - An optional search string of one or more keywords.
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • provider_id (UUID | str | None) - An optional filter, taking the unique identifier for the EMS placement provider.
  • status_ids (list[str] | None) - An optional filter with a list of statuses, restricting the results to bookings whose status is included in this list if applied. Permitted values to include: "draft", "requested", "declined", "accepted", "approved" and/or "cancelled".
  • tab_id (str | None) - An optional filter for splitting bookings into three lists on the EMS interface: either "active", "inactive", "saved" or "upcoming".
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "start_date, reference").
  • kwargs (Any) - Internal data
Return:
  • dict - A page object, containing an array of booking requests (object) with the key details required for displaying a listing of bookings.

user.getListOfConversations(read_status_id, page_number, page_size, order_by, kwargs)

JSON-RPC

Returns a paginated list of booking conversations, forming the student's 'messages home'

All params are optional.

Parameters:
  • read_status_id (str | None) - An optional filter, either "read", "unread" or "all".
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "-last_updated").
  • kwargs (Any) - Internal data
Return:
  • dict -

user.getListOfMessages(keywords, placement_type_ids, provider_id, read_status_id, sender_role_ids, page_number, page_size, order_by, kwargs)

JSON-RPC

Returns a paginated list of booking conversations in which the user is a participant.

All arguments are optional.

Parameters:
  • keywords (str | None) - An optional search string of one or more keywords.
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • provider_id (UUID | str | None) - An optional filter, taking the unique identifier for the EMS placement provider.
  • read_status_id (str | None) - An optional filter, either "read", "unread" or "all".
  • sender_role_ids (list[str] | None) - An optional filter with a list of sender roles, restricting the results to messages whose sender type is included in this list if applied. Permitted values to include: "provider", "student" and/or "tutor".
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "-sent").
  • kwargs (Any) - Internal data
Return:
  • dict - A page object, containing an array of booking conversations (object).

user.getUser(user_id, kwargs)

JSON-RPC

Returns details of a user.

The argument is required.

Parameters:
  • user_id (UUID | str) - A unique identifier for the user
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs representing the user details

user.getUserAssociations(user_id, order_by, kwargs)

JSON-RPC

Returns arrays of workplaces where the user has an admin role.

The user_id argument is required.

Parameters:
  • user_id (UUID | str) - A unique identifier for the user
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: name, id)
  • kwargs (Any) - Internal data
Return:
  • dict - an array of Providers (object) and an array of VetSchools (object)

user.logout(kwargs)

JSON-RPC

Logs the current user out of the system.

Calling this method destroys the token that was used to authorize the request, deletes any session data associated with the user and resets the request.user to be AnonymousUser.

There is no response.

Parameters:
  • kwargs (Any) - Internal data
Return:
  • None -

user.signConsentAgreement(consent_agreed, consent_agreement_version_id, kwargs)

JSON-RPC

Records a signature of an EMS user consent agreement by the current user.

All arguments are required.

There is no response.

Parameters:
  • consent_agreed (bool) - Confirms consent to the terms of the user agreement
  • consent_agreement_version_id (UUID | str) - A unique identifier for the agreement version
  • kwargs (Any) - Internal data
Return:
  • None -

user.updateUser(user_id, values, kwargs)

JSON-RPC

Returns an object containing details of a placement provider.

Both arguments are required.

Parameters:
  • user_id (UUID | str) - A unique identifier for the user
  • values (dict) - A collection of key/value pairs (object) representing the new values of fields to be set on the user instance. All fields are optional. The values of any omitted fields will not be altered.
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) representing the updated details of the user

user.verifyEmailAddress(code, email, kwargs)

JSON-RPC

Attempts to verify the user's email address with the numerical code provided. If both the email address and code match the most recent access code issued to the user and the email address matches the domain of the user's vet school, the email is stored as a persistent value in the user record and is flagged as verified.

Both arguments are required.

There is no response.

Parameters:
  • code (int) - The most recent access code issued for the user's email address
  • email (str) - The user's email address
  • kwargs (Any) - Internal data
Return:
  • None -

vetSchool.getBookingsByDates(student_id, vet_school_id, booking_id, dates, placement_type_ids, status_ids, kwargs)

JSON-RPC

Returns a specified array of dates, today or in the future, each including a 'bookings_count' and 'bookings' array listing a student's 'active' EMS bookings on that date. (Only bookings that are either requested, accepted or approved will be included in the 'bookings' array.)

It is mandatory to include both the ``student_id`` and ``vet_school_id`` params and to specify either ``booking_id`` or ``dates``. Do not include both ``booking_id`` and ``dates`` (this will return an error).

If a ``booking_id`` is provided, the dates returned will be the dates within that booking and the specified booking will be excluded from the 'bookings' array for each date (in other words, only bookings that clash with the specified booking will be listed).

Otherwise, provide an array of ``dates`` to specify the desired calendar dates.

Other params are optional filters that can be used to restrict the bookings returned.

Results are always ordered by date. Any nested 'booking' arrays are ordered by booking reference.

Parameters:
  • student_id (UUID | str) - A unique identifier for the student (required).
  • vet_school_id (UUID | str) - A unique identifier for the vet school (required).
  • booking_id (UUID | str | None) - Limits the results to the dates of the specified booking and excludes the specified booking from the booking data for each date.
  • dates (list[str] | None) - Limits the results to the specified dates.
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • status_ids (list[str] | None) - An optional filter with a list of statuses, restricting the results to bookings whose status is included in this list if applied. Permitted values to include: "requested", "accepted" and/or "approved".
  • kwargs (Any) - Internal data
Return:
  • list - An array of calendar dates (object) containing a 'bookings_count' (int) and an array of requested, accepted and approved bookings on that date.

vetSchool.getCalendar(vet_school_id, assigned, date_from, date_to, placement_type_ids, provider_id, status_ids, student_id, tutor_id, year, year_of_study_ids, kwargs)

JSON-RPC

Returns an array of calendar dates, today or in the future, with a breakdown of EMS bookings on each date that are either requested, accepted or approved. A tutor user can choose to see a breakdown of booking for all the vet school's students or to restrict the data to a particular student, a provider, or only bookings assigned to them. Bookings may also be filtered by placement type and/or status.

The vet_school_id argument is required.

A date range may be specified, either by a combination of 'date_from' and 'date_to' or by a 'year' value.

Other params are optional.

Parameters:
  • vet_school_id (UUID | str) - A unique identifier for the vet school (required).
  • assigned (bool | None) - An optional filter, for assigned bookings only (if true) or unassigned bookings only (if false).
  • date_from (datetime.date | None) - In combination with date_to, limits the calendar to the specified range (inclusive of both dates).
  • date_to (datetime.date | None) - In combination with date_from, limits the calendar to the specified range (inclusive of both dates).
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • provider_id (UUID | str | None) - An optional filter, taking the unique identifier for the EMS placement provider.
  • status_ids (list[str] | None) - An optional filter with a list of statuses, restricting the results to bookings whose status is included in this list if applied. Permitted values to include: "requested", "accepted", and/or "approved".
  • student_id (UUID | str | None) - An optional filter, taking the unique identifier for the student.
  • tutor_id (UUID | str | None) - An optional filter, for bookings assigned to the given tutor.
  • year (int | None) - The year selected for viewing booking data (alternative to specifying both date_from and date_to).
  • year_of_study_ids (list[str] | None) - An optional filter, taking a list of the students' year(s) of study (selected when making a booking), restricting results to those that match one of the included IDs.
  • kwargs (Any) - Internal data
Return:
  • list - An array of calendar dates (object) containing the counts for the user's requested, accepted and approved bookings on that date.

vetSchool.getListOfBookings(vet_school_id, assigned, keywords, placement_type_ids, provider_id, status_ids, student_id, tab_id, tutor_id, year_of_study_ids, page_number, page_size, order_by, kwargs)

JSON-RPC

Returns an array of summary details for EMS booking requests that have been submitted by students at a vet school.

The vet_school_id argument is required.

Parameters:
  • vet_school_id (UUID | str) - A unique identifier for the vet school (required).
  • assigned (bool | None) - An optional filter, for assigned bookings only (if true) or unassigned bookings only (if false).
  • keywords (str | None) - An optional search string of one or more keywords.
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • provider_id (UUID | str | None) - An optional filter, taking the unique identifier for the EMS placement provider.
  • status_ids (list[str] | None) - An optional filter with a list of statuses, restricting the results to bookings whose status is included in this list if applied. Permitted values to include: "draft", "requested", "declined", "accepted", "approved" and/or "cancelled".
  • student_id (UUID | str | None) - An optional filter, taking the unique identifier for the student.
  • tab_id (str | None) - An optional filter for splitting bookings into two lists on the EMS interface: either "active", "inactive" or "upcoming".
  • tutor_id (UUID | str | None) - An optional filter, for bookings assigned to the given tutor.
  • year_of_study_ids (list[str] | None) - An optional filter, taking a list of the students' year(s) of study (selected when making a booking), restricting results to those that match one of the included IDs.
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "start_date, reference").
  • kwargs (Any) - Internal data
Return:
  • dict - An array of booking requests (object) containing the key details required for displaying a listing of bookings.

vetSchool.getListOfConversations(vet_school_id, read_status_id, page_number, page_size, order_by, kwargs)

JSON-RPC

Returns a paginated list of booking conversations, forming the vet school's 'messages home'

The vet_school_id argument is required.

Parameters:
  • vet_school_id (UUID | str) - A unique identifier for the vet school (required)
  • read_status_id (str | None) - An optional filter, either "read", "unread" or "all".
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "-last_updated").
  • kwargs (Any) - Internal data
Return:
  • dict -

vetSchool.getListOfMessages(vet_school_id, assigned, keywords, placement_type_ids, provider_id, read_status_id, sender_role_ids, student_id, tutor_id, year_of_study_ids, page_number, page_size, order_by, kwargs)

JSON-RPC

Returns a paginated list of booking conversations in which the vet school is a participant.

The vet_school_id argument is required.

Parameters:
  • vet_school_id (UUID | str) - A unique identifier for the vet school (required).
  • assigned (bool | None) - An optional filter, for assigned bookings only (if true) or unassigned bookings only (if false).
  • keywords (str | None) - An optional search string of one or more keywords.
  • placement_type_ids (list[str] | None) - An optional filter with a list of placement types, restricting the results to these types of booking if applied. Permitted values to include: "animal_husbandry_ems" and/or "clinical_ems".
  • provider_id (UUID | str | None) - An optional filter, taking the unique identifier for the EMS placement provider.
  • read_status_id (str | None) - An optional filter, either "read", "unread" or "all".
  • sender_role_ids (list[str] | None) - An optional filter with a list of sender roles, restricting the results to messages whose sender type is included in this list if applied. Permitted values to include: "provider", "student" and/or "tutor".
  • student_id (UUID | str | None) - An optional filter, taking the unique identifier for the student.
  • tutor_id (UUID | str | None) - An optional filter, for bookings assigned to the given tutor.
  • year_of_study_ids (list[str] | None) - An optional filter, taking a list of the students' year(s) of study (selected when making a booking), restricting results to those that match one of the included IDs.
  • page_number (int | None) - The page of matching results to be returned (default: 1).
  • page_size (int | None) - The number of results returned per page (default: 20).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "-sent").
  • kwargs (Any) - Internal data
Return:
  • dict - A page object, containing an array of booking conversations (object).

vetSchool.getListOfTutors(vet_school_id, order_by, kwargs)

JSON-RPC

Returns an array of active EMS users with tutor roles at a vet school.

The vet_school_id argument is required.

The order_by argument is optional. By default, the method returns the current user as the first user in the list and any additional tutors in alphabetical order by first_name, last_name.

Parameters:
  • vet_school_id (UUID | str) - A unique identifier for the vet school (required).
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "current_user, first_name, last_name").
  • kwargs (Any) - Internal data
Return:
  • list - An array of users (object)

vetSchool.getListOfVetSchools(order_by, kwargs)

JSON-RPC

Returns an array of active vet school IDs and names.

The order_by argument is optional.

Parameters:
  • order_by (str | None) - The sort order of the results, a comma-separated list of fields (default: "name, id").
  • kwargs (Any) - Internal data
Return:
  • list - An array of summary 'vet school' options (object)

vetSchool.getVetSchool(vet_school_id, kwargs)

JSON-RPC

Returns an object containing details of a vet school.

The argument is required.

Parameters:
  • vet_school_id (UUID | str) - A unique identifier for the vet school
  • kwargs (Any) - Internal data
Return:
  • dict - A collection of key/value pairs (object) representing the details of the vet school