For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
SupportDeveloper ForumLogin
  • Overview
    • Introduction
    • Getting Started
    • Integration Example (PSA)
    • Authentication
    • Error Handling
    • Pagination
    • Filtering
    • Ordering
    • Rate Limits
    • Permissions
    • Webhooks
    • MCP Server
    • Versioning
    • Changelog
    • Support
  • API v1 Reference
    • Projects Overview
    • Tasks Overview
    • Time Tracking Overview
    • Documents Overview
    • Search Overview
    • Companies Overview
    • Users Overview
      • GETGets all workspace absences.
      • POSTCreates a new workspace absence.
      • PUTUpdates a workspace absence.
      • DELDeletes a workspace absence.
    • Files & Images Overview
    • Custom Fields Overview
    • Workload & Planning Overview
    • Project Templates Overview
    • Workflows Overview
    • Login & Access Overview
    • API Management Overview
LogoLogo
SupportDeveloper ForumLogin
API v1 ReferenceWorkspace Absences

Creates a new workspace absence.

POST
https://api.awork.com/api/v1/workspaceabsences
POST
/api/v1/workspaceabsences
$curl -X POST https://api.awork.com/api/v1/workspaceabsences \
> -H "Authorization: Bearer <token>" \
> -H "Content-Type: application/json" \
> -d '{
> "startOn": "2022-03-01T00:00:00Z",
> "endOn": "2022-03-03T00:00:00Z",
> "description": "Company offsite"
>}'
1{
2 "id": "123e4567-e89b-12d3-a456-426614174000",
3 "createdOn": "2022-03-11T15:33:47.100Z",
4 "createdBy": "123e4567-e89b-12d3-a456-426614174000",
5 "updatedOn": "2022-03-11T21:15:00.100Z",
6 "updatedBy": "123e4567-e89b-12d3-a456-426614174000",
7 "startOn": "2022-03-01T00:00:00Z",
8 "endOn": "2022-03-03T00:00:00Z",
9 "description": "Company offsite",
10 "regionId": "123e4567-e89b-12d3-a456-426614174000",
11 "region": "Hamburg",
12 "isReadOnly": true,
13 "isHalfDayOnStart": false,
14 "isHalfDayOnEnd": false
15}
Creates a new workspace absence. A workspace absence is a kind of absence that is applied to all users in a workspace. It can be used to define special holidays (e.g: company offsite) that apply to all users in a workspace. It can be limited to a specific absence region, in which case only users in that region will be affected. <Note title="Subscription Level" icon="layer-group">This endpoint requires the `Standard` plan or higher.</Note> <Check title="Required Permissions" icon="key">The user must be an admin or have `user-planning-data:write` permissions.</Check>
Was this page helpful?
Previous

Updates a workspace absence.

Next
Built with

Creates a new workspace absence. A workspace absence is a kind of absence that is applied to all users in a workspace. It can be used to define special holidays (e.g: company offsite) that apply to all users in a workspace. It can be limited to a specific absence region, in which case only users in that region will be affected.

Subscription Level
This endpoint requires the Standard plan or higher.
Required Permissions
The user must be an admin or have user-planning-data:write permissions.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Request

Workspace absence details including start date, end date, description, and optional region.
startOnstringRequiredformat: "date-time"
The start time of the workspace absence.
endOnstringRequiredformat: "date-time"
The end time of the workspace absence.
descriptionstringRequired0-1000 characters
The description of the workspace absence.
regionIdstring or nullOptionalformat: "uuid"

(optional) The id of the absence region to limit the workspace absence to. If not set, the workspace absence will apply to all users in the workspace. Otherwise, it will only apply to users in the specified absence region.

isHalfDayOnStartbooleanOptional
If it's true, and it's a single day absence means that the absence is for the first half of the workday. If it's a multi day absence, it will start on the second half of the first day of the absence period.
isHalfDayOnEndbooleanOptional
If it's true, and it's a single day absence means that the absence is for the second half of the workday. If it's a multi day absence it will end on the first half of the last day of the absence period.

Response

OK
idstringformat: "uuid"
The id of the entity.
createdOnstringformat: "date-time"
The date this entity was created.
createdBystringformat: "uuid"
The id of the user who created this entity.
updatedOnstringformat: "date-time"
The date this entity was last modified.
updatedBystringformat: "uuid"
The id of the user who last modified this entity.
startOnstringformat: "date-time"
The start time of the workspace absence.
endOnstringformat: "date-time"
The end time of the workspace absence.
descriptionstring or null
The description of the absence.
regionIdstring or nullformat: "uuid"

The (optional) regionId of the workspace absence. If null, the absence is global for the entire workspace. Otherwise, it will be applied only to the users of the region.

regionstring or null
The name of the region of the workspace absence. Null if the absence is global for the entire workspace.
isReadOnlybooleanRead-only

If it’s true it means that this Absence is read-only and cannot be edited/deleted by the user.

isHalfDayOnStartbooleanRead-only
If it's true and it's a single day absence means that the absence is for the first half of the workday. If it's a multi day absence it started on the second half of the first day of the absence period.
isHalfDayOnEndbooleanRead-only
If it's true and it's a single day absence means that the absence is for the second half of the workday. If it's a multi day absence it ended on the first half of the last day of the absence period.

Errors

400
Bad Request Error