Back to top

Labfolder ELN API v2 Beta

Latest

Pre-Release Notice

This API is still under active development. This means endpoint semantics and formats might change as we finalize the implementation. There may still be some bugs as well, but we believe getting it into the hands of our users sooner will help the process move faster.

Optional fields might be added to requests and additional fields might be added to responses without notice. To ensure the smoothes possible transition please make sure your code does not rely on the exact object structure returned and ignores unknown properties.

“null” values

We’re aware of an issue with the library that we use to generate the API documentation in which nullable string properties are represented with the value "null" in the documentation. The API will never return “null” (as a string), only either a valid id (in string form “12345”) or null.

As an example, see the properties group_id and folder_id under the List Projects resource

Version

This is API v2 build #

cfb08c868c49aa13f3a6cb0c9b660c8387797ec7

Access

Location

The API can only be accessed via HTTPS.

You can reach the API for the cloud instance at

https://eln.labfolder.com/api/v2/

Local installations can access the API using the respective domain with the path /api/v2/ appended.

So if your server is reachable at https://labfolder.mycompany.lan the API endpoint is located at

# Note: `/api/v2/` is appended to the standalone server url

https://labfolder.mycompany.lan/api/v2/

Authentication

Requests to the API have to be authenticated using an API token which is received after successfully providing your application credentials to the API.

Once acquired the token can either be provided as the username field for HTTP-Basic authentication (useful for commandline access) or set in the Authorization header using other tools.

The following examples illustrate the two different ways to provide the token when using curl

# via HTTP-Basic
# Note the proceeding ':'

> curl -u "$LABFOLDER_API_TOKEN:" <API_RESOURCE_PATH_GOES_HERE>
# via Authorization header
# Note the format is "Authorization: Token xxxxxx"

> curl -H "Authorization: Token $LABFOLDER_API_TOKEN" <API_RESOURCE_PATH_GOES_HERE>

Endpoints

Signup - Create Account
POST/auth/signup

Create a new user account.

By registering an account via the labfolder API, you agree to our terms of use and privacy policy.

Example URI

POST /auth/signup
Request  Create Account
HideShow
Headers
Content-Type: application/json
Body
{
  "email": "darth.vader@starwars.com",
  "password": "password",
  "first_name": "Anakin",
  "last_name": "Skywalker",
  "role": "Fleet Commander",
  "organization": "Imperium",
  "language": "de"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "email": {
      "type": "string",
      "description": "email of the user"
    },
    "password": {
      "type": "string",
      "description": "password of the user"
    },
    "first_name": {
      "type": "string",
      "description": "first name of the user"
    },
    "last_name": {
      "type": "string",
      "description": "last name of the user"
    },
    "role": {
      "type": "string",
      "description": "role of the user in his organization"
    },
    "organization": {
      "type": "string",
      "description": "organization the user is member of"
    },
    "language": {
      "type": "string",
      "enum": [
        "de",
        "en",
        "fr"
      ],
      "description": "defines the user language. If not submitted, user language is English"
    }
  },
  "required": [
    "email",
    "password",
    "first_name",
    "last_name"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /auth/login
X-ELN-Access-Token: TFzQgEmfSnFYV5sQ0mI4 - Token to access the ELN pages via browser
Body
{
  "email": "darth.vader@starwars.com",
  "uuid": "123e4567-e89b-12d3-a456-426655440000"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "email": {
      "type": "string",
      "description": "email the new user has been created with"
    },
    "uuid": {
      "type": "string",
      "description": "a unique key to the user which is to be used across 3rd party applications"
    }
  }
}

Login - Generate Token
POST/auth/login

Generate a token which can be used to make API requests.

Example URI

POST /auth/login
Request  Generate Token
HideShow
Headers
Content-Type: application/json
Body
{
  "user": "darth.vader@starwars.com",
  "password": "password"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "user": {
      "type": "string",
      "description": "email of the user"
    },
    "password": {
      "type": "string",
      "description": "password of the user"
    }
  },
  "required": [
    "user",
    "password"
  ]
}
Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "token": "MTZmNTigNWMtNWJ34y00NDgwL12wM2ItZTM4NzFGYzU1NTJm",
  "expires": "2017-09-04T13:27:55.641+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "description": "generated token"
    },
    "expires": {
      "type": "string",
      "description": "expiration date of the token"
    }
  },
  "required": [
    "token",
    "expires"
  ]
}

Concepts

User Agent Required

All requests MUST include a User-Agent header. Please include the name of your application and your e-mail address so we can contact you if needed.

User-Agent: My Application; email@domain.tld

if you do not provide a User-Agent we will return a 400 Bad Request.

Parameters & Body Format

Some GET requests can take optional parameters which are included in the query string and must be UTF-8 encoded.

# Example query string usage

?offset=0&limit=20&sort=-title

The body format of POST, PATCH, PUT, and DELETE request is JSON and the corresponding Content-Type header must be set to application/json.

# Set Content-Type header and provide JSON body

> curl -u "${LABFOLDER_API_TOKEN}:" -H "Content-Type: application/json" -X POST -d {...JSON...} <API_RESOURCE_PATH_GOES_HERE>

Compression

All requests including Accept-Encoding: gzip header wil get compressed content as response.

Accept-Encoding: gzip

if you do not provide Accept-Encoding we will return uncompressed content.

Skipping Response Body

When creating or updating a resource the API can be configured to not return the resulting object in the message body. This can be accomplished by providing a custom header with the request:

`X-LF-SKIP-BODY: true`

No message body will be provided in the response and the HTTP response code will be 204. This may be useful in situations where minimizing bandwidth is a concern and when the resulting resource size is large (for example: table elements or text elements).

Note: if the header is not provided or when a value other than true is given it will be ignored and the API will default to returning the full message body.

Pagination

Some requests return paginated results of items (usually 20 at a time). Paginated items will be returned as a JSON array:

[
    {...some JSON...},
    {...some JSON...},
    {...some JSON...},
    {...some JSON...}
]

The total amount of found items will be available in a header X-Total-Count. This header will always be present for pageable requests.

You can control the offset and number of results returned by adjusting the offset and limit query parameters. All endpoints will limit the number of results returned by the limit parameter and fallback on the allowed maximum if you request too many items. The usual maximum for offset is 50 items but may differ by endpoint.

curl -H "Authorization: Token $LABFOLDER_API_TOKEN" <API_RESOURCE_PATH_GOES_HERE>?limit=1000

[
    {...some JSON...},
    {...some JSON...},
    {...some JSON...},
    {...some JSON...}
]

Client Errors

Client errors are denoted as a 4XX response code. All errors will return JSON with a message attribute explaining what went wrong.

{
    "status": 400,
    "message": "Unable to parse JSON"
}

There are several types of errors:

Authentication and authorization related errors

These will return either a 401 Unauthorized on missing authentication or a 403 Forbidden on missing authorization.

Invalid requests because of invalid HTTP verbs or media types

These will return a 405 Method Not Allowed or 415 Unsupported Media Type respectively.

Missing parameters or invalid body format

A 400 Bad Request is usually returned in case of missing parameters or an invalid body format. The latter could be because of invalid JSON or the wrong object shape (e.g. wrong nesting of objects).

Validation errors

A 422 Unprocessable Entity is returned if the body format is correct but the entity did not pass validation. This denotes a wrong user input and can potentially be signalled to the user.

Timezones & Date Format

Date Format

In general the API returns and expects dates & times in the ISO 8601 format including the timezone specification. For example: 2017-02-27T17:05:06+01:00 for a time or 2017-02-27 for a date.

Timezone

The default timezone returned will be the timezone specified in the user profile of the authenticated user.

Data Access

According to the provided authentication token the requesting user is identified.

Full List Requests

On full list requests, the returned entities always contain all user accessible data and not only the user self-created content, as far as not mentioned differently in the endpoint description.

Groups

Groups

Get Groups
GET/groups{?limit,offset}

Returns all the top level groups (subgroups are not returned) that user belongs to.

Example URI

GET /groups?limit=&offset=
URI Parameters
HideShow
limit
number (optional) Default: 20 

Maximum number of groups to return

offset
number (optional) Default: 0 

Offset into result-set (useful for pagination)

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
X-Total-Count: 1
X-Limit: 20
X-Offset: 0
Body
[
  {
    "title": "Luke's Private Group",
    "description": "This group is intended to be used for private projects",
    "id": "46123",
    "owner_id": "11038",
    "type": "BASIC",
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version_date": "2017-02-15T12:34:56.789+0200"
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "title": {
        "type": "string",
        "description": "the display title of the group"
      },
      "description": {
        "type": "string",
        "description": "details about the group usage, functionality, etc."
      },
      "id": {
        "type": "string",
        "description": "the unique id of the group"
      },
      "owner_id": {
        "type": "string",
        "description": "the id of the group owner"
      },
      "type": {
        "type": "string",
        "enum": [
          "BASIC",
          "ADVANCED"
        ],
        "description": "the type of the group"
      },
      "creation_date": {
        "type": "string",
        "description": "date when the group was created"
      },
      "version_date": {
        "type": "string",
        "description": "date when the group was last modified"
      }
    },
    "required": [
      "title",
      "id",
      "owner_id",
      "type",
      "creation_date",
      "version_date"
    ]
  }
}

Projects

Projects Resource

List Projects
GET/projects{?group_id,only_root_level,folder_id,limit,offset}

Returns a list of projects the user has access to.

Example URI

GET /projects?group_id=&only_root_level=&folder_id=&limit=&offset=
URI Parameters
HideShow
group_id
string (optional) 

Only return the projects that belong to the specified group

only_root_level
boolean (optional) Default: false 

Only return root (top) level projects - I.e. projects that do not reside within a folder

folder_id
string (optional) 

Only return projects that reside within the specified folder

limit
number (optional) Default: 20 

Maximum number of projects to return

offset
number (optional) Default: 0 

Offset into result-set (useful for pagination)

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
X-Total-Count: 1
X-Limit: 20
X-Offset: 0
Body
[
  {
    "title": "Luke's Private Project",
    "id": "46123",
    "owner_id": "11038",
    "group_id": "null",
    "folder_id": "null",
    "hidden": false,
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version_date": "2017-02-15T12:34:56.789+0200"
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "title": {
        "type": "string",
        "description": "the display name of the project"
      },
      "id": {
        "type": "string",
        "description": "the unique id of the project"
      },
      "owner_id": {
        "type": "string",
        "description": "the id of the project owner"
      },
      "group_id": {
        "type": [
          "string",
          "null"
        ],
        "description": "the id of the group to which the project is associated"
      },
      "folder_id": {
        "type": [
          "string",
          "null"
        ],
        "description": "the id of the folder in which the project is stored"
      },
      "hidden": {
        "type": "boolean",
        "description": "indicating if the project is hidden"
      },
      "creation_date": {
        "type": "string",
        "description": "date when the project was created"
      },
      "version_date": {
        "type": "string",
        "description": "date when the project was last modified"
      }
    },
    "required": [
      "title",
      "id",
      "owner_id",
      "group_id",
      "folder_id",
      "hidden",
      "creation_date",
      "version_date"
    ]
  }
}

Create Project
POST/projects

Create a project

Example URI

POST /projects
Request  Create Private Project
HideShow
Headers
Content-Type: application/json
Body
{
  "title": "Luke's Private Project"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the project"
    }
  },
  "required": [
    "title"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /projects/1234
Body
{
  "title": "Luke's Private Project",
  "id": "46123",
  "owner_id": "11038",
  "group_id": "null",
  "folder_id": "null",
  "hidden": false,
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the project"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the project"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the project owner"
    },
    "group_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "the id of the group to which the project is associated"
    },
    "folder_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "the id of the folder in which the project is stored"
    },
    "hidden": {
      "type": "boolean",
      "description": "indicating if the project is hidden"
    },
    "creation_date": {
      "type": "string",
      "description": "date when the project was created"
    },
    "version_date": {
      "type": "string",
      "description": "date when the project was last modified"
    }
  },
  "required": [
    "title",
    "id",
    "owner_id",
    "group_id",
    "folder_id",
    "hidden",
    "creation_date",
    "version_date"
  ]
}
Request  Create Private Project in a Folder
HideShow
Headers
Content-Type: application/json
Body
{
  "title": "Luke's Private Project",
  "folder_id": "36273"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the project"
    },
    "folder_id": {
      "type": "string",
      "description": "the id of the folder in which the project is stored"
    }
  },
  "required": [
    "title",
    "folder_id"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /projects/1234
Body
{
  "title": "Luke's Private Project",
  "id": "46123",
  "owner_id": "11038",
  "group_id": "null",
  "folder_id": "36273",
  "hidden": false,
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the project"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the project"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the project owner"
    },
    "group_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "the id of the group to which the project is associated"
    },
    "folder_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "the id of the folder in which the project is stored"
    },
    "hidden": {
      "type": "boolean",
      "description": "indicating if the project is hidden"
    },
    "creation_date": {
      "type": "string",
      "description": "date when the project was created"
    },
    "version_date": {
      "type": "string",
      "description": "date when the project was last modified"
    }
  },
  "required": [
    "title",
    "id",
    "owner_id",
    "group_id",
    "folder_id",
    "hidden",
    "creation_date",
    "version_date"
  ]
}
Request  Create Group Project
HideShow
Headers
Content-Type: application/json
Body
{
  "title": "Luke's Private Project",
  "group_id": "1200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the project"
    },
    "group_id": {
      "type": "string",
      "description": "the id of the group to which the project is associated"
    }
  },
  "required": [
    "title",
    "group_id"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /projects/1234
Body
{
  "title": "Luke's Private Project",
  "id": "46123",
  "owner_id": "11038",
  "group_id": "1200",
  "folder_id": "null",
  "hidden": false,
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the project"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the project"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the project owner"
    },
    "group_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "the id of the group to which the project is associated"
    },
    "folder_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "the id of the folder in which the project is stored"
    },
    "hidden": {
      "type": "boolean",
      "description": "indicating if the project is hidden"
    },
    "creation_date": {
      "type": "string",
      "description": "date when the project was created"
    },
    "version_date": {
      "type": "string",
      "description": "date when the project was last modified"
    }
  },
  "required": [
    "title",
    "id",
    "owner_id",
    "group_id",
    "folder_id",
    "hidden",
    "creation_date",
    "version_date"
  ]
}
Request  Create Group Project in a Folder
HideShow
Headers
Content-Type: application/json
Body
{
  "title": "Luke's Private Project",
  "folder_id": "36274",
  "group_id": "1200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the project"
    },
    "folder_id": {
      "type": "string",
      "description": "the id of the folder in which the project is stored"
    },
    "group_id": {
      "type": "string",
      "description": "the id of the group to which the project is associated"
    }
  },
  "required": [
    "title",
    "folder_id",
    "group_id"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /projects/1234
Body
{
  "title": "Luke's Private Project",
  "id": "46123",
  "owner_id": "11038",
  "group_id": "1200",
  "folder_id": "36273",
  "hidden": false,
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the project"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the project"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the project owner"
    },
    "group_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "the id of the group to which the project is associated"
    },
    "folder_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "the id of the folder in which the project is stored"
    },
    "hidden": {
      "type": "boolean",
      "description": "indicating if the project is hidden"
    },
    "creation_date": {
      "type": "string",
      "description": "date when the project was created"
    },
    "version_date": {
      "type": "string",
      "description": "date when the project was last modified"
    }
  },
  "required": [
    "title",
    "id",
    "owner_id",
    "group_id",
    "folder_id",
    "hidden",
    "creation_date",
    "version_date"
  ]
}

