# Calendars

Operations related to calendars

## Get calendars

> Retrieve a paginated list of calendars with optional filtering

```json
{"openapi":"3.0.0","info":{"title":"Salescaling API","version":"1.0"},"tags":[{"name":"Calendars","description":"Operations related to calendars"}],"servers":[{"url":"https://api.salescaling.com","description":"Base API URL"}],"security":[{},{"bearer":[]}],"paths":{"/api/v1/calendars":{"get":{"operationId":"PublicApiCalendarController_getCalendars","summary":"Get calendars","description":"Retrieve a paginated list of calendars with optional filtering","parameters":[{"name":"name","required":false,"in":"query","description":"Filter calendars by name (partial match)","schema":{"type":"string"}},{"name":"isPrimary","required":false,"in":"query","description":"Filter calendars by primary status","schema":{"type":"boolean"}},{"name":"readOnly","required":false,"in":"query","description":"Filter calendars by read-only status","schema":{"type":"boolean"}},{"name":"page","required":false,"in":"query","description":"Page number for pagination","schema":{"type":"string"}},{"name":"limit","required":false,"in":"query","description":"Number of items per page","schema":{"type":"string"}}],"responses":{"200":{"description":"Calendars retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicApiGetCalendarsResponseDto"}}}},"401":{"description":"Unauthorized - missing or invalid API key or Bearer token"}},"tags":["Calendars"]}}},"components":{"schemas":{"PublicApiGetCalendarsResponseDto":{"type":"object","properties":{"statusCode":{"type":"number","default":200},"count":{"type":"number"},"error":{"type":"string","nullable":true},"data":{"type":"array","items":{"$ref":"#/components/schemas/PublicApiCalendarDto"}}},"required":["statusCode","count","error","data"]},"PublicApiCalendarDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier for the calendar"},"name":{"type":"string","description":"Name of the calendar"},"description":{"type":"string","description":"Description of the calendar"},"hexColor":{"type":"string","description":"Hex color code for the calendar"},"hexForegroundColor":{"type":"string","description":"Hex foreground color code for the calendar"},"isPrimary":{"type":"boolean","description":"Whether this is the primary calendar"},"location":{"type":"string","description":"Location associated with the calendar"},"timezone":{"type":"string","description":"IANA time zone database formatted string"},"readOnly":{"type":"boolean","description":"Whether the calendar is read-only"},"metadata":{"type":"object","description":"Additional metadata for the calendar"},"createdAt":{"format":"date-time","type":"string","description":"Date and time when the calendar was created"},"updatedAt":{"format":"date-time","type":"string","description":"Date and time when the calendar was last updated"}},"required":["id","name","createdAt","updatedAt"]}}}}
```

## Create calendar

> Create a new calendar

