K8 HQ

Calendar — K8 HQ Content API

Calendar operations for K8 HQ Content API. Requests, permissions and responses.

Version 1OpenAPI description (JSON)

Browse operation groups

Before making requests, read the authentication and request requirements.

Open your K8 HQ calendar. List, add, change or delete events, or download a copy.

Base URL

Base URLFor
https://api.k8hq.com/v1API tokens and the K8 HQ web app

Endpoints

Calendar

List events in a date range

GET/calendars/{calendar}/entries

For API tokens with calendar:read and the web app.

Parameters

NameTypeDescription
calendar (path) requiredstringCalendar ID.
start (query) requiredstringStart of the range, inclusive.
end (query) requiredstringEnd of the range, exclusive. Up to 62 days after the start.

Response body (JSON)

FieldTypeDescription
entries requiredCalendarEntry[]
tzdataVersion requiredstringVersion of the time zone data the server uses.

Responses

StatusBodyMeaning
200JSONTimed events that overlap the range.
400application/problem+jsonThe request is malformed (invalid).
401application/problem+jsonNo token, or it expired: sign in again (unauthenticated).
403application/problem+jsonThe token lacks the scope (scope_missing), the container is zero-access (zero_access), or the caller may not use this operation (forbidden).
404application/problem+jsonNot found, or not yours (not_found).
409application/problem+jsonThe calendar could not be opened or changed. Refresh and try again.
503application/problem+jsonTemporary failure; try again (unavailable).

Add a timed event

POST/calendars/{calendar}/entries

For API tokens with calendar:write and the web app.

Parameters

NameTypeDescription
calendar (path) requiredstringCalendar ID.

Request body (JSON)

FieldTypeDescription
end requiredstringAfter the start and within 31 days of it.
start requiredstring
title requiredstring
zone requiredstringIANA time zone name such as America/New_York, or UTC.
descriptionstringPlain text, up to 32 KB.
locationstring

Response body (JSON)

FieldTypeDescription
end requiredstringAfter the start and within 31 days of it.
etag requiredstring
id requiredstring
start requiredstring
title requiredstring
tzdataVersion requiredstringVersion of the time zone data the server uses.
version requiredinteger
zone requiredstringIANA time zone name such as America/New_York, or UTC.
descriptionstringPlain text, up to 32 KB.
locationstring

Responses

StatusBodyMeaning
201CalendarEntryResultThe new event.
400application/problem+jsonThe request is malformed (invalid).
401application/problem+jsonNo token, or it expired: sign in again (unauthenticated).
402application/problem+jsonThe organization is read-only because it is out of credit.
403application/problem+jsonThe token lacks the scope (scope_missing), the container is zero-access (zero_access), or the caller may not use this operation (forbidden).
404application/problem+jsonNot found, or not yours (not_found).
409application/problem+jsonThe calendar could not be opened or changed. Refresh and try again.
503application/problem+jsonTemporary failure; try again (unavailable).

Edit a timed event

PATCH/calendars/{calendar}/entries/{entry}

Supply the new title, start, end and time zone. Omit the description or location to clear it.

For API tokens with calendar:write and the web app.

Parameters

NameTypeDescription
calendar (path) requiredstringCalendar ID.
entry (path) requiredstringCalendar entry ID.
If-Match (header) requiredstringThe event's ETag from the list or write response.

Request body (JSON)

FieldTypeDescription
end requiredstringAfter the start and within 31 days of it.
start requiredstring
title requiredstring
zone requiredstringIANA time zone name such as America/New_York, or UTC.
descriptionstringPlain text, up to 32 KB.
locationstring

Response body (JSON)

FieldTypeDescription
end requiredstringAfter the start and within 31 days of it.
etag requiredstring
id requiredstring
start requiredstring
title requiredstring
tzdataVersion requiredstringVersion of the time zone data the server uses.
version requiredinteger
zone requiredstringIANA time zone name such as America/New_York, or UTC.
descriptionstringPlain text, up to 32 KB.
locationstring

Responses

StatusBodyMeaning
200CalendarEntryResultThe updated event.
400application/problem+jsonThe request is malformed (invalid).
401application/problem+jsonNo token, or it expired: sign in again (unauthenticated).
402application/problem+jsonThe organization is read-only because it is out of credit.
403application/problem+jsonThe token lacks the scope (scope_missing), the container is zero-access (zero_access), or the caller may not use this operation (forbidden).
404application/problem+jsonNot found, or not yours (not_found).
409application/problem+jsonThe calendar could not be opened or changed. Refresh and try again.
412application/problem+jsonThe entry version has changed.
428application/problem+jsonSupply the entry version in If-Match.
503application/problem+jsonTemporary failure; try again (unavailable).

Delete an event

DELETE/calendars/{calendar}/entries/{entry}

For API tokens with calendar:write and the web app.

Parameters

NameTypeDescription
calendar (path) requiredstringCalendar ID.
entry (path) requiredstringCalendar entry ID.
If-Match (header) requiredstringThe event's ETag from the list or write response.

Responses

StatusBodyMeaning
204Event deleted.
400application/problem+jsonThe request is malformed (invalid).
401application/problem+jsonNo token, or it expired: sign in again (unauthenticated).
402application/problem+jsonThe organization is read-only because it is out of credit.
403application/problem+jsonThe token lacks the scope (scope_missing), the container is zero-access (zero_access), or the caller may not use this operation (forbidden).
404application/problem+jsonNot found, or not yours (not_found).
409application/problem+jsonThe calendar could not be opened or changed. Refresh and try again.
412application/problem+jsonThe entry version has changed.
428application/problem+jsonSupply the entry version in If-Match.
503application/problem+jsonTemporary failure; try again (unavailable).

Download a calendar

GET/calendars/{calendar}/export

You can download your calendar even when your organization is read-only because it is out of credit.

For API tokens with calendar:read and the web app.

Parameters

NameTypeDescription
calendar (path) requiredstringCalendar ID.

Responses

StatusBodyMeaning
200text/calendarAn iCalendar file with your current events.
400application/problem+jsonThe request is malformed (invalid).
401application/problem+jsonNo token, or it expired: sign in again (unauthenticated).
403application/problem+jsonThe token lacks the scope (scope_missing), the container is zero-access (zero_access), or the caller may not use this operation (forbidden).
404application/problem+jsonNot found, or not yours (not_found).
409application/problem+jsonThe calendar could not be opened or changed. Refresh and try again.
503application/problem+jsonTemporary failure; try again (unavailable).

Open your calendar

POST/organizations/{org}/calendar

Creates your calendar the first time you open it. You can open an existing calendar even when the organization is read-only.

For the web app.

Parameters

NameTypeDescription
org (path) requiredstringOrganization ID.

Response body (JSON)

FieldTypeDescription
id requiredstring
name requiredstring
orgId requiredstring
privacy required"readable"
tzdataVersion requiredstringVersion of the time zone data the server uses.
zone requiredstringIANA time zone name such as America/New_York, or UTC.

Responses

StatusBodyMeaning
200CalendarYour calendar.
400application/problem+jsonThe request is malformed (invalid).
401application/problem+jsonNo token, or it expired: sign in again (unauthenticated).
402application/problem+jsonThe organization is read-only because it is out of credit.
403application/problem+jsonThe token lacks the scope (scope_missing), the container is zero-access (zero_access), or the caller may not use this operation (forbidden).
404application/problem+jsonNot found, or not yours (not_found).
409application/problem+jsonThe calendar could not be opened or changed. Refresh and try again.
410application/problem+jsonThe organization is being deleted.
503application/problem+jsonTemporary failure; try again (unavailable).