Folders

Folders Resource

List Folders
GET/folders{?group_id,only_root_level,folder_id,limit,offset}

Returns a list of folders the user has access to.

Example URI

GET /folders?group_id=&only_root_level=&folder_id=&limit=&offset=
URI Parameters
HideShow
group_id
string (optional) 

Only return the folders that belong to the specified group

only_root_level
boolean (optional) Default: false 

Only return root (top) level folders - I.e. folders that do not reside within another folder

folder_id
string (optional) 

Only return folders that reside within the specified folder

limit
number (optional) Default: 20 

Maximum number of folders to return

offset
number (optional) Default: 0 

Offset into result-set (useful for pagination)

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
X-Total-Count: 1
X-Limit: 20
X-Offset: 0
Body
[
  {
    "id": "46123",
    "title": "Luke's Folder",
    "owner_id": "11038",
    "group_id": "206",
    "folder_id": "null",
    "hidden": false,
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version_date": "2017-02-15T12:34:56.789+0200"
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "the unique id of the folder"
      },
      "title": {
        "type": "string",
        "description": "the display name of the folder"
      },
      "owner_id": {
        "type": "string",
        "description": "the id of the folder owner"
      },
      "group_id": {
        "type": [
          "string",
          "null"
        ],
        "description": "the id of the group to which the folder is associated"
      },
      "folder_id": {
        "type": [
          "string",
          "null"
        ],
        "description": "the id of the folder in which the folder is stored"
      },
      "hidden": {
        "type": "boolean",
        "description": "indicating if the folder is hidden"
      },
      "creation_date": {
        "type": "string",
        "description": "date when the folder was created"
      },
      "version_date": {
        "type": "string",
        "description": "date when the folder was last modified"
      }
    },
    "required": [
      "id",
      "title",
      "owner_id",
      "group_id",
      "folder_id",
      "hidden",
      "creation_date",
      "version_date"
    ]
  }
}

Notebook

Entries

List Entries
GET/entries{?sort,omit_empty_title,title,expand,limit,offset}

Returns the list of entries

Example URI

GET /entries?sort=&omit_empty_title=&title=&expand=&limit=&offset=
URI Parameters
HideShow
sort
string (optional) 

Field to sort the results by. When omitted results are sorted by user application settings

Choices: title -title

omit_empty_title
boolean (optional) Default: false 

omit entries without a title in the result set

title
string (optional) 

partial string to match the entry title

limit
number (optional) Default: 20 

Maximum number of projects to return. The maximum for limit is 50 items.

offset
number (optional) Default: 0 

Offset into result-set (useful for pagination)

expand
string (optional) 

A comma separated list of related domain objects that should be expanded for all items returned.

Choices: author project

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
X-Total-Count: 1
X-Limit: 20
X-Offset: 0
Body
[
  {
    "title": "Luke's Private Entry",
    "project_id": "36272",
    "id": "2309878",
    "version_id": "5309878",
    "author_id": "11038",
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version_date": "2017-02-15T12:34:56.789+0200",
    "hidden": false,
    "element_layout": {
      "rows": [
        {
          "cells": [
            {
              "element_id": "2309983",
              "width": 66
            }
          ]
        }
      ]
    },
    "elements": [
      {
        "id": "2309983",
        "version_id": "0",
        "type": "TEXT"
      }
    ],
    "tags": [
      "luke",
      "star wars"
    ],
    "custom_dates": [
      {
        "name": "validation date",
        "value": "2017-12-25"
      }
    ]
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "title": {
        "type": "string",
        "description": "the display name of the entry"
      },
      "project_id": {
        "type": "string",
        "description": "project location of the entry"
      },
      "id": {
        "type": "string",
        "description": "the stable pointer to the most current version `blockId`"
      },
      "version_id": {
        "type": "string",
        "description": "the unique id of the entry"
      },
      "author_id": {
        "type": "string",
        "description": "the unique id of the user created the entry"
      },
      "creation_date": {
        "type": "string",
        "description": "date when the entry was created"
      },
      "version_date": {
        "type": "string",
        "description": "date when this entry was last modified"
      },
      "hidden": {
        "type": "boolean",
        "description": "indicates if the entry is hidden or visible"
      },
      "element_layout": {
        "type": "object",
        "properties": {
          "rows": {
            "type": [
              "array",
              "null"
            ],
            "description": "the notebook row/column layout of elements in the entry"
          }
        },
        "required": [
          "rows"
        ],
        "description": "The layout of the elements in this entry"
      },
      "elements": {
        "type": "array",
        "description": "The elements in this entry"
      },
      "tags": {
        "type": "array",
        "description": "The tags for this entry. Tags are case insensitive."
      },
      "custom_dates": {
        "type": "array",
        "description": "Custom dates for this entry"
      }
    },
    "required": [
      "title",
      "project_id",
      "id",
      "version_id",
      "author_id",
      "creation_date",
      "version_date",
      "hidden",
      "element_layout",
      "elements",
      "tags",
      "custom_dates"
    ]
  }
}

Create Notebook Entry
POST/entries

Create a notebook entry

Example URI

POST /entries
Request  Create Entry with Title
HideShow
Headers
Content-Type: application/json
Body
{
  "title": "Luke's Private Entry",
  "project_id": "36272"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the entry"
    },
    "project_id": {
      "type": "string",
      "description": "project location of the entry"
    }
  },
  "required": [
    "title",
    "project_id"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /entries/10945
Body
{
  "title": "Luke's Private Entry",
  "project_id": "36272",
  "id": "2309878",
  "version_id": "5309878",
  "author_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "hidden": false,
  "element_layout": {
    "rows": []
  },
  "elements": [],
  "tags": [],
  "custom_dates": []
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the entry"
    },
    "project_id": {
      "type": "string",
      "description": "project location of the entry"
    },
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version `blockId`"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the entry"
    },
    "author_id": {
      "type": "string",
      "description": "the unique id of the user created the entry"
    },
    "creation_date": {
      "type": "string",
      "description": "date when the entry was created"
    },
    "version_date": {
      "type": "string",
      "description": "date when this entry was last modified"
    },
    "hidden": {
      "type": "boolean",
      "description": "indicates if the entry is hidden or visible"
    },
    "element_layout": {
      "type": "object",
      "properties": {
        "rows": {
          "type": "array",
          "description": "the notebook row/column layout of elements in the entry"
        }
      },
      "description": "The layout of the elements in this entry"
    },
    "elements": {
      "type": "array",
      "description": "The elements in this entry"
    },
    "tags": {
      "type": "array",
      "description": "The tags for this entry. Tags are case insensitive."
    },
    "custom_dates": {
      "type": "array",
      "description": "Custom dates for this entry"
    }
  },
  "required": [
    "title",
    "project_id",
    "id",
    "version_id",
    "author_id",
    "creation_date",
    "version_date",
    "hidden",
    "element_layout",
    "elements",
    "tags",
    "custom_dates"
  ]
}
Request  Create Entry with Tags
HideShow
Headers
Content-Type: application/json
Body
{
  "title": "Luke's Private Entry",
  "project_id": "36272",
  "tags": [
    "luke",
    "star wars"
  ]
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the entry"
    },
    "project_id": {
      "type": "string",
      "description": "project location of the entry"
    },
    "tags": {
      "type": "array",
      "description": "array of strings representing tags"
    }
  },
  "required": [
    "title",
    "project_id",
    "tags"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /entries/10945
Body
{
  "title": "Luke's Private Entry",
  "project_id": "36272",
  "id": "2309878",
  "version_id": "5309878",
  "author_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "hidden": false,
  "element_layout": {
    "rows": []
  },
  "elements": [],
  "tags": [
    "luke",
    "star wars"
  ],
  "custom_dates": []
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the entry"
    },
    "project_id": {
      "type": "string",
      "description": "project location of the entry"
    },
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version `blockId`"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the entry"
    },
    "author_id": {
      "type": "string",
      "description": "the unique id of the user created the entry"
    },
    "creation_date": {
      "type": "string",
      "description": "date when the entry was created"
    },
    "version_date": {
      "type": "string",
      "description": "date when this entry was last modified"
    },
    "hidden": {
      "type": "boolean",
      "description": "indicates if the entry is hidden or visible"
    },
    "element_layout": {
      "type": "object",
      "properties": {
        "rows": {
          "type": "array",
          "description": "the notebook row/column layout of elements in the entry"
        }
      },
      "description": "The layout of the elements in this entry"
    },
    "elements": {
      "type": "array",
      "description": "The elements in this entry"
    },
    "tags": {
      "type": "array",
      "description": "The tags for this entry. Tags are case insensitive."
    },
    "custom_dates": {
      "type": "array",
      "description": "Custom dates for this entry"
    }
  },
  "required": [
    "title",
    "project_id",
    "id",
    "version_id",
    "author_id",
    "creation_date",
    "version_date",
    "hidden",
    "element_layout",
    "elements",
    "tags",
    "custom_dates"
  ]
}
Request  Create Entry with Custom Dates
HideShow
Headers
Content-Type: application/json
Body
{
  "title": "Luke's Private Entry",
  "project_id": "36272",
  "custom_dates": [
    {
      "name": "validation date",
      "value": "2017-12-25"
    }
  ]
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the entry"
    },
    "project_id": {
      "type": "string",
      "description": "project location of the entry"
    },
    "custom_dates": {
      "type": "array",
      "description": "array of custom dates"
    }
  },
  "required": [
    "title",
    "project_id",
    "custom_dates"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /entries/10945
Body
{
  "title": "Luke's Private Entry",
  "project_id": "36272",
  "id": "2309878",
  "version_id": "5309878",
  "author_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "hidden": false,
  "element_layout": {
    "rows": []
  },
  "elements": [],
  "tags": [],
  "custom_dates": [
    {
      "name": "validation date",
      "value": "2017-12-25"
    }
  ]
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the entry"
    },
    "project_id": {
      "type": "string",
      "description": "project location of the entry"
    },
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version `blockId`"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the entry"
    },
    "author_id": {
      "type": "string",
      "description": "the unique id of the user created the entry"
    },
    "creation_date": {
      "type": "string",
      "description": "date when the entry was created"
    },
    "version_date": {
      "type": "string",
      "description": "date when this entry was last modified"
    },
    "hidden": {
      "type": "boolean",
      "description": "indicates if the entry is hidden or visible"
    },
    "element_layout": {
      "type": "object",
      "properties": {
        "rows": {
          "type": "array",
          "description": "the notebook row/column layout of elements in the entry"
        }
      },
      "description": "The layout of the elements in this entry"
    },
    "elements": {
      "type": "array",
      "description": "The elements in this entry"
    },
    "tags": {
      "type": "array",
      "description": "The tags for this entry. Tags are case insensitive."
    },
    "custom_dates": {
      "type": "array",
      "description": "Custom dates for this entry"
    }
  },
  "required": [
    "title",
    "project_id",
    "id",
    "version_id",
    "author_id",
    "creation_date",
    "version_date",
    "hidden",
    "element_layout",
    "elements",
    "tags",
    "custom_dates"
  ]
}

Material Database

Material Databases

List Material Databases
GET/mdb/databases

Returns the list of all material databases

Example URI

GET /mdb/databases
Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
[
  {
    "title": "Luke's Private MDB",
    "id": "c8ea2e7e-3755-497f-bd03-6b568dda025b",
    "owner_id": "11038",
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version_date": "2017-02-15T12:34:56.789+0200"
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "title": {
        "type": "string",
        "description": "the display name of the mdb"
      },
      "id": {
        "type": "string",
        "description": "the unique id of the mdb"
      },
      "owner_id": {
        "type": "string",
        "description": "the id of the original author of this mdb"
      },
      "creation_date": {
        "type": "string",
        "description": "the creation date of the mdb"
      },
      "version_date": {
        "type": "string",
        "description": "the last modification date of the mdb"
      }
    },
    "required": [
      "title",
      "id",
      "owner_id",
      "creation_date",
      "version_date"
    ]
  }
}

Get Material Database
GET/mdb/databases/{id}

Returns the material database

Example URI

GET /mdb/databases/1935c7cf-d340-4dc2-a0ed-f3ac85bc2874
URI Parameters
HideShow
id
string (required) Example: 1935c7cf-d340-4dc2-a0ed-f3ac85bc2874

id of the mdb

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "title": "Luke's Private MDB",
  "id": "c8ea2e7e-3755-497f-bd03-6b568dda025b",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the mdb"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the mdb"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author of this mdb"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the mdb"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the mdb"
    }
  },
  "required": [
    "title",
    "id",
    "owner_id",
    "creation_date",
    "version_date"
  ]
}