```json
{"openapi":"3.0.0","info":{"title":"Salescaling API","version":"1.0"},"tags":[{"name":"Calendars","description":"Operations related to calendars"}],"servers":[{"url":"https://api.salescaling.com","description":"Base API URL"}],"security":[{},{"bearer":[]}],"paths":{"/api/v1/calendars":{"post":{"operationId":"PublicApiCalendarController_createCalendar","summary":"Create calendar","description":"Create a new calendar","parameters":[],"requestBody":{"required":true,"description":"Calendar data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicApiCreateCalendarDto"}}}},"responses":{"201":{"description":"Calendar created successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicApiCreateCalendarResponseDto"}}}},"401":{"description":"Unauthorized - missing or invalid API key or Bearer token"}},"tags":["Calendars"]}}},"components":{"schemas":{"PublicApiCreateCalendarDto":{"type":"object","properties":{"name":{"type":"string","description":"Name of the calendar"},"description":{"type":"string","description":"Description of the calendar"},"hexColor":{"type":"string","description":"Hex color code for the calendar"},"hexForegroundColor":{"type":"string","description":"Hex foreground color code for the calendar"},"isPrimary":{"type":"boolean","description":"Whether this is the primary calendar"},"location":{"type":"string","description":"Location associated with the calendar"},"timezone":{"type":"string","description":"IANA time zone database formatted string"},"readOnly":{"type":"boolean","description":"Whether the calendar is read-only"},"metadata":{"type":"object","description":"Additional metadata for the calendar"}},"required":["name"]},"PublicApiCreateCalendarResponseDto":{"type":"object","properties":{"statusCode":{"type":"number","default":200},"count":{"type":"number"},"error":{"type":"string","nullable":true},"data":{"$ref":"#/components/schemas/PublicApiCalendarDto"}},"required":["statusCode","count","error","data"]},"PublicApiCalendarDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier for the calendar"},"name":{"type":"string","description":"Name of the calendar"},"description":{"type":"string","description":"Description of the calendar"},"hexColor":{"type":"string","description":"Hex color code for the calendar"},"hexForegroundColor":{"type":"string","description":"Hex foreground color code for the calendar"},"isPrimary":{"type":"boolean","description":"Whether this is the primary calendar"},"location":{"type":"string","description":"Location associated with the calendar"},"timezone":{"type":"string","description":"IANA time zone database formatted string"},"readOnly":{"type":"boolean","description":"Whether the calendar is read-only"},"metadata":{"type":"object","description":"Additional metadata for the calendar"},"createdAt":{"format":"date-time","type":"string","description":"Date and time when the calendar was created"},"updatedAt":{"format":"date-time","type":"string","description":"Date and time when the calendar was last updated"}},"required":["id","name","createdAt","updatedAt"]}}}}
```

## Get calendar by ID

> Retrieve a specific calendar by its ID

```json
{"openapi":"3.0.0","info":{"title":"Salescaling API","version":"1.0"},"tags":[{"name":"Calendars","description":"Operations related to calendars"}],"servers":[{"url":"https://api.salescaling.com","description":"Base API URL"}],"security":[{},{"bearer":[]}],"paths":{"/api/v1/calendars/{id}":{"get":{"operationId":"PublicApiCalendarController_getCalendarById","summary":"Get calendar by ID","description":"Retrieve a specific calendar by its ID","parameters":[{"name":"id","required":true,"in":"path","description":"Calendar ID","schema":{"type":"string"}}],"responses":{"200":{"description":"Calendar retrieved successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicApiGetCalendarByIdResponseDto"}}}},"401":{"description":"Unauthorized - missing or invalid API key or Bearer token"}},"tags":["Calendars"]}}},"components":{"schemas":{"PublicApiGetCalendarByIdResponseDto":{"type":"object","properties":{"statusCode":{"type":"number","default":200},"count":{"type":"number"},"error":{"type":"string","nullable":true},"data":{"$ref":"#/components/schemas/PublicApiCalendarDto"}},"required":["statusCode","count","error","data"]},"PublicApiCalendarDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier for the calendar"},"name":{"type":"string","description":"Name of the calendar"},"description":{"type":"string","description":"Description of the calendar"},"hexColor":{"type":"string","description":"Hex color code for the calendar"},"hexForegroundColor":{"type":"string","description":"Hex foreground color code for the calendar"},"isPrimary":{"type":"boolean","description":"Whether this is the primary calendar"},"location":{"type":"string","description":"Location associated with the calendar"},"timezone":{"type":"string","description":"IANA time zone database formatted string"},"readOnly":{"type":"boolean","description":"Whether the calendar is read-only"},"metadata":{"type":"object","description":"Additional metadata for the calendar"},"createdAt":{"format":"date-time","type":"string","description":"Date and time when the calendar was created"},"updatedAt":{"format":"date-time","type":"string","description":"Date and time when the calendar was last updated"}},"required":["id","name","createdAt","updatedAt"]}}}}
```

## Update calendar

> Update an existing calendar

