On this page

Format Change

Additional JSON syntax compliance

Due to the change in the JSON library, REST API accepts only the standard JSON syntax. One of the major changes is that a trailing comma after the last member is not valid. For example:

An invalid trailing comma used after the last member
"kerml:esiData": {
         "owningPackage": {
             "@id": "b296eaf8-346d-4f05-96aa-6ed8c061b4e1"
         },
         "name": "testBranchElement",     //non-compliant
}
Valid comma usage
"kerml:esiData": {
         "owningPackage": {
             "@id": "b296eaf8-346d-4f05-96aa-6ed8c061b4e1"
         },
         "name": "testBranchElement"
}

Change in the character set in an HTTP header

The Content type in an HTTP response header does not contain a character set.

2021xR1

2021xR2

Content type: application/json; charset=UTF-8

Content type: application/json (no charset)

Open API 3.0

The REST API specification returned from /osmc/manual is in the Open API 3.0 specification format. The specification is at https://swagger.io/specification/. The table below shows the major differences between Open API 2.0 and 3.0.

Item

Swagger 2.0 (Open API 2.0)

Open API 3.0

Schema

#/definitions

#/components/schemas

Parameter in a request body

In the parameters attribute that in = body.

A separated requestBody attribute.

MIME type of a request body

Located in the consumes attribute.

Located in requestBody/content/<MIME_type>.

Type of parameter (except request body)

Located in the type attribute.

Located in the schema attribute.

Response type

Located in the produces attribute.

Located in attribute responses/<status number>/<MIME_type>.


New data type

ProtectedObjectAccessible

Type: ENUM

Name

Remark

MANAGEABLE

The protected object can be managed by the caller.

UNFILTER

The filter parameter is not specified.

VISIBLE

The protected object can only be visible (but not manageable) by the caller.


Changes in data types

ProtectedObject

Name

Type

Status

Remark

access

ProtectedObjectAccessible

Added

A condition of this protected object.

containerId

UUID

Added

A UUID of its parent.

Affected URLs:

  • /admin/usergroups/{userGroupId}
  • /admin/usergroups/{userGroupId}/roles
  • /admin/users/{username}
  • /admin/users/{username}/roles

UserGroup

Name

Type

Status

Remark

createdDate

long

Added

Timestamp

modifiedDate

long

Added

Timestamp

Affected URL:

  • /admin/usergroups/{userGroupId}

LDAP Resync

Name

Type

Status

Remark

lastLoginDate

long

Type changed

From String to timestamp.

Affected URL:

  • /admin/ldaps/{ldapId}/resync