Create Material Database
POST/mdb/databases

Create a material database

Example URI

POST /mdb/databases
Request  Create Material Database
HideShow
Headers
Content-Type: application/json
Body
{
  "title": "Luke's Private MDB"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the mdb"
    }
  },
  "required": [
    "title"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /mdb/databases/1234
Body
{
  "title": "Luke's Private MDB",
  "id": "c8ea2e7e-3755-497f-bd03-6b568dda025b",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the mdb"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the mdb"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author of this mdb"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the mdb"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the mdb"
    }
  },
  "required": [
    "title",
    "id",
    "owner_id",
    "creation_date",
    "version_date"
  ]
}

Update Material Database
PUT/mdb/databases/{id}

Update a material database

Example URI

PUT /mdb/databases/c8ea2e7e-3755-497f-bd03-6b568dda025b
URI Parameters
HideShow
id
string (required) Example: c8ea2e7e-3755-497f-bd03-6b568dda025b

id of the mdb

Request  Update Material Database
HideShow
Headers
Content-Type: application/json
Body
{
  "title": "Luke's Private MDB",
  "id": "c8ea2e7e-3755-497f-bd03-6b568dda025b"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the mdb"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the mdb"
    }
  },
  "required": [
    "title",
    "id"
  ]
}
Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "title": "Luke's Private MDB",
  "id": "c8ea2e7e-3755-497f-bd03-6b568dda025b",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the mdb"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the mdb"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author of this mdb"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the mdb"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the mdb"
    }
  },
  "required": [
    "title",
    "id",
    "owner_id",
    "creation_date",
    "version_date"
  ]
}

Delete Material Database
DELETE/mdb/databases/{id}

Deletes the Material Database. Note: the entity is not deleted, but is flagged as ‘hidden’.

Example URI

DELETE /mdb/databases/c8ea2e7e-3755-497f-bd03-6b568dda025b
URI Parameters
HideShow
id
string (required) Example: c8ea2e7e-3755-497f-bd03-6b568dda025b

id of the mdb

Response  204

MDB Categories

List Categories
GET/mdb/categories{?mdb_id}

Returns the list of all mdb categories for the given material database

Example URI

GET /mdb/categories?mdb_id=1935c7cf-d340-4dc2-a0ed-f3ac85bc2874
URI Parameters
HideShow
mdb_id
string (required) Example: 1935c7cf-d340-4dc2-a0ed-f3ac85bc2874

id of the material database

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
[
  {
    "title": "Luke's Private Vehicles",
    "attributes": [
      {
        "type": "Text",
        "title": "Model",
        "mandatory": false
      }
    ],
    "mdb_id": "8f20ed8d-2e28-41c7-8233-d47874167a70",
    "id": "76625e69-52eb-40b5-a610-99ab8b801cf9",
    "creator_id": "11038",
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version_date": "2017-02-15T12:34:56.789+0200"
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "title": {
        "type": "string",
        "description": "the display name of the mdb"
      },
      "attributes": {
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "Text",
                "Date",
                "Number"
              ]
            },
            "title": {
              "type": "string",
              "description": "the display title of the attribute"
            },
            "mandatory": {
              "type": "boolean",
              "description": "is a value mandatory for this attribute"
            }
          },
          "required": [
            "type",
            "title",
            "mandatory"
          ]
        },
        "description": "The attributes for this item category"
      },
      "mdb_id": {
        "type": "string",
        "description": "the id of the material database this category is associated with"
      },
      "id": {
        "type": "string",
        "description": "the id of the category"
      },
      "creator_id": {
        "type": "string",
        "description": "the id of the original author"
      },
      "creation_date": {
        "type": "string",
        "description": "the creation date of the item category"
      },
      "version_date": {
        "type": "string",
        "description": "the last modification date of the item category"
      }
    },
    "required": [
      "title",
      "mdb_id",
      "id",
      "creator_id",
      "creation_date",
      "version_date"
    ]
  }
}

Get Category
GET/mdb/categories/{id}

Returns the category

Example URI

GET /mdb/categories/e87e6534-2ae0-4139-bc48-cc668f330069
URI Parameters
HideShow
id
string (required) Example: e87e6534-2ae0-4139-bc48-cc668f330069

id of the category

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "title": "Luke's Private Vehicles",
  "attributes": [
    {
      "type": "Text",
      "title": "Model",
      "mandatory": false
    }
  ],
  "mdb_id": "8f20ed8d-2e28-41c7-8233-d47874167a70",
  "id": "76625e69-52eb-40b5-a610-99ab8b801cf9",
  "creator_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the mdb"
    },
    "attributes": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "Text",
              "Date",
              "Number"
            ]
          },
          "title": {
            "type": "string",
            "description": "the display title of the attribute"
          },
          "mandatory": {
            "type": "boolean",
            "description": "is a value mandatory for this attribute"
          }
        },
        "required": [
          "type",
          "title",
          "mandatory"
        ]
      },
      "description": "The attributes for this item category"
    },
    "mdb_id": {
      "type": "string",
      "description": "the id of the material database this category is associated with"
    },
    "id": {
      "type": "string",
      "description": "the id of the category"
    },
    "creator_id": {
      "type": "string",
      "description": "the id of the original author"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the item category"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the item category"
    }
  },
  "required": [
    "title",
    "mdb_id",
    "id",
    "creator_id",
    "creation_date",
    "version_date"
  ]
}

Delete Category
DELETE/mdb/categories/{id}

Deletes the Category. Note: the entity is not deleted, but is flagged as ‘hidden’.

Example URI

DELETE /mdb/categories/b10b785d-d87d-48cf-9c0b-d7be08f377b2
URI Parameters
HideShow
id
string (required) Example: b10b785d-d87d-48cf-9c0b-d7be08f377b2

id of the category to delete

Response  204

MDB Category Attributes

List Default Category Attributes
GET/mdb/categories/attributes/default

Returns the default list of category attributes

Example URI

GET /mdb/categories/attributes/default
Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
[
  {
    "title": "General",
    "attributes": [
      {
        "type": "Text",
        "title": "Model",
        "mandatory": false
      }
    ]
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "title": {
        "type": "string",
        "description": "the display title"
      },
      "attributes": {
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "Text",
                "Date",
                "Number"
              ]
            },
            "title": {
              "type": "string",
              "description": "the display title of the attribute"
            },
            "mandatory": {
              "type": "boolean",
              "description": "is a value mandatory for this attribute"
            }
          },
          "required": [
            "type",
            "title",
            "mandatory"
          ]
        },
        "description": "the fields of the group"
      }
    },
    "required": [
      "title"
    ]
  }
}

MDB Items

List Items
GET/mdb/items{?category_id,keyword,expand}

Returns the list of all items sorted by display title

Example URI

GET /mdb/items?category_id=&keyword=&expand=
URI Parameters
HideShow
category_id
string (optional) 

The category id to show items for. If none provided will show all items.

keyword
string (optional) 

The search term to filter items by title. If not provided it will not filter.

expand
string (optional) 

A command separated list of related domain objects that should be expanded for all items returned.

Choices: category

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
[
  {
    "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
    "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
    "title": "X-Wing Fighter",
    "id": "1d573349-347b-4e46-a956-863d4e2db356",
    "version_id": "620c535d-45bd-497a-ad92-d0222f959d6b",
    "creator_id": "11038",
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version": 8,
    "version_count": 10,
    "version_date": "2017-02-15T12:34:56.789+0200",
    "version_author_id": "11040",
    "custom_attributes": {
      "0553c003-9014-47ef-9522-115ad7d4b3a1": "1001"
    },
    "status": "IN_STOCK"
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "mdb_id": {
        "type": "string",
        "description": "the id of the material database this item belongs to"
      },
      "category_id": {
        "type": "string",
        "description": "the id of the category used for creating this item `templateId`"
      },
      "title": {
        "type": "string",
        "description": "the display name of the item"
      },
      "id": {
        "type": "string",
        "description": "the stable pointer to the most current version `itemId`"
      },
      "version_id": {
        "type": "string",
        "description": "the unique id of the mdb item"
      },
      "creator_id": {
        "type": "string",
        "description": "the id of the original author of this item"
      },
      "creation_date": {
        "type": "string",
        "description": "the creation date of the mdb item"
      },
      "version": {
        "type": "number",
        "description": "the version number (it is automatically incremented for each modification on the item) `itemVersion`"
      },
      "version_count": {
        "type": "number",
        "description": "the total number of versions available"
      },
      "version_date": {
        "type": "string",
        "description": "the last modification date of the mdb item"
      },
      "version_author_id": {
        "type": "string",
        "description": "the id of the person that edited this version of the item"
      },
      "custom_attributes": {
        "type": "object",
        "properties": {
          "0553c003-9014-47ef-9522-115ad7d4b3a1": {
            "type": [
              "string",
              "null"
            ],
            "description": "The attribute id plus it's associated value"
          }
        },
        "description": "The attribute values of this mdb item according to the category field"
      },
      "status": {
        "type": "string",
        "enum": [
          "IN_STOCK",
          "OUT_STOCK",
          "DELETED",
          "ORDERED"
        ],
        "description": "the stock status of the item"
      }
    },
    "required": [
      "mdb_id",
      "category_id",
      "title",
      "id",
      "version_id",
      "creator_id",
      "creation_date",
      "version",
      "version_count",
      "version_date",
      "version_author_id",
      "custom_attributes",
      "status"
    ]
  }
}
Request  ?expand=category
Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
[
  {
    "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
    "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
    "title": "X-Wing Fighter",
    "id": "1d573349-347b-4e46-a956-863d4e2db356",
    "version_id": "620c535d-45bd-497a-ad92-d0222f959d6b",
    "creator_id": "11038",
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version": 8,
    "version_count": 10,
    "version_date": "2017-02-15T12:34:56.789+0200",
    "version_author_id": "11040",
    "custom_attributes": {
      "0553c003-9014-47ef-9522-115ad7d4b3a1": "1001"
    },
    "status": "IN_STOCK",
    "category": {
      "title": "Luke's Private Vehicles",
      "attributes": [
        {
          "type": "Text",
          "title": "Model",
          "mandatory": false
        }
      ],
      "mdb_id": "8f20ed8d-2e28-41c7-8233-d47874167a70",
      "id": "76625e69-52eb-40b5-a610-99ab8b801cf9",
      "creator_id": "11038",
      "creation_date": "2017-02-10T12:34:56.789+0200",
      "version_date": "2017-02-15T12:34:56.789+0200"
    }
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "mdb_id": {
        "type": "string",
        "description": "the id of the material database this item belongs to"
      },
      "category_id": {
        "type": "string",
        "description": "the id of the category used for creating this item `templateId`"
      },
      "title": {
        "type": "string",
        "description": "the display name of the item"
      },
      "id": {
        "type": "string",
        "description": "the stable pointer to the most current version `itemId`"
      },
      "version_id": {
        "type": "string",
        "description": "the unique id of the mdb item"
      },
      "creator_id": {
        "type": "string",
        "description": "the id of the original author of this item"
      },
      "creation_date": {
        "type": "string",
        "description": "the creation date of the mdb item"
      },
      "version": {
        "type": "number",
        "description": "the version number (it is automatically incremented for each modification on the item) `itemVersion`"
      },
      "version_count": {
        "type": "number",
        "description": "the total number of versions available"
      },
      "version_date": {
        "type": "string",
        "description": "the last modification date of the mdb item"
      },
      "version_author_id": {
        "type": "string",
        "description": "the id of the person that edited this version of the item"
      },
      "custom_attributes": {
        "type": "object",
        "properties": {
          "0553c003-9014-47ef-9522-115ad7d4b3a1": {
            "type": [
              "string",
              "null"
            ],
            "description": "The attribute id plus it's associated value"
          }
        },
        "description": "The attribute values of this mdb item according to the category field"
      },
      "status": {
        "type": "string",
        "enum": [
          "IN_STOCK",
          "OUT_STOCK",
          "DELETED",
          "ORDERED"
        ],
        "description": "the stock status of the item"
      },
      "category": {
        "type": "object",
        "properties": {
          "title": {
            "type": "string",
            "description": "the display name of the mdb"
          },
          "attributes": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "type": {
                  "type": "string",
                  "enum": [
                    "Text",
                    "Date",
                    "Number"
                  ]
                },
                "title": {
                  "type": "string",
                  "description": "the display title of the attribute"
                },
                "mandatory": {
                  "type": "boolean",
                  "description": "is a value mandatory for this attribute"
                }
              },
              "required": [
                "type",
                "title",
                "mandatory"
              ]
            },
            "description": "The attributes for this item category"
          },
          "mdb_id": {
            "type": "string",
            "description": "the id of the material database this category is associated with"
          },
          "id": {
            "type": "string",
            "description": "the id of the category"
          },
          "creator_id": {
            "type": "string",
            "description": "the id of the original author"
          },
          "creation_date": {
            "type": "string",
            "description": "the creation date of the item category"
          },
          "version_date": {
            "type": "string",
            "description": "the last modification date of the item category"
          }
        },
        "required": [
          "title",
          "mdb_id",
          "id",
          "creator_id",
          "creation_date",
          "version_date"
        ],
        "description": "the category referenced by the `category_id` property"
      }
    },
    "required": [
      "mdb_id",
      "category_id",
      "title",
      "id",
      "version_id",
      "creator_id",
      "creation_date",
      "version",
      "version_count",
      "version_date",
      "version_author_id",
      "custom_attributes",
      "status",
      "category"
    ]
  }
}

Get Item
GET/mdb/items/{id}/{?expand}

Returns the current version of a material database item

TODO: should we mention 404 response for deleted items here?

Example URI

GET /mdb/items/d395ff8e-3430-4cb5-8d34-b0a3399bf6b3/?expand=
URI Parameters
HideShow
id
string (required) Example: d395ff8e-3430-4cb5-8d34-b0a3399bf6b3

stable id of item

expand
string (optional) 

A command separated list of related domain objects that should be expanded for all items returned.

