API Docs
HomeDocsWebsite
  • Home
  • Introduction
    • Authorization
      • Authorize
      • Get a Token
      • Third-Party Login
    • Field Types and Validation
      • Field Types
      • Validation
    • Query Manipulation
      • Constraints
      • Result Control
      • Value Filters
    • Entity Permissions
      • Restricted Scope
  • API reference
    • Infoboard
      • InfoboardChannels
      • InfoboardPosts
      • InfoboardPostSeenUsers
      • InfoboardPostReadUsers
      • InfoboardComments
      • InfoboardDepartmentSettings
    • Manual
      • ManualChapters
      • ManualEntries
      • ManualEntrySeenUsers
    • Calendar
      • Calendars
      • CalendarEvents
    • Filemanager
      • FilemanagerDirectories
      • FilemanagerFiles
    • Files
    • Forms
      • Forms
      • FormFields
      • FormFieldTypes
      • FormFieldValidations
      • FormFieldValidationTypes
      • FormMessages
      • FormMessageFields
    • Layouts
      • Layouts
      • LayoutRows
      • LayoutColumns
      • LayoutColumnLayoutElements
    • Tasks 2.0
      • TaskTemplates
      • TaskFields
      • TaskAssignments
      • TaskExecutions
      • TaskProgressFields
    • Departments
    • Roles
    • Permissions
    • Users
    • EntityPermissions
    • Notifications
    • Reactions
    • Icons
    • Folders
    • SharedItems
    • UrlContext
  • Resources
    • Release Notes
      • v2.106.0
      • v2.102.0
Powered by GitBook
On this page
  • Model Definition
  • Relations
  • Traits
  • List
  • Show
  • Create
  • Update
  • Delete
  1. API reference
  2. Calendar

Calendars

PreviousCalendarNextCalendarEvents

Last updated 10 months ago

You can create any number of to categorize . Each can be assigned a different color to differentiate the in different .

Model Definition

Relations

Key
Relation
Type
Relation Field(s)

events

Has many

calendarEvent.calendar_id

Traits

  • Sortable

All kinds of are not vailable for Calendars.

List

Get a list of all Calendars.

Definition

GET /api/calendars

Example Request

$client = new GuzzleHttp\Client(['base_uri' => 'https://{tenant}.intratool.de']);
$response = $client->request('GET', '/api/calendars', [
    'headers' => ['Authorization' => "Bearer {accessToken}"]
]);

Example Response Body

[
  {
    "id": 1,
    "name": "Allgemein",
    "color": "#2196f3",
    "sort_number": 1,
    "created_at": "2024-06-01 12:00:00",
    "updated_at": "2024-06-01 12:00:00"
  },
  {
    "id": 2,
    "name": "Urlaubskalender",
    "color": "#8bc34a",
    "sort_number": 2,
    "created_at": "2024-06-01 13:00:00",
    "updated_at": "2024-06-01 13:00:00"
  }
]

Show

Show a single Calendar by id.

Definition

GET /api/calendars/{id}

Example Request

$client = new GuzzleHttp\Client(['base_uri' => 'https://{tenant}.intratool.de']);
$response = $client->request('GET', '/api/calendars/1', [
    'headers' => ['Authorization' => "Bearer {accessToken}"]
]);

Example Response

{
  "id": 1,
  "name": "Allgemein",
  "color": "#2196f3",
  "sort_number": 1,
  "created_at": "2024-06-01 12:00:00",
  "updated_at": "2024-06-01 12:00:00"
}

Create

Create a new Calendar.

Definition

POST /api/calendars

Request Keys

Key
Type
Default
Description

name*

string

-

The name of the Calendar.

color*

string

-

The HEX color of the Calendar.

sort_number

integer

Current highest +1

The index of the Calendar.

Keys with * are required.

Example Request

$client = new GuzzleHttp\Client(['base_uri' => 'https://{tenant}.intratool.de']);
$response = $client->request('POST', '/api/calendars', [
    'headers' => ['Authorization' => "Bearer {accessToken}"],
    'json' => [
        'name' => 'Geburtstage',
        'color' => '#810d0b',
        'sort_number' => 3,
    ]
]);

Example Response Body

{
  "status": "success",
  "data": {
    "id": 3,
    "name": "Geburtstage",
    "color": "#810d0b",
    "sort_number": 3,
    "created_at": "2024-06-01 14:00:00",
    "updated_at": "2024-06-01 14:00:00"
  }
}

Update

Update an existing Calendar by id.

Definition

PUT /api/calendar-event/{id}

Request Keys

Key
Type
Default
Description

name

string

-

The name of the Calendar.

color

string

-

The HEX color of the Calendar.

sort_number

integer

Current highest +1

The index of the Calendar.

Example Request

$client = new GuzzleHttp\Client(['base_uri' => 'https://{tenant}.intratool.de']);
$response = $client->request('PUT', '/api/calendars/3', [
    'headers' => ['Authorization' => "Bearer {accessToken}"],
    'json' => [
        'color' => '#fcb12b',
    ]
]);

Example Response

{
  "status": "success",
  "data": {
    "id": 3,
    "name": "Geburtstage",
    "color": "#fcb12b",
    "sort_number": 3,
    "created_at": "2024-06-01 14:00:00",
    "updated_at": "2024-06-01 15:00:00"
  }
}

Delete

Delete an existing Calendar by id.

Definition

DELETE /api/calendars/{id}

Example Request

$client = new GuzzleHttp\Client(['base_uri' => 'https://{tenant}.intratool.de']);
$response = $client->request('DELETE', '/api/calendars/3', [
    'headers' => ['Authorization' => "Bearer {accessToken}"]
]);

Example Response

{
  "status": "success",
  "data": []
}

Calendars
Events
Calendar
Events
Calendars
Query Manipulation
CalendarEvents