Here the changes of Rest API from VMS version to version are documented, which can potentially break compatibility. In particular, methods and params can be renamed, though often deprecated names are supported for a while, when noted below.


VMS 4.0 relative to 3.2

Breaking compatibility

In case of InvalidParameter or MissingParameter error, the status code has been changed from 200 OK to 422 Unprocessable Entity; in case of timeout, the status code has been changed from 200 OK to 408 Request Timeout in methods:

    /api/getCameraParam
    /api/setCameraParam

Output parameter value list can contain not only parameters specified by the user, but also additional parameter values affected by the set operation in the method:

    /api/setCameraParam

Params scheduleTask.beforeThreshold and scheduleTask.afterThreshold were removed in favor of the new recordBeforeMotionSec and recordAfterMotionSec params in methods:

    /ec2/saveCameraUserAttributesList
    /ec2/saveCameraUserAttributes
    /ec2/getCameraUserAttributesList
    /ec2/getCamerasEx

Added optional param currentPassword, which is required if new password is provided in methods:

    /api/configure
    /api/detachFromCloud

Added required param currentPassword in method /api/restoreState.

Expanded dewarpingParams and contrastParams fields in the layout items description in methods:

    /ec2/getLayouts
    /ec2/saveLayout
    /ec2/saveLayouts

Parameters layout.horizontalSpacing and layout.verticalSpacing were removed in favor of the new cellSpacing parameter in methods:

    /ec2/getLayouts
    /ec2/saveLayout
    /ec2/saveLayouts

Retaining compatibility until expired

Method /api/gettime deprecated in favor of the new method /api/getTime (deprecated method support expires after 4.0).
Result structure of the new method differs from the old one:

    timeZoneOffset - is now in milliseconds instead of seconds
    timezoneId -> timeZoneId
    utcTime -> vmsTime
    osTime - new parameter, see documentation for details

Made GET deprecated in favor of the newly implemented POST in method /api/setCameraParam (deprecated method support expires after 4.0).
NOTE: In API documentation, this method was previously incorrectly stated as POST, but now this statement becomes true.

Made GET deprecated in favor of the newly implemented POST in method /api/restart (deprecated method support expires after 4.0).

Retaining compatibility

Removed param scheduleTask.recordAudio (was not used) in methods:

    /ec2/saveCameraUserAttributesList
    /ec2/saveCameraUserAttributes
    /ec2/getCameraUserAttributesList
    /ec2/getCamerasEx


VMS 3.2 relative to 3.1

Breaking compatibility

Deleted deprecated method /api/image.

Retaining compatibility until expired

Made GET deprecated in favor of POST in method /api/detachFromCloud (deprecated method support expires after 3.2).

Renamed certain param values in method /ec2/cameraThumbnail (deprecated values support expires after 3.2):

    Param imageFormat values:
        jpeg -> jpg
        tiff -> tif

    Param roundMethod values:
        exact -> precise

Errata fixed in the API documentation (not changing API behavior)

Fixed param and value names in method /ec2/cameraThumbnail:

    Param imageFormat values:
        PngFormat -> png
        JpgFormat -> jpg
        TiffFormat -> tif
        RawFormat -> raw

    Param method -> roundMethod values:
        KeyFrameBeforeMethod -> before
        PreciseMethod -> precise
        KeyFrameAfterMethod -> after

Fixed method URL prefix: /api/execAction -> /ec2/execAction.


VMS 3.1 relative to 3.0

Retaining compatibility until expired

Changed GET -> POST in method /api/mergeSystems (deprecated method support expires after 3.2). Check changed params in the API documentation.


VMS 3.0 relative to 2.6

Breaking compatibility

Renamed methods:

    /ec2/getServerUserAttributes -> /ec2/getMediaServerUserAttributesList
    /ec2/saveServerUserAttributes -> /ec2/saveMediaServerUserAttributes
    /ec2/saveServerUserAttributesList -> /ec2/saveMediaServerUserAttributesList
    /ec2/getCameraUserAttributes -> /ec2/getCameraUserAttributesList
    /api/businessEvents -> /api/getEvents
    /ec2/getBusinessRules -> /ec2/getEventRules

Changed reply format XML -> JSON in methods:

    /api/manualCamera/search
    /api/manualCamera/status
    /api/manualCamera/stop
    /api/statistics
    /api/storageSpace
    /api/storageStatus

Retaining compatibility until expired

Replaced method /api/image -> /ec2/cameraThumbnail (deprecated method support expires after 3.1). The new method can get thumbnails from cameras located on other servers (the old one can not).

Renamed param cameraID -> cameraId (deprecated name support expires after 3.2) in methods:

    /ec2/getCamerasEx
    /ec2/getCameraUserAttributesList
    /ec2/saveCameraUserAttributesList
    /ec2/saveCameraUserAttributes

Renamed param serverID -> serverId (deprecated name support expires after 3.2) in methods:

    /ec2/getMediaServerUserAttributesList
    /ec2/saveMediaServerUserAttributesList
    /ec2/saveMediaServerUserAttributes

Renamed param phisicalMemory -> physicalMemory (deprecated name support expires after 3.2) in methods:

    /ec2/saveClientInfo
    /ec2/getClientInfoList

Renamed param preferedServerId -> preferredServerId (deprecated name support expires after 3.2) in methods:

    /ec2/saveCameraUserAttributesList
    /ec2/saveCameraUserAttributes
    /ec2/getCameraUserAttributesList
    /ec2/getCamerasEx

Renamed param res_id -> cameraId (deprecated name support expires after 3.2) in methods:

    /api/doCameraDiagnosticsStep
    /api/setCameraParam
    /api/getCameraParam

Renamed param resourceId -> cameraId (deprecated name support expires after 3.2) in methods:

    /api/ptz

Renamed and merged together params mac + physicalId -> cameraId in method /ec2/bookmarks (deprecated names support expires after 3.2).

Renamed param physicalId -> cameraId (deprecated name support expires after 3.2) in methods:

    /api/image
    /api/getEvents
    /ec2/recordedTimePeriods

Changed GET -> POST in method /api/manualCamera/add (deprecated method support expires after 3.2). Check changed params in the API documentation.

Renamed param timeSinseEpochMs -> timeSinceEpochMs in method /ec2/getTimeOfServers.

Remove global setting synchronizeTimeWithInternet It implicitly turned on if settings 'primaryTimeServer' is not defined and 'timeSynchronizationEnabled' is true.