Choices: category

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
  "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
  "title": "X-Wing Fighter",
  "id": "1d573349-347b-4e46-a956-863d4e2db356",
  "version_id": "620c535d-45bd-497a-ad92-d0222f959d6b",
  "creator_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version": 8,
  "version_count": 10,
  "version_date": "2017-02-15T12:34:56.789+0200",
  "version_author_id": "11040",
  "custom_attributes": {
    "0553c003-9014-47ef-9522-115ad7d4b3a1": "1001"
  },
  "status": "IN_STOCK"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "mdb_id": {
      "type": "string",
      "description": "the id of the material database this item belongs to"
    },
    "category_id": {
      "type": "string",
      "description": "the id of the category used for creating this item `templateId`"
    },
    "title": {
      "type": "string",
      "description": "the display name of the item"
    },
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version `itemId`"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the mdb item"
    },
    "creator_id": {
      "type": "string",
      "description": "the id of the original author of this item"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the mdb item"
    },
    "version": {
      "type": "number",
      "description": "the version number (it is automatically incremented for each modification on the item) `itemVersion`"
    },
    "version_count": {
      "type": "number",
      "description": "the total number of versions available"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the mdb item"
    },
    "version_author_id": {
      "type": "string",
      "description": "the id of the person that edited this version of the item"
    },
    "custom_attributes": {
      "type": "object",
      "properties": {
        "0553c003-9014-47ef-9522-115ad7d4b3a1": {
          "type": [
            "string",
            "null"
          ],
          "description": "The attribute id plus it's associated value"
        }
      },
      "description": "The attribute values of this mdb item according to the category field"
    },
    "status": {
      "type": "string",
      "enum": [
        "IN_STOCK",
        "OUT_STOCK",
        "DELETED",
        "ORDERED"
      ],
      "description": "the stock status of the item"
    }
  },
  "required": [
    "mdb_id",
    "category_id",
    "title",
    "id",
    "version_id",
    "creator_id",
    "creation_date",
    "version",
    "version_count",
    "version_date",
    "version_author_id",
    "custom_attributes",
    "status"
  ]
}
Request  ?expand=category
Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
  "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
  "title": "X-Wing Fighter",
  "id": "1d573349-347b-4e46-a956-863d4e2db356",
  "version_id": "620c535d-45bd-497a-ad92-d0222f959d6b",
  "creator_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version": 8,
  "version_count": 10,
  "version_date": "2017-02-15T12:34:56.789+0200",
  "version_author_id": "11040",
  "custom_attributes": {
    "0553c003-9014-47ef-9522-115ad7d4b3a1": "1001"
  },
  "status": "IN_STOCK",
  "category": {
    "title": "Luke's Private Vehicles",
    "attributes": [
      {
        "type": "Text",
        "title": "Model",
        "mandatory": false
      }
    ],
    "mdb_id": "8f20ed8d-2e28-41c7-8233-d47874167a70",
    "id": "76625e69-52eb-40b5-a610-99ab8b801cf9",
    "creator_id": "11038",
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version_date": "2017-02-15T12:34:56.789+0200"
  }
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "mdb_id": {
      "type": "string",
      "description": "the id of the material database this item belongs to"
    },
    "category_id": {
      "type": "string",
      "description": "the id of the category used for creating this item `templateId`"
    },
    "title": {
      "type": "string",
      "description": "the display name of the item"
    },
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version `itemId`"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the mdb item"
    },
    "creator_id": {
      "type": "string",
      "description": "the id of the original author of this item"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the mdb item"
    },
    "version": {
      "type": "number",
      "description": "the version number (it is automatically incremented for each modification on the item) `itemVersion`"
    },
    "version_count": {
      "type": "number",
      "description": "the total number of versions available"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the mdb item"
    },
    "version_author_id": {
      "type": "string",
      "description": "the id of the person that edited this version of the item"
    },
    "custom_attributes": {
      "type": "object",
      "properties": {
        "0553c003-9014-47ef-9522-115ad7d4b3a1": {
          "type": [
            "string",
            "null"
          ],
          "description": "The attribute id plus it's associated value"
        }
      },
      "description": "The attribute values of this mdb item according to the category field"
    },
    "status": {
      "type": "string",
      "enum": [
        "IN_STOCK",
        "OUT_STOCK",
        "DELETED",
        "ORDERED"
      ],
      "description": "the stock status of the item"
    },
    "category": {
      "type": "object",
      "properties": {
        "title": {
          "type": "string",
          "description": "the display name of the mdb"
        },
        "attributes": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "Text",
                  "Date",
                  "Number"
                ]
              },
              "title": {
                "type": "string",
                "description": "the display title of the attribute"
              },
              "mandatory": {
                "type": "boolean",
                "description": "is a value mandatory for this attribute"
              }
            },
            "required": [
              "type",
              "title",
              "mandatory"
            ]
          },
          "description": "The attributes for this item category"
        },
        "mdb_id": {
          "type": "string",
          "description": "the id of the material database this category is associated with"
        },
        "id": {
          "type": "string",
          "description": "the id of the category"
        },
        "creator_id": {
          "type": "string",
          "description": "the id of the original author"
        },
        "creation_date": {
          "type": "string",
          "description": "the creation date of the item category"
        },
        "version_date": {
          "type": "string",
          "description": "the last modification date of the item category"
        }
      },
      "required": [
        "title",
        "mdb_id",
        "id",
        "creator_id",
        "creation_date",
        "version_date"
      ],
      "description": "the category referenced by the `category_id` property"
    }
  },
  "required": [
    "mdb_id",
    "category_id",
    "title",
    "id",
    "version_id",
    "creator_id",
    "creation_date",
    "version",
    "version_count",
    "version_date",
    "version_author_id",
    "custom_attributes",
    "status",
    "category"
  ]
}

Get Item Version
GET/mdb/items/{id}/versions/{version_id}/{?expand}

Returns the specified version of a material database item

Example URI

GET /mdb/items/d395ff8e-3430-4cb5-8d34-b0a3399bf6b3/versions/2493713e-9316-47b5-b9c8-c83332bdee30/?expand=
URI Parameters
HideShow
id
string (required) Example: d395ff8e-3430-4cb5-8d34-b0a3399bf6b3

stable id of item

version_id
string (required) Example: 2493713e-9316-47b5-b9c8-c83332bdee30

version of the item

expand
string (optional) 

A command separated list of related domain objects that should be expanded for all items returned.

Choices: category

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
  "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
  "title": "X-Wing Fighter",
  "id": "1d573349-347b-4e46-a956-863d4e2db356",
  "version_id": "620c535d-45bd-497a-ad92-d0222f959d6b",
  "creator_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version": 8,
  "version_count": 10,
  "version_date": "2017-02-15T12:34:56.789+0200",
  "version_author_id": "11040",
  "custom_attributes": {
    "0553c003-9014-47ef-9522-115ad7d4b3a1": "1001"
  },
  "status": "IN_STOCK"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "mdb_id": {
      "type": "string",
      "description": "the id of the material database this item belongs to"
    },
    "category_id": {
      "type": "string",
      "description": "the id of the category used for creating this item `templateId`"
    },
    "title": {
      "type": "string",
      "description": "the display name of the item"
    },
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version `itemId`"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the mdb item"
    },
    "creator_id": {
      "type": "string",
      "description": "the id of the original author of this item"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the mdb item"
    },
    "version": {
      "type": "number",
      "description": "the version number (it is automatically incremented for each modification on the item) `itemVersion`"
    },
    "version_count": {
      "type": "number",
      "description": "the total number of versions available"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the mdb item"
    },
    "version_author_id": {
      "type": "string",
      "description": "the id of the person that edited this version of the item"
    },
    "custom_attributes": {
      "type": "object",
      "properties": {
        "0553c003-9014-47ef-9522-115ad7d4b3a1": {
          "type": [
            "string",
            "null"
          ],
          "description": "The attribute id plus it's associated value"
        }
      },
      "description": "The attribute values of this mdb item according to the category field"
    },
    "status": {
      "type": "string",
      "enum": [
        "IN_STOCK",
        "OUT_STOCK",
        "DELETED",
        "ORDERED"
      ],
      "description": "the stock status of the item"
    }
  },
  "required": [
    "mdb_id",
    "category_id",
    "title",
    "id",
    "version_id",
    "creator_id",
    "creation_date",
    "version",
    "version_count",
    "version_date",
    "version_author_id",
    "custom_attributes",
    "status"
  ]
}
Request  ?expand=category
Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
  "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
  "title": "X-Wing Fighter",
  "id": "1d573349-347b-4e46-a956-863d4e2db356",
  "version_id": "620c535d-45bd-497a-ad92-d0222f959d6b",
  "creator_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version": 8,
  "version_count": 10,
  "version_date": "2017-02-15T12:34:56.789+0200",
  "version_author_id": "11040",
  "custom_attributes": {
    "0553c003-9014-47ef-9522-115ad7d4b3a1": "1001"
  },
  "status": "IN_STOCK",
  "category": {
    "title": "Luke's Private Vehicles",
    "attributes": [
      {
        "type": "Text",
        "title": "Model",
        "mandatory": false
      }
    ],
    "mdb_id": "8f20ed8d-2e28-41c7-8233-d47874167a70",
    "id": "76625e69-52eb-40b5-a610-99ab8b801cf9",
    "creator_id": "11038",
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version_date": "2017-02-15T12:34:56.789+0200"
  }
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "mdb_id": {
      "type": "string",
      "description": "the id of the material database this item belongs to"
    },
    "category_id": {
      "type": "string",
      "description": "the id of the category used for creating this item `templateId`"
    },
    "title": {
      "type": "string",
      "description": "the display name of the item"
    },
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version `itemId`"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the mdb item"
    },
    "creator_id": {
      "type": "string",
      "description": "the id of the original author of this item"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the mdb item"
    },
    "version": {
      "type": "number",
      "description": "the version number (it is automatically incremented for each modification on the item) `itemVersion`"
    },
    "version_count": {
      "type": "number",
      "description": "the total number of versions available"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the mdb item"
    },
    "version_author_id": {
      "type": "string",
      "description": "the id of the person that edited this version of the item"
    },
    "custom_attributes": {
      "type": "object",
      "properties": {
        "0553c003-9014-47ef-9522-115ad7d4b3a1": {
          "type": [
            "string",
            "null"
          ],
          "description": "The attribute id plus it's associated value"
        }
      },
      "description": "The attribute values of this mdb item according to the category field"
    },
    "status": {
      "type": "string",
      "enum": [
        "IN_STOCK",
        "OUT_STOCK",
        "DELETED",
        "ORDERED"
      ],
      "description": "the stock status of the item"
    },
    "category": {
      "type": "object",
      "properties": {
        "title": {
          "type": "string",
          "description": "the display name of the mdb"
        },
        "attributes": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "Text",
                  "Date",
                  "Number"
                ]
              },
              "title": {
                "type": "string",
                "description": "the display title of the attribute"
              },
              "mandatory": {
                "type": "boolean",
                "description": "is a value mandatory for this attribute"
              }
            },
            "required": [
              "type",
              "title",
              "mandatory"
            ]
          },
          "description": "The attributes for this item category"
        },
        "mdb_id": {
          "type": "string",
          "description": "the id of the material database this category is associated with"
        },
        "id": {
          "type": "string",
          "description": "the id of the category"
        },
        "creator_id": {
          "type": "string",
          "description": "the id of the original author"
        },
        "creation_date": {
          "type": "string",
          "description": "the creation date of the item category"
        },
        "version_date": {
          "type": "string",
          "description": "the last modification date of the item category"
        }
      },
      "required": [
        "title",
        "mdb_id",
        "id",
        "creator_id",
        "creation_date",
        "version_date"
      ],
      "description": "the category referenced by the `category_id` property"
    }
  },
  "required": [
    "mdb_id",
    "category_id",
    "title",
    "id",
    "version_id",
    "creator_id",
    "creation_date",
    "version",
    "version_count",
    "version_date",
    "version_author_id",
    "custom_attributes",
    "status",
    "category"
  ]
}

Create Item
POST/mdb/items

Create a material database item

Example URI

