Creates a document space.

POSThttps://api.awork.com/api/v1/documentspaces
POST https://api.awork.com/api/v1/documentspaces

Creates a document space and assigns the requested workspace access level. The space is inserted into the workspace order. The Basic, Standard and Connect plans allow one active space, including Home.

Authentication

AuthorizationBearer

Send your token in the Authorization: Bearer <token> header. See Authentication for API keys and OAuth.

Request body Required

The model used to create the document space.

application/json

namestring or nullOptional
minLength: 0 maxLength: 1000

The name of the document space.

emojistring or nullOptional
minLength: 0 maxLength: 25

The emoji of the document space.

colorstring or nullOptional
minLength: 0 maxLength: 14

The color of the document space for display purposes in the app. Can be null when no color assigned.

ordernumber or nullOptional
format: double

The order of the document space in the list of document spaces.

workspaceAccessLevelstring or nullOptional

Allowed: "none" "read" "manage"

minLength: 0 maxLength: 25

Determines the level of access to this document space granted to all workspace users. Can be either none, read, or manage.

Responses

200 OK

application/json

idstringOptional
format: uuid

The id of the entity.

createdOnstringOptional
format: date-time

The date this entity was created.

createdBystringOptional
format: uuid

The id of the user who created this entity.

updatedOnstringOptional
format: date-time

The date this entity was last modified.

updatedBystringOptional
format: uuid

The id of the user who last modified this entity.

namestring or nullOptional

The name of the document space.

isExternalbooleanOptional

Whether this document space is coming from an external workspace (awork Connect).

emojistring or nullOptional

The emoji of the document space.

colorstring or nullOptional

The color of the document space for display purposes in the app. Can be null when no color assigned.

ordernumber or nullOptional
format: double

The order of the document space in the list of document spaces.

workspaceAccessLevelstring or nullOptional

Determines the level of access to this document space granted to all workspace users. Can be either not set (no access), read, or manage.

contributorsarray of object or nullOptional

The contributors of this document space.

Show 7 properties
idstringOptional
format: uuid

The id of the contributor.

userIdstringOptional
format: uuid

The id of the user this contributor references.

accessLevelstring or nullOptional

Determines the level of access granted to this contributor with respect to the specific entity. Can be either set to read or manage.

firstNamestring or nullOptional

The first name of the user.

lastNamestring or nullOptional

The last name of the user.

hasImageboolean or nullOptional

Whether the user has an image.

isDeactivatedbooleanOptional

Whether the user is deactivated.

teamsarray of object or nullOptional

The teams this document space is connected to.

Show 6 properties
idstringOptional
format: uuid

The id of the entity to team.

teamIdstringOptional
format: uuid

The id of the team this entity to team references.

accessLevelstring or nullOptional

Determines the level of access granted to this entity to team with respect to the specific entity. Can be either set to read or manage.

namestring or nullOptional

The name of the team.

iconstring or nullOptional

The icon which is assigned to the team.

colorstring or nullOptional

The color of the team.

400 Bad Request

application/json

codestringRequired
minLength: 1

The error code.

descriptionstringRequired
minLength: 1

The description of the error.

linkstringRequired
minLength: 1

The link to the API documentation page.

detailsarray of string or nullOptional

A list of details describing the error.

validationErrorsarray of object or nullOptional

If a validation error occurred, this contains the validation errors for each property.

Show 2 properties
propertystring or nullOptional

The name of the property that failed validation.

messagestring or nullOptional

The reason why this property failed validation.

traceIdstring or nullOptional

The request trace id for tracking the request.

401 Unauthorized

application/json

codestringRequired
minLength: 1

The error code.

descriptionstringRequired
minLength: 1

The description of the error.

linkstringRequired
minLength: 1

The link to the API documentation page.

detailsarray of string or nullOptional

A list of details describing the error.

validationErrorsarray of object or nullOptional

If a validation error occurred, this contains the validation errors for each property.

Show 2 properties
propertystring or nullOptional

The name of the property that failed validation.

messagestring or nullOptional

The reason why this property failed validation.

traceIdstring or nullOptional

The request trace id for tracking the request.

Search documentation