Skip to navigation

Create view

View as Markdown
Create a view with its first version

Request

This endpoint expects an object.
areaenumRequired

The content area the view is written for; fixed after creation

Allowed values:
namestringRequired0-150 characters
typeenumRequired
View type
Allowed values:
engine_versionintegerRequired>=1
HTML contract version the view was written against
inputsmap from strings to objectsRequired

Input name to data source, one or several; the view receives one data object with a key per input

htmlstringRequired0-1000000 characters

The view: HTML, CSS and script rendered in a sandboxed iframe

descriptionstringOptional0-1000 characters
summarystringOptional0-500 characters
What the first version shows, one line
authorenumOptional

Who produced the version: user (default), ollie or agent. Informational only

Allowed values:
librarieslist of stringsOptional

Libraries the host loads before the view runs; none when omitted

Response headers

Locationstring

Response

Created
idstringOptionalformat: "uuid"
areaenumOptional
Allowed values:
namestringOptional
descriptionstringOptional
current_versionintegerOptional
created_atdatetimeOptional
created_bystringOptional
last_updated_atdatetimeOptional
last_updated_bystringOptional
versionobjectOptional
An immutable version of a view

Errors

422
Unprocessable Entity Error