POST /mdb/items
Request  Create Item
HideShow
Headers
Content-Type: application/json
Body
{
  "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
  "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
  "title": "X-Wing Fighter"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "mdb_id": {
      "type": "string",
      "description": "the id of the material database this item belongs to"
    },
    "category_id": {
      "type": "string",
      "description": "the id of the category used for creating this item `templateId`"
    },
    "title": {
      "type": "string",
      "description": "the display name of the item"
    }
  },
  "required": [
    "mdb_id",
    "category_id",
    "title"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /mdb/items/1d573349-347b-4e46-a956-863d4e2db356
Body
{
  "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
  "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
  "title": "X-Wing Fighter",
  "id": "1d573349-347b-4e46-a956-863d4e2db356",
  "version_id": "620c535d-45bd-497a-ad92-d0222f959d6b",
  "creator_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version": 8,
  "version_count": 10,
  "version_date": "2017-02-15T12:34:56.789+0200",
  "version_author_id": "11040",
  "custom_attributes": {
    "0553c003-9014-47ef-9522-115ad7d4b3a1": "1001"
  },
  "status": "IN_STOCK"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "mdb_id": {
      "type": "string",
      "description": "the id of the material database this item belongs to"
    },
    "category_id": {
      "type": "string",
      "description": "the id of the category used for creating this item `templateId`"
    },
    "title": {
      "type": "string",
      "description": "the display name of the item"
    },
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version `itemId`"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the mdb item"
    },
    "creator_id": {
      "type": "string",
      "description": "the id of the original author of this item"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the mdb item"
    },
    "version": {
      "type": "number",
      "description": "the version number (it is automatically incremented for each modification on the item) `itemVersion`"
    },
    "version_count": {
      "type": "number",
      "description": "the total number of versions available"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the mdb item"
    },
    "version_author_id": {
      "type": "string",
      "description": "the id of the person that edited this version of the item"
    },
    "custom_attributes": {
      "type": "object",
      "properties": {
        "0553c003-9014-47ef-9522-115ad7d4b3a1": {
          "type": [
            "string",
            "null"
          ],
          "description": "The attribute id plus it's associated value"
        }
      },
      "description": "The attribute values of this mdb item according to the category field"
    },
    "status": {
      "type": "string",
      "enum": [
        "IN_STOCK",
        "OUT_STOCK",
        "DELETED",
        "ORDERED"
      ],
      "description": "the stock status of the item"
    }
  },
  "required": [
    "mdb_id",
    "category_id",
    "title",
    "id",
    "version_id",
    "creator_id",
    "creation_date",
    "version",
    "version_count",
    "version_date",
    "version_author_id",
    "custom_attributes",
    "status"
  ]
}
Request  Create Item with Custom Attribute
HideShow
Headers
Content-Type: application/json
Body
{
  "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
  "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
  "title": "X-Wing Fighter",
  "custom_attributes": {
    "0553c003-9014-47ef-9522-115ad7d4b3a1": "1001"
  }
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "mdb_id": {
      "type": "string",
      "description": "the id of the material database this item belongs to"
    },
    "category_id": {
      "type": "string",
      "description": "the id of the category used for creating this item `templateId`"
    },
    "title": {
      "type": "string",
      "description": "the display name of the item"
    },
    "custom_attributes": {
      "type": "object",
      "properties": {
        "0553c003-9014-47ef-9522-115ad7d4b3a1": {
          "type": [
            "string",
            "null"
          ],
          "description": "The attribute id plus it's associated value"
        }
      },
      "description": "The attribute values of this mdb item according to the category field"
    }
  },
  "required": [
    "mdb_id",
    "category_id",
    "title",
    "custom_attributes"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /mdb/items/1d573349-347b-4e46-a956-863d4e2db356
Body
{
  "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
  "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
  "title": "X-Wing Fighter",
  "id": "1d573349-347b-4e46-a956-863d4e2db356",
  "version_id": "620c535d-45bd-497a-ad92-d0222f959d6b",
  "creator_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version": 8,
  "version_count": 10,
  "version_date": "2017-02-15T12:34:56.789+0200",
  "version_author_id": "11040",
  "custom_attributes": {
    "0553c003-9014-47ef-9522-115ad7d4b3a1": "1001"
  },
  "status": "IN_STOCK"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "mdb_id": {
      "type": "string",
      "description": "the id of the material database this item belongs to"
    },
    "category_id": {
      "type": "string",
      "description": "the id of the category used for creating this item `templateId`"
    },
    "title": {
      "type": "string",
      "description": "the display name of the item"
    },
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version `itemId`"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the mdb item"
    },
    "creator_id": {
      "type": "string",
      "description": "the id of the original author of this item"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the mdb item"
    },
    "version": {
      "type": "number",
      "description": "the version number (it is automatically incremented for each modification on the item) `itemVersion`"
    },
    "version_count": {
      "type": "number",
      "description": "the total number of versions available"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the mdb item"
    },
    "version_author_id": {
      "type": "string",
      "description": "the id of the person that edited this version of the item"
    },
    "custom_attributes": {
      "type": "object",
      "properties": {
        "0553c003-9014-47ef-9522-115ad7d4b3a1": {
          "type": [
            "string",
            "null"
          ],
          "description": "The attribute id plus it's associated value"
        }
      },
      "description": "The attribute values of this mdb item according to the category field"
    },
    "status": {
      "type": "string",
      "enum": [
        "IN_STOCK",
        "OUT_STOCK",
        "DELETED",
        "ORDERED"
      ],
      "description": "the stock status of the item"
    }
  },
  "required": [
    "mdb_id",
    "category_id",
    "title",
    "id",
    "version_id",
    "creator_id",
    "creation_date",
    "version",
    "version_count",
    "version_date",
    "version_author_id",
    "custom_attributes",
    "status"
  ]
}
Request  Create Item With Custom Stock Status
HideShow
Headers
Content-Type: application/json
Body
{
  "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
  "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
  "title": "X-Wing Fighter",
  "status": "IN_STOCK"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "mdb_id": {
      "type": "string",
      "description": "the id of the material database this item belongs to"
    },
    "category_id": {
      "type": "string",
      "description": "the id of the category used for creating this item `templateId`"
    },
    "title": {
      "type": "string",
      "description": "the display name of the item"
    },
    "status": {
      "type": "string",
      "enum": [
        "IN_STOCK",
        "OUT_STOCK",
        "DELETED",
        "ORDERED"
      ],
      "description": "the stock status of the item"
    }
  },
  "required": [
    "mdb_id",
    "category_id",
    "title",
    "status"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /mdb/items/1d573349-347b-4e46-a956-863d4e2db356
Body
{
  "mdb_id": "1935c7cf-d340-4dc2-a0ed-f3ac85bc2874",
  "category_id": "e87e6534-2ae0-4139-bc48-cc668f330069",
  "title": "X-Wing Fighter",
  "id": "1d573349-347b-4e46-a956-863d4e2db356",
  "version_id": "620c535d-45bd-497a-ad92-d0222f959d6b",
  "creator_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version": 8,
  "version_count": 10,
  "version_date": "2017-02-15T12:34:56.789+0200",
  "version_author_id": "11040",
  "custom_attributes": {
    "0553c003-9014-47ef-9522-115ad7d4b3a1": "1001"
  },
  "status": "IN_STOCK"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "mdb_id": {
      "type": "string",
      "description": "the id of the material database this item belongs to"
    },
    "category_id": {
      "type": "string",
      "description": "the id of the category used for creating this item `templateId`"
    },
    "title": {
      "type": "string",
      "description": "the display name of the item"
    },
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version `itemId`"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the mdb item"
    },
    "creator_id": {
      "type": "string",
      "description": "the id of the original author of this item"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the mdb item"
    },
    "version": {
      "type": "number",
      "description": "the version number (it is automatically incremented for each modification on the item) `itemVersion`"
    },
    "version_count": {
      "type": "number",
      "description": "the total number of versions available"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the mdb item"
    },
    "version_author_id": {
      "type": "string",
      "description": "the id of the person that edited this version of the item"
    },
    "custom_attributes": {
      "type": "object",
      "properties": {
        "0553c003-9014-47ef-9522-115ad7d4b3a1": {
          "type": [
            "string",
            "null"
          ],
          "description": "The attribute id plus it's associated value"
        }
      },
      "description": "The attribute values of this mdb item according to the category field"
    },
    "status": {
      "type": "string",
      "enum": [
        "IN_STOCK",
        "OUT_STOCK",
        "DELETED",
        "ORDERED"
      ],
      "description": "the stock status of the item"
    }
  },
  "required": [
    "mdb_id",
    "category_id",
    "title",
    "id",
    "version_id",
    "creator_id",
    "creation_date",
    "version",
    "version_count",
    "version_date",
    "version_author_id",
    "custom_attributes",
    "status"
  ]
}

Delete Item
DELETE/mdb/items/{id}

Deletes the Item. Note: the entity is not deleted, but is flagged as ‘hidden’.

Example URI

DELETE /mdb/items/e8292212-2cce-433c-afb9-a39236b5f0ca
URI Parameters
HideShow
id
string (required) Example: e8292212-2cce-433c-afb9-a39236b5f0ca

id of the item

Response  204

Entry Elements

An Entry Element is a single element inside a notebook entry. An entry can consist of multiple elements laid out in a grid. These elements can be of different types. For example text elements, file elements (for upload files), image elements (for images) and tables.

Element for each type can be managed through different endpoints which are described in detail in the following sections. You need to create an entry first before you can add elements to it.

All operations on elements are automatically versioned through the containing entry. A new entry version will be created for each added, edited or removed element.

The following operations are available for elements:

File elements

Files can be added to notebook entries through the use of File Elements.

Currently it is possible to upload all kinds of file types. Known types will trigger front end functionality (e.g. Extract…).

Here are the supported types for frontend functionality:

Images

  • PNG/X-PNG (image/png, image/x-png)

  • JPG/JPEG/PJPG/PJPEG (image/jpg, image/jpeg, image/pjpg, image/pjpeg)

  • GIF (image/gif)

  • BMP (image/bmp)

  • TIFF (image/tiff)

Spreadsheets

  • MS Office Excel (application/vnd.ms-excel, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)

Texts

  • MS Office Word (application/msword)

  • CSV (text/csv)

Create File Element
POST/elements/file{?entry_id,file_name}

Create a file element for the provided notebook entry.

Send the raw binary content of the file as the request body using the appropriate (matching) Content-Type header.

Example URI

POST /elements/file?entry_id=938302&file_name=results.png
URI Parameters
HideShow
entry_id
string (required) Example: 938302

id of the entry to add the file element to.

file_name
string (required) Example: results.png

The name of the file

Request  /elements/file?entry_id=938302&file_name=results.png
HideShow
Headers
Content-Type: image/png
Body
... file content as binary ...
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /elements/file/67f7eb4dc5755c25a1555d2d5ecfd389406b3791
Body
{
  "id": "767930",
  "entry_id": "938302",
  "version_id": "767930",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "element_type": "FILE",
  "file_name": "results.png",
  "file_size": 14020,
  "content_type": "image/png"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version"
    },
    "entry_id": {
      "type": "string",
      "description": "the id of the stable pointer to the entry"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the element"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the entry element (first version)"
    },
    "version_date": {
      "type": "string",
      "description": "the creation date of the entry element version (same with the creation date on the first version)"
    },
    "element_type": {
      "type": "string",
      "enum": [
        "FILE"
      ],
      "description": "Denotes that this is a file element. The value is always `FILE`"
    },
    "file_name": {
      "type": "string",
      "description": "The name of the file"
    },
    "file_size": {
      "type": "number",
      "description": "The size of the file in bytes"
    },
    "content_type": {
      "type": "string",
      "description": "The type of the binary content which is sent on header parameter `Content-Type`"
    }
  },
  "required": [
    "id",
    "entry_id",
    "version_id",
    "owner_id",
    "creation_date",
    "version_date",
    "element_type",
    "file_name",
    "file_size",
    "content_type"
  ]
}

Get File Element
GET/elements/file/{id}

Returns the current version of the file element

Example URI

GET /elements/file/67f7eb4dc5755c25a1555d2d5ecfd389406b3791
URI Parameters
HideShow
id
string (required) Example: 67f7eb4dc5755c25a1555d2d5ecfd389406b3791

stable id of file element

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "id": "767930",
  "entry_id": "938302",
  "version_id": "767930",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "element_type": "FILE",
  "file_name": "results.png",
  "file_size": 14020,
  "content_type": "image/png"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version"
    },
    "entry_id": {
      "type": "string",
      "description": "the id of the stable pointer to the entry"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the element"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the entry element (first version)"
    },
    "version_date": {
      "type": "string",
      "description": "the creation date of the entry element version (same with the creation date on the first version)"
    },
    "element_type": {
      "type": "string",
      "enum": [
        "FILE"
      ],
      "description": "Denotes that this is a file element. The value is always `FILE`"
    },
    "file_name": {
      "type": "string",
      "description": "The name of the file"
    },
    "file_size": {
      "type": "number",
      "description": "The size of the file in bytes"
    },
    "content_type": {
      "type": "string",
      "description": "The type of the binary content which is sent on header parameter `Content-Type`"
    }
  },
  "required": [
    "id",
    "entry_id",
    "version_id",
    "owner_id",
    "creation_date",
    "version_date",
    "element_type",
    "file_name",
    "file_size",
    "content_type"
  ]
}

Download File
GET/elements/file/{id}/download

Access the file stored in the current version of the file element. If a file exists, the Content-Type header will match that of the file being accessed. If the file is empty, no content will be returned.

Example URI

GET /elements/file/67f7eb4dc5755c25a1555d2d5ecfd389406b3791/download
URI Parameters
HideShow
id
string (required) Example: 67f7eb4dc5755c25a1555d2d5ecfd389406b3791

stable id of file element

Request  File exists within the element
Response  200
HideShow
Headers
Content-Type: image/png
Body
... file content as binary ...

Data elements

Structured data can be added to notebook entries through the use of Data Elements.

There are three types of data elements: Individual Elements, Groups, and Material Elements.

Individual Elements

Individual elements are single measurements or observations which can contain <title> <value> <unit>.

NaCL    300     mg
<title> <value> <unit>

as JSON:

{
  'title': 'NaCL',
  'value': '300',
  'unit': 'mg',
  'type': 'SINGLE_DATA_ELEMENT'
}

When creating a data element it is not always necessary to provide a value for all possible fields. You can omit the value when creating a placeholder to fill out later (when creating within a template entry).

NaCl     mg
<title>  <value>

as JSON:

{
  'title': 'NaCL',
  'unit': 'mg',
  'type': 'SINGLE_DATA_ELEMENT'
}

You can also omit the unit when providing dimensionless data.

Success  true
<title>  <value>

as JSON:

{
  'title': 'Success',
  'value': 'true',
  'type': 'SINGLE_DATA_ELEMENT'
}

