Instilled API

Instilled RESTful Video and Collaboration Platform API Documentation

Base URI

https://tenant.kzoplatform.com/api
Parameters
created_by
string optional

Filtering by creator’s username with partial matching

Example:
admin
created_at_from
string optional

Filtering by creation time. Specifies beginning of inclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2012-10-10T14:12:24.324Z
created_at_to
string optional

Filtering by creation time. Specifies end of inclusive time interval using ISO8601 standard. If not set, it means until the end of time.

Example:
2013-10-10T14:12:24.324Z
modified_by
string optional

Filtering by last modifier’s username with partial matching

Example:
bob
modified_at_from
string optional

Filtering by modification time. Specifies beginning of exclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2012-10-10T14:12:24.324Z
modified_at_to
string optional

Filtering by modification time. Specifies end of exclusive time interval using ISO8601 standard. If not set, it means until the end of time.

Example:
2013-10-10T14:12:24.324Z
deleted_by
string optional

Filtering by deleter’s username with partial matching

Example:
bob
deleted_at_from
string optional

Filtering by deletion time. Specifies beginning of exclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2012-10-10T14:12:24.324Z
deleted_at_to
string optional

Filtering by deletion time. Specifies end of exclusive time interval using ISO8601 standard. If not set, it means until the end of time.

Example:
2013-10-10T14:12:24.324Z
unpublished
boolean optional

Whether to include resources with attribute published = false into the response. API user needs to have specific permissions to be able to access unpublished content. Default value is false.

Example:
true
include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: users, containers, groups etc. Parameters are joined with comma.

Includes for media and medium can be substituted, so that media information would be included to the response no matter which of two includes was requested. Same logic is applied container and containers.

Example:
media,containers,created_by
Headers
Content-Length
number required

Indicates the size of the entity-body.

Content-Type
string required

Indicates the media type of the entity-body. Must be in the form application/vnd.api+json

Operations: Creating User
If-Match
string optional

This should contain the version of the resource to be updated. The version is found from the response headers ETag when the resource was originally created (POST) or queried by the client (GET), or when the client queried metadata on the resource (HEAD). If provided, the current version of the resource must match for the action to proceed.

Host
string required

Specifies the Internet host and port number of the resource being requested.

X-KZO-API-Version
string required

Specifies API version. For details, see API Version.

X-KZO-Auth-AccessKey
string required

Access Key used by the API caller to authenticate against the server. For details, see Authentication and Authorization.

X-KZO-Auth-DelegateGroupId
number optional

Specifies ID of the Group on behalf of which the method should be executed. For details, see Authentication and Authorization.

X-KZO-Auth-DelegateUsername
string optional

Specifies username of the User on behalf of which the method should be executed. For details, see Authentication and Authorization.

X-KZO-Auth-Username
string required

Username used by the API caller to authenticate against the server. For details, see Authentication and Authorization.

X-KZO-Pipeline-Action
string optional

Used to initiate special actions related to pipeline processing on a pipeline-enabled entity or an entity managed by a pipeline of its parent entity. For more details, see Workflow.

X-KZO-Tenant
string required

Specifies name of the Tenant to which the request is issued. For details, see [Tenant Management](doc://Tenant Management).

Content-Length
number required

Indicates the size of the entity-body.

Content-Type
string required

Indicates the media type of the entity-body. Must be in the form application/vnd.api+json

ETag
number required

Contains the version of the resource being returned.

X-KZO-API-Version
string required

Specifies API version. For details, see API Version.

X-KZO-Available-API-Versions
string optional

Specifies comma-separated list of API versions available on the server. For details, see API Version.

Responses
400 Bad Request
Applied to all operations

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

401 Unauthorized

The request requires Authentication and Authorization.

Operations: Adding User to Group Copying Medium Creating Comment Creating Container Creating Group Creating Medium Creating Original Video Creating Permission Creating Platform Access Key Creating Property Creating Reply to Reply Creating Session Access Key Creating Session Access Key: Password Authentication Creating Slide Deck Creating Top-Level Container Creating Used Slide Creating User Creating Viewed Fragment For Medium Delete configuration Delete favorite Deleting Access Key Deleting Container Deleting Group Deleting Medium Deleting Permission Deleting Property Deleting Used Slide Deleting User Deleting User from Group Favorite container Favorite medium Get favorite Get favorites Incremental reordering of descendant playlist entries for container Reordering Children of a Container Replacing Container Replacing Group Replacing Medium Replacing Property Replacing Used Slide Replacing User Replacing Viewed Fragment Searching Capabilities Searching Containers Searching Content Searching Groups Searching Media Searching Montage Options Searching Permissions Searching Roles Searching Screenshot Options Searching Users Searching Video Rendition Options Update configuration Updating Container Updating Group Updating Medium Updating Used Slide Updating User Viewing Access Key Viewing Asset Viewing Available Properties Viewing Avatar Viewing Capability Viewing Chapter Viewing Comment Viewing Container Viewing Group Viewing Immediate Child Containers Viewing Medium Viewing Montage Viewing Montage Option Viewing Multiple Assets Viewing Multiple Chapters Viewing Multiple Comments Viewing Multiple Containers Viewing Multiple Groups Viewing Multiple Media Viewing Multiple Montages Viewing Multiple Replies Viewing Multiple Screenshots Viewing Multiple Used Slides Viewing Multiple Users Viewing Multiple Video Renditions Viewing Own Administrative Roles Viewing Permission Viewing Property Viewing Reply Viewing Role Viewing Screenshot Viewing Screenshot Option Viewing Slide Viewing Topmost Available Containers Viewing User Viewing Video Rendition Viewing Video Rendition Option
403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

404 Not Found
Applied to all operations

The server has not found anything matching the Request-URI.

405 Method Not Allowed

The client executed method which is not available on the given resource (see also error 409)

406 Not Acceptable
Applied to all operations

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

408 Request Timeout

Reported by the server in a situation when processing of the API request included request to external resource, and that request times out.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

412 Precondition Failed

The tag specified in If-Match header did not match.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

428 Precondition Required

The client failed to specify If-Match header for PUT request.

Documentation
JSON API

The KZO REST API follows the emerging JSON API specification. JSON API is an attempt to formalize similar ad hoc client-server interfaces that use JSON as an interchange format. It is specifically focused around using those APIs with a smart client that knows how to cache documents it has already seen and avoid asking for them again.

The object returned by the API typically contains the following members:

  1. Top-level primary object – either a single resource or a collection of resources of the primary entity being requested, keyed by the name of that entity.
  2. Top-level meta – meta-information about the response object, such as pagination.
  3. Top-level linked – a collection of flattened collections of resource objects, grouped by object type, that are linked to the primary resource(s) and/or each other (i.e. “linked resource(s)”)
  4. Resource-level id – resource identifier, typically an integer (User is the only entity where username serves as identifier).
  5. Resource-level href – URI of a resource.
  6. Resource-level links – linked resources, keyed by the name of each association.
  7. Resource-level meta – meta-information about a resource object, such as its pipeline status and available actions.

For more information please refer to the JSON API format

API Version

API is versioned according to the specification of Semantic Versioning. Stable versions are specified as M.m.p. Patch versions p introduce bug fixes, minor versions m introduce non-breaking changes, major versions M introduce breaking changes. Several versions of the API may be deployed on the server simultaneously. Information related to API versioning is communicated via custom headers.

Request must specify API version or version range acceptable to the client:

X-KZO-Accept-API-Versions: M1[.m1][-][M2[.m2]]

Patch levels cannot be specified in requests. The requested API version can be specified as a number, meaning a request for a specific major or major-and-minor version, or as a range, and the range may be open-ended on one or both ends. Omission of any of the 4 numbers from the requested version is treated as placing no restrictions on that number (i.e., zero on the lower end and infinity on the uppper end). Either both major and minor version or only major version can be specified for each end. The server determines which of the deployed API versions satisfies the request, and if match is found, the latest of matching versions is used to process the request. If no match is found, error 406 is returned.

Response specifies the actual API version being used to respond:

X-KZO-API-Version: M.m.p

Additionally, response provides a comma-separated list of API versions deployed on the server:

X-KZO-Available-API-Versions: M1.m1.p1[, M2.m2.p2, ...]

Examples:

X-KZO-Accept-API-Versions: 1
X-KZO-Accept-API-Versions: 1.2
X-KZO-Accept-API-Versions: 1.3-1
X-KZO-Accept-API-Versions: 1.3-2.4
X-KZO-Accept-API-Versions: 1-
X-KZO-Accept-API-Versions: -1.2
X-KZO-Accept-API-Versions: -
X-KZO-API-Version: 1.1.5
X-KZO-Available-API-Versions: 1.1.5, 2.2.4

Unless the API client has specific requirements for the API version, it is recommended to request the latest available minor version of the current major version, i.e.:

X-KZO-Accepts-API-Versions: 1
REST Verbs

GET: Used for retrieving resources. Safe and idempotent method.

HEAD: Itentical to GET, except that the server is not returning entity-body in the response. Can be used to “preflight” the request. Safe and idempotent method.

OPTIONS: Supported for compatibility reasons. For the list of actions available on the resource, see Workflow. Safe and idempotent method.

POST: Used for creating new resources. Unsafe and non-idempotent method.

PATCH: Used for updating select attributes for a resource. For example, a Medium object has multiple attributes, such as title and description. PATCH methods implement a subset of JSON Patch specification, namely, multiple invocations of the only method, replace. See http://jsonpatch.com/ for details. ETag header is optional for PATCH, but if provided, it is honored. Unsafe method. The current (limited) implementation makes it idempotent method.

PUT: Used for replacing resources entirely. Any missing attributes will either trigger an error (if they are required), or set the attribute’s value to null (if they are optional). ETag header is mandatory for PUT. Unsafe and idempotent method.

DELETE: Used for deleting resources. Unsafe and idempotent method.

Domain Terminology

TBD

Tenancy

KZO Platform is a multi-tenant application. It means that each partner of KZO (Tenant of the KZO Platform) for which an account is set up on a given Installation of KZO Platform, is allocated a logically separate area of the database to store its data, with independent ranges of IDs of all resources.

Each Tenant is identified with a name, which is communicated to the partner at the time its account is created. When an API request is made by API client, Tenant name must be specified via mandatory header:

X-KZO-Tenant: tenant-name
Authentication and Authorization

All communication between the API server and client is always happening over HTTPS. There is no provision for request signature.

Access Control

To be able to execute most API methods, the API client is required to have specific Capabilities. For example, to be able to view media belonging to a given container, the API user is required to have a capability VIEW_CONTENT on that container. Another example: to be able to manage users, the API user is required to have a capability MANAGE_ACCESS on the root container (Capabilities which can only be assigned to root Container are marked root_only). Capabilities are grouped into Roles. Users are grouped into Groups.

Note: as the API is changing over time, the following things may change without advance notice: the set of Capabilities available by the Platform, access rights provided by any given Capability, sets of Capabilities comprising any given Role. Such changes are not considered breaking changes for the API because access rights provided by Roles will never be reduced, they can only grow. API clients should consider Role as an assignable unit of information related to access control. Capabilties are technical entities closely tied to the current implementation state of the Platform. Capabilities and Roles available on the Platform are listed below in the end of this section.

Access to containers is inherited on the Container hierarchy. It means that if a given User has specific access to a given Container, that User will have the same access to all children Containers of that Container, which are connected to its parent via links of types ORIGINAL and FULL_REFERENCE. If the method in question is of the viewer type (property viewerOnly=true, indicated in the description of each method) then in addition to the above, the user will have the same access to all children Containers of that Container, which are connected to its parent via links of type VIEW_ONLY_REFERENCE. For more information, see Content Structure in Migrating from the SOAP API.

Access is managed via Permissions. A permission is comprised of three references: to a container, to a group, and to a role. A given permission therefore gives all Capabilities which the given Role is comprised of on the given Container to all Users of the given Group.

Authorization

The client authorizes itself with an Access Key, which it typically receives from the server at the time of authentication. There are two types of keys: SESSION or PLATFORM. They both expire automatically. SESSION key expires after a certain period of inactivity, 5 hours by default (can be changed on Tenant level). PLATFORM key expires at a specific time, set at the time of its creation. Session key can be created by an unauthenticated user using various authentication methods provided by the Platform, e.g., via password authentication method.

There are no limits on a number of simultaneously active SESSION or PLATFORM Access Keys for any given User.

Authorization is implemented via the following mandatory request headers:

X-KZO-Auth-Username: <username>
X-KZO-Auth-AccessKey: <accessKey>

where

  1. <username> is a username of the API user,
  2. <accessKey> is a 32-symbol alphanumeric access key, returned by one of authetication methods.

Methods which do not require prior authorization will ignore these headers.

Authentication

To obtain an Access Key, the API user must first call one of available access key creation methods, see method group Authentication.

To logout, the API user must delete his active Access Key, see method Deleting Access Key.

Delegated access

The API user can execute requests on behalf of other Users or Groups. To be able to do it, she must have a special Capability. For instance, in order for delegated access to a method which requires capability MANAGE_CONTENT to be granted, the following conditions must satisfy:

  1. the User executing the request must have the Capability DELEGATE_MANAGE_CONTENT,
  2. the User/Group on whose behalf the request is being executed must have Capability MANAGE_CONTENT,
  3. if the request is executed on behalf of a Group, the given method must also have a property delegateGroup=true (indicated in the description of each method).

Delegated access can be requested via one of the following optional headers:

X-KZO-Auth-DelegateUsername: <username>
X-KZO-Auth-DelegateGroupId: <group_id>

which specifies either User or Group, on behalf of which the request should be executed.

Errors

If a request which requires authentication is performed without specifying valid credentials, error 401 is returned. If a request which requires authentication is performed with valid credentials but access rigths of the User are deemed insufficient for the requested action, error 403 will be returned.

Capabilities

Here is the list of Capabilities available on the Platform:

  1. [root_only] MANAGE_TENANT
  2. [root_only] DELEGATE_MANAGE_TENANT
  3. [root_only] MANAGE_INSTALLATION
  4. [root_only] DELEGATE_MANAGE_INSTALLATION
  5. [root_only] MANAGE_IDENTITIES
  6. [root_only] DELEGATE_MANAGE_IDENTITIES
  7. [root_only] MANAGE_INTEGRATION_VISITORS_IDENTITIES
  8. [root_only] DELEGATE_MANAGE_INTEGRATION_VISITORS_IDENTITIES
  9. [root_only] VIEW_IDENTITIES
  10. [root_only] DELEGATE_VIEW_IDENTITIES
  11. [root_only] CREATE_TOP_LEVEL_CONTAINERS
  12. [root_only] DELEGATE_CREATE_TOP_LEVEL_CONTAINERS
  13. MANAGE_ACCESS
  14. DELEGATE_MANAGE_ACCESS
  15. CREATE_CONTENT
  16. DELEGATE_CREATE_CONTENT
  17. CREATE_CONTENT_RECORD_MEDIA
  18. DELEGATE_CREATE_CONTENT_RECORD_MEDIA
  19. CREATE_CONTENT_UPLOAD_MEDIA
  20. DELEGATE_CREATE_CONTENT_UPLOAD_MEDIA
  21. CREATE_CONTENT_COPY_MEDIA
  22. DELEGATE_CREATE_CONTENT_COPY_MEDIA
  23. CREATE_CONTENT_CONTAINERS
  24. DELEGATE_CREATE_CONTENT_CONTAINERS
  25. UPDATE_CONTENT
  26. DELEGATE_UPDATE_CONTENT
  27. DELETE_CONTENT
  28. DELEGATE_DELETE_CONTENT
  29. VIEW_CONTENT
  30. DELEGATE_VIEW_CONTENT
  31. COMMENT_REPLY
  32. DELEGATE_COMMENT_REPLY
  33. MANAGE_AUTHORSHIP
  34. DELEGATE_MANAGE_AUTHORSHIP

Capabilities *_CONTENT allow User to perform respective actions on Containers, Playlist Entries, Media and everything below Media.

Capability MANAGE_ACCESS allow User to manage other user’s Permissions on Container on which they are assigned. E.g., if MANAGE_ACCESS is given to a User on a non-root Container, it allow that User to manage Capabilities *_CONTENT and MANAGE_ACCESS for any Group on that Container or below on Container hierarchy. If MANAGE_ACCESS is assigned to a User on a root Container, it allows that User to manage all Capabilities for any Group on all Containers.

Capability MANAGE_IDENTITIES allows User to manage Users, Groups, Group Membership, Access Keys for Users of all authentication_types.

Capability MANAGE_INTEGRATION_VISITORS_IDENTITIES allows User to manage Users, Group Membership, Access Keys for Users of authentication_type=INTEGRATION_VISITOR.

Capability VIEW_IDENTITIES allows User to view Users, Groups, Group Membership.

Capability MANAGE_INSTALLATION allows User to manage Tenants on privileged Tenant.

Capability MANAGE_TENANT allows User to do various administrative tasks not in Container context.

Capability COMMENT_REPLY allows User to create Comments and Replies (other actions with them are managed by the respective capabilities *_CONTENT).

Capability CREATE_TOP_LEVEL_CONTAINERS allows User to create top-level containers (children of root Container) without giving her any other access. In particular, it does not allow her to view the root Container itself.

Roles

Here is the list of Roles available on the Platform, along with Capabilities comprising them:

  1. [root_only] SUPERUSER: MANAGE_TENANT, DELEGATE_MANAGE_TENANT, MANAGE_INSTALLATION, DELEGATE_MANAGE_INSTALLATION, MANAGE_IDENTITIES, DELEGATE_MANAGE_IDENTITIES, VIEW_IDENTITIES, DELEGATE_VIEW_IDENTITIES, CREATE_TOP_LEVEL_CONTAINERS, DELEGATE_CREATE_TOP_LEVEL_CONTAINERS, MANAGE_ACCESS, DELEGATE_MANAGE_ACCESS, VIEW_CONTENT, DELEGATE_VIEW_CONTENT, CREATE_CONTENT, DELEGATE_CREATE_CONTENT, RECORD_CONTENT, DELEGATE_RECORD_CONTENT, CREATE_CONTAINERS, DELEGATE_CREATE_CONTAINERS. UPDATE_CONTENT, DELEGATE_UPDATE_CONTENT, DELETE_CONTENT, DELEGATE_DELETE_CONTENT, COMMENT_REPLY, DELEGATE_COMMENT_REPLY, UPDATE_CONTENT_AUTHORED_BY
  2. [root_only] INSTALLATION_MANAGER: MANAGE_INSTALLATION
  3. [root_only] INSTALLATION_MANAGER_DELEGATOR: DELEGATE_MANAGE_INSTALLATION
  4. [root_only] IDENTITY_MANAGER: VIEW_IDENTITIES, MANAGE_IDENTITIES
  5. [root_only] IDENTITY_MANAGER_DELEGATOR: DELEGATE_VIEW_IDENTITIES, DELEGATE_MANAGE_IDENTITIES
  6. [root_only] IDENTITY_VIEWER: VIEW_IDENTITIES
  7. [root_only] IDENTITY_VIEWER_DELEGATOR: DELEGATE_VIEW_IDENTITIES
  8. [root_only] INTEGRATION_VISITOR_IDENTITY_MANAGER: VIEW_IDENTITIES, MANAGE_INTEGRATION_VISITORS_IDENTITIES
  9. [root_only] INTEGRATION_VISITOR_IDENTITY_MANAGER_DELEGATOR: DELEGATE_VIEW_IDENTITIES, DELEGATE_MANAGE_INTEGRATION_VISITORS_IDENTITIES
  10. [root_only] TOP_LEVEL_CONTAINER_CREATOR: CREATE_TOP_LEVEL_CONTAINERS
  11. [root_only] TOP_LEVEL_CONTAINER_CREATOR_DELEGATOR: DELEGATE_CREATE_TOP_LEVEL_CONTAINERS
  12. ACCESS_MANAGER: VIEW_CONTENT, MANAGE_ACCESS
  13. ACCESS_MANAGER_DELEGATOR: DELEGATE_VIEW_CONTENT, DELEGATE_MANAGE_ACCESS
  14. CONTENT_MANAGER: VIEW_CONTENT, CREATE_CONTENT, UPDATE_CONTENT, DELETE_CONTENT, COMMENT_REPLY, CREATE_TOP_LEVEL_CONTAINERS, RECORD_CONTENT, CREATE_CONTAINERS, UPDATE_CONTENT_AUTHORED_BY
  15. CONTENT_MANAGER_DELEGATOR: DELEGATE_VIEW_CONTENT, DELEGATE_CREATE_CONTENT, DELEGATE_UPDATE_CONTENT, DELEGATE_DELETE_CONTENT, DELEGATE_COMMENT_REPLY, DELEGATE_CREATE_TOP_LEVEL_CONTAINERS, DELEGATE_RECORD_CONTENT, DELEGATE_CREATE_CONTAINERS, DELEGATE_UPDATE_CONTENT_AUTHORED_BY
  16. CONTENT_CREATOR: VIEW_CONTENT, CREATE_CONTENT, RECORD_CONTENT, CREATE_CONTAINERS
  17. CONTENT_CREATOR_DELEGATOR: DELEGATE_VIEW_CONTENT, DELEGATE_CREATE_CONTENT, DELEGATE_RECORD_CONTENT, DELEGATE_CREATE_CONTAINERS
  18. CONTENT_CREATOR_UPLOAD_MEDIA: VIEW_CONTENT, CREATE_CONTENT (hidden=true)
  19. CONTENT_CREATOR_UPLOAD_MEDIA_DELEGATOR: DELEGATE_VIEW_CONTENT, DELEGATE_CREATE_CONTENT (hidden=true)
  20. CONTENT_CREATOR_RECORD_MEDIA: VIEW_CONTENT, RECORD_CONTENT (hidden=true)
  21. CONTENT_CREATOR_RECORD_MEDIA_DELEGATOR: DELEGATE_VIEW_CONTENT, DELEGATE_RECORD_CONTENT (hidden=true)
  22. CONTENT_CREATOR_CONTAINERS: VIEW_CONTENT, CREATE_CONTAINERS (hidden=true)
  23. CONTENT_CREATOR_CONTAINERS: DELEGATE_VIEW_CONTENT, DELEGATE_CREATE_CONTAINERS (hidden=true)
  24. CONTENT_UPDATER: VIEW_CONTENT, UPDATE_CONTENT
  25. CONTENT_UPDATER_DELEGATOR: DELEGATE_VIEW_CONTENT, DELEGATE_UPDATE_CONTENT
  26. CONTENT_DELETER: VIEW_CONTENT, DELETE_CONTENT
  27. CONTENT_DELETER_DELEGATOR: DELEGATE_VIEW_CONTENT, DELEGATE_DELETE_CONTENT
  28. CONTENT_VIEWER: VIEW_CONTENT
  29. CONTENT_VIEWER_DELEGATOR: DELEGATE_VIEW_CONTENT
  30. COMMENTATOR: COMMENT_REPLY
  31. COMMENTATOR_DELEGATOR: DELEGATE_COMMENT_REPLY
  32. AUTHORSHIP_MANAGER: VIEW_CONTENT, MANAGE_AUTHORSHIP
  33. AUTHORSHIP_MANAGER_DELEGATOR: DELEGATE_VIEW_CONTENT, DELEGATE_MANAGE_AUTHORSHIP
Workflow

Pipelines

Some entities on the Platform are “pipeline-enabled”, meaning that CUD operations on them are performed by passing them through a pipeline of transitions programmed in a specifc way. The primary purpose of such formalization is to simplify customization of the processing of resources by the API users, for instance, to be able to easily add custom authentication, email notification at different stages of processing, integration with external systems of the client’s IT infrastructure, etc.

The following entites are pipeline-enabled:

  • Container,
  • Medium,
  • User,
  • Group,
  • Comment,
  • Reply,
  • Access Key,
  • Metrics Datum,
  • Original Video,
  • Slide Deck.

Pipelines of Slide Deck and Original Video are dependent on pipeline of Medium. Chapters and Used Slides do not have their own pipelines and are managed directly by the pipeline of Medium.

Resources can have one of the following statuses while they are traversing their pipelines:

  1. EDITING – the resource is in the process if being edited by the admin end user,
  2. PROCESSING – the resource’s editing by the end user is over, it is now in the state of pipeline processing, which may include editing by the admin,
  3. READY – the resource’s processing is over, it is available to all end users, including non-admins, according to their permissions,
  4. ERROR – the resource’s processing is not over, but the resource is in the state of error, from which it could not be recovered without user intervention.
  5. DELETED – the resource is deleted (it only used for Users, Comments and Replies, other deleted resources are not shown).

The current status of the pipeline-enabled resource is listed in meta.piepline_status.

Transitioning between statuses is done either automatically (i.e., performed by pipeline) or manually by suppying the header of X-KZO-Pipeline-Action as part of the requested method call:

  1. From EDITING to EDITING: by executing API methods of editing type (PUT, PATCH, create subodrinate resources, etc).
  2. From EDITING to PROCESSING: by specifying X-KZO-Pipeline-Action: Process, the processing by pipeline will be started.
  3. From PROCESSING to EDITING or to READY: by specifying X-KZO-Pipeline-Action: Cancel all changes made to the resource are canceled and the resource is returned to READY if it has been published before or to EDITING if it has never been published before.
  4. From PROCESSING to READY: by pipeline, when processing is complete.
  5. From any status to ERROR: by pipeline, when the requested action or automatic processing could not be performed.
  6. From ERROR to EDITING: by specifying X-KZO-Pipeline-Action: Revise, therefore acknowledging that the pipeline-enabled resource was in the status ERROR and the API user wants to revise its state.
  7. From any status to DELETED: by calling Deletion method on the resource

Actions Available for Resources

Actions available for any resource (pipeline-enabled or not) at any given time are listed in its representation as an array meta.actions, an action per array element. Every action is keyed with label, provides an URL and HTTP method to be used on it. Further details, such as query string parameters, can be found in this docuemtnation. This list is the authoritative source of information on what a given user can do with the resource, given her access level and, for pipeline-enabled resources, current status of the resource.

For entites without associated pipelines, this list does not change over time but still depends on user’s access level.

Workflow for Pipeline-Enabled Entities

The typical workflow is to

  1. Create the resource by calling its Creation method.
  2. Edit it, if necessary, by methods PUT, PATCH, by creating child resources if they exist for the given piepeline-enabled resource (e.g., create Chapters as part of editing of the object Medium).
  3. Start processing by specifying header X-KZO-Pipeline-Action: Process. It can be performed either together with the last action from item (2), on the pipeline-enabled resource itself or on its subordinate resource, or as a separate empty (with body {}) PATCH request can be called on the resource with this header set.
  4. Wait until the resource is processed and is transitioned to the state READY by the piepeline.
  5. If the resource is found in the status ERROR instead, check the error objects in the array meta.pipeline_errors and transition the resource back to status EDITING by specifying X-KZO-Pipeline-Action: Revise, the proceed starting with item (2) above.
Migrating from the SOAP API

Migrating from the SOAP API

SOAP -> REST

Those currently using the SOAP based API will notice a number of significant differences. First, we’ve switched from SOAP to REST, which means SOAP methods are no longer used, and instead content is accessed via resource endpoints (/containers/23423) and actions performed on those resources are done using HTTP verbs (GET, POST, DELETE, etc).

Content Structure

The content structure has been modified to provide more flexibility. Previously all content was organized into a fixed 3 level hierarchy:

Courses > Lectures > Parts (often referred to as Communities > Playlists > Videos).

The REST API simplified this into Containers and Media. Containers can contain other containers as well as Media and can be nested as deep or as shallow as makes sense for your application.

By default, the system ships with a root container which serves as a parent to all Containers and Media created.

In addition to parent-child relationship of Containers, it is also allowed to share Containers, i.e. to mark Containers as effective children of other Containers, residing in other parts of the Container hierarchy. It allows to share subtrees of content with different branches of the Container hierarchy without copying it. Hence in the Container hierarchy, Containers can be connected by three types of links:

  1. ORIGINAL – this is the original parent-child link, created together with the child Container. It cannot be removed in any way other than by deleting the child Container.
  2. FULL_REFERENCE – this link imitates ORIGINAL link in a sense that all access rights are inherited from the “shared parent” Container to its “shared child” Container. This link can be added and removed via API.
  3. VIEW_ONLY_REFERENCE – this link restricts access to the “shared child” to only viewing-type actions. I.e., if a given User has administrative rights to the “shared parent” Container, those rights do not apply to its “shared child”. This link can be added and removed via API.

The latter two types of links are namaged by methods Creating Full Reference, Creating View-Only Reference, Deleting References. See also Access Control in Authentication and Authorization.

Migrating existing content to version 5

When upgrading to version 5, your existing content will automatically be converted into the newer schema, while preserving your existing content structure. This means that we will keep your three-level hierarchy as it is, and simply update the references accordingly. By preserving your existing hierarchy, upgrading to the new API will be completely transparent to your users.

Example:

Course 1 > Lecture 2 > Part 3

will become:

Container 1 > Container 2 > Medium 3

SOAP -> REST update examples

The following are examples showing a SOAP call, and it’s newer, updated REST call. SOAP methods requiring an AuthVO as the first argument have been removed in the following examples for brevity.

ContentService

getCourses()
In order to request all containers available to the user, the following method is provided:

GET https://tenant.kzoplatform.com/containers/top

getCourseDetails(courseId)
Requesting information about a course is the same as requesting the container:

GET https://tenant.kzoplatform.com/containers/:containerId

deleteCourse(courseId)

DELETE https://tenant.kzoplatform.com/containers/:containerId

UMService (User Management)

addRegularUser(user)

POST https://tenant.kzoplatform.com/users

{
  "users": {
    "first_name": "Wes",
    "last_name": "Cruver",
    "username": "wescruver",
    "password": "s3cr3t"
  }
}

deleteUser(userId)

DELETE https://tenant.kzoplatform.com/users/:username
Conditional Requests

Not implemented yet.

JSONP Callbacks

Not implemented yet.

We implement page-based pagination for primary resources of some endpoints and some to-many relationships. It’s intended to decrease both response time and response size.

Pagination of primary resources

To paginate over primary resources, an API user can use the following parameters:

  1. page_size_primary is the maximum number of primary resources are to be returned. Default value is 20.
  2. page is the number of page. Default value is 1.

Suppose an API user searches some content, ordered by some criteria, and N of them are relevant to search criteria.

  1. If N is greater than or equal to page * page_size_primary, no primary resources are returned.
  2. Otherwise API skips page * page_size_primary and returns max{page_size_primary, N - page * page_size_primary} primary resources.

Note that we never paginate primary resources for endpoints intended to request specific ones by identifiers.

Endpoints that don’t support pagination of primary resources ignore page and page_size_primary.

When primary resources are paginated, pagination object is included in the root meta of response. It contain the following fields:

  1. total_results (integer) - the total number of primary resources. So many resources would be included in response if we didn’t use pagination at all.
  2. links is an object containing the following links: first, last, prev, next. prev and/or next can be null if there are no previous/next page.

Pagination of relationships

An API user can limit the maximum number of related resources included in response for some to-many relationships. This can be done with a request parameter page_size_related (default value is 10). For instance, when fetching containers with include=media, each container will be linked with no more than page_size_related media in response.

Endpoints that don’t support pagination of relationships ignore page_size_related.

If some relationships of a primary resource can be paginated, meta of the primary resource object included in response contains pagination object with pagination links objects (see pagination links for primary resources) named so as the respective relationship. For instance: {containers: [{id: 123, meta: {pagination: {media: {total_results: 0, ...}}}}]}

Error Reporting

Response meta information may contain information on media or it’s subordinates processing errors.

In case when something went wrong while resource processing state object included in the meta of response may contain non blank error_code and error_message fields together with pipeline_status equal to ERROR:

  • pipeline_status - status of entity, in case of error will take ‘ERROR’ value, that allows error_code and error_message to have not blank values
  • error_code - unique numeric code of error
  • error_message - detailed description of error

When pipeline_status holds value different from ERROR then error_code and error_message are not returned.

Example of meta with error:

 "meta": {
    ...
    "state": {
        ...
        "pipeline_status": "ERROR",
        "error_code": 16033651,
        "error_message": "Slide deck file type incorrect: txt"
    }
}
API Methods
Watershed

API to manage watershed report templates and configuration to access Watershed

POST /api/lrs_reports
Create watershed report
POST /api/lrs_reports

Authentication

Creates report for specified media/container and groups using template created earlier.

Request parameters

container_id
string optional

Id of container to build report for. Caller must have VIEW_CONTENT capability for specified container.

Example:
12345
medium_id
string optional

Id of medium to build report for

Example:
3432
group_ids
string optional

Comma-separated list of groups ids

Example:
123, 34, 5454, 45
template_name
string required

Name of the template

Example:
template_name

Responses

201 Created
Body
Object
linked
Object
meta
Object
lrs_reports
Object
id
unknown nullable
href
string
links
Object
meta
Object
pagination
Object
actions
Array of unknown
url
string
Example:
https://sandbox.watershedlrs.com/app/index.html#/share/tmp_219f703a4f79
card_url
string
Example:
https://sandbox.watershedlrs.com/app/index.html#/share/tmp_219f703a4f79?view=card
Examples
{
    "linked": {},
    "meta": {},
    "lrs_reports": {
        "id": null,
        "href": "",
        "links": {},
        "meta": {
            "pagination": {},
            "actions": [
                null
            ]
        },
        "url": "https://sandbox.watershedlrs.com/app/index.html#/share/tmp_219f703a4f79",
        "card_url": "https://sandbox.watershedlrs.com/app/index.html#/share/tmp_219f703a4f79?view=card"
    }
}
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Authentication
GET /access_keys/{key}
POST /access_keys/session
POST /access_keys/platform
DELETE /access_keys/{key}
GET /api/default_authentication_options/{optionId}
GET /api/default_authentication_options
Viewing Access Key
GET /access_keys/{key}

Viewing access key resource.

For details, see Authentication and Authorization.

The method also returns the list of Roles returned by the method Viewing Own Administrative Roles as users.roles.

User executing this request must either have permission MANAGE_IDENTITIES or the key must be his own.

Path variables

key
string required

The access key

Example:
cf8ac35eca7977f9e6a05f4d7e8f4ff7

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: created_by.modified_by,users,users.roles, users.created_by,users_modified_by. Object users refers to the User for whom the key is issued.
Object roles refers to Own Administrative Roles.

Example:
roles

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/access_keys/cf8ac35eca7977f9e6a05f4d7e8f4ff7 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "access_keys": {
        "id" : "12345",
        "type" : "SESSION",
        "key" : "cf8ac35eca7977f9e6a05f4d7e8f4ff7",
        "http_user_agent" : "Mozilla/5.0 (Windows NT 6.3; WOW64; Trident/7.0; rv:11.0) like Gecko",
        "ip_v4" : "173.74.130.253",
        "published" : true,
        "expires_at" : "2012-10-10T15:12:24Z",
        "created_at" : "2012-10-10T14:12:24Z",
        "modified_at" : "2012-10-10T14:12:24Z",
        "href" : "https://tenant.kzoplatform.com/api/access_keys/12345",
        "links" : {
            "created_by" : {
                "username" : "admin",
                "type" : "users"
            },
            "modified_by" : {
                "username" : "admin",
                "type" : "users"
            },
            "users": "admin"
        },
        "meta": {
            "actions": [{
                "label": "ACCESS_KEY___DELETE",
                "href" : "https://tenant.kzoplatform.com/api/access_keys/12345",
                "method" : "DELETE"
            }],
            "pipeline_status": "READY",
            "pipeline_resource": {
                "href" : "https://tenant.kzoplatform.com/api/access_keys/12345",
                "type": "access_keys"
            }
        }
    },
    "linked": {
        "users": [{
            "id": 2,
            "username": "admin",
            "links": {
                "roles": [ 2, 3 ]
                ...
            }
            ...
        }],
        "roles": [{
            "id": 2
            ...
        },{
            "id": 3
            ...
        }]
    },
    "meta": {}
}
Creating Session Access Key
POST /access_keys/session

Creates a session access key.

User executing this request must have permission MANAGE_IDENTITIES. For details, see Authentication and Authorization.

The response is returned as if include=created_by.modified_by,users,users.created_by,users_modified_by,users.roles were set.

Request body

Object
access_keys
Object
username
string

User’s login

browser_session_id
string

Id of browser’s session, to sync authentication requests

Examples

Request to create session key for user with username = user1 from browser session with id AAAA-FFFF

{
    "access_keys": {
        "username": "user1",
        "browser_session_id": "AAAA-FFFF"
    }
}

Responses

201 Created
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

404 Not Found

In case of miss of browser’s session with passed id (browser_session_id).

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Access Key.

POST https://tenant.kzoplatform.com/api/access_keys/session HTTP/1.1 

Content-Type: application/json

{
    "access_keys": {
        "username" : "admin"
    }
}
Creating Session Access Key: Password Authentication
POST /access_keys/password

Used by an API client to authenticate with username and password and establish a session. For details, see Authentication and Authorization.

Does not require the User to be authenticated.

The response is returned as if include=created_by.modified_by,users,users.created_by,users_modified_by,users.roles were set.

Request body

Object
access_keys
Object
username
string

User’s login

password
string

User’s password

browser_session_id
string

Id of browser’s session, to sync authentication requests

Examples

Request to create user session for user with username=user1 who has password password1 from session of browser with id AAA_FFF.

{
    "access_keys": {
        "username": "user1",
        "password": "password1",
        "browser_session_id": "AAA_FFF"
    }
}

Responses

201 Created
Headers
Location
string optional

Contains the URI of the newly created resource.

401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

404 Not Found

In case of miss of browser’s session with passed id (browser_session_id).

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Access Key.

POST https://tenant.kzoplatform.com/api/access_keys/password HTTP/1.1 

Content-Type: application/json

{
    "access_keys": {
        "username" : "admin",
        "password" : "myCrypticPassw0rd"
    }
}
Creating Session Access Key for Public Access
POST /access_keys/public

Does not require the User to be authenticated. As a result of the method execution, the caller will be authenticated as user anonymous.

Requires public access to be enabled for the given Tenant.

The response is returned as if include=created_by.modified_by,users,users.created_by,users_modified_by,users.roles were set.

Request body

Object
access_keys
Object
browser_session_id
string

Id of browser’s session, to sync authentication requests

Examples

Request to create the session for anonymous user from browser’s session with id = ‘AAA_FFF’.

{
    "access_keys": {
        "browser_session_id": "AAA_FFF"
    }
}

Responses

201 Created
403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

404 Not Found

In case of miss of browser’s session with passed id (browser_session_id).

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

No request body is expected for this request.

The response is the same as that of the method Viewing Access Key.

POST https://tenant.kzoplatform.com/api/access_keys/public HTTP/1.1 
Creating Platform Access Key
POST /access_keys/platform

Creates a platform access key.

User executing this request must have permission MANAGE_IDENTITIES. For details, see Authentication and Authorization.

The response is returned as if include=created_by.modified_by,users,users.created_by,users_modified_by,users.roles were set.

Request body

Object
access_keys
Object
username
string

Username

Example:
admin
expires_at
string date

Date when platform key will expired. Required field.

Example:
2014-10-10T14:13:24.000Z

Responses

201 Created
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/access_keys/platform HTTP/1.1 

Content-Type: application/json

{
    "access_keys": {
        "username" : "admin",
        "expires_at" : "2014-10-10T14:13:24.000Z"
    }
}
Deleting Access Key
DELETE /access_keys/{key}

Deletes access key, so that user session associated with it becomes invalid.

For session Access Keys, requires either Permission assigning Role IDENTITY_MANAGER, or the key to be owned by the the User calling this method. For platform Access Keys, requires Permission assigning Role IDENTITY_MANAGER. For details, see Authentication and Authorization.

Path variables

key
string required

The Access Key.

Example:
cf8ac35eca7977f9e6a05f4d7e8f4ff7

Responses

204 No Content
401 Unauthorized

The request requires Authentication and Authorization.

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/access_keys/cf8ac35eca7977f9e6a05f4d7e8f4ff7 HTTP/1.1 
Change default authentication option
GET /api/default_authentication_options/{optionId}

Sets the default authetnication option using specified id. Id of option can be fetched from the response of /api/client_init. Only one option can be marked as default, so this method moves default flag from previous authentication option to the new one. Result can be checked using /api/client_init or GET to /api/default_authentication_options. Method requires precense of MANAGE_TENANT capability for caller.

Path variables

optionId
string required

Id of option to be set as default

Responses

200 OK
403 Forbidden

If user doesn’t have required capability

404 Not Found

IF there is no authentication option with passed id.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Get current default authentication option
GET /api/default_authentication_options

Gets current default authentication option. Requires MANAGE_TENANT capability.

Containers

Containers are abstract objects that can either contain media (such as videos) or other containers to form a hierarchy. All media created must belong to a container.

Only one root container is allowed, which is created automatically during the tenant creation process. Therefore, all containers created through the API must belong to another container.

GET /containers/{id}
GET /containers/{ids}
GET /containers
POST /containers/{id}/container
POST /containers/root/container
PUT /containers/{id}
PATCH /containers/{id}
DELETE /containers/{id}
POST /containers/{id}/meta/order
GET /playlist/{id}
GET /containers/{id}/containers
GET /containers/{id}/media
GET /containers/{id}/playlist_entries
Viewing Container
GET /containers/{id}

Fetch a container with a given ID.

Requires Permission assigning Role VIEWER on the given Container.

Pagination: containers, media.

This endpoint supports 2 output modes of operation: the normal and the proxy ones.

The normal mode is used when child containers and/or media are requested (see parameter include) as containers and media, respectively. In this mode:

  1. links in container objects contain unordered sets media and containers, containing direct links to corresponding child media and containers, respectively.
  2. Order of child containers and media is represented by meta.order of the container object.
  3. Child containers and media are two separate relationships, so their paginations are independent from each other.

The proxy mode is used when child containers and/or media are requested (see parameter include) as playlist_entries.container and playlist_entries.medium, respectively. In this mode:

  1. links in container objects contain arrays playlist_entries, containing links to proxy objects linked.playlist_entries.
  2. Each element of linked.playlist_entries is a link to the corresponding container/medium.
  3. Order of child containers and media is represented by the order of links to the corresponding proxy objects in links.playlist_entries of the container object.
  4. Child containers and media are considered as a single heterogeneous collection, with the pagination across this collection.

Note that if modes are mixed up in include, 400 This endpoint can be used either in normal or in proxy mode. will be returned. This applies also to subordinate relationships of containers and media. For example, if media are requested in the proxy mode (playlist_entries.medium), their slide decks should be, too (playlist_entries.medium.slide_deck).

Path variables

id
number required

The id of container

Example:
1

Request parameters

unpublished
boolean optional

Whether to include resources with attribute published = false into the response. API user needs to have specific permissions to be able to access unpublished content. Default value is false.

Example:
true
child_depth
number optional

Depth of the heirarchy of Container resources to be included in the response (namely, into the top-level collection linked, resource-level collection links). Value 0 means no children are included, value -1 means the full hierarchy is included. Default value is 0.

Example:
1
parent_depth
number optional

Depth of the heirarchy of Container resources up from the given Container (using only links of type ORIGINAL) to be included in the response (namely, into the top-level collection linked, resource-level collection links). Value 0 means no parent are included, value -1 means the full hierarchy is included. Default value is 0. For the topmost Container, no parent is specified.

Example:
1
include
string optional

Comma-separated list of associated objects which should be included in the response. Applicable to all levels of the hierarchy but the deepest one. Default value: empty. What can be included at most in the normal mode: parent,containers,media,containers.modified_by,containers.created_by, media.modified_by,media.created_by,media.slide_deck,media.parent,containers.authored_by,media.authored_by,media.closed_captions_sets,media.closed_captions_sets.languages,favorites,favorites.containers,favorites.media,favorites.created_by,media.favorites,media.favorites.media,media.favorites.created_by,containers.favorites,containers.favorites.containers,containers.favorites.created_by. What can be included at most in the proxy mode: parent,playlist_entries.container,playlist_entries.medium,playlist_entries.container.modified_by,playlist_entries.container.created_by,playlist_entries.medium.modified_by,playlist_entries.medium.created_by,playlist_entries.medium.slide_deck,playlist_entries.medium.parent,playlist_entries.container.authored_by,playlist_entries.medium.authored_by,playlist_entries.medium.closed_captions_sets,playlist_entries.medium.closed_captions_sets.languages,favorites,favorites.containers,favorites.media,favorites.created_by,playlist_entries.medium.favorites,playlist_entries.medium.favorites.media,playlist_entries.medium.favorites.created_by,playlist_entries.container.favorites,playlist_entries.container.favorites.containers,playlist_entries.container.favorites.created_by Inclusion of Containers is also controlled by parameters parent_depth and child_depth. Use include=parent to fill respective link for all primary and linked containers. Use include=media.parent to fill respective link for all linked media.

Example:
media
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10
preauth_actions
boolean optional

Whether to include actions to get and play container by unauthenticated users. The URLs of actions will contain temporal access key.

Default:
false

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/containers/14 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "containers": {
        "id" : "14",
        "title" : "Yep, this is title",
        "description" : "My description",
        "root" : false,
        "published" : true,
        "created_at" : "2012-10-10T14:12:24Z",
        "modified_at" : "2012-10-10T14:12:24Z",
        "comment_notification": true,
        "href": "https://tenant.kzoplatform.com/api/containers/14",
        "screenshot_href": "http://d6mgdbc2kfx06.cloudfront.net/...",
        "links" : {
            "created_by" : {
                "username" : "admin",
                "type" : "users"
            },
            "modified_by" : {
                "username" : "admin",
                "type" : "users"
            },
            "parent": {
                "id": 12,
                "type": "containers"
            },
            "containers": [2, 3, 4],
            "media": [5, 6]
        },
        "meta": {
            "collective": {
                "views": 234958,
                "trt_msec": 38522000,
                "media_count": 24,
                "container_count": 6
            },
            "actions": [{
                "label": "CONTAINER___GET",
                "href" : "https://tenant.kzoplatform.com/api/containers/14",
                "method" : "GET"
            },{
                "label": "CONTAINER___EDIT_METADATA",
                "href" : "https://tenant.kzoplatform.com/api/containers/14",
                "method" : "PATCH"
            },{
                "label": "CONTAINER___UPDATE",
                "href" : "https://tenant.kzoplatform.com/api/containers/14",
                "method" : "PUT"
            }],
            "order": {
                "containers": {
                    "0": 2,
                    "2": 3,
                    "3": 4
                },
                "media": {
                    "1": 6,
                    "4": 5
                }
            },
            "pipeline_status": "EDITING",
            "pipeline_resource": {
                "href": "https://tenant.kzoplatform.com/api/containers/14",
                "type": "containers"
            }
        },
        "thumbnails": null
    },
    "linked": {
        "containers": [{
            "id": 2,
            "links": {
                "containers": [20, 30],
                "media": [200, 300]
                ...
            },
            "meta": {
                "order": {
                    "containers": {
                        "1": 30,
                        "2": 20
                    },
                    "media": {
                        "0": 200,
                        "3": 300
                    }
                }
                ...
            }
            ...
        }, {
            "id": 3,
            "links": {
                "containers": [50],
                "media": [500]
                ...
            },
            "meta": {
                "order": {
                    "containers": {
                        "1": 50
                    },
                    "media": {
                        "0": 500
                    }
                }
                ...
            }
            ...
        }, {
            "id": 4,
            "links": {
                "containers": [],
                "media": []
                ...
            },
            "meta": {
                "order": {
                    "containers": {},
                    "media": {}
                }
                ...
            }
            ...
        }, {
            "id": 20,
            "links": {
                "containers": [],
                "media": []
                ...
            },
            "meta": {
                "order": {
                    "containers": {},
                    "media": {}
                }
                ...
            }
            ...
        }, {
            "id": 30,
            "links": {
                "containers": [],
                "media": []
                ...
            },
            "meta": {
                "order": {
                    "containers": {},
                    "media": {}
                }
                ...
            }
            ...
        }, {
            "id": 50,
            "links": {
                "containers": [],
                "media": []
                ...
            },
            "meta": {
                "order": {
                    "containers": {},
                    "media": {}
                }
                ...
            }
            ...
        }, {
            "id": 20,
            "links": {
                "containers": [],
                "media": []
                ...
            },
            "meta": {
                "order": {
                    "containers": {},
                    "media": {}
                }
                ...
            }
            ...
        }, {
            "id": 12,
            "links": {
                "containers": [],
                "media": []
                ...
            },
            "meta": {
                "order": {
                    "containers": {
                        "0": 12
                    },
                    "media": {}
                }
                ...
            }
            ...
        }],
        "media": [{
            "id": 5
            ...
        }, {
            "id": 6
            ...
        }, {
            "id": 200
            ...
        }, {
            "id": 300
            ...
        }, {
            "id": 500
            ...
        }],
        "users": [{
            "id": 1,
            "username": "admin"
            ...
        }]
    },
    "meta": {}
}
GET https://tenant.kzoplatform.com/api/containers/14?parent_depth=-1&child_depth=-1&include=parent,playlist_entries.container,playlist_entries.medium HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "containers": {
        "id" : "14",
        "title" : "Yep, this is title",
        "description" : "My description",
        "root" : false,
        "published" : true,
        "created_at" : "2012-10-10T14:12:24Z",
        "modified_at" : "2012-10-10T14:12:24Z",
        "comment_notification": true,
        "href": "https://tenant.kzoplatform.com/api/containers/14",
        "screenshot_href": "http://d6mgdbc2kfx06.cloudfront.net/...",
        "links" : {
            "created_by" : {
                "username" : "admin",
                "type" : "users"
            },
            "modified_by" : {
                "username" : "admin",
                "type" : "users"
            },
            "parent": {
                "id": 12,
                "type": "containers"
            },
            "containers": [],
            "media": [],
            "playlist_entries": ["C_2", "M_6", "C_3", "C_4", "M_5"]
        },
        "meta": {
            "pagination": {
                "playlist_entries": {
                    "total_results": 5,
                    "links": {
                        "first": "https://tenant.kzoplatform.com/api/containers/14/playlist_entries?page=1&page_size_primary=10000&page_size_related=10000",
                        "last": "https://tenant.kzoplatform.com/api/containers/14/playlist_entries?page=1&page_size_primary=10000&page_size_related=10000"
                    }
                }
            },
            "collective": {
                "views": 234958,
                "trt_msec": 38522000,
                "media_count": 24,
                "container_count": 6
            },
            "actions": [{
                "label": "CONTAINER___GET",
                "href" : "https://tenant.kzoplatform.com/api/containers/14",
                "method" : "GET"
            },{
                "label": "CONTAINER___EDIT_METADATA",
                "href" : "https://tenant.kzoplatform.com/api/containers/14",
                "method" : "PATCH"
            },{
                "label": "CONTAINER___UPDATE",
                "href" : "https://tenant.kzoplatform.com/api/containers/14",
                "method" : "PUT"
            }],
            "order": {
                "containers": {},
                "media": {}
            },
            "pipeline_status": "EDITING",
            "pipeline_resource": {
                "href": "https://tenant.kzoplatform.com/api/containers/14",
                "type": "containers"
            }
        },
        "thumbnails": null
    },
    "linked": {
        "playlist_entries": [{
            "id": "C_2",
            "href": "",
            "links":{"container": "2"},
            "meta":{"pagination":{}, "actions":[]}
        },{
            "id": "M_6",
            "href": "",
            "links":{"medium": "6"},
            "meta":{"pagination":{}, "actions":[]}
        },{
            "id": "C_3",
            "href": "",
            "links":{"container": "3"},
            "meta":{"pagination":{}, "actions":[]}
        },{
            "id": "C_4",
            "href": "",
            "links":{"container": "4"},
            "meta":{"pagination":{}, "actions":[]}
        },{
            "id": "M_5",
            "href": "",
            "links":{"medium": "5"},
            "meta":{"pagination":{}, "actions":[]}
        },{
            "id": "C_20",
            "href": "",
            "links":{"container": "20"},
            "meta":{"pagination":{}, "actions":[]}
        },{
            "id": "C_30",
            "href": "",
            "links":{"container": "30"},
            "meta":{"pagination":{}, "actions":[]}
        },{
            "id": "M_200",
            "href": "",
            "links":{"medium": "200"},
            "meta":{"pagination":{}, "actions":[]}
        },{
            "id": "M_300",
            "href": "",
            "links":{"medium": "300"},
            "meta":{"pagination":{}, "actions":[]}
        },{
            "id": "M_500",
            "href": "",
            "links":{"medium": "500"},
            "meta":{"pagination":{}, "actions":[]}
        },{
            "id": "C_50",
            "href": "",
            "links":{"container": "50"},
            "meta":{"pagination":{}, "actions":[]}
        }],
        "containers": [{
            "id": 2,
            "links": {
                "playlist_entries": ["M_200", "C_30", "C_20", "M_300"]
                ...
            },
            "meta": {
                "order": {},
                "pagination": {...}
                ...
            }
            ...
        }, {
            "id": 3,
            "links": {
                "playlist_entries": ["M_500", "C_50"]
                ...
            },
            "meta": {
                "order": {},
                "pagination": {...}
                ...
            }
            ...
        }, {
            "id": 4,
            "links": {
                "playlist_entries": []
                ...
            },
            "meta": {
                "order": {},
                "pagination": {...}
                ...
            }
            ...
        }, {
            "id": 20,
            "links": {
                "playlist_entries": []
                ...
            },
            "meta": {
                "order": {},
                "pagination": {...}
                ...
            }
            ...
        }, {
            "id": 30,
            "links": {
                "playlist_entries": []
                ...
            },
            "meta": {
                "order": {},
                "pagination": {...}
                ...
            }
            ...
        }, {
            "id": 50,
            "links": {
                "playlist_entries": []
                ...
            },
            "meta": {
                "order": {},
                "pagination": {...}
                ...
            }
            ...
        }, {
            "id": 20,
            "links": {
                "playlist_entries": []
                ...
            },
            "meta": {
                "order": {},
                "pagination": {...}
                ...
            }
            ...
        }, {
            "id": 12,
            "links": {
                "playlist_entries": []
                ...
            },
            "meta": {
                "order": {},
                "pagination": {...}
                ...
            }
            ...
        }],
        "media": [{
            "id": 5
            ...
        }, {
            "id": 6
            ...
        }, {
            "id": 200
            ...
        }, {
            "id": 300
            ...
        }, {
            "id": 500
            ...
        }],
        "users": [{
            "id": 1,
            "username": "admin"
            ...
        }]
    },
    "meta": {}
}
Viewing Multiple Containers
GET /containers/{ids}

Fetch containers with specific IDs.

Requires Permission assigning Role VIEWER on the given Containers.

Pagination: containers, media.

This endpoint supports 2 output modes of operation: the normal and the proxy ones.

The normal mode is used when child containers and/or media are requested (see parameter include) as containers and media, respectively. In this mode:

  1. links in container objects contain unordered sets media and containers, containing direct links to corresponding child media and containers, respectively.
  2. Order of child containers and media is represented by meta.order of the container object.
  3. Child containers and media are two separate relationships, so their paginations are independent from each other.

The proxy mode is used when child containers and/or media are requested (see parameter include) as playlist_entries.container and playlist_entries.medium, respectively. In this mode:

  1. links in container objects contain arrays playlist_entries, containing links to proxy objects linked.playlist_entries.
  2. Each element of linked.playlist_entries is a link to the corresponding container/medium.
  3. Order of child containers and media is represented by the order of links to the corresponding proxy objects in links.playlist_entries of the container object.
  4. Child containers and media are considered as a single heterogeneous collection, with the pagination across this collection.

Note that if modes are mixed up in include, 400 This endpoint can be used either in normal or in proxy mode. will be returned. This applies also to subordinate relationships of containers and media. For example, if media are requested in the proxy mode (playlist_entries.medium), their slide decks should be, too (playlist_entries.medium.slide_deck).

Path variables

ids
string required

Comma-separated list of the IDs of multiple containers

Example:
1,2

Request parameters

unpublished
boolean optional

Whether to include resources with attribute published = false into the response. API user needs to have specific permissions to be able to access unpublished content. Default value is false.

Example:
true
child_depth
number optional

Depth of the heirarchy of Container resources to be included in the response (namely, into the top-level collection linked, resource-level collection links). Value 0 means no children are included, value -1 means the full hierarchy is included. Default value is 0.

Example:
2
parent_depth
number optional

Depth of the heirarchy of Container resources up from the given Container (using only links of type ORIGINAL) to be included in the response (namely, into the top-level collection linked, resource-level collection links). Value 0 means no parent are included, value -1 means the full hierarchy is included. Default value is 0. For the topmost Container, no parent is specified.

Example:
1
include
string optional

Comma-separated list of associated objects which should be included in the response. Applicable to all levels of the hierarchy but the deepest one. Default value: empty. What can be included at most in the normal mode: parent,containers,media,containers.modified_by,containers.created_by, media.modified_by,media.created_by,media.slide_deck,media.parent,containers.authored_by,media.authored_by,media.closed_captions_sets,media.closed_captions_sets.languages,favorites,favorites.containers,favorites.media,favorites.created_by,media.favorites,media.favorites.media,media.favorites.created_by,containers.favorites,containers.favorites.containers,containers.favorites.created_by. What can be included at most in the proxy mode: parent,playlist_entries.container,playlist_entries.medium,playlist_entries.container.modified_by,playlist_entries.container.created_by,playlist_entries.medium.modified_by,playlist_entries.medium.created_by,playlist_entries.medium.slide_deck,playlist_entries.medium.parent,playlist_entries.container.authored_by,playlist_entries.medium.authored_by,playlist_entries.medium.closed_captions_sets,playlist_entries.medium.closed_captions_sets.languages,favorites,favorites.containers,favorites.media,favorites.created_by,playlist_entries.medium.favorites,playlist_entries.medium.favorites.media,playlist_entries.medium.favorites.created_by,playlist_entries.container.favorites,playlist_entries.container.favorites.containers,playlist_entries.container.favorites.created_by Inclusion of Containers is also controlled by parameters parent_depth and child_depth. Use include=parent to fill respective link for all primary and linked containers. Use include=media.parent to fill respective link for all linked media.

Example:
media.modified_by
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

This example only demonstrates the key differences of the response from the response of the method Viewing Container.

GET https://tenant.kzoplatform.com/api/containers/1,2 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "containers": [{
        "id" : "1"
        ...
    }, {
        "id" : "2"
        ...
    }]
    ...
}
Viewing Topmost Available Containers
GET /containers/top

This method returns the topmost avalilable Containers in the hierarchy to which the user has access. Hence, if the user has access to the full Container hierarchy, the only Container returned in the primary resource collection will be the root Container. If the user has access only to one or more subtrees of the Container tree, the Containers which are roots of all Container hierarchy subtrees available to the user will be returned.

Does not require Permissions.

Pagination: primary, containers, media.

This endpoint supports 2 output modes of operation: the normal and the proxy ones.

The normal mode is used when child containers and/or media are requested (see parameter include) as containers and media, respectively. In this mode:

  1. links in container objects contain unordered sets media and containers, containing direct links to corresponding child media and containers, respectively.
  2. Order of child containers and media is represented by meta.order of the container object.
  3. Child containers and media are two separate relationships, so their paginations are independent from each other.

The proxy mode is used when child containers and/or media are requested (see parameter include) as playlist_entries.container and playlist_entries.medium, respectively. In this mode:

  1. links in container objects contain arrays playlist_entries, containing links to proxy objects linked.playlist_entries.
  2. Each element of linked.playlist_entries is a link to the corresponding container/medium.
  3. Order of child containers and media is represented by the order of links to the corresponding proxy objects in links.playlist_entries of the container object.
  4. Child containers and media are considered as a single heterogeneous collection, with the pagination across this collection.

Note that if modes are mixed up in include, 400 This endpoint can be used either in normal or in proxy mode. will be returned. This applies also to subordinate relationships of containers and media. For example, if media are requested in the proxy mode (playlist_entries.medium), their slide decks should be, too (playlist_entries.medium.slide_deck).

Request parameters

unpublished
boolean optional

Whether to include resources with attribute published = false into the response. API user needs to have specific permissions to be able to access unpublished content. Default value is false.

Example:
true
child_depth
number optional

Depth of the heirarchy of Container resources to be included in the response (namely, into the top-level collection linked, resource-level collection links). Value 0 means no children are included, value -1 means the full hierarchy is included. Default value is 0.

Example:
0
parent_depth
integer optional

Depth of the heirarchy of Container resources up from the given Container to be included in the response (namely, into the top-level collection linked, resource-level collection links). Value 0 means no parent are included, value -1 means the full hierarchy is included. Default value is 0. For the topmost Container, no parent is specified.

Actually, parent will be included if all the following conditions are true:

  • Root container is available to the API user.
  • top_level=true.
  • parent_depth=-1 or greater than 0.
  • include contains parent
  • include contains containers or playlist_entries.container
Default:
0
include
string optional

Comma-separated list of associated objects which should be included in the response. Applicable to all levels of the hierarchy but the deepest one. Default value: empty. What can be included at most in the normal mode: parent,containers,media,containers.modified_by,containers.created_by, media.modified_by,media.created_by,media.slide_deck,media.parent,containers.authored_by,media.authored_by,media.closed_captions_sets,media.closed_captions_sets.languages,favorites,favorites.containers,favorites.media,favorites.created_by,media.favorites,media.favorites.media,media.favorites.created_by,containers.favorites,containers.favorites.containers,containers.favorites.created_by. What can be included at most in the proxy mode: parent,playlist_entries.container,playlist_entries.medium,playlist_entries.container.modified_by,playlist_entries.container.created_by,playlist_entries.medium.modified_by,playlist_entries.medium.created_by,playlist_entries.medium.slide_deck,playlist_entries.medium.parent,playlist_entries.container.authored_by,playlist_entries.medium.authored_by,playlist_entries.medium.closed_captions_sets,playlist_entries.medium.closed_captions_sets.languages,favorites,favorites.containers,favorites.media,favorites.created_by,playlist_entries.medium.favorites,playlist_entries.medium.favorites.media,playlist_entries.medium.favorites.created_by,playlist_entries.container.favorites,playlist_entries.container.favorites.containers,playlist_entries.container.favorites.created_by Inclusion of Containers is also controlled by parameters parent_depth and child_depth. Use include=parent to fill respective link for all primary and linked containers. Use include=media.parent to fill respective link for all linked media.

Example:
media,media.modified_by,media.created_by
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10
top_level
boolean optional

Applies if the root Container is available to API User: if top_level=false, primary containers contains only the root Container, otherwise it contains immediate child containers of the root Container.

Default:
false
sort
string optional

Comma-separated list of attributes by which sorting should be performed. The default sort order is ascending. A - prefix to attribute name on any sort field specifies a descending sort order. Default is sorting by the place in the whole container hierarchy according to the number of the container among siblings, the number of its parent, etc. Unsupported attributes are ignored. Supported attributes:

  • created_at - date and time of the creation of the container.
  • views - total number of views of all media under the container.
  • favorites - number of favorites on the container.
  • title - title of the container.
  • comments - total number of comments on all media under the container.
  • trt_msec - total length of all media under the container.
  • subscriptions - number of users who is subscribed on the container.
  • trending - total number of recent hits on all media under the container.
Example:
views,comments

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Multiple Containers.

GET https://tenant.kzoplatform.com/api/containers/top HTTP/1.1 
Searching Containers
GET /containers

Fetch containers satisfying specific criteria.

Does not require Permissions.

Pagination: primary, containers, media.

Request parameters

unpublished
boolean optional

Whether to include resources with attribute published = false into the response. API user needs to have specific permissions to be able to access unpublished content. Default value is false.

Example:
true
title
string optional

Filtering by container title with partial matching.

Example:
New
description
string optional

Filtering by container description with partial matching

Example:
York
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10

Responses

200 OK

No associated resources are included with the response.

401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

Find all containers titles of which include the word ‘new’.

The response is the same as that of the method Viewing Multiple Containers.

GET https://tenant.kzoplatform.com/api/containers?title=new HTTP/1.1 
Creating Container
POST /containers/{id}/container

Creates a container.

Requires Permission assigning Role CONTENT_CREATOR_CONTAINERS on the parent Container of the Container to be created.

Path variables

id
number required

The id of the parent container that this container should become a child of

Example:
1

Responses

201 Created

No associated resources are included with the response.

Headers
Location
string optional

Contains the URI of the newly created resource.

401 Unauthorized

The request requires Authentication and Authorization.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Container.

POST https://tenant.kzoplatform.com/api/containers/1/container HTTP/1.1 

Content-Type: application/json

{
    "containers": {
        "title" : "Marketing Videos",
        "description": "All of our Marketing videos will go in here"
    }
}
POST https://tenant.kzoplatform.com/api/containers/{id}/container HTTP/1.1 

Content-Type: application/json

{
    "containers": {
        "title" : "Marketing Videos",
        "description": "All of our Marketing videos will go in here",
        "authored_by": "author"
    }
}
Creating Top-Level Container
POST /containers/root/container

Creates a new top-level Container – a direct descendant of the root Container.

Requires Permission assigning Role TOP_LEVEL_CONTAINER_CREATOR on the root Container. If the User has not been assigned Role CONTENT_VIEWER on the root Container, the newly created container will be returned parentless.

Responses

201 Created
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Container.

POST https://tenant.kzoplatform.com/api/containers/root/container HTTP/1.1 
Replacing Container
PUT /containers/{id}

Complete replacement of container.

Requires Permission assigning Role CONTENT_UPDATER on the given Container.

Requires Permission assigning Role AUTHORSHIP_MANAGER on the given Container for updating an author of Container.

Path variables

id
number required

The id of container

Example:
1

Responses

200 OK

No associated resources are included with the response.

401 Unauthorized

The request requires Authentication and Authorization.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Container.

PUT https://tenant.kzoplatform.com/api/containers/1 HTTP/1.1 

Content-Type: application/json

{
    "containers": {
        "title" : "Marketing Videos",
        "description": "All of our Marketing videos will go in here",
        "parent_id" : "id of new parent(optional field)"
    }
}
PUT https://tenant.kzoplatform.com/api/containers/{id} HTTP/1.1 

Content-Type: application/json

{
    "containers": {
        "title" : "Marketing Videos",
        "description": "All of our Marketing videos will go in here",
        "parent_id" : "id of new parent(optional field)",
        "authored_by": "author"
    }
}
Updating Container
PATCH /containers/{id}

Partial update of the container.

Requires Permission assigning Role CONTENT_UPDATER on the given Container.

Requires Permission assigning Role AUTHORSHIP_MANAGER on the given Container for updating an author of Container.

Path variables

id
number required

The id of container

Example:
1

Responses

200 OK

No associated resources are included with the response.

401 Unauthorized

The request requires Authentication and Authorization.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

Request is an array representing sequence of patch operations.

The response is the same as that of the method Viewing Container.

PATCH https://tenant.kzoplatform.com/api/containers/5 HTTP/1.1 

Content-Type: application/json

[{ 
    "op": "replace", 
    "path": "/title", 
    "value": "It is new title" 
}, { 
    "op": "replace", 
    "path": "/description", 
    "value": "It is new description" 
}, { 
    "op": "replace", 
    "path": "/parent_id", 
    "value": "123"
}, {
    "op": "replace",
    "path": "/created_at",
    "value": "2016-05-14T08:05:50.374Z"
}]
Deleting Container
DELETE /containers/{id}

Deletes container

Requires Permission assigning Role CONTENT_DELETER on the given Container.

Path variables

id
number required

The id of container

Example:
2

Responses

204 No Content

The response does not include body.

401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/containers/10 HTTP/1.1 
Reordering Children of a Container
POST /containers/{id}/meta/order

It is not possible to add or delete children of a Container using this method, only reorder. Error 400 is returned if either duplicate keys are provided or not all IDs of Media and Containers which are children of the given Container are specified. Keys have to be non-negative integers, but not necessarily consecutive ones.

The endpoint supports request payloads in normal and proxy modes.

In the normal mode, the order is represented by 2 separate assotiative arrays, one for media and one for containers. Each key is a unique (across all immediate child containers and media of the container) integer priority, while the corresponding value is the ID of the container/medium, which should have that priority.

In the proxy mode, all immediate child containers and media should be represented by a single heterogeneous array of their encoded IDs. Encoded ID of container {id} should be "C_{id}". Encoded ID of medium {id} should be "M_{id}".

Mixing of the normal and proxy modes is forbidden: 400 Bad Request will be returned.

Path variables

id
number optional

The ID of Container

Example:
123

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/containers/123/meta/order HTTP/1.1 

Content-Type: application/json

{
    "order": {
        "containers": {
            "0": 3,
            "2": 2,
            "3": 4
        },
        "media": {
            "1": 6,
            "4": 5
        }
    }
}
POST https://tenant.kzoplatform.com/api/containers/123/meta/order HTTP/1.1 

Content-Type: application/json

{
    "order": {
        "playlist_entries": ["C_3", "M_6", "C_2", "C_4", "M_5"]
    }
}
Viewing Playlist
GET /playlist/{id}

Fetch all PUBLISHED media under container with the specified id

Path variables

id
string required

The id of container

Example:
123

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/playlist/123 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "playlist": {
    "id": 123,
    "links": {
      "media": [ 1, 89 ]
    }
  },
  "linked": {
    "media": [{
      "id": "1"
      ...
    },{
      "id": "89"
      ...
    ]},
  "meta": {}
}
Viewing Immediate Child Containers
GET /containers/{id}/containers

Fetch containers linked directly with a container with a given ID as children (link type does not matter).

Requires Permission assigning Role VIEWER on the given Container.

Pagination: primary, containers, media.

This endpoint supports 2 output modes of operation: the normal and the proxy ones.

The normal mode is used when child containers and/or media are requested (see parameter include) as containers and media, respectively. In this mode:

  1. links in container objects contain unordered sets media and containers, containing direct links to corresponding child media and containers, respectively.
  2. Order of child containers and media is represented by meta.order of the container object.
  3. Child containers and media are two separate relationships, so their paginations are independent from each other.

The proxy mode is used when child containers and/or media are requested (see parameter include) as playlist_entries.container and playlist_entries.medium, respectively. In this mode:

  1. links in container objects contain arrays playlist_entries, containing links to proxy objects linked.playlist_entries.
  2. Each element of linked.playlist_entries is a link to the corresponding container/medium.
  3. Order of child containers and media is represented by the order of links to the corresponding proxy objects in links.playlist_entries of the container object.
  4. Child containers and media are considered as a single heterogeneous collection, with the pagination across this collection.

Note that if modes are mixed up in include, 400 This endpoint can be used either in normal or in proxy mode. will be returned. This applies also to subordinate relationships of containers and media. For example, if media are requested in the proxy mode (playlist_entries.medium), their slide decks should be, too (playlist_entries.medium.slide_deck).

Path variables

id
number required

The id of container

Example:
1

Request parameters

unpublished
boolean optional

Whether to include resources with attribute published = false into the response. API user needs to have specific permissions to be able to access unpublished content. Default value is false.

Example:
true
child_depth
number optional

Depth of the heirarchy of Container resources to be included in the response (namely, into the top-level collection linked, resource-level collection links). Value 0 means no children are included, value -1 means the full hierarchy is included.

Min: -1
parent_depth
number optional

Depth of the heirarchy of Container resources up from the given Container (using only links of type ORIGINAL) to be included in the response (namely, into the top-level collection linked, resource-level collection links). Value 0 means no parent are included, value -1 means the full hierarchy is included. For the topmost Container, no parent is specified.

Min: -1
include
string optional

Comma-separated list of associated objects which should be included in the response. Applicable to all levels of the hierarchy but the deepest one. Default value: empty. What can be included at most in the normal mode: parent,containers,media,containers.modified_by,containers.created_by, media.modified_by,media.created_by,media.slide_deck,media.parent,containers.authored_by,media.authored_by,media.closed_captions_sets,media.closed_captions_sets.languages,favorites,favorites.containers,favorites.media,favorites.created_by,media.favorites,media.favorites.media,media.favorites.created_by,containers.favorites,containers.favorites.containers,containers.favorites.created_by. What can be included at most in the proxy mode: parent,playlist_entries.container,playlist_entries.medium,playlist_entries.container.modified_by,playlist_entries.container.created_by,playlist_entries.medium.modified_by,playlist_entries.medium.created_by,playlist_entries.medium.slide_deck,playlist_entries.medium.parent,playlist_entries.container.authored_by,playlist_entries.medium.authored_by,playlist_entries.medium.closed_captions_sets,playlist_entries.medium.closed_captions_sets.languages,favorites,favorites.containers,favorites.media,favorites.created_by,playlist_entries.medium.favorites,playlist_entries.medium.favorites.media,playlist_entries.medium.favorites.created_by,playlist_entries.container.favorites,playlist_entries.container.favorites.containers,playlist_entries.container.favorites.created_by Inclusion of Containers is also controlled by parameters parent_depth and child_depth. Use include=parent to fill respective link for all primary and linked containers. Use include=media.parent to fill respective link for all linked media.

Example:
media
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10
sort
string optional

Comma-separated list of attributes by which sorting should be performed. The default sort order is ascending. A - prefix to attribute name on any sort field specifies a descending sort order. Default is sorting by the number of the container/medium among siblings. Unsupported attributes are ignored. Supported attributes:

  • created_at - date and time of the creation of the container or medium.
  • views - total number of views of the medium or all media under the container.
  • favorites - number of favorites on the container or medium.
  • title - title of the container or medium.
  • comments - total number of comments on the medium or all media under the container.
  • trt_msec - length of the medium or total length of all media under the container.
  • subscriptions - number of users who is subscribed on the container or medium.
  • trending - total number of recent hits on the medium or all media under the container.
  • type - first containers then media for ascending order
Example:
views,comments

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Fetching immediate media
GET /containers/{id}/media

Fetch media linked directly with a container with a given ID (link type does not matter).

Requires Permission assigning Role VIEWER on the given Container.

Pagination: primary.

Path variables

id
number required

The id of container

Request parameters

unpublished
boolean optional

Whether to include resources with attribute published = false into the response. API user needs to have specific permissions to be able to access unpublished content. Default value is false.

Example:
true
include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: media.created_by,media.modified_by, parent,parent.created_by,parent.modified_by, chapters,chapters.created_by,chapters.modified_by, original_videos,original_videos.created_by,original_videos.modified_by, video_renditions,video_renditions.created_by,video_renditions.modified_by, slide_decks,slide_decks.created_by,slide_decks.modified_by, slides,slides.created_by,slides.modified_by, used_slides,used_slides.created_by,used_slides.modified_by, comments,comments.created_by,comments.modified_by,comments.deleted_by, replies,replies.created_by,replies.modified_by,replies.deleted_by, video_rendition_options,screenshots,screenshot_options, montages,montage_options,media.authored_by,closed_captions_sets.

If Replies are included, it is assumed that unlimited depth is requested.

Example:
parent,parent.created_by
parent_depth
number optional

Depth of the heirarchy of Container resources up from the given Container (using only links of type ORIGINAL) to be included in the response (namely, into the top-level collection linked, resource-level collection links). Value 0 means no parent are included, value -1 means the full hierarchy is included.

Min: -1
Max: 2,147,483,647
Default:
0
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
Fetching Immediate Children
GET /containers/{id}/playlist_entries

Fetch playlist entries linked directly with a container with a given ID as children.

Requires Permission assigning Role CONTENT_VIEWER on the given Container.

Pagination: primary.

Path variables

id
number required

The id of container

Example:
1

Request parameters

unpublished
boolean optional

Whether to include resources with attribute published = false into the response. API user needs to have specific permissions to be able to access unpublished content. Default value is false.

Example:
true
include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most:

  • playlist_entries.container
  • playlist_entries.container.created_by
  • playlist_entries.container.authored_by
  • playlist_entries.container.modified_by
  • playlist_entries.container.parent
  • playlist_entries.medium
  • playlist_entries.medium.created_by
  • playlist_entries.medium.authored_by
  • playlist_entries.medium.modified_by
  • playlist_entries.medium.parent
  • playlist_entries.medium.slide_deck
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
q
string optional

Term to search for. When specified, the returned primary content is filtered according to this string.

Example:
awesome

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/containers/325641022015018940/playlist_entries?include=playlist_entries.container,playlist_entries.medium&page_size_primary=3 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "slide_decks": [],
        "containers": [
            {
                "id": "472060407171781682",
                "href": "https://staging-101.kzoinnovations.com/api/containers/472060407171781682?page_size_related=10000",
                "links": {
                    "favorites": {
                    },
                    "parent": {
                    },
                    "authored_by": {
                    },
                    "modified_by": {
                    },
                    "deleted_by": {
                    },
                    "playlist_entries": [
                    ],
                    "owned_by": {
                        "type": "users",
                        "username": "admin"
                    },
                    "containers": [
                    ],
                    "media": [
                    ],
                    "created_by": {
                    }
                },
                "meta": {
                    "notification_subscription": {
                        "direct": null,
                        "inherited": false
                    },
                    "pagination": {
                    },
                    "state": {
                        "pipeline_status": "EDITING",
                        "published": true,
                        "pipeline_resource": {
                            "href": "https://staging-101.kzoinnovations.com/api/containers/472060407171781682?page_size_related=10000",
                            "type": "containers"
                        }
                    },
                    "collective": {
                    },
                    "actions": [
                        {
                            "label": "CONTAINER_GET",
                            "href": "https://staging-101.kzoinnovations.com/api/containers/472060407171781682?page_size_related=10000",
                            "method": "GET"
                        }
                    ],
                    "order": {
                        "containers": {
                        },
                        "media": {
                        }
                    }
                },
                "root": false,
                "title": "Lexxxxx child",
                "description": null,
                "created_at": "2015-10-14T07:39:45.761Z",
                "modified_at": "2015-10-14T07:39:45.761Z",
                "deleted_at": null,
                "screenshot_href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/SCREENSHOT/612003726051251892.png?Expires=1495793925&Signature=NsRZDAhnP3JUNrYYOIz4lAQG8-~EBn-OrrzHXRbKWFwOvZbKIYqzuXBHGZOLExrflqQcCvbVpsW22tpWP99SqpYKvB~Qz7VT1gC-bYQXhJ0CoSPxzrhsiDvpFszmBPrWqBbEgp4Ae7rG0slUWR2A20A3Fgi2V7wjln1h7kCCtavG2TwIJRmYpMkCxlSvfAyjg4sHd6A9dq9vpH7pQs0fI4IFkH~8-Ey7eFFjsR0Ztnl-c992ycRmhrJ9iu3s3FUdE6QXS-0pErENV0RSoeYSk~H~42nXL6XLkK49y-u9TTU53Qv2enpD1SoZiQ3Sp6dhuzpp3DvF4VJPYR68ZcuYZw__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
                "thumbnails": [
                    ...
                ],
                "subscription": false
            }
        ],
        "media": [
            {
                "id": "328537880626468139",
                "href": "https://staging-101.kzoinnovations.com/api/media/328537880626468139?page_size_related=10000",
                "links": {
                    "favorites": {
                    },
                    "parent": {
                    },
                    "slides": [
                    ],
                    "authored_by": {
                    },
                    "comments": [
                    ],
                    "chapters": [
                    ],
                    "montages": [
                    ],
                    "closed_captions_sets": [
                    ],
                    "original_video": {
                    },
                    "deleted_by": {
                    },
                    "owned_by": {
                        "type": "users",
                        "username": "admin"
                    },
                    "created_by": {
                    },
                    "used_slides": [
                    ],
                    "screenshots": [
                    ],
                    "replies": [
                    ],
                    "modified_by": {
                    },
                    "video_renditions": [
                    ],
                    "screenshot_positions": [
                    ],
                    "slide_deck": {
                    }
                },
                "meta": {
                    "notification_subscription": {
                        "direct": "SUBSCRIPTION",
                        "inherited": false
                    },
                    "pagination": {
                    },
                    "state": {
                        "pipeline_status": "READY",
                        "published": true,
                        "pipeline_resource": {
                            "href": "https://staging-101.kzoinnovations.com/api/media/328537880626468139?page_size_related=10000",
                            "type": "media"
                        }
                    },
                    "metrics": {
                        "favorites": 0,
                        "comments": 0,
                        "views": 9
                    },
                    "actions": [
                        {
                            "label": "MEDIA_GET",
                            "href": "https://staging-101.kzoinnovations.com/api/media/328537880626468139?page_size_related=10000",
                            "method": "GET"
                        }
                    ]
                },
                "title": "My Media",
                "description": "Media description",
                "created_at": "2015-03-30T07:06:17.398Z",
                "modified_at": "2015-03-30T07:06:17.398Z",
                "deleted_at": null,
                "trt_msec": 16000,
                "screenshot_href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/SCREENSHOT/612003561265436316.jpg?Expires=1495793915&Signature=ZrT2b02Xa3wow5lOSTBvgsw0PNDjIVaQ4Z-Ur819uEW3eMozcLA07Zwy-M4eYoAqjgbQe4z6nMvn~L6PIOPqyN89xPecu~Pi6ewW4EPcuh3HNtTCJQdnFk3gZush1iPuV8~OhLYQaNWNX3KCfB6oHvgpn5ziJVRJsH9xKeH0A1JPhN3eXdbeOBhRFoswXNThbN7VJfDDQK8iMRyDTG3EwOCp~8TA5K1S81vJISCZ280JZ03M3BlC6P6361SZcL2NwFrhv37R8WvMqSj2Nk4uv25xPuSHwzPcOvTRT4TUfvPyuAx~9RvC5Wb1PFF2Mc52Ma14LgMiuyEj0bDAtoYHmw__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
                "subscription": true,
                "thumbnails": [
                    ...
                ]
            },
            {
                "id": "374948088395077039",
                "href": "https://staging-101.kzoinnovations.com/api/media/374948088395077039?page_size_related=10000",
                "links": {
                    "favorites": {
                    },
                    "parent": {
                    },
                    "slides": [
                    ],
                    "authored_by": {
                    },
                    "comments": [
                    ],
                    "chapters": [
                    ],
                    "montages": [
                    ],
                    "closed_captions_sets": [
                    ],
                    "original_video": {
                    },
                    "deleted_by": {
                    },
                    "owned_by": {
                        "type": "users",
                        "username": "admin"
                    },
                    "created_by": {
                    },
                    "used_slides": [
                    ],
                    "screenshots": [
                    ],
                    "replies": [
                    ],
                    "modified_by": {
                    },
                    "video_renditions": [
                    ],
                    "screenshot_positions": [
                    ],
                    "slide_deck": {
                    }
                },
                "meta": {
                    "notification_subscription": {
                        "direct": "SUBSCRIPTION",
                        "inherited": false
                    },
                    "pagination": {
                    },
                    "state": {
                        "pipeline_status": "READY",
                        "published": true,
                        "pipeline_resource": {
                            "href": "https://staging-101.kzoinnovations.com/api/media/374948088395077039?page_size_related=10000",
                            "type": "media"
                        }
                    },
                    "metrics": {
                        "favorites": 0,
                        "comments": 0,
                        "views": 6
                    },
                    "actions": [
                        {
                            "label": "MEDIA_GET",
                            "href": "https://staging-101.kzoinnovations.com/api/media/374948088395077039?page_size_related=10000",
                            "method": "GET"
                        }
                    ]
                },
                "title": "My Media",
                "description": "Media description",
                "created_at": "2015-06-02T07:55:16.807Z",
                "modified_at": "2015-12-10T19:56:31.642Z",
                "deleted_at": null,
                "trt_msec": 23000,
                "screenshot_href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/SCREENSHOT/598990642600744268.jpg?Expires=1495793927&Signature=WCxEuPyX4iGNtjP6w3Zf5U3zPk4nR4MmtJNBBvFLr-AtHW4DAGbXcWulKhr41QqUkX3Op1cJVSJDIl2HawUtMXozssbYaRxCOZncPgtNkkzoPAY~0CCoAxqRsgMJ1AMD5pNHFqKRo2Yjr6N17xa2ylmlgqMpjcecdpNlKUVw~XcbwT-A1cLHDFEW5~zD8Hpp7f4FIxGJ7AJx9HlArnb-C78AKkMum-kN4ZdiUpZCEgkkS1aJymnJhWe0PsAdy1xF7ilf6zE3yWjsH9tfGVBklVdeRpDaBQVGoNaR69vBEEmeM4pWRPgwRHlG4enF5nYEBo9sshPXVfwCiUA2zIl1~Q__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
                "subscription": true,
                "thumbnails": [
                    ...
                ]
            }
        ],
        "users": [
            {
                "id": "316971525670441986",
                "href": "https://staging-101.kzoinnovations.com/api/users/admin?page_size_related=10000",
                "links": {
                    "modified_by": {
                    },
                    "home_container": {
                    },
                    "deleted_by": {
                    },
                    "groups": [
                    ],
                    "created_by": {
                    },
                    "avatars": ""
                },
                "meta": {
                    "pagination": {
                    },
                    "state": {
                    },
                    "actions": [
                        {
                            "label": "USER_GET",
                            "href": "https://staging-101.kzoinnovations.com/api/users/admin?page_size_related=10000",
                            "method": "GET"
                        },
                        {
                            "label": "USER_GET_ALL",
                            "href": "https://staging-101.kzoinnovations.com/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
                            "method": "GET"
                        },
                        {
                            "label": "USER_UPDATE",
                            "href": "https://staging-101.kzoinnovations.com/api/users/admin",
                            "method": "PUT"
                        },
                        {
                            "label": "USER_EDIT_METADATA",
                            "href": "https://staging-101.kzoinnovations.com/api/users/admin",
                            "method": "PATCH"
                        },
                        {
                            "label": "USER_CREATE",
                            "href": "https://staging-101.kzoinnovations.com/api/users",
                            "method": "POST"
                        }
                    ]
                },
                "created_at": "2015-03-14T08:05:50.374Z",
                "modified_at": "2017-04-27T22:24:06.911Z",
                "deleted_at": null,
                "first_name": "admin",
                "last_name": "admin",
                "username": "admin",
                "email": "admin@kzotest.com",
                "authentication_type": "PASSWORD",
                "avatar_href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/AVATAR/359696837701014575.png?Expires=1497388851&Signature=b1DQclt9YfqMm~mTBq15Hr1JDGAQu86KDGb6vS7Ca-pM2Vaixwnl5jMp4G~1K-Jp1C9qXXoWT4wazc5pUOpMeJJNhciX4RLJHE8sNR9mLhmmBPA8J8CxySBPcOHsIPd5UCaq4DZ1oonJUdyVnp5hqwGWl~9FsDOGH2UbCFiA9Z1-SdWaDOxQRb8cuRIyzwd1o~hGKNUGVJUCRw0Kqsnl9~zUUIGzXr3o15T-HLDvs-eCb5yCbfF6LwoVXE6v3CX9J4e2xKHJ-aCDD1ecqP44aC~~D87GSlZ6ejRu-wxqMTQCOVf43-jbzbjBTkYwbp5NPWRNwDaWSYiqWA7KR1dSBw__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
                "custom_authn_option_id": null
            }
        ]
    },
    "meta": {
        "pagination": {
            "total_results": 17,
            "links": {
                "next": "https://staging-101.kzoinnovations.com/api/containers/325641022015018973/playlist_entries?page_size_primary=3&include=playlist_entries,playlist_entries.container,playlist_entries.medium&page_size_related=10000&page=2",
                "2next": "https://staging-101.kzoinnovations.com/api/containers/325641022015018973/playlist_entries?page_size_primary=3&include=playlist_entries,playlist_entries.container,playlist_entries.medium&page_size_related=10000&page=3",
                "last": "https://staging-101.kzoinnovations.com/api/containers/325641022015018973/playlist_entries?page_size_primary=3&include=playlist_entries,playlist_entries.container,playlist_entries.medium&page_size_related=10000&page=6",
                "3next": "https://staging-101.kzoinnovations.com/api/containers/325641022015018973/playlist_entries?page_size_primary=3&include=playlist_entries,playlist_entries.container,playlist_entries.medium&page_size_related=10000&page=4",
                "first": "https://staging-101.kzoinnovations.com/api/containers/325641022015018973/playlist_entries?page_size_primary=3&include=playlist_entries,playlist_entries.container,playlist_entries.medium&page_size_related=10000&page=1"
            }
        }
    },
    "playlist_entries": [
        {
            "id": "C_472060407171781682",
            "href": "",
            "links": {
                "container": "472060407171781682"
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            }
        },
        {
            "id": "M_328537880626468139",
            "href": "",
            "links": {
                "medium": "328537880626468139"
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            }
        },
        {
            "id": "M_374948088395077039",
            "href": "",
            "links": {
                "medium": "374948088395077039"
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            }
        }
    ]
}
Incremental reordering of descendant playlist entries for container
POST /containers/{id}/meta/set_order

Method performs reordering of child content units for container under consideration. The main difference from https://speca.io/KZO/kzo-api#reordering-children-of-a-container is that this method requires only new orders of PLEs to be moved.

For example we have container with 3 media Media1, Media2 and Media3 arranged respectively. If we want to move Media3 to be the first in the list - identifier of Media3 should be submitted along with it’s new position index 0, i.e {"order":{"playlist_entries": {"0":"M_<Media3_identifier_here>"}}}. If we want to move Media1 to the end of list then Media1 identifier should go with position index 2: {"order":{"playlist_entries": {"2":"M_<Media1_identifier_here>"}}}.

Mind that element numbering starts with 0. Also mind that container identifiers are submitted with prefix C_ and media identifiers are submitted with prefix M_ just like those identifiers are returned in https://speca.io/KZO/kzo-api#fetching-immediate-children

Position index should be in range from 0 to number of descendants - 1.

Path variables

id
number optional

The ID of Container

Example:
123

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad request

If input data is incorrect: incorrect content units ids or related orders are passed

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

Put media with identifier 6 to be the first in list and container with identifier 2 to be the fouth in list.

POST https://tenant.kzoplatform.com/api/containers/123/meta/set_order HTTP/1.1 

Content-Type: application/json

{
    "order": {
        "playlist_entries": {
            "0": "M_6",
            "3": "C_2"
        }
    }
}
Media
GET /media/{id}
GET /media/{ids}
GET /media
POST /containers/{id}/medium
PATCH /media/{id}
PUT /media/{id}
DELETE /media/{id}
POST /media/{id}/copy
Viewing Medium
GET /media/{id}

View information about a given Medium object.

Requires Permission assigning Role VIEWER on the parent Container of the given Medium.

Path variables

id
number required

The id of media

Example:
1

Request parameters

unpublished
boolean optional

Whether to include resources with attribute published = false into the response. API user needs to have specific permissions to be able to access unpublished content. Default value is false.

Example:
true
include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: media.created_by,media.modified_by, parent,parent.created_by,parent.modified_by, chapters,chapters.created_by,chapters.modified_by, original_videos,original_videos.created_by,original_videos.modified_by, video_renditions,video_renditions.created_by,video_renditions.modified_by,slide_decks,slide_decks.created_by,slide_decks.modified_by, slides,slides.created_by,slides.modified_by, used_slides,used_slides.created_by,used_slides.modified_by, comments,comments.created_by,comments.modified_by,comments.deleted_by, comments.replies,comments.replies.created_by,comments.replies.modified_by,comments.replies.deleted_by, video_rendition_options,screenshots,screenshot_options, montages,montage_options,media.authored_by,closed_captions_sets, closed_captions_sets.languages,unique_viewed_ranges,registration_unique_viewed_ranges.

If Replies are included, it is assumed that unlimited depth is requested.

Example:
parent,parent.created_by
parent_depth
number optional

Depth of the heirarchy of Container resources up from the given Container (using only links of type ORIGINAL) to be included in the response (namely, into the top-level collection linked, resource-level collection links). Value 0 means no parent are included, value -1 means the full hierarchy is included. Default value is 0.

Example:
2
preauth_actions
boolean optional

Whether to include actions to get and play medium by unauthenticated users. The URLs of actions will contain temporal access key.

Default:
false
video_registration_id
number optional

Video registration identifier. May be used for filtering of registration_unique_viewed_ranges that are returned in case when include registration_unique_viewed_ranges is requested. This parameter is mutually exclusive with rustici_engine_registartion_id. May be appicable only to media with content type VIDEO.

rustici_engine_registartion_id
number optional

Rustici course registration identifier. May be used for filtering of registration_unique_viewed_ranges that are returned in case when include registration_unique_viewed_ranges is requested. This parameter is mutually exclusive with video_registration_id. May be appicable only to media with content type RUSTICI_ENGINE_COURSE

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/media/234?video_registration_id=789&include=registration_unique_viewed_ranges HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "media": {
        "id" : "234",
        "title" : "Baby's first video!",
        "description" : "A lovely description for your new video.",
        "trt_msec" : 48000,
        "published" : true,
        "created_at" : "2012-10-10T14:12:24Z",
        "updated_at" : "2012-10-10T14:12:24Z",
        "comment_notification": true,
        "href": "https://tenant.kzoplatform.com/api/media/234",
        "screenshot_href": "http://d6mgdbc2kfx06.cloudfront.net/...",
        "links" : {
            "parent": {
                "id": 1,
                "type": "containers"
            },
            "original_video": 99,
            "video_renditions": [ 345, 456 ],
            "slide_deck": 567,
            "used_slides": [ 678, 789 ],
            "chapters": [ 890, 901 ],
            "comments": [ 45, 56 ],
            "replies": [ 67, 78 ],
            "registration_unique_viewed_ranges": "234",
            "created_by": {
                "username": "admin",
                "type": "users"
            },
            "modified_by": {
                "username": "admin",
                "type": "users"
            },
        },
        "meta": {
            "actions": [{
                "label": "MEDIUM___EDIT_METADATA",
                "href" : "https://tenant.kzoplatform.com/api/media/234",
                "method" : "PATCH"
            },{
                "label": "MEDIUM___DELETE",
                "href" : "https://tenant.kzoplatform.com/api/media/234",
                "method" : "DELETE"
            }],
            "pipeline_status": "EDITING",
            "pipeline_resource": {
                "href": "https://tenant.kzoplatform.com/api/media/234",
                "type": "media"
            }
        },
        thumbnails":[{
            "x": null,
            "y": null,
            "href":{
                "DEFAULT": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/SCREENSHOT/428121458238035702.jpg?Expires=1443172157&Signature=Sr5LJJ9qrar4yLgyKTbz4V2weeo5TFyiGhb119t7SvHVDmOhZPHx6enrh1LuLh68MjEWqQaVefdOPaIRB~mJGZ95GDd0~jptft~Ew5lRJj1ilHJczwUyYS9rWtCxT0ItnDeEJr9cItC1AtAAKsjd~uvkILhkiLYc0BZCVDJ56qDlbKxrBldWq4RjIifcGh1SQVrxFaKMekfNM6T8TQCoAvVOQ4DEr7jHwwiV1eqoGYxghribGEAsHs4x2YUlMIetx6QqOcrzllhKDy2~DyN7rvdJHJAE5c69ySnydOkpyMDCUThdKXGW2w8gjjwKBGGZySaGPOXqh0Tr1RcNGdt58A__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
                "LARGE": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/SCREENSHOT/428121458246424311.jpg?Expires=1443172157&Signature=If46AI0HYJoWyqkhX2MqH5SLh6TdtOHALiJBJMkgtdNL-3hNYWkeZYhQ1mgxl~moFW7-KD4oam2tJUMDQfQ8gvxS1KHAlI8ywXr6Jlfy15z~iUdzfr8bfIocrA~ELdg9RNPlV1qKQyc52li-sP2NLto9lvIQpS8dJNOOyEWhuBOzICZivJGLm~i-QDxQzUcToP1KAQpXT0qJntnFdtvBL8Oc9MoUKXPicsC9DX2zYUs2j78bFvUL2BJC35EDHerK-MMSERRI3LoFBqq0MCCQZn4FUFoCB9qfa6kHA5klck-4LrDMRRBPI1ZNZATZn9dcPp6JKebxDMJQL-x1w8lrRg__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA"
            }
        }]
    },
    "linked": {
        "containers": [{
            "id": 1
            ...
        }],
        "original_videos": [{
            "id": 99
            ...
        },{
        "video_renditions": [{
            "id": 345
            ...
        },{
            "id": 456
            ...
        }
        }],
        "slide_decks": [{
            "id": 567
            ...
        }],
        "used_slides": [{
            "id": 678
            ...
        },{
            "id": 789
            ...
        }],
        "chapters": [{
            "id": 809
            ...
        },{
            "id": 901
            ...
        }],
        "comments": [{
            "id": 45
            ...
        },{
            "id": 56
            ...
        }],
        "replies": [{
            "id": 67
            ...
        },{
            "id": 78
            ...
        }],
        "users": [{
            "id": 2,
            "username": "admin"
            ...
        }],
        "registration_unique_viewed_ranges": [
            {
                "id": "234",
                "unique_viewed_ranges": [
                    {
                        "start_msec": 0,                      
                        "end_msec": 10000
                    }
                ]
            }
        ],
    },
    "meta": {}
}
Viewing Multiple Media
GET /media/{ids}

View information about a given Media objects.

Requires Permission assigning Role VIEWER on the parent Containers of the given Media objects.

Path variables

ids
string required

Comma-separated list of the IDs of multiple media

Example:
1,2

Request parameters

unpublished
boolean optional

Whether to include resources with attribute published = false into the response. API user needs to have specific permissions to be able to access unpublished content. Default value is false.

Example:
true
include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: media.created_by,media.modified_by, parent,parent.created_by,parent.modified_by, chapters,chapters.created_by,chapters.modified_by, original_videos,original_videos.created_by,original_videos.modified_by, video_renditions,video_renditions.created_by,video_renditions.modified_by, slide_decks,slide_decks.created_by,slide_decks.modified_by, slides,slides.created_by,slides.modified_by, used_slides,used_slides.created_by,used_slides.modified_by, comments,comments.created_by,comments.modified_by, replies,replies.created_by,replies.modified_by, video_rendition_options,screenshots,screenshot_options, montages,montage_options,media.authored_by,closed_captions_sets, closed_captions_sets.languages.

Example:
parent
parent_depth
number optional

Depth of the heirarchy of Container resources up from the given Container (using only links of type ORIGINAL) to be included in the response (namely, into the top-level collection linked, resource-level collection links). Value 0 means no parent are included, value -1 means the full hierarchy is included. Default value is 0.

Example:
1

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

This example only demonstrates the key differences of the response from the response of the method Viewing Medium.

GET https://tenant.kzoplatform.com/api/media/1,2 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "media": [{
        "id": 1
        ...
    },{
        "id": 2
        ...
    }]
    ...
}
Searching Media
GET /media

Does not require Permissions.

Request parameters

title
string optional

Filtering by media title with partial matching.

Example:
New
description
string optional

Filtering by media description with partial matching.

Example:
York
created_at_to
string optional

Filtering by creation time. Specifies end of inclusive time interval using ISO8601 standard. If not set, it means until the end of time.

Example:
2013-10-10T14:12:24.324Z
created_at_from
string optional

Filtering by creation time. Specifies beginning of inclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2013-10-10T14:12:24.324Z

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

Dsiplay all media with a title matching a.

The response is the same as that of the method Viewing Multiple Media.

GET https://tenant.kzoplatform.com/api/media?title=A HTTP/1.1 
Creating Medium
POST /containers/{id}/medium

Creates a medium.

Requires Permission assigning Role CONTENT_CREATOR on the given Container.

Path variables

id
number required

The id of the container you wish to put the new Medium in.

Example:
1234

Responses

201 Created
401 Unauthorized

The request requires Authentication and Authorization.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Medium.

POST https://tenant.kzoplatform.com/api/containers/1234/medium HTTP/1.1 

Content-Type: application/json

{
    "media" : {
        "title" : "Baby's first video!",
        "description" : "A lovely description for your new video."
    }
}
POST https://tenant.kzoplatform.com/api/containers/{id}/medium HTTP/1.1 

Content-Type: application/json

{
    "media" : {
        "title" : "Baby's first video!",
        "description" : "A lovely description for your new video.",
        "authored_by": "author"
    }
}
Updating Medium
PATCH /media/{id}

Partial update of the medium.

Requires Permission assigning Role CONTENT_UPDATER on the parent Container of the given Medium.

Requires Permission assigning Role AUTHORSHIP_MANAGER on the parent Container of the given Medium for updating an author of Medium.

Path variables

id
number required

The id of media

Example:
1

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Medium.

PATCH https://tenant.kzoplatform.com/api/media/5 HTTP/1.1 

Content-Type: application/json

[{ 
    "op": "replace", 
    "path": "/title", 
    "value": "It is new title" 
}, { 
    "op": "replace", 
    "path": "/description", 
    "value": "It is new description" 
}, { 
    "op": "replace", 
    "path": "/parent_id", 
    "value": "123"
}, {
    "op": "replace",
    "path": "/created_at",
    "value": "2016-05-14T08:05:50.374Z"
}]
Replacing Medium
PUT /media/{id}

Complete replacement of media.

Requires Permission assigning Role CONTENT_UPDATER on the parent Container of the given Medium.

Requires Permission assigning Role AUTHORSHIP_MANAGER on the parent Container of the given Medium for updating an author of Medium.

Path variables

id
number required

The id of media

Example:
1

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Medium.

PUT https://tenant.kzoplatform.com/api/media/1 HTTP/1.1 

Content-Type: application/json

{
    "media" : {
        "title" : "Baby's first update video!",
        "description" : "A lovely new description for your new video.",
        "parent_id" : "id of new parent(optional field)"
    }
}
PUT https://tenant.kzoplatform.com/api/media/{id} HTTP/1.1 

Content-Type: application/json

{
    "media" : {
        "title" : "Baby's first update video!",
        "description" : "A lovely new description for your new video.",
        "parent_id" : "id of new parent(optional field)",
        "authored_by": "author"
    }
}
Deleting Medium
DELETE /media/{id}

Requires Permission assigning Role CONTENT_DELETER on the parent Container of the given Medium.

Path variables

id
number required

The id of media

Example:
1

Responses

204 No Content
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/media/1 HTTP/1.1 
Copying Medium
POST /media/{id}/copy

Creates a full copy of a given medium.

Requires Permission assigning Role VIEW_CONTENT on the given Medium.

Path variables

id
string required

The id of medium

Example:
123

Request parameters

target_container_id
string required

The id of Container where Medium will be copying. Requires Permission assigning Role CREATE_CONTENT_COPY_MEDIA on the given Container.

Example:
1234

Responses

401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Medium.

POST https://tenant.kzoplatform.com/api/media/123/copy?target_container_id=1234 HTTP/1.1 

HTTP/1.1 201 Created 
Original Videos

The purpose of Original Videos is to accept upload of a video file.

GET /original_video/{id}
POST /media/{id}/original_video
PUT /original_videos/{id}
Viewing Original Video
GET /original_video/{id}

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the parent Medium.

Path variables

id
number required

The ID of the Original Video

Example:
123

Responses

200 OK

Action ORIGINAL_RENDITION_UPLOAD_WITH_PRESIGNED_URL provides a pre-signed URL which can be used to PUT a video file to S3.

Action ORIGINAL_VIDEO_UPLOAD (deprecated) provides an URL to which the upload should be performed, as well as all information necessary for upload. See AWS S3 howto for details on how to perform the upload. All additional attributes required to compose the form are provided in meta.actions.post_presigned_s3.

Actions ORIGINAL_VIDEO_UPLOAD/ORIGINAL_RENDITION_UPLOAD_WITH_PRESIGNED_URL and ORIGINAL_VIDEO_DOWNLOAD are never available at the same time. The former ones are available only when the resource pipeline is in the status EDITING, the latter one is only available when it is in the status READY and sometimes ERROR.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/original_video/234 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "original_videos": {
        "id": "234",
        "trim_beginning_msec": 0,
        "trim_end_msec": null,
        "href": "https://tenant.kzoplatform.com/api/original_videos/234",
        "links" : {
            "parent": {
                "id": 12,
                "type": "media"
            }
        },
        "meta": {
            "stream_name": "567/video_rendition/mp4:234.mp4",
            "pipeline_status": "EDITING",
            "pipeline_resource": {
                "href": "https://tenant.kzoplatform.com/api/original_videos/234",
                "type": "original_videos"
            },
            "actions": [{
                "label": "ORIGINAL_VIDEO_UPLOAD",
                "href": "http://uploads-presigned-post-s3.s3.amazonaws.com/",
                "method": "POST",
                "post_presigned_aws_s3": {
                    "key": "123/ORIGINAL_VIDEO/456",
                    "AWSAccessKeyId": "AKIAJQEXAMPLEEXAMPLE",
                    "acl": "bucket-owner-full-control",
                    "policy": "asdklfjadskf...283749234",
                    "signature": "123...kjdfgkj"
                }
            },
            {
                "label": "ORIGINAL_VIDEO_UPLOAD_WITH_PRESIGNED_URL",
                "href": "http://uploads-presigned-post-s3.s3.amazonaws.com/123/ORIGINAL_VIDEO/456?...",
                "method": "PUT"
            },
            {
                "label": "ORIGINAL_VIDEO_DOWNLOAD",
                "href": "http://d6mgdbc2kfx06.cloudfront.net/...",
                "method": "GET"
            }
            ...
            ]
        }
        ...
    },
    "linked": {},
    "meta": {}
}
Creating Original Video
POST /media/{id}/original_video

Creates resource to hold Original Video. Attribute meta.actions for meta.action.label=ORIGINAL_VIDEO___UPLOAD provide information on how to upload the video file.

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the given Medium.

Path variables

id
number required

The ID of the Medium for which this Original Video is being created.

Example:
1

Request body

Object
original_videos
Object
trim_beginning_msec
integer nullable
trim_end_msec
integer nullable

Responses

201 Created
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Original Video.

POST https://tenant.kzoplatform.com/api/media/1/original_video HTTP/1.1 

Content-Type: application/json

{
    "original_videos": {
    }
}
POST https://tenant.kzoplatform.com/api/media/1/original_video HTTP/1.1 

Content-Type: application/json

{
    "original_videos": {
        "trim_beginning_msec": 1000
    }
}
POST https://tenant.kzoplatform.com/api/media/1/original_video HTTP/1.1 

Content-Type: application/json

{
    "original_videos": {
        "trim_beginning_msec": 1000,
        "trim_end_msec": 1000
    }
}
Updating Original Video
PUT /original_videos/{id}

Changes trimming parameters of the video. If a parameter was actually changed, the video has to be processed.

Requires Permission assigning Role CONTENT_UPDATER, CONTENT_CREATOR, CONTENT_CREATOR_UPLOAD_MEDIA, CONTENT_CREATOR_RECORD_MEDIA or CONTENT_CREATOR_COPY_MEDIA on the parent Container of the parent Medium.

The response is the same as that of the method Viewing Original Video.

Path variables

id
string required

The ID of the Original Video

Request body

Object
original_videos
Object
trim_beginning_msec
integer nullable

pass null to keep the current value unchanged

trim_end_msec
integer nullable

pass null to keep the current value unchanged

Video Renditions
GET /video_renditions/{id}
GET /video_renditions/{ids}
Viewing Video Rendition
GET /video_renditions/{id}

Path variables

id
number required

The ID of the Video Rendition

Example:
1

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/video_renditions/234 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "video_renditions": {
        "id": "234",
        "href": "https://tenant.kzoplatform.com/api/video_renditions/234",
        "links" : {
            "parent": {
                "id": 12,
                "type": "media"
            }
        },
        "meta": {
            "actions": [{
                "label": "VIDEO_RENDITION___DOWNLOAD",
                "href": "http://d6mgdbc2kfx06.cloudfront.net/...",
                "method": "GET"
            }
            ...
            ]
        }
        ...
    },
    "linked": {},
    "meta": {}
}
Viewing Multiple Video Renditions
GET /video_renditions/{ids}

Path variables

ids
string optional

Comma-separated list of the IDs of multiple Video Renditions

Example:
1,2

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/video_renditions/1,2 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "video_renditions": [{
        "id" : "1"
        ...
    }, {
        "id" : "2"
        ...
    }]
    ...
}
Video Rendition Options
GET /video_rendition_options/{id}
GET /video_rendition_options
Viewing Video Rendition Option
GET /video_rendition_options/{id}

Requires authenticated user.

Path variables

id
number optional

The ID of the Video Rendition Option

Example:
123

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/video_rendition_options/12 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "video_rendition_options": {
        "links": [],
        "meta": {},
        "id": 123,
        "href": "https://tenant.kzoplatform.com/api/video_rendition_options/123",
        "amazon_preset_id": "1409118559066-rg63pm",
        "video_bitrate": 300,
        "video_codec": "mp4"
        ...
    },
    "linked": [],
    "meta": {}
}
Searching Video Rendition Options
GET /video_rendition_options

Limited functionality: returns all Video Rendition Options.

Requires authenticated user.

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/video_rendition_options HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "video_rendition_options": [{
        "id": 12
        ...
    }, {
        "id": 34
        ...
    }
    ...
    ]
    ...
}
Screenshots
GET /screenshot/{id}
GET /screenshots/{ids}
Viewing Screenshot
GET /screenshot/{id}

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the parent Medium.

Path variables

id
number required

The ID of the Screenshot

Example:
1

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: created_by,modified_by, media,screenshot_options.

Example:
screenshot_options

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/screenshot/14 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "screenshots": {
        "id" : "14",
        "width": 1920,
        "height": 1080,
        "default": false,
        "published" : true,
        "created_at" : "2012-10-10T14:12:24Z",
        "modified_at" : "2012-10-10T14:12:24Z",
        "href": "https://tenant.kzoplatform.com/api/screenshots/14",
        "links" : {
            "medium": 123,
            "screenshot_option": 2,
            "created_by" : {
                "username" : "admin",
                "type" : "users"
            },
            "modified_by" : {
                "username" : "admin",
                "type" : "users"
            }
        },
        "meta": {
            "actions": [{
                "label": "SCREENSHOT___GET",
                "href": "https://tenant.kzoplatform.com/api/screenshots/14",
                "method": "GET"
            }, {
                "label": "SCREENSHOT___DOWNLOAD",
                "href": "http://d6mgdbc2kfx06.cloudfront.net/...",
                "method": "GET"
            }
            ...
            ]
        }
    },
    "linked": {
        "media": [{
            "id": 123
            ...
        }],
        "users": [{
            "id": 2,
            "username": "admin"
            ...
        }],
        "screenshot_options": [{
            "id": 2
            ...
        }]
    },
    "meta": {}
}
Viewing Multiple Screenshots
GET /screenshots/{ids}

Requires Permission assigning Role CONTENT_VIEWER on the parent Containers of the parent Media.

Path variables

ids
string optional

The IDs of the Screenshots

Example:
12,34

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: created_by,modified_by, media,screenshot_options.

Example:
media

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

This example only demonstrates the key differences of the response from the response of the method Viewing Screenshot.

GET https://tenant.kzoplatform.com/api/screenshots/12,34 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "screeshots": [{
        "id" : "12"
        ...
    }, {
        "id" : "34"
        ...
    }]
    ...
}
Screenshot Options
GET /screenshot_options/{id}
GET /screenshot_options
PUT /screenshot_options/{id}
Viewing Screenshot Option
GET /screenshot_options/{id}

Screenshot option types are vertcal resolutions of images.

Requires authenticated user.

Path variables

id
number optional

The ID of the Screenshot Option

Example:
12

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/screenshot_options/12 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "screenshot_options": {
        "id": 123,
        "href": "https://tenant.kzoplatform.com/api/screenshot_options/12",
        "width": 295,
        "height": 166,
        "screenshot_type": "166",
        "default": false,
        "playicon": false
        "links": [],
        "meta": {}
    },
    "linked": [],
    "meta": {}
}
Searching Screenshot Options
GET /screenshot_options

Limited functionality: returns all Screenshot Options.

Requires authenticated user.

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/screenshot_options HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "screenshot_options": [{
        "id": 12
        ...
    }, {
        "id": 34
        ...
    }
    ...
    ]
    ...
}
Replacing Screenshot Options
PUT /screenshot_options/{id}

Replacing thumbnail_type of screenshot option. Allowed values: NONE, DEFAULT, SMALL, MEDIUM, LARGE, SMALL_PLAYICON, MEDIUM_PLAYICON, LARGE_PLAYICON.

Requires Permission assigning Role MANAGE_TENANT on the given Container.

Path variables

id
number required

The id of screenshot options

Example:
123

Examples

PUT https://tenant.kzoplatform.com/api/screenshot_options/234 HTTP/1.1 

Content-Type: application/json

{
  "screenshot_options": {
    "thumbnail_type": "LARGE_PLAYICON"
  }
}
Montages
GET /montages/{id}
GET /montages/{ids}
Viewing Montage
GET /montages/{id}

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the parent Medium.

Path variables

id
number optional

The ID of the Montage

Example:
123

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: created_by,modified_by, media,montage_options.

Example:
media

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/montages/14 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "montages": {
        "id" : "14",
        "page_number": 2,
        "number_pages": 4,
        "published" : true,
        "created_at" : "2012-10-10T14:12:24Z",
        "modified_at" : "2012-10-10T14:12:24Z",
        "href": "https://tenant.kzoplatform.com/api/montages/14",
        "links" : {
            "medium": 123,
            "montage_option": 2,
            "created_by" : {
                "username" : "admin",
                "type" : "users"
            },
            "modified_by" : {
                "username" : "admin",
                "type" : "users"
            }
        },
        "meta": {
            "actions": [{
                "label": "MONTAGE___GET",
                "href": "https://tenant.kzoplatform.com/api/montages/14",
                "method": "GET"
            }, {
                "label": "MONTAGE___DOWNLOAD",
                "href": "http://d6mgdbc2kfx06.cloudfront.net/...",
                "method": "GET"
            }
            ...
            ]
        }
    },
    "linked": {
        "media": [{
            "id": 123
            ...
        }],
        "users": [{
            "id": 2,
            "username": "admin"
            ...
        }],
        "montage_options": [{
            "id": 2
            ...
        }]
    },
    "meta": {}
}
Viewing Multiple Montages
GET /montages/{ids}

Requires Permission assigning Role CONTENT_VIEWER on the parent Containers of the parent Media.

Path variables

ids
string optional

The IDs of the Montages

Example:
12,34

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: created_by,modified_by, media,montage_options.

Example:
media

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/montages/12,34 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "montages": [{
        "id" : "12"
        ...
    }, {
        "id" : "34"
        ...
    }]
    ...
}
Montage Options
GET /montage_options/{id}
Viewing Montage Option
GET /montage_options/{id}

Requires authenticated user.

Path variables

id
string optional

The ID of the Montage Option

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/montage_options/123 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "montage_options": {
        "id": 123,
        "href": "https://tenant.kzoplatform.com/api/montage_options/123",
        "width": 1000,
        "height": 750,
        "number_cells_x": 10,
        "number_cells_y": 10,
        "cell_interval_msec": 5000,
        "links": [],
        "meta": {}
    },
    "linked": [],
    "meta": {}
}
Searching Montage Options
GET /montages

Limited functionality: returns all Montage Options.

Requires authenticated user.

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/montages HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "montage_options": [{
        "id": 12
        ...
    }, {
        "id": 34
        ...
    }
    ...
    ]
    ...
}
Slide Decks
GET /slide_decks/{id}
POST /media/{id}/slide_deck
DELETE /slide_decks/{id}
Viewing Slide Deck
GET /slide_decks/{id}

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the parent Medium.

Path variables

id
number required

The ID of the Slide Deck

Example:
1

Responses

200 OK

Slide Deck will accept upload of video file.

Action SLIDE_DECK_UPLOAD_WITH_PRESIGNED_URL provides a pre-signed URL which can be used to PUT a slide deck to S3.

Action SLIDE_DECK_UPLOAD (deprecated) provides an URL to which the upload should be performed, as well as all information necessary for upload. See AWS S3 howto for details on how to perform the upload. All additional attributes required to compose the form are provided in meta.actions.post_presigned_s3.

Actions SLIDE_DECK_UPLOAD/SLIDE_DECK_UPLOAD_WITH_PRESIGNED_URL and SLIDE_DECK_DOWNLOAD are never available at the same time. The former ones are available only when the resource pipeline is in the status EDITING, the latter one is only available when it is in the status READY and sometimes ERROR.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/slide_decks/789 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "slide_decks": {
        "id": "789",
        "number_slides": 10,
        "href": "https://tenant.kzoplatform.com/api/slide_decks/234",
        "links" : {
            "parent": {
                "id": 12,
                "type": "media"
            }
        },
        "meta": {
            "pipeline_status": "EDITING",
            "pipeline_resource": {
                "href": "https://tenant.kzoplatform.com/api/slide_decks/789",
                "type": "slide_decks"
            },
            "actions": [{
                "label": "SLIDE_DECK_UPLOAD",
                "href": "http://uploads-presigned-post-s3.s3.amazonaws.com/",
                "method": "POST",
                "post_presigned_aws_s3": {
                    "key": "123/SLIDE_DECK/456",
                    "AWSAccessKeyId": "AKIAJQEXAMPLEEXAMPLE",
                    "acl": "bucket-owner-full-control",
                    "policy": "asdklfjadskf...283749234",
                    "signature": "123...kjdfgkj"
                }
            }, 
            {
                "label": "SLIDE_DECK_UPLOAD_WITH_PRESIGNED_URL",
                "href": "http://uploads-presigned-post-s3.s3.amazonaws.com/123/SLIDE_DECK/456?...",
                "method": "PUT"
            },
            {
                "label": "SLIDE_DECK_DOWNLOAD",
                "href": "http://d6mgdbc2kfx06.cloudfront.net/...",
                "method": "GET"
            }
            ...
            ]
        }
        ...
    },
    "linked": {},
    "meta": {}
}
Creating Slide Deck
POST /media/{id}/slide_deck

Creates resource to hold the Slide Deck. Attribute meta.actions for meta.action.label=SLIDE_DECK___UPLOAD provide information on how to upload the slide deck file.

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the given Medium.

Path variables

id
string required

The ID of the Medium in which Slide Deck is being created.

Example:
111

Request body

Request body is ignored.

Responses

201 Created
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Slide Deck.

POST https://tenant.kzoplatform.com/api/media/111/slide_deck HTTP/1.1 
Deleting Slide Deck
DELETE /slide_decks/{id}

Deletes the given Slide Deck, its Slides and associated Used Slides.

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the parent Medium.

Path variables

id
number required

The ID of the Slide Deck to be deleted

Example:
123

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/slide_decks/123 HTTP/1.1 
Slides
GET /slides/{id}
Viewing Slide
GET /slides/{id}

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the parent Medium.

Path variables

id
number required

The ID of the Slide

Example:
1

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: slides.created_by,slides.modified_by, slide_decks,slide_decks.created_by,slide_decks.modified_by

Example:
slide_decks

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/slides/1 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "slides": {
        "id" : "14",
        "page_number": 4,
        "published" : true,
        "created_at" : "2012-10-10T14:12:24Z",
        "modified_at" : "2012-10-10T14:12:24Z",
        "href": "https://tenant.kzoplatform.com/api/slides/14",
        "links" : {
            "slide_deck": 123,
            "created_by" : {
                "username" : "admin",
                "type" : "users"
            },
            "modified_by" : {
                "username" : "admin",
                "type" : "users"
            }
        },
        "meta": {
            "actions": [{
                "label": "SLIDE___GET",
                "href": "https://tenant.kzoplatform.com/api/slides/14",
                "method": "GET"
            }, {
                "label": "SLIDE___DOWNLOAD",
                "href": "http://d6mgdbc2kfx06.cloudfront.net/...",
                "method": "GET"
            }
            ...
            ]
        }
    },
    "linked": {
        "slide_decks": {
            "id": 123
            ...
        },
        "users": {
            "id": 2,
            "username": "admin"
            ...
        }
    },
    "meta": {}
}
Used Slides
GET /used_slides/{id}
GET /used_slides/{ids}
POST /media/{id}/used_slide
PUT /used_slides/{id}
PATCH /used_slides/{id}
DELETE /used_slides/{id}
Viewing Used Slide
GET /used_slides/{id}

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the parent Medium.

Path variables

id
number required

The ID of Used Slide

Example:
1

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/used_slides/14 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "slides": {
        "id" : "14",
        "start_msec" : 15,
        "published" : true,
        "created_at" : "2012-10-10T14:12:24Z",
        "modified_at" : "2012-10-10T14:12:24Z",
        "href": "https://tenant.kzoplatform.com/api/used_slides/14",
        "links" : {
            "slide": 123,
            "medium": 456,
            "created_by" : {
                "username" : "admin",
                "type" : "users"
            },
            "modified_by" : {
                "username" : "admin",
                "type" : "users"
            }
        },
        "meta": {
            "actions": [{
                "label": "USED_SLIDE___GET",
                "href": "https://tenant.kzoplatform.com/api/used_slides/14",
                "method": "GET"
            }
            ...
            ]
        }
    },
    "linked": {
        "slides": {
            "id": 123
            ...
        },
        "users": {
            "id": 2,
            "username": "admin"
            ...
        },
        "media": {
            "id": 456
            ...
        }
    },
    "meta": {}
}
Viewing Multiple Used Slides
GET /used_slides/{ids}

Path variables

ids
string required

Comma-separated list of the IDs of multiple Used Slides

Example:
1,2

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: slides.created_by,slides.modified_by, slide_decks,slide_decks.created_by,slide_decks.modified_by

Example:
slide_decks

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

This example only demonstrates the key differences of the response from the response of the method Viewing Slide.

GET https://tenant.kzoplatform.com/api/used_slides/1,2 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "used_slides": [{
        "id" : "1"
        ...
    }, {
        "id" : "2"
        ...
    }]
    ...
}
Creating Used Slide
POST /media/{id}/used_slide

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the given Medium.

Path variables

id
number required

The ID of media

Example:
1

Responses

201 Created
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Used Slide.

POST https://tenant.kzoplatform.com/api/media/1/used_slide HTTP/1.1 

Content-Type: application/json

{
    "used_slides": {
        "slide": 234,
        "start_msec": 456
    }
}
Replacing Used Slide
PUT /used_slides/{id}

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the parent Medium.

Path variables

id
number required

The id of slide

Example:
1

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Used Slide.

PUT https://tenant.kzoplatform.com/api/used_slides/1 HTTP/1.1 

Content-Type: application/json

{
    "used_slides": {
        "slide": 234,
        "start_msec": 456
    }
}
Updating Used Slide
PATCH /used_slides/{id}

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the parent Medium.

Path variables

id
number required

The ID of the Used Slide

Example:
1

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Used Slide.

PATCH https://tenant.kzoplatform.com/api/used_slides/1 HTTP/1.1 

Content-Type: application/json

[{ 
    "op": "replace", 
    "path": "/start_msec", 
    "value": 2000
}]
Deleting Used Slide
DELETE /used_slides/{id}

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the parent Medium.

Path variables

id
number required

The id of slide

Example:
1

Responses

204 No Content
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/used_slides/1 HTTP/1.1 
Chapters
GET /chapters/{id}
GET /chapters/{ids}
POST /media/{id}/chapter
PATCH /chapters/{id}
PUT /chapters/{id}
DELETE /chapters/{id}
Viewing Chapter
GET /chapters/{id}

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the parent Medium.

Path variables

id
number required

The id of chapter

Example:
1

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: modified_by,created_by,media,media.modified_by,media.created_by.

Example:
media

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/chapters/14?include=modified_by,created_by,media HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "chapters": {
        "id" : "14",
        "title" : "Yep, this is title",
        "start_msec" : 5,
        "published" : true,
        "created_at" : "2012-10-10T14:12:24Z",
        "modified_at" : "2012-10-10T14:12:24Z",
        "links" : {
            "media" : 111,
            "created_by" : {
                "username" : "admin",
                "type": "users",
            },
            "modified_by" : {
                "username" : "admin",
                "type": "users",
            }
        },
        "meta": {
            "actions": [{
                "label": "CHAPTER___GET",
                "href" : "https://tenant.kzoplatform.com/api/chapters/14",
                "method" : "GET"
            }],
            "pipeline_status": "READY",
            "pipeline_resource": {
                "href": "https://tenant.kzoplatform.com/api/media/111",
                "type": "media"
            }
        }
    },
    "linked": {
        "media":  {
            "id": 111
            ...
        },
        "users": {
            "id": 2,
            "username": "admin"
            ...
        }
    },
    "meta": {}
}
Viewing Multiple Chapters
GET /chapters/{ids}

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the parent Media.

Path variables

ids
string optional

Comma-separated list of the IDs of multiple Chapters

Example:
22,33

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: modified_by,created_by,media,media.modified_by,media.created_by.

Example:
media

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

This example only demonstrates the key differences of the response from the response of the method Viewing Chapter.

GET https://tenant.kzoplatform.com/api/chapters/22,33 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "chapters": [{
        "id" : "22"
        ...
    }, {
        "id" : "33"
        ...
    }]
    ...
}
Create chapter
POST /media/{id}/chapter

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the given Medium.

Path variables

id
number required

The id of media

Example:
1

Responses

201 CREATED
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Chapter.

POST https://tenant.kzoplatform.com/api/media/1/chapter HTTP/1.1 

Content-Type: application/json

{
    "chapters": {
        "title" : "Yep, this is title",
        "start_msec" : 5
    }
}
Update chapter
PATCH /chapters/{id}

Requires Permission assigning Role CONTENT_UPDATER on the parent Container of the given Medium.

Path variables

id
number required

The id of chapter

Example:
1

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PATCH https://tenant.kzoplatform.com/api/chapters/1 HTTP/1.1 

Content-Type: application/json

[{ 
    "op": "replace", 
    "path": "/title", 
    "value": "We are changed title"
}, { 
    "op": "replace", 
    "path": "/start_msec", 
    "value": 25
}]
Replace chapter
PUT /chapters/{id}

Requires Permission assigning Role CONTENT_UPDATER on the parent Container of the given Medium.

Path variables

id
number required

The id of chapter

Example:
1

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/chapters/1 HTTP/1.1 

Content-Type: application/json

{
    "chapters": {
        "title" : "Nope, this is no title",
        "start_msec" : 10
    }
}

HTTP/1.1 200 OK 
Delete chapter
DELETE /chapters/{id}

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the given Medium.

Path variables

id
number required

The id of chapter

Example:
1

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/chapters/1 HTTP/1.1 
Search
GET /search
Searching Content
GET /search

Search content. The results are returned grouped by Containers.

Pagination: primary (containers).

Request parameters

q
string required

Term to search for

Example:
awesome
domain
string optional

Attributes to be searched.
Possble value is a comma-separated list of any of the following:
media – Media title and/or description,
containers – Container title and/or description,
slides – Slide text,
chapters – Chapter title,
comments – text of Comments and/or Replies,
closed_captions_sets – Closed captions text, everything – all of the above (default value).

Example:
media,containers
within_container
number optional

Limits the resultset to the Container with the specified ID and all content below it in the Container hierarchy.

Example:
123
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/search?q=awesome&domain=containers,chapters HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "containers": [{
        "id" : "1",
        "title": "some title 1",
        "description": "some descr 1",
        "links": {
            "media": [ 5 ]
            ...
        }
        ...
    }, {
        "id" : "2",
        "title": "c2",
        "description": "nothing awesome"
        ...
    }],
    "linked": {
        "media": [{
            "id": 5,
            "title": "some title 3",
            "description": "some descr 3",
            "links": {
                "chapters": [ 6 ]
                ...
            }
            ...
        }],
        "chapters": [{
            "id": 6,
            "title": "pure awesomeness"
            ...
        }],
        "closed_captions_sets": [
            {
                "created_at": "2017-03-16T05:57:32.248Z",
                "hash_md5": "86e66f62e8ef434fbc89bff52e41404e",
                "hash_sha1": "415f5403fa0735ab28407cdd6c6df94222eb1df9",
                "href": "https://tenant.kzoplatform.com/api/closed_captions_sets/848167560019973580",
                "id": "848167560019973580",
                "size": 114830,
                "links": {
                    "closed_captions_cues": [
                        "848165158084679110.216",
                        "848165158084679110.570"
                    ],
                    "language": {
                        "id": "en",
                        "type": "languages"
                    },
                },
                ...
            }
        ],
         "closed_captions_cues": [
            {
                "start_msec": "925024",
                "end_msec": "929094",
                "id": "848167560019973580.216",
                "text": "Probably doing something awesome, right?"
            },
            {
                "start_msec": "2614211",
                "end_msec": "2615847",
                "id": "848167560019973580.570",
                "text": "What I would like to see is... something awesome."
            }
        ],
        "languages": [
            {
                "id": "en",
                "name": "English"
            }
        ]
    },
    "meta": {}
}
Comments
GET /comments/{id}
GET /comments/{ids}
POST /media/{id}/comment
DELETE /comments/{id}
Viewing Comment
GET /comments/{id}

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the parent Medium.

Path variables

id
number required

The id of Comment

Example:
123

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: comments.created_by,comments.updated_by, replies,replies.created_by,replies.updated_by, parent,parent.created_by,parent.updated_by.
If Replies are included, it is assumed that unlimited depth is requested.

Example:
parent

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/comments/123 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "comments" : {
        "id" : "123",
        "text" : "This is new comment", 
        "time_msec" : 36,
        "coordinate_x" : 22.46,
        "coordinate_y" : 32.46,
        "coordinate_radius" : 10.5,
        "coordinate_target" : "VIDEO",
        "published" : true,
        "created_at" : "2012-10-10T14:12:24Z",
        "modified_at" : "2012-10-10T14:12:24Z",
        "links" : {
            "parent": {
                "id": 4,
                "type": "media"
            },
            "replies": [ 567, 890 ],
            "created_by" : {
                "username" : "admin",
                "type": "users",
            },
            "modified_by" : {
                "username" : "admin",
                "type": "users",
            }
        },
        "meta" : {
            "actions": [{
                "label": "COMMENT___CREATE_REPLY"
                ...
            }, {
                "label": "COMMENT___DELETE"
                ...
            }]
        }
    },
    "linked" : {
        "media": [{
            "id": 4
            ...
        }],
        "users": [{
            "username": "admin"
            ...
        }],
        "replies": [{
            "id": 567
            ...
        }, {
            "id": 890
            ...
        }]
    },
    "meta" : {}
}
Viewing Multiple Comments
GET /comments/{ids}

Requires Permission assigning Role CONTENT_VIEWER on the parent Containers of the parent Media. The Comments may belong to different Containers, Media.

Path variables

ids
string optional

IDs of Comments

Example:
123,456

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: comments.created_by,comments.updated_by, replies,replies.created_by,replies.updated_by, parent,parent.created_by,parent.updated_by.
If Replies are included, it is assumed that unlimited depth is requested.

Example:
parent

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

This example only demonstrates the key differences of the response from the response of the method Viewing Comment

GET https://tenant.kzoplatform.com/api/comments/1,2 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "conmments": [{
        "id" : "1"
        ...
    }, {
        "id" : "2"
        ...
    }]
    ...
}
Creating Comment
POST /media/{id}/comment

Requires Permission assigning Roles CONTENT_MANAGER or COMMENTATOR on the parent Container of the parent Medium.

Path variables

id
number required

The id of Medium

Example:
123

Responses

201 Created
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Comment

POST https://tenant.kzoplatform.com/api/media/5/comment HTTP/1.1 

Content-Type: application/json

{
    "comments" : {
        "text" : "This is new comment", 
        "time_msec" : 36,
        "coordinate_x" : 22.46,
        "coordinate_y" : 32.46,
        "coordinate_radius" : 10.5,
        "coordinate_target" : "VIDEO"
    }
}
Deleting comment
DELETE /comments/{id}

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the parent Medium.

Path variables

id
number required

The ID of Comment

Example:
123

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/comments/456 HTTP/1.1 
Replies
GET /replies/{id}
GET /replies/{ids}
POST /comments/{id}/reply
POST /replies/{id}/reply
DELETE /replies/{id}
Viewing Reply
GET /replies/{id}

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the parent Medium of the parent Comment.

Path variables

id
number optional

The ID of the Reply

Example:
123

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: comments.created_by,comments.updated_by, replies,replies.created_by,replies.updated_by, parent,parent.created_by,parent.updated_by.
If Replies are included, it is assumed that unlimited child depth is requested.

Example:
parent

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/replies/123 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "replies" : {
        "id" : "123",
        "text" : "This is new comment", 
        "published" : true,
        "created_at" : "2012-10-10T14:12:24Z",
        "modified_at" : "2012-10-10T14:12:24Z",
        "links" : {
            "parent": {
                "id": 345,
                "type": "comment"
            }
            "replies": [ 567, 890 ],
            "created_by" : {
                "username" : "admin",
                "type": "users",
            },
            "modified_by" : {
                "username" : "admin",
                "type": "users",
            }
        },
        "meta" : {
            "actions": [{
                "label": "REPLY___CREATE_REPLY"
                ...
            }, {
                "label": "REPLY___DELETE"
                ...
            }]
        }
    },
    "linked" : {
        "comments": [{
            "id": 345
            ...
        }],
        "users": [{
            "username": "admin"
            ...
        }],
        "replies": [{
            "id": 567
            ...
        }, {
            "id": 890
            ...
        }]
    },
    "meta" : {}
}
Viewing Multiple Replies
GET /replies/{ids}

Requires Permission assigning Role CONTENT_VIEWER on the parent Containers of the parent Media of the parent Comments. The Replies may belong to different Containers, Media, Comments, Replies.

Path variables

ids
string optional

The IDs of the Replies

Example:
23,45

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: comments.created_by,comments.updated_by, replies,replies.created_by,replies.updated_by, parent,parent.created_by,parent.updated_by.
If Replies are included, it is assumed that unlimited child depth is requested.

Example:
parent

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

This example only demonstrates the key differences of the response from the response of the method Viewing Reply. It also illustrates that requested Replies may belong to different parent Comments or Replies.

GET https://tenant.kzoplatform.com/api/replies/12,56 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "replies": [{
        "id" : "12",
        "links": {
            "parent": {
                "id": 34,
                "type": "comment"
            }
            ...
        }
        ...
    }, {
        "id" : "56",
        "links": {
            "parent": {
                "id": 78,
                "type": "reply"
            }
            ...
        }
        ...
        ...
    }]
    ...
}
Creating Reply to Comment
POST /comments/{id}/reply

Requires Permission assigning Roles CONTENT_MANAGER or COMMENTATOR on the parent Container of the parent Medium of the parent Comment.

Path variables

id
number required

The id of the parent Comment

Example:
123

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method [Viewing Reply](mrthod://Viewing Reply)

POST https://tenant.kzoplatform.com/api/comments/5/reply HTTP/1.1 

Content-Type: application/json

{
    "replies": {
        "text" : "This is a reply to comment"
    }
}
Creating Reply to Reply
POST /replies/{id}/reply

Requires Permission assigning Roles CONTENT_MANAGER or COMMENTATOR on the parent Container of the parent Medium of the parent Comment.

Path variables

id
number optional

The ID of the parent Reply

Example:
34

Responses

201 Created
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/replies/34/reply HTTP/1.1 

Content-Type: application/json

{
    "replies": {
        "text" : "This is a reply to reply"
    }
}
Deleting Reply
DELETE /replies/{id}

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the parent Medium of the parent COmment.

Path variables

id
number required

The id of reply

Example:
1

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/replies/1 HTTP/1.1 
Users
GET /users/{username}
GET /users/{usernames}
GET /users
POST /users
PATCH /users/{username}
PUT /users/{username}
DELETE /users/{username}
Viewing User
GET /users/{username}

Requires authenticated user.

Pagination: groups.

Path variables

username
string required

Username

Example:
admin

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: modified_by,created_by,groups,groups.modified_by, groups.created_by,roles,avatars,home_container.

Example:
users
group_labels
string optional

Which kinds of groups are returned in associated objects if groups are requested in include.
Possible values: INDIVIDUAL,NONINDIVIDUAL,ALL.
NONINDIVIDUAL indicates that groups with all labels other than INDIVIDUAL should be returned. INDIVIDUAL and ALL are self-explanatory.
Default value: NONINDIVIDUAL.

page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/users/admin HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "users": {
        "id": "2",
        "username": "admin",
        "first_name": "joe",
        "last_name": "smith",
        "email": "email@email.com",
        "created_at": "2012-10-10T14:12:24Z",
        "modified_at": "2012-10-10T14:12:24Z",
        "href": "https://tenant.kzoplatform.com/api/users/admin",
        "avatar_href": "http://d6mgdbc2kfx06.cloudfront.net/...",
        "published": true,
        "links": {
            "created_by": {
                "username": "system",
                "type": "users"
            },
            "modified_by": {
                "username": "system",
                "type": "users"
            },
            "groups": [ 1, 2 ]
        },
        "meta": {
            "pipeline_status": "READY",
            "pipeline_resource": {
                "href": "https://tenant.kzoplatform.com/api/users/admin",
                "type": "containers"
            },
            "actions": [{
                "label" : "USER__EDIT_METADATA",
                "href" : "https://tenant.kzoplatform.com/api/users/admin",
                "method" : "PATCH"
            }, {
                "label" : "USER__UPDATE",
                "href" : "https://tenant.kzoplatform.com/api/users/admin",
                "type" : "PUT"
            }]
        }
    },
    "linked": {
        "users": [{
            "id": 1,
            "username": "system"
            ...
        }],
        "groups": [{
            "id": 1
            ...
        },{
            "id": 2
            ...
        }]
    },
    "meta": {}
}
Viewing Multiple Users
GET /users/{usernames}

Filtering is not supported.

Requires authenticated user.

Pagination: groups.

Path variables

usernames
string required

Comma-separated list of the usernames of multiple users

Example:
admin,system

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: modified_by,created_by,groups,groups.modified_by, groups.created_by,roles,avatars,home_container.

Example:
users
group_labels
string optional

Which kinds of groups are returned in associated objects if groups are requested in include.
Possible values: INDIVIDUAL,NONINDIVIDUAL,ALL.
NONINDIVIDUAL indicates that groups with all labels other than INDIVIDUAL should be returned. INDIVIDUAL and ALL are self-explanatory.
Default value: NONINDIVIDUAL.

page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/users/admin,system HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "users": [{
        "username" : "system"
        ...
    }, {
        "username" : "admin"
        ...
    }]
    ...
}
Searching Users
GET /users

Requires authenticated user.

Pagination: primary, groups.

Request parameters

created_by
string optional

Filtering by creator’s username with partial matching

Example:
admin
created_at_from
string optional

Filtering by creation time. Specifies beginning of inclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2012-10-10T14:12:24.324Z
created_at_to
string optional

Filtering by creation time. Specifies end of inclusive time interval using ISO8601 standard. If not set, it means until the end of time.

Example:
2013-10-10T14:12:24.324Z
modified_by
string optional

Filtering by last modifier’s username with partial matching

Example:
bob
modified_at_from
string optional

Filtering by modification time. Specifies beginning of exclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2012-10-10T14:12:24.324Z
modified_at_to
string optional

Filtering by modification time. Specifies end of exclusive time interval using ISO8601 standard. If not set, it means until the end of time.

Example:
2013-10-10T14:12:24.324Z
email
string optional

Filtering by email with partial matching.

Example:
com
username
string optional

Filtering by username with partial matching.

Example:
bob
first_name
string optional

Filtering by first name with partial matching.

Example:
john
last_name
string optional

Filtering by last name with partial matching.

Example:
smith
include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: modified_by,created_by,groups,groups.modified_by, groups.created_by,users.roles,home_container.

Example:
groups
sort
string optional

Comma-separated list of attributes by which sorting should be performed. The default sort order is ascending. A - prefix to attribute name on any sort field specifies a descending sort order. Default is unsorted. What can be included at most: TBD

Example:
-username
q
string optional

Filtering to match any of the following: username, email, first name, last name.

Example:
john
group_labels
string optional

Which kinds of groups are returned in associated objects if groups are requested in include.
Possible values: INDIVIDUAL,NONINDIVIDUAL,ALL.
NONINDIVIDUAL indicates that groups with all labels other than INDIVIDUAL should be returned. INDIVIDUAL and ALL are self-explanatory.
Default value: NONINDIVIDUAL.

group_id
number optional

If specified, return only members of a group with a given ID.

Example:
1
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the Viewing Multiple Users.

GET https://tenant.kzoplatform.com/api/users?include=users&sort=-username HTTP/1.1 
Creating User
POST /users

Requires Permission assigning Role:

  • IDENTITY_MANAGER for Users of all authentication_types.
  • INTEGRATION_VISITOR_IDENTITY_MANAGER for Users of all authentication_type=INTEGRATION_VISITOR.

User authentication types: NONE, PASSWORD, PUBLIC, IPAAS, SAML2, INTEGRATION_RESIDENT, INTEGRATION_VISITOR.

Allowed user authentication types via API: PASSWORD, INTEGRATION_RESIDENT, INTEGRATION_VISITOR.

Request headers

Content-Type
string required

Indicates the media type of the entity-body. Must be in the form application/vnd.api+json

X-KZO-API-Version
string required

Specifies API version. For details, see API Version.

X-KZO-Auth-AccessKey
string required

Access Key used by the API caller to authenticate against the server. For details, see Authentication and Authorization.

X-KZO-Auth-Username
string required

Username used by the API caller to authenticate against the server. For details, see Authentication and Authorization.

X-KZO-Pipeline-Action
string optional

Used to initiate special actions related to pipeline processing on a pipeline-enabled entity or an entity managed by a pipeline of its parent entity. For more details, see Workflow.

X-KZO-Tenant
string required

Specifies name of the Tenant to which the request is issued. For details, see [Tenant Management](doc://Tenant Management).

Request body

Object
users

Responses

201 Created
Headers
Location
string optional

Contains the URI of the newly created resource.

Body
Object
users
401 Unauthorized

The request requires Authentication and Authorization.

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the Viewing User.

POST https://tenant.kzoplatform.com/api/users HTTP/1.1 

Content-Type: application/json

{
    "users" : {
        "username" : "cparker",
        "first_name" : "Chris", 
        "last_name" : "Parker",
        "email" : "cparker@example.org",
        "password" : "password",
        "authentication_type": "PASSWORD"
    }
}
Updating User
PATCH /users/{username}

Requires Permission assigning Role:

  • IDENTITY_MANAGER for Users of all authentication_types.
  • INTEGRATION_VISITOR_IDENTITY_MANAGER for Users of all authentication_type=INTEGRATION_VISITOR.
  • Or if current user is user for editing (the same users).

Path variables

username
string required

Username

Example:
admin

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the Viewing User.

PATCH https://tenant.kzoplatform.com/api/users/admin HTTP/1.1 

Content-Type: application/json

[{
    "op": "replace", "path": "/email", "value": "new@example.org"  
}, {
    "op": "replace", "path": "/last_name", "value": "Bell"  
}]
Replacing User
PUT /users/{username}

Requires Permission assigning Role:

  • IDENTITY_MANAGER for Users of all authentication_types.
  • INTEGRATION_VISITOR_IDENTITY_MANAGER for Users of all authentication_type=INTEGRATION_VISITOR.
  • Or if current user is user for editing (the same users).

Path variables

username
string required

Username

Example:
admin

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the Viewing User.

PUT https://tenant.kzoplatform.com/api/users/admin HTTP/1.1 

Content-Type: application/json

{
    "users" : {
        "username" : "cparker",
        "first_name" : "Chris", 
        "last_name" : "Parker",
        "email" : "cparker@example.org",
        "password" : "password"
    }
}
Deleting User
DELETE /users/{username}

Requires Permission assigning Role:

  • IDENTITY_MANAGER for Users of all authentication_types.
  • INTEGRATION_VISITOR_IDENTITY_MANAGER for Users of all authentication_type=INTEGRATION_VISITOR.

Path variables

username
string required

Username

Example:
admin

Responses

204 No Content
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/users/admin HTTP/1.1 
Groups
GET /groups/{id}
GET /groups/{ids}
GET /groups
POST /groups
PATCH /groups/{id}
PUT /groups/{id}
DELETE /groups/{id}
POST /groups/{id}/users
DELETE /groups/{id}/users/{username}
Viewing Group
GET /groups/{id}

Requires authenticated user.

Pagination: users.

Path variables

id
number required

The id of group

Example:
1

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: modified_by,created_by,users,users.modified_by,users.created_by, permissions,permissions.modified_by,permissions.created_by.

group_labels
string optional

Which kinds of groups are returned.
Possible values: INDIVIDUAL,NONINDIVIDUAL,ALL.
NONINDIVIDUAL indicates that groups with all labels other than INDIVIDUAL should be returned. INDIVIDUAL and ALL are self-explanatory.
Default value: NONINDIVIDUAL.

page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/groups/1?include=users,permissions HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "users": [{
            "id": 1,
            "username": "system"
            ...
        }, {
            "id": 2,
            "username": "admin"
            ...
        }, {
            "id": 22,
            "username": "bob"
            ...
        }],
        "permissions": [{
            "id": 33
            ...
        }
            ...
        ]
    },
    "meta": {},
    "groups": {
        "id": "1",
        "name": "Administrators",
        "label": "ADMIN",
        "href": "https://tenant.kzoplatform.com/api/groups/1",
        "created_at": "2012-10-10T14:12:24Z",
        "modified_at": "2012-10-10T14:12:24Z",
        "published": true,
        "links": {
            "created_by": {
                "username": "system",
                "type": "users"
            },
            "modified_by": {
                "username": "admin",
                "type": "users"
            },
            "users": [ "admin", "bob" ]
        },
        "meta": {
            "pipeline_status": "READY",
            "pipeline_resource": {
                "href": "https://tenant.kzoplatform.com/api/groups/1",
                "type": "groups"
            },
            "actions": [{
                "label" : "GROUP__EDIT_METADATA",
                "href" : "https://tenant.kzoplatform.com/api/groups/1",
                "method" : "PATCH"
            }, {
                "label" : "GROUP__UPDATE",
                "href" : "https://tenant.kzoplatform.com/api/groups/1",
                "method" : "PUT"
            }. {
                "label" : "GROUP__ADD_USER",
                "href" : "https://tenant.kzoplatform.com/api/groups/1/users",
                "method" : "POST"
            }, {
                "label" : "GROUP__DELETE_USER",
                "href" : "https://tenant.kzoplatform.com/api/groups/1/users/:username",
                "method" : "DELETE"
            }]
        }
    }
}
Viewing Multiple Groups
GET /groups/{ids}

Requires authenticated user.

Pagination: users.

Path variables

ids
string required

The comma-separated list of IDs of the Groups.

Example:
45,56

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: modified_by,created_by,users,users.modified_by,users.created_by, permissions,permissions.modified_by,permissions.created_by.

group_labels
string optional

Which kinds of groups are returned.
Possible values: INDIVIDUAL,NONINDIVIDUAL,ALL.
NONINDIVIDUAL indicates that groups with all labels other than INDIVIDUAL should be returned. INDIVIDUAL and ALL are self-explanatory.
Default value: NONINDIVIDUAL.

page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/groups/23,34 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "groups": [{
        "id": 23
        ...
    },{
        "id": 34
        ...
    ]}
    ...
}
Searching Groups
GET /groups

Requires authenticated user.

Pagination: primary, users.

Request parameters

created_by
string optional

Filtering by creator’s username with partial matching

Example:
admin
created_at_from
string optional

Filtering by creation time. Specifies beginning of inclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2012-10-10T14:12:24.324Z
created_at_to
string optional

Filtering by creation time. Specifies end of inclusive time interval using ISO8601 standard. If not set, it means until the end of time.

Example:
2013-10-10T14:12:24.324Z
modified_by
string optional

Filtering by last modifier’s username with partial matching

Example:
bob
modified_at_from
string optional

Filtering by modification time. Specifies beginning of exclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2012-10-10T14:12:24.324Z
modified_at_to
string optional

Filtering by modification time. Specifies end of exclusive time interval using ISO8601 standard. If not set, it means until the end of time.

Example:
2013-10-10T14:12:24.324Z
name
string optional

Filtering by group name with partial matching.

Example:
something
description
string optional

Filtering by group description with partial matching.

Example:
many
label
string optional

Filtering by group label with partial matching.

Example:
indivi
include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: modified_by,created_by,users,users.modified_by,users.created_by.

group_labels
string optional

Which kinds of groups are returned.
Possible values: INDIVIDUAL,NONINDIVIDUAL,ALL.
NONINDIVIDUAL indicates that groups with all labels other than INDIVIDUAL should be returned. INDIVIDUAL and ALL are self-explanatory.
Default value: NONINDIVIDUAL.

username
string optional

If specified, return only groups of a user with a given username.

Example:
admin
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10
q
string optional

Filtering to match any of the following: name, description.

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Multiple Groups.

GET https://tenant.kzoplatform.com/api/groups?label=indivi HTTP/1.1 
Creating Group
POST /groups

Requires Permission assigning Role IDENTITY_MANAGER.

Responses

201 Created
Headers
Location
string optional

Contains the URI of the newly created resource.

401 Unauthorized

The request requires Authentication and Authorization.

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Group.

POST https://tenant.kzoplatform.com/api/groups HTTP/1.1 

Content-Type: application/json

{
    "groups" : {
        "name" : "New group"
    }
}
Updating Group
PATCH /groups/{id}

Requires Permission assigning Role IDENTITY_MANAGER.

Path variables

id
number required

The id of group

Example:
1

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Group.

PATCH https://tenant.kzoplatform.com/api/groups/1 HTTP/1.1 

Content-Type: application/json

[{ 
    "op": "replace", 
    "path": "/name", 
    "value": "New group name" 
}]
Replacing Group
PUT /groups/{id}

Requires Permission assigning Role IDENTITY_MANAGER.

Path variables

id
number required

The id of group

Example:
1

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Group.

PUT https://tenant.kzoplatform.com/api/groups/1 HTTP/1.1 

Content-Type: application/json

{
    "groups" : {
        "name" : "Test group"
    }
}
Deleting Group
DELETE /groups/{id}

Requires Permission assigning Role IDENTITY_MANAGER.

Path variables

id
number required

The id of group

Example:
1

Responses

204 No Content
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/groups/1 HTTP/1.1 
Adding User to Group
POST /groups/{id}/users

Requires Permission assigning Role IDENTITY_MANAGER. To add Users to Group with label=ADMIN, requires Permission assigning Role SUPERUSER.

Path variables

id
number required

The id of group

Example:
1

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Group.

POST https://tenant.kzoplatform.com/api/groups/1/users HTTP/1.1 

Content-Type: application/json

{
  "users": ["user_11", "user_22"]
}
Deleting User from Group
DELETE /groups/{id}/users/{username}

Requires Permission assigning Role IDENTITY_MANAGER. To delete Users from Group with label=ADMIN, requires Permission assigning Role SUPERUSER.

Path variables

id
number required

The id of group

Example:
1
username
string required

Username

Example:
rbob

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/groups/1/users/rbob HTTP/1.1 
Avatars
GET /avatars/{id}
Viewing Avatar
GET /avatars/{id}

Requires authenticated User.

Path variables

id
number optional

The ID of the Avatar

Example:
234

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: users,users.created_by,users.updated_by, created_by,updated_by.

Example:
created_by

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/avatars/234 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "avatars": {
        "id" : "234",
        "created_at" : "2012-10-10T14:12:24Z",
        "modified_at" : "2012-10-10T14:12:24Z",
        "href": "https://tenant.kzoplatform.com/api/avatars/234",
        "links" : {
            "users": "abc",
            "created_by" : {
                "username" : "admin",
                "type" : "users"
            },
            "modified_by" : {
                "username" : "admin",
                "type" : "users"
            }
        },
        "meta": {
            "actions": [{
                "label": "AVATAR___GET",
                "href": "https://tenant.kzoplatform.com/api/avatrs/234",
                "method": "GET"
            }, {
                "label": "AVATAR___DOWNLOAD",
                "href": "http://d6mgdbc2kfx06.cloudfront.net/...",
                "method": "GET"
            }
            ...
            ]
        }
    },
    "linked": {
        "users": [{
            "username": "abc"
            ...
        }, {
            "username": "admin"
            ...
        }]
    },
    "meta": {}
}
Capabilities

Capabilty gives specific access rights to Groups to which it is assigned through Roles which include this Capability. See Authentication and Authorization for a detailed explanation of Capabilities.

GET /capabilities/{name}
GET /capabilities
Viewing Capability
GET /capabilities/{name}

Requires Permission assigning Role ACCESS_MANAGER on at least one Container.

Path variables

name
string required

Name of the Capability

Example:
MANAGE_TENANT

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/capabilities/MANAGE_TENANT HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "capabilities": {
        "name": "MANAGE_TENANT",
        "description": "Allows to perform all actions on the Tenant",
        "root_only": true,
        "href": "https://tenant.kzoplatform.com/api/capabilities/MANAGE_TENANT",
        "links": [],
        "meta": {
            "actions": [{
                "label": "CAPABILITY___GET",
                "href" : "https://tenant.kzoplatform.com/api/capabilities/MANAGE_TENANT",
                "method" : "GET"
            }]
    },
    "linked": [],
    "meta": {}
}
Searching Capabilities
GET /capabilities

Limited functionality: lists all Capabilities available on the Platform.

Requires Permission assigning Role ACCESS_MANAGER on at least one Container.

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/capabilities HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "capabilities": [{
        "name": "MANAGE_TENANT"
        ...
    }, {
        "name": "MANAGE_ACCESS"
    }
    ...
    ]
    ...
}
Roles

Role is an aggregator of Capabilities. See Authentication and Authorization for a detailed explanation of Roles.

GET /roles/{id}
GET /roles
GET /roles/myself/containers/{id}
Viewing Role
GET /roles/{id}

Requires Permission assigning Role ACCESS_MANAGER on at least one Container.

Path variables

id
number required

The ID of the role

Example:
1

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: modified_by,created_by,capabilities.

Example:
capabilities

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/roles/2 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "roles": {
        "id": 2,
        "name": "SUPERUSER",
        "hidden": false,
        "created_at": "2012-10-10T14:12:24Z",
        "modified_at": "2012-10-10T14:12:24Z",
        "href": "https://tenant.kzoplatform.com/api/roles/2",
        "links": {
            "created_by": {
                "username": "system",
                "type": "users"
            },
            "modified_by": {
                "username": "system",
                "type": "users"
            },
            "capabilities": [ "MANAGE_TENANT" ]
        },
        "meta": {
            "actions": [{
                "label": "ROLE___GET",
                "href" : "https://tenant.kzoplatform.com/api/roles/2",
                "method" : "GET"
            }],
        }
    },
    "linked": {
        "users": [{
            "id": 1,
            "username": "system"
            ...
        }],
        "capabilities": [{
            "name": "MANAGE_TENANT"
            ...
        }]
    },
    "meta": {}
}
Searching Roles
GET /roles

Limited functionality: lists all roles available on the platform.

Requires Permission assigning Role ACCESS_MANAGER or INTEGRATION_VISITOR_ACCESS_MANAGER on at least one Container.

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/roles HTTP/1.1 

Content-Type: application/json

{
    "roles": [{
        "id" : 1
        ...
    }, {
        "id" : 2
        ...
    }
    ...
    ]
    ...
}
Viewing Own Administrative Roles
GET /roles/myself

Lists own administrative Roles of the API User (specifically, Roles which the User performing the request has on the root Container). Note, they are also returned as users.roles by the method Viewing Access Key.

Requires authenticated user.

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Searching Roles.

GET https://tenant.kzoplatform.com/api/roles/myself HTTP/1.1 
Viewing Own Roles On Container
GET /roles/myself/containers/{id}

Lists own Roles of the API User on the given container and its ancestors.

Requires authenticated user.

Path variables

id
string required

ID of container

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: modified_by,created_by,capabilities.

Responses

200 OK
404 Not Found

If the given container does not exist or the API User has no access to it.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/roles/myself/containers/123 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "capabilities": [
        ],
        "users": [
        ]
    },
    "meta": {
    },
    "roles": [
        {
            "id": "15",
            "href": "https://localhost:8080/api/roles/15",
            "name": "CONTENT_VIEWER",
            "hidden": false,
            "title": "Content Viewer",
            "description": "Can view content.",
            "links": {
                "capabilities": [
                ],
                "modified_by": {
                },
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "ROLE_GET",
                        "href": "https://localhost:8080/api/roles/15",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2016-08-29T04:42:46.166Z",
            "modified_at": "2016-08-29T04:42:46.166Z",
            "root_only": false
        },
        {
            "id": "7",
            "href": "https://localhost:8080/api/roles/7",
            "name": "CONTENT_MANAGER",
            "hidden": false,
            "title": "Content Manager",
            "description": "Can view, create, update and delete content.",
            "links": {
                "capabilities": [
                ],
                "modified_by": {
                },
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "ROLE_GET",
                        "href": "https://localhost:8080/api/roles/7",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2016-08-29T04:42:46.166Z",
            "modified_at": "2016-08-29T04:42:46.166Z",
            "root_only": false
        },
        {
            "id": "1",
            "href": "https://localhost:8080/api/roles/1",
            "name": "SUPERUSER",
            "hidden": false,
            "title": "Superuser",
            "description": "Can manage the Platform settings, other Platforms (from the privileged Tenant only), Users, Groups, Group Membership, Platform Access Keys, Create top level containers, and manage all Capabilities for any Group on all Containers. Can also do the same on behalf of another user if that user has necessary permissions.",
            "links": {
                "capabilities": [
                ],
                "modified_by": {
                },
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "ROLE_GET",
                        "href": "https://localhost:8080/api/roles/1",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2016-08-29T04:42:46.166Z",
            "modified_at": "2016-08-29T04:42:46.166Z",
            "root_only": true
        }
    ]
}
Permissions
GET /permissions/{id}
GET /permissions
POST /permissions
DELETE /permissions/{id}
Viewing Permission
GET /permissions/{id}

Requires access with Role ACCESS_MANAGER to the Container on which the given Permission is issued.

Path variables

id
number required

The ID of the Permission

Example:
1

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: roles,groups. What can be included at most: roles,groups,containers.

Example:
groups

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/permissions/12 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "users": [{
            "id": 1,
            "username": "system"
            ...
        }],
        "groups": [{
            "id": 2
            ...
        }],
        "roles": [{
            "id": 3
            ...
        }],
        "containers": [{
            "id": 4
            ...
        }]
    },
    "meta": {},
    "permissions": {
        "id": "12",
        "created_at": "2012-10-10T14:12:24Z",
        "href": "https://tenant.kzoplatform.com/api/permissions/12",
        "links": {
            "created_by": {
                "username": "system",
                "type": "users"
            },
            "groups": 2,
            "roles": 3,
            "containers": 4
        },
        "meta": {
            "actions": [{
                "label" : "PERMISSION__DELETE",
                "href" : "https://tenant.kzoplatform.com/api/permissions/12",
                "method" : "DELETE"
            }]
        }
    }
}
Searching Permissions
GET /permissions

Will return Permissions on Containers to which the User has access with Role ACCESS_MANAGER.

Request parameters

created_by
string optional

Filtering by creator’s username with partial matching

Example:
admin
created_at_from
string optional

Filtering by creation time. Specifies beginning of inclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2012-10-10T14:12:24.324Z
created_at_to
string optional

Filtering by creation time. Specifies end of inclusive time interval using ISO8601 standard. If not set, it means until the end of time.

Example:
2013-10-10T14:12:24.324Z
container_id
number optional

ID of a Contianer

Example:
1
group_id
number optional

ID of Group

Example:
2
role_id
number optional

ID of Role

Example:
3
include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: roles,groups. What can be included at most: roles,groups,containers.

Example:
groups

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/permissions?container_id=10 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "permissions": [{
        "id": 100
        ...
    }, {
        "id": 200
        ...
    }]
    ...
}
Creating Permission
POST /permissions

Permissions are a mapping between groups and roles and are applied to a container.

Requires access with Role ACCESS_MANAGER to the Container on which the given Permission is being issued.

Responses

201 Created
Headers
Location
string optional

Contains the URI of the newly created resource.

401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

411 Length Required

The server refuses to accept the request without a defined Content-Length.

415 Unsupported media type

The server is refusing to service the request because the entity of the request is in a format not supported by the requested resource for the requested method. For example, the server does not support the requested Content-Type.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method [Viewing Permissions](method://Viewing Permissions)

POST https://tenant.kzoplatform.com/api/permissions HTTP/1.1 

Content-Type: application/json

{
    "permissions" : {
        "role_id" : 12,
        "group_id" : 48,
        "container_id" : 33
    }
}
Deleting Permission
DELETE /permissions/{id}

Requires access with Role ACCESS_MANAGER to the Container on which the given Permission is issued.

Path variables

id
number required

The ID of permission

Example:
25

Responses

204 No Content
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/permissions/234 HTTP/1.1 
Properties

Properties can be defined on 3 levels, from upper to lower: installation (for all tenants on the installation), tenant (only for a given tenant), user (only for a given user). Value of Property defined on each next lower level overrides its value defined on upper levels.

GET /properties/{name}
POST /properties
PUT /properties/{name}
DELETE /properties/{name}
Viewing Property
GET /properties/{name}

Returns Property if it is defined on the Platform and available to the given User.

  • If Property is defined but not available to the given User, error 403 is returned.
  • If Property is not defined error 404 is returned.
  • If definition_level is requested, but Property is not defined on that level, 404 is returned, regardless of whether it is specified on other levels.
  • If User is not authenticated and if Property is defined but not available, error 403 is returned.

Unless parameter definition_level is provided, values defined on the deepmost level are returned (user has precedence over tenant, tenant has precedence over installation). In the response object, the level on which the returned value is actually defined is reflected via attribute definition_level .

Path variables

name
string required

The name of Property

Example:
property1

Request parameters

definition_level
string optional

Defines level of which the value of the Property is being queried.
Possible values: installation,tenant,user

Example:
tenant

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/properties/some_property HTTP/1.1 

Content-Type: application/json

{
    "properties": {
        "name": "some_property",
        "value": 90,
        "mutable": true,
        "deletable": true,
        "definition_level": "installation",
        "created_at": "2012-10-10T14:12:24Z",
        "updated_at": "2012-10-10T14:12:24Z",
        "links": {},
        "meta": {}
    },
    "linked": {},
    "meta": {}
}
Viewing Available Properties
GET /properties

Requires authenticated user. Lists all Properties available on the Platform for the given User. For each property, values defined on the deepmost definition level are returned (user has precedence over tenant, tenant has precedence over installation).

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

This example only demonstrates the key differences of the response from the response of the method Viewing Property.

GET https://tenant.kzoplatform.com/api/properties HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "properties": [{
        "name": "prop1"
        ...
    }, {
        "name": "prop2"
        ...
    }]
    ...
}
Creating Property
POST /properties

Defines value of Property on tenant or user level. Requires access with Role MANAGE_TENANT if tenant level is requested, requires authenticated User otherwise. Names of Properties created this way should be prefixed with custom., otherwise error 403 is returned, and cannot contain / or ?. An attempt to create Property with name which already exists on the given level leads to error 409.

Request parameters

definition_level
string required

Definition level on which the value of Property is to be defined.
Possible values: tenant,user

Example:
user

Responses

201 Created
401 Unauthorized

The request requires Authentication and Authorization.

409 Conflict

The request could not be completed due to a conflict with the current state of the resource. Examples: PUT is attempted with outdated ETag, or execution of a currently unavailable method was attempted (see also error 405 and Workflow for details).

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/properties?definition_level=user HTTP/1.1 

Content-Type: application/json

{
    "properties": {
        "name": "custom.prop_name",
        "value": "something"
    }
}
Replacing Property
PUT /properties/{name}

Redefine value of Property on tenant or user definition level. Requires access with Role MANAGE_TENANT if tenant level is requested, requires authenticated user otherwise. If Property is not modifiable, error 403 is returned. If tenant definition level is requested, the Property is defined on that level but not available to the given User, error 403 is returned. If tenant definition level is requested, but the Property is not defined on that level, error 404 is returned.

Path variables

name
string required

The name of Property

Example:
prop_name

Request parameters

definition_level
string required

Definition level on which the value of Property is to be redefined.
Possible values: tenant,user

Example:
tenant

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/properties/prop_name?definition_level=tenant HTTP/1.1 

Content-Type: application/json

{
    "properties": {
        "value": "something else"
    }
}
Deleting Property
DELETE /properties/{name}

Undefine property on tenant or user level. Requires access with Role MANAGE_TENANT if tenant level is requested, requires authenticated user otherwise. If property is not deletable on tenant level, error 403 is returned. If tenant level is requested, and the Property is defined on that level but not available to the given User, error 403 is returned. If tenant level is requested, and the Property is not defined on that level, error 404 is returned.

Path variables

name
string required

The name of Property

Example:
prop1

Request parameters

definition_level
string required

Definition level on which the value of Property is to be undefined.
Possible values: tenant,user

Example:
user

Responses

204 No Content
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/properties/prop1?definition_level=user HTTP/1.1 
L10n
Assets

Assets is an entity describing auxiliary files made available by the server, such as logo, custom CSS, etc.

GET /assets/{id}
POST /assets
DELETE /assets/{id}
Viewing Asset
GET /assets/{id}

Fetch a asset with a given id.

Requires authenticated user.

Path variables

id
number required

The ID of the Asset

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/assets/421028840647693900 HTTP/1.1 

Content-Type: application/json

{
  "linked": {},
  "meta": {},
  "assets": {
    "id": "421028840647693900",
    "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900",
    "links": {
      "modified_by": {},
      "created_by": {}
    },
    "meta": {
      "pagination": {},
      "actions": [
        {
          "label": "ASSET_CREATE",
          "href": "https://staging-101.kzoinnovations.com/api/assets",
          "method": "POST"
        },
        {
          "label": "ASSET_PROCESS",
          "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900/process",
          "method": "POST"
        },
        {
          "label": "ASSET_DELETE",
          "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900",
          "method": "DELETE"
        },
        {
          "label": "ASSET_GET",
          "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900",
          "method": "GET"
        },
        {
          "label": "ASSET_GET_ALL",
          "href": "https://staging-101.kzoinnovations.com/api/assets",
          "method": "GET"
        },
        {
          "label": "ASSET_DOWNLOAD",
          "href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/ASSET/421028840647693900?Expires=1438858146&Signature=dahWsY9E16ecPT9hT1MgHkAueXul6BCv6Hv7JLX~PNdPK~OZ6fvANhJgiQJjIyynBaJO5-yp103trkpSlhTNd3-H1OFvKG7iatDnzDp1-NszB8RWoow2AJ4J5UEyf2jMAv08gZSO~NIOM8uq9C4MxO094K5xW0Cwq939GtiGMz94kuYGDUzTnsK538JEzMB~elqMMk2h4NJoldwpX~f2cPYlPsiiHnoAbPauXcA6REbizspw4oXf0wGqX~~c1sYgJVvwkXXR~iWXp6dTpVGdzULXuN~8OjQ4Fw1ukSZqngNBLSnMmycxpCLx~ZZgZZOigFbYBe7lrr7Zg1MkYrskUg__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
          "method": "GET"
        }
      ]
    },
    "name": "logo",
    "is_init_data", true
    "created_at": "2015-08-04T21:49:08.974Z",
    "modified_at": "2015-08-04T21:49:09.842Z"
  }
}
Viewing Multiple Assets
GET /assets

Fetch all assets. If parameter name not empty, fetch a asset with a given name.

Requires authenticated user.

Request parameters

name
string optional

The name of asset

Default:
empty

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/assets HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "linked": {},
  "meta": {},
  "assets": [
    {
      "id": "418030388074518267",
      "href": "https://staging-101.kzoinnovations.com/api/assets/418030388074518267",
      "links": {
        "modified_by": {},
        "created_by": {}
      },
      "meta": {
        "pagination": {},
        "actions": [
          {
            "label": "ASSET_CREATE",
            "href": "https://staging-101.kzoinnovations.com/api/assets",
            "method": "POST"
          },
          {
            "label": "ASSET_PROCESS",
            "href": "https://staging-101.kzoinnovations.com/api/assets/418030388074518267/process",
            "method": "POST"
          },
          {
            "label": "ASSET_DELETE",
            "href": "https://staging-101.kzoinnovations.com/api/assets/418030388074518267",
            "method": "DELETE"
          },
          {
            "label": "ASSET_GET",
            "href": "https://staging-101.kzoinnovations.com/api/assets/418030388074518267",
            "method": "GET"
          },
          {
            "label": "ASSET_GET_ALL",
            "href": "https://staging-101.kzoinnovations.com/api/assets",
            "method": "GET"
          },
          {
            "label": "ASSET_DOWNLOAD",
            "href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/ASSET/418030388074518267?Expires=1438857996&Signature=TK-b~fXTa8uXe4gY1W~Fp2KTrg1mwGohFFrPzPQCX2xqcAyPwZP~0ipfB-1bTcIqrCvmADXlNxX2EFVE44PMiSNvSO5xLlATJlqK~rnwaDyglJabKU0DyZy3-3CW62r~8o~pRC1amO8Yo34d-ZQlc98wBbDMahzZKrYXo--1aArhzZkqWitWSty-v2HAbSg6Z0vuBUqLVPy~FEwkPjo-IpMjjDak0hKXzVFrRVl~7knxlgl8xGHfgXJznUqBvqccvPRsbrFtXJ6C7okhwg737oB2BkKUJ9l3wZx5pnyJjSbE1aJh0Ee7a5R-I7nVJyt-1TlmZwQe2qac~b1ewmbwGQ__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
            "method": "GET"
          }
        ]
      },
      "name": "companyLogo",
      "created_at": "2015-07-31T18:31:45.568Z",
      "modified_at": "2015-07-31T18:31:46.215Z"
    },
    {
      "id": "421028840647693900",
      "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900",
      "links": {
        "modified_by": {},
        "created_by": {}
      },
      "meta": {
        "pagination": {},
        "actions": [
          {
            "label": "ASSET_CREATE",
            "href": "https://staging-101.kzoinnovations.com/api/assets",
            "method": "POST"
          },
          {
            "label": "ASSET_PROCESS",
            "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900/process",
            "method": "POST"
          },
          {
            "label": "ASSET_DELETE",
            "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900",
            "method": "DELETE"
          },
          {
            "label": "ASSET_GET",
            "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900",
            "method": "GET"
          },
          {
            "label": "ASSET_GET_ALL",
            "href": "https://staging-101.kzoinnovations.com/api/assets",
            "method": "GET"
          },
          {
            "label": "ASSET_DOWNLOAD",
            "href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/ASSET/421028840647693900?Expires=1438857997&Signature=P9fZ1JcYdf-1nPJBMuanAf613GazsA~einkSE16FhCRMNI7Z9oODevdqeK1sF4dqImOn-8P8vhiUgjO-Rahp7uLiYmAD6qYutr5pqCaCOgpfHJHHxsWe9M1s3pncE8Xae01opVhbuM3FFq2rTYQHHlO51JD3kD74Ox3MtAXNb1jI0om6SJg6XTa~wXR-CgfnUbARySeY-fruGRRq~35yuJeveUzKckmW1GfF~54kwFB6u-zDU45uTsXIEgrjN3WA54pwiBhAtZ91Tx3WymE6~cKpWzH4BRCAJS4NdqJu0urHPA~PKZA4UtM3I-zn9GFcXBU1jBfRyYQkUk6Lap8RtA__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
            "method": "GET"
          }
        ]
      },
      "name": "logo",
      "created_at": "2015-08-04T21:49:08.974Z",
      "modified_at": "2015-08-04T21:49:09.842Z"
    },
    {
      "id": "421028905785235021",
      "href": "https://staging-101.kzoinnovations.com/api/assets/421028905785235021",
      "links": {
        "modified_by": {},
        "created_by": {}
      },
      "meta": {
        "pagination": {},
        "actions": [
          {
            "label": "ASSET_CREATE",
            "href": "https://staging-101.kzoinnovations.com/api/assets",
            "method": "POST"
          },
          {
            "label": "ASSET_PROCESS",
            "href": "https://staging-101.kzoinnovations.com/api/assets/421028905785235021/process",
            "method": "POST"
          },
          {
            "label": "ASSET_DELETE",
            "href": "https://staging-101.kzoinnovations.com/api/assets/421028905785235021",
            "method": "DELETE"
          },
          {
            "label": "ASSET_GET",
            "href": "https://staging-101.kzoinnovations.com/api/assets/421028905785235021",
            "method": "GET"
          },
          {
            "label": "ASSET_GET_ALL",
            "href": "https://staging-101.kzoinnovations.com/api/assets",
            "method": "GET"
          },
          {
            "label": "ASSET_DOWNLOAD",
            "href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/ASSET/421028905785235021?Expires=1438857997&Signature=dHNe0FVa80nkUiPrSsfTjPGaldtpauuoELo1Dfei6nZyRl7Kyhz7O8DkFVw9Xt3dZiiyafz81mD70kQvPwChKaV29PTB3UO5TODM0HPuyqyfv-pzyNpRqo4FvYwaP4zykYjK35EbRwpv0RKeJ~jpTpbA~g43lyoqSXv5CeD9gFElt6cwAaUtDute35ggpUw~icJ9~xeB8aO7HRQ0SNn~dnRgW7ELiKISj5zDEVqhiZNq-UuxEAmcXrENOfsgOxmZTfqcJnUjeVE9bRWW9Da~6PkLqaU~rjXy3vjkuRbteF2KzaTr1LZM~eLXuOQIlljdr5kQq8HIQsIP2mVOb9HefQ__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
            "method": "GET"
          }
        ]
      },
      "name": "css",
      "created_at": "2015-08-04T21:49:16.738Z",
      "modified_at": "2015-08-04T21:49:17.694Z"
    }
  ]
}
GET https://tenant.kzoplatform.com/api/assets?name=logo HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "linked": {},
  "meta": {},
  "assets": {
    "id": "421028840647693900",
    "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900",
    "links": {
      "modified_by": {},
      "created_by": {}
    },
    "meta": {
      "pagination": {},
      "actions": [
        {
          "label": "ASSET_CREATE",
          "href": "https://staging-101.kzoinnovations.com/api/assets",
          "method": "POST"
        },
        {
          "label": "ASSET_PROCESS",
          "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900/process",
          "method": "POST"
        },
        {
          "label": "ASSET_DELETE",
          "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900",
          "method": "DELETE"
        },
        {
          "label": "ASSET_GET",
          "href": "https://staging-101.kzoinnovations.com/api/assets/421028840647693900",
          "method": "GET"
        },
        {
          "label": "ASSET_GET_ALL",
          "href": "https://staging-101.kzoinnovations.com/api/assets",
          "method": "GET"
        },
        {
          "label": "ASSET_DOWNLOAD",
          "href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/ASSET/421028840647693900?Expires=1438858146&Signature=dahWsY9E16ecPT9hT1MgHkAueXul6BCv6Hv7JLX~PNdPK~OZ6fvANhJgiQJjIyynBaJO5-yp103trkpSlhTNd3-H1OFvKG7iatDnzDp1-NszB8RWoow2AJ4J5UEyf2jMAv08gZSO~NIOM8uq9C4MxO094K5xW0Cwq939GtiGMz94kuYGDUzTnsK538JEzMB~elqMMk2h4NJoldwpX~f2cPYlPsiiHnoAbPauXcA6REbizspw4oXf0wGqX~~c1sYgJVvwkXXR~iWXp6dTpVGdzULXuN~8OjQ4Fw1ukSZqngNBLSnMmycxpCLx~ZZgZZOigFbYBe7lrr7Zg1MkYrskUg__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
          "method": "GET"
        }
      ]
    },
    "name": "logo",
    "created_at": "2015-08-04T21:49:08.974Z",
    "modified_at": "2015-08-04T21:49:09.842Z"
  }
}
Create Asset
POST /assets

Create asset.

After asset will be created, use action ASSET_UPLOAD_WITH_PRESIGNED_URLto upload asset resource to Amazon S3 and make POST request to URL /assets/{id}/process for run asset processing.

Alternative (deprecated) method - ASSET_UPLOAD.

Requires Permission assigning Role MANAGE_TENANT.

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/assets HTTP/1.1 

Content-Type: application/json

{
    "assets": {
        "name": "logo",
        "is_init_data": true
    }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
  "linked": {},
  "meta": {},
  "assets": {
    "id": "421429885550991028",
    "href": "https://staging-101.kzoinnovations.com/api/assets/421429885550991028",
    "links": {
      "modified_by": {},
      "created_by": {}
    },
    "meta": {
      "pagination": {},
      "actions": [
        {
          "label": "ASSET_CREATE",
          "href": "https://staging-101.kzoinnovations.com/api/assets",
          "method": "POST"
        },
        {
          "label": "ASSET_PROCESS",
          "href": "https://staging-101.kzoinnovations.com/api/assets/421429885550991028/process",
          "method": "POST"
        },
        {
          "label": "ASSET_DELETE",
          "href": "https://staging-101.kzoinnovations.com/api/assets/421429885550991028",
          "method": "DELETE"
        },
        {
          "label": "ASSET_GET",
          "href": "https://staging-101.kzoinnovations.com/api/assets/421429885550991028",
          "method": "GET"
        },
        {
          "label": "ASSET_GET_ALL",
          "href": "https://staging-101.kzoinnovations.com/api/assets",
          "method": "GET"
        },
        {
          "label": "ASSET_UPLOAD",
          "href": "https://s3-external-1.amazonaws.com/kzo-staging-upload/",
          "method": "POST",
          "post_presigned_aws_s3": {
            "key": "kzo3/ASSET/421429885550991028",
            "awsAccessKeyId": "AKIAJRDQ75RV4OUWJGSA",
            "acl": "bucket-owner-full-control",
            "policy": "eyJleHBpcmF0aW9uIjoiMjAxNS0wOC0wNlQwNzowNTo1N1oiLCJjb25kaXRpb25zIjpbeyJidWNrZXQiOiJrem8tc3RhZ2luZy11cGxvYWQifSxbImVxIiwiJGtleSIsImt6bzMvQVNTRVQvNDIxNDI5ODg1NTUwOTkxMDI4Il0seyJhY2wiOiJidWNrZXQtb3duZXItZnVsbC1jb250cm9sIn0sWyJzdGFydHMtd2l0aCIsIiRDb250ZW50LVR5cGUiLCIiXSxbInN0YXJ0cy13aXRoIiwiJGZpbGVuYW1lIiwiIl1dfQ==",
            "signature": "uUrRoctunCa43QB7+JtUq5mcbUs="
          }
        },
        {
          "label": "ASSET_UPLOAD_WITH_PRESIGNED_URL",
          "href": "https://s3-external-1.amazonaws.com/kzo-staging-upload/kzo3/ASSET/421429885550991028?...",
          "method": "PUT"
        }
      ]
    },
    "name": "resource",
    "created_at": "2015-08-05T11:05:57.247Z",
    "modified_at": "2015-08-05T11:05:57.247Z"
  }
}
Delete Asset
DELETE /assets/{id}

Delete asset.

Requires Permission assigning Role MANAGE_TENANT.

Path variables

id
string optional

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/assets/421429885550991028 HTTP/1.1 

HTTP/1.1 204 No Content 
Reports
GET /reports/most_recently_created_media_by_container
GET /reports/most_viewed_media
GET /reports/containers_viewed
GET /reports/most_recently_created_media_by_user
GET /reports/media_viewed_csv
GET /reports/media_viewed_aggregated_by_session
GET /reports/containers_viewed_csv
GET /reports/media_viewed_aggregated_by_session_csv
GET /reports/media_viewed
GET /api/reports/container_viewed_aggregated_by_session
GET /api/reports/email_activity
GET /misc/csv/email_activity
GET /misc/csv/comments_for_medium
GET /misc/csv/scheduled_reports/{id}/comments_for_medium
GET /misc/csv/scheduled_reports/{id}/media_viewed_under_container
GET /api/scheduled_reports/{id}/media_viewed_under_container
Most recently created media by container
GET /reports/most_recently_created_media_by_container

Returns list of media as primary resource below parent (original or by reference), ordered by created_at.

Request parameters

container_id
number optional

The id of container. If empty, application will take id of root container.

Example:
395543960044442750
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10
include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: media.created_by,media.modified_by, parent,parent.created_by,parent.modified_by, chapters,chapters.created_by,chapters.modified_by, original_videos,original_videos.created_by,original_videos.modified_by, video_renditions,video_renditions.created_by,video_renditions.modified_by, slide_decks,slide_decks.created_by,slide_decks.modified_by, slides,slides.created_by,slides.modified_by, used_slides,used_slides.created_by,used_slides.modified_by, comments,comments.created_by,comments.modified_by,comments.deleted_by, comments.replies,comments.replies.created_by,comments.replies.modified_by,comments.replies.deleted_by, video_rendition_options,screenshots,screenshot_options, montages,montage_options.

If Replies are included, it is assumed that unlimited depth is requested.

Example:
parent,parent.created_by
deleted
boolean optional

Whether to include data on deleted resources into the response.
Default value is false.

Example:
true

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Multiple Media.

GET https://tenant.kzoplatform.com/api/reports/most_recently_created_media_by_container?container_id=395543960044442769&page_size_primary=10&page_size_related=20 HTTP/1.1 

HTTP/1.1 200 OK 
Most viewed media
GET /reports/most_viewed_media

Returns list of media as primary resource aggregated by user and ordered by hits for all media below parent container (original or by reference).

Request parameters

container_id
number optional

The id of container. If empty, application will take id of root container.

Example:
395543960044442750
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10
include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: media.created_by,media.modified_by, parent,parent.created_by,parent.modified_by, chapters,chapters.created_by,chapters.modified_by, original_videos,original_videos.created_by,original_videos.modified_by, video_renditions,video_renditions.created_by,video_renditions.modified_by, slide_decks,slide_decks.created_by,slide_decks.modified_by, slides,slides.created_by,slides.modified_by, used_slides,used_slides.created_by,used_slides.modified_by, comments,comments.created_by,comments.modified_by,comments.deleted_by, comments.replies,comments.replies.created_by,comments.replies.modified_by,comments.replies.deleted_by, video_rendition_options,screenshots,screenshot_options, montages,montage_options.

If Replies are included, it is assumed that unlimited depth is requested.

Example:
parent,parent.created_by
deleted
boolean optional

Whether to include data on deleted resources into the response.
Default value is false.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Multiple Media.

GET https://tenant.kzoplatform.com/api/reports/most_viewed_media?container_id=395543960044442769&page_size_primary=10&page_size_related=20 HTTP/1.1 

HTTP/1.1 200 OK 
Containers Viewed by User
GET /reports/containers_viewed

Returns data by all available containers which ever viewed.

This report contains a hierarchy of all descendants, containers and media, original and via references.

Report returns data in JSON API format.

Requires Permission assigning role VIEWER on the given container or it’s parent containers.

Request parameters

container_id
integer optional

If specified, include only the metrics related to the container with the given ID

Example:
1
user_id
integer optional

If specified, include only the metrics related to the user with the given ID

Example:
2
include
string optional

Comma-separated list of associated objects which should be included in the response. What can be included at most: containers,users.

Default:
users,containers
page_size_primary
integer optional

The maximum number of primary resources are to be returned (see Pagination)

Min: 1
Max: 2,147,483,647
Default:
10000
page
integer optional

The number of page (see Pagination)

Min: 1
Max: 2,147,483,647
Default:
1

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

Report for container with id = 502022615246837573

GET https://tenant.kzoplatform.com/api/reports/containers_viewed?container_id=1502022615246837500 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "linked": {
    "containers": [
      {
        "id": "502022615246837573",
        "href": "https://tenant.kzoplatform.com/api/containers/502022615246837573?page_size_related=10000",
        "links": {
          "favorites": {},
          "parent": {},
          "modified_by": {},
          "containers": [],
          "media": [],
          "created_by": {}
        },
        "meta": {
          "pagination": {},
          "full_references": {},
          "view_only_references": {},
          "state": {},
          "collective": {},
          "actions": [
            {
              "label": "CONTAINER_GET",
              "href": "https://tenant.kzoplatform.com/api/containers/502022615246837573?page_size_related=10000",
              "method": "GET"
            },
            {
              "label": "CONTAINER_UPDATE",
              "href": "https://tenant.kzoplatform.com/api/containers/502022615246837573",
              "method": "PUT"
            },
            {
              "label": "CONTAINER_CREATE",
              "href": "https://tenant.kzoplatform.com/api/containers/502022615246837573/container",
              "method": "POST"
            },
            {
              "label": "CONTAINER_EDIT_METADATA",
              "href": "https://tenant.kzoplatform.com/api/containers/502022615246837573",
              "method": "PATCH"
            },
            {
              "label": "MEDIA_CREATE",
              "href": "https://tenant.kzoplatform.com/api/containers/502022615246837573/medium",
              "method": "POST"
            },
            {
              "label": "CONTAINER_DELETE",
              "href": "https://tenant.kzoplatform.com/api/containers/502022615246837573",
              "method": "DELETE"
            },
            {
              "label": "MEDIA_CREATE_VIA_UPLOADER",
              "href": "https://tenant.kzoplatform.com/#/containers/502022615246837573/upload",
              "method": "GET"
            },
            {
              "label": "MEDIA_CREATE_VIA_COPY",
              "href": "https://tenant.kzoplatform.com/api/containers/502022615246837573/copy_medium",
              "method": "POST"
            },
            {
              "label": "MEDIA_CREATE_VIA_PRESENTER",
              "href": "https://tenant.kzoplatform.com/#/containers/502022615246837573/presenter",
              "method": "GET"
            },
            {
              "label": "CONTAINER_PLAY",
              "href": "https://tenant.kzoplatform.com/#/player/container/502022615246837573",
              "method": "GET"
            }
          ],
          "order": {
            "containers": {},
            "media": {}
          }
        },
        "root": false,
        "title": "Test Videos",
        "description": "A container that has nice videos used to test the player.",
        "created_at": "2015-11-24T15:49:19.301Z",
        "modified_at": "2015-12-07T16:35:05.771Z",
        "screenshot_href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/SCREENSHOT/598550992417461634.png?Expires=1460146868&Signature=il8PI3JOaxwZCwjYzHPxGGRklLgVrhhMEcS3p1v--XwvW3GWpTdSTScJo23FKSlkA~ldmxa3Rw91cx7tkdlSyfqJSThXCY1gdiK-yzZrYeyZr-7eVazeyySM1OSGNHCpvsZtIfAFj1T-Pe6S7Tgaf9S~-jpiZpM6KSy3SasePz~48uCcFISQ6XetmefKUdZ68wmga-MXjt~kZbvu5F5bm1sa3OI4q4zq9cyxjiLlqFsZMEo4XH8ILFJ8Vqpg9c8nW3VULYV0FGduM5uzwAff-kNnkxBvEZGBv9yI3ADRyuPOAkgVDiwYNHRumLzuZ~6kFYB4nHjuC1yQGj7~IGb-1Q__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
        "thumbnails": [
          {
            "x": null,
            "y": null,
            "href": {
              "DEFAULT": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/SCREENSHOT/598550992417461634.png?Expires=1460146868&Signature=il8PI3JOaxwZCwjYzHPxGGRklLgVrhhMEcS3p1v--XwvW3GWpTdSTScJo23FKSlkA~ldmxa3Rw91cx7tkdlSyfqJSThXCY1gdiK-yzZrYeyZr-7eVazeyySM1OSGNHCpvsZtIfAFj1T-Pe6S7Tgaf9S~-jpiZpM6KSy3SasePz~48uCcFISQ6XetmefKUdZ68wmga-MXjt~kZbvu5F5bm1sa3OI4q4zq9cyxjiLlqFsZMEo4XH8ILFJ8Vqpg9c8nW3VULYV0FGduM5uzwAff-kNnkxBvEZGBv9yI3ADRyuPOAkgVDiwYNHRumLzuZ~6kFYB4nHjuC1yQGj7~IGb-1Q__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
              "LARGE": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/SCREENSHOT/598551007777002884.png?Expires=1460146868&Signature=Fc7zeH6ubJoJ01Fjnfk1pqiPk-bhMNFvzwOwstlxNvXYQNI70JH40xFCBwfig~GUQrsYCPceuKBSU3m2G0zH0dEv551Aw9Ad7rolZPjQekl6T0HEy~ZVmWOyRLGr9AedS7Ud4ve7vm6BHa7kzTl1E3brnDhvvFD8u6LR8pOlw2XGu5uhhxfWqC6ak14wuiXZAja7zifo-jYj1HTmMdsDQAz~m7qzlV0pcvTxOHIz~UgPMZ-In8~uC44aPj7tyOImM8Hz60po-f-ZUXKeeibsiD3qqpF5X42sXaJAvWEmTzHzqPF6IyCpkT1uV989vhWhfCY56kBrGgWAeMe7YcS8aw__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
              "LARGE_PLAYICON": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/SCREENSHOT/598551020427023749.png?Expires=1460146868&Signature=PWyj9v93VChZytrCPPmCWVmd2-STIB--JIox9idXh1n9lqGdUwmDsIV0-VryBKvHjnvHjsfOS3aPGcXfC7V33-A1fdOfO8KGvmebxIQ7FXR1DDRQz5zwVAeh6WTtNt3bWzQwMQrOO3iU8d81r2QygqikDoBxsatyedSYSyJINZ1Qp6UEVXey6JFuoXnSjJbny96HclJDdP8cmrwtQJ6z7s4XnE7mEnAKkNt90UKegA0~DGxklhGtw9ZP9CzeSJevob6Zc67VgBiqt4Ost89jrRvnBS~8kn-uGZgEQkdrDQLv~OI0SahwWQMn8uHDlHLwaynaXj8cZ5G3wRayBBMNkw__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA"
            }
          }
        ]
      }
    ],
    "users": [
      {
        "id": "563492125128267292",
        "href": "https://tenant.kzoplatform.com/api/users/ivan2016?page_size_related=10000",
        "links": {
          "modified_by": {},
          "groups": [],
          "created_by": {},
          "avatars": ""
        },
        "meta": {
          "pagination": {},
          "state": {},
          "actions": [
            {
              "label": "USER_GET",
              "href": "https://tenant.kzoplatform.com/api/users/ivan2016?page_size_related=10000",
              "method": "GET"
            },
            {
              "label": "USER_CREATE",
              "href": "https://tenant.kzoplatform.com/api/users",
              "method": "POST"
            },
            {
              "label": "USER_DELETE",
              "href": "https://tenant.kzoplatform.com/api/users/ivan2016",
              "method": "DELETE"
            },
            {
              "label": "USER_GET_ALL",
              "href": "https://tenant.kzoplatform.com/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
              "method": "GET"
            },
            {
              "label": "USER_UPDATE",
              "href": "https://tenant.kzoplatform.com/api/users/ivan2016",
              "method": "PUT"
            },
            {
              "label": "USER_EDIT_METADATA",
              "href": "https://tenant.kzoplatform.com/api/users/ivan2016",
              "method": "PATCH"
            }
          ]
        },
        "created_at": "2016-02-17T11:18:15.368Z",
        "modified_at": "2016-04-08T13:48:09.496Z",
        "first_name": "Ivan",
        "last_name": "Ivvvanov",
        "username": "ivan2016",
        "email": "ivan@gmail.com",
        "avatar_href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/AVATAR/563492140269704740.png?Expires=1460919998&Signature=bVBZ9DPq2QJhg~IJdOiWUhlbb8V4g94krmyLDfBAv3lr5Kpux1lqWtYjoJ~5dCZ9Cga3-vcxv0YeV3d5IaqGhXuAElb8bBhe8qfTJpb6Z-b66ofttwDhvAPwWJcpvQlMRwb8mHfYeeBi5kIFXIfr3~xGV9ZSX8AHEjNENIbxTPkJMdCbLPLlefIVcWOpXJSnzJjNgS06JTiE8WwYmDUFm3Y0CbluxY-8qF8V5eWTesbP~mo6Ur0tpzQhWSs47ja9FxY5K-lyKKsbG1VHNJPKxlqHlcX4RXX~ffFK4PQw6lIMM7cQbpLCYZvmVkKUC8mA2JNMA~Im3q7RmYiEcND4RA__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA"
      }
    ]
  },
  "meta": {
    "pagination": {
      "total_results": 1,
      "links": {
        "prev": null,
        "next": null,
        "first": "https://tenant.kzoplatform.com/api/reports/containers_viewed?page_size_primary=10000&page_size_related=10000&page=1",
        "last": "https://tenant.kzoplatform.com/api/reports/containers_viewed?page_size_primary=10000&page_size_related=10000&page=1"
      }
    }
  },
  "report_entities": [
    {
        "id": "606251730182607977",
        "href": "",
        "links":{
            "viewed_by":{
                "type": "users",
                "username": "oscar"
            },
            "containers": "509351086990038735"
        },
        "meta":{
            "pagination":{},
            "actions":[]
        },
        "last_viewed_at": "2015-12-04T18:00:00.000Z",
        "hits": 1,
        "time_viewed_msec": 10829,
        "visits": 1,
        "descendant_media_trt_msec": 186000,
        "number_descendant_media": 1
    }
  ]
}
Most recently created media by user
GET /reports/most_recently_created_media_by_user

Returns list of media created by user, ordered by created_at.

Request parameters

username
string required
Example:
admin
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10
include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: media.created_by,media.modified_by, parent,parent.created_by,parent.modified_by, chapters,chapters.created_by,chapters.modified_by, original_videos,original_videos.created_by,original_videos.modified_by, video_renditions,video_renditions.created_by,video_renditions.modified_by, slide_decks,slide_decks.created_by,slide_decks.modified_by, slides,slides.created_by,slides.modified_by, used_slides,used_slides.created_by,used_slides.modified_by, comments,comments.created_by,comments.modified_by,comments.deleted_by, comments.replies,comments.replies.created_by,comments.replies.modified_by,comments.replies.deleted_by, video_rendition_options,screenshots,screenshot_options, montages,montage_options.

If Replies are included, it is assumed that unlimited depth is requested.

Example:
parent,parent.created_by
deleted
boolean optional

Whether to include data on deleted resources into the response.
Default value is false.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Multiple Media.

GET https://tenant.kzoplatform.com/api/reports/most_recently_created_media_by_user?username=admin&page_size_primary=10&page_size_related=10 HTTP/1.1 

HTTP/1.1 200 OK 
Media Viewed by User in CSV Format
GET /reports/media_viewed_csv

Returns data by all available media for current user which ever viewed.

Report returns data in CSV format.

Query string is allowed to contain at most one of medium_id and container_id parameters.

Request parameters

medium_id
integer optional

If specified, include only the metrics related to the medium with the given ID

Example:
1
user_id
integer optional

If specified, include only the metrics related to the user with the given ID

Example:
2
container_id
string optional

If specified, include only the metrics related to the media under the given container ID

Example:
3

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/reports/media_viewed_csv HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

userId,username,userFirstName,userLastName,userEmail,userDeletedAt,mediumId,mediumTitle,mediumTrt,timeViewed,timeViewedPercent,lastViewedAt,hits,visits
370940702781085354,alfonso-deleted-3709407027810853541557483946,Alfonso,Guillen,on@on.com,2016-01-08 01:51:08.645,384571249688319617,2015060312
Media non unique viewed time aggregated by user and session
GET /reports/media_viewed_aggregated_by_session

Method returns non unique view times for all media which current user (caller of method) has view access to (caller must have permission assigning role VIEWER on the parent containers of media objects to be returned). As media could be viewed by anybody, media viewed time report is split by users and sessions i.e. Every value viewed_time_msec in the row of report means how much time was spent by user to view media per particular session. As user could view media several times obviously mentioned time value viewed_time_msec can be grater than medium’s trt.

Report is returned in JSON API format.

If some caller passes another username as a parameter or doesn’t pass it at all caller must have VIEW_IDENTITIES capability. Otherwise method will return response code 403.

Records can also be filtered by medium or container:

  • If medium_id is specified, response will include only the records related to this medium if the API caller has ability to view it, otherwise 404 Not Found with message Medium with id %d is not found will be returned.
  • If container_id is specified, response will include only the records related to the media under this container if the API caller has ability to view it, otherwise 404 Not Found with message Container with id %d is not found will be returned.
  • If both medium_id and container_id are specified and this medium is under this container and the API caller has ability to view the container, response will include only the records related to this medium. If the API caller has ability to view this container, but the medium is not under it, 404 Not Found with message Medium %d is not found under container %d will be returned.

Request parameters

page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10
include
string optional

Comma separated list of related entities names. Existence of each mentioned entity means that there will be entity parameters at the output. For example if there is no sessions word in the include value there will be no any session related parameters at the output. The same situations with other parameters.

Default:
users,media,sessions
last_viewed_at_from
string date optional

If it is required to filter by last_viewed_at. Specifies beginning of exclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2012-10-10T14:12:24.324Z
last_viewed_at_to
string optional

If it is required to filter by last_viewed_at. Specifies end of exclusive time interval using ISO8601 standard. If not set, it means from the beginning of time. End of time if omitted.

Example:
2012-10-10T14:12:24.324Z
username
string optional

If it is required to filter by username with exact matching. If not specified, data for all users are returned, which requires VIEW_IDENTITIES capability. Any username other than API caller’s one also requires VIEW_IDENTITIES. Otherwise 403 will be returned.

user_authentication_type

If it is required to filter by users authentication type with exact matching. any if omitted.

medium_id
number optional

If specified, return only records related to this medium

container_id
string optional

If specified, return only records related to the media under this container

Responses

200 OK
403 Insufficient identity viewing privileges
400 Invalid parameters

If some of parameters was invalid

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

Obtainins report with default parameters. Example for returned media with content type - VIDEO

GET https://tenant.kzoplatform.com/api/reports/media_viewed_aggregated_by_session HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "linked": {
    "sessions": [
      {
        "id": "587405107813947070",
        "href": "",
        "links": {},
        "meta": {
          "pagination": {},
          "actions": []
        },
        "started_at": "2016-03-21T11:09:05.564Z",
        "ended_at": "2016-03-21T17:07:25.257Z",
        "http_user_agent": "Java/1.8.0_72",
        "ip": "127.0.0.1"
      }
    ],
    "media": [
      {
        "id": "584409458529015248",
        "href": "",
        "links": {
          "favorites": {},
          "parent": {},
          "slides": [],
          "comments": [],
          "chapters": [],
          "montages": [],
          "original_video": {},
          "created_by": {},
          "used_slides": [],
          "screenshots": [],
          "modified_by": {},
          "video_renditions": [],
          "screenshot_positions": [],
          "slide_deck": {}
        },
        "meta": {
          "pagination": {},
          "state": {},
          "metrics": {
            "favorites": 0,
            "comments": 0,
            "views": 0
          },
          "actions": [
            {
              "label": "MEDIA_GET",
              "href": "https://tenant.kzoplatform.com/api/media/584409458529015248?page_size_related=10000",
              "method": "GET"
            }
          ]
        },
        "title": null,
        "description": null,
        "created_at": null,
        "modified_at": null,
        "trt_msec": 2358,
        "screenshot_href": null,
        "deleted_at": null,
        "thumbnails": []
      }
    ],
    "users": [
      {
        "id": "583754245749085186",
        "href": "https://tenant.kzoplatform.com/api/users/admin?page_size_related=10000",
        "links": {
          "modified_by": {},
          "groups": [],
          "created_by": {},
          "avatars": ""
        },
        "meta": {
          "pagination": {},
          "state": {},
          "actions": [
            {
              "label": "USER_GET",
              "href": "https://tenant.kzoplatform.com/api/users/admin?page_size_related=10000",
              "method": "GET"
            },
            {
              "label": "USER_CREATE",
              "href": "https://tenant.kzoplatform.com/api/users",
              "method": "POST"
            },
            {
              "label": "USER_DELETE",
              "href": "https://tenant.kzoplatform.com/api/users/admin",
              "method": "DELETE"
            },
            {
              "label": "USER_GET_ALL",
              "href": "https://tenant.kzoplatform.com/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
              "method": "GET"
            },
            {
              "label": "USER_UPDATE",
              "href": "https://tenant.kzoplatform.com/api/users/admin",
              "method": "PUT"
            },
            {
              "label": "USER_EDIT_METADATA",
              "href": "https://tenant.kzoplatform.com/api/users/admin",
              "method": "PATCH"
            }
          ]
        },
        "created_at": "2016-03-16T10:15:28.453Z",
        "modified_at": "2016-03-16T10:15:28.453Z",
        "first_name": "admin",
        "last_name": "admin",
        "username": "admin",
        "email": "admin@kzotest.com",
        "avatar_href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo2/AVATAR/584415828343002577.png?Expires=1461223090&Signature=cJpq1M28DewJ5ufYjW1gZVf~NKXcDPpTISOl9yfQ73yU2yAGMALuCF77RjDL819ok24H5jEKrE7FUHhutHB5a9l~YkxftKzK9mlG8~pwqfC-sapzh-hQQ5SCaj2F~~AChviZ5a-nfk6oFYlITFkpQjlfSYVefCO5t1JZ9e8mskbiw5P3UW7V4PwUD5AuF8V1HwXnED1oVv5ezSqtzh7tyXO2KgJxfKruVpk2UN45~ouW5~zi9srd8b3xGjNqZ~5iK~uH60aWvRT8jz9i2extsETziGeFEbjwEooT-PqVrqGGINnF186-hPMp-wa6y~A0z3weT1wUZ2zcPqxf4jX0fg__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA"
      }
    ]
  },
  "meta": {
    "pagination": {
      "total_results": 1,
      "links": {
        "prev": null,
        "next": null,
        "first": "https://tenant.kzoplatform.com/api/reports/media_viewed_aggregated_by_session?page_size_primary=10000&page_size_related=10000&page=1",
        "last": "https://tenant.kzoplatform.com/api/reports/media_viewed_aggregated_by_session?page_size_primary=10000&page_size_related=10000&page=1"
      }
    }
  },
  "report_entities": [
    {
      "links": {
        "sessions": "587405107813947070",
        "viewed_by": {
          "type": "users",
          "username": "admin"
        },
        "media": "584409458529015248"
      },
      "meta": {
        "pagination": {},
        "actions": []
      },
      "last_viewed_at": "2016-03-22T06:48:18.657Z",
      "hits": 0,
      "time_viewed_msec": 3050,
      "visits": 1,
      "completion": null,
      "success": null,
      "score": null
    }
  ]
}

Obtainins report with default parameters. Example for returned media with content type - RUSTICI_ENGINE_COURSE

GET https://tenant.kzoplatform.com/api/reports/media_viewed_aggregated_by_session HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "linked": {
    "sessions": [
      {
        "id": "1400484065412387914",
        "href": "",
        "links": {},
        "meta": {
          "pagination": {},
          "actions": []
        },
        "started_at": "2019-04-17T07:11:50.457Z",
        "ended_at": "2019-04-17T14:05:49.495Z",
        "http_user_agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36",
        "ip": null
      }
    ],
    "media": [
      {
        "id": "1400484901429449806",
        "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806?page_size_related=10000",
        "title": "golf",
        "description": null,
        "links": {
          "favorites": {},
          "parent": {},
          "slides": [],
          "authored_by": {},
          "comments": [],
          "chapters": [],
          "montages": [],
          "closed_captions_sets": [],
          "original_video": {},
          "deleted_by": {},
          "owned_by": {
            "type": "users",
            "username": "user@kzoplatform.com"
          },
          "created_by": {},
          "used_slides": [],
          "screenshots": [],
          "rustici_engine_course": {},
          "replies": [],
          "player_layout_timings": [],
          "modified_by": {},
          "video_renditions": [],
          "unique_viewed_ranges": {},
          "screenshot_positions": [],
          "slide_deck": {}
        },
        "meta": {
          "notification_subscription": {
            "direct": null,
            "inherited": false
          },
          "pagination": {},
          "state": {
            "pipeline_status": "READY",
            "published": true,
            "pipeline_resource": {
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806?page_size_related=10000",
              "type": "media"
            }
          },
          "metrics": {
            "favorites": 0,
            "comments": 0,
            "views": "1"
          },
          "actions": [
            {
              "label": "MEDIA_GET",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806?page_size_related=10000",
              "method": "GET"
            },
            {
              "label": "MEDIA_EDIT_METADATA",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806",
              "method": "PATCH"
            },
            {
              "label": "MEDIA_DELETE",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806",
              "method": "DELETE"
            },
            {
              "label": "MEDIA_UPDATE",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806",
              "method": "PUT"
            },
            {
              "label": "MEDIA_PLAY",
              "href": "https://tenant.kzoplatform.com/player/medium/1400484901429449806",
              "method": "GET"
            },
            {
              "label": "CLOSED_CAPTIONS_SET_CREATE",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806/closed_captions_set",
              "method": "POST"
            },
            {
              "label": "CHAPTER_CREATE",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806/chapter",
              "method": "POST"
            },
            {
              "label": "COMPLETION_SUBSCRIPTION_POST",
              "href": "https://tenant.kzoplatform.com/api/feature_interactions/SCORM/completion_subscriptions",
              "method": "POST"
            },
            {
              "label": "COMMENT_CREATE",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806/comment",
              "method": "POST"
            },
            {
              "label": "SCREENSHOT_POSITION___CREATE",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806/screenshot_position",
              "method": "POST"
            },
            {
              "label": "MEDIA_UPDATE_AUTHORED_BY",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806",
              "method": "PUT"
            },
            {
              "label": "SLIDE_DECK_CREATE",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806/slide_deck",
              "method": "POST"
            },
            {
              "label": "VIEWED_FRAGMENT_CREATE",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806/viewed_fragment",
              "method": "POST"
            },
            {
              "label": "CLOSED_CAPTIONS_SET_EXTRACT_CCS",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806/extract_ccs",
              "method": "POST"
            },
            {
              "label": "CUSTOM_SCREENSHOT_CREATE",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806/custom_screenshot",
              "method": "POST"
            },
            {
              "label": "CUSTOM_SCREENSHOT_CANOPY_CREATE",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806/custom_screenshot?purpose=CANOPY",
              "method": "POST"
            },
            {
              "label": "NOTIFICATION_SUBSCRIPTION_CREATE",
              "href": "https://tenant.kzoplatform.com/api/media/1400484901429449806/subscription",
              "method": "POST"
            }
          ]
        },
        "created_at": "2019-04-17T07:13:30.124Z",
        "modified_at": "2019-04-17T07:13:30.124Z",
        "deleted_at": null,
        "trt_msec": "0",
        "content_type": "RUSTICI_ENGINE_COURSE",
        "screenshot_href": null,
        "subscription": false,
        "custom_attributes": null,
        "thumbnails": []
      }
    ],
    "users": [
      {
        "id": "1267227458919208598",
        "href": "https://tenant.kzoplatform.com/api/users/user%40kzoplatform.com?page_size_related=10000",
        "links": {
          "modified_by": {},
          "home_container": {},
          "deleted_by": {},
          "groups": [],
          "created_by": {},
          "avatars": ""
        },
        "meta": {
          "pagination": {},
          "state": {},
          "actions": [
            {
              "label": "USER_GET",
              "href": "https://tenant.kzoplatform.com/api/users/user%40kzoplatform.com?page_size_related=10000",
              "method": "GET"
            },
            {
              "label": "USER_GET_ALL",
              "href": "https://tenant.kzoplatform.com/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
              "method": "GET"
            },
            {
              "label": "USER_UPDATE_AUTHENTICATION_TYPE",
              "href": "https://tenant.kzoplatform.com/api/users/user%40kzoplatform.com",
              "method": "PUT"
            },
            {
              "label": "USER_EDIT_METADATA_AUTHENTICATION_TYPE",
              "href": "https://tenant.kzoplatform.com/api/users/user%40kzoplatform.com",
              "method": "PATCH"
            },
            {
              "label": "USER_DELETE",
              "href": "https://tenant.kzoplatform.com/api/users/user%40kzoplatform.com",
              "method": "DELETE"
            }
          ]
        },
        "created_at": "2018-10-15T10:34:45.078Z",
        "modified_at": "2018-10-15T10:34:45.078Z",
        "deleted_at": null,
        "first_name": "Test",
        "last_name": "Test",
        "username": "user@kzoplatform.com",
        "email": "user@kzoplatform.com",
        "authentication_type": "OIDC",
        "avatar_href": "https://tenant.kzoplatform.com/kzo32/AVATAR/1267227460135556766.png?Expires=1556806869&Signature=LHBxCNoipzJVIXuoqjYMMrTuRD~WKX2qVTXawrrBrHLZd8R~Ti904GE8v5Onkv5dvKd9qFu0K~IGTpcOpBjeZvF7ld4px8Gi1nG19XMwWQgqs2ptV5B8qml-Hk6dz0yBmyJB13xOCHu0LfnCjnHW8~6hhHdWCb42xdOJUjwI5LxnU0HvZS~bGR3DS9bkNxKKDtnp4mefFJfnXr1p0WgIk0bpSo-6nHPBj2u3GiMET0WG-lnK0bbueApVcNggO50yogRm~Vpux3y9~g8-kRNuByJmmjtYUi2mMSzUv6j9ag15j8JkUxOLD5nNBjevnVNWVqDJ4maTBlzJ2Pj7Izk1bg__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
        "custom_authn_option_id": "1187662302933947477",
        "custom_attributes": null
      }
    ]
  },
  "meta": {
    "pagination": {
      "total_results": 1,
      "links": {
        "last": "https://tenant.kzoplatform.com/api/reports/media_viewed_aggregated_by_session?page_size_primary=24&include=media%2Csessions%2Cusers&last_viewed_at_from=2019-03-02T17%3A00%3A00.000%2B0000&last_viewed_at_to=2019-05-02T16%3A59%3A59.662%2B0000&page_size_related=24&page=1&medium_id=1400484901429449806",
        "first": "https://tenant.kzoplatform.com/api/reports/media_viewed_aggregated_by_session?page_size_primary=24&include=media%2Csessions%2Cusers&last_viewed_at_from=2019-03-02T17%3A00%3A00.000%2B0000&last_viewed_at_to=2019-05-02T16%3A59%3A59.662%2B0000&page_size_related=24&page=1&medium_id=1400484901429449806"
      }
    }
  },
  "report_entities": [
    {
      "id": "1400500213281461365",
      "href": "",
      "links": {
        "sessions": "1400484065412387914",
        "viewed_by": {
          "type": "users",
          "username": "user@kzoplatform.com"
        },
        "media": "1400484901429449806"
      },
      "meta": {
        "pagination": {},
        "actions": []
      },
      "last_viewed_at": "2019-04-17T07:43:55.419Z",
      "hits": 1,
      "time_viewed_msec": "0",
      "visits": 1,
      "completion": "COMPLETED",
      "success": "PASSED",
      "score": 100.0
    }
  ]
}


Containers Viewed by User in CSV Format
GET /reports/containers_viewed_csv

Returns data by all available containers which ever viewed.

This report contains a hierarchy of all descendants, containers and media, original and via references.

Report returns data in CSV format.

Requires Permission assigning role VIEWER on the given container or it’s parent containers.

Request parameters

container_id
integer optional

If specified, include only the metrics related to the container with the given ID

Example:
1
user_id
integer optional

If specified, include only the metrics related to the user with the given ID

Example:
2

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/reports/containers_viewed_csv HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

userId,username,userFirstName,userLastName,userEmail,userDeletedAt,containerId,containerTitle,descendantMediaNumber,descendantMediaTrt,timeViewed,timeViewedPercent,lastViewedAt,hits,visits
316971537179612168,anonymous,Anonymous,User,noreply@kzoinnovations.com,,316971525670441987,Root Container,268,06:49:52,00:17:57,4,Mon Apr 11 01:58:34 KGT 2016,97,9
Media Viewed by User by Session in CSV Format
GET /reports/media_viewed_aggregated_by_session_csv

Return data about media viewed by current user. Data is also grouped by sessions. Report is returned in CSV format.

Requires Permission assigning Role VIEWER on the parent Containers of the given Media objects.

Request parameters

last_viewed_at_from
string date optional

Filtering by last_viewed_at. Specifies beginning of exclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2012-10-10T14:12:24.324Z

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/reports/media_viewed_aggregated_by_session_csv HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

sessionId,userId,username,userFirstName,userLastName,userEmail,userDeletedAt,mediumId,mediumTitle,mediumTrt,timeViewed,timeViewedPercent,lastViewedAt,hits,completion,success,score
438124115107255742,316971525670441986,admin,admin,admin,admin@kzotest.com,,328537880626468139,My Media,00:00:16,00:00:00,0,Thu Jul 23 00:00:00 KGT 2015,1,,,
1400484065412387914,1267227458919208598,admin,admin,admin,admin@kzotest.com,,1400484901429449806,golf,00:00:00,00:00:00,100,2019-04-17T07:43:55.419,1,COMPLETED,PASSED,100.0
Media Viewed by User
GET /reports/media_viewed

Returns data by all available media for current user which ever viewed.

Report returns data in CSV format.

Request parameters

medium_id
integer optional

If specified, include only the metrics related to the medium with the given ID

Example:
1
user_id
integer optional

If specified, include only the metrics related to the user with the given ID

Example:
2
include
string optional

Comma-separated list of associated objects which should be included in the response. What can be included at most: users,media.

Default:
users,media
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/reports/media_viewed?page_size_primary=10 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "media": [
            {
                "id": "328537880626468139",
                "href": "https://localhost:8080/api/media/328537880626468139?page_size_related=10000",
                "links": {
                    "favorites": {
                    },
                    "parent": {
                    },
                    "slides": [
                    ],
                    "comments": [
                    ],
                    "chapters": [
                    ],
                    "montages": [
                    ],
                    "original_video": {
                    },
                    "created_by": {
                    },
                    "used_slides": [
                    ],
                    "screenshots": [
                    ],
                    "modified_by": {
                    },
                    "video_renditions": [
                    ],
                    "screenshot_positions": [
                    ],
                    "slide_deck": {
                    }
                },
                "meta": {
                    "pagination": {
                    },
                    "state": {
                    },
                    "metrics": {
                        "favorites": 0,
                        "comments": 0,
                        "views": 9
                    },
                    "actions": [
                        {
                            "label": "MEDIA_GET",
                            "href": "https://localhost:8080/api/media/328537880626468139?page_size_related=10000",
                            "method": "GET"
                        },
                        {
                            "label": "MEDIA_DELETE",
                            "href": "https://localhost:8080/api/media/328537880626468139",
                            "method": "DELETE"
                        },
                        {
                            "label": "MEDIA_UPDATE",
                            "href": "https://localhost:8080/api/media/328537880626468139",
                            "method": "PUT"
                        },
                        {
                            "label": "SCREENSHOT_POSITION___CREATE",
                            "href": "https://localhost:8080/api/media/328537880626468139/screenshot_position",
                            "method": "POST"
                        },
                        {
                            "label": "MEDIA_EDIT_METADATA",
                            "href": "https://localhost:8080/api/media/328537880626468139",
                            "method": "PATCH"
                        },
                        {
                            "label": "ORIGINAL_RENDITION_CREATE",
                            "href": "https://localhost:8080/api/media/328537880626468139/original_video",
                            "method": "POST"
                        },
                        {
                            "label": "SLIDE_DECK_CREATE",
                            "href": "https://localhost:8080/api/media/328537880626468139/slide_deck",
                            "method": "POST"
                        },
                        {
                            "label": "MEDIA_PLAY",
                            "href": "https://localhost:8080/#/player/medium/328537880626468139",
                            "method": "GET"
                        },
                        {
                            "label": "COMMENT_CREATE",
                            "href": "https://localhost:8080/api/media/328537880626468139/comment",
                            "method": "POST"
                        },
                        {
                            "label": "CHAPTER_CREATE",
                            "href": "https://localhost:8080/api/media/328537880626468139/chapter",
                            "method": "POST"
                        },
                        {
                            "label": "VIEWED_FRAGMENT_CREATE",
                            "href": "https://localhost:8080/api/media/328537880626468139/viewed_fragment",
                            "method": "POST"
                        },
                        {
                            "label": "CUSTOM_SCREENSHOT_CREATE",
                            "href": "https://localhost:8080/api/media/328537880626468139/custom_screenshot",
                            "method": "POST"
                        }
                    ]
                },
                "title": "My Media",
                "description": "Media description",
                "created_at": "2015-03-30T07:06:17.398Z",
                "modified_at": "2015-03-30T07:06:17.398Z",
                "trt_msec": 16000,
                "screenshot_href": null,
                "deleted_at": null,
                "thumbnails": [
                ]
            },
            {
                "id": "384571249688319617",
                "href": "https://localhost:8080/api/media/384571249688319617?page_size_related=10000",
                "links": {
                    "favorites": {
                    },
                    "parent": {
                    },
                    "slides": [
                    ],
                    "comments": [
                    ],
                    "chapters": [
                    ],
                    "montages": [
                    ],
                    "original_video": {
                    },
                    "created_by": {
                    },
                    "used_slides": [
                    ],
                    "screenshots": [
                    ],
                    "modified_by": {
                    },
                    "video_renditions": [
                    ],
                    "screenshot_positions": [
                    ],
                    "slide_deck": {
                    }
                },
                "meta": {
                    "pagination": {
                    },
                    "state": {
                    },
                    "metrics": {
                        "favorites": 0,
                        "comments": 12,
                        "views": 39
                    },
                    "actions": [
                        {
                            "label": "MEDIA_GET",
                            "href": "https://localhost:8080/api/media/384571249688319617?page_size_related=10000",
                            "method": "GET"
                        },
                        {
                            "label": "MEDIA_DELETE",
                            "href": "https://localhost:8080/api/media/384571249688319617",
                            "method": "DELETE"
                        },
                        {
                            "label": "MEDIA_UPDATE",
                            "href": "https://localhost:8080/api/media/384571249688319617",
                            "method": "PUT"
                        },
                        {
                            "label": "SCREENSHOT_POSITION___CREATE",
                            "href": "https://localhost:8080/api/media/384571249688319617/screenshot_position",
                            "method": "POST"
                        },
                        {
                            "label": "MEDIA_EDIT_METADATA",
                            "href": "https://localhost:8080/api/media/384571249688319617",
                            "method": "PATCH"
                        },
                        {
                            "label": "ORIGINAL_RENDITION_CREATE",
                            "href": "https://localhost:8080/api/media/384571249688319617/original_video",
                            "method": "POST"
                        },
                        {
                            "label": "SLIDE_DECK_CREATE",
                            "href": "https://localhost:8080/api/media/384571249688319617/slide_deck",
                            "method": "POST"
                        },
                        {
                            "label": "MEDIA_PLAY",
                            "href": "https://localhost:8080/#/player/medium/384571249688319617",
                            "method": "GET"
                        },
                        {
                            "label": "VIEWED_FRAGMENT_CREATE",
                            "href": "https://localhost:8080/api/media/384571249688319617/viewed_fragment",
                            "method": "POST"
                        },
                        {
                            "label": "COMMENT_CREATE",
                            "href": "https://localhost:8080/api/media/384571249688319617/comment",
                            "method": "POST"
                        },
                        {
                            "label": "CHAPTER_CREATE",
                            "href": "https://localhost:8080/api/media/384571249688319617/chapter",
                            "method": "POST"
                        },
                        {
                            "label": "CUSTOM_SCREENSHOT_CREATE",
                            "href": "https://localhost:8080/api/media/384571249688319617/custom_screenshot",
                            "method": "POST"
                        }
                    ]
                },
                "title": "2015060312 00compliancewithadaandsection503oftherehabilitationact",
                "description": null,
                "created_at": "2015-06-15T14:34:54.238Z",
                "modified_at": "2015-06-15T14:34:54.238Z",
                "trt_msec": 5028000,
                "screenshot_href": null,
                "deleted_at": null,
                "thumbnails": [
                ]
            }
        ],
        "users": [
            {
                "id": "370940702781085354",
                "href": "https://localhost:8080/api/users/alfonso-deleted-3709407027810853541557483946?page_size_related=10000",
                "links": {
                    "modified_by": {
                    },
                    "groups": [
                    ],
                    "created_by": {
                    },
                    "avatars": ""
                },
                "meta": {
                    "pagination": {
                    },
                    "state": {
                    },
                    "actions": [
                        {
                            "label": "USER_GET",
                            "href": "https://localhost:8080/api/users/alfonso-deleted-3709407027810853541557483946?page_size_related=10000",
                            "method": "GET"
                        },
                        {
                            "label": "USER_CREATE",
                            "href": "https://localhost:8080/api/users",
                            "method": "POST"
                        },
                        {
                            "label": "USER_DELETE",
                            "href": "https://localhost:8080/api/users/alfonso-deleted-3709407027810853541557483946",
                            "method": "DELETE"
                        },
                        {
                            "label": "USER_GET_ALL",
                            "href": "https://localhost:8080/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
                            "method": "GET"
                        },
                        {
                            "label": "USER_UPDATE",
                            "href": "https://localhost:8080/api/users/alfonso-deleted-3709407027810853541557483946",
                            "method": "PUT"
                        },
                        {
                            "label": "USER_EDIT_METADATA",
                            "href": "https://localhost:8080/api/users/alfonso-deleted-3709407027810853541557483946",
                            "method": "PATCH"
                        }
                    ]
                },
                "created_at": "2015-05-27T19:13:15.935Z",
                "modified_at": "2016-01-07T17:11:41.477Z",
                "first_name": "Alfonso",
                "last_name": "Guillen",
                "username": "alfonso-deleted-3709407027810853541557483946",
                "email": "on@on.com",
                "authentication_type": "PASSWORD",
                "avatar_href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/AVATAR/370940707277379250.png?Expires=1467889279&Signature=AwL6PgXVgosjL4BV3SQRjAoAYHd6vpoE773hI1b-sri-5UQF~4jzNiiPYftCuc6NgNw0keFRyoJdsT2Bg4FdpaP2LcKLB0dBiw2mK8jvZJhwpC1rAEIZmySXSll3P03ZBIkr7eJFhLtFGSDaQ0t6jhRv4EaZnt1a4BkACuPdolhhzabZWaX7LiNBJLE1LDz22s7M~t0RiOJB0fLFNMxSiqhgkDO6U1yeFIF2YaiB-rQqGECAad1IfiP6uac2A~v~Rnw9XTKGi7AHR8SJqs6C65K60wM2pUOwh4awehmJKT1RCZuwYvNp6jI7KM4kEQs5Pi2bvfFKtoEWaa~hWfeV4w__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
                "deleted_at": "2016-01-07T19:51:08.645Z",
                "deleted_by": "User{firstName=Oscar, lastName=Guillen, userName=oscar, password=$2a$10$CRlHFFM5REg1BC6m/TBnD.tdP55HsaWJIDjggHNCWqKvHhF7x1N/u, passwordHashType=BCRYPT, email=osalfo@yahoo.com, pipelineStatus=READY, pipelineInstance=null, published=true, createdVia=PASSWORD, label=NONE}"
            },
            {
                "id": "316971525670441986",
                "href": "https://localhost:8080/api/users/admin?page_size_related=10000",
                "links": {
                    "modified_by": {
                    },
                    "groups": [
                    ],
                    "created_by": {
                    },
                    "avatars": ""
                },
                "meta": {
                    "pagination": {
                    },
                    "state": {
                    },
                    "actions": [
                        {
                            "label": "USER_GET",
                            "href": "https://localhost:8080/api/users/admin?page_size_related=10000",
                            "method": "GET"
                        },
                        {
                            "label": "USER_CREATE",
                            "href": "https://localhost:8080/api/users",
                            "method": "POST"
                        },
                        {
                            "label": "USER_DELETE",
                            "href": "https://localhost:8080/api/users/admin",
                            "method": "DELETE"
                        },
                        {
                            "label": "USER_GET_ALL",
                            "href": "https://localhost:8080/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
                            "method": "GET"
                        },
                        {
                            "label": "USER_UPDATE",
                            "href": "https://localhost:8080/api/users/admin",
                            "method": "PUT"
                        },
                        {
                            "label": "USER_EDIT_METADATA",
                            "href": "https://localhost:8080/api/users/admin",
                            "method": "PATCH"
                        }
                    ]
                },
                "created_at": "2015-03-14T08:05:50.374Z",
                "modified_at": "2015-03-14T08:05:50.374Z",
                "first_name": "admin",
                "last_name": "admin",
                "username": "admin",
                "email": "admin@kzotest.com",
                "authentication_type": "PASSWORD",
                "avatar_href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/AVATAR/359696837701014575.png?Expires=1467889279&Signature=WLFt5Bti5fhM1Y9013NDro3F97NZsYm3P3OCfl~z5TiHPmqferKL6qiCBuyfXfxeuimxGi9h5oYAJqCpR8WKCufQnwNQlO1YgUdXoL621TgLbjPr9f7M6a30d5~X66f2P8fBPpSzE3iHmMdtuv6YD96Pc~repufO6tSD4BdpmFhBy2zX2aifhctBEddTc5hJPspr4uOZDhGEgblx0saSfzTmhRUQG44KQ46w6mJP7oSKqykDgYxmMMqEqbmfmtTJmkgLhh5phLF~N6RB4ZMcY7FB7gzxMCqpkFiDKiVaZAIj4H-RYXVasnj5A2oT2EVSz-mC0ZnIUZe1xBftsP0RUw__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA"
            }
        ]
    },
    "meta": {
        "pagination": {
            "total_results": 15,
            "links": {
                "prev": null,
                "next": "https://localhost:8080/api/reports/media_viewed?page_size_primary=2&page_size_related=10000&page=2",
                "first": "https://localhost:8080/api/reports/media_viewed?page_size_primary=2&page_size_related=10000&page=1",
                "last": "https://localhost:8080/api/reports/media_viewed?page_size_primary=2&page_size_related=10000&page=8"
            }
        }
    },
    "report_entities": [
        {
            "id": "606251729419245461",
            "href": "",
            "links": {
                "viewed_by": {
                    "type": "users",
                    "username": "alfonso-deleted-3709407027810853541557483946"
                },
                "media": "384571249688319617"
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "last_viewed_at": "2015-10-12T18:00:00.000Z",
            "hits": 1,
            "time_viewed_msec": null,
            "visits": 0
        },
        {
            "id": "606251729477965802",
            "href": "",
            "links": {
                "viewed_by": {
                    "type": "users",
                    "username": "admin"
                },
                "media": "328537880626468139"
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "last_viewed_at": "2015-07-22T18:00:00.000Z",
            "hits": 1,
            "time_viewed_msec": null,
            "visits": 0
        }
    ]
}
Container non unique viewed time aggregated by user and session
GET /api/reports/container_viewed_aggregated_by_session

Method returns non unique viewed time for all container which current user (caller of method) has view access to (caller must have permission assigning role VIEWER on the parent containers of items to be returned). As media could be viewed by anybody, container viewed time report is split by users and sessions i.e. every value viewed_time_msec in the row of report means how much time was spent by user to view particular container in particular session.

Report returns data in JSON API format.

Requires VIEW_IDENTITIES to view reports on other users, otherwise method will return response code 403.

Request parameters

page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10
include
string optional

Comma separated list of related entities names. Existence of each mentioned entity means that there will be entity parameters at the output. For example if there is no sessions word in the include value there will be no any session related parameters at the output. The same situations with other parameters.

Default:
users,media,sessions
last_viewed_at_from
string date optional

If it is required to filter by last_viewed_at. Specifies beginning of exclusive time interval using ISO8601 standard. If not set, it means from the beginning of time.

Example:
2012-10-10T14:12:24.324Z
last_viewed_at_to
string optional

If it is required to filter by last_viewed_at. Specifies end of exclusive time interval using ISO8601 standard. If not set, it means from the beginning of time. End of time if omitted.

Example:
2012-10-10T14:12:24.324Z
username
string optional

If it is required to filter by username with exact matching. If not specified, data for all users are returned, which requires VIEW_IDENTITIES capability. Any username other than API caller’s one also requires VIEW_IDENTITIES. Otherwise 403 will be returned.

user_authentication_type

If it is required to filter by users authentication type with exact matching. any if omitted.

Responses

200 OK
403 Insufficient identity viewing privileges
400 Invalid parameters

If some of parameters was invalid

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/api/reports/container_viewed_aggregated_by_session?username=admin&last_viewed_at_from=2015-07-23T04:00:00.000Z&last_viewed_at_to=2015-07-23T05:00:00.000Z HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "linked": {
    "sessions": [
      {
        "id": "438124115107255742",
        "href": "",
        "links": {},
        "meta": {
          "pagination": {},
          "actions": []
        },
        "started_at": "2015-07-23T07:35:27.965Z",
        "ended_at": "2015-08-03T11:26:35.319Z",
        "http_user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.89 Safari/537.36",
        "ip": "93.92.220.166"
      }
    ],
    "containers": [
      {
        "id": "325641022015018973",
        "href": "https://localhost:8080/api/containers/325641022015018973?page_size_related=10000",
        "links": {
          "favorites": {},
          "parent": {},
          "authored_by": {},
          "modified_by": {},
          "owned_by": {
            "type": "users",
            "username": "admin"
          },
          "containers": [],
          "media": [],
          "created_by": {}
        },
        "meta": {
          "pagination": {},
          "full_references": {},
          "view_only_references": {},
          "state": {
            "pipeline_status": "EDITING",
            "published": true,
            "pipeline_resource": {
              "href": "https://localhost:8080/api/containers/325641022015018973?page_size_related=10000",
              "type": "containers"
            }
          },
          "collective": {},
          "actions": [
            {
              "label": "CONTAINER_GET",
              "href": "https://localhost:8080/api/containers/325641022015018973?page_size_related=10000",
              "method": "GET"
            },
            {
              "label": "CONTAINER_UPDATE",
              "href": "https://localhost:8080/api/containers/325641022015018973",
              "method": "PUT"
            },
            {
              "label": "CONTAINER_REORDER",
              "href": "https://localhost:8080/api/containers/325641022015018973/meta/order",
              "method": "POST"
            },
            {
              "label": "CONTAINER_CREATE",
              "href": "https://localhost:8080/api/containers/325641022015018973/container",
              "method": "POST"
            },
            {
              "label": "CONTAINER_EDIT_METADATA",
              "href": "https://localhost:8080/api/containers/325641022015018973",
              "method": "PATCH"
            },
            {
              "label": "MEDIA_CREATE",
              "href": "https://localhost:8080/api/containers/325641022015018973/medium",
              "method": "POST"
            },
            {
              "label": "CONTAINER_DELETE",
              "href": "https://localhost:8080/api/containers/325641022015018973",
              "method": "DELETE"
            },
            {
              "label": "MEDIA_CREATE_VIA_UPLOADER",
              "href": "https://localhost:8080/#/containers/325641022015018973/upload",
              "method": "GET"
            },
            {
              "label": "MEDIA_CREATE_VIA_PRESENTER",
              "href": "https://localhost:8080/#/containers/325641022015018973/presenter",
              "method": "GET"
            },
            {
              "label": "CONTAINER_UPDATE_AUTHORED_BY",
              "href": "https://localhost:8080/api/containers/325641022015018973",
              "method": "PUT"
            },
            {
              "label": "MEDIA_CREATE_VIA_COPY",
              "href": "https://localhost:8080/api/containers/325641022015018973/copy_medium",
              "method": "POST"
            },
            {
              "label": "COMPLETION_SUBSCRIPTION_POST",
              "href": "https://localhost:8080/api/feature_interactions/SCORM/completion_subscriptions",
              "method": "POST"
            },
            {
              "label": "CONTAINER_PLAY",
              "href": "https://localhost:8080/#/player/container/325641022015018973",
              "method": "GET"
            },
            {
              "label": "CONTAINER_COMMENT_SUBSCRIPTION_CREATE",
              "href": "https://localhost:8080/api/containers/325641022015018973/comment_subscription",
              "method": "POST"
            }
          ],
          "order": {
            "containers": {},
            "media": {}
          }
        },
        "root": false,
        "title": "SomeTitle",
        "description": "SomeTitle",
        "created_at": "2015-03-26T07:10:18.637Z",
        "modified_at": "2015-03-26T07:10:18.637Z",
        "screenshot_href": "https://example.com/example.jpg",
        "thumbnails": [
          {
            "x": null,
            "y": null,
            "href": {
              "DEFAULT": "https://example.com/example.jpg",
              "LARGE": "https://example.com/example.jpg",
              "LARGE_PLAYICON":"https://example.com/example.jpg"
            }
          }
        ],
        "comment_subscription": false
      },
      {
        "id": "316971525670441987",
        "href": "https://localhost:8080/api/containers/316971525670441987?page_size_related=10000",
        "links": {
          "favorites": {},
          "parent": {},
          "authored_by": {},
          "modified_by": {},
          "owned_by": {
            "type": "users",
            "username": "system"
          },
          "containers": [],
          "media": [],
          "created_by": {}
        },
        "meta": {
          "pagination": {},
          "full_references": {},
          "view_only_references": {},
          "state": {
            "pipeline_status": "EDITING",
            "published": true,
            "pipeline_resource": {
              "href": "https://localhost:8080/api/containers/316971525670441987?page_size_related=10000",
              "type": "containers"
            }
          },
          "collective": {},
          "actions": [
            {
              "label": "CONTAINER_GET",
              "href": "https://localhost:8080/api/containers/316971525670441987?page_size_related=10000",
              "method": "GET"
            },
            {
              "label": "CONTAINER_UPDATE",
              "href": "https://localhost:8080/api/containers/316971525670441987",
              "method": "PUT"
            },
            {
              "label": "CONTAINER_REORDER",
              "href": "https://localhost:8080/api/containers/316971525670441987/meta/order",
              "method": "POST"
            },
            {
              "label": "CONTAINER_CREATE",
              "href": "https://localhost:8080/api/containers/316971525670441987/container",
              "method": "POST"
            },
            {
              "label": "CONTAINER_EDIT_METADATA",
              "href": "https://localhost:8080/api/containers/316971525670441987",
              "method": "PATCH"
            },
            {
              "label": "COMPLETION_SUBSCRIPTION_POST",
              "href": "https://localhost:8080/api/feature_interactions/SCORM/completion_subscriptions",
              "method": "POST"
            },
            {
              "label": "CONTAINER_PLAY",
              "href": "https://localhost:8080/#/player/container/316971525670441987",
              "method": "GET"
            },
            {
              "label": "CONTAINER_COMMENT_SUBSCRIPTION_CREATE",
              "href": "https://localhost:8080/api/containers/316971525670441987/comment_subscription",
              "method": "POST"
            }
          ],
          "order": {
            "containers": {},
            "media": {}
          }
        },
        "root": true,
        "title": "Root Container",
        "description": "This is the very top of the container hierarchy",
        "created_at": "2015-03-14T08:05:50.374Z",
        "modified_at": "2015-03-14T08:05:50.374Z",
        "screenshot_href": "https://example.com/example.jpg",
        "thumbnails": [
          {
            "x": null,
            "y": null,
            "href": {
              "DEFAULT": "https://example.com/example.jpg",
              "LARGE": "https://example.com/example.jpg",
              "LARGE_PLAYICON": "https://example.com/example.jpg"
            }
          }
        ],
        "comment_subscription": false
      }
    ],
    "users": [
      {
        "id": "316971525670441986",
        "href": "https://localhost:8080/api/users/admin?page_size_related=10000",
        "links": {
          "modified_by": {},
          "groups": [],
          "created_by": {},
          "avatars": ""
        },
        "meta": {
          "pagination": {},
          "state": {},
          "actions": [
            {
              "label": "USER_GET",
              "href": "https://localhost:8080/api/users/admin?page_size_related=10000",
              "method": "GET"
            },
            {
              "label": "USER_GET_ALL",
              "href": "https://localhost:8080/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
              "method": "GET"
            },
            {
              "label": "USER_DELETE",
              "href": "https://localhost:8080/api/users/admin",
              "method": "DELETE"
            },
            {
              "label": "USER_EDIT_METADATA",
              "href": "https://localhost:8080/api/users/admin",
              "method": "PATCH"
            },
            {
              "label": "USER_UPDATE",
              "href": "https://localhost:8080/api/users/admin",
              "method": "PUT"
            },
            {
              "label": "USER_CREATE",
              "href": "https://localhost:8080/api/users",
              "method": "POST"
            }
          ]
        },
        "created_at": "2015-03-14T08:05:50.374Z",
        "modified_at": "2015-03-14T08:05:50.374Z",
        "first_name": "admin",
        "last_name": "admin",
        "username": "admin",
        "email": "admin@example.com",
        "authentication_type": "PASSWORD",
        "avatar_href": "https://example.com/example.jpg",
        "custom_authn_option_id": null
      },
      {
        "id": "316971525662053377",
        "href": "https://localhost:8080/api/users/system?page_size_related=10000",
        "links": {
          "modified_by": {},
          "groups": [],
          "created_by": {},
          "avatars": ""
        },
        "meta": {
          "pagination": {},
          "state": {},
          "actions": [
            {
              "label": "USER_GET",
              "href": "https://localhost:8080/api/users/system?page_size_related=10000",
              "method": "GET"
            },
            {
              "label": "USER_GET_ALL",
              "href": "https://localhost:8080/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
              "method": "GET"
            }
          ]
        },
        "created_at": "2015-03-14T08:05:50.374Z",
        "modified_at": "2015-03-14T08:05:50.374Z",
        "first_name": "system",
        "last_name": "system",
        "username": "system",
        "email": "system@example.com",
        "authentication_type": "NONE",
        "avatar_href": "",
        "custom_authn_option_id": null
      }
    ]
  },
  "meta": {
    "pagination": {
      "total_results": 2,
      "links": {
        "prev": null,
        "next": null,
        "first": "https://localhost:8080/api/reports/container_viewed_aggregated_by_session?page_size_primary=10000&page_size_related=10000&page=1&username=admin",
        "last": "https://localhost:8080/api/reports/container_viewed_aggregated_by_session?page_size_primary=10000&page_size_related=10000&page=1&username=admin"
      }
    }
  },
  "report_entities": [
    {
      "id": "316971525670441987_630001673393149243",
      "href": "",
      "links": {
        "sessions": "438124115107255742",
        "viewed_by": {
          "type": "users",
          "username": "admin"
        },
        "containers": "316971525670441987"
      },
      "meta": {
        "pagination": {},
        "actions": []
      },
      "last_viewed_at": "2015-07-23T04:00:00.000Z",
      "hits": 1,
      "time_viewed_msec": 100,
      "visits": 1
    },
    {
      "id": "325641022015018973_630001673393149243",
      "href": "",
      "links": {
        "sessions": "438124115107255742",
        "viewed_by": {
          "type": "users",
          "username": "admin"
        },
        "containers": "325641022015018973"
      },
      "meta": {
        "pagination": {},
        "actions": []
      },
      "last_viewed_at": "2015-07-23T04:00:00.000Z",
      "hits": 1,
      "time_viewed_msec": 100,
      "visits": 1
    }
  ]
}
Email activity
GET /api/reports/email_activity

Method returns activity related to email messages sent by users to share the containers or media. Such activity includes:

  • visits of shared resource - how many times recipient visited shared resource
  • number of openings of sent email - how many times recipient watched the email
  • number of clicks on sent email - how many times recipient clicked on container or medium shared via received email
  • unique viewed time percentage of shared resource for recipient

If caller passes identifier of container or medium under interest it’s required to have VIEW_CONTENT capability for them. In this case report will contain only messages related to that media or all media and containers under passed container. When caller does not have MANAGE_CONTENT on that medium/container, report will contain only activity for emails created by him. If both ids specified - method will answer with 400th response code. If both ids ommitted - report will contain messages related to all resources which caller has VIEW_CONTENT capability for.

Along with pagination information meta section contains collective holding information on total summaries of email clicks total_clicked, opens total_opened, partial views total_partial_views, complete views total_complete_views and total number os sent emails total_sent.

Request parameters

page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20
page_size_related
number optional

The limit for paginated relationships (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
10
recipient_email
string optional

Comma separated list of recipient email addresses.

Example:
user1@example.com, user2@gagmail.com
sent_at_from
string date optional

Specifies beginning of inclusive time interval using ISO8601 standard. Beginning of time if omitted.

Example:
2012-10-10T14:12:24.324Z
sent_at_to
string optional

Specifies end of inclusive time interval using ISO8601 standard. End of time if omitted.

Example:
2012-10-10T14:12:24.324Z
events
string optional

Comma separated list of events.

Example:
OPENED, EMAIL_CLICKED, VISITED, VIEWED_PARTIAL, VIEWED_COMPLETE.
medium_id
integer optional

id of medium under interest.

container_id
integer optional

id of container under interest.

sent_by
string optional

username of sender (case insensetive)

Responses

200 OK
403 Insufficient identity viewing privileges

If caller doesn’t have required capabilities.

400 Invalid parameters

If medium and container ids are passed at the same time

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/reports/email_activity?medium_id=817813306709383026&events=opened%2C+clicked%2C+viewed HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/vnd.api+json;charset=UTF-8

{
  "linked": {
    "containers": [
      {
        "id": "826709438160181195",
        "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195?page_size_related=10000",
        "root": false,
        "title": "Hello",
        "description": "Shift-enter removes the text. I had a whole thing here. :{    I can't press enter for a new line. Should we make this more editable? Make it cleaner? Hmmmm",
        "links": {
          "favorites": {
          },
          "parent": {
          },
          "authored_by": {
          },
          "modified_by": {
          },
          "deleted_by": {
          },
          "playlist_entries": [
          ],
          "owned_by": {
            "type": "users",
            "username": "bwolcott"
          },
          "containers": [
          ],
          "media": [
          ],
          "created_by": {
          }
        },
        "meta": {
          "notification_subscription": {
            "direct": null,
            "inherited": false
          },
          "pagination": {
          },
          "state": {
            "pipeline_status": "EDITING",
            "published": true,
            "pipeline_resource": {
              "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195?page_size_related=10000",
              "type": "containers"
            }
          },
          "collective": {
          },
          "actions": [
            {
              "label": "CONTAINER_GET",
              "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195?page_size_related=10000",
              "method": "GET"
            },
            {
              "label": "CONTAINER_UPDATE",
              "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195",
              "method": "PUT"
            },
            {
              "label": "CONTAINER_REORDER",
              "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195/meta/order",
              "method": "POST"
            },
            {
              "label": "CONTAINER_CREATE",
              "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195/container",
              "method": "POST"
            },
            {
              "label": "CONTAINER_EDIT_METADATA",
              "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195",
              "method": "PATCH"
            },
            {
              "label": "MEDIA_CREATE",
              "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195/medium",
              "method": "POST"
            },
            {
              "label": "CONTAINER_DELETE",
              "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195",
              "method": "DELETE"
            },
            {
              "label": "MEDIA_CREATE_VIA_COPY",
              "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195/copy_medium?source_medium_id=0",
              "method": "POST"
            },
            {
              "label": "MEDIA_CREATE_VIA_UPLOADER",
              "href": "https://tenant.kzoplatform.com/#/containers/826709438160181195/upload",
              "method": "GET"
            },
            {
              "label": "CONTAINER_UPDATE_AUTHORED_BY",
              "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195",
              "method": "PUT"
            },
            {
              "label": "MEDIA_CREATE_VIA_PRESENTER",
              "href": "https://tenant.kzoplatform.com/#/containers/826709438160181195/presenter",
              "method": "GET"
            },
            {
              "label": "COMPLETION_SUBSCRIPTION_POST",
              "href": "https://tenant.kzoplatform.com/api/feature_interactions/SCORM/completion_subscriptions",
              "method": "POST"
            },
            {
              "label": "CONTAINER_PLAY",
              "href": "https://tenant.kzoplatform.com/#/player/container/826709438160181195",
              "method": "GET"
            },
            {
              "label": "NOTIFICATION_SUBSCRIPTION_CREATE",
              "href": "https://tenant.kzoplatform.com/api/containers/826709438160181195/subscription",
              "method": "POST"
            }
          ],
          "order": {
            "containers": {
            },
            "media": {
            }
          }
        },
        "created_at": "2017-02-14T15:24:04.790Z",
        "modified_at": "2017-05-25T20:13:08.378Z",
        "deleted_at": null,
        "screenshot_href": "https://d1nqj7fk8ojzpc.cloudfront.net/wkzo/SCREENSHOT/903427087929447882.png?Expires=1497709307&Signature=Sp33lDjn7CXBbt9mfKnuaD1mU83Mk9kY5mfe14zl241laWc6AZrot8-E-R2GV3RDVc6oiA~mdZBICAcZJuY~zRjuuS0dW3YVAcAlTcr~FFr0bYYc41wHF6YyoKNPVKRIPU1pw58-KdShZ2QGfAHkFYV-PN9gd1n3hmwiiO-JrefcU10udG80yO-Ep2W7ggE8Bdjl0ohRweqCzbva7bsuRHeiGURtCthP4HFt8OrAxfsJ-E25mwlOz-ir2BCQtLXPBs3-U6NZXRdzQB3yN7ABdgB~6yu93h3FKIzM45vYjlbZnrt5eoH5qj1cXvmIwODi~JDrRAMc0i7NusXXSFYN3w__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
        "thumbnails": [
          {
            "x": null,
            "y": null,
            "href": {
              "DEFAULT": "https://d1nqj7fk8ojzpc.cloudfront.net/wkzo/SCREENSHOT/903427087929447882.png?Expires=1497709307&Signature=Sp33lDjn7CXBbt9mfKnuaD1mU83Mk9kY5mfe14zl241laWc6AZrot8-E-R2GV3RDVc6oiA~mdZBICAcZJuY~zRjuuS0dW3YVAcAlTcr~FFr0bYYc41wHF6YyoKNPVKRIPU1pw58-KdShZ2QGfAHkFYV-PN9gd1n3hmwiiO-JrefcU10udG80yO-Ep2W7ggE8Bdjl0ohRweqCzbva7bsuRHeiGURtCthP4HFt8OrAxfsJ-E25mwlOz-ir2BCQtLXPBs3-U6NZXRdzQB3yN7ABdgB~6yu93h3FKIzM45vYjlbZnrt5eoH5qj1cXvmIwODi~JDrRAMc0i7NusXXSFYN3w__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
              "LARGE": "https://d1nqj7fk8ojzpc.cloudfront.net/wkzo/SCREENSHOT/903427093935691212.png?Expires=1497709307&Signature=OHbz8wPRDsw2a5Rv9-IgQfYkiYqd2KJ5L5y4vX2fFMUNVQExR2UgVUl3slaWg51MGegNvB0ZEVt1tL3Yk9N7qRQxP752KoQnaPujuqFCZ~lJEPqo6U4d9ENlEFDw-52qDLyYcCpajyLcyI0r-uixGHPIdTVmtnqSmkmahszUZIwWlSYL9ZV8RDtvxEakrJVywN~IhXG5vAygchdboD46dWGrLuofPcI-b71uSh4ZIYKCpMQ3fKtdaTGLDdaDIfyJpZVv31oljMIevJ0Hzxec~IHdewmS-CVphk5I4D23RiieBkv5nsHKockBCeZ7epoYU2e6~4pN2ILcrSbiB7ZDqg__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
              "LARGE_PLAYICON": "https://d1nqj7fk8ojzpc.cloudfront.net/wkzo/SCREENSHOT/903427094975878605.jpg?Expires=1497709307&Signature=WDfWeQopKEhK5iv0w5Jzin0He~ccUBEM4eQlG17PwDCHnJGEr6jYXTRMJGsvxhOhZi9frZ1eYdotgYNjrgVv0zZ3nkJuqFFs3N2PJQ~CcO-pSgWlH9O-Bgkx0N4GEh~kDF3bwJYAROs~81Zh62u63rjzyONAEAAu268Y5QHiScZXcnUxe16ECRiffmniBZSrIKUktXRxj0FL~NM1r8NHr0u1kIiYldUps78eJoqC~aEDB1SgsUmPDphvFk5MXSW-29K-AYkJk7-xmZVkuZO6hxznvquSXj0CtJVgP8GXfH666iB~vDKn9GdYXhBlDQVecbrtlLqZqnf0~~LqeZdSYQ__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA"
            }
          }
        ],
        "subscription": false
      }
    ],
    "media": [
    ],
    "users": [
      {
        "id": "815955361696584818",
        "href": "https://tenant.kzoplatform.com/api/users/bwolcott?page_size_related=10000",
        "links": {
          "modified_by": {
          },
          "home_container": {
          },
          "deleted_by": {
          },
          "groups": [
          ],
          "created_by": {
          },
          "avatars": ""
        },
        "meta": {
          "pagination": {
          },
          "state": {
          },
          "actions": [
            {
              "label": "USER_GET",
              "href": "https://tenant.kzoplatform.com/api/users/bwolcott?page_size_related=10000",
              "method": "GET"
            },
            {
              "label": "USER_GET_ALL",
              "href": "https://tenant.kzoplatform.com/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
              "method": "GET"
            },
            {
              "label": "USER_UPDATE",
              "href": "https://tenant.kzoplatform.com/api/users/bwolcott",
              "method": "PUT"
            },
            {
              "label": "USER_EDIT_METADATA",
              "href": "https://tenant.kzoplatform.com/api/users/bwolcott",
              "method": "PATCH"
            },
            {
              "label": "USER_CREATE",
              "href": "https://tenant.kzoplatform.com/api/users",
              "method": "POST"
            },
            {
              "label": "USER_DELETE",
              "href": "https://tenant.kzoplatform.com/api/users/bwolcott",
              "method": "DELETE"
            }
          ]
        },
        "created_at": "2017-01-30T19:17:38.863Z",
        "modified_at": "2017-06-06T16:35:35.898Z",
        "deleted_at": null,
        "first_name": "Brenton",
        "last_name": "Wolcott",
        "username": "bwolcott",
        "email": "user@example.com",
        "authentication_type": "PASSWORD",
        "avatar_href": "https://d1nqj7fk8ojzpc.cloudfront.net/wkzo/AVATAR/815955362610943098.png?Expires=1499983198&Signature=eqfJqaAp93IqlKXk8lA2I2CP3csPbWAZfg~WNM1S3cg0LCdlQHb-OJDngfmYkldZ1qWH6UKhgHr4EmYrrESJ4d8TlVv-Kzuzs8LoV8DLDW6bw~hKfoViLU9wcZusPpJPMEfMQPqq~99KLlX~ZB-XVyV~o76wfovHHaLW2o8eX8aX36eDIjGQ0~mUWnPaESH0p9dINDYg0CAMVWTVlH~qX4-3aCq-eehEPIOMgBSM2Q76agsrN7nZO90kwCi9D60xAhf9oukRDVE-AbHHQCxKjKp71F1TpfLnk0GXlXLdfcDC7orKAgMSxvVBrYBZiIZJgu9GkzjDx9Wsrj5xltp9HQ__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
        "custom_authn_option_id": null
      }
    ]
  },
  "meta": {
    "collective": {
            "total_clicked": 0,
            "total_opened":  1,
            "total_sent":    1,
            "total_partial_views":  0,
            "total_complete_views":  0
    },
    "pagination": {
      "total_results": 15,
      "links": {
        "next": "https://tenant.kzoplatform.com/api/reports/email_activity?page_size_primary=1&page_size_related=10000&page=2&events=com.kzoinnovations.service.restapi.utils.wrappers.ReportWrapper$8$$Lambda$668/1584423606@7ddc15cd",
        "2next": "https://tenant.kzoplatform.com/api/reports/email_activity?page_size_primary=1&page_size_related=10000&page=3&events=com.kzoinnovations.service.restapi.utils.wrappers.ReportWrapper$8$$Lambda$668/1584423606@5f9cfe32",
        "last": "https://tenant.kzoplatform.com/api/reports/email_activity?page_size_primary=1&page_size_related=10000&page=15&events=com.kzoinnovations.service.restapi.utils.wrappers.ReportWrapper$8$$Lambda$668/1584423606@582a1c2",
        "3next": "https://tenant.kzoplatform.com/api/reports/email_activity?page_size_primary=1&page_size_related=10000&page=4&events=com.kzoinnovations.service.restapi.utils.wrappers.ReportWrapper$8$$Lambda$668/1584423606@65454c0e",
        "first": "https://tenant.kzoplatform.com/api/reports/email_activity?page_size_primary=1&page_size_related=10000&page=1&events=com.kzoinnovations.service.restapi.utils.wrappers.ReportWrapper$8$$Lambda$668/1584423606@78aa4f16"
      }
    }
  },
  "email_activity": [
    {
      "email_message_id": "887731486940206196",
      "links": {
        "container": "826709438160181195",
        "sent_by": {
          "type": "users",
          "username": "bwolcott"
        },
        "medium": "null"
      },
      "meta": {
        "pagination": {
        },
        "actions": [
        ]
      },
      "recipient_emails": {
        "TO": [
          "user@example.com"
        ],
        "CC": [
          "user@example.com"
        ],
        "BCC": [
          "user@example.com"
        ]
      },
      "visits": 0,
      "email_opens": 1,
      "email_clicks": 0,
      "last_viewed_at": null,
      "email_last_opened_at": "2017-05-09T21:43:02Z",
      "email_sent_at": "2017-05-09T20:03:59Z",
      "email_last_clicked_at": null,
      "viewed": {
        "percentage": 0,
        "complete": false,
        "partial": false
      }
    }
  ]
}
Email activity (CSV)
GET /misc/csv/email_activity

Method returns activity related to email messages sent by users to share the containers or media. Such activity includes:

  • visits of shared resource - how many times recipient visited shared resource
  • number of openings of sent email - how many times recipient watched the email
  • number of clicks on sent email - how many times recipient clicked on container or medium shared via received email
  • unique viewed time percentage of shared resource for recipient

If caller passes identifier of container or medium under interest it’s required to have VIEW_CONTENT capability for them. In this case report will contain only messages related to that media or all media and containers under passed container. When caller does not have MANAGE_CONTENT on that medium/container, report will contain only activity for emails created by him. If both ids specified - method will answer with 400th response code. If both ids ommitted - report will contain messages related to all resources which caller has VIEW_CONTENT capability for.

Result returned as CSV file.

Request parameters

recipient_email
string optional

Comma separated list of recipient email addresses.

Example:
user1@example.com, user2@gagmail.com
sent_at_from
string date optional

Specifies beginning of inclusive time interval using ISO8601 standard. Beginning of time if omitted.

Example:
2012-10-10T14:12:24.324Z
sent_at_to
string optional

Specifies end of inclusive time interval using ISO8601 standard. End of time if omitted.

Example:
2012-10-10T14:12:24.324Z
events
string optional

Comma separated list of events.

Example:
OPENED, EMAIL_CLICKED, VISITED, VIEWED.
medium_id
integer optional

If of medium under interest.

container_id
integer optional

If of container under interest.

Responses

200 OK
403 Insufficient identity viewing privileges

If caller doesn’t have required capabilities.

400 Invalid parameters

If medium and container ids are passed at the same time

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/misc/csv/email_activity?medium_id=817813306709383026&events=opened%2C+clicked%2C+viewed HTTP/1.1 

HTTP/1.1 200 OK 


email_message_id,recipient_emails_to,recipient_emails_cc_bcc,email_sent_at,email_last_opened_at,email_last_clicked_at,last_viewed_at,email_opens,email_clicks,visits,viewed.complete,viewed.percentage,sent_by_username,medium_id,medium_title,container_id,container_title
904739748675852073,v.user@example.com,admin@kzotest.com,2017-06-02T07:16:22.665,2017-06-02T12:30:21.151,2017-06-02T07:17:32.147,2017-06-02T07:17:32.147,6,1,1,false,1,admin,720859024366507205,Forrest meets Lt  Dan  Forrest Gump  1994,,
904739914753513262,v.user@example.com,admin@kzotest.com,2017-06-02T07:16:42.464,2017-06-02T12:30:18.874,2017-06-02T07:17:47.888,2017-06-02T07:17:47.888,8,1,1,false,38,admin,642522472943457897,MVI 1233,,
904740047410960179,v.user@example.com,admin@kzotest.com,2017-06-02T07:16:58.279,2017-06-02T12:30:17.146,2017-06-02T10:21:18.148,2017-06-02T10:21:18.148,4,2,1,false,0,admin,817813306709383026,Truck Trial Compilation 2014 the long video Tatra 815 8x8 DAF 8X8 Mercedes Benz,,

Comments for medium
GET /misc/csv/comments_for_medium

Fetch all comments and replies according to the QSPs and return them in CSV format.

Caller is required to have VIEW_CONTENT capability for requested media.

Request parameters

reporting_interval_starts_at
string required

Specifies beginning of inclusive time interval using ISO8601 standard.

Example:
2012-10-10T14:12:24.324Z
reporting_interval_ends_at
string required

Specifies end of inclusive time interval using ISO8601 standard.

Example:
2012-10-11T14:12:24.324Z
medium_id
integer required

Medium identifier

Responses

200 OK
403 Forbidden

If caller doesn’t have required capabilities.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/misc/csv/comments_for_medium?reporting_interval_starts_at=2017-06-21T14:00:00.000Z&reporting_interval_ends_at=2017-06-22T14:00:00.000Z&medium_id=919423599561938112 HTTP/1.1 


reportType,reportingPeriodStartsAt,reportingPeriodEndsAt,mediumId,mediumTitle,commentTimeMsec,createdAt,commentId,replyId,parentCommentId,parentReplyId,authorUsername,authorFirstName,authorLastName,authorEmail,commentReplyText
comments_for_medium,2017-06-21T14:00:00.000,2017-06-22T14:00:00.000,919423599561938112,CommentSpecMedium,700,2017-06-22T16:01:10.000,,,,admin,admin,admin,admin@kzotest.com,some comment
comments_for_medium,2017-06-21T14:00:00.000,2017-06-22T14:00:00.000,919423599561938112,CommentSpecMedium,700,2017-06-22T16:01:00.000,,919423603806573773,919423602388899016,,admin,admin,admin,admin@kzotest.com,some reply
comments_for_medium,2017-06-21T14:00:00.000,2017-06-22T14:00:00.000,919423599561938112,CommentSpecMedium,700,2017-06-22T17:11:00.000,,919423605157139666,,919423603806573773,admin,admin,admin,admin@kzotest.com,"reply, ""for"" reply"
Comments for medium (scheduled)
GET /misc/csv/scheduled_reports/{id}/comments_for_medium

Method returns result of scheduled report on comments for medium.

All comments and replies that match supplied scheduled report’s date interval and medium id are returned in CSV format.

Caller is required to have VIEW_CONTENT capability for media referenced by scheduled report.

Path variables

id
integer required

scheduled report identifier

Examples

GET https://tenant.kzoplatform.com/api/misc/csv/scheduled_reports/123/comments_for_medium HTTP/1.1 

reportType,reportingPeriodStartsAt,reportingPeriodEndsAt,mediumId,mediumTitle,commentTimeMsec,createdAt,commentId,replyId,parentCommentId,parentReplyId,authorUsername,authorFirstName,authorLastName,authorEmail,commentReplyText
comments_for_medium,2017-06-21T14:00:00.000,2017-06-22T14:00:00.000,919423599561938112,CommentSpecMedium,700,2017-06-22T16:01:10.000,,,,admin,admin,admin,admin@kzotest.com,some comment
comments_for_medium,2017-06-21T14:00:00.000,2017-06-22T14:00:00.000,919423599561938112,CommentSpecMedium,700,2017-06-22T16:01:00.000,,919423603806573773,919423602388899016,,admin,admin,admin,admin@kzotest.com,some reply
comments_for_medium,2017-06-21T14:00:00.000,2017-06-22T14:00:00.000,919423599561938112,CommentSpecMedium,700,2017-06-22T17:11:00.000,,919423605157139666,,919423603806573773,admin,admin,admin,admin@kzotest.com,"reply, ""for"" reply"
Media viewed under container (csv)
GET /misc/csv/scheduled_reports/{id}/media_viewed_under_container

Method returns result of scheduled report on media viewed under container in CSV format.

Information on views of all media under container referenced by report schedule is aggregated by media.

Caller is required to have VIEW_CONTENT capability on container referenced by scheduled report.

Path variables

id
integer required

scheduled report identifier

Examples

GET https://tenant.kzoplatform.com/api/misc/csv/scheduled_reports/123/media_viewed_under_container HTTP/1.1 


reportType,reportingPeriodStartsAt,reportingPeriodEndsAt,containerId,mediumId,mediumTitle,hits,visits,uniqueViewedTimeMsec
MEDIA_VIEWED_UNDER_CONTAINER,2017-06-23T00:00:00Z,2017-06-25T00:00:00Z,919932854186547006,919932855981709124,some media title,1,1,5000
MEDIA_VIEWED_UNDER_CONTAINER,2017-06-23T00:00:00Z,2017-06-25T00:00:00Z,919932854186547006,919932861987952474,some media title1,2,1,15001
Media viewed under container (json)
GET /api/scheduled_reports/{id}/media_viewed_under_container

Method returns result of scheduled report on media viewed under container.

Information on views of all media under container referenced by report schedule is aggregated by media.

Caller is required to have VIEW_CONTENT capability on container referenced by scheduled report.

Path variables

id
integer required

scheduled report identifier

Examples

GET https://tenant.kzoplatform.com/api/api/scheduled_reports/123/media_viewed_under_container HTTP/1.1 

{
    "media_viewed_under_container": [
        {
            "hits": 3,
            "id": "1",
            "last_viewed_at": "2017-06-22T17:00:00Z",
            "links": {
            "medium": "648476143086736654"
        },
            "unique_viewed_time_msec": 5000,
            "visits": 3
        },
        {
            "hits": 3,
            "id": "2",
            "last_viewed_at": "2017-06-22T17:00:00Z",
            "links": {
            "medium": "660000358239573278"
        },
            "unique_viewed_time_msec": 5000,
            "visits": 3
        }
    ],
    "meta": {
        "pagination": {
            "links": {
                "first": "https://tenant.kzoplatform.com/api/scheduled_reports/920010159076414951/media_viewed_under_container?page_size_primary=100&include=medium,medium.parent,medium.screenshot&page_size_related=10000&page=1&sort=unique_viewed_time_msec",
                "last": "https://tenant.kzoplatform.com/api/scheduled_reports/920010159076414951/media_viewed_under_container?page_size_primary=100&include=medium,medium.parent,medium.screenshot&page_size_related=10000&page=1&sort=unique_viewed_time_msec"
            },
            "total_results": 2
        }
    },
    "linked": {
        "containers": [
                {
                    "id": "648476020998935811",
                    ...
                }
        ],
        "medium": [
                {
                    "id": "660000358239573278",
                    "links": {
                    "parent": {
                        "id": "648476020998935811",
                        "type": "containers"
                    },
                    "screenshots": [
                            "660000744635634993"
                    ],
                    ...
                },
                    "title": "KZO Video Demo",
                    "trt_msec": 1067000
                },
                {
                    "id": "648476143086736654",
                    "title": "Let's Talk About How You Use Video Today",
                    "trt_msec": 50000
                }
        ],
        "screenshots": [
                {

                }
        ],
        "users": [
                {
                    "username": "someusername",
                    ...
                },
                ...
        ]
    }
}
Subscriptions

Various subsriptions of users for updates of content. Currently the following subsriptions are supported:

  • comments and replies - when some person leaves a comment o reply, subscribers of current medium or container will obtain email about that.
  • visits of media - when some user watch media under subscription at first time, subscribers will obtain email about that.
GET /subscriptions/{id}
GET /subscriptions
DELETE /subscriptions/{id}
PUT /subscriptions/{id}
View subscriptions
GET /subscriptions/{id}

Fetches subscriptions with the given ID. Requires Permission assigning role VIEWER on the parent container.

Path variables

id
integer required

ID of recipient instance

Example:
1

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.
Default value: empty.
What can be included at most: containers,media,media.authored_by,subscriber.

Responses

200 OK
403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

404 Not Found

The server has not found anything matching the Request-URI.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/comment_subscriptions/1 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "comment_subscriptions":{
        "id": "1",
        "href": "https://tenant.kzoplatform.com/api/comment_subscriptions/1",
        "modified_by":{},
        "created_by":{},
        "type": "UNSUBSCRIPTION",
        "created_at": "2015-08-18T14:08:20.139Z",
        "modified_at": "2015-08-18T14:08:20.139Z",
        "links": {}
    },
    "linked":{},
    "meta":{}
}
Search for subscriptions
GET /subscriptions

Searches for subscriptions satisfying specific criteria. Does not require any permission.

Request parameters

subscriber
string optional

Filtering by subscriber username

Example:
username
medium_id
integer optional

Filtering by medium ID

Example:
2
container_id
integer optional

Filtering by container ID

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/comment_subscriptions HTTP/1.1 

HTTP/1.1 200 OK 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "subscriptions": [
        {
            "created_at": "2016-08-25T05:20:35.088Z",
            "href": "https://tenant.kzoplatform.com/api/comment_subscriptions/456",
            "id": "456",
            "links": {
                "medium": "789",
            },
            "modified_at": "2016-08-25T05:20:35.088Z",
            "type": "SUBSCRIPTION"
        }
    ],
    "linked": {
        "media": [
            {
                "id": "789",
                ...
            }
      ],
        "users": [
            ...
        ]
    },
    "meta": {
       "pagination": {
            "links": {
                "2next": "https://tenant.kzoplatform.com/api/subscriptions?page_size_primary=20&include=containers,media,media.authored_by&page_size_related=10000&page=3",
                "3next": "https://tenant.kzoplatform.com/api/subscriptions?page_size_primary=20&include=containers,media,media.authored_by&page_size_related=10000&page=4",
                "first": "https://tenant.kzoplatform.com/api/subscriptions?page_size_primary=20&include=containers,media,media.authored_by&page_size_related=10000&page=1",
                "last": "https://tenant.kzoplatform.com/api/subscriptions?page_size_primary=20&include=containers,media,media.authored_by&page_size_related=10000&page=5",
                "next": "https://tenant.kzoplatform.com/api/subscriptions?page_size_primary=20&include=containers,media,media.authored_by&page_size_related=10000&page=2"
            },
            "total_results": 100
    }
}
Subscribe user for notifications about comments, replies and visits of a medium
POST /media/{id}/subscription

Subscribes user for notifications about comments, replies and visits of a medium. Requires permission assigning role VIEWER on the parent container of the given medium if the user wants to subscribe his own individual group, CONTENT_UPDATER otherwise. In the latter case, the subscribed user must have Permission assigning role VIEWER on the parent container of the given Medium.

Path variables

id
integer required

ID of medium

Example:
1

Responses

201 Created
403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

404 Not Found

The server has not found anything matching the Request-URI.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/media/4/comment_subscription HTTP/1.1 

Content-Type: application/json

{
    "comment_subscriptions" : {
        "subscriber" : "username",
        "type": "SUBSCRIPTION"
    }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "comment_subscriptions":{
        "id": "4",
        "href": "https://tenant.kzoplatform.com/api/comment_subscriptions/1",
        "modified_by":{},
        "created_by":{},
        "type": "SUBSCRIPTION",
        "created_at": "2015-08-18T14:08:20.139Z",
        "modified_at": "2015-08-18T14:08:20.139Z",
        "links": {}
    },
    "linked":{},
    "meta":{}
}
Subscribe user for notifications about container's media comments
POST /containers/{id}/subscription

Subscribes a user for notifications about comments and replies related to media located inside of the container. Requires Permission assigning Role VIEWER on the given container if the user wants to subscribe their own, CONTENT_UPDATER otherwise. In the latter case, the subscribed user must have Permission assigning Role VIEWER on the given Container.

Path variables

id
integer required

ID of container

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/containers/6/comment_subscription HTTP/1.1 

Content-Type: application/json

{
    "comment_subscriptions" : {
        "subscriber" : "username",
        "type": "UNSUBSCRIPTION"
    }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "comment_subscriptions":{
        "id": "6",
        "href": "https://tenant.kzoplatform.com/api/comment_subscriptions/1",
        "modified_by":{},
        "created_by":{},
        "type": "UNSUBSCRIPTION",
        "created_at": "2015-08-18T14:08:20.139Z",
        "modified_at": "2015-08-18T14:08:20.139Z",
        "links": {}
    },
    "linked":{},
    "meta":{}
}
Delete subscription
DELETE /subscriptions/{id}

Deletes subscription with specified identifier. Requires Permission assigning Role VIEWER on the parent container of the given medium/container if the user wants to unsubscribe themself, CONTENT_UPDATER otherwise.

Path variables

id
string required

ID of subscription

Example:
1

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/comment_subscriptions/1 HTTP/1.1 

HTTP/1.1 204 No Content 
Replace subscription
PUT /subscriptions/{id}

Method allows to change the type of subscription. The possible values for the type field are SUBSCRIPTION, UNSUBSCRIPTION.

Path variables

id
string required

The id of subscription to update

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/comment_subscriptions/1 HTTP/1.1 

Content-Type: application/json

{
    "comment_subscriptions": {
        "type": "UNSUBSCRIPTION"
    }
}

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "comment_subscriptions":{
        "id": "1",
        "href": "https://tenant.kzoplatform.com/api/comment_subscriptions/1",
        "modified_by":{},
        "created_by":{},
        "type": "UNSUBSCRIPTION",
        "created_at": "2015-08-18T14:08:20.139Z",
        "modified_at": "2015-08-18T14:08:20.139Z",
        "links": {}
    },
    "linked":{},
    "meta":{}
}
Client Init. Data

Initialization data for client

Viewing Client Initialization Data
POST /client_init

Returns initialization data for client:

  • available methods of authentication;
  • administrative roles (only for authenticated user);
  • assets;
  • tenant-level properties.

Does not require the User to be authenticated.

If an access key is not provided and client_init.invitee_email is not empty, creates (or synchronyzes) an invitee user and includes their access key in response. If client_init.invitee_email is not empty, client_init.invitee_first_name and/or client_init.invitee_last_name can be provided. Note that invitee user creation rate is limited by properties user_creation_rate.invitee.per_min and user_creation_rate.invitee.per_day. They can be overridden at tenant level.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/client_init HTTP/1.1 

Content-Type: application/json

{
  "client_init": {
    "browser_session_id": "aw4e5r"
  }
}

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "users": [
            {
                "id": "826388510444361575",
                "href": "https://localhost:8080/api/users/skozlov?page_size_related=10000",
                "links": {
                    "roles": [
                    ],
                    "modified_by": {
                    },
                    "home_container": {
                    },
                    "created_by": {
                    },
                    "avatars": ""
                },
                "meta": {
                    "pagination": {
                    },
                    "state": {
                    },
                    "actions": [
                        {
                            "label": "USER_GET",
                            "href": "https://localhost:8080/api/users/skozlov?page_size_related=10000",
                            "method": "GET"
                        },
                        {
                            "label": "USER_GET_ALL",
                            "href": "https://localhost:8080/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
                            "method": "GET"
                        },
                        {
                            "label": "USER_UPDATE",
                            "href": "https://localhost:8080/api/users/skozlov",
                            "method": "PUT"
                        },
                        {
                            "label": "USER_EDIT_METADATA",
                            "href": "https://localhost:8080/api/users/skozlov",
                            "method": "PATCH"
                        },
                        {
                            "label": "USER_CREATE",
                            "href": "https://localhost:8080/api/users",
                            "method": "POST"
                        }
                    ]
                },
                "created_at": "2017-02-14T04:46:27.138Z",
                "modified_at": "2017-02-27T05:03:10.464Z",
                "first_name": "Sergey",
                "last_name": "Kozlov",
                "username": "skozlov",
                "email": "mail@example.org",
                "authentication_type": "PASSWORD",
                "avatar_href": "...",
                "custom_authn_option_id": null
            }
        ]
    },
    "meta": {
    },
    "client_init": {
        "meta": {
            "public_access": true,
            "landing_url": null
        },
        "access_key": {
            "id": "835820968260671283",
            "href": "https://localhost:8080/api/access_keys/FqUz",
            "links": {
                "modified_by": {
                },
                "created_by": {
                },
                "users": "skozlov"
            },
            "meta": {
                "pagination": {
                },
                "state": {
                    "pipeline_status": "CREATED",
                    "published": true,
                    "pipeline_resource": {
                        "href": "https://localhost:8080/api/access_keys/FqUz",
                        "type": "access_keys"
                    }
                },
                "actions": [
                    {
                        "label": "ACCESS_KEY_GET",
                        "href": "https://localhost:8080/api/access_keys/FqUz",
                        "method": "GET"
                    },
                    {
                        "label": "ACCESS_KEY_DELETE",
                        "href": "https://localhost:8080/api/access_keys/FqUz",
                        "method": "DELETE"
                    }
                ]
            },
            "key": "FqUz",
            "created_at": "2017-02-27T05:07:03.814Z",
            "modified_at": "2017-02-27T05:07:03.814Z",
            "type": "SESSION",
            "expires_at": "2017-02-27T10:07:03.814Z",
            "http_user_agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.112 Safari/537.36",
            "ip": "127.0.0.1"
        },
        "roles": [
        ],
        "assets": [
            {
                "id": "583928516446262762",
                "href": "https://localhost:8080/api/assets/583928516446262762",
                "links": {
                    "modified_by": {
                    },
                    "created_by": {
                    }
                },
                "meta": {
                    "pagination": {
                    },
                    "actions": [
                        {
                            "label": "ASSET_GET",
                            "href": "https://localhost:8080/api/assets/583928516446262762",
                            "method": "GET"
                        },
                        {
                            "label": "ASSET_GET_ALL",
                            "href": "https://localhost:8080/api/assets",
                            "method": "GET"
                        },
                        {
                            "label": "ASSET_DOWNLOAD",
                            "href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/ASSET/583928516446262762?Expires=1488258432&Signature=QgmhFweAFAjpOoGnJzdZfOoj7WbwZ72hoWnB8fTfWzlQKQ1BAx2un3rHlXKJwtYW7OnzLRCwoAGppK3Mkm3kAvkSI3ciNLmfvurWYNa9qCcbsQhUasBXbsTxEcBt4QAuTga8Efsk-DJ-5jbgkH33Ur5aioofgTwPd84c6W9OpWnmHvkO2CdVmaDnmDtKuMrV3mV4FK2M2fvK-4~7EM4LQte3C4VbQibcQwd0yDCEY3e3oqzxD2u9FELdtFvQK5rZj7gvWeo4f4IU9O5BYTen49tFs36UzVZNDHTT04szUQW4NCvkp~L6MWCuxsrAPEvxaDgpblIhoozQzGvBVbDHHw__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
                            "method": "GET"
                        }
                    ]
                },
                "name": "css",
                "created_at": "2016-03-16T16:01:43.597Z",
                "modified_at": "2016-03-16T16:01:44.059Z",
                "is_init_data": true
            }
        ],
        "properties": [
            {
                "id": "1",
                "links": {
                },
                "meta": {
                    "pagination": {
                    },
                    "actions": [
                    ]
                },
                "name": "wowza.rtmp.port",
                "value": "80",
                "created_at": "2016-01-25T23:10:06.722Z",
                "modified_at": "2016-01-25T23:10:06.722Z",
                "definition_level": "TENANT",
                "mutable": true,
                "deletable": false,
                "is_init_data": true
            }
        ],
        "features": [
            {
                "id": "623728058846680909",
                "href": "https://localhost:8080/api/features/IPAAS",
                "links": {
                    "modified_by": {
                    }
                },
                "meta": {
                    "pagination": {
                    },
                    "actions": [
                        {
                            "label": "FEATURE_GET",
                            "href": "https://localhost:8080/api/features/IPAAS",
                            "method": "GET"
                        },
                        {
                            "label": "FEATURE_GET_ALL",
                            "href": "https://localhost:8080/api/features",
                            "method": "GET"
                        }
                    ]
                },
                "name": "IPAAS",
                "type": "AUTHENTICATION",
                "status": "DISABLED",
                "modified_at": "2016-08-09T14:27:03.374Z"
            }
        ],
        "languages": [
            {
                "id": "en",
                "name": "English"
            },
            {
                "id": "fr",
                "name": "French"
            }
        ],
        "custom_authn_options": [
        ],
        "home_container": {
            "id": "835819009537479831",
            "href": "https://localhost:8080/api/containers/835819009537479831?page_size_related=10000",
            "links": {
                "favorites": {
                },
                "parent": {
                },
                "authored_by": {
                },
                "modified_by": {
                },
                "owned_by": {
                    "type": "users",
                    "username": "system"
                },
                "containers": [
                ],
                "media": [
                ],
                "created_by": {
                }
            },
            "meta": {
                "notification_subscription": {
                    "direct": null,
                    "inherited": false
                },
                "pagination": {
                },
                "full_references": {
                },
                "view_only_references": {
                },
                "state": {
                    "pipeline_status": "EDITING",
                    "published": true,
                    "pipeline_resource": {
                        "href": "https://localhost:8080/api/containers/835819009537479831?page_size_related=10000",
                        "type": "containers"
                    }
                },
                "collective": {
                },
                "actions": [
                    {
                        "label": "CONTAINER_GET",
                        "href": "https://localhost:8080/api/containers/835819009537479831?page_size_related=10000",
                        "method": "GET"
                    },
                    {
                        "label": "CONTAINER_UPDATE",
                        "href": "https://localhost:8080/api/containers/835819009537479831",
                        "method": "PUT"
                    },
                    {
                        "label": "CONTAINER_REORDER",
                        "href": "https://localhost:8080/api/containers/835819009537479831/meta/order",
                        "method": "POST"
                    },
                    {
                        "label": "CONTAINER_CREATE",
                        "href": "https://localhost:8080/api/containers/835819009537479831/container",
                        "method": "POST"
                    },
                    {
                        "label": "CONTAINER_EDIT_METADATA",
                        "href": "https://localhost:8080/api/containers/835819009537479831",
                        "method": "PATCH"
                    },
                    {
                        "label": "MEDIA_CREATE",
                        "href": "https://localhost:8080/api/containers/835819009537479831/medium",
                        "method": "POST"
                    },
                    {
                        "label": "CONTAINER_DELETE",
                        "href": "https://localhost:8080/api/containers/835819009537479831",
                        "method": "DELETE"
                    },
                    {
                        "label": "MEDIA_CREATE_VIA_COPY",
                        "href": "https://localhost:8080/api/containers/835819009537479831/copy_medium",
                        "method": "POST"
                    },
                    {
                        "label": "MEDIA_CREATE_VIA_PRESENTER",
                        "href": "https://localhost:8080/#/containers/835819009537479831/presenter",
                        "method": "GET"
                    },
                    {
                        "label": "MEDIA_CREATE_VIA_UPLOADER",
                        "href": "https://localhost:8080/#/containers/835819009537479831/upload",
                        "method": "GET"
                    },
                    {
                        "label": "CONTAINER_UPDATE_AUTHORED_BY",
                        "href": "https://localhost:8080/api/containers/835819009537479831",
                        "method": "PUT"
                    },
                    {
                        "label": "COMPLETION_SUBSCRIPTION_POST",
                        "href": "https://localhost:8080/api/feature_interactions/SCORM/completion_subscriptions",
                        "method": "POST"
                    },
                    {
                        "label": "CONTAINER_PLAY",
                        "href": "https://localhost:8080/#/player/container/835819009537479831",
                        "method": "GET"
                    },
                    {
                        "label": "NOTIFICATION_SUBSCRIPTION_CREATE",
                        "href": "https://localhost:8080/api/containers/835819009537479831/comment_subscription",
                        "method": "POST"
                    }
                ],
                "order": {
                    "containers": {
                    },
                    "media": {
                    }
                }
            },
            "root": false,
            "title": "Sergey Kozlov",
            "description": "",
            "created_at": "2017-02-27T05:03:10.307Z",
            "modified_at": "2017-02-27T05:03:10.307Z",
            "screenshot_href": null,
            "thumbnails": [
            ],
            "comment_subscription": false
        }
    }
}
Screenshot positions
GET /screenshot_positions/{id}
POST /media/{id}/screenshot_position
PATCH /screenshot_positions/{id}
PUT /screenshot_positions/{id}
GET /screenshot_positions/{id}
Viewing Screenshot Position
GET /screenshot_positions/{id}

Fetch a screenshot position with a given ID.

Requires Permission assigning Role VIEWER on the parent container of the medium of the given screenshot position.

Path variables

id
number required

The id of screenshot position

Example:
1

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/screenshot_positions/457622761863386478 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "screenshot_positions": {
        "id": "457622761863386478",
        "href": "https://localhost:8080/api/screenshot_positions/457622761863386478",
        "links": {
            "modified_by": {
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "SCREENSHOT_POSITION_GET",
                    "href": "https://localhost:8080/api/screenshot_positions/457622761863386478",
                    "method": "GET"
                },
                {
                    "label": "SCREENSHOT_POSITION_DELETE",
                    "href": "https://localhost:8080/api/screenshot_positions/457622761863386478",
                    "method": "DELETE"
                },
                {
                    "label": "SCREENSHOT_POSITION_UPDATE",
                    "href": "https://localhost:8080/api/screenshot_positions/457622761863386478",
                    "method": "PATCH"
                },
                {
                    "label": "SCREENSHOT_POSITION_EDIT_METADATA",
                    "href": "https://localhost:8080/api/screenshot_positions/457622761863386478",
                    "method": "PUT"
                }
            ]
        },
        "x": 1,
        "y": 2,
        "created_at": "2015-09-24T09:34:44.319Z",
        "modified_at": "2015-09-24T09:34:44.319Z"
    }
}
Creating Screenshot Position
POST /media/{id}/screenshot_position

Add a screenshot position to medium with the given ID.

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the given Medium.

Path variables

id
number required

The id of medium

Example:
1

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/media/428121048295151317/screenshot_position HTTP/1.1 

Content-Type: application/json

{
    "screenshot_positions" : {
        "x" : 1,
      	"y": 2
    }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "screenshot_positions": {
        "id": "457622761863386478",
        "href": "https://localhost:8080/api/screenshot_positions/457622761863386478",
        "links": {
            "modified_by": {
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "SCREENSHOT_POSITION_GET",
                    "href": "https://localhost:8080/api/screenshot_positions/457622761863386478",
                    "method": "GET"
                },
                {
                    "label": "SCREENSHOT_POSITION_DELETE",
                    "href": "https://localhost:8080/api/screenshot_positions/457622761863386478",
                    "method": "DELETE"
                },
                {
                    "label": "SCREENSHOT_POSITION_UPDATE",
                    "href": "https://localhost:8080/api/screenshot_positions/457622761863386478",
                    "method": "PATCH"
                },
                {
                    "label": "SCREENSHOT_POSITION_EDIT_METADATA",
                    "href": "https://localhost:8080/api/screenshot_positions/457622761863386478",
                    "method": "PUT"
                }
            ]
        },
        "x": 1,
        "y": 2,
        "created_at": "2015-09-24T09:34:44.319Z",
        "modified_at": "2015-09-24T09:34:44.319Z"
    }
}
Updating Screenshot Position
PATCH /screenshot_positions/{id}

Update a screenshot position with a given ID.

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the Medium of the given Screenshot Position.

Path variables

id
number required

The id of screenshot position

Example:
1

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PATCH https://tenant.kzoplatform.com/api/screenshot_positions/457606640300987757 HTTP/1.1 

Content-Type: application/json

[{ 
    "op": "replace", 
    "path": "/x", 
    "value": 3 
}]

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "screenshot_positions": {
        "id": "457606640300987757",
        "href": "",
        "links": {
            "modified_by": {
            },
            "medium": null,
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
            ]
        },
        "x": 3,
        "y": 2,
        "created_at": "2015-09-24T09:02:42.483Z",
        "modified_at": "2015-09-24T09:07:07.558Z"
    }
}
Replacing Screenshot Position
PUT /screenshot_positions/{id}

Replace a screenshot position with a given ID.

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the Medium of the given Screenshot Position.

Path variables

id
number required

The id of screenshot position

Example:
1

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/screenshot_positions/457606640300987757 HTTP/1.1 

Content-Type: application/json

{
    "screenshot_positions" : {
        "x": 5,
      	"y": 6
    }
}

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "screenshot_positions": {
        "id": "457606640300987757",
        "href": "",
        "links": {
            "modified_by": {
            },
            "medium": null,
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
            ]
        },
        "x": 5,
        "y": 6,
        "created_at": "2015-09-24T09:02:42.483Z",
        "modified_at": "2015-09-24T09:07:51.955Z"
    }
}
Deleting Screenshot Position
GET /screenshot_positions/{id}

Delete a screenshot position with a given ID.

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the Medium of the given Screenshot Position.

Path variables

id
number required

The id of screenshot position

Example:
1

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/screenshot_positions/1 HTTP/1.1 

HTTP/1.1 204 No Content 
Favorites
POST /containers/{id}/favorite
POST /media/{id}/favorite
DELETE /favorites/{id}
GET /favorites
GET /favorites/{id}
Favorite container
POST /containers/{id}/favorite

Path variables

id
number required

container id

Responses

204 No Content
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/containers/123/favorite HTTP/1.1 

Content-Type: application/json

{
  "favorites" : {
    "is_subscription" : "true"
  }
}
Favorite medium
POST /media/{id}/favorite

Path variables

id
number required

medium id

Responses

204 No Content
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/media/321/favorite HTTP/1.1 

Content-Type: application/json

{
  "favorites" : {
    "is_subscription" : "true"
  }
}
Delete favorite
DELETE /favorites/{id}

Path variables

id
number required

favorite id

Responses

204 No Content
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Get favorites
GET /favorites

Returns favorites created by authorized user, CONTENT_VIEWER permission is required for faviorite’s medium or container.

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: created_by,media,containers.

page_size_primary
integer optional

Count of favorites on one page

page
integer optional

1-based page number

inaccessible_favorites
boolean optional

Request for list of ids of inaccessible favorites.

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/favorites?inaccessible_favorites=true&include=containers,media,created_by HTTP/1.1 

Content-Type: application/json



HTTP/1.1 200 OK 

Content-Type: application/json

{
  "linked": {
    "containers": [{...}],
    "media": [],
    "users": [{...}]
  },
  "meta": {
    "pagination": {
      "total_results": 1,
      "links": {
        "prev": null,
        "next": null,
        "first": "https://tenant.kzoplatform.com/api/favorites?container_id=123",
        "last": "https://tenant.kzoplatform.com/api/favorites?container_id=123"
      }
    },
    "inaccessible_favorites": [
      {"id": "123"},
      {"id": "456"}
    ]
  },
  "favorites": [
    {
      "id": "321",
      "href": "https://tenant.kzoplatform.com/api/favorites/526398432860968188",
      "links": {
        "containers": "123",
        "media": "",
        "created_by": {
          "type": "users",
          "username": "username"
        }
      },
      "meta": {
        "pagination": {},
        "actions": [
                {
                    "href": "https://tenant.kzoplatform.com/api/favorites/526398432860968188",
                    "label": "FAVORITE_GET",
                    "method": "GET"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/favorites/526398432860968188",
                    "label": "FAVORITE_DELETE",
                    "method": "DELETE"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/favorites/526398432860968188",
                    "label": "FAVORITE_UPDATE",
                    "method": "PUT"
                }
        ]
      },
      "created_at": "2015-12-22T09:23:55.739Z",
      "is_subscription": true
    }
  ]
}
Get favorite
GET /favorites/{id}

Returns favorite by id, created by authorized user

Path variables

id
string required

identifier of favorite

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: created_by,media,containers

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

404 Not Found

The server has not found anything matching the Request-URI.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/favorites/123 HTTP/1.1 

HTTP/1.1 200 OK 


{
    "favorites": {
        "created_at": "2017-09-22T09:36:14.441Z",
        "href": "https://tenant.kzoplatform.com/api/favorites/123",
        "id": "123",
        "is_subscription": false,
        "links": {
            "created_by": {
                "type": "users",
                "username": "admin"
            },
            "media": "985098302024324274"
        },
        "meta": {
            "actions": [
                {
                    "href": "https://localhost:8080/api/favorites/123",
                    "label": "FAVORITE_GET",
                    "method": "GET"
                },                
                {
                    "href": "https://staging-101.kzoinnovations.com/api/favorites/123",
                    "label": "FAVORITE_DELETE",
                    "method": "DELETE"
                },
                {
                    "href": "https://staging-101.kzoinnovations.com/api/favorites/123",
                    "label": "FAVORITE_UPDATE",
                    "method": "PUT"
                }
            ],
        }
    },
    "linked": {
        "media": [
            {
                "created_at": "2017-09-21T04:14:28.719Z",
                "deleted_at": null,
                "description": null,
                "href": "https://tenant.kzoplatform.com/api/media/985098302024324274?page_size_related=10000",
                "id": "985098302024324274",
                "title": "983063329373165394",
                "trt_msec": 100000
                ...
            }
        ],
        "users": [
            {
                "authentication_type": "PASSWORD",
                "created_at": "2015-03-14T08:05:50.374Z",
                "email": "admin@kzotest.com",
                "href": "https://tenant.kzoplatform.com/api/users/admin?page_size_related=10000",
                "id": "316971525670441986",
                "last_name": "admin",
                "modified_at": "2017-04-27T22:24:06.911Z",
                "username": "admin"
                ...
            }
        ]
    }
}
Custom Screenshots
POST /media/{id}/custom_screenshot
POST /containers/{id}/custom_screenshot
GET /custom_screenshots/{id}
POST /media/{id}/process_custom_screenshot
POST /containers/{id}/process_custom_screenshot
Creating Custom Screenshot For Medium
POST /media/{id}/custom_screenshot

Create a custom screenshot to medium with the given ID.

Requires Permission assigning Role CONTENT_UPDATER on the parent Container of the given Medium.

Path variables

id
number required

The id of the medium

Example:
1

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: created_by, modified_by, parent.

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/media/1/custom_screenshot HTTP/1.1 

HTTP/1.1 201 Created 

Content-Type: application/json

{
  "linked":{
    "containers":[],
    "media":[],
    "users":[]
  },
  "meta":{},
  "custom_screenshots":{
    "id": "537360343672820866",
    "href": "https://localhost:8080/api/custom_screenshots/537360343672820866",
    "links":{
      "parent":{},
      "modified_by":{},
      "created_by":{}
    },
    "meta":{
      "pagination":{},
      "actions":[
        {"label": "CUSTOM_SCREENSHOT_GET", "href": "https://localhost:8080/api/custom_screenshots/537360343672820866",},
        {"label": "CUSTOM_SCREENSHOT_UPLOAD", "href": "https://s3-external-1.amazonaws.com/kzo-staging-upload/",}
      ]
    },
    "created_at": "2016-01-12T09:59:04.801Z",
    "modified_at": "2016-01-12T09:59:04.801Z"
  }
}
Creating Custom Screenshot For Container
POST /containers/{id}/custom_screenshot

Create a custom screenshot to container with the given ID.

Requires Permission assigning Role CONTENT_UPDATER on the given Container.

Path variables

id
number required

The id of the container

Example:
1

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: created_by, modified_by, parent.

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/containers/1/custom_screenshot HTTP/1.1 

HTTP/1.1 201 Created 

Content-Type: application/json

{
  "linked":{
    "containers":[],
    "media":[],
    "users":[]
  },
  "meta":{},
  "custom_screenshots":{
    "id": "537360343672820866",
    "href": "https://localhost:8080/api/custom_screenshots/537360343672820866",
    "links":{
      "parent":{},
      "modified_by":{},
      "created_by":{}
    },
    "meta":{
      "pagination":{},
      "actions":[
        {"label": "CUSTOM_SCREENSHOT_GET", "href": "https://localhost:8080/api/custom_screenshots/537360343672820866",},
        {"label": "CUSTOM_SCREENSHOT_UPLOAD", "href": "https://s3-external-1.amazonaws.com/kzo-staging-upload/",}
      ]
    },
    "created_at": "2016-01-12T09:59:04.801Z",
    "modified_at": "2016-01-12T09:59:04.801Z"
  }
}
Fetching Custom Screenshot
GET /custom_screenshots/{id}

Fetch Custom Screenshot with the given ID.

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the Custom Screenshot or the parent Container of the parent Medium of the Custom Screenshot.

Path variables

id
number required

The ID of the screenshot

Example:
1

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: created_by, modified_by, parent.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/custom_screenshots/1 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "linked":{
    "containers":[],
    "media":[],
    "users":[]
  },
  "meta":{},
  "custom_screenshots":{
    "id": "537360343672820866",
    "href": "https://localhost:8080/api/custom_screenshots/537360343672820866",
    "links":{
      "parent":{},
      "modified_by":{},
      "created_by":{}
    },
    "meta":{
      "pagination":{},
      "actions":[
        {"label": "CUSTOM_SCREENSHOT_GET", "href": "https://localhost:8080/api/custom_screenshots/537360343672820866",},
        {"label": "CUSTOM_SCREENSHOT_UPLOAD", "href": "https://s3-external-1.amazonaws.com/kzo-staging-upload/",},
        {"label": "CUSTOM_SCREENSHOT_UPLOAD_WITH_PRESIGNED_URL", "href": "https://s3-external-1.amazonaws.com/kzo-staging-upload/",}
      ]
    },
    "created_at": "2016-01-12T09:59:04.801Z",
    "modified_at": "2016-01-12T09:59:04.801Z"
  }
}
Processing Custom Screenshot Of Medium
POST /media/{id}/process_custom_screenshot

Process Custom Screenshot of the given Medium.

Requires Permission assigning Role CONTENT_UPDATER on the parent Container of the given Medium.

Path variables

id
number required

The ID of the medium

Example:
1

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/media/1/process_custom_screenshot HTTP/1.1 

HTTP/1.1 200 OK 
Processing Custom Screenshot Of Container
POST /containers/{id}/process_custom_screenshot

Process Custom Screenshot of the given Container.

Requires Permission assigning Role CONTENT_UPDATER on the given Container.

Path variables

id
number required

The ID of the Container

Example:
1

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/containers/1/process_custom_screenshot HTTP/1.1 

HTTP/1.1 200 OK 
Viewed Fragments
POST /media/{id}/viewed_fragment
PUT /viewed_fragments/{id}
Creating Viewed Fragment For Medium
POST /media/{id}/viewed_fragment

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the given Medium.

Path variables

id
number required

The ID of the Medium

Example:
123

Responses

201 Created
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/media/123/viewed_fragment HTTP/1.1 

Content-Type: application/json

{
  "viewed_fragments": {
    "hit": true,
    "start_msec": 0,
    "end_msec": 10000,
    "protocol": "HTTP",
    "access_type": "VOD",
    "video_rendition_option": 3,
/*object with variuos structure to store additional attributes*/
    "attributes_object":{ 
        "key1": "43j523lk46j", 
        "key2": "9034wkjrtylwkrjy", 
        "key3": "325",
        "shared":true
    }
  }
}
Replacing Viewed Fragment
PUT /viewed_fragments/{id}

Requires the current session to be the one was used to create the Viewed Fragment. Only end_msec can be changed. The new value of end_msec must be greater than or equal to the old one.

Path variables

id
number required

The ID of the Viewed Fragment

Example:
123

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/viewed_fragments/123 HTTP/1.1 

Content-Type: application/json

{
  "viewed_fragments": {
    "hit": true,
    "start_msec": 0,
    "end_msec": 15000,
    "protocol": "HTTP",
    "access_type": "VOD",
    "video_rendition_option": 3
    /*object with variuos structure to store additional attributes*/
    "attributes_object":{ 
        "key1": "43j523lk46j", 
        "key2": "9034wkjrtylwkrjy", 
        "key3": "325",
        "shared":true
    }
  }
}
Platform Features
POST /features/{name}/disable
POST /features/{name}/enable
GET /features/{name}
PUT /features/{name}
Disable feature
POST /features/{name}/disable

Authentication

Disables feature with the specified name. Private feature can be manged only if user is included to group with MANAGE_TENANT and SUPPORT_TENANT capabilities.

Path variables

name
string required

Name of the feature

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: users, containers, groups etc. Parameters are joined with comma.

Includes for media and medium can be substituted, so that media information would be included to the response no matter which of two includes was requested. Same logic is applied container and containers.

Example:
media,containers,created_by
Enable feature
POST /features/{name}/enable

Authentication

Method enables feature with the specified name. Private feature can be manged only if user is included to group with MANAGE_TENANT and SUPPORT_TENANT capabilities.

Path variables

name
string required

Name of the feature

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: users, containers, groups etc. Parameters are joined with comma.

Includes for media and medium can be substituted, so that media information would be included to the response no matter which of two includes was requested. Same logic is applied container and containers.

Example:
media,containers,created_by
Viewing All Platform Features
GET /features

Fetch all platform features.

Requires authenticated user if parameter include is not empty.

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.What can be included at most: modified_by,users.created_by,users.modified_by.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/features?include=modified_by,users.created_by,users.modified_by HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "users": [
            {
                "id": "316971525662053377",
                "href": "https://staging-101.kzoinnovations.com/api/users/system?page_size_related=10000",
                "links": {
                    "modified_by": {
                        "type": "users",
                        "username": "system"
                    },
                    "groups": [
                    ],
                    "created_by": {
                        "type": "users",
                        "username": "system"
                    },
                    "avatars": ""
                },
                "meta": {
                    "pagination": {
                    },
                    "state": {
                    },
                    "actions": [
                        {
                            "label": "USER_GET",
                            "href": "https://staging-101.kzoinnovations.com/api/users/system?page_size_related=10000",
                            "method": "GET"
                        },
                        {
                            "label": "USER_CREATE",
                            "href": "https://staging-101.kzoinnovations.com/api/users",
                            "method": "POST"
                        },
                        {
                            "label": "USER_DELETE",
                            "href": "https://staging-101.kzoinnovations.com/api/users/system",
                            "method": "DELETE"
                        },
                        {
                            "label": "USER_GET_ALL",
                            "href": "https://staging-101.kzoinnovations.com/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
                            "method": "GET"
                        }
                    ]
                },
                "created_at": "2015-03-14T08:05:50.374Z",
                "modified_at": "2015-03-14T08:05:50.374Z",
                "first_name": "system",
                "last_name": "system",
                "username": "system",
                "email": "system@kzotest.com",
                "authentication_type": "NONE",
                "avatar_href": ""
            }
        ]
    },
    "meta": {
    },
    "features": [
        {
            "id": "623728058838292300",
            "href": "https://staging-101.kzoinnovations.com/api/features/PUBLIC_ACCESS",
            "links": {
                "modified_by": {
                    "type": "users",
                    "username": "system"
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "FEATURE_GET",
                        "href": "https://staging-101.kzoinnovations.com/api/features/PUBLIC_ACCESS",
                        "method": "GET"
                    },
                    {
                        "label": "FEATURE_GET_ALL",
                        "href": "https://staging-101.kzoinnovations.com/api/features",
                        "method": "GET"
                    },
                    {
                        "label": "FEATURE_EDIT_METADATA",
                        "href": "https://staging-101.kzoinnovations.com/api/features/PUBLIC_ACCESS",
                        "method": "PUT"
                    }
                ]
            },
            "name": "PUBLIC_ACCESS",
            "type": "AUTHENTICATION",
            "status": "ENABLED",
            "modified_at": "2016-06-03T09:26:32.007Z"
        },
        {
            "id": "623728058846680909",
            "href": "https://staging-101.kzoinnovations.com/api/features/IPAAS",
            "links": {
                "modified_by": {
                    "type": "users",
                    "username": "system"
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "FEATURE_GET",
                        "href": "https://staging-101.kzoinnovations.com/api/features/IPAAS",
                        "method": "GET"
                    },
                    {
                        "label": "FEATURE_GET_ALL",
                        "href": "https://staging-101.kzoinnovations.com/api/features",
                        "method": "GET"
                    },
                    {
                        "label": "FEATURE_EDIT_METADATA",
                        "href": "https://staging-101.kzoinnovations.com/api/features/IPAAS",
                        "method": "PUT"
                    }
                ]
            },
            "name": "IPAAS",
            "type": "AUTHENTICATION",
            "status": "DISABLED",
            "modified_at": "2016-06-03T09:26:32.007Z"
        },
        {
            "id": "623728058855069518",
            "href": "https://staging-101.kzoinnovations.com/api/features/DRIVE",
            "links": {
                "modified_by": {
                    "type": "users",
                    "username": "system"
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "FEATURE_GET",
                        "href": "https://staging-101.kzoinnovations.com/api/features/DRIVE",
                        "method": "GET"
                    },
                    {
                        "label": "FEATURE_GET_ALL",
                        "href": "https://staging-101.kzoinnovations.com/api/features",
                        "method": "GET"
                    },
                    {
                        "label": "FEATURE_EDIT_METADATA",
                        "href": "https://staging-101.kzoinnovations.com/api/features/DRIVE",
                        "method": "PUT"
                    }
                ]
            },
            "name": "DRIVE",
            "type": "INTEGRATION",
            "status": "DISABLED",
            "modified_at": "2016-06-03T09:26:32.007Z"
        }
    ]
}
Viewing Platform Feature
GET /features/{name}

Fetch a Platform Feature with a given name.

Requires authenticated user if parameter include is not empty.

Path variables

name
string required
Enumeration:
DRIVE
IPAAS
PUBLIC_ACCESS

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.What can be included at most: modified_by,users.created_by,users.modified_by.

Responses

200 OK
404 Not Found

Not found features with a given name

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/features/PUBLIC_ACCESS?include=modified_by,users.created_by,users.modified_by HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "users": {
            "id": "316971525662053377",
            "href": "https://staging-101.kzoinnovations.com/api/users/system?page_size_related=10000",
            "links": {
                "modified_by": {
                    "type": "users",
                    "username": "system"
                },
                "groups": [
                ],
                "created_by": {
                    "type": "users",
                    "username": "system"
                },
                "avatars": ""
            },
            "meta": {
                "pagination": {
                },
                "state": {
                },
                "actions": [
                    {
                        "label": "USER_GET",
                        "href": "https://staging-101.kzoinnovations.com/api/users/system?page_size_related=10000",
                        "method": "GET"
                    },
                    {
                        "label": "USER_CREATE",
                        "href": "https://staging-101.kzoinnovations.com/api/users",
                        "method": "POST"
                    },
                    {
                        "label": "USER_DELETE",
                        "href": "https://staging-101.kzoinnovations.com/api/users/system",
                        "method": "DELETE"
                    },
                    {
                        "label": "USER_GET_ALL",
                        "href": "https://staging-101.kzoinnovations.com/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2015-03-14T08:05:50.374Z",
            "modified_at": "2015-03-14T08:05:50.374Z",
            "first_name": "system",
            "last_name": "system",
            "username": "system",
            "email": "system@kzotest.com",
            "authentication_type": "NONE",
            "avatar_href": ""
        }
    },
    "meta": {
    },
    "features": {
        "id": "623728058838292300",
        "href": "https://staging-101.kzoinnovations.com/api/features/PUBLIC_ACCESS",
        "links": {
            "modified_by": {
                "type": "users",
                "username": "system"
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "FEATURE_GET",
                    "href": "https://staging-101.kzoinnovations.com/api/features/PUBLIC_ACCESS",
                    "method": "GET"
                },
                {
                    "label": "FEATURE_GET_ALL",
                    "href": "https://staging-101.kzoinnovations.com/api/features",
                    "method": "GET"
                },
                {
                    "label": "FEATURE_EDIT_METADATA",
                    "href": "https://staging-101.kzoinnovations.com/api/features/PUBLIC_ACCESS",
                    "method": "PUT"
                }
            ]
        },
        "name": "PUBLIC_ACCESS",
        "type": "AUTHENTICATION",
        "status": "ENABLED",
        "modified_at": "2016-06-03T09:26:32.007Z"
    }
}
Replacing Platform Feature
PUT /features/{name}

Metod is deprecated and will be removed soon.

Complete replacement of Platform Feature with a given name.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

The name in the URL path must be the same as features.name in the request body, otherwise 400 with a corresponding message is returned.

Path variables

name
string required
Enumeration:
DRIVE
IPAAS
PUBLIC_ACCESS

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.What can be included at most: modified_by,users.created_by,users.modified_by.

Responses

200 OK
403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

404 Not Found

Not found features with a given name

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/features/PUBLIC_ACCESS?include=modified_by,users.created_by,users.modified_by HTTP/1.1 

Content-Type: application/json

{
  "features": {
    "name": "PUBLIC_ACCESS",
    "type": "INTEGRATION",
    "status": "DISABLED"
  }
}

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "users": {
            "id": "316971525662053377",
            "href": "https://staging-101.kzoinnovations.com/api/users/system?page_size_related=10000",
            "links": {
                "modified_by": {
                    "type": "users",
                    "username": "system"
                },
                "groups": [
                ],
                "created_by": {
                    "type": "users",
                    "username": "system"
                },
                "avatars": ""
            },
            "meta": {
                "pagination": {
                },
                "state": {
                },
                "actions": [
                    {
                        "label": "USER_GET",
                        "href": "https://staging-101.kzoinnovations.com/api/users/system?page_size_related=10000",
                        "method": "GET"
                    },
                    {
                        "label": "USER_CREATE",
                        "href": "https://staging-101.kzoinnovations.com/api/users",
                        "method": "POST"
                    },
                    {
                        "label": "USER_DELETE",
                        "href": "https://staging-101.kzoinnovations.com/api/users/system",
                        "method": "DELETE"
                    },
                    {
                        "label": "USER_GET_ALL",
                        "href": "https://staging-101.kzoinnovations.com/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2015-03-14T08:05:50.374Z",
            "modified_at": "2015-03-14T08:05:50.374Z",
            "first_name": "system",
            "last_name": "system",
            "username": "system",
            "email": "system@kzotest.com",
            "authentication_type": "NONE",
            "avatar_href": ""
        }
    },
    "meta": {
    },
    "features": {
        "id": "623728058838292300",
        "href": "https://staging-101.kzoinnovations.com/api/features/PUBLIC_ACCESS",
        "links": {
            "modified_by": {
                "type": "users",
                "username": "system"
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "FEATURE_GET",
                    "href": "https://staging-101.kzoinnovations.com/api/features/PUBLIC_ACCESS",
                    "method": "GET"
                },
                {
                    "label": "FEATURE_GET_ALL",
                    "href": "https://staging-101.kzoinnovations.com/api/features",
                    "method": "GET"
                },
                {
                    "label": "FEATURE_EDIT_METADATA",
                    "href": "https://staging-101.kzoinnovations.com/api/features/PUBLIC_ACCESS",
                    "method": "PUT"
                }
            ]
        },
        "name": "PUBLIC_ACCESS",
        "type": "INTEGRATION",
        "status": "DISABLED",
        "modified_at": "2016-06-03T09:26:32.007Z"
    }
}
iPaaS Configuration
GET /feature_configs/IPAAS
PUT /feature_configs/IPAAS
Viewing iPaaS Configuration
GET /feature_configs/IPAAS

Fetch iPaaS configuration data.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Responses

200 OK
403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

iPaaS is configured for the tenant

GET https://tenant.kzoplatform.com/api/feature_configs/IPAAS HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "feature_config_ipaas": {
        "id": "678970295536588461",
        "href": "https://localhost:8080/api/feature_configs/IPAAS",
        "links": {
            "modified_by": {
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "IPAAS_CONFIG_GET",
                    "href": "https://localhost:8080/api/feature_configs/IPAAS",
                    "method": "GET"
                },
                {
                    "label": "IPAAS_CONFIG_REPLACE",
                    "href": "https://localhost:8080/api/feature_configs/IPAAS",
                    "method": "PUT"
                }
            ]
        },
        "created_at": "2016-10-21T07:11:05.573Z",
        "modified_at": "2017-05-15T12:56:20.013Z",
        "name": "few",
        "autoenroll_group_id": null,
        "autoenroll_group_label": null,
        "client_host_port": "session-v1.peoplefluent.com",
        "api_host_port": "gateway-v1.peoplefluent.com",
        "client_id": "ewfwfw-b260-43d7-912wef257-wfe",
        "secret": "xbbxcbgrr-adf5-427f-b679-wefwefewf",
        "token_expiration_skew_seconds": 10,
        "slo_enabled": true
    }
}
Creating or Replacing iPaaS Configuration
PUT /feature_configs/IPAAS

Delete existing iPaaS configuration, if any, and create a new one.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/feature_configs/IPAAS HTTP/1.1 

Content-Type: application/json

{
  "feature_configs": {
    "name": "SomeName",
    "autoenroll_group_id": null,
    "autoenroll_group_label": null,
    "client_host_port": "session-v1.people.com",
    "api_host_port": "gateway-v1.people.com",
    "client_id": "clientId",
    "secret": "secret",
    "token_expiration_skew_seconds": 10,
    "slo_enabled": true
  }
}



HTTP/1.1 201 Created 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "feature_config_ipaas": {
        "id": "678970295536588461",
        "href": "https://localhost:8080/api/feature_configs/IPAAS",
        "links": {
            "modified_by": {
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "IPAAS_CONFIG_GET",
                    "href": "https://localhost:8080/api/feature_configs/IPAAS",
                    "method": "GET"
                },
                {
                    "label": "IPAAS_CONFIG_REPLACE",
                    "href": "https://localhost:8080/api/feature_configs/IPAAS",
                    "method": "PUT"
                }
            ]
        },
        "created_at": "2016-10-21T07:11:05.573Z",
        "modified_at": "2017-05-15T12:56:20.013Z",
        "name": "few",
        "autoenroll_group_id": null,
        "autoenroll_group_label": null,
        "client_host_port": "session-v1.people.com",
        "api_host_port": "gateway-v1.people.com",
        "client_id": "clientId",
        "secret": "secret",
        "token_expiration_skew_seconds": 10,
        "slo_enabled": true
    }
}
Emails
POST /emails
Send Email
POST /emails

Sends email.

Content of emails.body_html is treated as HTML. It is also converted to plaintext (stripping all non-text HTML tags). Both variants are included in the message as alternatives.

If emails.body_html contains <img src="${url}" x-kzo-attach-image="${content-type}" />, the image is downloaded and converted to an inline attachment with the Content-Type specified (${content-type}). If ${content-type} is omitted (<img src="${url}" x-kzo-attach-image />), KZO API try guess it; it is not guaranteed to work as expected, so it is recommended to specify x-kzo-attach-image="${content-type}".

Requires authenticated user. Not available to ANONYMOUS. Requires DRIVE feature to be enabled. Requires email.api.from.email_address tenant-level property to be set. Mandatory attributes of POST body: subject, body_html, at least one address in to.

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

Image is not converted to an inline attachments since it has no x-kzo-attach-image="${content-type}". Alternative text will be Hello.

POST https://tenant.kzoplatform.com/api/emails HTTP/1.1 

Content-Type: application/json

{
  "emails": {
    "subject": "Title",
    "body_html": "<i>Hello</i><img src='http://cs7052.vk.me/c540107/v540107359/2729/fYQlS_23QdA.jpg' />",
    "to": ["mail@example.com"]
  }
}

The img tag is converted to <img src='cid:${part-id}' x-kzo-attach-image='image/jpeg' />; the image will be attached as ${part-id}. In case the resource to be inlined does not exist or is not available - service will return 400 Bad request.

POST https://tenant.kzoplatform.com/api/emails HTTP/1.1 

Content-Type: application/json

{
  "emails": {
    "subject": "Title",
    "body_html": "<i>Hello</i><img src='http://cs7052.vk.me/c540107/v540107359/2729/fYQlS_23QdA.jpg' x-kzo-attach-image='image/jpeg' />",
    "to": ["mail@example.com"]
  }
}

HTTP/1.1 204 No Content 
POST https://tenant.kzoplatform.com/api/emails HTTP/1.1 

Content-Type: application/json

{
  "emails": {
    "subject": "Title",
    "body_html": "Hello",
    "to": ["a@example.com", "b@example.com"],
    "cc": ["c@example.com", "d@example.com"],
    "bcc": ["e@example.com", "f@example.com"]
  }
}

HTTP/1.1 204 No Content 
POST https://tenant.kzoplatform.com/api/emails HTTP/1.1 

Content-Type: application/json

{
  "emails": {
    "subject": "Title",
    "body_html": "Hello",
    "to": ["a@example.com"],
    "container_id ":"54321",
    "medium_id":"9876"
  }
}

HTTP/1.1 204 No Content 
SAML Configurations
GET /feature_configs/SAML/key_aliases
GET /feature_configs/SAML
GET /feature_configs/SAML/{id}
DELETE /feature_configs/SAML/{id}
POST /feature_configs/SAML
PUT /feature_configs/SAML/{id}
Viewing SAML key aliases
GET /feature_configs/SAML/key_aliases

Fetch available SAML key aliases.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Examples

GET https://tenant.kzoplatform.com/api/feature_configs/SAML/key_aliases HTTP/1.1 

Content-Type: application/json

{
    "feature_saml_key_aliases": [
        {
            "key_alias": "kzoinnovations",
            "is_default": true
        }
    ]
}
Viewing All SAML Configurations
GET /feature_configs/SAML

Fetch all SAML configurations.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Responses

200 OK
Body
Object
feature_config_saml
Array of SamlConfig
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/feature_configs/SAML HTTP/1.1 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "feature_config_saml": [
        {
            "id": "742361017782114123",
            "name": "client",
            "key_alias": "kzoinnovations",
            "autoenroll_group_id": null,
            "idp_metadata": "...",
            "idp_id": "http://ad-staging.kzoinnovations.com/adfs/services/trust",
            "username_attr": "E-Mail Address",
            "first_name_attr": "Given Name",
            "last_name_attr": "Surname",
            "email_attr": "E-Mail Address",
            "redirect_to_relay_state_enabled": true,
            "slo_enabled": true,
            "response_skew_sec": 60,
            "sp_metadata_href": "https://skozlov.kzoinnovations.com/saml/metadata/sp.xml?cao=client",
            "idp_metadata_href": "https://skozlov.kzoinnovations.com/saml/metadata/idp.xml?cao=client",
            "is_default": true
        },
        {
            "id": "742367022448383837",
            "name": "custom",
            "key_alias": "kzoinnovations",
            "autoenroll_group_id": null,
            "idp_metadata": "...",
            "idp_id": "http://ad-staging.kzoinnovations.com/adfs/services/trust",
            "username_attr": "E-Mail Address",
            "first_name_attr": "Given Name",
            "last_name_attr": "Surname",
            "email_attr": "E-Mail Address",
            "redirect_to_relay_state_enabled": true,
            "slo_enabled": true,
            "response_skew_sec": 60,
            "sp_metadata_href": "https://skozlov.kzoinnovations.com/saml/metadata/sp.xml?cao=custom",
            "idp_metadata_href": "https://skozlov.kzoinnovations.com/saml/metadata/idp.xml?cao=custom",
            "is_default": false
        }
    ]
}
Viewing SAML Configuration
GET /feature_configs/SAML/{id}

Fetch SAML configuration.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Path variables

id
string required

The ID of configuration

Responses

200 OK
Body
Object
feature_config_saml
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/feature_configs/SAML/742361017782114123 HTTP/1.1 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "feature_config_saml": {
        "id": "742361017782114123",
        "name": "client",
        "key_alias": "kzoinnovations",
        "autoenroll_group_id": null,
        "idp_metadata": "...",
        "idp_id": "http://ad-staging.kzoinnovations.com/adfs/services/trust",
        "username_attr": "E-Mail Address",
        "first_name_attr": "Given Name",
        "last_name_attr": "Surname",
        "email_attr": "E-Mail Address",
        "redirect_to_relay_state_enabled": true,
        "slo_enabled": true,
        "response_skew_sec": 60,
        "sp_metadata_href": "https://skozlov.kzoinnovations.com/saml/metadata/sp.xml?cao=client",
        "idp_metadata_href": "https://skozlov.kzoinnovations.com/saml/metadata/idp.xml?cao=client",
        "is_default": true
    }
}
Deleting SAML Configuration
DELETE /feature_configs/SAML/{id}

Deletes SAML configuration.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Path variables

id
string required

The ID of configuration

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Creating SAML Configuration
POST /feature_configs/SAML

Creates a SAML configuration.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Request headers

X-KZO-API-Version
string required

Specifies API version. For details, see API Version.

X-KZO-Auth-AccessKey
string required

Access Key used by the API caller to authenticate against the server. For details, see Authentication and Authorization.

X-KZO-Auth-DelegateGroupId
number optional

Specifies ID of the Group on behalf of which the method should be executed. For details, see Authentication and Authorization.

X-KZO-Auth-DelegateUsername
string optional

Specifies username of the User on behalf of which the method should be executed. For details, see Authentication and Authorization.

X-KZO-Auth-Username
string required

Username used by the API caller to authenticate against the server. For details, see Authentication and Authorization.

X-KZO-Pipeline-Action
string optional

Used to initiate special actions related to pipeline processing on a pipeline-enabled entity or an entity managed by a pipeline of its parent entity. For more details, see Workflow.

X-KZO-Tenant
string required

Specifies name of the Tenant to which the request is issued. For details, see [Tenant Management](doc://Tenant Management).

Request body

Object
feature_config_saml

Responses

201 Created
Body
Object
feature_config_saml
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/feature_configs/SAML HTTP/1.1 

Content-Type: application/json

{
    "feature_config_saml": {
      "name": "custom",
      "idp_metadata": "...",
      "idp_id": "http://ad-staging.kzoinnovations.com/adfs/services/trust",
      "username_attr": "E-Mail Address",
      "first_name_attr": "Given Name",
      "last_name_attr": "Surname",
      "email_attr": "E-Mail Address"
    }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "feature_config_saml": {
        "id": "742367022448383837",
        "name": "custom",
        "key_alias": "kzoinnovations",
        "autoenroll_group_id": null,
        "idp_metadata": "...",
        "idp_id": "http://ad-staging.kzoinnovations.com/adfs/services/trust",
        "username_attr": "E-Mail Address",
        "first_name_attr": "Given Name",
        "last_name_attr": "Surname",
        "email_attr": "E-Mail Address",
        "redirect_to_relay_state_enabled": true,
        "slo_enabled": true,
        "response_skew_sec": 60,
        "sp_metadata_href": "https://skozlov.kzoinnovations.com/saml/metadata/sp.xml?cao=custom",
        "idp_metadata_href": "https://skozlov.kzoinnovations.com/saml/metadata/idp.xml?cao=custom",
        "is_default": false
    }
}
Replacing SAML Configuration
PUT /feature_configs/SAML/{id}

Complete replacement of SAML configuration.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Path variables

id
string required

The ID of configuration

Request headers

X-KZO-API-Version
string required

Specifies API version. For details, see API Version.

X-KZO-Auth-AccessKey
string required

Access Key used by the API caller to authenticate against the server. For details, see Authentication and Authorization.

X-KZO-Auth-DelegateGroupId
number optional

Specifies ID of the Group on behalf of which the method should be executed. For details, see Authentication and Authorization.

X-KZO-Auth-DelegateUsername
string optional

Specifies username of the User on behalf of which the method should be executed. For details, see Authentication and Authorization.

X-KZO-Auth-Username
string required

Username used by the API caller to authenticate against the server. For details, see Authentication and Authorization.

X-KZO-Pipeline-Action
string optional

Used to initiate special actions related to pipeline processing on a pipeline-enabled entity or an entity managed by a pipeline of its parent entity. For more details, see Workflow.

X-KZO-Tenant
string required

Specifies name of the Tenant to which the request is issued. For details, see [Tenant Management](doc://Tenant Management).

Request body

Object
feature_config_saml

Responses

200 OK
Body
Object
feature_config_saml
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/feature_configs/SAML/742367022448383837 HTTP/1.1 

Content-Type: application/json

{
    "feature_config_saml": {
      "name": "custom",
      "idp_metadata": "...",
      "idp_id": "http://ad-staging.kzoinnovations.com/adfs/services/trust",
      "username_attr": "E-Mail Address",
      "first_name_attr": "Given Name",
      "last_name_attr": "Surname",
      "email_attr": "E-Mail Address"
    }
}

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "feature_config_saml": {
        "id": "742367022448383837",
        "name": "custom",
        "key_alias": "kzoinnovations",
        "autoenroll_group_id": null,
        "idp_metadata": "...",
        "idp_id": "http://ad-staging.kzoinnovations.com/adfs/services/trust",
        "username_attr": "E-Mail Address",
        "first_name_attr": "Given Name",
        "last_name_attr": "Surname",
        "email_attr": "E-Mail Address",
        "redirect_to_relay_state_enabled": true,
        "slo_enabled": true,
        "response_skew_sec": 60,
        "sp_metadata_href": "https://skozlov.kzoinnovations.com/saml/metadata/sp.xml?cao=custom",
        "idp_metadata_href": "https://skozlov.kzoinnovations.com/saml/metadata/idp.xml?cao=custom",
        "is_default": false
    }
}
Closed Captions Sets
GET /closed_captions_sets/{id}
DELETE /closed_captions_sets/{id}
POST /media/{id}/closed_captions_set
POST /api/media/{medium_id}/extract_ccs
POST /closed_captions_sets/{ccsId}/translate/{language}
POST /containers/{id}/speech_recognition
Viewing Closed Captions Set
GET /closed_captions_sets/{id}

Fetch a Closed Captions Set with a given id.

Requires Permission assigning Role CONTENT_VIEWER on the parent Container of the parent Medium.

Path variables

id
string required

The ID of the Closed Captions Set

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/closed_captions_sets/123 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "languages": [
        ]
    },
    "meta": {
    },
    "closed_captions_sets": {
        "id": "123",
        "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/123",
        "links": {
            "modified_by": {
            },
            "language": {
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "state": {
                "pipeline_status": "CREATED",
                "published": false,
                "pipeline_resource": {
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/123",
                    "type": "closed_captions_sets"
                }
            },
            "actions": [
                {
                    "label": "CLOSED_CAPTIONS_SET_GET",
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/123",
                    "method": "GET"
                },
                {
                    "label": "CLOSED_CAPTIONS_SET_DELETE",
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/123",
                    "method": "DELETE"
                }
            ]
        },
        "created_at": "2017-02-09T11:00:11.660Z",
        "modified_at": "2017-02-09T11:00:11.660Z",
        "hash_sha1": null,
        "hash_md5": null,
        "size": null,
        "speech_recognition_confidence_avg": 85.2,
        "speech_recognition_confidence_stddev": 0.01
    }
}
GET https://tenant.kzoplatform.com/api/closed_captions_sets/123 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "languages": [
            {
                "id": "ru",
                "name": "Russian"
            }
        ]
    },
    "meta": {
    },
    "closed_captions_sets": {
        "id": "123",
        "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/123",
        "links": {
            "modified_by": {
            },
            "language": {
                "type": "languages",
                "id": "ru"
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "state": {
                "pipeline_status": "CREATED",
                "published": false,
                "pipeline_resource": {
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/123",
                    "type": "closed_captions_sets"
                }
            },
            "actions": [
                {
                    "label": "CLOSED_CAPTIONS_SET_GET",
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/123",
                    "method": "GET"
                },
                {
                    "label": "CLOSED_CAPTIONS_SET_DELETE",
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/123",
                    "method": "DELETE"
                }
            ]
        },
        "created_at": "2017-02-09T11:05:26.643Z",
        "modified_at": "2017-02-09T11:05:26.643Z",
        "hash_sha1": null,
        "hash_md5": null,
        "size": null,
        "speech_recognition_confidence_avg": 85.2,
        "speech_recognition_confidence_stddev": 0.01
    }
}
Deleting Closed Captions Set
DELETE /closed_captions_sets/{id}

Deletes the given Closed Captions Set.

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the parent Medium.

Path variables

id
string required

The ID of the Closed Captions Set

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/closed_captions_sets/123 HTTP/1.1 

HTTP/1.1 204 No Content 
Creating Closed Captions Set
POST /media/{id}/closed_captions_set

Creates resource to hold the Closed Captions Set. Attribute meta.actions for meta.action.label=CLOSED_CAPTIONS_SET_UPLOAD provide information on how to upload the Closed Captions Set file. This action is deprecated, use CLOSED_CAPTIONS_SET_UPLOAD_WITH_PRESIGNED_URL instead.

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the given Medium.

Path variables

id
string required

The ID of the Medium in which Closed Captions Set is being created.

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/media/123/closed_captions_set HTTP/1.1 

Content-Type: application/json

{
  "closed_captions_sets": {}
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "linked": {
        "languages": [
        ]
    },
    "meta": {
    },
    "closed_captions_sets": {
        "id": "456",
        "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/456",
        "links": {
            "modified_by": {
            },
            "language": {
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "state": {
                "pipeline_status": "CREATED",
                "published": false,
                "pipeline_resource": {
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/456",
                    "type": "closed_captions_sets"
                }
            },
            "actions": [
                {
                    "label": "CLOSED_CAPTIONS_SET_GET",
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/456",
                    "method": "GET"
                },
                {
                    "label": "CLOSED_CAPTIONS_SET_DELETE",
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/456",
                    "method": "DELETE"
                }
            ]
        },
        "created_at": "2017-02-09T11:00:11.660Z",
        "modified_at": "2017-02-09T11:00:11.660Z",
        "hash_sha1": null,
        "hash_md5": null,
        "size": null
    }
}
POST https://tenant.kzoplatform.com/api/media/123/closed_captions_set HTTP/1.1 

Content-Type: application/json

{
  "closed_captions_sets": {
    "language": "ru"
  }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "linked": {
        "languages": [
            {
                "id": "ru",
                "name": "Russian"
            }
        ]
    },
    "meta": {
    },
    "closed_captions_sets": {
        "id": "456",
        "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/456",
        "links": {
            "modified_by": {
            },
            "language": {
                "type": "languages",
                "id": "ru"
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "state": {
                "pipeline_status": "CREATED",
                "published": false,
                "pipeline_resource": {
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/456",
                    "type": "closed_captions_sets"
                }
            },
            "actions": [
                {
                    "label": "CLOSED_CAPTIONS_SET_GET",
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/456",
                    "method": "GET"
                },
                {
                    "label": "CLOSED_CAPTIONS_SET_DELETE",
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/456",
                    "method": "DELETE"
                }
            ]
        },
        "created_at": "2017-02-09T11:05:26.643Z",
        "modified_at": "2017-02-09T11:05:26.643Z",
        "hash_sha1": null,
        "hash_md5": null,
        "size": null
    }
}
Automatically generate subtitles from media
POST /api/media/{medium_id}/extract_ccs

Automatically generate subtitles using speech to text voice recognition.

Path variables

medium_id
number required

The id of media

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com//api/media/12300000000000000044/extract_ccs HTTP/1.1 

Content-Type: application/json
{}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "closed_captions_sets": {
        "ccs_creation_type": "SPEECH_RECOGNITION",
        "created_at": "2017-11-03T09:11:18.306Z",
        "href": "https://tenant.kzoplatform.com/api/closed_captions_sets/1016413056084743555",
        "id": "1016413056084743555",
        "links": {
            "language": {
                "id": "en",
                "type": "languages"
            },
        },
        "meta": {
            "actions": [
                {
                    "href": "https://staging-platform-test.kzoinnovations.com/api/closed_captions_sets/1016413056084743555",
                    "label": "CLOSED_CAPTIONS_SET_GET",
                    "method": "GET"
                },
                {
                    "href": "https://staging-platform-test.kzoinnovations.com/api/closed_captions_sets/1016413056084743555",
                    "label": "CLOSED_CAPTIONS_SET_DELETE",
                    "method": "DELETE"
                },
                {
                    "href": "https://s3-external-1.amazonaws.com/kzo-staging-upload/",
                    "label": "CLOSED_CAPTIONS_SET_UPLOAD",
                    "method": "POST",
                },
                {
                    "href": "https://staging-platform-test.kzoinnovations.com/api/closed_captions_sets/1016413056084743555/process_closed_captions",
                    "label": "CLOSED_CAPTIONS_SET_PROCESS",
                    "method": "POST"
                }
            ],
            "state": {
                "pipeline_resource": {
                    "href": "https://staging-platform-test.kzoinnovations.com/api/closed_captions_sets/1016413056084743555",
                    "type": "closed_captions_sets"
                },
                "pipeline_status": "EDITING",
                "published": false
            }
        },
        "modified_at": "2017-11-03T09:11:18.306Z",
    },
    "linked": {
        "languages": [
            {
                "id": "en",
                "name": "English"
            }
        ]
    }
}
Translating Closed Captions Set
POST /closed_captions_sets/{ccsId}/translate/{language}

Creates a Closed Captions Set and starts its creation by translating the original Closed Captions Set into the specified language.

The created Closed Captions Set will be returned in PROCESSING status.

Requires Permission assigning Role CONTENT_MANAGER or CONTENT_UPDATER on the parent Container of the parent Medium of the original Closed Captions Set.

Path variables

ccsId
string required

ID of the original Closed Captions Set

language
string required

Target language

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/closed_captions_sets/1024441575628870911/translate/ru HTTP/1.1 

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "linked": {
        "languages": [
            {
                "id": "ru",
                "name": "Russian"
            }
        ]
    },
    "meta": {
    },
    "closed_captions_sets": {
        "id": "1024442376975815948",
        "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/1024442376975815948",
        "links": {
            "modified_by": {
            },
            "deleted_by": {
            },
            "language": {
                "type": "languages",
                "id": "ru"
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "state": {
                "pipeline_status": "PROCESSING",
                "published": false,
                "pipeline_resource": {
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/1024442376975815948",
                    "type": "closed_captions_sets"
                }
            },
            "actions": [
                {
                    "label": "CLOSED_CAPTIONS_SET_GET",
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/1024442376975815948",
                    "method": "GET"
                },
                {
                    "label": "CLOSED_CAPTIONS_SET_DELETE",
                    "href": "https://staging-101.kzoinnovations.com/api/closed_captions_sets/1024442376975815948",
                    "method": "DELETE"
                }
            ]
        },
        "created_at": "2017-11-14T11:04:07.944Z",
        "modified_at": "2017-11-14T11:04:07.951Z",
        "deleted_at": null,
        "ccs_creation_type": "TRANSLATED",
        "hash_sha1": null,
        "hash_md5": null,
        "size": null
    }
}
Perform Speech Recognition for container
POST /containers/{id}/speech_recognition

Perform EXISTING media speech recognition for container and all its descendants, mark container as enabled for existing media speech recognition.

Requires Permission assigning Role CONTENT_UPDATER on the Container.

If parent container has already been enabled for EXISTING media recognition - return error: Feature SPEECH_RECOGNITION is not enabled on this tenant.

If process_existing_media parameter of Speech Recognition Config is not equal to BY_CONTAINER - return error Speech recognition config parameter process existing media by container must be set

Path variables

id
string required

container identifier

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/containers/876/speech_recognition HTTP/1.1 

HTTP/1.1 200 OK 
Home Container Configuration
GET /feature_configs/HOME_CONTAINER
PUT /feature_configs/HOME_CONTAINER
Viewing Home Container Configuration
GET /feature_configs/HOME_CONTAINER

Fetch Home Container configuration data.

Requires Permission assigning Role SUPERUSER on the root Container.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/feature_configs/HOME_CONTAINER HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "feature_config_home_container": {
        "id": "835816165564487141",
        "href": "https://localhost:8080/api/feature_configs/HOME_CONTAINER",
        "links": {
            "modified_by": {
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "HOME_CONTAINER_CONFIG_GET",
                    "href": "https://localhost:8080/api/feature_configs/HOME_CONTAINER",
                    "method": "GET"
                },
                {
                    "label": "HOME_CONTAINER_CONFIG_CREATE_OR_REPLACE",
                    "href": "https://localhost:8080/api/feature_configs/HOME_CONTAINER",
                    "method": "PUT"
                }
            ]
        },
        "created_at": "2017-02-27T04:57:31.290Z",
        "modified_at": "2017-02-27T04:57:31.290Z",
        "parent_container_id": 660036865360925971,
        "user_container_description": ""
    }
}
Creating or Replacing Home Container Configuration
PUT /feature_configs/HOME_CONTAINER

Delete existing Home Container configuration, if any, and create a new one.

Requires: a) Permission assigning Role SUPERUSER on the root Container; b) Permission assigning Role CONTENT_CREATOR_CONTAINERS, CONTENT_CREATOR or CONTENT_MANAGER; c) HOME_CONTAINER feature to be disabled.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/feature_configs/HOME_CONTAINER HTTP/1.1 

Content-Type: application/json

{
  "feature_config_home_container": {
    "parent_container_id": 835831118644123313
  }
}

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "feature_config_home_container": {
        "id": "835832533508691216",
        "href": "https://staging-101.kzoinnovations.com/api/feature_configs/HOME_CONTAINER",
        "links": {
            "modified_by": {
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "HOME_CONTAINER_CONFIG_GET",
                    "href": "https://staging-101.kzoinnovations.com/api/feature_configs/HOME_CONTAINER",
                    "method": "GET"
                },
                {
                    "label": "HOME_CONTAINER_CONFIG_CREATE_OR_REPLACE",
                    "href": "https://staging-101.kzoinnovations.com/api/feature_configs/HOME_CONTAINER",
                    "method": "PUT"
                }
            ]
        },
        "created_at": "2017-02-27T05:30:02.498Z",
        "modified_at": "2017-02-27T05:30:02.498Z",
        "parent_container_id": 835831118644123313,
        "user_container_description": ""
    }
}
PUT https://tenant.kzoplatform.com/api/feature_configs/HOME_CONTAINER HTTP/1.1 

Content-Type: application/json

{
  "feature_config_home_container": {
    "parent_container_id": 835831118644123313,
    "user_container_description": "Home container"
  }
}

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "feature_config_home_container": {
        "id": "835832533508691216",
        "href": "https://staging-101.kzoinnovations.com/api/feature_configs/HOME_CONTAINER",
        "links": {
            "modified_by": {
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "HOME_CONTAINER_CONFIG_GET",
                    "href": "https://staging-101.kzoinnovations.com/api/feature_configs/HOME_CONTAINER",
                    "method": "GET"
                },
                {
                    "label": "HOME_CONTAINER_CONFIG_CREATE_OR_REPLACE",
                    "href": "https://staging-101.kzoinnovations.com/api/feature_configs/HOME_CONTAINER",
                    "method": "PUT"
                }
            ]
        },
        "created_at": "2017-02-27T05:30:02.498Z",
        "modified_at": "2017-02-27T05:30:02.498Z",
        "parent_container_id": 835831118644123313,
        "user_container_description": "Home container"
    }
}
Event registrations

API for event registrations

POST /event_registrations
PUT /event_registrations/{id}
GET /event_registrations/{id}
DELETE /event_registrations/{id}
GET /event_registrations
Create event registration
POST /event_registrations

Creation algorithm:

  • makes sure registration_starts_at <= event_starts_at < event_ends_at, otherwise creates response with code 400, and message:“Condition check failed: registration_starts_at <= event_starts_at < event_ends_at”,
  • makes sure registration_ends_at <= event_ends_at, otherwise creates response with code 400, and message: “Condition check failed: registration_ends_at <= event_ends_at”,
  • creates ER,
  • creates a new Container under parent_container_id, with title & description copied from the request body,
  • creates a new Medium in that Container, with title & description copied from the request body,
  • creates a new Group, with name & description copied from the request body’s title & description, and label=FEATURE_EVENT_REGISTRATION, then creates Permissions CONTENT_VIEWER & COMMENTATOR for this Group on this Container.

EVENT_REGISTRATION feature must be enabled.

Required capabilities:

  • root container: MANAGE_TENANT, MANAGE_IDENTITIES
  • container which will hold newly created associated entities: CREATE_CONTENT_CONTAINERS

Request body

Object
event_registrations
Object
title
string

Title which will be used as description for associated entities, should be unique as newly created group name should be unique

Example:
a
description
string nullable

Description which will be used as description for associated entities

Example:
b
parent_container_id
string

Id of container where event registration associated entities should be created

Example:
123
registration_starts_at
string date-time
Pattern: yyyy-MM-dd'T'HH:mm:ss.SSS
Example:
2017-10-10T14:12:24.324Z
registration_ends_at
string date-time
Pattern: yyyy-MM-dd'T'HH:mm:ss.SSS
Example:
2017-10-21T14:12:24.324Z
event_starts_at
string date-time
Pattern: yyyy-MM-dd'T'HH:mm:ss.SSS
Example:
2017-10-17T14:12:24.324Z
event_ends_at
string date-time
Pattern: yyyy-MM-dd'T'HH:mm:ss.SSS
Example:
2017-10-24T14:12:24.324Z
embed_code
string nullable
show_comments
boolean nullable
allow_commenting
boolean nullable

Responses

201 Created
403 Forbidden

Action forbidden as there are no required user capabilities or feature EVENT_REGISTRATION is disabled.

400 Bad request

Passed date parameters don’t satisfy required conditions. See description.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Update event registration
PUT /event_registrations/{id}

Update algotithm:

  • makes sure that title and description were not changed, otherwise creates response with code 403, and message: “It’s not allowed to modify title or description of event registration. Recreate event registration if modification of title or description required”,
  • makes sure registration_starts_at <= event_starts_at < event_ends_at, otherwise creates response with code 400, and message:“Condition check failed: registration_starts_at <= event_starts_at < event_ends_at”,
  • makes sure registration_ends_at <= event_ends_at, otherwise creates response with code 400, and message: “Condition check failed: registration_ends_at <= event_ends_at”,
  • updates ER entity. This update doesn’t affect to associated entities

EVENT_REGISTRATION feature must be enabled.

Required capabilities:

  • root container: MANAGE_TENANT

Path variables

id
integer required

Request body

Object
event_registrations
Object
title
string

Title which will be used as description for associated entities, should be unique as newly created group name should be unique

Example:
a
description
string nullable

Description which will be used as description for associated entities

Example:
b
parent_container_id
string

Id of container where event registration associated entities should be created

Example:
123
registration_starts_at
string date-time
Pattern: yyyy-MM-dd'T'HH:mm:ss.SSS
Example:
2017-10-10T14:12:24.324Z
registration_ends_at
string date-time
Pattern: yyyy-MM-dd'T'HH:mm:ss.SSS
Example:
2017-10-21T14:12:24.324Z
event_starts_at
string date-time
Pattern: yyyy-MM-dd'T'HH:mm:ss.SSS
Example:
2017-10-17T14:12:24.324Z
event_ends_at
string date-time
Pattern: yyyy-MM-dd'T'HH:mm:ss.SSS
Example:
2017-10-24T14:12:24.324Z
embed_code
string nullable
show_comments
boolean nullable
allow_commenting
boolean nullable

Responses

200 OK
403 Forbidden

Action forbidden as there are no required user capabilities or feature EVENT_REGISTRATION is disabled.

400 Bad request

Passed date parameters don’t satisfy required conditions. See description.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Get event registration
GET /event_registrations/{id}

Fetches event registration and associated entities.

EVENT_REGISTRATION feature must be enabled.

Requires authenticated user.

Path variables

id
number required

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: users, containers, groups etc. Parameters are joined with comma.

Includes for media and medium can be substituted, so that media information would be included to the response no matter which of two includes was requested. Same logic is applied container and containers.

Example:
media,containers,created_by

Responses

200 OK
403 Forbidden

Action forbidden as there are no required user capabilities or feature EVENT_REGISTRATION is disabled.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Delete event registration
DELETE /event_registrations/{id}

Deletes event registration entity. Associated entities are not affected by this operation.

EVENT_REGISTRATION feature must be enabled.

Required capabilities:

root container: MANAGE_TENANT

Path variables

id
number required

Responses

204 No Content
403 Forbidden

Action forbidden as there are no required user capabilities or feature EVENT_REGISTRATION is disabled.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Get all event registrations
GET /event_registrations

Fetches all event registrations and associated entities. Event registrations will be ordered by id.

EVENT_REGISTRATION feature must be enabled.

Requires authenticated user.

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: users, containers, groups etc. Parameters are joined with comma.

Includes for media and medium can be substituted, so that media information would be included to the response no matter which of two includes was requested. Same logic is applied container and containers.

Example:
media,containers,created_by
page
number optional

The number of page (see Pagination).

Max: 2,147,483,647
Default:
1
page_size_primary
number optional

The maximum number of primary resources are to be returned (see Pagination).

Min: 1
Max: 2,147,483,647
Default:
20

Responses

200 OK
403 Forbidden

Action forbidden as there are no required user capabilities or feature EVENT_REGISTRATION is disabled.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Custom Authn Group Autoenroll Configurations

Feature CUSTOM_AUTHN_GROUP_AUTOENROLL allows to automatically add users to some groups after successful SSO depending on users’ attributes.

To enable such autoenrollment, enable feature CUSTOM_AUTHN_GROUP_AUTOENROLL using Replacing Platform Feature.

GET /feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL
GET /feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/{id}
POST /feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL
DELETE /feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/{id}
Viewing All Custom Authn Group Autoenroll Configurations
GET /feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL

Fetch all Custom Authn Group Autoenroll configuration records.

Requires Permission assigning Role SUPERUSER on the root Container.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "custom_authn_group_autoenroll_configs": [
        {
            "id": "841079223421507532",
            "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/841079223421507532",
            "links": {
                "modified_by": {
                },
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_GET",
                        "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/841079223421507532",
                        "method": "GET"
                    },
                    {
                        "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_GET_ALL",
                        "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL",
                        "method": "GET"
                    },
                    {
                        "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_CREATE",
                        "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL",
                        "method": "POST"
                    },
                    {
                        "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_DELETE",
                        "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/841079223421507532",
                        "method": "DELETE"
                    }
                ]
            },
            "created_at": "2017-03-06T11:14:16.679Z",
            "modified_at": "2017-03-06T11:14:16.679Z",
            "attribute_name": "Given Name",
            "attribute_value_regex": "Userone",
            "attribute_present": true,
            "custom_authn_option_id": "123",
            "group_id": "456"
        },
        {
            "id": "841085404676364240",
            "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/841085404676364240",
            "links": {
                "modified_by": {
                },
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_GET",
                        "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/841085404676364240",
                        "method": "GET"
                    },
                    {
                        "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_GET_ALL",
                        "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL",
                        "method": "GET"
                    },
                    {
                        "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_CREATE",
                        "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL",
                        "method": "POST"
                    },
                    {
                        "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_DELETE",
                        "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/841085404676364240",
                        "method": "DELETE"
                    }
                ]
            },
            "created_at": "2017-03-06T11:26:33.543Z",
            "modified_at": "2017-03-06T11:26:33.543Z",
            "attribute_name": "Given Name",
            "attribute_value_regex": "Userone2",
            "attribute_present": true,
            "custom_authn_option_id": "789",
            "group_id": "012"
        }
    ]
}
Viewing Custom Authn Group Autoenroll Configuration
GET /feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/{id}

Fetch a Custom Authn Group Autoenroll Configuration record with the given ID.

Requires Permission assigning Role SUPERUSER on the root Container.

Path variables

id
string required

The ID of the Custom Authn Group Autoenroll Configuration record

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/841083539846862798 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "custom_authn_group_autoenroll_configs": {
        "id": "841083539846862798",
        "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/841083539846862798",
        "links": {
            "modified_by": {
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_GET",
                    "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/841083539846862798",
                    "method": "GET"
                },
                {
                    "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_GET_ALL",
                    "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL",
                    "method": "GET"
                },
                {
                    "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_CREATE",
                    "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL",
                    "method": "POST"
                },
                {
                    "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_DELETE",
                    "href": "https://localhost:8080/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/841083539846862798",
                    "method": "DELETE"
                }
            ]
        },
        "created_at": "2017-03-06T11:22:51.230Z",
        "modified_at": "2017-03-06T11:22:51.230Z",
        "attribute_name": "Given Name",
        "attribute_value_regex": "Userone1",
        "attribute_present": true,
        "custom_authn_option_id": "123",
        "group_id": "456"
    }
}
Creating Custom Authn Group Autoenroll Configuration
POST /feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL

Creates a Custom Authn Group Autoenroll Configuration record.

Requires Permission assigning Role SUPERUSER on the root Container.

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL HTTP/1.1 

Content-Type: application/json

{
  "custom_authn_group_autoenroll_configs": {
    "attribute_name": "Given Name",
    "attribute_value_regex": "Userone1",
    "custom_authn_option_id": 771483000759129800,
    "attribute_present": true,
    "group_id": 785921380171388877
  }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "custom_authn_group_autoenroll_configs": {
        "id": "843216226552387346",
        "href": "https://adfs-test.kzoinnovations.com/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/843216226552387346",
        "links": {
            "modified_by": {
            },
            "created_by": {
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_GET",
                    "href": "https://adfs-test.kzoinnovations.com/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/843216226552387346",
                    "method": "GET"
                },
                {
                    "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_GET_ALL",
                    "href": "https://adfs-test.kzoinnovations.com/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL",
                    "method": "GET"
                },
                {
                    "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_CREATE",
                    "href": "https://adfs-test.kzoinnovations.com/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL",
                    "method": "POST"
                },
                {
                    "label": "CUSTOM_AUTHN_GROUP_AUTOENROLL_CONFIG_DELETE",
                    "href": "https://adfs-test.kzoinnovations.com/api/feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/843216226552387346",
                    "method": "DELETE"
                }
            ]
        },
        "created_at": "2017-03-09T10:00:07.302Z",
        "modified_at": "2017-03-09T10:00:07.302Z",
        "attribute_name": "Given Name",
        "attribute_value_regex": "Userone1",
        "attribute_present": true,
        "custom_authn_option_id": "123",
        "group_id": "456"
    }
}
Delete Custom Authn Group Autoenroll Configuration
DELETE /feature_configs/CUSTOM_AUTHN_GROUP_AUTOENROLL/{id}

Deletes the Custom Authn Group Autoenroll Configuration record with the given ID.

Requires Permission assigning Role SUPERUSER on the root Container.

Path variables

id
string required

The ID of the Custom Authn Group Autoenroll Configuration record

Scheduled Reports

Description of scheduled reports API

POST /api/report_schedules
GET /api/report_schedules/{id}
DELETE /api/report_schedules/{id}
GET /api/report_schedule/{id}/deactivate
GET /api/scheduled_reports/{id}
GET /api/report_schedules
GET /reports/scheduled_reports/{id}/audience_engagement_under_medium_by_chapters
Creating Report Schedule
POST /api/report_schedules

Creates Report Schedule for Medium or Container

Requires Permission assigning Role VIEWER on the Schedule’s Container or parent Container of Schedule’s Medium. Comments on some attributes:

  • repetitions: -1 for unlimited, or any positive number of report repetitions
  • reporting_interval: reporting interval in ISO8601-compliant duration format, e.g P1M for one month
  • retention_interval: is an ISO8601-compliant duration format: PnD, e.g., P3D means keep the report for 3 days since generated_at.
  • incremental_reporting = true For incremental reports the incremental_reporting_interval_starts_at should always be specified and this date would be used as a start date for all reports under schedule. So the report periods for incremental reports would be as follows: (incremental_reporting_interval_starts_at to first_report_computed_at), (incremental_reporting_interval_starts_at to first_report_computed_at + reporting_interval * 1), (incremental_reporting_interval_starts_at to first_report_computed_at + reporting_interval * 2),… (incremental_reporting_interval_starts_at to first_report_computed_at + reporting_interval * repetitions)
  • incremental_reporting = false For non incremental reports start date would be different for every generated report. So the report periods for non incremental reports would be as follows: (first_report_computed_at - reporting_interval to first_report_computed_at), (first_report_computed_at to first_report_computed_at + reporting_interval * 1), (first_report_computed_at + reporting_interval * 1 to first_report_computed_at + reporting_interval * 2),… (first_report_computed_at + reporting_interval * (repetitions - 1) to first_report_computed_at + reporting_interval * repetitions)
  • report_type, list of acceptable values:
    • MEDIA_VIEWED_UNDER_CONTAINER
    • COMMENTS_FOR_MEDIUM
    • AUDIENCE_ENGAGEMENT_UNDER_MEDIUM_BY_UNIFORM_BINS
    • AUDIENCE_ENGAGEMENT_UNDER_MEDIUM_BY_CHAPTERS
    • TENANT_STATISTICS
    • COMPLETION_UNDER_CONTAINER
    • CODELESS_REPORT

Request body

Object
report_schedules
Object
repetitions
integer

Number of report repetitions, may be -1 for unlimited number

Example:
3
name
string

Name of report schedule, must be unique across not deleted report schedules

Example:
Some Report Name
incremental_reporting
boolean

Boolean flag indicating incremantal (true) or non incremental (false) report schedule

Example:
true
first_report_computed_at
string

Date of first report computation

Example:
2020-01-20T05:00:00.000Z
report_type
string

Type of scheduled report

Example:
AUDIENCE_ENGAGEMENT_UNDER_MEDIUM_BY_UNIFORM_BINS
container_id
unknown nullable

Identifier of container the report schedule relates to, must be null if medium_id is defined

medium_id
string

Identifier of medium the report schedule relates to, must be null if container_id is defined

Example:
1265252086673577078
incremental_reporting_interval_starts_at
string
Example:
2019-05-13T00:00:00.000Z
reporting_interval
string

Reporting interval in ISO8601 compliant format

Example:
P1M
retention_interval
string

Generated report retention interval in ISO8601 compliant format

Example:
P1M
include_anonymous
boolean

Include anonymous users (only applicable to certain types of reports, including report types AUDIENCE_ENGAGEMENT_*)

Example:
true
include_non_anonymous
string

Include non anonymous users (only applicable to certain types of reports, including report types AUDIENCE_ENGAGEMENT_*)

Example:
true
recipients
Array of string

List of additional recipients usernames, they will recieve notifications on report generation along with the report schedule creator

Example:
["some_user1", "some_user2"]

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

The response is the same as that of the method Viewing Report Schedule.

POST https://tenant.kzoplatform.com/api/report_schedules
Content-Type: application/json
{
  "report_schedules": {
    "repetitions": 3,
    "name": "Some Report",
    "incremental_reporting": true,
    "first_report_computed_at": "2020-01-20T05:00:00.000Z",
    "report_type": "AUDIENCE_ENGAGEMENT_UNDER_MEDIUM_BY_UNIFORM_BINS",
    "container_id": null,
    "medium_id": "1265252086673577078",
    "incremental_reporting_interval_starts_at": "2019-05-13T00:00:00.000Z",
    "reporting_interval": "P1M",
    "retention_interval": "P2M"
  }
}

HTTP/1.1 201 Created
{
    "report_schedules": {
    "id": "1601951714615759966",
    "links": {
      "scheduled_reports": [
        "1601951714833863775"
      ],
      "created_by": {
        "type": "users",
        "username": "some_user"
      }
    },
    "meta": {
      "actions": [
        {
          "label": "REPORT_SCHEDULE_GET",
          "href": "https://tenant.kzoplatform.com/api/report_schedules/1601951714615759966",
          "method": "GET"
        },
        {
          "label": "REPORT_SCHEDULE_DELETE",
          "href": "https://tenant.kzoplatform.com/api/report_schedules/1601951714615759966",
          "method": "DELETE"
        },
        {
          "label": "REPORT_SCHEDULE_DEACTIVATE",
          "href": "https://tenant.kzoplatform.com/api/report_schedules/1601951714615759966/deactivate",
          "method": "POST"
        }
      ]
    },
    "created_at": "2020-01-20T06:32:05.792Z",
    "name": "Some Report",
    "first_report_computed_at": "2020-01-20T05:00:00.000Z",
    "repetitions": 3,
    "retention_interval": "P1M",
    "recipients": null,
    "feature": null,
    "reporting_interval": "P1M",
    "container_id": null,
    "medium_id": "1265252086673577078",
    "include_anonymous": true,
    "include_non_anonymous": true,
    "report_type": "AUDIENCE_ENGAGEMENT_UNDER_MEDIUM_BY_UNIFORM_BINS",
    "deactivated_at": null,
    "paused_at": null,
    "incremental_reporting": true,
    "incremental_reporting_interval_starts_at": "2019-05-13T00:00:00.000Z"
  },
  "linked": {
    "scheduled_reports": [
      {
        "id": "1601951714833863775",
        "meta": {
          "actions": [
            {
              "label": "SCHEDULED_REPORT_GET",
              "href": "https://tenant.kzoplatform.com/api/scheduled_reports/1601951714833863775",
              "method": "GET"
            }
          ]
        },
        "created_at": "2020-01-20T06:32:05.757Z",
        "report_schedule_id": "1601951714615759966",
        "reporting_interval_starts_at": "2019-05-13T00:00:00.000Z",
        "reporting_interval_ends_at": "2020-01-20T05:00:00.000Z",
        "status": "SCHEDULED",
        "updated_at": "2020-01-20T06:32:05.757Z",
        "generated_at": null,
        "to_be_deleted_at": null,
        "deleted_at": null
      }
    ],
    "users": [
      {
        ...
      }
    ]
  }
}
Viewing Report Schedule
GET /api/report_schedules/{id}

View information on given Report Schedule object.

Requires Permission assigning Role VIEWER on the parent Container of report Schedule’s Medium or report Schedule’s Container.

Path variables

id
string required

Request parameters

include
string optional

May be empty string or scheduled_reports. In latter case information on not deleted Report objects related to Report Schedule will be included.

Responses

200 OK
Body
Object
report_schedules
Array
Object
id
string

Report schedule identifier

Example:
1601951714615759966
created_at
string

Creation date

Example:
2020-01-20T06:32:05.792Z
name
string

Nam of report schedule

Example:
Some Name
first_report_computed_at
string

Date of first report computation

Example:
2020-01-20T05:00:00.000Z
repetitions
integer

Number of report generations repetitions, may be -1 if number is unlimited

Example:
3
retention_interval
string

Interval to retire generated reports

Example:
P1M
recipients
unknown nullable

List of additional recipients usernames, they will recieve notifications on report generation along with the report schedule creator

feature
unknown nullable

Name of reature, may not be blanked for report schedules that are automatically created when related feature is on

reporting_interval
string

Interval for report generation

Example:
P1M
container_id
unknown nullable

Identifier of container the report schedule relates to, must be null if medium_id is defined

medium_id
string

Identifier of medium the report schedule relates to, must be null if container_id is defined

Example:
1265252086673577078
include_anonymous
boolean

Include anonymous users (only applicable to certain types of reports, including AUDIENCE_ENGAGEMENT_*)

Example:
true
include_non_anonymous
boolean

Include non anonymous users (only applicable to certain types of reports, including AUDIENCE_ENGAGEMENT_*)

Example:
true
report_type
string

Type of scheduled report

Example:
AUDIENCE_ENGAGEMENT_UNDER_MEDIUM_BY_UNIFORM_BINS
deactivated_at
string

Date of report schedule deactivation

Example:
2020-01-20T07:05:00.822Z
paused_at
unknown nullable

Date of report schedule set to pause

incremental_reporting
boolean

Boolean flag indicating incremantal (true) or non incremental (false) report schedule

Example:
true
incremental_reporting_interval_starts_at
string

Start date for incremental reports, this parameter is null for non incremantal reports

Example:
2019-05-13T00:00:00.000Z
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/report_schedules/1601930939674399765 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "report_schedules": 
    {
      "id": "1601930939674399765",
      "links": {
        "deactivated_by": {
          "type": "users",
          "username": "system"
        },
        "recipients": [],
        "medium": "1265252086673577078",
        "created_by": {
          "type": "users",
          "username": "some_user"
        }
      },
      "meta": {
        "pagination": {},
        "actions": [
          {
            "label": "REPORT_SCHEDULE_GET",
            "href": "https://tenant.kzoplatform.com/api/report_schedules/1601930939674399765",
            "method": "GET"
          },
          {
            "label": "REPORT_SCHEDULE_DELETE",
            "href": "https://tenant.kzoplatform.com/api/report_schedules/1601930939674399765",
            "method": "DELETE"
          },
          {
            "label": "REPORT_SCHEDULE_ACTIVATE",
            "href": "https://tenant.kzoplatform.com/api/report_schedules/1601930939674399765/activate",
            "method": "POST"
          }
        ]
      },
      "created_at": "2020-01-20T05:50:49.226Z",
      "name": "Test2112_4",
      "first_report_computed_at": "2020-01-20T05:00:00.000Z",
      "repetitions": 1,
      "retention_interval": "P1M",
      "recipients": null,
      "feature": null,
      "reporting_interval": "P1M",
      "container_id": null,
      "medium_id": "1265252086673577078",
      "include_anonymous": true,
      "include_non_anonymous": true,
      "report_type": "AUDIENCE_ENGAGEMENT_UNDER_MEDIUM_BY_UNIFORM_BINS",
      "deactivated_at": "2020-01-20T06:05:00.799Z",
      "paused_at": null,
      "incremental_reporting": false,
      "incremental_reporting_interval_starts_at": null
    }
   ...
}
Deleting Report Schedule
DELETE /api/report_schedules/{id}

Hard deletes Report Schedule with all its Reports and their data.

Requires Permission assigning Role CONTENT_VIEWER on Report Schedule’s Container.

Path variables

id
string required

Responses

204 No Content
401 Unauthorized

The request requires Authentication and Authorization.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/report_schedules/1234 HTTP/1.1 
Deactivating Report Schedule
GET /api/report_schedule/{id}/deactivate

Deactivates report schedule, returns error if schedule is already deactivated.

Path variables

id
string required

Report Schedule identifier

Responses

204 No Content
400 Bad Request

Bad request parameters or Report Schedule is already deactivated

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/report_schedules/1234/deactivate HTTP/1.1 
Viewing Scheduled Report
GET /api/scheduled_reports/{id}

View information on given Scheduled Report object.

Requires Permission assigning Role VIEWER on Scheduled Report’s Container.

Path variables

id
string required

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/scheduled_reports/900045805879039534 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "scheduled_reports": {
        "created_at": "2017-05-26T19:50:21.054Z",
        "deleted_at": null,
        "generated_at": null,
        "href": "",
        "id": "900045805879039534",
        "links": {
            
        },
        "meta": {
            "actions": [
                {
                    "href": "https://localhost:8080/api/scheduled_reports/900045805879039534",
                    "label": "SCHEDULED_REPORT_GET",
                    "method": "GET"
                }
            ],
            "pagination": {
                
            },
            "state": {
                
            }
        },
        "report_schedule_id": 900045805820319277,
        "reporting_interval_ends_at": "2017-02-17T19:00:00Z",
        "reporting_interval_starts_at": "2017-02-15T19:00:00Z",
        "status": "SCHEDULED",
        "to_be_deleted_at": null,
        "updated_at": "2017-05-26T19:50:21.054Z"
    }
}
Searching Report Schedules
GET /api/report_schedules

Search for Report Schedules.

Request parameters

report_type
string optional

Type of Scheduled Report

container_id
number optional

Container identifier, exact match is assumed, i.e. no sub-hierarchies for containers

medium_id
number optional

Medium identifier, only container or medium identifier can be supplied at a time

include
string optional

May be empty string or scheduled_reports. In latter case information on not deleted Report objects related to Report Schedule will be included.

include_featured
boolean optional

Whether to include featured (automatically created) report schedules

Default:
false

Examples

GET https://tenant.kzoplatform.com/api/report_schedules?include=container,medium,recipients&include_featured=true&page_size_primary=1&page_size_related=24&sort=created_at+desc HTTP/1.1 

HTTP/1.1 200 OK 
Content-Type: application/json
{
  "report_schedules": {
    "id": "1601951714615759966",
    "href": "",
    "links": {
      "deactivated_by": {
        "type": "users",
        "username": "some_user"
      },
      "recipients": [],
      "medium": "1265252086673577078",
      "created_by": {
        "type": "users",
        "username": "some_user"
      }
    },
    "meta": {
      "pagination": {},
      "actions": [
        {
          "label": "REPORT_SCHEDULE_GET",
          "href": "https://tenant.kzoplatform.com/api/report_schedules/1601951714615759966",
          "method": "GET"
        },
        {
          "label": "REPORT_SCHEDULE_DELETE",
          "href": "https://tenant.kzoplatform.com/api/report_schedules/1601951714615759966",
          "method": "DELETE"
        },
        {
          "label": "REPORT_SCHEDULE_ACTIVATE",
          "href": "https://tenant.kzoplatform.com/api/report_schedules/1601951714615759966/activate",
          "method": "POST"
        }
      ]
    },
    "created_at": "2020-01-20T06:32:05.792Z",
    "name": "Test2112_7",
    "first_report_computed_at": "2020-01-20T05:00:00.000Z",
    "repetitions": 3,
    "retention_interval": "P1M",
    "recipients": null,
    "feature": null,
    "reporting_interval": "P1M",
    "container_id": null,
    "medium_id": "1265252086673577078",
    "include_anonymous": true,
    "include_non_anonymous": true,
    "report_type": "AUDIENCE_ENGAGEMENT_UNDER_MEDIUM_BY_UNIFORM_BINS",
    "deactivated_at": "2020-01-20T07:05:00.822Z",
    "paused_at": null,
    "incremental_reporting": true,
    "incremental_reporting_interval_starts_at": "2019-05-13T00:00:00.000Z"
  },
  "linked": {
    "medium": [
      {
        "id": "1265252086673577078",
        ...
      }
    ],
    "users": [
      {
        "id": "744905196152296449",
        "username": "some_user",
        ...
      },
      {
        "id": "1183413268392187116",
        "username": "test_user",
        ...
      }
    ]
  },
  "meta": {
    "pagination": {
      "total_results": 296,
      "links": {
        "next": "https://tenant.kzoplatform.com/api/report_schedules?page_size_primary=1&include=container%2Cmedium%2Crecipients&page_size_related=10000&page=2&sort=-created_at&include_featured=true",
        "2next": "https://tenant.kzoplatform.com/api/report_schedules?page_size_primary=1&include=container%2Cmedium%2Crecipients&page_size_related=10000&page=3&sort=-created_at&include_featured=true",
        "last": "https://tenant.kzoplatform.com/api/report_schedules?page_size_primary=1&include=container%2Cmedium%2Crecipients&page_size_related=10000&page=296&sort=-created_at&include_featured=true",
        "3next": "https://tenant.kzoplatform.com/api/report_schedules?page_size_primary=1&include=container%2Cmedium%2Crecipients&page_size_related=10000&page=4&sort=-created_at&include_featured=true",
        "first": "https://tenant.kzoplatform.com/api/report_schedules?page_size_primary=1&include=container%2Cmedium%2Crecipients&page_size_related=10000&page=1&sort=-created_at&include_featured=true"
      }
    }
  }
}
Viewing Audience Engagement Report By Chapters
GET /reports/scheduled_reports/{id}/audience_engagement_under_medium_by_chapters

View information on the given report.

Requires Permission assigning Role CONTENT_VIEWER on the root Container.

Path variables

id
string required

ID of the report

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/reports/scheduled_reports/123/audience_engagement_under_medium_by_chapters HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "audience_engagement_under_medium_by_chapters": [
        {
            "links": {
                "chapter": "456",
                "medium": "111",
                "audience_engagement_medium_collective": "222"
            },
            "id": "789",
            "start_msec": 0,
            "end_msec": 1000,
            "engagement_score": 1,
            "nonunique_viewed_time_msec": 5
        }
    ],
    "linked": {
        "chapters": {...},
        "media": {...},
        "audience_engagement_medium_collective": {
            "id": "222",
            "engagement_score": 10
        }
    }
}
OAuth2
OAuth2 Client Configurations
POST /api/oauth2_client_configurations
GET /api/oauth2_client_configurations
GET /api/oauth2_client_configurations/{id}
PUT /api/oauth2_client_configurations/{id}
DELETE /api/oauth2_client_configurations/{id}
Creating OAuth2 Client Configuration
POST /api/oauth2_client_configurations

Creates OAuth2 Client Configuration.

Multi-tenant OAuth2 Client Configuration automatically becomes available on all tenants. It can be created on the privileged tenant only.

Requires Permission assigning Role SUPERUSER on the root Container.

Request body

Object
oauth2_client_configurations
Object
name
string

Must be unique across tenant. If multi_tenant = true, it must be unique across all tenants.

authr_server_implementation
string

Which authorization server to use.

Enumeration:
GOOGLE
MICROSOFT_TENANT_APIV1
MICROSOFT_TENANT_APIV2
MICROSOFT_COMMON_APIV1
MICROSOFT_COMMON_APIV2
SFDC
CUSTOM

Abstract authorization server

Example:
GOOGLE
client_id
string

Unique identifier issued by the authorization server. See https://tools.ietf.org/html/rfc6749#section-2.2 for details.

Example:
test
client_secret
string

Secret string provided by the authorization server together with client_id. See https://tools.ietf.org/html/rfc6749#section-2.3.1 for details.

Example:
test
multi_tenant
boolean nullable

Whether this OAuth2 Client Configuration should be available on all tenants

Default:
false
clock_skew_max_sec
integer nullable

If an OAuth2 authorization token obtained for the current OAuth2 Client Configuration is expected to expire in given number of seconds or earlier, that token will be refreshed before being used.

Default:
60
Example:
60
server_discovery_uri
string nullable

URI to fetch OAuth server configuration. This parmeter is required for such server types as: CUSTOM,MICROSOFT_TENANT_APIV1, MICROSOFT_TENANT_APIV2. For other server types it will be calculated automatically.

Examples:
https://accounts.google.com/.well-known/openid-configuration (Google)https://login.microsoftonline.com/common/v2.0/.well-known/openid-configuration (Microsoft)https://login.salesforce.com/.well-known/openid-configuration

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/api/oauth2_client_configurations HTTP/1.1 

Content-Type: application/json

{
  "oauth2_client_configurations": {
    "name": "test",
    "authr_server_implementation": "GOOGLE",
    "client_id": "test",
    "client_secret": "test"
  }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
  "linked": {},
  "meta": {},
  "oauth2_client_configurations": {
    "id": "977903402900002448",
    "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
    "links": {},
    "meta": {
      "pagination": {},
      "actions": [
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_GET",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
          "method": "GET"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_GET_ALL",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
          "method": "GET"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_DELETE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
          "method": "DELETE"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_CREATE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
          "method": "POST"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_UPDATE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
          "method": "PUT"
        }
      ]
    },
    "created_at": "2017-09-11T05:59:29.893Z",
    "modified_at": "2017-09-11T05:59:29.893Z",
    "name": "test",
    "authr_server_implementation": "GOOGLE",
    "client_id": "test",
    "client_secret": "test",
    "multi_tenant": false,
    "clock_skew_max_sec": 60
  }
}
POST https://tenant.kzoplatform.com/api/api/oauth2_client_configurations HTTP/1.1 

Content-Type: application/json

{
    "oauth2_client_configurations": {
        "name": "test2",
        "authr_server_implementation": "GOOGLE",
        "client_id": "test2",
        "client_secret": "test2",
        "multi_tenant": "false",
        "clock_skew_max_sec": 60
    }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
  "linked": {},
  "meta": {},
  "oauth2_client_configurations": {
    "id": "977905879477130897",
    "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
    "links": {},
    "meta": {
      "pagination": {},
      "actions": [
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_GET",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
          "method": "GET"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_GET_ALL",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
          "method": "GET"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_DELETE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
          "method": "DELETE"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_CREATE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
          "method": "POST"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_UPDATE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
          "method": "PUT"
        }
      ]
    },
    "created_at": "2017-09-11T06:04:25.111Z",
    "modified_at": "2017-09-11T06:04:25.111Z",
    "name": "test2",
    "authr_server_implementation": "GOOGLE",
    "client_id": "test2",
    "client_secret": "test2",
    "multi_tenant": false,
    "clock_skew_max_sec": 60
  }
}
Viewing All OAuth2 Client Configurations
GET /api/oauth2_client_configurations

View information on all OAuth2 Client Configurations available on the current tenant:

  • non-multi-tenant ones created on the current tenant,
  • multi-tenant ones created on the privileged tenant.

They are also limited by the authorization server implementations available on the given installation.

Requires authenticated user. Exceptions: anonymous and system users - theese users aren’t allowed to perform this situation.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/api/oauth2_client_configurations HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "linked": {},
  "meta": {},
  "oauth2_client_configurations": [
    {
      "id": "977903402900002448",
      "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
      "links": {},
      "meta": {
        "pagination": {},
        "actions": [
          {
            "label": "OAUTH2_CLIENT_CONFIGURATION_GET",
            "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
            "method": "GET"
          },
          {
            "label": "OAUTH2_CLIENT_CONFIGURATION_GET_ALL",
            "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
            "method": "GET"
          },
          {
            "label": "OAUTH2_CLIENT_CONFIGURATION_DELETE",
            "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
            "method": "DELETE"
          },
          {
            "label": "OAUTH2_CLIENT_CONFIGURATION_CREATE",
            "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
            "method": "POST"
          },
          {
            "label": "OAUTH2_CLIENT_CONFIGURATION_UPDATE",
            "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
            "method": "PUT"
          }
        ]
      },
      "created_at": "2017-09-11T05:59:29.893Z",
      "modified_at": "2017-09-11T05:59:29.893Z",
      "name": "test",
      "authr_server_implementation": "GOOGLE",
      "client_id": "test",
      "client_secret": "test",
      "multi_tenant": false,
      "clock_skew_max_sec": 60
    },
    {
      "id": "977905879477130897",
      "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
      "links": {},
      "meta": {
        "pagination": {},
        "actions": [
          {
            "label": "OAUTH2_CLIENT_CONFIGURATION_GET",
            "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
            "method": "GET"
          },
          {
            "label": "OAUTH2_CLIENT_CONFIGURATION_GET_ALL",
            "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
            "method": "GET"
          },
          {
            "label": "OAUTH2_CLIENT_CONFIGURATION_DELETE",
            "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
            "method": "DELETE"
          },
          {
            "label": "OAUTH2_CLIENT_CONFIGURATION_CREATE",
            "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
            "method": "POST"
          },
          {
            "label": "OAUTH2_CLIENT_CONFIGURATION_UPDATE",
            "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
            "method": "PUT"
          }
        ]
      },
      "created_at": "2017-09-11T06:04:25.111Z",
      "modified_at": "2017-09-11T06:04:25.111Z",
      "name": "test2",
      "authr_server_implementation": "GOOGLE",
      "multi_tenant": false,
      "clock_skew_max_sec": 60
    }
  ]
}
Viewing OAuth2 Client Configuration
GET /api/oauth2_client_configurations/{id}

View information on the OAuth2 Client Configuration with the given ID.

It can be viewed if all the following conditions are met:

  • The OAuth2 Client Configuration is created on the current tenant, or it is multi-tenant and created on the privileged tenant.
  • The corresponding authorization server implementation is available on the current installation.

Requires Permission assigning Role SUPERUSER on the root Container.

Path variables

id
string required

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/api/oauth2_client_configurations/977903402900002448 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "linked": {},
  "meta": {},
  "oauth2_client_configurations": {
    "id": "977903402900002448",
    "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
    "links": {},
    "meta": {
      "pagination": {},
      "actions": [
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_GET",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
          "method": "GET"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_GET_ALL",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
          "method": "GET"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_DELETE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
          "method": "DELETE"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_CREATE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
          "method": "POST"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_UPDATE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977903402900002448",
          "method": "PUT"
        }
      ]
    },
    "created_at": "2017-09-11T05:59:29.893Z",
    "modified_at": "2017-09-11T05:59:29.893Z",
    "name": "test",
    "authr_server_implementation": "GOOGLE",
    "client_id": "test",
    "client_secret": "test",
    "multi_tenant": false,
    "clock_skew_max_sec": 60
  }
}
Updating OAuth2 Client Configuration
PUT /api/oauth2_client_configurations/{id}

Update attributes of OAuth2 Client Configuration with the given ID.

Multi-tenant OAuth2 Client Configurations can only be updated on the privileged tenant.

multi_tenant cannot be changed.

Requires Permission assigning Role SUPERUSER on the root Container.

Format of the request body is the same as when Creating OAuth2 Client Configuration. If an optional attribute is omitted, it won’t be changed.

Path variables

id
string required

Responses

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/api/oauth2_client_configurations/977905879477130897 HTTP/1.1 

Content-Type: application/json

{
    "oauth2_client_configurations": {
        "name": "test2",
        "authr_server_implementation": "GOOGLE",
        "client_id": "test2",
        "client_secret": "test2",
        "multi_tenant": "false",
        "clock_skew_max_sec": 60
    }
}

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "linked": {},
  "meta": {},
  "oauth2_client_configurations": {
    "id": "977905879477130897",
    "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
    "links": {},
    "meta": {
      "pagination": {},
      "actions": [
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_GET",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
          "method": "GET"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_GET_ALL",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
          "method": "GET"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_DELETE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
          "method": "DELETE"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_CREATE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations",
          "method": "POST"
        },
        {
          "label": "OAUTH2_CLIENT_CONFIGURATION_UPDATE",
          "href": "https://staging-101.kzoinnovations.com/api/oauth2_client_configurations/977905879477130897",
          "method": "PUT"
        }
      ]
    },
    "created_at": "2017-09-11T06:04:25.111Z",
    "modified_at": "2017-09-11T06:26:57.333Z",
    "name": "test2",
    "authr_server_implementation": "GOOGLE",
    "client_id": "test2",
    "client_secret": "test2",
    "multi_tenant": false,
    "clock_skew_max_sec": 60
  }
}
Deleting OAuth2 Client Configuration
DELETE /api/oauth2_client_configurations/{id}

Delete OAuth2 Client Configuration with the given ID.

Multi-tenant OAuth2 Client Configurations can only be deleted on the privileged tenant.

Requires Permission assigning Role SUPERUSER on the root Container.

Path variables

id
string required

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/api/oauth2_client_configurations/977905879477130897 HTTP/1.1 

HTTP/1.1 204 No Content 
Authorization
GET /misc/oauth2/oauth2_authorizations/create
GET /misc/oauth2/redirect
Initiate OAuth2 token obtaining
GET /misc/oauth2/oauth2_authorizations/create

Initiates the process of OAuth2 access token obtaining. OAuth2 authorization code flow is used here - using passed OAuth2 client configuration this endpoint redirects user to the OAuth2 authorization server to obtain authorization code. In case of errors - user will be redirected to the URL passed as location QSP value, error description and code will be passed as JSON via error QSP. In case of success location QSP value will be used to redirect user after OAuth2 token obtaining.
Typical use case of such method - obtaining tokens to send mail from personal accounts. So this is not usual authorization and to call this method user has to be authenticated.

Request parameters

oauth2_client_configuration_id
number required

Id of the client configuration to be used.

authr_purpose
string required

Purpose of authorization code obtaining. Now USERS_EMAIL_RELAY is the only supported value.

location
string required

URL which will be used for redirects. In case of errors and when authotization token will be finally obtained.

Accept OAuth2 authorization code
GET /misc/oauth2/redirect

Authentication

Open

Accepts OAuth2 authorization code to exhange it on access and refresh tokens using presaved token endpoints of authorization servers. This endpoint should be registered on authorization servers.

No authentication required for this endpoint.

Request parameters

state
string optional

This QSP used as container to pass user session related data e.g tenant, token entity id etc.

code
string optional

OAuth2 authorization code

UserInfo

Authentication using OAuth and specific endpoint to retrieve information about user. Now all popular identity providers like Google, Office 365, Salesforce has support of OIDC and specific endpoints to retrieve user information (e.g https://www.googleapis.com/oauth2/v3/userinfo for Google). We can use such endpoints without OIDC.

Configuration

Configuration to enable support of OAuth authorization. Here endpoints and attributes that are returned from remote userinfo endpoint are specified. Only one configuration is allowed for tenant.

POST /api/feature_configs/OAUTH2_USERINFO/
PUT /api/feature_configs/OAUTH2_USERINFO
GET /api/feature_configs/OAUTH2_USERINFO
GET /api/feature_configs/OAUTH2_USERINFO
Create configuration
POST /api/feature_configs/OAUTH2_USERINFO/

Authentication

Creates new configuration for authentication. Configuration extends the custom authentication option entity and related tables, so some properties of CAO are inherited. Only one configuration is allowed for tenant. There is no sharing of configurations as we have for OAuth2 or OIDC.

Request body

Object
feature_config_oauth2_userinfo
Object
scope
string required

scope required to obtain authorization code and so the access token which will be used for user information obtaining.

Example:
profile email
userinfo_endpoint
string required

Userinfo endpoint. URL to obtain information about user: login, first name, last name, email etc. using access token. This URL should be available via HTTP GET

Example:
https://www.googleapis.com/oauth2/v3/userinfo
authorization_endpoint
string required

Endpoint to request authorization code in OAuth2 terminology.

Example:
https://accounts.google.com/o/oauth2/v2/auth
token_endpoint
string required

Endpoint to request OAuth2 access tokens using authorization code obtained on previous step.

Example:
https://www.googleapis.com/oauth2/v4/token
username_attr
string required

When we obtain response from the userinfo_endpoint we obtain JSON with the properties whcih mean some personal data attributes of the end user. username_attr is the attribute to define user login on our side.

Example:
sub
first_name_attr
string required

When we obtain response from the userinfo_endpoint we obtain JSON with the properties whcih mean some personal data attributes of the end user. first_name_attr is the attribute to define first name of the user on our side.

Example:
given_name
last_name_attr
string required

When we obtain response from the userinfo_endpoint we obtain JSON with the properties whcih mean some personal data attributes of the end user. last_name_attr is the attribute to define last name of the user on our side.

Example:
family_name
email_attr
string required

When we obtain response from the userinfo_endpoint we obtain JSON with the properties whcih mean some personal data attributes of the end user. email_attr is the attribute to define email of the user on our side.

Example:
email
name
string required

Name of the config as the custom authentication option

Example:
OAuth2_userinfo
is_default
boolean required

Whether this custom authentication option is default for tenant

Example:
false
autoenroll_group_id
number nullable

Id of the group to enroll all users with current authenit

Example:
123456
oauth2_client_configuration_id
string

Id of OAuth client configuration

Example:
12345874
use_bearer
boolean

Flag: if set then request to userinfo endpoint will have the following value of Authorization header: Bearer <access_toke_value> - this is required for most servers: Google, Microsoft etc. Some servers require that Authorization header’s value must be equal to <access_token_value> only. -Now word “Bearer” or something else. In this case use_bearer must be false (default value)

Default:
false

Examples

curl -i -X POST \
   -H "X-KZO-Pipeline-Action:Process" \
   -H "X-KZO-Auth-Username:admin" \
   -H "X-KZO-Accept-API-Versions:1" \
   -H "X-KZO-Auth-AccessKey:fece30008f6f4261b863bbbe439960e4" \
   -H "Content-Type:application/vnd.api+json" \
   -d \
'{
  "feature_config_oauth2_userinfo":{
    "scope":"profile email",
    
    "userinfo_endpoint":"https://www.googleapis.com/oauth2/v3/userinfo",
    "token_endpoint": "https://www.googleapis.com/oauth2/v4/token",
    "authorization_endpoint": "https://accounts.google.com/o/oauth2/v2/auth",
    "user_bearer":true,
    "username_attr":"sub",
    "first_name_attr":"given_name",
    "last_name_attr":"family_name",
    "email_attr":"email",
    "name":"oauth2_example",
    "is_default":"false"    
  }
}' \
 'https://oauth2-test.kzoinnovations.com/api/feature_configs/OAUTH2_USERINFO/980960792113321144'
Update configuration
PUT /api/feature_configs/OAUTH2_USERINFO

Authentication

Updates the OAuth2 userinfo configuration. As only one confiruation allowed no path variables are required.

Request body

Examples

curl -i -X PUT \
   -H "X-KZO-Pipeline-Action:Process" \
   -H "X-KZO-Auth-Username:admin" \
   -H "X-KZO-Accept-API-Versions:1" \
   -H "X-KZO-Auth-AccessKey:fece30008f6f4261b863bbbe439960e4" \
   -H "Content-Type:application/vnd.api+json" \
   -d \
'{
  "feature_config_oauth2_userinfo":{
    "scope":"profile email",
    
    "userinfo_endpoint":"https://www.googleapis.com/oauth2/v3/userinfo",
    "token_endpoint": "https://www.googleapis.com/oauth2/v4/token",
    "authorization_endpoint": "https://accounts.google.com/o/oauth2/v2/auth",
    
    "username_attr":"sub",
    "first_name_attr":"family_name",
    "last_name_attr":"family_name",
    "email_attr":"email",
    "name":"oauth2_example",
    "is_default":"false"    
  }
}' \
 'https://oauth2-test.kzoinnovations.com/api/feature_configs/OAUTH2_USERINFO'
feature_config_oauth2_userinfo

Main parameters of oauth2_userinfo feature config

Object
feature_config_oauth2_userinfo
Object
scope
string required

scope required to obtain authorization code and so the access token which will be used for user information obtaining.

Example:
profile email
userinfo_endpoint
string required

Userinfo endpoint. URL to obtain information about user: login, first name, last name, email etc. using access token. This URL should be available via HTTP GET

Example:
https://www.googleapis.com/oauth2/v3/userinfo
authorization_endpoint
string required

Endpoint to request authorization code in OAuth2 terminology.

Example:
https://accounts.google.com/o/oauth2/v2/auth
token_endpoint
string required

Endpoint to request OAuth2 access tokens using authorization code obtained on previous step.

Example:
https://www.googleapis.com/oauth2/v4/token
username_attr
string required

When we obtain response from the userinfo_endpoint we obtain JSON with the properties whcih mean some personal data attributes of the end user. username_attr is the attribute to define user login on our side.

Example:
sub
first_name_attr
string required

When we obtain response from the userinfo_endpoint we obtain JSON with the properties whcih mean some personal data attributes of the end user. first_name_attr is the attribute to define first name of the user on our side.

Example:
given_name
last_name_attr
string required

When we obtain response from the userinfo_endpoint we obtain JSON with the properties whcih mean some personal data attributes of the end user. last_name_attr is the attribute to define last name of the user on our side.

Example:
family_name
email_attr
string required

When we obtain response from the userinfo_endpoint we obtain JSON with the properties whcih mean some personal data attributes of the end user. email_attr is the attribute to define email of the user on our side.

Example:
email
name
string required

Name of the config as the custom authentication option

Example:
OAuth2_userinfo
is_default
boolean required

Whether this custom authentication option is default for tenant

Example:
false
autoenroll_group_id
number nullable

Id of the group to enroll all users with current authenit

Example:
123456
oauth2_client_configuration_id
string required

Id of OAuth client configuration

Example:
17856954
use_bearer
boolean

Flag: if set then request to userinfo endpoint will have the following value of Authorization header: Bearer <access_toke_value> - this is required for most servers: Google, Microsoft etc. Some servers require that Authorization header’s value must be equal to <access_token_value> only. -Now word “Bearer” or something else. In this case use_bearer must be false (default value)

Default:
false
Get configuration
GET /api/feature_configs/OAUTH2_USERINFO

Gets current configuration for tenant. It can be only one. If there is no configuration - 404 will be returned.

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: users, containers, groups etc. Parameters are joined with comma.

Includes for media and medium can be substituted, so that media information would be included to the response no matter which of two includes was requested. Same logic is applied container and containers.

Example:
media,containers,created_by

Responses

200 OK
404 Not Found

If there is no current configuration

403 Forbidden

If user doesn’t has MANAGE_TENANT capability

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/api/feature_configs/OAUTH2_USERINFO?include=created_by,oauth2_client_configurations, modified_by HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
        "oauth2_client_configurations": [
            {
                "id": "980960792113321144",
                "href": "https://oauth2-test.kzoinnovations.com/api/oauth2_client_configurations/980960792113321144",
                "links": {
                },
                "meta": {
                    "pagination": {
                    },
                    "actions": [
                        {
                            "label": "OAUTH2_CLIENT_CONFIGURATION_GET",
                            "href": "https://oauth2-test.kzoinnovations.com/api/oauth2_client_configurations/980960792113321144",
                            "method": "GET"
                        },
                        {
                            "label": "OAUTH2_CLIENT_CONFIGURATION_GET_ALL",
                            "href": "https://oauth2-test.kzoinnovations.com/api/oauth2_client_configurations",
                            "method": "GET"
                        },
                        {
                            "label": "OAUTH2_CLIENT_CONFIGURATION_DELETE",
                            "href": "https://oauth2-test.kzoinnovations.com/api/oauth2_client_configurations/980960792113321144",
                            "method": "DELETE"
                        },
                        {
                            "label": "OAUTH2_CLIENT_CONFIGURATION_CREATE",
                            "href": "https://oauth2-test.kzoinnovations.com/api/oauth2_client_configurations",
                            "method": "POST"
                        },
                        {
                            "label": "OAUTH2_CLIENT_CONFIGURATION_UPDATE",
                            "href": "https://oauth2-test.kzoinnovations.com/api/oauth2_client_configurations/980960792113321144",
                            "method": "PUT"
                        },
                        {
                            "label": "OAUTH2_AUTHORIZATION_USERS_EMAIL_RELAY_CREATE",
                            "href": "https://oauth2-test.kzoinnovations.com/misc/oauth2/oauth2_authorizations/create?oauth2_client_configuration_id=980960792113321144&authr_purpose=USERS_EMAIL_RELAY",
                            "method": "GET"
                        }
                    ]
                },
                "created_at": "2017-09-15T11:13:59.106Z",
                "modified_at": "2017-09-15T11:13:59.106Z",
                "name": "google",
                "authr_server_implementation": "GOOGLE",
                "multi_tenant": false,
                "clock_skew_max_sec": 300
            }
        ],
        "users": [
            {
                "id": "975307276808098818",
                "href": "https://oauth2-test.kzoinnovations.com/api/users/admin?page_size_related=10000",
                "links": {
                    "modified_by": {
                    },
                    "home_container": {
                    },
                    "deleted_by": {
                    },
                    "groups": [
                    ],
                    "created_by": {
                    },
                    "avatars": ""
                },
                "meta": {
                    "pagination": {
                    },
                    "state": {
                    },
                    "actions": [
                        {
                            "label": "USER_GET",
                            "href": "https://oauth2-test.kzoinnovations.com/api/users/admin?page_size_related=10000",
                            "method": "GET"
                        },
                        {
                            "label": "USER_GET_ALL",
                            "href": "https://oauth2-test.kzoinnovations.com/api/users?page_size_primary=2147483647&page_size_related=10000&page=1",
                            "method": "GET"
                        },
                        {
                            "label": "USER_UPDATE",
                            "href": "https://oauth2-test.kzoinnovations.com/api/users/admin",
                            "method": "PUT"
                        },
                        {
                            "label": "USER_EDIT_METADATA",
                            "href": "https://oauth2-test.kzoinnovations.com/api/users/admin",
                            "method": "PATCH"
                        },
                        {
                            "label": "USER_CREATE",
                            "href": "https://oauth2-test.kzoinnovations.com/api/users",
                            "method": "POST"
                        }
                    ]
                },
                "created_at": "2017-09-07T16:01:26.528Z",
                "modified_at": "2017-09-07T16:01:26.528Z",
                "deleted_at": null,
                "first_name": "admin",
                "last_name": "admin",
                "username": "admin",
                "email": "admin@kzotest.com",
                "authentication_type": "PASSWORD",
                "avatar_href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo2289/AVATAR/980790940039910574.png?Expires=1519761789&Signature=HZB2sTDf~ToRJb17KLeffalLa9VKXoKq2ii16lq0xB314IN4VG7MNm8qvbtdwtFv8M4KJF4S5gHVgsRZqOVplpxSc8gVghNWKg6lolQbIDfVeQD9-jZZ~V41NhbaW40lBQEWXvHpq2u9JNpL7bNhikQPt5Ey~ypK~WRWoU8VcX5zPlWDSevDSUKw9Hpo6iPn1AhOuxcHn0hYXQxHpO40Cw1DXVVmdhdUoJArBxnWaeHVUBNFSNG8cUEhejmPfpwt2TvHWv98KI7CZ1jTCF9jbEZVK1M4E57gYJ-o8E54c3aVP-JYiWpCpLSKVjHJ5HXJE6zBrj-XxmxhpDL8MIqnPw__&Key-Pair-Id=APKAI3Y7W2IRT5A2ADMA",
                "custom_authn_option_id": null
            }
        ]
    },
    "meta": {
    },
    "feature_config_oauth2_userinfo": {
        "id": "1096468514849428651",
        "href": "",
        "links": {
            "oauth2_client_configurations": "980960792113321144",
            "modified_by": {
                "type": "users",
                "username": "admin"
            },
            "created_by": {
                "type": "users",
                "username": "admin"
            }
        },
        "meta": {
            "pagination": {
            },
            "actions": [
                {
                    "label": "OAUTH2_USERINFO_CONFIG_GET",
                    "href": "https://oauth2-test.kzoinnovations.com/api/feature_configs/OAUTH2_USERINFO",
                    "method": "GET"
                },
                {
                    "label": "OAUTH2_USERINFO_CONFIG_REPLACE",
                    "href": "https://oauth2-test.kzoinnovations.com/api/feature_configs/OAUTH2_USERINFO",
                    "method": "PUT"
                },
                {
                    "label": "OAUTH2_USERINFO_CONFIG_DELETE",
                    "href": "https://oauth2-test.kzoinnovations.com/api/feature_configs/OAUTH2_USERINFO",
                    "method": "DELETE"
                }
            ]
        },
        "created_at": "2018-02-21T20:07:12.663Z",
        "modified_at": "2018-02-21T20:07:12.663Z",
        "name": "geoaxis1",
        "autoenroll_group_id": null,
        "scope": "profile email",
        "userinfo_endpoint": "https://www.googleapis.com/oauth2/v3/userinfo",
        "username_attr": "sub",
        "first_name_attr": "given_name",
        "last_name_attr": "family_name",
        "email_attr": "email",
        "authorization_endpoint": "https://accounts.google.com/o/oauth2/v2/auth",
        "token_endpoint": "https://www.googleapis.com/oauth2/v4/token",
        "is_default": false,
        "use_bearer":true
    }
}
Delete configuration
GET /api/feature_configs/OAUTH2_USERINFO

Authentication

Deletes current configuration for tenant

Responses

200 OK
401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

OAuth2 Authorization

Methods required for authorization using OAuth2 userinfo.

GET /misc/custom_auth/oauth2_userinfo/login
Initiate authorization
GET /misc/custom_auth/oauth2_userinfo/login

Authentication

Open

Initiates the authorization using OAuth2 tokens. Builds the request to the identity provider to redirect the user for authorization code obtaining.

Request parameters

custom_authn_option_id
string required

Id of the OAuth2 userinfo config

browser_session_id
string optional

Id of the browser session for synchronization and definition of final location to redirect the user to

location
string optional

Location to redirect the user to. If browser_session_id is specified

Responses

302 Found
Headers

The URL to redirect the user for authorization code obtaining

Location
string optional

Contains the URI of the newly created resource.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

OIDC Feature Configurations

An OIDC Feature Configuration describes whether multi-tenant OIDC configurations are enabled on the current tenant.

One and only one OIDC Feature Configuration exists on each tenant.

GET /api/oidc_rp_configurations
GET /api/oidc_rp_configurations/{id}
POST /oidc_rp_configurations
DELETE /oidc_rp_configurations/{id}
PUT /oidc_rp_configurations/{id}
Viewing available OIDC configurations
GET /api/oidc_rp_configurations

View all available OIDC configurations, i.e. all local ones plus all multi-tenant ones, limited by OIDC feature config and by the implementations available on the given installation.

Requires Permission assigning Role SUPERUSER on the root Container.

Examples

GET https://tenant.kzoplatform.com/api/api/oidc_rp_configurations HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "oidc_rp_configurations": [
        {
            "autoenroll_group_id": null,
            "autoenroll_group_label": "SUPPORT",
            "created_at": "2018-03-14T08:29:59.423Z",
            "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1111337882510955806",
            "id": "1111337882510955806",
            "is_default": false,
            "links": {
            },
            "meta": {
                "actions": [
                    {
                        "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1111337882510955806",
                        "label": "OIDC_RP_CONFIGURATION_GET",
                        "method": "GET"
                    },
                    {
                        "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations",
                        "label": "OIDC_RP_CONFIGURATION_CREATE",
                        "method": "POST"
                    },
                    {
                        "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations",
                        "label": "OIDC_RP_CONFIGURATION_GET_ALL",
                        "method": "GET"
                    },
                    {
                        "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1111337882510955806",
                        "label": "OIDC_RP_CONFIGURATION_UPDATE",
                        "method": "PUT"
                    },
                    {
                        "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1111337882510955806",
                        "label": "OIDC_RP_CONFIGURATION_DELETE",
                        "method": "DELETE"
                    }
                ],
                "pagination": {
                    
                }
            },
            "modified_at": "2018-03-14T08:29:59.423Z",
            "name": "rp_config_name",
            "oauth2_client_configuration_id": 1111337138659530011,
            "oauth2_client_configuration_name": "some_client_config_name",
            "op_tenant": "kzoinnovations.com"
        }
    ],
    "linked": {
    },
    "meta": {
    }
}
Viewing OIDC configuration
GET /api/oidc_rp_configurations/{id}

View the specific OIDC configuration if available, limited by OIDC feature config and by the implementations available on the given installation.

Requires Permission assigning Role SUPERUSER on the root Container.

Path variables

id
number required

relying party configuration identifier

Examples

GET https://tenant.kzoplatform.com/api/oidc_rp_configurations/1111337882510955806 HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "oidc_rp_configurations": {
            "autoenroll_group_id": null,
            "autoenroll_group_label": "SUPPORT",
            "created_at": "2018-03-14T08:29:59.423Z",
            "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1111337882510955806",
            "id": "1111337882510955806",
            "is_default": false,
            "links": {
            },
            "meta": {
                "actions": [
                    {
                        "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1111337882510955806",
                        "label": "OIDC_RP_CONFIGURATION_GET",
                        "method": "GET"
                    },
                    {
                        "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations",
                        "label": "OIDC_RP_CONFIGURATION_CREATE",
                        "method": "POST"
                    },
                    {
                        "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations",
                        "label": "OIDC_RP_CONFIGURATION_GET_ALL",
                        "method": "GET"
                    },
                    {
                        "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1111337882510955806",
                        "label": "OIDC_RP_CONFIGURATION_UPDATE",
                        "method": "PUT"
                    },
                    {
                        "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1111337882510955806",
                        "label": "OIDC_RP_CONFIGURATION_DELETE",
                        "method": "DELETE"
                    }
                ],
                "pagination": {
                    
                }
            },
            "modified_at": "2018-03-14T08:29:59.423Z",
            "name": "rp_config_name",
            "oauth2_client_configuration_id": 1111337138659530011,
            "oauth2_client_configuration_name": "some_client_config_name",
            "op_tenant": "kzoinnovations.com"
    },
    "linked": {
    },
    "meta": {
    }
}
Creating OIDC configuration
POST /oidc_rp_configurations

Authentication

Creates new configuration for OIDC authentication. Configuration extends the custom authentication option entity and related tables, so some properties of CAO are inherited.

Multi-tenant OIDC Configuration automatically becomes available on all tenants. It can be only created on the privileged tenant.

Requires Permission assigning Role SUPERUSER on the root Container.

Request body

Object
oidc_rp_configurations
Object
name
string required

Name of the config as the custom authentication option

Example:
some_oidc_config_name
is_default
boolean required

Whether this custom authentication option is default for tenant

Example:
false
autoenroll_group_id
number nullable

Id of the group to enroll users automatically

Example:
123456
autoenroll_group_label
string

Group label name to enroll users automatically

Example:
SUPPORT
oauth2_client_configuration_id
number

Identifier of OAuth2 client configuration

op_tenant
string

Organization specific for this configuration

Example:
kzoinnovations.com
tenant_claim_name
string nullable

Name of the claim to fetch the organization name from JWT token. If empty - tenant claim will be calculated from related OAuth server.

Examples:
tid (OFFICE_365)hd (GOOGLE)
additional_scopes
Array of string

Array of scopes which will be used in authorization endpoint beside the service openid

Example:
profile, email
ordered_claims
Array of string

Array of claims to be ordered from authorization server in JWT

Example:
organization_id

Examples

POST https://tenant.kzoplatform.com/api/oidc_rp_configurations HTTP/1.1 

Content-Type: application/json

{
    "oidc_rp_configurations": {
        "name": "some_oidc_config_name",
        "is_default": "false",
        "autoenroll_group_id": 123456,
        "autoenroll_group_label": null,
        "oauth2_client_configuration_id": 1122099855984956952,
        "op_tenant": "kzoinnovations.com"
    }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "linked": {
        
    },
    "meta": {
        
    },
    "oauth2_client_configurations": {
        "authr_server_implementation": "GOOGLE",
        "client_id": "123",
        "client_secret": "456",
        "clock_skew_max_sec": 60,
        "created_at": "2018-03-29T04:52:06.636Z",
        "href": "https://tenant.kzoplatform.com/api/oauth2_client_configurations/1122099855984956952",
        "id": "1122099855984956952",
        "links": {
            
        },
        "meta": {
            "actions": [
                {
                    "href": "https://tenant.kzoplatform.com/api/oauth2_client_configurations/1122099855984956952",
                    "label": "OAUTH2_CLIENT_CONFIGURATION_GET",
                    "method": "GET"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/oauth2_client_configurations",
                    "label": "OAUTH2_CLIENT_CONFIGURATION_GET_ALL",
                    "method": "GET"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/oauth2_client_configurations/1122099855984956952",
                    "label": "OAUTH2_CLIENT_CONFIGURATION_DELETE",
                    "method": "DELETE"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/oauth2_client_configurations",
                    "label": "OAUTH2_CLIENT_CONFIGURATION_CREATE",
                    "method": "POST"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/oauth2_client_configurations/1122099855984956952",
                    "label": "OAUTH2_CLIENT_CONFIGURATION_UPDATE",
                    "method": "PUT"
                },
                {
                    "href": "https://tenant.kzoplatform.com/misc/oauth2/oauth2_authorizations/create?oauth2_client_configuration_id=1122099855984956952&authr_purpose=USERS_EMAIL_RELAY",
                    "label": "OAUTH2_AUTHORIZATION_USERS_EMAIL_RELAY_CREATE",
                    "method": "GET"
                }
            ],
            "pagination": {
                
            }
        },
        "modified_at": "2018-03-29T04:52:06.636Z",
        "multi_tenant": true,
        "name": "some_cli_cfg_name_a5186fe9-0618-472c-9095-ad2df2702d69",
        "server_discovery_uri": null
    }
}
{
    "linked": {
        
    },
    "meta": {
        
    },
    "oidc_rp_configurations": {
        "autoenroll_group_id": 123456,
        "autoenroll_group_label": null,
        "created_at": "2018-03-29T04:52:06.933Z",
        "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1122099858476373529",
        "id": "1122099858476373529",
        "is_default": false,
        "links": {
            
        },
        "meta": {
            "actions": [
                {
                    "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1122099858476373529",
                    "label": "OIDC_RP_CONFIGURATION_GET",
                    "method": "GET"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations",
                    "label": "OIDC_RP_CONFIGURATION_CREATE",
                    "method": "POST"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations",
                    "label": "OIDC_RP_CONFIGURATION_GET_ALL",
                    "method": "GET"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1122099858476373529",
                    "label": "OIDC_RP_CONFIGURATION_UPDATE",
                    "method": "PUT"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1122099858476373529",
                    "label": "OIDC_RP_CONFIGURATION_DELETE",
                    "method": "DELETE"
                }
            ],
            "pagination": {
                
            }
        },
        "modified_at": "2018-03-29T04:52:08.809Z",
        "name": "some_oidc_config_name",
        "oauth2_client_configuration_id": 1122099855984956952,
        "oauth2_client_configuration_name": "some_cli_cfg_name_a5186fe9-0618-472c-9095-ad2df2702d69",
        "op_tenant": "kzoinnovations.com"
    }
}
Delete OIDC configuration
DELETE /oidc_rp_configurations/{id}

Delete OIDC Configuration with the given ID.

Multi-tenant OIDC Configurations can only be deleted on the privileged tenant.

Requires Permission assigning Role SUPERUSER on the root Container.

Path variables

id
number required

Examples

DELETE https://tenant.kzoplatform.com/api/oidc_rp_configurations/1234 HTTP/1.1 

HTTP/1.1 204 No Content 
Updating OIDC Configuration
PUT /oidc_rp_configurations/{id}

Update attributes of OIDC Configuration with the given ID.

Multi-tenant OIDC Configurations can only be updated on the privileged tenant.

oauth2_client_configuration_id cannot be changed. autoenroll_group_label, name, op_tenant cannot be changed for multitenant configurations.

Requires Permission assigning Role SUPERUSER on the root Container.

Format of the request body is the same as when Creating OIDC Configuration.

Path variables

id
number required

Examples

PUT https://tenant.kzoplatform.com/api/oidc_rp_configurations/1122114385381168673 HTTP/1.1 

Content-Type: application/json

{
  "oidc_rp_configurations": {
    "autoenroll_group_id": null,
    "autoenroll_group_label": "SUPPORT",
    "name": "some_cfg_name_1522300857553",
    "oauth2_client_configuration_id": 1122114383997048352,
    "op_tenant": "kzoinnovations.com"
  }
}

HTTP/1.1 200 OK
Content-Type: application/json

{
  "linked": {
  },
  "meta": {
  },
  "oidc_rp_configurations": {
    "autoenroll_group_id": null,
    "autoenroll_group_label": "SUPPORT",
    "created_at": "2018-03-29T05:20:58.676Z",
    "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1122114385381168673",
    "id": "1122114385381168673",
    "is_default": false,
    "links": {
    },
    "meta": {
      "actions": [
        {
          "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1122114385381168673",
          "label": "OIDC_RP_CONFIGURATION_GET",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations",
          "label": "OIDC_RP_CONFIGURATION_CREATE",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations",
          "label": "OIDC_RP_CONFIGURATION_GET_ALL",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1122114385381168673",
          "label": "OIDC_RP_CONFIGURATION_UPDATE",
          "method": "PUT"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/oidc_rp_configurations/1122114385381168673",
          "label": "OIDC_RP_CONFIGURATION_DELETE",
          "method": "DELETE"
        }
      ],
      "pagination": {
      }
    },
    "modified_at": "2018-03-29T05:20:58.967Z",
    "name": "some_cfg_name_1522300857553",
    "oauth2_client_configuration_id": 1122114383997048352,
    "oauth2_client_configuration_name": "some_cli_cfg_name_de0d5acd-6e15-44a9-9a10-e7bbb4938875",
    "op_tenant": "kzoinnovations.com"
  }
}
Authorization
GET /misc/custom_auth/oidc/login
Initiate OIDC authorization flaw
GET /misc/custom_auth/oidc/login

Authentication

Open

Initiates the OIDC authorization flaw. It is suppose that OIDC custom authentication option is created and assigned with correspondent OAuth2 client configuration.

Request parameters

custom_authn_option_id
number required

Id of OIDC custom authentication option

browser_session_id
string optional

Id of browser session. Non required but usefull parameter which allow to synchronize authentication attempts

location
string optional

URL where user will be redirected after successful authentication or in case of errrors

Languages
GET /api/languages
GET /api/languages/translation
Viewing All Languages
GET /api/languages

View information on all supported languages.

Authentication is not required.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/api/languages HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "languages": [
        {
            "id": "en",
            "name": "English"
        },
        {
            "id": "fr",
            "name": "French"
        },
        {
            "id": "de",
            "name": "German"
        },
        {
            "id": "it",
            "name": "Italian"
        },
        {
            "id": "nl",
            "name": "Dutch"
        },
        {
            "id": "sv",
            "name": "Swedish"
        },
        {
            "id": "es",
            "name": "Spanish"
        },
        {
            "id": "da",
            "name": "Danish"
        },
        {
            "id": "pt",
            "name": "Portuguese"
        },
        {
            "id": "no",
            "name": "Norwegian"
        },
        {
            "id": "he",
            "name": "Hebrew"
        },
        {
            "id": "ja",
            "name": "Japanese"
        },
        {
            "id": "ar",
            "name": "Arabic"
        },
        {
            "id": "fi",
            "name": "Finnish"
        },
        {
            "id": "el",
            "name": "Greek"
        },
        {
            "id": "is",
            "name": "Icelandic"
        },
        {
            "id": "mt",
            "name": "Maltese"
        },
        {
            "id": "tr",
            "name": "Turkish"
        },
        {
            "id": "hr",
            "name": "Croatian"
        },
        {
            "id": "zh",
            "name": "Chinese"
        },
        {
            "id": "ur",
            "name": "Urdu"
        },
        {
            "id": "hi",
            "name": "Hindi"
        },
        {
            "id": "th",
            "name": "Thai"
        },
        {
            "id": "ko",
            "name": "Korean"
        },
        {
            "id": "lt",
            "name": "Lithuanian"
        },
        {
            "id": "pl",
            "name": "Polish"
        },
        {
            "id": "hu",
            "name": "Hungarian"
        },
        {
            "id": "et",
            "name": "Estonian"
        },
        {
            "id": "lv",
            "name": "Latvian"
        },
        {
            "id": "se",
            "name": "Northern Sami"
        },
        {
            "id": "fo",
            "name": "Faroese"
        },
        {
            "id": "fa",
            "name": "Farsi"
        },
        {
            "id": "ru",
            "name": "Russian"
        },
        {
            "id": "ga",
            "name": "Irish"
        },
        {
            "id": "sq",
            "name": "Albanian"
        },
        {
            "id": "ro",
            "name": "Romanian"
        },
        {
            "id": "cs",
            "name": "Czech"
        },
        {
            "id": "sk",
            "name": "Slovak"
        },
        {
            "id": "sl",
            "name": "Slovene"
        },
        {
            "id": "yi",
            "name": "Yiddish"
        },
        {
            "id": "sr",
            "name": "Serbian"
        },
        {
            "id": "mk",
            "name": "Macedonian"
        },
        {
            "id": "bg",
            "name": "Bulgarian"
        },
        {
            "id": "uk",
            "name": "Ukrainian"
        },
        {
            "id": "be",
            "name": "Belarusian"
        },
        {
            "id": "uz",
            "name": "Uzbek"
        },
        {
            "id": "kk",
            "name": "Kazakh"
        },
        {
            "id": "az",
            "name": "Azerbaijani"
        },
        {
            "id": "hy",
            "name": "Armenian"
        },
        {
            "id": "ka",
            "name": "Georgian"
        },
        {
            "id": "ky",
            "name": "Kyrgyz"
        },
        {
            "id": "tg",
            "name": "Tajik"
        },
        {
            "id": "tk",
            "name": "Turkmen"
        },
        {
            "id": "mn",
            "name": "Mongolian"
        },
        {
            "id": "ps",
            "name": "Pushto"
        },
        {
            "id": "ku",
            "name": "Kurdish"
        },
        {
            "id": "ks",
            "name": "Kashmiri"
        },
        {
            "id": "sd",
            "name": "Sindhi"
        },
        {
            "id": "bo",
            "name": "Tibetan"
        },
        {
            "id": "ne",
            "name": "Nepali"
        },
        {
            "id": "sa",
            "name": "Sanskrit"
        },
        {
            "id": "mr",
            "name": "Marathi"
        },
        {
            "id": "bn",
            "name": "Bengali"
        },
        {
            "id": "as",
            "name": "Assamese"
        },
        {
            "id": "gu",
            "name": "Gujarati"
        },
        {
            "id": "pa",
            "name": "Eastern Panjabi"
        },
        {
            "id": "or",
            "name": "Oriya"
        },
        {
            "id": "ml",
            "name": "Malayalam"
        },
        {
            "id": "kn",
            "name": "Kannada"
        },
        {
            "id": "ta",
            "name": "Tamil"
        },
        {
            "id": "te",
            "name": "Telugu"
        },
        {
            "id": "si",
            "name": "Sinhalese"
        },
        {
            "id": "my",
            "name": "Burmese"
        },
        {
            "id": "km",
            "name": "Khmer"
        },
        {
            "id": "lo",
            "name": "Lao"
        },
        {
            "id": "vi",
            "name": "Vietnamese"
        },
        {
            "id": "id",
            "name": "Indonesian"
        },
        {
            "id": "tl",
            "name": "Tagalog"
        },
        {
            "id": "ms",
            "name": "Malay"
        },
        {
            "id": "am",
            "name": "Amharic"
        },
        {
            "id": "om",
            "name": "Oromo"
        },
        {
            "id": "so",
            "name": "Somali"
        },
        {
            "id": "sw",
            "name": "Swahili"
        },
        {
            "id": "rw",
            "name": "Kinyarwanda"
        },
        {
            "id": "rn",
            "name": "Kirundi"
        },
        {
            "id": "ny",
            "name": "Nyanja"
        },
        {
            "id": "mg",
            "name": "Malagasy"
        },
        {
            "id": "eo",
            "name": "Esperanto"
        },
        {
            "id": "cy",
            "name": "Welsh"
        },
        {
            "id": "eu",
            "name": "Basque"
        },
        {
            "id": "ca",
            "name": "Catalan"
        },
        {
            "id": "la",
            "name": "Latin"
        },
        {
            "id": "qu",
            "name": "Quechua"
        },
        {
            "id": "gn",
            "name": "Guaraní"
        },
        {
            "id": "ay",
            "name": "Aymara"
        },
        {
            "id": "tt",
            "name": "Tatar"
        },
        {
            "id": "ug",
            "name": "Uyghur"
        },
        {
            "id": "dz",
            "name": "Dzongkha"
        },
        {
            "id": "jv",
            "name": "Javanese"
        },
        {
            "id": "zh-Hans",
            "name": "Simplified Chinese"
        },
        {
            "id": "zh-Hant",
            "name": "Traditional Chinese"
        }
    ]
}
Viewing All Languages Available For Translation
GET /api/languages/translation

View information on all languages available for translation.

Requires authenticated user.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/api/languages/translation HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "languages": [
        {
            "id": "tr",
            "name": "Turkish"
        },
        {
            "id": "et",
            "name": "Estonian"
        },
        {
            "id": "pt",
            "name": "Portuguese"
        },
        {
            "id": "ja",
            "name": "Japanese"
        },
        {
            "id": "sl",
            "name": "Slovene"
        },
        {
            "id": "ps",
            "name": "Pushto"
        },
        {
            "id": "hu",
            "name": "Hungarian"
        },
        {
            "id": "fa",
            "name": "Farsi"
        },
        {
            "id": "hy",
            "name": "Armenian"
        },
        {
            "id": "ms",
            "name": "Malay"
        },
        {
            "id": "ne",
            "name": "Nepali"
        },
        {
            "id": "pa",
            "name": "Eastern Panjabi"
        },
        {
            "id": "sw",
            "name": "Swahili"
        },
        {
            "id": "hr",
            "name": "Croatian"
        },
        {
            "id": "la",
            "name": "Latin"
        },
        {
            "id": "ky",
            "name": "Kyrgyz"
        },
        {
            "id": "kn",
            "name": "Kannada"
        },
        {
            "id": "nl",
            "name": "Dutch"
        },
        {
            "id": "ka",
            "name": "Georgian"
        },
        {
            "id": "gu",
            "name": "Gujarati"
        },
        {
            "id": "el",
            "name": "Greek"
        },
        {
            "id": "bn",
            "name": "Bengali"
        },
        {
            "id": "lt",
            "name": "Lithuanian"
        },
        {
            "id": "sr",
            "name": "Serbian"
        },
        {
            "id": "eo",
            "name": "Esperanto"
        },
        {
            "id": "mr",
            "name": "Marathi"
        },
        {
            "id": "sq",
            "name": "Albanian"
        },
        {
            "id": "sk",
            "name": "Slovak"
        },
        {
            "id": "am",
            "name": "Amharic"
        },
        {
            "id": "ta",
            "name": "Tamil"
        },
        {
            "id": "zh",
            "name": "Chinese"
        },
        {
            "id": "sv",
            "name": "Swedish"
        },
        {
            "id": "ur",
            "name": "Urdu"
        },
        {
            "id": "ro",
            "name": "Romanian"
        },
        {
            "id": "cs",
            "name": "Czech"
        },
        {
            "id": "mk",
            "name": "Macedonian"
        },
        {
            "id": "uk",
            "name": "Ukrainian"
        },
        {
            "id": "my",
            "name": "Burmese"
        },
        {
            "id": "it",
            "name": "Italian"
        },
        {
            "id": "th",
            "name": "Thai"
        },
        {
            "id": "mn",
            "name": "Mongolian"
        },
        {
            "id": "lv",
            "name": "Latvian"
        },
        {
            "id": "es",
            "name": "Spanish"
        },
        {
            "id": "da",
            "name": "Danish"
        },
        {
            "id": "bg",
            "name": "Bulgarian"
        },
        {
            "id": "is",
            "name": "Icelandic"
        },
        {
            "id": "uz",
            "name": "Uzbek"
        },
        {
            "id": "mt",
            "name": "Maltese"
        },
        {
            "id": "ny",
            "name": "Nyanja"
        },
        {
            "id": "si",
            "name": "Sinhalese"
        },
        {
            "id": "lo",
            "name": "Lao"
        },
        {
            "id": "ml",
            "name": "Malayalam"
        },
        {
            "id": "ar",
            "name": "Arabic"
        },
        {
            "id": "ca",
            "name": "Catalan"
        },
        {
            "id": "so",
            "name": "Somali"
        },
        {
            "id": "ku",
            "name": "Kurdish"
        },
        {
            "id": "vi",
            "name": "Vietnamese"
        },
        {
            "id": "eu",
            "name": "Basque"
        },
        {
            "id": "cy",
            "name": "Welsh"
        },
        {
            "id": "ga",
            "name": "Irish"
        },
        {
            "id": "id",
            "name": "Indonesian"
        },
        {
            "id": "km",
            "name": "Khmer"
        },
        {
            "id": "fi",
            "name": "Finnish"
        },
        {
            "id": "tg",
            "name": "Tajik"
        },
        {
            "id": "de",
            "name": "German"
        },
        {
            "id": "pl",
            "name": "Polish"
        },
        {
            "id": "az",
            "name": "Azerbaijani"
        },
        {
            "id": "tl",
            "name": "Tagalog"
        },
        {
            "id": "ru",
            "name": "Russian"
        },
        {
            "id": "en",
            "name": "English"
        },
        {
            "id": "kk",
            "name": "Kazakh"
        },
        {
            "id": "hi",
            "name": "Hindi"
        },
        {
            "id": "no",
            "name": "Norwegian"
        },
        {
            "id": "ko",
            "name": "Korean"
        },
        {
            "id": "be",
            "name": "Belarusian"
        },
        {
            "id": "sd",
            "name": "Sindhi"
        },
        {
            "id": "te",
            "name": "Telugu"
        },
        {
            "id": "fr",
            "name": "French"
        },
        {
            "id": "mg",
            "name": "Malagasy"
        },
        {
            "id": "yi",
            "name": "Yiddish"
        }
    ]
}
Speech Recognition Configuration
GET /api/feature_configs/speech_recognition
PUT /api/feature_configs/speech_recognition
Viewing Speech Recognition Configuration
GET /api/feature_configs/speech_recognition

Fetch Speech Recognition configuration data.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Examples

GET https://tenant.kzoplatform.com/api/api/feature_configs/OIDC HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "feature_config_speech_recognition": {
        "created_at": "2018-01-05T04:09:18.729Z",
        "href": "",
        "id": "1061921929247593853",
        "implementation": "GOOGLE_FRAGMENTS",
        "links": {
            "created_by": {
                
            },
            "modified_by": {
                
            }
        },
        "meta": {
            "actions": [
                
            ],
            "pagination": {
                
            }
        },
        "modified_at": "2018-01-05T04:09:18.729Z",
        "process_existing_media": "NONE"
    },
    "linked": {
        
    },
    "meta": {
        
    }
}
Replacing Speech Recognition Configuration
PUT /api/feature_configs/speech_recognition

Replace Speech Recognition Feature Configuration on the current tenant. Requires Permission assigning Role MANAGE_TENANT on the root Container.

If platform feature SPEECH_RECOGNITION is enabled and parameter process_existing_media is passed as ALL then speech recognition will be scheduled for all media without closed captions.

Request body

Object
feature_config_speech_recognition
Object
implementation
string

Implementation of speech recognition, now only google is supported but here can be IBM Watson, Microsoft, etc.

Enumeration:
GOOGLE_FRAGMENTS

Split speech by short phrases, use to google for recognition

GOOGLE_FRAGMENTS_CHUNKED

Split speech by short phrases chunked up to 15 seconds google rounding interval, use to google for recognition

process_existing_media
string

Type of processing for speech recognition config

Enumeration:
NONE

Do not process existing media

ALL

Process all existing media

BY_CONTAINER

Process existing media only in certain containers

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/feature_configs/speech_recognition HTTP/1.1 

Content-Type: application/json

{
    "feature_config_speech_recognition": {
        "implementation": "GOOGLE_FRAGMENTS",
        "process_existing_media": "NONE"
    }
}

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "feature_config_speech_recognition": {
        "created_at": "2018-01-05T04:09:18.729Z",
        "id": "1061921929247593853",
        "implementation": "GOOGLE_FRAGMENTS",
        "modified_at": "2018-01-05T04:09:18.729Z",
        "process_existing_media": "NONE"
    }
}
Overlay Fonts
Viewing All Active Overlay Fonts
GET /overlay_fonts

Fetch all active Overlay Fonts.

Requires authenticated user.

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/overlay_fonts HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
    },
    "overlay_fonts": [
        {
            "id": "Arial",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Arial"
        },
        {
            "id": "Bookman",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Bookman"
        },
        {
            "id": "Chalkduster",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Chalkduster"
        },
        {
            "id": "Comic_Sans_MS",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Comic Sans MS"
        },
        {
            "id": "Courier",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Courier"
        },
        {
            "id": "Courier_New",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Courier New"
        },
        {
            "id": "Georgia",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Georgia"
        },
        {
            "id": "Impact",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Impact"
        },
        {
            "id": "Oxygen",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Oxygen"
        },
        {
            "id": "Tahoma",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Tahoma"
        },
        {
            "id": "Times",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Times"
        },
        {
            "id": "Times_New_Roman",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Times New Roman"
        },
        {
            "id": "Verdana",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Verdana"
        },
        {
            "id": "Webdings",
            "href": "",
            "links": {
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                ]
            },
            "name": "Webdings"
        }
    ]
}
Waveforms

API for waveform data

GET /api/original_videos/{id}/waveform
DELETE /api/original_videos/{id}/waveform
POST /api/original_videos/{id}/process_waveform_recognition
Viewing waveforms
GET /api/original_videos/{id}/waveform

Fetch Waveforms data. Requires Permission assigning Role VIEW_CONTENT on the Container that contains media with waveforms.

Path variables

id
string required

original video rendition identifier

Request parameters

variety
string required
Enumeration:
coarse

coarse overview, at most 2000 data points for media

fine

fine view with 100 ms step

start_msec
integer optional

start time of fragment to return, defaults to 0

end_msec
integer optional

end time of fragment to return, defaults to medium trt

Responses

200 OK
403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/original_videos/12345/waveform?variety=fine HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "linked": {
    },
    "meta": {
        "state": {
        }
    },
    "waveform": {
        "cues": [
            13.63,
            40.22,
            70.25,
            71.5,
            73.23,
            57.18,
            57.81,
            74.85,
            71.83,
            65.31,
            65.6,
            56.24,
            60.24,
            82.18,
            68.49,
            78.35,
            63.0,
            60.45,
            40.86
        ],
        "id": "1121459893207832369",
        "start_msec": "0"
        "end_msec": "95",
    }
}
Deleting waveforms
DELETE /api/original_videos/{id}/waveform

Delete waveforms for original video.

Requires Permission assigning Capability DELETE_CONTENT on the parent Container of the parent Medium.

Path variables

id
string required

original video identifier

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/original_videos/12324/waveform HTTP/1.1 

HTTP/1.1 200 OK 
Creating waveforms
POST /api/original_videos/{id}/process_waveform_recognition

Process waveform recognition for video rendition.

Requires Permission assigning Role CONTENT_CREATOR on the parent Container of the parent Medium.

Path variables

id
string required

original video identifier

Examples

POST https://tenant.kzoplatform.com/api/original_videos/1234/process_waveform_recognition HTTP/1.1 
Screenshot Overlays
Custom Attributes
POST /api/custom_attributes
PUT /custom_attributes/{id}
DELETE /custom_attributes/{id}
GET /custom_attributes/{id}
GET /custom_attributes
Create custom attribute
POST /api/custom_attributes

Creates new custom attribute. Requires MANAGE_DEPLOY capability if subtsr(category, 1, 6) == DEPLOY and MANAGE_TENANT capability if subtsr(category, 1, 6) == TENANT.

Request body

Object
custom_attributes
Examples

Responses

201 Created
Body
Object
custom_attributes
400 Bad request

If some of parameters are invalid

403 Forbidden

If illegal parmeters combination were used

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Content Hierarchy Config
GET /custom_attributes_on_content_hierarchy_configs/{id}
GET /custom_attributes_on_content_hierarchy_configs
POST /custom_attributes_on_content_hierarchy_configs
DELETE /custom_attributes_on_content_hierarchy_configs/{id}
PUT /custom_attributes_on_content_hierarchy_configs/{id}
Viewing Custom Attributes On Content Hierarchy Config By Id
GET /custom_attributes_on_content_hierarchy_configs/{id}

Fetch custom attributes on content hierarchy config by id.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Response is the same with api/custom_attributes_on_content_hierarchy_configs

Path variables

id
string required

custom attributes on content hierarchy config identifier

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: users, containers, groups etc. Parameters are joined with comma. Example: created_by,modified_by

Viewing All Custom Attributes On Content Hierarchy Configs
GET /custom_attributes_on_content_hierarchy_configs

Fetch all custom attributes on content hierarchy configs.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: users, containers, groups etc. Parameters are joined with comma. Example: created_by,modified_by

Responses

200 OK
Body
Object
custom_attributes_on_content_hierarchy_configs
Array

list of content hierarchy configs

Object
colors_html
Array of string

HTML color

Example:
["#000000"]

Aggregation function

created_at
string

Creation date

Example:
2018-06-08T14:39:21.282Z
custom_attribute_category

Custom attribute category

custom_attribute_name
string

Name of custom attribute, the config relates to

Example:
test_attribute_name
description
string

Description of config

Example:
test_description
display
boolean

Whether to display this attribute on a content card as a label on a ribbon, or just to compute it for containers and report via API.

Example:
true
href
string

Reference to current config

Example:
https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1173854502533469362
id
string

Config identifier

Example:
1173854502533469362
json_path
string

JSON Path of an attribute within the CA defined by custom_attribute_name and category, whose value is to be matched against values. The attribute must be of an ordered string set type, according to json_schema for that CA.

Example:
{"some_test_path"}
labels
Array

List of labels to be displayed for each matching value.

Example:
["test_label"]
string
Example:
test_label
modified_at
string

Modification date

Example:
2018-06-08T14:39:21.502Z
name
string

Name of config

Example:
updated_name
values
Array

List of values to match the CA against.

Example:
["test_val"]
string
Example:
test_val
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/custom_attributes_on_content_hierarchy_configs HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "custom_attributes_on_content_hierarchy_configs": [
        {
            "container_value_function": "MIN_INDEX",
            "created_at": "2018-06-08T14:39:21.282Z",
            "custom_attribute_category": "DEPLOY__MUTABLE__DEPLOY",
            "custom_attribute_name": "test_attribute_name",
            "description": "test_description",
            "display": true,
            "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1173854502533469362",
            "id": "1173854502533469362",
            "json_path": "{\"some_test_path\"}",
            "links": {
                "created_by": {
                    "type": "users",
                    "username": "admin"
                },
                "modified_by": {
                    "type": "users",
                    "username": "admin"
                }
            },
            "meta": {
                "actions": [
                    {
                        "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs",
                        "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_CREATE",
                        "method": "POST"
                    },
                    {
                        "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1173854502533469362",
                        "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_EDIT",
                        "method": "PUT"
                    },
                    {
                        "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1173854502533469362",
                        "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_GET",
                        "method": "GET"
                    },
                    {
                        "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1173854502533469362",
                        "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_DELETE",
                        "method": "DELETE"
                    },
                    {
                        "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs",
                        "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_GET_ALL",
                        "method": "GET"
                    }
                ],
                "pagination": {
                    
                }
            },
            "modified_at": "2018-06-08T14:39:21.502Z",
            "name": "updated_name",
            "colors_html": [
                "#000000"
            ],
            "labels": [
                "test_label"
            ],
            "values": [
                "test_val"
            ]
        }
    ],
    "linked": {
        "users": [
            {
                "username": "admin"
                ...
            }
        ]
    },
}
Creating Content Hierarchy Config
POST /custom_attributes_on_content_hierarchy_configs

Create custom attributes on content hierarchy config.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Request body

Object
custom_attributes_on_content_hierarchy_configs
Object

parameters describing configuration

custom_attribute_name
string

Name of custom attribute

Example:
some attribute name
custom_attribute_category

Category of custom attribute

name
string

Name of configuration

Example:
config name
description
string

Human readable description of configuration

Example:
config description
display
boolean

Whether to display this attribute on a content card as a label on a ribbon, or just to compute it for containers and report via API

Example:
true

How to compute value for Container. We are starting with 2 functions, MIN_INDEX & MAX_INDEX. E.g., in case of the former, an value with minimum index of the ordered string set encountered among Media is used for the Container. Other functions may be added in the future

json_path
string

JSON Path of an attribute within the CA defined by (custom_attribute_name,custom_attribute_category), whose value is to be matched against values. The attribute must be of an ordered string set type, according to json_schema for that CA

Example:
{"some_test_path"}
values
Array

List of values to match the CA against

Example:
["some val"]
string
Example:
some val
colors_html
Array

List of ribbon HTML colors to be used as a background for the labels corresponding to the matching values

Example:
["#000000"]
string
Example:
#000000
labels
Array

List of labels to be displayed for each matching value

Example:
["some label"]
string
Example:
some label

Examples

POST https://tenant.kzoplatform.com/api/custom_attributes_on_content_hierarchy_configs HTTP/1.1 

Content-Type: application/json

{
    "custom_attributes_on_content_hierarchy_configs": {
        "custom_attribute_name": "some attribute name",
        "custom_attribute_category": "DEPLOY__MUTABLE__DEPLOY",
        "name": "config name",
        "description": "config description",
        "display": true,
        "container_value_function": "MIN_INDEX",
        "json_path": "{\"some_test_path\"}",
        "values": [
            "some val"
        ],
        "colors_html": [
            "#000000"
        ],
        "labels": [
            "some label"
        ]
    }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "custom_attributes_on_content_hierarchy_configs": {
        "colors_html": [
            "#000000"
        ],
        "container_value_function": "MIN_INDEX",
        "created_at": "2018-06-11T09:28:31.961Z",
        "custom_attribute_category": "TENANT__MUTABLE__TENANT",
        "custom_attribute_name": "test_attribute_name",
        "description": "test_description",
        "display": true,
        "entityType": "MEDIUM",
        "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1175872387875345651",
        "id": "1175872387875345651",
        "json_path": "{\"some_test_path\"}",
        "labels": [
            "some label"
        ],
        "meta": {
            "actions": [
                {
                    "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs",
                    "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_CREATE",
                    "method": "POST"
                },
                {
                    "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1175872387875345651",
                    "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_EDIT",
                    "method": "PUT"
                },
                {
                    "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1175872387875345651",
                    "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_GET",
                    "method": "GET"
                },
                {
                    "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1175872387875345651",
                    "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_DELETE",
                    "method": "DELETE"
                },
                {
                    "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs",
                    "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_GET_ALL",
                    "method": "GET"
                }
            ]
        },
        "modified_at": "2018-06-11T09:28:31.961Z",
        "name": "some name",
        "values": [
            "some val"
        ]
    }
}
Deleting Custom Attributes On Content Hierarchy Config
DELETE /custom_attributes_on_content_hierarchy_configs/{id}

Delete custom attributes on content hierarchy configs by id.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Path variables

id
string required

custom attributes on content hierarchy config identifier

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Updating Custom Attributes On Content Hierarchy Config
PUT /custom_attributes_on_content_hierarchy_configs/{id}

Update custom attributes on content hierarchy configs by id.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Path variables

id
string required

custom attributes on content hierarchy config identifier

Request body

Object
custom_attributes_on_content_hierarchy_configs
Object
name
string

Name of config

Example:
some name
description
string

Description of config

Example:
some description
custom_attribute_name
string

Name of custom attribute

Example:
some attribute name
custom_attribute_category

Category of custom attribute

display
string

Whether to display this attribute on a content card as a label on a ribbon (true), or just to compute it for containers and report via API (false)

Example:
true
json_path
string

JSON Path of an attribute within the CA defined by custom_attribute_name and category, whose value is to be matched against values. The attribute must be of an ordered string set type, according to json_schema for that CA

Example:
{"some_test_path"}
values
Array

List of values to match the CA against

Example:
["some val"]
string
Example:
some val
labels
Array

Labels to be displayed on ribbon

Example:
["some label"]
string
Example:
some label
colors_html
Array

HTML color of ribbon

Example:
["#000000"]
string
Example:
#000000

Aggregation function

Examples

PUT https://tenant.kzoplatform.com/api/custom_attributes_on_content_hierarchy_configs/1175872387875345651 HTTP/1.1 

Content-Type: application/json

{
    "custom_attributes_on_content_hierarchy_configs": {
        "name": "some name",
        "description": "some description",
        "custom_attribute_name": "some attribute name",
        "custom_attribute_category": "TENANT__MUTABLE__TENANT",
        "display": "true",
        "json_path": "{\"some_test_path1\"}",
        "values": [
            "some val"
        ],
        "labels": [
            "some label"
        ],
        "colors_html": [
            "#000000"
        ],
        "container_value_function": "MAX_INDEX"
    }
}

HTTP/1.1 200 OK

Content-Type: application/json

{
    "custom_attributes_on_content_hierarchy_configs": {
        "colors_html": [
            "#000000"
        ],
        "container_value_function": "MAX_INDEX",
        "created_at": "2018-06-11T09:28:31.961Z",
        "custom_attribute_category": "TENANT__MUTABLE__TENANT",
        "custom_attribute_name": "some attribute name",
        "description": "some description",
        "display": true,
        "entityType": "MEDIUM",
        "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1175872387875345651",
        "id": "1175872387875345651",
        "json_path": "{\"some_test_path1\"}",
        "labels": [
            "some label"
        ],
        "meta": {
            "actions": [
                {
                    "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs",
                    "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_CREATE",
                    "method": "POST"
                },
                {
                    "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1175872387875345651",
                    "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_EDIT",
                    "method": "PUT"
                },
                {
                    "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1175872387875345651",
                    "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_GET",
                    "method": "GET"
                },
                {
                    "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs/1175872387875345651",
                    "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_DELETE",
                    "method": "DELETE"
                },
                {
                    "href": "https://localhost:8080/api/custom_attributes_on_content_hierarchy_configs",
                    "label": "CUSTOM_ATTRIBUTES_ON_CONTENT_HIERARCHY_CONFIGS_GET_ALL",
                    "method": "GET"
                }
            ]
        },
        "modified_at": "2018-06-12T11:28:31.961Z",
        "name": "some name",
        "values": [
            "some val"
        ]
    }
}
Update custom attribute
PUT /custom_attributes/{id}

Updates custom attibute. Requires MANAGE_DEPLOY capability if subtsr(category, 1, 6) == DEPLOY and MANAGE_TENANT capability if subtsr(category, 1, 6) == TENANT.

Path variables

id
string required

id of custom attribute

Request body

Object
custom_attributes

Responses

200 OK
Body
Object
custom_attributes
404 Not Found

If custom attribute not found by id

400 Bad request

If some parameters are invalid

403 Forbidden

If some parameters combination are illegal

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Delete custom attribute
DELETE /custom_attributes/{id}

Deletes specified custom attribute. Requires MANAGE_DEPLOY capability if subtsr(category, 1, 6) == DEPLOY and MANAGE_TENANT capability if subtsr(category, 1, 6) == TENANT.

Path variables

id
string required

id of custom attribute

Get custom attribue
GET /custom_attributes/{id}

Gets custom attribute by id

Path variables

id
string required

Id of the custom attribute

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: users, containers, groups etc. Parameters are joined with comma.

Includes for media and medium can be substituted, so that media information would be included to the response no matter which of two includes was requested. Same logic is applied container and containers.

Example:
media,containers,created_by

Responses

200 OK
Body
Object
404 Not Found

If custom attribute wasn’t found by id

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Get all custom attributes
GET /custom_attributes

Gets all available custom attributes

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: users, containers, groups etc. Parameters are joined with comma.

Includes for media and medium can be substituted, so that media information would be included to the response no matter which of two includes was requested. Same logic is applied container and containers.

Example:
media,containers,created_by

Responses

200 OK
Body
Object
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Custom attributes values

Set of API methods to manage values of custom attributes

POST /custom_attribute_values
GET /custom_attribute_values/{id}
PUT /custom_attribute_values/{id}
DELETE /custom_attribute_values/{id}
GET /custom_attribute_values
GET /custom_attribute_effective_values
Create custom attribute's value
POST /custom_attribute_values

Authentication

Create the value for specified custom attribute.

  • If entity=MEDIUM and the API caller doesn’t have VIEW_CONTENT for medium_id: {404, "Medium not found."}.
  • If entity=MEDIUM and the API caller doesn’t have UPDATE_CONTENT for medium_id: {403, "Permission to access this medium is denied."}.
  • If entity=USER and the API caller doesn’t have VIEW_IDENTITIES: {404, "User not found."}.
  • If entity=USER and the API caller doesn’t have MANAGE_IDENTITIES: {403, "Permission to access this user is denied."}.
  • If custom_attribute__scope__declaration__value like %__IMMUTABLE: {400, "Custom attributes with immutable values cannot be managed via API."}.
  • If custom_attribute__scope__declaration__value like %__DEPLOY or deploy_level=true and the tenant is unprivileged: {400, "Custom attribute values of deploy scope or deploy-level can only be managed on privileged tenant."}.
  • If custom_attribute__scope__declaration__value like %__DEPLOY or deploy_level=true and the API caller doesn’t have MANAGE_DEPLOY: {403, "Permission to modify deploy-level custom attribute is denied."}.
  • If custom_attribute__scope__declaration__value like %__TENANT% and the API caller doesn’t have MANAGE_TENANT: {403, "Permission to modify tenant-level custom attribute is denied."}.

Request body

Object
custom_attribute_values
CA value required

Value of attribute

Responses

201 Created
Body
Object
custom_attribute_values
CA value required
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Get the custom attribute value
GET /custom_attribute_values/{id}

Authentication

Gets the value by id.

  • If entity=MEDIUM and the API caller doesn’t have VIEW_CONTENT for medium_id: {404, "Medium not found."}.
  • If entity=USER and the API caller doesn’t have VIEW_IDENTITIES: {404, "User not found."}.

Path variables

id
string required

Id of the custom attribute value

Responses

200 OK
Body
Object
custom_attribute_values
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Update custom attribute value
PUT /custom_attribute_values/{id}

Edits custom attibute value by id.

  • If entity=MEDIUM and the API caller doesn’t have VIEW_CONTENT for medium_id: {404, "Medium not found."}.
  • If entity=MEDIUM and the API caller doesn’t have UPDATE_CONTENT for medium_id: {403, "Permission to access this medium is denied."}.
  • If entity=USER and the API caller doesn’t have VIEW_IDENTITIES: {404, "User not found."}.
  • If entity=USER and the API caller doesn’t have MANAGE_IDENTITIES: {403, "Permission to access this user is denied."}.
  • If custom_attribute__scope__declaration__value like %__IMMUTABLE: {400, "Custom attributes with immutable values cannot be managed via API."}.
  • If custom_attribute__scope__declaration__value like %__DEPLOY or deploy_level=true and the tenant is unprivileged: {400, "Custom attribute values of deploy scope or deploy-level can only be managed on privileged tenant."}.
  • If custom_attribute__scope__declaration__value like %__DEPLOY or deploy_level=true and the API caller doesn’t have MANAGE_DEPLOY: {403, "Permission to modify deploy-level custom attribute is denied."}.
  • If custom_attribute__scope__declaration__value like %__TENANT% and the API caller doesn’t have MANAGE_TENANT: {403, "Permission to modify tenant-level custom attribute is denied."}.
  • Attempting to modify custom_attribute_name, custom_attribute__scope__declaration__value, entity: {403, "Attributes custom_attribute_name, custom_attribute__scope__declaration__value, and entity cannot be modified."}

Path variables

id
string required

Id of the custom attribute value

Request body

Object
custom_attribute_values

Responses

200 OK
Body
Object
custom_attribute_values
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Delete custom attribute value
DELETE /custom_attribute_values/{id}

Authentication

Deletes custom attribute value.

  • If entity=MEDIUM and the API caller doesn’t have VIEW_CONTENT for medium_id: {404, "Medium not found."}.
  • If entity=MEDIUM and the API caller doesn’t have UPDATE_CONTENT for medium_id: {403, "Permission to access this medium is denied."}.
  • If entity=USER and the API caller doesn’t have VIEW_IDENTITIES: {404, "User not found."}.
  • If entity=USER and the API caller doesn’t have MANAGE_IDENTITIES: {403, "Permission to access this user is denied."}.
  • If custom_attribute__scope__declaration__value like %__IMMUTABLE: {400, "Custom attributes with immutable values cannot be managed via API."}.
  • If custom_attribute__scope__declaration__value like %__DEPLOY or deploy_level=true and the tenant is unprivileged: {400, "Custom attribute values of deploy scope or deploy-level can only be managed on privileged tenant."}.
  • If custom_attribute__scope__declaration__value like %__DEPLOY or deploy_level=true and the API caller doesn’t have MANAGE_DEPLOY: {403, "Permission to modify deploy-level custom attribute is denied."}.
  • If custom_attribute__scope__declaration__value like %__TENANT% and the API caller doesn’t have MANAGE_TENANT: {403, "Permission to modify tenant-level custom attribute is denied."}.

Path variables

id
string required

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Search for custom attribute value
GET /custom_attribute_values

Authentication

Returns an array of matching CA values for Media to which the user has VIEW_CONTENT, for Users, if the user has VIEW_IDENTITIES, all records with medium_id is null and user_id is null and container_id is null

Request parameters

medium_id
string optional

Id of the medium

user_id
string optional

Id of the user

container_id
string optional
Allow empty value: true
Default:
null
custom_attribute_name
string optional
category

Responses

200 OK
Body
Object
custom_attribute_values
Array of CA value
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Get custom attribute effective value
GET /custom_attribute_effective_values

Request parameters

custom_attribute_name
string required

Custom attribute name

category

Custom attribute category

Custom attribute entity type

medium_id
integer optional

Id of medium

user_id
integer optional

Id of user

Request headers

X-KZO-API-Version
string required

Specifies API version. For details, see API Version.

X-KZO-Auth-AccessKey
string required

Access Key used by the API caller to authenticate against the server. For details, see Authentication and Authorization.

X-KZO-Auth-Username
string required

Username used by the API caller to authenticate against the server. For details, see Authentication and Authorization.

X-KZO-Pipeline-Action
string optional

Used to initiate special actions related to pipeline processing on a pipeline-enabled entity or an entity managed by a pipeline of its parent entity. For more details, see Workflow.

X-KZO-Tenant
string required

Specifies name of the Tenant to which the request is issued. For details, see [Tenant Management](doc://Tenant Management).

Responses

200 OK
Body
Object
custom_attribute_effective_values
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

User Editable Custom Attributes
POST /api/user_editable_user_custom_attributes
PUT /api/user_editable_user_custom_attributes/{id}
GET /api/user_editable_user_custom_attributes/{id}
GET /api/user_editable_user_custom_attributes
DELETE /api/user_editable_user_custom_attributes/{id}
Creating User Editable Custom Attributes
POST /api/user_editable_user_custom_attributes

Create User Editable Custom Attribute.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Requires existing Custom Attribute having same name and category with entity type USER and assigned json schema containing enumeration, e.g. {“type”:“string”,“enum”:[“ONE”,“TWO”,“THREE”]}

Request body

Object
user_editable_user_custom_attributes
Object
custom_attribute_name
string

Name of existing Custom Attribute

Example:
sample_attribute_name
custom_attribute_category
string

Category of existing Custom Attribute

Example:
TENANT__MUTABLE__TENANT

Responses

201 Created
Body
Object
user_editable_user_custom_attributes
Object
custom_attribute_name
string

Custom Attribute name

Example:
sample_attribute_name
custom_attribute_category
string

Custom Attribute category

Example:
TENANT__MUTABLE__TENANT
entityType
string

Custom Attribute entiry

Example:
USER
id
string

Identifier of created entity

Example:
1283765452136257313
created_at
string

Creation date string representation in ISO8601 standard

Example:
2018-11-05T10:56:21.438Z
modified_at
string

Modification date string representation in ISO8601 standard, equal to creation date in response to creation.

Example:
2018-11-05T10:56:21.438Z
409 Conflict

In case when User Editable Custom Attribute with same name and category already exists

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/api/user_editable_user_custom_attributes HTTP/1.1 

Content-Type: application/json

{
    "user_editable_user_custom_attributes": {
        "custom_attribute_name": "sample_attribute_name",
        "custom_attribute_category": "TENANT__MUTABLE__TENANT"
    }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "user_editable_user_custom_attributes": {
        "custom_attribute_name": "sample_attribute_name",
        "custom_attribute_category": "TENANT__MUTABLE__TENANT",
        "entityType": "USER",
        "id": "1283765452136257313",
        "created_at": "2018-11-07T08:40:19.045Z",
        "modified_at": "2018-11-07T08:40:19.045Z",
        "meta": {
              "actions": [
                {
                  "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283765452136257313",
                  "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_GET",
                  "method": "GET"
                },
                {
                  "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes",
                  "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_GET_ALL",
                  "method": "GET"
                },
                {
                  "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes",
                  "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_CREATE",
                  "method": "POST"
                },
                {
                  "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283765452136257313",
                  "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_EDIT",
                  "method": "PUT"
                },
                {
                  "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283765452136257313",
                  "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_DELETE",
                  "method": "DELETE"
                }
            ]
        }    
    }
}
Updating User Editable Custom Attributes
PUT /api/user_editable_user_custom_attributes/{id}

Update User Editable Custom Attribute.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Requires existing Custom Attribute having same name and category with entity type USER and assigned json schema containing enumeration, e.g. {"type":"string","enum":["ONE","TWO","THREE"]}

Path variables

id
number required

User Editable Custom Attributes identifier

Request body

Object
user_editable_user_custom_attributes
Object
custom_attribute_name
string

Name of existing Custom Attribute

Example:
sample_attribute_name
custom_attribute_category
string

Category of existing Custom Attribute

Example:
TENANT__MUTABLE__TENANT

Responses

200 OK
Body
Object
user_editable_user_custom_attributes
Object
custom_attribute_name
string

Custom Attribute name

Example:
sample_attribute_name
custom_attribute_category
string

Custom Attribute category

Example:
TENANT__MUTABLE__TENANT
entityType
string

Custom Attribute entity type

Example:
USER
id
string

User Editable Custom Attribute identifier

Example:
1283765452136257313
created_at
string

Creation date string representation in ISO8601 standard

Example:
2018-11-05T10:56:21.438Z
modified_at
string

Modification date string representation in ISO8601 standard

Example:
2018-11-08T10:57:11.328Z
409 Conflict

In case when another User Editable Custom Attribute with same name and category already exists

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283765452136257313 HTTP/1.1 

Content-Type: application/json
{
    "user_editable_user_custom_attributes": {
        "custom_attribute_name": "updated_sample_attribute_name",
        "custom_attribute_category": "TENANT__MUTABLE__TENANT"
    }
}

HTTP/1.1 200 OK 

Content-Type: application/json
{
  "user_editable_user_custom_attributes": {
    "custom_attribute_category": "TENANT__MUTABLE__TENANT",
    "custom_attribute_name": "updated_sample_attribute_name",
    "entityType": "USER",
    "id": "1283765452136257313",
    "modified_at": "2018-11-07T08:40:19.045Z",
    "created_at": "2018-11-07T08:22:11.153Z"
    "meta": {
      "actions": [
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283765452136257313",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_GET",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_GET_ALL",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_CREATE",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283765452136257313",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_EDIT",
          "method": "PUT"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283765452136257313",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_DELETE",
          "method": "DELETE"
        }
      ]
    }
  }
}
Viewing User Editable Custom Attributes
GET /api/user_editable_user_custom_attributes/{id}

Viewing User Editable Custom Attributes.

Path variables

id
number required

User Editable Custom Attribute identifier

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: created_by, modified_by, custom_attribute etc. Parameters are joined with comma.

Example:
created_by,modified_by,custom_attribute

Responses

200 OK
Body
Object
user_editable_user_custom_attributes
Object
custom_attribute_name
string

Name of related Custom Attribute

Example:
sample_attribute_name
custom_attribute_category
string

Category of related Custom Attribute

Example:
TENANT__MUTABLE__TENANT
entityType
string

Entity type of related Custom Attribute

Example:
USER
id
string

Identifier of User Editable Custom Attribute

Example:
1283765452136257313
created_at
string

Creation date string representation in ISO8601 standard

Example:
2018-11-05T10:56:21.438Z
modified_at
string

Modification date string representation in ISO8601 standard

Example:
2018-11-05T10:56:21.438Z
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283825976681174823?include=created_by,modified_by,custom_attribute HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "user_editable_user_custom_attributes": {
    "created_at": "2018-11-07T08:13:02.585Z",
    "custom_attribute_category": "TENANT__MUTABLE__TENANT",
    "custom_attribute_name": "sample_attribute_name",
    "entityType": "USER",
    "href": "",
    "id": "1283825976681174823",
    "links": {
      "custom_attribute": "kzo3_1283825973401229094",
      "created_by": {
        "type": "users",
        "username": "admin"
      },
      "modified_by": {
        "type": "users",
        "username": "admin"
      }
    },
    "meta": {
      "actions": [
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283825976681174823",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_GET",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_GET_ALL",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_CREATE",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283825976681174823",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_EDIT",
          "method": "PUT"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283825976681174823",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_DELETE",
          "method": "DELETE"
        }
      ]
    },
    "modified_at": "2018-11-07T08:13:02.692Z"
  },
  "linked": {
    "custom_attributes": [
      {
        "category": "TENANT__MUTABLE__TENANT",
        "entity": "USER",
        "name": "sample_attribute_name",
        "id": "kzo3_1283825973401229094",
        "json_schema": {
          "enum": [
            "ONE",
            "TWO",
            "THREE"
          ],
          "type": "string"
        },
        ...
      }
    ],
    "users": [
      {
        "username": "admin",
        ....
      }
    ]
  }
}
Viewing All User Editable Custom Attributes
GET /api/user_editable_user_custom_attributes

Viewing all User Editable Custom Attributes.

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: created_by, modified_by, custom_attribute etc. Parameters are joined with comma.

Example:
created_by,modified_by,custom_attribute

Responses

200 OK
Body
Object
user_editable_user_custom_attributes
Array
Object
custom_attribute_name
string

Name of related Custom Attribute

Example:
sample_attribute_name
custom_attribute_category
string

Category of related Custom Attribute

Example:
TENANT__MUTABLE__TENANT
entityType
string

Entity type of related Custom Attribute

Example:
USER
id
number

Identifier of User Editable Custom Attribute

created_at
string

Creation date string representation in ISO8601 standard

Example:
2018-11-05T10:56:21.438Z
modified_at
string

Modification date string representation in ISO8601 standard

Example:
2018-11-05T10:56:21.438Z
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes?include=created_by,modified_by,custom_attribute HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json
{
  "user_editable_user_custom_attributes": [{
    "created_at": "2018-11-07T08:13:02.585Z",
    "modified_at": "2018-11-07T08:13:02.692Z"
    "custom_attribute_category": "TENANT__MUTABLE__TENANT",
    "custom_attribute_name": "sample_attribute_name",
    "entityType": "USER",
    "id": "1283825976681174823",
    "links": {
      "custom_attribute": "kzo3_1283825973401229094",
      "created_by": {
        "type": "users",
        "username": "admin"
      },
      "modified_by": {
        "type": "users",
        "username": "admin"
      }
    },
    "meta": {
      "actions": [
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283825976681174823",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_GET",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_GET_ALL",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_CREATE",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283825976681174823",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_EDIT",
          "method": "PUT"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283825976681174823",
          "label": "EDITABLE_USER_CUSTOM_ATTRIBUTE_DELETE",
          "method": "DELETE"
        }
      ]
    }
  }],
  "linked": {
    "custom_attributes": [
      {
        "category": "TENANT__MUTABLE__TENANT",
        "entity": "USER",
        "name": "sample_attribute_name",
        "id": "kzo3_1283825973401229094",
        "json_schema": {
          "enum": [
            "ONE",
            "TWO",
            "THREE"
          ],
          "type": "string"
        },
        ...
      }
    ],
    "users": [
      {
        "username": "admin",
        ....
      }
    ]
  }
}
Deleting User Editable Custom Attributes
DELETE /api/user_editable_user_custom_attributes/{id}

Delete User Editable Custom Attribute.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Path variables

id
string required

Identifier of User Editable Custom Attribute to be deleted

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

DELETE https://tenant.kzoplatform.com/api/user_editable_user_custom_attributes/1283765452136257313 HTTP/1.1 

HTTP/1.1 204 No Content 
Rustici Engine Configuration
GET /api/feature_configs/RUSTICI_ENGINE
POST /api/feature_configs/RUSTICI_ENGINE
GET /api/feature_configs/RUSTICI_ENGINE
GET /api/feature_configs/RUSTICI_ENGINE
Viewing Rustici Engine Configuration
GET /api/feature_configs/RUSTICI_ENGINE

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Requires feature RUSTICI_ENGINE to be enabled on tenant.

Responses

200 OK
403 Forbidden

In case when Platfrom Feature RUSTICI_ENGINE is not enabled on this tenant

404 Not Found

In case when Rustici Engine Configuration was not created for the tenant or has already been deleted

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

Note that basic_auth_user_id and basic_auth_password values are not returned in response.

GET https://tenant.kzoplatform.com/api/feature_configs/RUSTICI_ENGINE HTTP/1.1 

HTTP/1.1 200 OK 

{
    "rustici_configs": {
        "api_use_signed_launch_links": true,
        "created_at": "2018-10-25T08:07:28.511Z",
        "id": "1274401133917378003",
        "meta": {
            "actions": [
                {
                    "href": "https://localhost:8080/api/feature_configs/RUSTICI_ENGINE",
                    "label": "RUSTICI_ENGINE_CONFIG_GET",
                    "method": "GET"
                },
                {
                    "href": "https://localhost:8080/api/feature_configs/RUSTICI_ENGINE",
                    "label": "RUSTICI_ENGINE_CONFIG_EDIT",
                    "method": "PUT"
                },
                {
                    "href": "https://localhost:8080/api/feature_configs/RUSTICI_ENGINE",
                    "label": "RUSTICI_ENGINE_CONFIG_DELETE",
                    "method": "DELETE"
                }
            ]
        },
        "modified_at": "2018-10-25T08:07:28.511Z",
        "player_sco_launch_type": "FRAMESET",
        "tenant_name": "ad3fa518-36d9-45b6-89b3-57b45ec949da",
        "when_restart_registration": "NEVER"
    }
}
Creating Rustici Engine Configuration
POST /api/feature_configs/RUSTICI_ENGINE

Create Rustici Engine Configuration.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Requires feature RUSTICI_ENGINE to be enabled on tenant.

Request body

Object
rustici_configs
Object
basic_auth_user_id
string

Basic auth user id for rustici api usage

Example:
jhon_doe
basic_auth_password
string

Basic auth user pasword for rustici api usage

Example:
jhon_doe_password
api_use_signed_launch_links
boolean

If enabled, launch links generated by the API will be signed, and only signed launch links will be accepted by the player (so launch links must be generated via the API). In rustici engine documentation this parameter is named ApiUseSignedLaunchLinks

Example:
true
player_sco_launch_type
string

Specifies how the player as a whole should be launched for this course. In rustici engine documentation named as PlayerLaunchType. Available values are:

  • FRAMESET Display the player or SCO in a child frameset
  • NEW_WINDOW Display the player or SCO in a popup window
  • NEW_WINDOW_AFTER_CLICK Display the player or SCO in a popup window after prompting the user to click a link to avoid popup blocker restrictions
  • NEW_WINDOW_WITHOUT_BROWSER_TOOLBAR Display the player or SCO in a popup window (without toolbar).
  • NEW_WINDOW_AFTER_CLICK_WITHOUT_BROWSER_TOOLBAR Display the player or SCO in a popup window (without toolbar) after prompting the user to click a link to avoid popup blocker restrictions
Example:
FRAMESET
when_restart_registration
string

Determines whether or not to restart a registration when launching. In rustici engine documentation named as WhenToRestartRegistration. Available values:

  • NEVER Never restart an existing registration (never increment instance id)
  • REG_COMPLETE_NEWER_PACKAGE_VERSION_EXISTS Restart course (increment instance id) when the overall course when a newer version of the associated course package exists and course status is Complete
  • NEWER_PACKAGE_VERSION_EXISTS Restart course (increment instance id) when a newer version of the associated course package exists
  • REG_COMPLETE Restart course (increment instance id) when the course has been completed, regardless of satisfaction (pass/fail)
  • REG_SATISFIED Restart course (increment instance id) when the overall course status is ‘Satisfied’
  • REG_SATISFIED_NEWER_PACKAGE_VERSION_EXISTS Restart course (increment instance id) when the overall course is satisfied and a newer version of the associated course package exists and course status is ‘Satisfied’
  • REG_INCOMPLETE_NEWER_PACKAGE_VERSION_EXISTS Restart course (increment instance id) when the overall course is incomplete and a newer version of the associated course package exists
  • REG_FAILED Restart course (increment instance ID) when the overall course is failed
  • REG_FAILED_NEWER_PACKAGE_VERSION_EXISTS Restart course (increment instance ID) when the overall course is failed and a newer version of of the associated course package exists.
Example:
NEVER

Responses

201 Created
403 Forbidden

In case when user has no permissions or feature RUSTICI_ENGINE is not enabled on tenant

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

Note that basic_auth_user_id and basic_auth_password values are not returned in response.

POST https://tenant.kzoplatform.com/api/feature_configs/RUSTICI_ENGINE HTTP/1.1 

Content-Type: application/json

{
    "rustici_configs": {
        "basic_auth_user_id": "jhon_doe",
        "basic_auth_password": "jhon_doe_password",
        "api_use_signed_launch_links": true,
        "player_sco_launch_type": "FRAMESET",
        "when_restart_registration": "NEVER"
    }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "rustici_configs": {
        "api_use_signed_launch_links": true,
        "basic_auth_password": null,
        "basic_auth_user_id": null,
        "created_at": "2018-10-25T09:35:04.376Z",
        "id": "1274445219441415639",
        "meta": {
            "actions": [
                {
                    "href": "https://tenant.kzoplatform.com/api/feature_configs/RUSTICI_ENGINE",
                    "label": "RUSTICI_ENGINE_CONFIG_GET",
                    "method": "GET"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/feature_configs/RUSTICI_ENGINE",
                    "label": "RUSTICI_ENGINE_CONFIG_EDIT",
                    "method": "PUT"
                },
                {
                    "href": "https://tenant.kzoplatform.com/api/feature_configs/RUSTICI_ENGINE",
                    "label": "RUSTICI_ENGINE_CONFIG_DELETE",
                    "method": "DELETE"
                }
            ]
        },
        "modified_at": "2018-10-25T09:35:04.376Z",
        "player_sco_launch_type": "FRAMESET",
        "tenant_name": "0b7c7d75-6c05-4d6f-ac79-435fee9e3b80",
        "when_restart_registration": "NEVER"
    }
}
Replacing Rustici Engine Configuration
GET /api/feature_configs/RUSTICI_ENGINE

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Requires feature RUSTICI_ENGINE to be enabled on tenant.

Request body

Object
rustici_configs
Object
basic_auth_password
string

Basic auth user id for rustici api usage

Example:
john_doe_password
basic_auth_user_id
string

Basic auth user pasword for rustici api usage

Example:
john_doe
api_use_signed_launch_links
boolean

If enabled, launch links generated by the API will be signed, and only signed launch links will be accepted by the player (so launch links must be generated via the API). In rustici engine documentation named as ApiUseSignedLaunchLinks

Example:
true
player_sco_launch_type
string

Specifies how the player as a whole should be launched for this course. In rustici engine documentation named as PlayerLaunchType.

Available values are:

  • FRAMESET Display the player or SCO in a child frameset
  • NEW_WINDOW Display the player or SCO in a popup window
  • NEW_WINDOW_AFTER_CLICK Display the player or SCO in a popup window after prompting the user to click a link to avoid popup blocker restrictions
  • NEW_WINDOW_WITHOUT_BROWSER_TOOLBAR Display the player or SCO in a popup window (without toolbar).
  • NEW_WINDOW_AFTER_CLICK_WITHOUT_BROWSER_TOOLBAR Display the player or SCO in a popup window (without toolbar) after prompting the user to click a link to avoid popup blocker restrictions
Example:
FRAMESET
when_restart_registration
string

Determines whether or not to restart a registration when launching. In rustici engine documentation named as WhenToRestartRegistration.

Available values:

  • NEVER Never restart an existing registration (never increment instance id)
  • REG_COMPLETE_NEWER_PACKAGE_VERSION_EXISTS Restart course (increment instance id) when the overall course when a newer version of the associated course package exists and course status is Complete
  • NEWER_PACKAGE_VERSION_EXISTS Restart course (increment instance id) when a newer version of the associated course package exists
  • REG_COMPLETE Restart course (increment instance id) when the course has been completed, regardless of satisfaction (pass/fail)
  • REG_SATISFIED Restart course (increment instance id) when the overall course status is ‘Satisfied’
  • REG_SATISFIED_NEWER_PACKAGE_VERSION_EXISTS Restart course (increment instance id) when the overall course is satisfied and a newer version of the associated course package exists and course status is ‘Satisfied’
  • REG_INCOMPLETE_NEWER_PACKAGE_VERSION_EXISTS Restart course (increment instance id) when the overall course is incomplete and a newer version of the associated course package exists
  • REG_FAILED Restart course (increment instance ID) when the overall course is failed
  • REG_FAILED_NEWER_PACKAGE_VERSION_EXISTS Restart course (increment instance ID) when the overall course is failed and a newer version of of the associated course package exists.
Example:
NEVER

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/feature_configs/RUSTICI_ENGINE HTTP/1.1 

Content-Type: application/json

{
    "rustici_configs": {
        "basic_auth_password": "john_doe_password",
        "basic_auth_user_id": "john_doe",
        "api_use_signed_launch_links": false,
        "player_sco_launch_type": "NEW_WINDOW",
        "when_restart_registration": "REG_COMPLETE"
    }
}

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "rustici_configs": {
        "api_use_signed_launch_links": false,
        "created_at": "2018-10-25T10:12:46.575Z",
        "id": "1274464195420624355",
        "meta": {
            "actions": [
                {
                    "href": "https://localhost:8080/api/feature_configs/RUSTICI_ENGINE",
                    "label": "RUSTICI_ENGINE_CONFIG_GET",
                    "method": "GET"
                },
                {
                    "href": "https://localhost:8080/api/feature_configs/RUSTICI_ENGINE",
                    "label": "RUSTICI_ENGINE_CONFIG_EDIT",
                    "method": "PUT"
                },
                {
                    "href": "https://localhost:8080/api/feature_configs/RUSTICI_ENGINE",
                    "label": "RUSTICI_ENGINE_CONFIG_DELETE",
                    "method": "DELETE"
                }
            ],
            "pagination": {
                
            }
        },
        "modified_at": "2018-10-25T10:12:51.515Z",
        "player_sco_launch_type": "NEW_WINDOW",
        "tenant_name": "6581ead5-9d61-4f53-8b7c-45d3aae12deb",
        "when_restart_registration": "REG_COMPLETE"
    }
}
Deleting Rustici Engine Configuration
GET /api/feature_configs/RUSTICI_ENGINE

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Requires feature RUSTICI_ENGINE to be enabled on tenant.

Rustici Engine Course
POST /api/media/{id}/rustici_engine_course
GET /api/rustici_engine_courses/{id}
POST /api/rustici_engine_courses/{id}/process
Creating Rustici Engine Course
POST /api/media/{id}/rustici_engine_course

Create course for media.

Requires Permission assigning Role CONTENT_CREATOR on the parent Container of the given Medium.

Requires Medium to be created with content_type equal to RUSTICI_ENGINE_COURSE.

Requires feature RUSTICI_ENGINE to be enabled on tenant.

Path variables

id
number required

Medium identifier

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/api/media/{id}/rustici_engine_course HTTP/1.1 

HTTP/1.1 201 Created 

{
       "rustici_engine_course": {
        "created_at": "2018-10-29T09:18:19.507Z",
        "href": "https://localhost:8080/api/rustici_engine_courses/1277335852606822197",
        "id": "1277335852606822197",
        "meta": {
            "actions": [
                {
                    "href": "https://tenant-upload.s3-external-1.amazonaws.com/kzo123/RUSTICI_ENGINE_COURSE/1277335852606822197.zip?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20181029T091819Z&X-Amz-SignedHeaders=host&X-Amz-Expires=86400&X-Amz-Credential=AKISOMETEST181029%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Signature=dd8SOMETESTVALUEe7d9134",
                    "label": "RUSTICI_ENGINE_COURSE_UPLOAD_WITH_PRESIGNED_URL",
                    "method": "PUT"
                }
            ],
            "pagination": {
                
            },
            "state": {
                "pipeline_resource": {
                    "href": "https://tenant.kzoplatform.com/api/rustici_engine_courses/1277335852606822197",
                    "type": "RUSTICI_ENGINE_COURSE"
                },
                "pipeline_status": "CREATED",
                "published": true
            }
        },
        "modified_at": "2018-10-29T09:18:19.507Z",
        "re_languages": []
    }
}
Viewing Rustici Engine Course
GET /api/rustici_engine_courses/{id}

Requires Permission assigning Role CONTENT_CREATOR on the parent Container of the related Medium.

Requires feature RUSTICI_ENGINE to be enabled on tenant.

Path variables

id
string required

rustici engine course identifier

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included at most: created_by, modified_by, media.

Examples

Example result for course that was created and was not sent to processing

GET https://tenant.kzoplatform.com/api/api/rustici_engine_courses/1277339389478836046

HTTP/1.1  200 OK

{
    "linked": {
    },
    "rustici_engine_course": {
        "course_learning_standard": null,
        "created_at": "2018-10-29T09:25:21.134Z",
        "href": "https://tenant.kzoplatform.com/api/rustici_engine_courses/1277339389478836046",
        "id": "1277339389478836046",
        "links": {
            "created_by": {
                
            },
            "deleted_by": {
                
            },
            "modified_by": {
                
            }
        },
        "meta": {
            "actions": [
                {
                    "href": "https://kzo-tenant-upload.s3-external-1.amazonaws.com/kzo3/RUSTICI_ENGINE_COURSE/1277339389478836046.zip?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20181029T092533Z&X-Amz-SignedHeaders=host&X-Amz-Expires=86400&X-Amz-Credential=AKIASISOMETESTVALUE%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Signature=1ea5fc31011111111122222222222223333879596a29b0",
                    "label": "RUSTICI_ENGINE_COURSE_UPLOAD_WITH_PRESIGNED_URL",
                    "method": "PUT"
                }
            ],
            "pagination": {
                
            },
            "state": {
                "pipeline_resource": {
                    "href": "https://tenant.kzoplatform.com/api/rustici_engine_courses/1277339389478836046",
                    "type": "RUSTICI_ENGINE_COURSE"
                },
                "pipeline_status": "CREATED",
                "published": true
            }
        },
        "modified_at": "2018-10-29T09:25:21.134Z",
        "re_languages": [
            
        ]
    }
}

Example for processed course with included media, creator and modifier

GET https://tenant.kzoplatform.com/api/rustici_engine_courses/{id}?include=created_by,modified_by,media

HTTP/1.1  200 OK
{
    "linked": {
        "media": [
            {
                "content_type": "RUSTICI_ENGINE_COURSE",
                "id": "1277393742902334487",
                ...
            }
        ],
        "users": [
            {
                "username": "admin"
                ...
            }
        ]
    },
    "rustici_engine_course": {
        "course_learning_standard": "SCORM_12",
        "created_at": "2018-10-29T11:13:21.397Z",
        "href": "https://tenant.kzoplatform.com/api/rustici_engine_courses/1277393749898433572",
        "id": "1277393749898433572",
        "links": {
            "created_by": {
                "type": "users",
                "username": "admin"
            },
            "deleted_by": {
                
            },
            "media": "1277393742902334487",
            "modified_by": {
                "type": "users",
                "username": "admin"
            }
        },
        "meta": {
            "actions": [
                {
                    "href": "https://d1nqj7fk8ojzpc.cloudfront.net/kzo3/RUSTICI_ENGINE_COURSE/1277393749898433572.zip?Expires=1540898173&Signature=F9Ew~HseQ7cLv6oN~8kCdFHAGmglJcO8zBZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ4nB~CwCrPdHjyww~-oc5fVhtCQWe8ixNGapPMzhOHaKlSYGbEhg~dDDbSj5YZZZZZZZZZZZZZZZZZZZZZZZZZZmmHr9NkpLKYzs6Q7ageArKRNqvkMxJ6~1afWvQ__&Key-Pair-Id=APVVVVVVVVVVVVV2ADMA",
                    "label": "RUSTICI_ENGINE_COURSE_DOWNLOAD",
                    "method": "GET"
                }
            ],
           "state": {
                "pipeline_resource": {
                    "href": "https://tenant.kzoplatform.com/api/rustici_engine_courses/1277393749898433572",
                    "type": "RUSTICI_ENGINE_COURSE"
                },
                "pipeline_status": "READY",
                "published": true
            }
        },
        "modified_at": "2018-10-29T11:16:13.293Z",
        "re_languages": [
        ]
    }
}
Processing Rustici Engine Course
POST /api/rustici_engine_courses/{id}/process

Performs the following speps:

  • Copy course from uploads bucket to storage
  • Create download link for the course
  • Call Rustici Engine endpoint /courses/importJobs with created course link
  • Return the result

Path variables

id
string required

Course identifier

Responses

201 Created
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/api/rustici_engine_courses/1277335852606822197/process

HTTP/1.1 201 Created 

{
       "rustici_engine_course": {
        "created_at": "2018-10-29T09:18:19.507Z",
        "href": "https://localhost:8080/api/rustici_engine_courses/1277335852606822197",
        "id": "1277335852606822197",
        "meta": {
            "actions": [
                {
                    "href": "https://tenant-upload.s3-external-1.amazonaws.com/kzo123/RUSTICI_ENGINE_COURSE/1277335852606822197.zip?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20181029T091819Z&X-Amz-SignedHeaders=host&X-Amz-Expires=86400&X-Amz-Credential=AKISOMETEST181029%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Signature=dd8SOMETESTVALUEe7d9134",
                    "label": "RUSTICI_ENGINE_COURSE_UPLOAD_WITH_PRESIGNED_URL",
                    "method": "PUT"
                }
            ],
            "pagination": {
                
            },
            "state": {
                "pipeline_resource": {
                    "href": "https://tenant.kzoplatform.com/api/rustici_engine_courses/1277335852606822197",
                    "type": "RUSTICI_ENGINE_COURSE"
                },
                "pipeline_status": "PROCESSING",
                "published": true
            }
        },
        "modified_at": "2018-10-29T09:18:19.507Z",
        "re_languages": []
    }
}

Example for processing started without course file in uploads bucket

POST https://tenant.kzoplatform.com/api/api/rustici_engine_courses/1277352342269728615/process HTTP/1.1 

HTTP/1.1 201 Created 

{
    "rustici_engine_course": {
        "course_learning_standard": null,
        "created_at": "2018-10-29T09:51:05.228Z",
        "deleted_at": null,
        "href": "https://tenant.kzoplatform.com/api/rustici_engine_courses/1277352342269728615",
        "id": "1277352342269728615",
        "links": {
            "created_by": {
                
            },
            "deleted_by": {
                
            },
            "modified_by": {
                
            }
        },
        "meta": {
            "actions": [
                {
                    "href": "https://tenant-upload.s3-external-1.amazonaws.com/kzo3/RUSTICI_ENGINE_COURSE/1277352342269728615.zip?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20181029T095117Z&X-Amz-SignedHeaders=host&X-Amz-Expires=86400&X-Amz-Credential=AKIAITESTVALUE181029%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Signature=998f5745454532132132132132325",
                    "label": "RUSTICI_ENGINE_COURSE_UPLOAD_WITH_PRESIGNED_URL",
                    "method": "PUT"
                }
            ],
            "pagination": {
                
            },
            "state": {
                "error": {
                    "code": "UNEXPECTED_SYSTEM_ERROR",
                    "meta": {
                        "params": {
                            "errorText": "AmazonS3Exception: Not Found (Service: Amazon S3; Status Code: 404; Error Code: 404 Not Found; Request ID: 0371C705B03509FC; S3 Extended Request ID: puEoc/15CS+Kz1kQjT8XNLVvYTpEPv6Bp/GTLinc1K3bGycn82d5jWWH75Xq9Gr9c1ie5IhxDbA=)"
                        }
                    },
                    "title": "AmazonS3Exception: Not Found (Service: Amazon S3; Status Code: 404; Error Code: 404 Not Found; Request ID: 0371C705B03509FC; S3 Extended Request ID: puEoc/15CS+Kz1kQjT8XNLVvYTpEPv6Bp/GTLinc1K3bGycn82d5jWWH75Xq9Gr9c1ie5IhxDbA=)"
                },
                "pipeline_resource": {
                    "href": "https://tenant.kzoplatform.com/api/rustici_engine_courses/1277352342269728615",
                    "type": "RUSTICI_ENGINE_COURSE"
                },
                "pipeline_status": "ERROR",
                "published": true
            }
        },
        "modified_at": "2018-10-29T09:51:05.228Z",
        "re_languages": [
            
        ]
    }
}
Rustici Engine Registrations

API methods to manage registrations—entities representing a particular user experiencing a particular e-learning course managed through Rustici Engine. (This is unrelated to the “registration” in the context of KZO user self-registration).

POST /api/media/{medium_id}/rustici_engine_registrations
GET /api/{medium_id}/rustici_engine_registrations
GET /api/rustici_engine_registrations/{re_registration_id}
Creating Rustici Engine Registration
POST /api/media/{medium_id}/rustici_engine_registrations

Authentication

Creates a registration for the given medium and the currently-authenticated user in Engine and records it in the KZO Platform database. If the user is the anonymous user, the created entity is associated with the medium, the currently-authenticated API user, and the current session, and there can only be one registration for the anonymous user for any given medium and session. If the user is not the anonymous user, the created entity is associated with the medium and the currently-authenticated API user. There can only be one registration for any non-anonymous user and any given medium, no matter the browser session.

If the API call is successful, a link to launch the registration (that is, to launch the course for the given user) will be returned.

Path variables

medium_id
string required

id of the associated medium of type RUSTICI_ENGINE_COURSE

Responses

201 Created
409 Conflict

If there is existing registration entity for current user, medium and session

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

curl -X POST "https://tenant.kzoplatform.com/api/api/media/{medium_id}/rustici_engine_registrations" 

HTTP/1.1 201 Created  
 
Content-Type: application/json 

{
"linked":{
"users":[
{"id": "744905196160685058", "href": "https://localhost:8080/api/users/admin?page_size_related=10000",…},
{"id": "1267227458919208598", "href": "https://localhost:8080/api/users/dmitry.bekrenev%40gomolearning.com?page_size_related=10000",…}
],
"medium":[
{"id": "123", "href": "https://localhost:8080/api/media/123?page_size_related=10000",…}
]
},
"meta":{},
"rustici_engine_registrations":{
"id": null,
"href": "",
"links":{
"medium": "123",
"created_by":{
"type": "users",
"username": "admin"
}
},
"meta":{
"pagination":{},
"actions":[
{
"label": "RUSTICI_ENGINE_REGISTRATION_PLAY",
"href": "/ScormEngineInterface/defaultui/launch.jsp?jwt=wefwewef.eyJyZWRpcmVjdE9uRXhpdFVybCI6Imh0dHBzOi8vZnJvbnQtMTAzLmt6b2lubm92YXRpb25zLmNvbS9taXNjL3J1c3RpY2lfZW5naW5lL25vdGlmeS5odG1sIiwiY29uZmlndXJhdGlvbiI6IjY0YWM1M2FiLWFkMmMtNDljOS1hOTI5LTk2MzU3ZTlhNGU5NSIsInJlZ2lzdHJhdGlvbiI6IjEyNzY1MjkwMDEyODM3MjA1NjciLCJleHAiOjE1NTg3MDg3MzksImZvcmNlUmV2aWV3IjoiZmFsc2UifQ.pc-1yx2VWFg0TDLLm2fNUzDiZKV9w6m1sGXs45dWYA8&cc=null",
"method": "GET"
}
]
},
"created_at": null
}
}
Getting Rustici Engine Registration
GET /api/{medium_id}/rustici_engine_registrations

Authentication

If the currently-authenticated API user is the anonymous user, gets the Rustici Engine registration for the current user, the given medium, and the current browser session, if such a registration exists.

If the currently-authenticated API user is not the anonymous user, gets the Rustici Engine registration for the current user and the given medium (browser session is not considered).

Path variables

medium_id
string required

Id of the associated medium (which is equal to course Id in Rustici)

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

curl -X GET "https://tenant.kzoplatform.com/api/api/{medium_id}/rustici_engine_registrations"  \
 -d '{
    "linked": {
    },
    "meta": {
    },
    "rustici_engine_registrations": [
        {
            "id": "1276517238291043695",
            "href": "",
            "links": {
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "RUSTICI_ENGINE_REGISTRATION_DELETE",
                        "href": "https://localhost:8080/api/rustici_engine_registrations/1276517238291043695",
                        "method": "DELETE"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_REGISTRATIONS_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations",
                        "method": "GET"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_RECENT_REGISTRATION_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations?last=true",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2018-10-28T06:11:52.474Z"
        },
        {
            "id": "1276514713286481261",
            "href": "",
            "links": {
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "RUSTICI_ENGINE_REGISTRATION_DELETE",
                        "href": "https://localhost:8080/api/rustici_engine_registrations/1276514713286481261",
                        "method": "DELETE"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_REGISTRATIONS_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations",
                        "method": "GET"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_RECENT_REGISTRATION_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations?last=true",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2018-10-28T06:06:52.063Z"
        },
        {
            "id": "1276521252374189425",
            "href": "",
            "links": {
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "RUSTICI_ENGINE_REGISTRATION_DELETE",
                        "href": "https://localhost:8080/api/rustici_engine_registrations/1276521252374189425",
                        "method": "DELETE"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_REGISTRATIONS_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations",
                        "method": "GET"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_RECENT_REGISTRATION_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations?last=true",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2018-10-28T06:19:51.585Z"
        },
        {
            "id": "1276518564387362160",
            "href": "",
            "links": {
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "RUSTICI_ENGINE_REGISTRATION_DELETE",
                        "href": "https://localhost:8080/api/rustici_engine_registrations/1276518564387362160",
                        "method": "DELETE"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_REGISTRATIONS_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations",
                        "method": "GET"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_RECENT_REGISTRATION_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations?last=true",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2018-10-28T06:14:30.688Z"
        },
        {
            "id": "1276527614378382710",
            "href": "",
            "links": {
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "RUSTICI_ENGINE_REGISTRATION_DELETE",
                        "href": "https://localhost:8080/api/rustici_engine_registrations/1276527614378382710",
                        "method": "DELETE"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_REGISTRATIONS_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations",
                        "method": "GET"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_RECENT_REGISTRATION_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations?last=true",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2018-10-28T06:32:29.996Z"
        },
        {
            "id": "1276526923995944309",
            "href": "",
            "links": {
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "RUSTICI_ENGINE_REGISTRATION_DELETE",
                        "href": "https://localhost:8080/api/rustici_engine_registrations/1276526923995944309",
                        "method": "DELETE"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_REGISTRATIONS_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations",
                        "method": "GET"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_RECENT_REGISTRATION_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations?last=true",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2018-10-28T06:31:07.701Z"
        },
        {
            "id": "1276529001283720567",
            "href": "",
            "links": {
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "RUSTICI_ENGINE_REGISTRATION_DELETE",
                        "href": "https://localhost:8080/api/rustici_engine_registrations/1276529001283720567",
                        "method": "DELETE"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_REGISTRATIONS_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations",
                        "method": "GET"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_RECENT_REGISTRATION_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations?last=true",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2018-10-28T06:35:15.239Z"
        },
        {
            "id": "1276526601982449012",
            "href": "",
            "links": {
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "RUSTICI_ENGINE_REGISTRATION_DELETE",
                        "href": "https://localhost:8080/api/rustici_engine_registrations/1276526601982449012",
                        "method": "DELETE"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_REGISTRATIONS_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations",
                        "method": "GET"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_RECENT_REGISTRATION_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations?last=true",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2018-10-28T06:30:29.314Z"
        },
        {
            "id": "1276522522493326706",
            "href": "",
            "links": {
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "RUSTICI_ENGINE_REGISTRATION_DELETE",
                        "href": "https://localhost:8080/api/rustici_engine_registrations/1276522522493326706",
                        "method": "DELETE"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_REGISTRATIONS_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations",
                        "method": "GET"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_RECENT_REGISTRATION_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations?last=true",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2018-10-28T06:22:23.002Z"
        },
        {
            "id": "1276515983246234990",
            "href": "",
            "links": {
                "created_by": {
                }
            },
            "meta": {
                "pagination": {
                },
                "actions": [
                    {
                        "label": "RUSTICI_ENGINE_REGISTRATION_DELETE",
                        "href": "https://localhost:8080/api/rustici_engine_registrations/1276515983246234990",
                        "method": "DELETE"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_REGISTRATIONS_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations",
                        "method": "GET"
                    },
                    {
                        "label": "RUSTICI_ENGINE_MEDIUM_RECENT_REGISTRATION_GET",
                        "href": "https://localhost:8080/api/media/1275376729589814377/rustici_engine_registrations?last=true",
                        "method": "GET"
                    }
                ]
            },
            "created_at": "2018-10-28T06:09:23.457Z"
        }
    ]
}
'
Deleting Rustici Engine Registration
GET /api/rustici_engine_registrations/{re_registration_id}

Authentication

Deletes the registration entity by id.

Path variables

re_registration_id
string required

Id of the registration

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Terms And Conditions

This group of API methods is related to Platform feature TERMS_AND_CONDITIONS.

If enabled this feature requires users to accept terms and conditions before using the Platform.

POST /api/terms_and_conditions
GET /api/terms_and_conditions
GET /api/terms_and_conditions/{id}
PUT /api/terms_and_conditions/{id}
DELETE /api/terms_and_conditions/{id}
POST /api/terms_and_conditions/{id}/acceptance
GET /api/terms_and_conditions_acceptances
Creating Terms And Conditions
POST /api/terms_and_conditions

Create Terms And Conditions.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Requires feature TERMS_AND_CONDITIONS to be enabled on tenant.

Request body

Object
terms_and_conditions
Object
active
boolean

Flag indicating that current terms and conditions are active (true) or not (false). There may be at most 1 active terms and conditions

Example:
true
title
string

Title of terms and conditions

Example:
SomeText
body
string

Body text of terms and conditions

Example:
SomeBody

Responses

201 Created
Body
Object
terms_and_conditions
Object
id
string

Identifier of created terms and conditions

Example:
1282458624114824968
active
boolean

Flag indicating that current terms and conditions are active (true) or not (false)

Example:
true
title
string

Title of terms and conditions

Example:
SomeText
body
string

Body text of terms and conditions

Example:
SomeBody
created_at
string

Creation date string representation in ISO8601 standard

Example:
2018-11-05T10:56:21.438Z
modified_at
string

Modification date string representation in ISO8601 standard, equal to creation date in response to creation.

Example:
2018-11-05T10:56:21.438Z
409 Conflict

In case when adding terms and conditions with active=true and database record with actctive=true already exists

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/terms_and_conditions HTTP/1.1 

Content-Type: application/json

{
    "terms_and_conditions": {
        "active": true,
        "title": "SomeText",
        "body": "SomeBody"
    }
}


HTTP/1.1 201 Created

{
  "terms_and_conditions": {
    "id": "1282458624114824968",
    "active": true,
    "title": "SomeText",
    "body": "SomeBody",
    "created_at": "2018-11-05T10:56:21.438Z",
    "modified_at": "2018-11-05T10:56:21.438Z",
    "meta": {
      "actions": [
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968",
          "label": "TERMS_AND_CONDITIONS_GET",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions",
          "label": "TERMS_AND_CONDITIONS_GET_ALL",
          "method": "GET"
          },
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions",
          "label": "TERMS_AND_CONDITIONS_CREATE",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968",
          "label": "TERMS_AND_CONDITIONS_UPDATE",
          "method": "PUT"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968/acceptance",
          "label": "TERMS_AND_CONDITIONS_ACCEPT",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968",
          "label": "TERMS_AND_CONDITIONS_DELETE",
          "method": "DELETE"
        }
      ]
    }
  }
}
Viewing All Terms And Conditions
GET /api/terms_and_conditions

Fetch all Terms And Conditions.

Requires authenticated user.

Request parameters

active
boolean optional

If true - return only active terms and conditions, if false return active and not active terms and conditions altogether

Default:
true

Responses

200 OK
Body
Object
terms_and_conditions
Object
id
string

Identifier of terms and conditions

Example:
1282458624114824968
active
boolean

Flag indicating that current terms and conditions are active (true) or not (false)

Example:
true
title
string

Title of terms and conditions

Example:
SomeText
body
string

Body text of terms and conditions

Example:
SomeBody
created_at
string

Creation date string representation in ISO8601 standard

Example:
2018-11-05T10:56:21.438Z
modified_at
string

Modification date string representation in ISO8601 standard

Example:
2018-11-05T10:56:21.438Z
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/terms_and_conditions HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
  "terms_and_conditions": [
    {
      "id": "1282458624114824968",
      "active": true,
      "title": "SomeText",
      "body": "SomeBody",
      "created_at": "2018-11-05T10:56:21.438Z",
      "modified_at": "2018-11-05T10:56:21.438Z",
      "meta": {
        "actions": [
          {
            "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968",
            "label": "TERMS_AND_CONDITIONS_GET",
            "method": "GET"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/terms_and_conditions",
            "label": "TERMS_AND_CONDITIONS_GET_ALL",
            "method": "GET"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/terms_and_conditions",
            "label": "TERMS_AND_CONDITIONS_CREATE",
            "method": "POST"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968",
            "label": "TERMS_AND_CONDITIONS_UPDATE",
            "method": "PUT"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968/acceptance",
            "label": "TERMS_AND_CONDITIONS_ACCEPT",
            "method": "POST"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968",
            "label": "TERMS_AND_CONDITIONS_DELETE",
            "method": "DELETE"
          }
        ]
      }
    }
  ]
}
Viewing Terms And Conditions
GET /api/terms_and_conditions/{id}

Fetch all Terms And Conditions by identifier.

Requires authenticated user.

Path variables

id
number required

Terms And Conditions identifier

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty.

What can be included at most: created_by,modified_by

Example:
created_by

Responses

200 OK
Body
Object
terms_and_conditions
Object
id
string

Identifier of terms and conditions

Example:
1282458624114824968
active
boolean

Flag indicating that current terms and conditions are active (true) or not (false)

Example:
true
title
string

Title of terms and conditions

Example:
SomeText
body
string

Body text of terms and conditions

Example:
SomeBody
created_at
string

Creation date string representation in ISO8601 standard

Example:
2018-11-05T10:56:21.438Z
modified_at
string

Modification date string representation in ISO8601 standard

Example:
2018-11-05T10:56:21.438Z
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968

HTTP/1.1 200 OK 

{
  "terms_and_conditions": {
    "id": "1282458624114824968",
    "active": true,
    "title": "SomeText",
    "body": "SomeBody",
    "created_at": "2018-11-05T10:56:21.438Z",
    "modified_at": "2018-11-05T10:56:21.438Z",
    "meta": {
      "actions": [
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968",
          "label": "TERMS_AND_CONDITIONS_GET",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions",
          "label": "TERMS_AND_CONDITIONS_GET_ALL",
          "method": "GET"
          },
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions",
          "label": "TERMS_AND_CONDITIONS_CREATE",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968",
          "label": "TERMS_AND_CONDITIONS_UPDATE",
          "method": "PUT"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968/acceptance",
          "label": "TERMS_AND_CONDITIONS_ACCEPT",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/terms_and_conditions/1282458624114824968",
          "label": "TERMS_AND_CONDITIONS_DELETE",
          "method": "DELETE"
        }
      ]
    }
  }
}
Updating Terms And Conditions
PUT /api/terms_and_conditions/{id}

Create Terms And Conditions.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Requires feature TERMS_AND_CONDITIONS to be enabled on tenant.

Response is equal to response of Creating Terms And Conditions

Path variables

id
number required

Terms and conditions identifier

Request body

Object
terms_and_conditions
Object
active
boolean

Flag indicating that current terms and conditions sould be set active (true) or not (false)

Example:
true
title
string

Title of terms and conditions

Example:
SomeText
body
string

Body text of terms and conditions

Example:
SomeBody

Responses

200 OK
409 Conflict

In case of attempt of two active terms and conditions creation

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Deleting Terms And Conditions
DELETE /api/terms_and_conditions/{id}

Delete Terms And Conditions.

Deletion is only allowed until the first acceptance of the Terms And Conditions.

Requires Permission assigning Role MANAGE_TENANT on the root Container.

Requires feature TERMS_AND_CONDITIONS to be enabled on tenant.

Path variables

id
number required

Terms And Conditions identifier

Examples

DELETE https://tenant.kzoplatform.com/api/terms_and_conditions/1234

HTTP/1.1 204 No Content
Terms And Conditions Acceptance
POST /api/terms_and_conditions/{id}/acceptance

Accept Terms And Conditions.

Path variables

id
number required

Terms And Conditions identifier

Request parameters

include
string optional

Parameter to specify which associated entities shoud be returned by method. For example: created_by, terms_and_conditions etc. Parameters are joined with comma.

Example:
created_by,terms_and_conditions

Responses

201 Created
Body
Object
terms_and_conditions_acceptances
Object
created_at
string

Creation date in ISO8601 format

Example:
2018-11-06T09:07:20.657Z
id
string

Created acceptance identifier

Example:
1283128531630429235
409 Conflict

In case when Terms And Conditions has already been accepted.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/terms_and_conditions/1283128497941779500/acceptance 

HTTP/1.1 201 Created
{
 "terms_and_conditions_acceptances": {
        "created_at": "2018-11-06T09:07:20.657Z",
        "id": "1283128531630429235"
  }
}
Viewing All Terms And Conditions Acceptances
GET /api/terms_and_conditions_acceptances

View all All Terms And Conditions Acceptances by user, defaulted to API caller.

Requires role assigning MANAGE_IDENTITIES capability to view acceptances for other users.

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response.

Default:
created_by,terms_and_conditions
Example:
created_by

Responses

200 OK
Body
Object
terms_and_conditions_acceptances
Array
Object
created_at
string

Creation date in ISO8601 format

Example:
2018-11-06T09:07:20.657Z
id
string

Terms And Conditions identifier

Example:
1283128531630429235
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/terms_and_conditions_acceptances HTTP/1.1 

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "terms_and_conditions_acceptances": [
        {
            "created_at": "2018-11-06T10:26:25.196Z",
            "id": "1283168331708240969",
            "links": {
                "created_by": {
                    "type": "users",
                    "username": "usernamee83583ba-bb42-4782-9225-0b6fbc06c18c"
                },
                "terms_and_conditions": "1283128497941779489"
            }
        }
    ],
    "linked": {
        "terms_and_conditions": [
            {
                "id": "1283128497941779489",
                ...
                }
            }
        ],
        "users": [
            {
                "username": "usernamee83583ba-bb42-4782-9225-0b6fbc06c18c",
                ...
            }
        ]
    }
}
Self Registration
GET /api/access_keys/self_registration
Self registration configuration management

Management of configurations for self registration. Only one self registration configuration can exist on tenant.

PUT /api/feature_configs/SELF_REGISTRATION
GET /api/feature_configs/SELF_REGISTRATION
POST /api/feature_configs/SELF_REGISTRATION
Update configuration
PUT /api/feature_configs/SELF_REGISTRATION

Updates the self registration config. First input parameters are validated, then method changes the Cognito users pool using input parameters. If this step fails - no entity will be changed on the platform side. If users pool modification was successful - updates the configuration entity on the platform side and returns it to the caller.

Required capabilities: MANAGE_TENANT.

Required features to be enabled: SELF_REGISTRATION

Request parameters

feature_config_self_registration

Responses

200 OK
Body
Object
feature_config_self_registration
400 Bad request

If some of parameters was invalid

401 Unauthorized

The request requires Authentication and Authorization.

403 Forbidden

The server understood the request, but is refusing to fulfill it. Authorization will not help and the request should not be repeated.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/api/feature_configs/SELF_REGISTRATION HTTP/1.1 

Content-Type: application/json

{
  "feature_config_self_registration":{
    "name":"first_self_registration_config",
    "email_verification_from_address":"vdronov@kzoinnovations.com"
  }
}

HTTP/1.1 200 OK 

Content-Type: application/json

{
    "feature_config_self_registration": {
        "user_pool_id": "wfew",
        "user_pool_app_client_id": "fwefwef",
        "name":"first_self_registration_config",
        "email_verification_from_address":"vdronov@kzoinnovations.com",
        "autoenroll_group_id": "",
        "autoenroll_group_label": "",
        "on_selector": true
    }
}
Get configuration
GET /api/feature_configs/SELF_REGISTRATION

Gets current self registration configuration.

Required capabilities: MANAGE_TENANT.

Required features to be enabled: SELF_REGISTRATION

Create configuration
POST /api/feature_configs/SELF_REGISTRATION

Creates the self registration config. First input parameters are validated, then method created the Cognito users pool using input and predefined parameters. If this step fails - no entity will be created on the platform side. If users pool creation was successful - creates the configuration entity on the platform side and returns it to the caller.

Only one self registration configuration can exist on tenant. If for some reasons there was concurrent request to create similar entity and it was first - then 409th response will be sent and created users pool will be deleted.

Required capabilities: MANAGE_TENANT.

Required features to be enabled: SELF_REGISTRATION

Request body

Object
feature_config_self_registration

Responses

201 Created
Body
Object
feature_config_self_registration
409 Conflict

If configuration allready exists or was created simultaneously with current attempt.

400 Bad request

If some of input parameters was invalid

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/api/feature_configs/SELF_REGISTRATION HTTP/1.1 

Content-Type: application/json

{
    "feature_config_self_registration": {
        "name": "self reg",
        "email_verification_subject": "Verification message",
        "email_verification_from_address": "vdronov@kzoinnovations.com",
        "email_verification_body": "Hello  {username}, your verification code is {####}"
    }
}

HTTP/1.1 201 Created 

Content-Type: application/json

{
    "feature_config_self_registration": {
        "user_pool_id": "wefw12e",
        "user_pool_app_client_id": "wegtxvcvx11",
        "email_verification_from_address": "vdronov@kzoinnovations.com",
        "name": "self reg",
        "autoenroll_group_id": "",
        "autoenroll_group_label": "",
        "on_selector": true
    }
}
Self Registration Obtain Access Key By Token
GET /api/access_keys/self_registration

Obtain Access Key b Cognito access token.

Response is equal to Creating Session Access Key: Password Authentication

Request parameters

access_token
string required

Cognito access token

browser_session_id
string optional

Browser session identifier

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Container Locking
PUT /container_locking_lock/{lockId}
DELETE /container_locking_lock/{lockId}
GET /container_locking_lock
GET /container_locking_lock/{lockId}
POST /containers/{container_id}/container_locking_lock
Updating Container Locking Lock
PUT /container_locking_lock/{lockId}

Update Container Locking Lock.

Requires Permission assigning Role UPDATE_CONTENT on the Container related to the lock being updated.

Path variables

lockId
string required

container locking lock identifier

Request body

Object
title
string

Title describing the lock

Example:
sample title
prerequisite_containers
Array

Prerequisite container identifiers

Example:
[8789789789,767676645545]
integer
Example:
8789789789

Responses

200 OK

The response is the same as that of the method Viewing Container Locking Lock.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Deleting Container Locking Lock
DELETE /container_locking_lock/{lockId}

Delete Container Locking Lock.

Requires Permission assigning Role UPDATE_CONTENT on the Container related to the lock being deleted.

Path variables

lockId
integer required

container locking lock identifier

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Searching Container Locking Locks
GET /container_locking_lock

Does not require Permissions.

Only locks for containers that are available to the caller will be returned.

Request parameters

container_id
number optional

Optional identifier of container, related to lock. If not null only related lock will be returned.

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included: container,created_by,modified_by,container_locking_locks

Responses

200 OK
Body
Object
container_locking_locks
Array
Object
title
string

Title describing the lock

Example:
sample lock
created_at
string

Creation date

Example:
2019-01-30T14:48:01.679Z
modified_at
string

Last modification date

Example:
2019-01-30T14:48:01.679Z
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/container_locking_lock HTTP/1.1 

HTTP/1.1 200 OK 

{
  "container_locking_locks": [
    {
      "id": "1344905940503107450",
      "created_at": "2019-01-30T14:48:01.679Z",
      "modified_at": "2019-01-30T14:48:01.679Z",
      "title": "sample lock",
      "links": {
        "container": "1345433298716857476",
        "created_by": {
          "type": "users",
          "username": "admin"
        },
        "modified_by": {
          "type": "users",
          "username": "admin"
        },
        "prerequisite_containers": [
          "1345433300629460107"
        ]
      },
      "meta": {
        "actions": [
          {
            "href": "https://tenant.kzoplatform.com/api/container_locking_locks/1344905940503107450",
            "label": "CONTAINER_LOCKING_LOCK_DELETE",
            "method": "DELETE"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/container_locking_lock/1344905940503107450",
            "label": "CONTAINER_LOCKING_LOCK_UPDATE",
            "method": "PUT"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/container_locking_locks/1344905940503107450",
            "label": "CONTAINER_LOCKING_LOCK_GET",
            "method": "GET"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/container_locking_locks",
            "label": "CONTAINER_LOCKING_LOCK_GET_ALL",
            "method": "GET"
          }
        ]
      }
    }],
    "linked":
    {
      "container": [
        ...
      ],
      "users": [
        ...
      ]
    }
}
Viewing Container Locking Lock
GET /container_locking_lock/{lockId}

View information about given Container Locking Lock object.

Requires Permission assigning Role VIEWER on the Container related to the given Container Locking Lock object.

Path variables

lockId
integer required

Container Locking Lock identifier

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. Default value: empty. What can be included: container,created_by,modified_by,container_locking_locks

Responses

200 OK
Body
Object
container_locking_locks
Object
id
string

Container Locking Lock Identifier

Example:
1344905940503107450
title
string

Title describing the lock

Example:
sample lock
created_at
string

Creation date

Example:
2019-01-30T14:48:01.679Z
modified_at
string

Update date

Example:
2019-01-30T14:48:01.679Z
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/container_locking_lock/1344905940503107450 HTTP/1.1 

HTTP/1.1 200 OK 

{
  "container_locking_locks": {
    "id": "1344905940503107450",
    "created_at": "2019-01-30T14:48:01.679Z",
    "modified_at": "2019-01-30T14:48:01.679Z",
    "title": "sample lock",
    "links": {
      "container": "1344905930889762653",
      "created_by": {
        "type": "users",
        "username": "admin"
      },
      "modified_by": {
        "type": "users",
        "username": "admin"
      },
      "prerequisite_containers": [
        "1344905933557340004"
      ]
    },
    "meta": {
      "actions": [
        {
          "href": "https://tenant.kzoplatform.com/api/container_locking_locks/1344905940503107450",
          "label": "CONTAINER_LOCKING_LOCK_DELETE",
          "method": "DELETE"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/container_locking_lock/1344905940503107450",
          "label": "CONTAINER_LOCKING_LOCK_UPDATE",
          "method": "PUT"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/container_locking_locks/1344905940503107450",
          "label": "CONTAINER_LOCKING_LOCK_GET",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/container_locking_locks",
          "label": "CONTAINER_LOCKING_LOCK_GET_ALL",
          "method": "GET"
        }
      ]
    }
  },
  "linked": {
    "container": [
      ...
    ],
    "users": [
      ...
    ]
  }
}
Create Container Locking Lock
POST /containers/{container_id}/container_locking_lock

Create Container Locking Lock.

Requires Permission assigning Role UPDATE_CONTENT on the given Container.

Path variables

container_id
string required

Identifier of container related to lock

Request body

Object
title
string

Title describing the lock

Example:
sample_lock
prerequisite_containers
Array of number

Prerequisite container identifiers

Example:
["1344905933557340004","1344905933557340005"]

Responses

201 Created

The response content is the same as that of the method Viewing Container Locking Lock.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Self Registration Token
POST /self_registration_tokens
GET /self_registration_tokens/{id}
GET /self_registration_tokens
POST /self_registration_tokens/{id}/activate
POST /self_registration_tokens/{id}/deactivate
DELETE /self_registration_tokens/{id}
PUT /self_registration_tokens/{id}
POST /self_registration_tokens/{id}
GET /self_registration_tokens/verify
GET /misc/csv/token_export
Creating Self Registration Token
POST /self_registration_tokens

Creates a Self Registration Token.

Requires Permission assigning Role SELF_REGISTRATION_TOKEN_MANAGER

Request body

Object
self_registration_tokens
Object

Information on self registration token

name
string

Name of token, should be unique

Example:
Some name
expires_at
string

Date of token expiration, string representation in ISO8601 standard

Example:
2019-05-14T09:00:26.715Z
max_number_of_uses
integer

Number of times the token can be used

Example:
100
description
string

Description of token

Example:
Some token

Responses

201 Created
409 Conflict

In case when Self Registration Token added with name that already exists.

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

POST https://tenant.kzoplatform.com/api/self_registration_tokens HTTP/1.1 

Content-Type: application/json

{
    "self_registration_tokens": {
        "name": "Some name",
        "expires_at": "2019-11-14T09:00:26.715Z",
        "max_number_of_uses": 100
    }
}

HTTP/1.1 201 Created

{
  "self_registration_tokens": {
    "code": "VS99JFMI",
    "created_at": "2019-07-24T05:09:48.787Z",
    "expires_at": "2019-11-14T09:00:26.715Z",
    "id": "1471450668383343789",
    "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
    "is_active": true,
    "max_number_of_uses": 100,
    "number_of_uses": 0,
    "meta": {
      "actions": [
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
          "label": "SELF_REGISTRATION_TOKEN_UPDATE",
          "method": "PUT"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
          "label": "SELF_REGISTRATION_TOKEN_DELETE",
          "method": "DELETE"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789/duplicate",
          "label": "SELF_REGISTRATION_TOKEN_DUPLICATE",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
          "label": "SELF_REGISTRATION_TOKEN_GET",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789/deactivate",
          "label": "SELF_REGISTRATION_TOKEN_DEACTIVATE",
          "method": "POST"
        }
      ]
    },
    "modified_at": "2019-07-24T05:09:48.787Z",
    "name": "Some name"
  }
}
Viewing Self Registration Token
GET /self_registration_tokens/{id}

Requires Permission assigning Role SELF_REGISTRATION_TOKEN_MANAGER

Path variables

id
number required

identifier of Self Registration Token

Request parameters

include
string optional

Comma-separated list of associated objects which should be included in the response. At most may inclide: modified_by,created_by

Responses

200 OK
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789 HTTP/1.1 

HTTP/1.1 200 OK 
{
  "self_registration_tokens": {
    "code": "VS99JFMI",
    "created_at": "2019-07-24T05:09:48.787Z",
    "expires_at": "2019-11-14T09:00:26.715Z",
    "id": "1471450668383343789",
    "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
    "is_active": true,
    "max_number_of_uses": 100,
    "number_of_uses": 0,
    "meta": {
      "actions": [
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
          "label": "SELF_REGISTRATION_TOKEN_UPDATE",
          "method": "PUT"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
          "label": "SELF_REGISTRATION_TOKEN_DELETE",
          "method": "DELETE"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789/duplicate",
          "label": "SELF_REGISTRATION_TOKEN_DUPLICATE",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
          "label": "SELF_REGISTRATION_TOKEN_GET",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789/deactivate",
          "label": "SELF_REGISTRATION_TOKEN_DEACTIVATE",
          "method": "POST"
        }
      ]
    },
    "modified_at": "2019-07-24T05:09:48.787Z",
    "name": "Some name"
  }
}
Searching Self Registration Tokens
GET /self_registration_tokens

Fetch Self Registration Tokens satisfying specific criteria.

At most 100 tokens are returned. Result list is ordered by token identifier in descending order.

Requires Permission assigning Role SELF_REGISTRATION_TOKEN_MANAGER

Request parameters

q
string optional

string to filter by name, code, created_at, expires_at, description(dates are matched as strings)

include
string optional

Comma-separated list of associated objects which should be included in the response. At most may inclide: modified_by,created_by

Responses

200 OK
Body
Object
self_registration_tokens
Array
Object
id
string

Identifier of Self Registration Token

Example:
1471450668383343789
name
string

Name of token

Example:
Some name
code
string

Token code

Example:
VS99JFMI
is_active
boolean

State of token true - token is active, false - token is inactive

Example:
true
max_number_of_uses
integer

Number of times the token can be used

Example:
100
expires_at
string

Date of token expiration, string representation in ISO8601 format

Example:
2019-11-14T09:00:26.715Z
created_at
string

Date of token creation, string representation in ISO8601 format

Example:
2019-07-24T05:09:48.787Z
modified_at
string

Date of last token modification, string representation in ISO8601 format

Example:
2019-07-24T05:09:48.787Z
number_of_uses
integer

Number of current uses of token

Example:
10
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

GET https://tenant.kzoplatform.com/api/self_registration_tokens?q=Some%20name HTTP/1.1 

HTTP/1.1 200 OK 
{
  "self_registration_tokens": [
    {
      "code": "VS99JFMI",
      "created_at": "2019-07-24T05:09:48.787Z",
      "expires_at": "2019-11-14T09:00:26.715Z",
      "id": "1471450668383343789",
      "is_active": true,
      "max_number_of_uses": 100,
      "number_of_uses": 10,
      "meta": {
        "actions": [
          {
            "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
            "label": "SELF_REGISTRATION_TOKEN_UPDATE",
            "method": "PUT"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
            "label": "SELF_REGISTRATION_TOKEN_DELETE",
            "method": "DELETE"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789/duplicate",
            "label": "SELF_REGISTRATION_TOKEN_DUPLICATE",
            "method": "POST"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
            "label": "SELF_REGISTRATION_TOKEN_GET",
            "method": "GET"
          },
          {
            "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789/deactivate",
            "label": "SELF_REGISTRATION_TOKEN_DEACTIVATE",
            "method": "POST"
          }
        ]
      },
      "modified_at": "2019-07-24T05:09:48.787Z",
      "name": "Some name"
    }
  ],
  "linked": {
      ...
  }
}
Activating Self Registration Token
POST /self_registration_tokens/{id}/activate

Activates Self Registration Token.

Requires Permission assigning Role SELF_REGISTRATION_TOKEN_MANAGER

Path variables

id
number required

token identifier

Responses

200 OK

In case of successful activation

400 Bad Request

In case when token is already in active state

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Deactivating Self Registration Token
POST /self_registration_tokens/{id}/deactivate

Deactivates Self Registration Token.

Requires Permission assigning Role SELF_REGISTRATION_TOKEN_MANAGER

Path variables

id
number required

token identifier

Responses

200 OK
400 Bad Request

In case when token is already in inactive state

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Deleting Self Registration Token
DELETE /self_registration_tokens/{id}

Deletes Self Registration Token.

Requires Permission assigning Role SELF_REGISTRATION_TOKEN_MANAGER

Path variables

id
string required

token identifier

Responses

204 No Content
400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Updating Self Registration Token
PUT /self_registration_tokens/{id}

Updates Self Registration Token.

Requires Permission assigning Role SELF_REGISTRATION_TOKEN_MANAGER

Path variables

id
number required

token identifier

Request body

Object
self_registration_tokens
Object
name
string

Name of token, should be unique

Example:
Some name
expires_at
string

Date of token expiration, string representation in ISO8601 standard

Example:
2019-11-14T09:00:26.715Z
max_number_of_uses
integer

Number of times the token can be used

Example:
100
description
string

Description of token

Responses

200 OK
409 Conflict

In case when another token with same name already exists

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Examples

PUT https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789 HTTP/1.1 

Content-Type: application/json

{
    "self_registration_tokens": {
        "name": "Updated name",
        "expires_at": "2019-11-14T09:00:26.715Z",
        "max_number_of_uses": 100
    }
}

HTTP/1.1 200 OK

{
  "self_registration_tokens": {
    "code": "VS99JFMI",
    "created_at": "2019-07-24T05:09:48.787Z",
    "expires_at": "2019-11-14T09:00:26.715Z",
    "id": "1471450668383343789",
    "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
    "is_active": true,
    "max_number_of_uses": 100,
    "number_of_uses": 0,
    "meta": {
      "actions": [
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
          "label": "SELF_REGISTRATION_TOKEN_UPDATE",
          "method": "PUT"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
          "label": "SELF_REGISTRATION_TOKEN_DELETE",
          "method": "DELETE"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789/duplicate",
          "label": "SELF_REGISTRATION_TOKEN_DUPLICATE",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789",
          "label": "SELF_REGISTRATION_TOKEN_GET",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789/deactivate",
          "label": "SELF_REGISTRATION_TOKEN_DEACTIVATE",
          "method": "POST"
        }
      ]
    },
    "modified_at": "2019-07-24T05:09:48.787Z",
    "name": "Updated name"
  }
}
Duplicating Self Registration Token
POST /self_registration_tokens/{id}

Duplicates Self Registration Token. New token is created with new code and with date and time suffix added to name.

Requires Permission assigning Role SELF_REGISTRATION_TOKEN_MANAGER

Path variables

id
number required

token identifier

Examples

POST https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668383343789 HTTP/1.1 

HTTP/1.1 201 Created

{
  "self_registration_tokens": {
    "code": "SS32M0VT",
    "created_at": "2019-07-24T05:09:48.787Z",
    "expires_at": "2019-11-14T09:00:26.715Z",
    "id": "1471450668389767677",
    "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668389767677",
    "is_active": true,
    "max_number_of_uses": 100,
    "meta": {
      "actions": [
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668389767677",
          "label": "SELF_REGISTRATION_TOKEN_UPDATE",
          "method": "PUT"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668389767677",
          "label": "SELF_REGISTRATION_TOKEN_DELETE",
          "method": "DELETE"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668389767677/duplicate",
          "label": "SELF_REGISTRATION_TOKEN_DUPLICATE",
          "method": "POST"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668389767677",
          "label": "SELF_REGISTRATION_TOKEN_GET",
          "method": "GET"
        },
        {
          "href": "https://tenant.kzoplatform.com/api/self_registration_tokens/1471450668389767677/deactivate",
          "label": "SELF_REGISTRATION_TOKEN_DEACTIVATE",
          "method": "POST"
        }
      ]
    },
    "modified_at": "2019-07-24T05:09:48.787Z",
    "name": "Some name_2019-07-24T16:45:51.062+07"
  }
}
Verifying Self Registration Token
GET /self_registration_tokens/verify

Authentication

Open

Verifies Self Registration Token code.

Requires no Permissions.

Request parameters

code
string required

Self Registration Token Code

Responses

200 OK

In case when verification was successful

410 Gone

In case when token exists but was expired or maximum number of uses was exceeded or token was deactivated

429 Too Many Requests

In case when token check was requested too many times, try again later

400 Bad Request

The request could not be understood by the server due to malformed syntax. The client should not repeat the request without modifications.

404 Not Found

The server has not found anything matching the Request-URI.

406 Not Acceptable

The server cannot respond with content type specified in the Accept request header or the requested API Version is not supported by the server.

Exporting Self Registration Tokens To CSV
GET /misc/csv/token_export

Exports Self Registration Tokens to csv.

Requires Permission assigning Role SELF_REGISTRATION_TOKEN_MANAGER

Examples

GET https://tenant.kzoplatform.com/misc/csv/token_export HTTP/1.1 


HTTP/1.1 200 OK 

id,code,name,description,max_number_of_uses,is_active,expires_at,created_at,created_by,updated_at,updated_by
1481861432726263424,B7T1221F,some_name_ba29faf8,some description,100,true,2019-05-14T16:00:26.715,2019-08-07T20:54:08.574,1188875865522443266,2019-08-07T20:54:09.486,1188875865522443266
1481736851847911021,897490Q6,some_name_9b100b51,some description,100,true,2019-05-14T16:00:26.715,2019-08-07T16:46:37.410,1188875865522443266,2019-08-07T16:46:37.410,1188875865522443266
1481736851235542636,P29Z3ZJ4,some_name_9b100b51,some description,100,true,2019-05-14T16:00:26.715,2019-08-07T16:46:37.336,1188875865522443266,2019-08-07T16:46:37.336,1188875865522443266

Data Reference
ClientInitData

Contains initialization information

Object
meta
Object
access_key
Object
roles
Array of role
assets
Array
Object
properties
Array
Object
features
Object
languages
Array
Object
custom_attribute_categories
Array
Object
portal_name
unknown
player_sco_launch_type
Array of string
when_restart_registration
Array of string
custom_attribute_entity_types
Array
Object
custom_authn_options
Array
Object
default_authentication_option
Object
home_container
privileged_tenant_hostname
string
system_state_leap_counter
integer
recaptcha_client_id
string
supported_oauth_server_implementations
Array
Object
session_id
string
tenant_id
integer
myself

Current logged user

Self registration config input parameters

Input parameters to create self registration config.

Object
name
string required

Name of the configuration to distinguish it from other authentication options

email_verification_subject
string

Subject for email message with verification code which will be sent to user.

email_verification_from_address
string

Address to be used for reply to. This address must be registered on AWS SES first.

email_verification_body
string

Body of email verification message. Must contain placeholders: {username} - for username, {####} - verification code.

Self registration config

Schema for self registration output configuration

Object
user_pool_id
string

Id of the Cognito’s user pool. Returned for successfully created configurations only

user_pool_app_client_id
string

Id of the application registered at Cognito’s user pool with id user_pool_id

email_verification_from_address
string

Address to reply on verification message

name
string

Name of the self registration config as authentication option

autoenroll_group_id
string

Id of the group to enroll users logged in with SELF_REGISTRATION authentication option

autoenroll_group_label
string

Label of the group to enroll users logged in with SELF_REGISTRATION authentication option

on_selector
boolean

Flag meaning the this option is used as one of the possible authentication options suggested to user on special selector page.

allow_phone
boolean

Enable an option to self-register with phone number

Default:
true
default_login_type
string

Controls which login type tab is active by default

Enumeration:
PHONE
EMAIL
Default:
PHONE
media

The media object represents a single video. All other entities (such as closed captions, thumbnails, etc) belong to this

Object
id
number
Example:
234
container_id
number
Example:
12
title
string
Example:
Baby's first video!
description
string
Example:
A lovely description for your new video.
upload_url
string

The URL used for uploading video or audio

Example:
https://tenant.kzoplatform.com/files/video/4436
complete
boolean

Whether the video has completed uploading

Example:
false
closed_captions
Array of closed_caption
renditions
Array of video_rendition
chapters
Array of chapter
thumbnails
Array of thumbnail
comments
Array of comment
slide_deck
created_at
string
Example:
2012-10-10T14:12:24.324Z
created_by
number
Example:
1
modified_at
string
Example:
2012-10-10T14:12:24.324Z
modified_by
number
Example:
1
closed_caption
Object
id
number
Example:
38583
language
string
Example:
en
text
string
Example:
I'm a chapter title!
start_msec
number

start time of the caption in milliseconds

Example:
7743
end_msec
number

end time of the caption in milliseconds

Example:
10322
video_rendition
Object
id
number
Example:
94862
filesize
number
Example:
403857413
md5
string
Example:
9729bfefe48c6c088f0ffa2cea05edf5
completed
boolean
Example:
false
bitrate
number

in kbps

Example:
800
resolution
string
Example:
720
created_at
string
Example:
2012-10-10T14:12:24.324Z
created_by
number
Example:
1
modified_at
string
Example:
2012-10-10T14:12:24.324Z
modified_by
number
Example:
1
Types: media
chapter
Object
id
number
Example:
7534
text
string

Chapter title

Example:
My first chapter!
msec
number

Start time in milliseconds

Example:
1232
created_at
string
Example:
2012-10-10T14:12:24.324Z
created_by
number
Example:
1
modified_at
string
Example:
2012-10-10T14:12:24.324Z
modified_by
number
Example:
1
thumbnail
Object
id
number
Example:
8238
msec
number
Example:
5000
md5
string
Example:
9729bfefe48c6c088f0ffa2cea05edf5
href
string
Example:
https://tenant.kzoplatform.com/files/thumbnails/234223.jpg
size
string
Example:
34938
created_at
string
Example:
2012-10-10T14:12:24.324Z
created_by
number
Example:
1
modified_at
string
Example:
2012-10-10T14:12:24.324Z
modified_by
number
Example:
1
Types: media
comment
Object
id
number
Example:
1
media_id
number
Example:
1
parent_id
unknown
text
string
Example:
This video is great!
msec
string
Example:
5500
created_at
string
Example:
2012-10-10T14:12:24.324Z
created_by
number
Example:
1
modified_at
string
Example:
2012-10-10T14:12:24.324Z
modified_by
number
Example:
1
deleted_at
string
Example:
2012-10-10T16:34:23.871Z
deleted_by
number
Example:
1
slide_deck
Object
id
number
Example:
553
slides
Array of string
created_at
string
Example:
2012-10-10T14:12:24.324Z
created_by
number
Example:
1
modified_at
string
Example:
2012-10-10T14:12:24.324Z
modified_by
number
Example:
1
Types: media
session_access_key
Object
access_key_id
string
Example:
AKIAIOSFODNN7EXAMPLE
secret_access_key
string
Example:
wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY
expiration
string
Example:
2014-10-10T14:12:23.324Z
session_token
string
Example:
ddkfssdfvDNN7EXAMPLE
status
string
Example:
ACTIVE
user
container
Object
id
number

Auto-generated

Example:
14
root
boolean

Auto-generated. Whether or not this is the root of the container tree

Example:
false
published
boolean

Auto-generated

Example:
false
display
boolean

Whether or not this container should be visible and displayed to the end user. This is helpful when using containers for organization

Example:
false
title
string

The name of the container. Only needed if visible is set to true

Example:
Marketing Videos
items
Array of item

The “playlist” of the container. Displays an ordered list of videos and other containers

parent_container_id
number
Example:
1
description
string

Optional description for the container

Example:
My awesome description for this container
playlist_schema

defines the order and various properties of the container

Object
id
number
Example:
1
parent_container_id
number
Example:
1
child_container_id
number

Either a child_container_id must be supplied OR a media_id, not both.

Example:
1
media_id
number

Either a child_container_id must be supplied OR a media_id, not both.

Example:
234
order
number
Example:
1
type
string

enum(‘original’, ‘view-only’, ‘admin’) needs work

item

Abstraction used by playlist model to represent either a container or media object

Object
id
number
Example:
1
order
number
Example:
1
media

Either media or container will be returned, never both.

container
Array of container

Either media or container will be returned, never both.

link_type
string
Example:
original
Types: container
acl_response

A mapping between roles, groups, and containers

Object
id
number
Example:
5683
role
Example:
12
group
Example:
43
container_id
number
Example:
234
role
Object
id
number
Example:
12
name
string
Example:
admin
abilities
Array of string
Example:
CREATE CONTENT
ability
Object
name
string
Example:
CREATE CONTENT
group
Object
id
number
Example:
48
name
string
Example:
Marketing
members
Array of user
Types: acl_response
user
Object
id
number
Example:
5542
username
string
Example:
admin
password
string
email
string
Example:
admin@example.org
avatar_url
string
Example:
https://tenant.kzoplatform.com/files/avatar/5542
firstname
string required
lastname
string required
locale

preferred user’s locale

Default:
en
search_result
Object
total_count
number

total number of matches

Example:
65
page
number
Example:
1
query
string
Example:
search term here
domain
string

everything, slides, closed_captions, comments

Example:
everything
items
Array
Object
media
comments
Array of comment

All comments belonging to the media that match the search query

chapters
Array of chapter

All chapters belonging to the media that match the search query

closed_captions
Array of closed_caption

All closed captions belonging to the media that match the search query

slide
Array of slide

All slides belonging to the media that match the search query

slide

Individual slide that belongs to a slide_deck

Object
id
number
Example:
8563
page_number
number

What page in the slide deck this represents

Example:
3
text
string

The text contained on the slide

search_meta
Object
Items
Object data_container

Data container (//TODO provide better description)

count
number
Example:
1
page
number
Example:
1
query
string
domain
string

The search domain. e.g. slides, chapters, etc

Example:
everything
Custom attribute parameters

Parameters of custom attribute

Object
Example:
{
    "name": "person",
    "description": "Typical person",
    "entity_type": "USER",
    "category": "TENANT__MUTABLE__TENANT",
    "json_schema": "{\\r\\n  \\\"$schema\\\": \\\"http:\\/\\/json-schema.org\\/draft-04\\/schema#\\\",\\r\\n  \\\"description\\\": \\\"Person object\\\",\\r\\n  \\\"type\\\": \\\"object\\\",\\r\\n  \\\"properties\\\": {\\r\\n    \\\"name\\\": {\\r\\n      \\\"type\\\": \\\"string\\\"\\r\\n    },\\r\\n    \\\"age\\\": {\\r\\n      \\\"type\\\": \\\"number\\\"\\r\\n    }\\r\\n  },\\r\\n  \\\"required\\\":[\\\"name\\\",\\\"age\\\"]\\r\\n}",
    "default_value": "{\\r\\n  \\\"name\\\":\\\"john smith\\\",\\r\\n  \\\"age\\\": 22\\r\\n}"
}
name
string required

Name of the attribute

description
string nullable

Short description of the attribute

Type of related entity

category

Syntetical parameter to define the following parameters of the attribute:

  • scope
  • mutability
  • customization level
Example:
TENANT__MUTABLE__TENANT
json_schema
string required

JSON schema to define structural base of values for attributes

Example:
{\r\n \"$schema\": \"http:\/\/json-schema.org\/draft-04\/schema#\",\r\n \"description\": \"Person object\",\r\n \"type\": \"object\",\r\n \"properties\": {\r\n \"name\": {\r\n \"type\": \"string\"\r\n },\r\n \"age\": {\r\n \"type\": \"number\"\r\n }\r\n },\r\n \"required\":[\"name\",\"age\"]\r\n}
default_value
string nullable

Default value of the attribute

Example:
{\r\n \"name\":\"john smith\",\r\n \"age\": 22\r\n}
Custom attribute value

Structure of value entity for custom attribute

Object
CA value

Value of custom attribute

Object
Example:
{
  "custom_attribute_values": {
     "custom_attribute_name" : "kzo.test.ca-content-objects.config.container",
     "category" : "TENANT__MUTABLE__TENANT",
     "entity": "CONTAINER",
     "value": "TEEES!!T",
     "container_id": 1365115148494181441
  } 
}
category

Category of the custom attribute

Example:
DEPLOY__IMMUTABLE__DEPLOY
custom_attribute_name
string required

Name of the custom attribute

Min length: 1
Example:
ca1

Type of entity CA relates to

deploy_value
boolean

Flag to distinguish between tenant and deploy level for custom attribute value with category DEPLOY__MUTABLE__DEPLOY_TENANT

media_id
integer

Id of the medium, if CA relates to media

user_id
integer

Id of the user, if CA relates to users

value
Object required

value of custom attribute which satisfies schema of attribute

Example:
{"rectangle":{"name":"simple square"}}
container_id
integer

Id of the container, if CA relates to containers

SamlConfig
Object
key_alias
string

Key alias to fetch encryption/signing key from keystore

Pattern: ^[a-zA-Z0-9_]+$
idp_metadata
string

SAML identity provider metadata, typically XML

idp_metadata_url
string
Example:
External URL of IdP metadata that can be used to update the metadata locally
idp_metadata_autoupdate
boolean
Default:
false
idp_id
string required

Identifier of SAML identity provider

sp_id
string

Identifier of SAML service provider

username_attr
string

The name of attribute of SAML assertion, which value should be treated as username

first_name_attr
string

The name of attribute of SAML assertion, which value should be treated as user’s first name

last_name_attr
string

The name of attribute of SAML assertion, which value should be treated as user’s last name

email_attr
string

The name of attribute of SAML assertion, which value should be treated as user’s email

locale_attr
string

The name of attribute of SAML assertion, which value should be treated as user’s locale

phone_number_attr
string

The name of attribute of SAML assertion, which value should be treated as user’s phone number

redirect_to_relay_state_enabled
boolean

If true, the value present in RelayState of SAML assertion will be treated as URL to redirect user after successful SAML login

response_skew_sec
integer

Maximum time from response creation when the message is deemed valid.

Min: 1
slo_enabled
boolean

Whether single logout is enabled

Custom attribute effective value

Effective value of a custom attribute.

Object
custom_attribute_name
string

Name of custom attribute

category
string
entity
string
value
unknown

JSON object

media_id
integer

Id of media can be filled only for CAEVs with entity type MEDIUM

user_id
integer

Id of user can be filled only for CAEVs with entity type USER

container_id
integer

Id of container can be filled only for CAEVs with entity type CONTAINER

Level of value

Enums
LanguageCode

Enumeration of codes supported languages

string
Enumeration:
en

English

en_GB

English British

fr

French

de

German

it

Italian

Types: user
AuthenticationType

Users authentication type

string
Enumeration:
NONE
PASSWORD
PUBLIC
IPAAS
SAML
INTEGRATION_RESIDENT
INTEGRATION_VISITOR
CustomAttributeOnContentHierarchyConfigFunction

CustomAttributeOnContentHierarchy value aggregating function

string
Enumeration:
MIN_INDEX

Get value with minimal index in list while grouping

MAX_INDEX

Get value with maximum index in list while grouping

CustomAttributeCategory

The first component of the triplet defines scope of the CA: whether it is the whole Deploy, in which case it can only be defined on the privileged Tenant, or just the current Tenant. The second component of the triplet defines whether the declaration of the CA can be modified or deleted.

Obviously, this can only be done on the Tenant where the CA is declared. When it is immutable, the intention is to create and modify the declaration via DB updates only. The third component of the triplet defines where the value of the CA can be customized. For CAs with scope of Deploy, this can be done either for the whole scope of Deploy (must be done on the privileged Tenant) or per Tenant (can be done on either privileged or unprivileged Tenant). For CAs with scope of Tenant, it can only be done for the given Tenant. It does not make sense to create CA with immutable declarations on Tenant level, because we will always want to define Deploy-level defaults for them. CAs with DEPLOY__IMMUTABLE__IMMUTABLE are designed to replace Installation-level Properties. Contrary to DC, we don’t need validation for such CAs at runtime, as CAs with immutable declarations and values are always expected top be present in the DB (we should maintain a test to validate this). CAs with DEPLOY__IMMUTABLE__DEPLOY% are designed to replace Tenant-level Properties, which can be customized on Deploy level, in addition to Tenant level. Overall, CAs referred to in code (i.e., names of which are hardcoded somewhere) must be of types DEPLOY__IMMUTABLE%.

string
Enumeration:
DEPLOY__IMMUTABLE__IMMUTABLE
DEPLOY__IMMUTABLE__DEPLOY
DEPLOY__MUTABLE__DEPLOY
DEPLOY__IMMUTABLE__DEPLOY_TENANT
DEPLOY__MUTABLE__DEPLOY_TENANT
TENANT__MUTABLE__TENANT
Custom attributes entities types

Type of entity eligible for custom attributes.

string
Enumeration:
NONE

abstract properties

API_CLIENT

client initialization properties

MEDIUM

Attributes bound to media

USER

Attributes bound to users

CONTAINER

Attributes bound to containers

CustomAttributeValueLevel

Level where a value of a custom attribute was defined

string
Enumeration:
ENTITY

level of entity

TENANT

level of tenant

DEPLOY

level of deploy

DEFAULT

level of custom attribute