```json
{"openapi":"3.0.0","info":{"title":"Salescaling API","version":"1.0"},"tags":[{"name":"Calendars","description":"Operations related to calendars"}],"servers":[{"url":"https://api.salescaling.com","description":"Base API URL"}],"security":[{},{"bearer":[]}],"paths":{"/api/v1/calendars/{id}":{"put":{"operationId":"PublicApiCalendarController_updateCalendar","summary":"Update calendar","description":"Update an existing calendar","parameters":[{"name":"id","required":true,"in":"path","description":"Calendar ID","schema":{"type":"string"}}],"requestBody":{"required":true,"description":"Updated calendar data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicApiUpdateCalendarDto"}}}},"responses":{"200":{"description":"Calendar updated successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicApiUpdateCalendarResponseDto"}}}},"401":{"description":"Unauthorized - missing or invalid API key or Bearer token"}},"tags":["Calendars"]}}},"components":{"schemas":{"PublicApiUpdateCalendarDto":{"type":"object","properties":{"name":{"type":"string","description":"Name of the calendar"},"description":{"type":"string","description":"Description of the calendar"},"hexColor":{"type":"string","description":"Hex color code for the calendar"},"hexForegroundColor":{"type":"string","description":"Hex foreground color code for the calendar"},"isPrimary":{"type":"boolean","description":"Whether this is the primary calendar"},"location":{"type":"string","description":"Location associated with the calendar"},"timezone":{"type":"string","description":"IANA time zone database formatted string"},"readOnly":{"type":"boolean","description":"Whether the calendar is read-only"},"metadata":{"type":"object","description":"Additional metadata for the calendar"}}},"PublicApiUpdateCalendarResponseDto":{"type":"object","properties":{"statusCode":{"type":"number","default":200},"count":{"type":"number"},"error":{"type":"string","nullable":true},"data":{"$ref":"#/components/schemas/PublicApiCalendarDto"}},"required":["statusCode","count","error","data"]},"PublicApiCalendarDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier for the calendar"},"name":{"type":"string","description":"Name of the calendar"},"description":{"type":"string","description":"Description of the calendar"},"hexColor":{"type":"string","description":"Hex color code for the calendar"},"hexForegroundColor":{"type":"string","description":"Hex foreground color code for the calendar"},"isPrimary":{"type":"boolean","description":"Whether this is the primary calendar"},"location":{"type":"string","description":"Location associated with the calendar"},"timezone":{"type":"string","description":"IANA time zone database formatted string"},"readOnly":{"type":"boolean","description":"Whether the calendar is read-only"},"metadata":{"type":"object","description":"Additional metadata for the calendar"},"createdAt":{"format":"date-time","type":"string","description":"Date and time when the calendar was created"},"updatedAt":{"format":"date-time","type":"string","description":"Date and time when the calendar was last updated"}},"required":["id","name","createdAt","updatedAt"]}}}}
```

## Delete calendar

> Delete a calendar by its ID

```json
{"openapi":"3.0.0","info":{"title":"Salescaling API","version":"1.0"},"tags":[{"name":"Calendars","description":"Operations related to calendars"}],"servers":[{"url":"https://api.salescaling.com","description":"Base API URL"}],"security":[{},{"bearer":[]}],"paths":{"/api/v1/calendars/{id}":{"delete":{"operationId":"PublicApiCalendarController_deleteCalendar","summary":"Delete calendar","description":"Delete a calendar by its ID","parameters":[{"name":"id","required":true,"in":"path","description":"Calendar ID","schema":{"type":"string"}}],"responses":{"200":{"description":"Calendar deleted successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicApiDeleteCalendarResponseDto"}}}},"401":{"description":"Unauthorized - missing or invalid API key or Bearer token"}},"tags":["Calendars"]}}},"components":{"schemas":{"PublicApiDeleteCalendarResponseDto":{"type":"object","properties":{"statusCode":{"type":"number","default":200},"count":{"type":"number"},"error":{"type":"string","nullable":true},"data":{"type":"boolean"}},"required":["statusCode","count","error","data"]}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.salescaling.com/api/calendars.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