Supported Units

  • m/s^2 (Acceleration)

  • pmol (Amount of substance)

  • nmol (Amount of substance)

  • µmol (Amount of substance)

  • mmol (Amount of substance)

  • mol (Amount of substance)

  • kmol (Amount of substance)

  • Mmol (Amount of substance)

  • rad/s^2 (Angular Acceleration)

  • kg/m^2 s^-1 (Angular Momentum)

  • rad/s (Angular Speed)

  • Da (Atomic Mass)

  • u (Atomic Mass)

  • µF (Capacitance)

  • F (Capacitance)

  • rpm (Centrifugation)

  • G-force (Centrifugation)

  • J/mol (Chemical Potential)

  • kg/m^3 (Density)

  • nm (Diameter)

  • µm (Diameter)

  • mm (Diameter)

  • cm (Diameter)

  • m (Diameter)

  • C (Electric Charge)

  • C/m^3 (Electric Charge Density)

  • S (Electric Conductance)

  • C/m^2 (Electric Displacement)

  • V/m (Electric Field Strength)

  • C (Electric Flux)

  • S/m (Electrical Conductivity)

  • S/cm (Electrical Conductivity)

  • nA (Electrical Current)

  • µA (Electrical Current)

  • mA (Electrical Current)

  • A (Electrical Current)

  • mV (Electrical Potential)

  • V (Electrical Potential)

  • kV (Electrical Potential)

  • ohm (Electrical Resistance)

  • ohm m (Electrical Resistivity)

  • cm^2 V^-1 s^-1 (Electron mobility)

  • cal (Energy)

  • kcal (Energy)

  • J (Energy)

  • kJ (Energy)

  • MJ (Energy)

  • J/m^3 (Energy Density)

  • J/mol (Enthalpy)

  • cal/mol (Enthalpy)

  • kJ/mol (Enthalpy)

  • J K^-1 kg^-1 (Entropy)

  • J K^-1 mol^-1 (Entropy)

  • U/µg (Enzyme Activity)

  • U/mg (Enzyme Activity)

  • U/µL (Enzyme Activity)

  • U/mL (Enzyme Activity)

  • C/kg (Exposure (X and gamma rays))

  • N (Force)

  • Hz (Frequency)

  • Pa (Fugacity)

  • J (Heat)

  • J/K (Heat Capacity)

  • lx (Illuminance)

  • cd sr m^-2 (Illuminance)

  • phot (Illuminance)

  • m (Length)

  • mm (Length)

  • nm (Length)

  • µm (Length)

  • cm (Length)

  • lm (Luminous Flux)

  • cd (Luminous Intensity)

  • Wb m (Magnetic Dipole Moment)

  • A/m (Magnetic Field Strength)

  • V s (Magnetic Flux)

  • Wb (Magnetic Flux)

  • T (Magnetic Flux Density)

  • Wb/m^2 (Magnetic Flux Density)

  • A m^2 (Magnetic Moment)

  • Wb/m^2 (Magnetic Moment)

  • T (Magnetic Polarization)

  • Wb/m^2 (Magnetic Polarization)

  • A (Magnetic Potential Difference)

  • A m^2/kg (Magnetization (Mass))

  • Wb m/kg (Magnetization (Mass))

  • A/m (Magnetization (Volume))

  • pg (Mass)

  • g (Mass)

  • mg (Mass)

  • µg (Mass)

  • ng (Mass)

  • kg (Mass)

  • % (Mass concentration)

  • pg/µL (Mass concentration)

  • µg/µL (Mass concentration)

  • pg/mL (Mass concentration)

  • ng/mL (Mass concentration)

  • mg/mL (Mass concentration)

  • g/L (Mass concentration)

  • mg/L (Mass concentration)

  • g/mL (Mass concentration)

  • ng/µl (Mass concentration)

  • µg/L (Mass concentration)

  • µg/mL (Mass concentration)

  • kg (Mass of Entity)

  • yM (Molar concentration)

  • zM (Molar concentration)

  • aM (Molar concentration)

  • fM (Molar concentration)

  • pM (Molar concentration)

  • nM (Molar concentration)

  • µM (Molar concentration)

  • mM (Molar concentration)

  • M (Molar concentration)

  • g/mol (Molar mass)

  • m^3/mol (Molar Volume)

  • H/m (Permeability)

  • Wb/A m (Permeability)

  • F/m (Permittivity)

  • W (Power)

  • Pa (Pressure)

  • bar (Pressure)

  • Torr (Pressure)

  • atm (Pressure)

  • Bq (Radioactivity)

  • Ci (Radioactivity)

  • mol/m^3 (Solubility)

  • m/s (Speed)

  • m/s (Speed of Light (Medium))

  • m/s (Speed of Light (Vacuum))

  • m^3/kg (Susceptibility (Mass))

  • H m^2/kg (Susceptibility (Mass))

  • H/m (Susceptibility (volume))

  • Wb/A m (Susceptibility (volume))

  • °C (Temperature)

  • °F (Temperature)

  • K (Temperature)

  • °C/s (Temperature Ramp Rate)

  • °C/min (Temperature Ramp Rate)

  • °C/h (Temperature Ramp Rate)

  • K/min (Temperature Ramp Rate)

  • K/h (Temperature Ramp Rate)

  • J/K (Thermal capacity)

  • kg m^2/K s^2 (Thermal capacity)

  • sec (Time)

  • msec (Time)

  • minute(s) (Time)

  • hour(s) (Time)

  • day(s) (Time)

  • month(s) (Time)

  • year(s) (Time)

  • N m (Torque)

  • L (Volume)

  • mL (Volume)

  • µL (Volume)

  • nL (Volume)

  • cl (Volume)

  • dl (Volume)

  • % v/v (Volume concentration)

  • % w/v (Volume concentration)

  • % w/w (Volume concentration)

  • N (Weight)

  • J (Work)

Data Element Groups

Data Element Groups are used to create structure around other data elements. Groups only have a <title>. Additional elements can be associated with the group using the children property

<title>
Solution XYZ

as JSON (a Data Element Group without children):

{
  'title': 'Solution ABC',
  'type': 'DATA_ELEMENT_GROUP'
}

or (a Data Element Group with children)

{
  'title': 'Solution DEF',
  'type': 'DATA_ELEMENT_GROUP',
  'children': [
    {
      'title': 'NaCL',
      'value': '300',
      'unit': 'mg',
      'type': 'SINGLE_DATA_ELEMENT'
    },
    {
      'title': 'Water',
      'value': '1000',
      'unit': 'mL',
      'type': 'SINGLE_DATA_ELEMENT'
    }
  ]
}

You can nest groups within groups but only at the top level. Nested groups can’t have other groups as children.

Create Data Element
POST/elements/data

Create a data element container for the provided notebook entry.

Example URI

POST /elements/data
Request  Create Data Element Group
HideShow
Headers
Content-Type: application/json
Body
{
  "entry_id": "938302",
  "data_elements": [
    {
      "type": "DATA_ELEMENT_GROUP",
      "title": "Solution XYZ",
      "children": [
        {
          "type": "SINGLE_DATA_ELEMENT",
          "title": "NaCl",
          "value": "200",
          "unit": "mL"
        },
        {
          "type": "SINGLE_DATA_ELEMENT",
          "title": "Love",
          "value": "900",
          "unit": "mL"
        },
        {
          "type": "SINGLE_DATA_ELEMENT",
          "title": "Water",
          "value": "300",
          "unit": "mL"
        }
      ]
    }
  ]
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "entry_id": {
      "type": "string",
      "description": "the stable id of the entry which the element will be created in."
    },
    "data_elements": {
      "type": "array",
      "description": "The data elements. See description of data elements for details on format."
    }
  },
  "required": [
    "entry_id",
    "data_elements"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /elements/data/767930
Body
{
  "id": "767930",
  "entry_id": "938302",
  "version_id": "767930",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "element_type": "DATA",
  "data_elements": [
    {
      "type": "DATA_ELEMENT_GROUP",
      "title": "Solution XYZ",
      "children": [
        {
          "type": "SINGLE_DATA_ELEMENT",
          "title": "NaCl",
          "value": "200",
          "unit": "mL"
        },
        {
          "type": "SINGLE_DATA_ELEMENT",
          "title": "Love",
          "value": "900",
          "unit": "mL"
        },
        {
          "type": "SINGLE_DATA_ELEMENT",
          "title": "Water",
          "value": "300",
          "unit": "mL"
        }
      ]
    }
  ]
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version"
    },
    "entry_id": {
      "type": "string",
      "description": "the id of the stable pointer to the entry"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the element"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the entry element (first version)"
    },
    "version_date": {
      "type": "string",
      "description": "the creation date of the entry element version (same with the creation date on the first version)"
    },
    "element_type": {
      "type": "string",
      "enum": [
        "DATA"
      ],
      "description": "Denotes that this is a data elements entry element. The value is always `DATA`"
    },
    "data_elements": {
      "type": "array",
      "description": "The data elements. See description of data elements for details on format."
    }
  },
  "required": [
    "id",
    "entry_id",
    "version_id",
    "owner_id",
    "creation_date",
    "version_date",
    "element_type",
    "data_elements"
  ]
}
Request  Create Single Data Element
HideShow
Headers
Content-Type: application/json
Body
{
  "entry_id": "938302",
  "data_elements": [
    {
      "type": "SINGLE_DATA_ELEMENT",
      "title": "Water",
      "value": "300",
      "unit": "mL"
    }
  ]
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "entry_id": {
      "type": "string",
      "description": "the stable id of the entry which the element will be created in."
    },
    "data_elements": {
      "type": "array",
      "description": "The data elements. See description of data elements for details on format."
    }
  },
  "required": [
    "entry_id",
    "data_elements"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /elements/data/767930
Body
{
  "id": "767930",
  "entry_id": "938302",
  "version_id": "767930",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "element_type": "DATA",
  "data_elements": [
    {
      "type": "SINGLE_DATA_ELEMENT",
      "title": "Water",
      "value": "300",
      "unit": "mL"
    }
  ]
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version"
    },
    "entry_id": {
      "type": "string",
      "description": "the id of the stable pointer to the entry"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the element"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the entry element (first version)"
    },
    "version_date": {
      "type": "string",
      "description": "the creation date of the entry element version (same with the creation date on the first version)"
    },
    "element_type": {
      "type": "string",
      "enum": [
        "DATA"
      ],
      "description": "Denotes that this is a data elements entry element. The value is always `DATA`"
    },
    "data_elements": {
      "type": "array",
      "description": "The data elements. See description of data elements for details on format."
    }
  },
  "required": [
    "id",
    "entry_id",
    "version_id",
    "owner_id",
    "creation_date",
    "version_date",
    "element_type",
    "data_elements"
  ]
}
Request  Create Material Data Element
HideShow
Headers
Content-Type: application/json
Body
{
  "entry_id": "938302",
  "data_elements": [
    {
      "type": "MATERIAL_DATA_ELEMENT",
      "item_id": "d395ff8e-3430-4cb5-8d34-b0a3399bf6b3"
    }
  ]
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "entry_id": {
      "type": "string",
      "description": "the stable id of the entry which the element will be created in."
    },
    "data_elements": {
      "type": "array",
      "description": "The data elements. See description of data elements for details on format."
    }
  },
  "required": [
    "entry_id",
    "data_elements"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /elements/data/767930
Body
{
  "id": "767930",
  "entry_id": "938302",
  "version_id": "767930",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "element_type": "DATA",
  "data_elements": [
    {
      "type": "MATERIAL_DATA_ELEMENT",
      "item_id": "d395ff8e-3430-4cb5-8d34-b0a3399bf6b3"
    }
  ]
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version"
    },
    "entry_id": {
      "type": "string",
      "description": "the id of the stable pointer to the entry"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the element"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the entry element (first version)"
    },
    "version_date": {
      "type": "string",
      "description": "the creation date of the entry element version (same with the creation date on the first version)"
    },
    "element_type": {
      "type": "string",
      "enum": [
        "DATA"
      ],
      "description": "Denotes that this is a data elements entry element. The value is always `DATA`"
    },
    "data_elements": {
      "type": "array",
      "description": "The data elements. See description of data elements for details on format."
    }
  },
  "required": [
    "id",
    "entry_id",
    "version_id",
    "owner_id",
    "creation_date",
    "version_date",
    "element_type",
    "data_elements"
  ]
}
Request  Create Descriptive Data Element
HideShow
Headers
Content-Type: application/json
Body
{
  "entry_id": "938302",
  "data_elements": [
    {
      "type": "DESCRIPTIVE_DATA_ELEMENT",
      "title": "Descriptive XYZ",
      "description": "Some very scientific and hard to understand description which will ruin the nature first and then rescue it"
    }
  ]
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "entry_id": {
      "type": "string",
      "description": "the stable id of the entry which the element will be created in."
    },
    "data_elements": {
      "type": "array",
      "description": "The data elements. See description of data elements for details on format."
    }
  },
  "required": [
    "entry_id",
    "data_elements"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /elements/data/767930
Body
{
  "id": "767930",
  "entry_id": "938302",
  "version_id": "767930",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "element_type": "DATA",
  "data_elements": [
    {
      "type": "DESCRIPTIVE_DATA_ELEMENT",
      "title": "Descriptive XYZ",
      "description": "Some very scientific and hard to understand description which will ruin the nature first and then rescue it"
    }
  ]
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version"
    },
    "entry_id": {
      "type": "string",
      "description": "the id of the stable pointer to the entry"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the element"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the entry element (first version)"
    },
    "version_date": {
      "type": "string",
      "description": "the creation date of the entry element version (same with the creation date on the first version)"
    },
    "element_type": {
      "type": "string",
      "enum": [
        "DATA"
      ],
      "description": "Denotes that this is a data elements entry element. The value is always `DATA`"
    },
    "data_elements": {
      "type": "array",
      "description": "The data elements. See description of data elements for details on format."
    }
  },
  "required": [
    "id",
    "entry_id",
    "version_id",
    "owner_id",
    "creation_date",
    "version_date",
    "element_type",
    "data_elements"
  ]
}

Table elements

Table Data can be added to notebook entries. Table element may have a title and content in the Grapecity Spread.JS format. The object sent in the field content must be valid according to the Grapecity Documentation for JSON schema.

Get Table Element
GET/elements/table/{id}

Returns the current version of the table element

Example URI

GET /elements/table/0801c8932f4567dc59eeb806d3c2f2be592a99ac
URI Parameters
HideShow
id
string (required) Example: 0801c8932f4567dc59eeb806d3c2f2be592a99ac

stable id of table element

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "id": "0801c8932f4567dc59eeb806d3c2f2be592a99ac",
  "entry_id": "938302",
  "version_id": "767930",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "element_type": "TABLE",
  "title": "Rebellion Table",
  "content": null
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version"
    },
    "entry_id": {
      "type": "string",
      "description": "the id of the stable pointer to the entry"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the element"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the entry element (first version)"
    },
    "version_date": {
      "type": "string",
      "description": "the creation date of the entry element version (same with the creation date on the first version)"
    },
    "element_type": {
      "type": "string",
      "enum": [
        "TABLE"
      ],
      "description": "Denotes that this is a table element. The value is always `TABLE`"
    },
    "title": {
      "type": [
        "string",
        "null"
      ],
      "description": "The title of the table"
    },
    "content": {
      "type": [
        "object",
        "null"
      ],
      "properties": {},
      "description": "The JSON content of the table element"
    }
  },
  "required": [
    "id",
    "entry_id",
    "version_id",
    "owner_id",
    "creation_date",
    "version_date",
    "element_type",
    "title",
    "content"
  ]
}

