Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

id2102576462

...

id2102576476

...

id2102576459

On this page

Table of Contents

...

id2102576466

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:

Code Block
languagetext
titleAn invalid trailing comma used after the last member
"kerml:esiData": {
         "owningPackage": {
             "@id": "b296eaf8-346d-4f05-96aa-6ed8c061b4e1"
         },
         "name": "testBranchElement",     //non-compliant
}
Code Block
languagetext
titleValid 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>.

Username Parameter Moved from Path to Query

The ULRs with the username parameter in the path have been changed to move the parameter to query. This has been done due to a special security vulnerability related to some special characters being used in the path.

Due to this change, the following URLs have been moved:

From

To

/osmc/admin/ldaps/{ldapId}/import/{username}

/osmc/admin/ldaps/{ldapId}/import

/osmc/admin/ldaps/{ldapId}/import/{username}/usergroups

/osmc/admin/ldaps/{ldapId}/importas/usergroups

/osmc/admin/ldaps/{ldapId}/import/{username}/users

/osmc/admin/ldaps/{ldapId}/importas/users

/osmc/admin/locks/{username}

/osmc/admin/locks

/osmc/admin/roles/{roleId}/users/{username}

/osmc/admin/roles/{roleId}/users

/osmc/admin/users/{username}

/osmc/admin/user

/osmc/admin/users/{username}/resourcebranchreadonlyall

/osmc/admin/user/resourcebranchreadonlyall

/osmc/admin/users/{username}/resources/{resourceId}/branches/readonly

/osmc/admin/user/resources/{resourceId}/branches/readonly

/osmc/admin/users/{username}/roles

/osmc/admin/user/roles

/osmc/resources/{resourceId}/roles/{roleId}/users/{username}

/osmc/resources/{resourceId}/roles/{roleId}/users

/osmc/workspaces/{workspaceId}/resources/{resourceId}/roles/{roleId}/users/{username}

/osmc/workspaces/{workspaceId}/resources/{resourceId}/roles/{roleId}/users

/osmc/workspaces/{workspaceId}/roles/{roleId}/users/{username}

/osmc/workspaces/{workspaceId}/roles/{roleId}/users

New URLs

Read-only Branch Deletion

New API for read-only branch deletion to comply with HTTP standards. Uses HTTP PUT method.

  • /osmc/admin/user/resources/{resourceId}/branches/readonlydelete
  • /osmc/admin/usergroups/{usergroupId}/resources/{resourceId}/branches/readonlydelete

Webhooks

Webhook CRUD.

  • /osmc/admin/webhooks
  • /osmc/admin/webhooks/{webhookId}
  • /osmc/admin/webhooks/{webhookId}/status

Removed URLs

Deprecated in Previous Version

  • /osmc/admin/tsl

New Data Types

WebhookTriggerSimple

Name

Type

Remark

type

ENUM (one of: “all”, “list”, “commit”, “any_tag”)

The trigger type.

WebhookTriggerResourceTags

Name

Type

Remark

type

ENUM (one of: “tags”)

The trigger type.

value

Array of String

The commit tags that trigger the invocation of the webhook.

WebhookTrigger

One of: WebhookTriggerSimple, WebhookTriggerResourceTags.

SetOfWebhookTrigger

Name

Type

Remark

type

ENUM (one of: “list”)

The trigger type.

value

Array of WebhookTrigger

Arbitrary set of webhook triggers.

WebhookScopeAll

Name

Type

Remark

type

ENUM (one of: “all”)

The scope type.

WebhookScopeResource

Name

Type

Remark

type

ENUM (one of: “resource”)

The scope type.

value

UUID

The ID of the resource that constitutes the scope.

WebhookScopeResourcesInCategory

Name

Type

Remark

type

ENUM (one of: “resource_in_category”)

The scope type.

value

UUID

The ID of the category that constitutes the scope.

WebhookScope

One of: WebhookScopeAll, WebhookScopeResource, WebhookScopeResourcesInCategory. 

WebhookAuthenticationNone

Name

Type

Remark

type

ENUM (one of: “none”)

The authentication type.

WebhookAuthenticationBasic

Name

Type

Remark

type

ENUM (one of: “type”)

The authentication type.

authentication_username

String

The username.

authentication_password

String

The password.

WebhookAuthentication

One of: WebhookAuthenticationNone, WebhookAuthenticationBasic.

Webhook

Name

Type

Remark

webhookId

UUID

The webhook ID.

trigger

One of: WebhookTrigger, SetOfWebhookTrigger

The trigger.

scope

WebhookScope

The scope.

enabled

Boolean

Is the webhook enabled.

type

ENUM (one of: “http”)

The webhook type.

endpoint

String

The webhook endpoint (URL).

authentication

WebhookAuthentication

The authentication.

WebhookUpdate

Name

Type

Remark

trigger

One of: WebhookTrigger, SetOfWebhookTrigger

The trigger.

scope

WebhookScope

The scope.

enabled

Boolean

Is the webhook enabled.

type

ENUM (one of: “http”)

The webhook type.

endpoint

String

The webhook endpoint (URL).

authentication

WebhookAuthentication

The authentication.

WebhookCreateResult

Name

Type

Remark

webhookId

UUID

The ID of the created webhook.

WebhookStatus

Name

Type

Remark

enabled

Boolean

Is the webhook enabled.

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:

...