Get Table Element Version
GET/elements/table/{id}/version/{versionId}

Returns the table element in the specified entry version

Example URI

GET /elements/table/0801c8932f4567dc59eeb806d3c2f2be592a99ac/version/2309984
URI Parameters
HideShow
id
string (required) Example: 0801c8932f4567dc59eeb806d3c2f2be592a99ac

stable id of table element

versionId
string (required) Example: 2309984

element version id of the table element

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "id": "0801c8932f4567dc59eeb806d3c2f2be592a99ac",
  "entry_id": "938302",
  "version_id": "767930",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "element_type": "TABLE",
  "title": "Rebellion Table",
  "content": null
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version"
    },
    "entry_id": {
      "type": "string",
      "description": "the id of the stable pointer to the entry"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the element"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the entry element (first version)"
    },
    "version_date": {
      "type": "string",
      "description": "the creation date of the entry element version (same with the creation date on the first version)"
    },
    "element_type": {
      "type": "string",
      "enum": [
        "TABLE"
      ],
      "description": "Denotes that this is a table element. The value is always `TABLE`"
    },
    "title": {
      "type": [
        "string",
        "null"
      ],
      "description": "The title of the table"
    },
    "content": {
      "type": [
        "object",
        "null"
      ],
      "properties": {},
      "description": "The JSON content of the table element"
    }
  },
  "required": [
    "id",
    "entry_id",
    "version_id",
    "owner_id",
    "creation_date",
    "version_date",
    "element_type",
    "title",
    "content"
  ]
}

Create Table Element
POST/elements/table

Create a table element container for the provided notebook entry.

Example URI

POST /elements/table
Request  Create Table Element
HideShow
Headers
Content-Type: application/json
Body
{
  "entry_id": "938302",
  "title": "New Table Title",
  "content": {}
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "entry_id": {
      "type": "string",
      "description": "The id of the notebook entry"
    },
    "title": {
      "type": "string",
      "description": "The title of the table"
    },
    "content": {
      "type": "object",
      "properties": {},
      "description": "The JSON content of the table element"
    }
  },
  "required": [
    "entry_id"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /elements/table/0801c8932f4567dc59eeb806d3c2f2be592a99ac
Body
{
  "id": "0801c8932f4567dc59eeb806d3c2f2be592a99ac",
  "entry_id": "938302",
  "version_id": "767930",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "element_type": "TABLE",
  "title": "Rebellion Table",
  "content": null
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version"
    },
    "entry_id": {
      "type": "string",
      "description": "the id of the stable pointer to the entry"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the element"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the entry element (first version)"
    },
    "version_date": {
      "type": "string",
      "description": "the creation date of the entry element version (same with the creation date on the first version)"
    },
    "element_type": {
      "type": "string",
      "enum": [
        "TABLE"
      ],
      "description": "Denotes that this is a table element. The value is always `TABLE`"
    },
    "title": {
      "type": [
        "string",
        "null"
      ],
      "description": "The title of the table"
    },
    "content": {
      "type": [
        "object",
        "null"
      ],
      "properties": {},
      "description": "The JSON content of the table element"
    }
  },
  "required": [
    "id",
    "entry_id",
    "version_id",
    "owner_id",
    "creation_date",
    "version_date",
    "element_type",
    "title",
    "content"
  ]
}

Update Table Element
PUT/elements/table/{id}

Update a table element container for the provided notebook entry.

Example URI

PUT /elements/table/0801c8932f4567dc59eeb806d3c2f2be592a99ac
URI Parameters
HideShow
id
string (required) Example: 0801c8932f4567dc59eeb806d3c2f2be592a99ac

stable id of table element

Request  Update Table Element
HideShow
Headers
Content-Type: application/json
Body
{
  "entry_id": "938302",
  "title": "Updated Table Title",
  "content": {},
  "id": "0801c8932f4567dc59eeb806d3c2f2be592a99ac"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "entry_id": {
      "type": "string",
      "description": "The id of the notebook entry"
    },
    "title": {
      "type": "string",
      "description": "The title of the table"
    },
    "content": {
      "type": "object",
      "properties": {},
      "description": "The JSON content of the table element"
    },
    "id": {
      "type": "string",
      "description": "The id of the table element"
    }
  },
  "required": [
    "entry_id",
    "id"
  ]
}
Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "id": "0801c8932f4567dc59eeb806d3c2f2be592a99ac",
  "entry_id": "938302",
  "version_id": "767930",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200",
  "element_type": "TABLE",
  "title": "Rebellion Table",
  "content": null
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "the stable pointer to the most current version"
    },
    "entry_id": {
      "type": "string",
      "description": "the id of the stable pointer to the entry"
    },
    "version_id": {
      "type": "string",
      "description": "the unique id of the element"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the entry element (first version)"
    },
    "version_date": {
      "type": "string",
      "description": "the creation date of the entry element version (same with the creation date on the first version)"
    },
    "element_type": {
      "type": "string",
      "enum": [
        "TABLE"
      ],
      "description": "Denotes that this is a table element. The value is always `TABLE`"
    },
    "title": {
      "type": [
        "string",
        "null"
      ],
      "description": "The title of the table"
    },
    "content": {
      "type": [
        "object",
        "null"
      ],
      "properties": {},
      "description": "The JSON content of the table element"
    }
  },
  "required": [
    "id",
    "entry_id",
    "version_id",
    "owner_id",
    "creation_date",
    "version_date",
    "element_type",
    "title",
    "content"
  ]
}

Signature Workflows

A Signature Workflow is a procedure in which the intentions, actions, and people responsible for undertaking a reviewing process are set out through one or more sequential signatures.

The following operations are available for signature workflows:

Signature Workflows Resource

List Signature Workflows
GET/signature-workflows{?group_id,expand}

Returns the list of all signature workflows belong to the specified group

Example URI

GET /signature-workflows?group_id=1200&expand=
URI Parameters
HideShow
group_id
string (required) Example: 1200

The Group id which the workflow belongs to.

expand
string (optional) 

A comma separated list of related domain objects that should be expanded for all workflows returned.

Choices: owner

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
X-Total-Count: 1
X-Limit: 20
X-Offset: 0
Body
[
  {
    "title": "Luke's Signature Workflow",
    "group_id": "1200",
    "project_ids": [
      "36276"
    ],
    "signature_definitions": [
      {
        "title": "Luke's First Signature",
        "intention": {
          "label": "Signed By",
          "body": "I hereby certify that I carried out the documented steps"
        },
        "actions": [
          {
            "triggered_by": "APPROVAL",
            "type": "ADD_COMMENT",
            "body": "{}"
          }
        ],
        "signees": [
          "11038"
        ]
      },
      {
        "title": "Luke's First Signature",
        "intention": {
          "label": "Signed By",
          "body": "I hereby certify that I carried out the documented steps"
        },
        "actions": [
          {
            "triggered_by": "APPROVAL",
            "type": "ADD_COMMENT",
            "body": "{}"
          }
        ],
        "signees": [
          "11038"
        ]
      }
    ],
    "status": "DRAFT",
    "id": "6b08850a-3901-4499-b6f6-c0e15c72a19c",
    "owner_id": "11038",
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version_date": "2017-02-15T12:34:56.789+0200"
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "title": {
        "type": "string",
        "description": "the display name of the signature workflow"
      },
      "group_id": {
        "type": "string",
        "description": "the group id which the workflow belongs to"
      },
      "project_ids": {
        "type": "array",
        "description": "the project ids which the workflow is applicable to"
      },
      "signature_definitions": {
        "type": "array",
        "description": "the signature steps of the workflow as an ordered list"
      },
      "status": {
        "type": "string",
        "enum": [
          "DRAFT",
          "PUBLISHED",
          "ACTIVE",
          "HIDDEN"
        ],
        "description": "the status of the workflow"
      },
      "id": {
        "type": "string",
        "description": "the unique id of the workflow"
      },
      "owner_id": {
        "type": "string",
        "description": "the id of the original author of this signature workflow"
      },
      "creation_date": {
        "type": "string",
        "description": "the creation date of the workflow"
      },
      "version_date": {
        "type": "string",
        "description": "the last modification date of the workflow"
      }
    },
    "required": [
      "title",
      "group_id",
      "project_ids",
      "signature_definitions",
      "status",
      "id",
      "owner_id",
      "creation_date",
      "version_date"
    ]
  }
}

List Signature Workflows
GET/signature-workflows{?project_id,expand}

Returns the list of all signature workflows assigned to the specified project

Example URI

GET /signature-workflows?project_id=36275&expand=
URI Parameters
HideShow
project_id
string (required) Example: 36275

The Project id which the workflow assigned to.

expand
string (optional) 

A comma separated list of related domain objects that should be expanded for all workflows returned.

Choices: owner

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
X-Total-Count: 1
X-Limit: 20
X-Offset: 0
Body
[
  {
    "title": "Luke's Signature Workflow",
    "group_id": "1200",
    "project_ids": [
      "36276"
    ],
    "signature_definitions": [
      {
        "title": "Luke's First Signature",
        "intention": {
          "label": "Signed By",
          "body": "I hereby certify that I carried out the documented steps"
        },
        "actions": [
          {
            "triggered_by": "APPROVAL",
            "type": "ADD_COMMENT",
            "body": "{}"
          }
        ],
        "signees": [
          "11038"
        ]
      },
      {
        "title": "Luke's First Signature",
        "intention": {
          "label": "Signed By",
          "body": "I hereby certify that I carried out the documented steps"
        },
        "actions": [
          {
            "triggered_by": "APPROVAL",
            "type": "ADD_COMMENT",
            "body": "{}"
          }
        ],
        "signees": [
          "11038"
        ]
      }
    ],
    "status": "DRAFT",
    "id": "6b08850a-3901-4499-b6f6-c0e15c72a19c",
    "owner_id": "11038",
    "creation_date": "2017-02-10T12:34:56.789+0200",
    "version_date": "2017-02-15T12:34:56.789+0200"
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "title": {
        "type": "string",
        "description": "the display name of the signature workflow"
      },
      "group_id": {
        "type": "string",
        "description": "the group id which the workflow belongs to"
      },
      "project_ids": {
        "type": "array",
        "description": "the project ids which the workflow is applicable to"
      },
      "signature_definitions": {
        "type": "array",
        "description": "the signature steps of the workflow as an ordered list"
      },
      "status": {
        "type": "string",
        "enum": [
          "DRAFT",
          "PUBLISHED",
          "ACTIVE",
          "HIDDEN"
        ],
        "description": "the status of the workflow"
      },
      "id": {
        "type": "string",
        "description": "the unique id of the workflow"
      },
      "owner_id": {
        "type": "string",
        "description": "the id of the original author of this signature workflow"
      },
      "creation_date": {
        "type": "string",
        "description": "the creation date of the workflow"
      },
      "version_date": {
        "type": "string",
        "description": "the last modification date of the workflow"
      }
    },
    "required": [
      "title",
      "group_id",
      "project_ids",
      "signature_definitions",
      "status",
      "id",
      "owner_id",
      "creation_date",
      "version_date"
    ]
  }
}

Get Signature Workflow
GET/signature-workflows/{id}

Returns the signature workflow

Example URI

GET /signature-workflows/c8ea2e7e-3755-497f-bd03-6b568dda025b
URI Parameters
HideShow
id
string (required) Example: c8ea2e7e-3755-497f-bd03-6b568dda025b

the unique id of the workflow

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "title": "Luke's Signature Workflow",
  "group_id": "1200",
  "project_ids": [
    "36276"
  ],
  "signature_definitions": [
    {
      "title": "Luke's First Signature",
      "intention": {
        "label": "Signed By",
        "body": "I hereby certify that I carried out the documented steps"
      },
      "actions": [
        {
          "triggered_by": "APPROVAL",
          "type": "ADD_COMMENT",
          "body": "{}"
        }
      ],
      "signees": [
        "11038"
      ]
    },
    {
      "title": "Luke's First Signature",
      "intention": {
        "label": "Signed By",
        "body": "I hereby certify that I carried out the documented steps"
      },
      "actions": [
        {
          "triggered_by": "APPROVAL",
          "type": "ADD_COMMENT",
          "body": "{}"
        }
      ],
      "signees": [
        "11038"
      ]
    }
  ],
  "status": "DRAFT",
  "id": "6b08850a-3901-4499-b6f6-c0e15c72a19c",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the signature workflow"
    },
    "group_id": {
      "type": "string",
      "description": "the group id which the workflow belongs to"
    },
    "project_ids": {
      "type": "array",
      "description": "the project ids which the workflow is applicable to"
    },
    "signature_definitions": {
      "type": "array",
      "description": "the signature steps of the workflow as an ordered list"
    },
    "status": {
      "type": "string",
      "enum": [
        "DRAFT",
        "PUBLISHED",
        "ACTIVE",
        "HIDDEN"
      ],
      "description": "the status of the workflow"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the workflow"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author of this signature workflow"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the workflow"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the workflow"
    }
  },
  "required": [
    "title",
    "group_id",
    "project_ids",
    "signature_definitions",
    "status",
    "id",
    "owner_id",
    "creation_date",
    "version_date"
  ]
}

Create Signature Workflow
POST/signature-workflows

Create a signature workflow

Example URI

POST /signature-workflows
Request  Create Signature Workflow
HideShow
Headers
Content-Type: application/json
Body
{
  "title": "Luke's Signature Workflow",
  "group_id": "1200",
  "project_ids": [
    "36276"
  ],
  "signature_definitions": [
    {
      "title": "Luke's First Signature",
      "intention": {
        "label": "Signed By",
        "body": "I hereby certify that I carried out the documented steps"
      },
      "actions": [
        {
          "triggered_by": "APPROVAL",
          "type": "ADD_COMMENT",
          "body": "{}"
        }
      ],
      "signees": [
        "11038"
      ]
    },
    {
      "title": "Luke's First Signature",
      "intention": {
        "label": "Signed By",
        "body": "I hereby certify that I carried out the documented steps"
      },
      "actions": [
        {
          "triggered_by": "APPROVAL",
          "type": "ADD_COMMENT",
          "body": "{}"
        }
      ],
      "signees": [
        "11038"
      ]
    }
  ],
  "status": "DRAFT"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the signature workflow"
    },
    "group_id": {
      "type": "string",
      "description": "the group id which the workflow belongs to"
    },
    "project_ids": {
      "type": "array",
      "description": "the project ids which the workflow is applicable to"
    },
    "signature_definitions": {
      "type": "array",
      "description": "the signature steps of the workflow as an ordered list"
    },
    "status": {
      "type": "string",
      "enum": [
        "DRAFT",
        "PUBLISHED",
        "ACTIVE",
        "HIDDEN"
      ],
      "description": "the status of the workflow"
    }
  },
  "required": [
    "title",
    "group_id",
    "project_ids",
    "signature_definitions",
    "status"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /signature-workflows/1d573349-347b-4e46-a956-863d4e2db356
Body
{
  "title": "Luke's Signature Workflow",
  "group_id": "1200",
  "project_ids": [
    "36276"
  ],
  "signature_definitions": [
    {
      "title": "Luke's First Signature",
      "intention": {
        "label": "Signed By",
        "body": "I hereby certify that I carried out the documented steps"
      },
      "actions": [
        {
          "triggered_by": "APPROVAL",
          "type": "ADD_COMMENT",
          "body": "{}"
        }
      ],
      "signees": [
        "11038"
      ]
    },
    {
      "title": "Luke's First Signature",
      "intention": {
        "label": "Signed By",
        "body": "I hereby certify that I carried out the documented steps"
      },
      "actions": [
        {
          "triggered_by": "APPROVAL",
          "type": "ADD_COMMENT",
          "body": "{}"
        }
      ],
      "signees": [
        "11038"
      ]
    }
  ],
  "status": "DRAFT",
  "id": "6b08850a-3901-4499-b6f6-c0e15c72a19c",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the signature workflow"
    },
    "group_id": {
      "type": "string",
      "description": "the group id which the workflow belongs to"
    },
    "project_ids": {
      "type": "array",
      "description": "the project ids which the workflow is applicable to"
    },
    "signature_definitions": {
      "type": "array",
      "description": "the signature steps of the workflow as an ordered list"
    },
    "status": {
      "type": "string",
      "enum": [
        "DRAFT",
        "PUBLISHED",
        "ACTIVE",
        "HIDDEN"
      ],
      "description": "the status of the workflow"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the workflow"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author of this signature workflow"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the workflow"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the workflow"
    }
  },
  "required": [
    "title",
    "group_id",
    "project_ids",
    "signature_definitions",
    "status",
    "id",
    "owner_id",
    "creation_date",
    "version_date"
  ]
}

Update Signature Workflow
PUT/signature-workflows/{id}

Update an existing signature workflow

Example URI

PUT /signature-workflows/6b08850a-3901-4499-b6f6-c0e15c72a19c
URI Parameters
HideShow
id
string (required) Example: 6b08850a-3901-4499-b6f6-c0e15c72a19c

id of the signature workflow to update

Request  Update Signature Workflow
HideShow
Headers
Content-Type: application/json
Body
{
  "title": "Luke's Signature Workflow",
  "group_id": "1200",
  "project_ids": [
    "36276"
  ],
  "signature_definitions": [
    {
      "title": "Luke's First Signature",
      "intention": {
        "label": "Signed By",
        "body": "I hereby certify that I carried out the documented steps"
      },
      "actions": [
        {
          "triggered_by": "APPROVAL",
          "type": "ADD_COMMENT",
          "body": "{}"
        }
      ],
      "signees": [
        "11038"
      ]
    },
    {
      "title": "Luke's First Signature",
      "intention": {
        "label": "Signed By",
        "body": "I hereby certify that I carried out the documented steps"
      },
      "actions": [
        {
          "triggered_by": "APPROVAL",
          "type": "ADD_COMMENT",
          "body": "{}"
        }
      ],
      "signees": [
        "11038"
      ]
    }
  ],
  "status": "DRAFT",
  "id": "6b08850a-3901-4499-b6f6-c0e15c72a19c"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the signature workflow"
    },
    "group_id": {
      "type": "string",
      "description": "the group id which the workflow belongs to"
    },
    "project_ids": {
      "type": "array",
      "description": "the project ids which the workflow is applicable to"
    },
    "signature_definitions": {
      "type": "array",
      "description": "the signature steps of the workflow as an ordered list"
    },
    "status": {
      "type": "string",
      "enum": [
        "DRAFT",
        "PUBLISHED",
        "ACTIVE",
        "HIDDEN"
      ],
      "description": "the status of the workflow"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the workflow"
    }
  },
  "required": [
    "title",
    "group_id",
    "project_ids",
    "signature_definitions",
    "status",
    "id"
  ]
}
Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
{
  "title": "Luke's Signature Workflow",
  "group_id": "1200",
  "project_ids": [
    "36276"
  ],
  "signature_definitions": [
    {
      "title": "Luke's First Signature",
      "intention": {
        "label": "Signed By",
        "body": "I hereby certify that I carried out the documented steps"
      },
      "actions": [
        {
          "triggered_by": "APPROVAL",
          "type": "ADD_COMMENT",
          "body": "{}"
        }
      ],
      "signees": [
        "11038"
      ]
    },
    {
      "title": "Luke's First Signature",
      "intention": {
        "label": "Signed By",
        "body": "I hereby certify that I carried out the documented steps"
      },
      "actions": [
        {
          "triggered_by": "APPROVAL",
          "type": "ADD_COMMENT",
          "body": "{}"
        }
      ],
      "signees": [
        "11038"
      ]
    }
  ],
  "status": "DRAFT",
  "id": "6b08850a-3901-4499-b6f6-c0e15c72a19c",
  "owner_id": "11038",
  "creation_date": "2017-02-10T12:34:56.789+0200",
  "version_date": "2017-02-15T12:34:56.789+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "the display name of the signature workflow"
    },
    "group_id": {
      "type": "string",
      "description": "the group id which the workflow belongs to"
    },
    "project_ids": {
      "type": "array",
      "description": "the project ids which the workflow is applicable to"
    },
    "signature_definitions": {
      "type": "array",
      "description": "the signature steps of the workflow as an ordered list"
    },
    "status": {
      "type": "string",
      "enum": [
        "DRAFT",
        "PUBLISHED",
        "ACTIVE",
        "HIDDEN"
      ],
      "description": "the status of the workflow"
    },
    "id": {
      "type": "string",
      "description": "the unique id of the workflow"
    },
    "owner_id": {
      "type": "string",
      "description": "the id of the original author of this signature workflow"
    },
    "creation_date": {
      "type": "string",
      "description": "the creation date of the workflow"
    },
    "version_date": {
      "type": "string",
      "description": "the last modification date of the workflow"
    }
  },
  "required": [
    "title",
    "group_id",
    "project_ids",
    "signature_definitions",
    "status",
    "id",
    "owner_id",
    "creation_date",
    "version_date"
  ]
}

Signatures Resource

A Signature is applied to an entry and documents the authorizing of a cheque for the entries content.

List Signatures
GET/signatures{?entry_id,entry_version_id,expand}

Returns the list of signatures

Note that exactly one of the parameters entry_id or entry_version_id is mandatory to provide with the request.

Example URI

GET /signatures?entry_id=938302&entry_version_id=&expand=
URI Parameters
HideShow
entry_id
string (optional) Example: 938302

filter signatures being applied to latest version of specific entry

entry_version_id
string (optional) 

filter signatures being applied to specific entry version

expand
string (optional) 

Choices: owner

Response  200
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Body
[
  {
    "entry_id": "938303",
    "signature_definition_id": "441646aa-449e-4d46-a493-c0cf6406db21",
    "intention": {
      "label": "Signed By",
      "body": "I hereby certify that I carried out the documented steps"
    },
    "type": "APPROVAL",
    "id": "21e16a61-fd64-4b55-b679-7a0c74cf855b",
    "owner_id": "11038",
    "biometric_doc_id": "465862",
    "hash": "90b30ef9902ae4c4c691d2d78c2f8fa0aa785afbc5545286b310f68e91dd2299c84a2484f0419fc5eaa7de598940799e1091c4948926ae1c9488dddae180bb80",
    "hash_version": 4,
    "creation_date": "2018-11-07T16:32:12.729+0200"
  }
]
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "entry_id": {
        "type": "string",
        "description": "the id of the entry that is signed with the signature"
      },
      "signature_definition_id": {
        "type": "string",
        "description": "id of the signature definition as defined in the signature workflow"
      },
      "intention": {
        "type": "object",
        "properties": {
          "label": {
            "type": "string",
            "description": "the label of the signature"
          },
          "body": {
            "type": "string",
            "description": "the intention body of the signature"
          }
        },
        "required": [
          "label",
          "body"
        ],
        "description": "the intention describing the signature"
      },
      "type": {
        "type": "string",
        "enum": [
          "APPROVAL",
          "REJECTION"
        ],
        "description": "signature submit type"
      },
      "id": {
        "type": "string",
        "description": "uuid of the entry signature"
      },
      "owner_id": {
        "type": "string",
        "description": "the unique id of the user who created the signature"
      },
      "biometric_doc_id": {
        "type": [
          "string",
          "null"
        ],
        "description": "file id containing the biometric signature"
      },
      "hash": {
        "type": "string",
        "description": "SHA hash value of the entry content"
      },
      "hash_version": {
        "type": "number",
        "description": "indicating which version of the internal hash implementation was used to produce the hash value"
      },
      "creation_date": {
        "type": "string",
        "description": "timestamp of the signature creation"
      }
    },
    "required": [
      "entry_id",
      "signature_definition_id",
      "intention",
      "type",
      "id",
      "owner_id",
      "biometric_doc_id",
      "hash",
      "hash_version",
      "creation_date"
    ]
  }
}

Create Signature
POST/signatures

Create a signature for an entry

Example URI

POST /signatures
Request  Create Signature
HideShow
Headers
Content-Type: application/json
Body
{
  "entry_id": "938303",
  "signature_definition_id": "441646aa-449e-4d46-a493-c0cf6406db21",
  "intention": {
    "label": "Signed By",
    "body": "I hereby certify that I carried out the documented steps"
  },
  "type": "APPROVAL",
  "biometric_sign_data": "iVBORw0KGgoAAAANSUhEUgAAAAEAAAABAQMAAAAl21bKAAAAA1BMVEX/TQBcNTh/AAAAAXRSTlMAQObYZgAAAApJREFUeJxjYgAAAAYAAzY3fKgAAAAASUVORK5CYII="
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "entry_id": {
      "type": "string",
      "description": "the id of the entry that is signed with the signature"
    },
    "signature_definition_id": {
      "type": "string",
      "description": "id of the signature definition as defined in the signature workflow"
    },
    "intention": {
      "type": "object",
      "properties": {
        "label": {
          "type": "string",
          "description": "the label of the signature"
        },
        "body": {
          "type": "string",
          "description": "the intention body of the signature"
        }
      },
      "required": [
        "label",
        "body"
      ],
      "description": "the intention describing the signature"
    },
    "type": {
      "type": "string",
      "enum": [
        "APPROVAL",
        "REJECTION"
      ],
      "description": "signature submit type"
    },
    "biometric_sign_data": {
      "type": "string",
      "description": "base64 encoded image data, containing biometrical signature"
    }
  },
  "required": [
    "entry_id",
    "signature_definition_id",
    "intention",
    "type"
  ]
}
Response  201
HideShow
Headers
Content-Type: application/json;charset=UTF-8
Location: /signatures/1d573349-347b-4e46-a956-863d4e2db356
Body
{
  "entry_id": "938303",
  "signature_definition_id": "441646aa-449e-4d46-a493-c0cf6406db21",
  "intention": {
    "label": "Signed By",
    "body": "I hereby certify that I carried out the documented steps"
  },
  "type": "APPROVAL",
  "id": "21e16a61-fd64-4b55-b679-7a0c74cf855b",
  "owner_id": "11038",
  "biometric_doc_id": "465862",
  "hash": "90b30ef9902ae4c4c691d2d78c2f8fa0aa785afbc5545286b310f68e91dd2299c84a2484f0419fc5eaa7de598940799e1091c4948926ae1c9488dddae180bb80",
  "hash_version": 4,
  "creation_date": "2018-11-07T16:32:12.729+0200"
}
Schema
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "entry_id": {
      "type": "string",
      "description": "the id of the entry that is signed with the signature"
    },
    "signature_definition_id": {
      "type": "string",
      "description": "id of the signature definition as defined in the signature workflow"
    },
    "intention": {
      "type": "object",
      "properties": {
        "label": {
          "type": "string",
          "description": "the label of the signature"
        },
        "body": {
          "type": "string",
          "description": "the intention body of the signature"
        }
      },
      "required": [
        "label",
        "body"
      ],
      "description": "the intention describing the signature"
    },
    "type": {
      "type": "string",
      "enum": [
        "APPROVAL",
        "REJECTION"
      ],
      "description": "signature submit type"
    },
    "id": {
      "type": "string",
      "description": "uuid of the entry signature"
    },
    "owner_id": {
      "type": "string",
      "description": "the unique id of the user who created the signature"
    },
    "biometric_doc_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "file id containing the biometric signature"
    },
    "hash": {
      "type": "string",
      "description": "SHA hash value of the entry content"
    },
    "hash_version": {
      "type": "number",
      "description": "indicating which version of the internal hash implementation was used to produce the hash value"
    },
    "creation_date": {
      "type": "string",
      "description": "timestamp of the signature creation"
    }
  },
  "required": [
    "entry_id",
    "signature_definition_id",
    "intention",
    "type",
    "id",
    "owner_id",
    "biometric_doc_id",
    "hash",
    "hash_version",
    "creation_date"
  ]
}

Generated by aglio on 03 Dec 2018