@hostinger/mail-sdk 1.19.9 → 1.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/README.md +2 -2
  2. package/api.ts +2905 -760
  3. package/base.ts +1 -1
  4. package/common.ts +1 -1
  5. package/configuration.ts +2 -2
  6. package/dist/api.d.ts +2206 -720
  7. package/dist/api.js +1249 -6
  8. package/dist/base.d.ts +1 -1
  9. package/dist/base.js +1 -1
  10. package/dist/common.d.ts +1 -1
  11. package/dist/common.js +1 -1
  12. package/dist/configuration.d.ts +1 -1
  13. package/dist/configuration.js +2 -2
  14. package/dist/esm/api.d.ts +2206 -720
  15. package/dist/esm/api.js +1239 -5
  16. package/dist/esm/base.d.ts +1 -1
  17. package/dist/esm/base.js +1 -1
  18. package/dist/esm/common.d.ts +1 -1
  19. package/dist/esm/common.js +1 -1
  20. package/dist/esm/configuration.d.ts +1 -1
  21. package/dist/esm/configuration.js +2 -2
  22. package/dist/esm/index.d.ts +1 -1
  23. package/dist/esm/index.js +1 -1
  24. package/dist/index.d.ts +1 -1
  25. package/dist/index.js +1 -1
  26. package/docs/CalendarEventsApi.md +505 -0
  27. package/docs/CalendarsApi.md +317 -0
  28. package/docs/MessagesApi.md +3 -0
  29. package/docs/SendApi.md +2 -2
  30. package/docs/V1CalendarEventsAttendee.md +25 -0
  31. package/docs/V1CalendarEventsAttendeeInput.md +23 -0
  32. package/docs/V1CalendarEventsCollection.md +23 -0
  33. package/docs/V1CalendarEventsCollectionMeta.md +20 -0
  34. package/docs/V1CalendarEventsCreateRequest.md +43 -0
  35. package/docs/V1CalendarEventsEvent.md +61 -0
  36. package/docs/V1CalendarEventsEventListItem.md +43 -0
  37. package/docs/V1CalendarEventsOrganizer.md +23 -0
  38. package/docs/V1CalendarEventsRecurrenceDay.md +23 -0
  39. package/docs/V1CalendarEventsRecurrenceRule.md +35 -0
  40. package/docs/V1CalendarEventsReminder.md +23 -0
  41. package/docs/V1CalendarEventsReplyRequest.md +23 -0
  42. package/docs/V1CalendarEventsRescheduleRequest.md +33 -0
  43. package/docs/V1CalendarEventsResource.md +21 -0
  44. package/docs/V1CalendarEventsUpdateRequest.md +49 -0
  45. package/docs/V1CalendarsCalendar.md +31 -0
  46. package/docs/V1CalendarsCollection.md +23 -0
  47. package/docs/V1CalendarsCreateRequest.md +27 -0
  48. package/docs/V1CalendarsResource.md +21 -0
  49. package/docs/V1CalendarsUpdateRequest.md +27 -0
  50. package/index.ts +1 -1
  51. package/package.json +1 -1
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Hostinger Mail API
3
3
  *
4
- * API Version: 1.3.0
4
+ * API Version: 1.4.0
5
5
  *
6
6
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
7
7
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
package/dist/esm/base.js CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger Mail API
5
5
  *
6
- * API Version: 1.3.0
6
+ * API Version: 1.4.0
7
7
  *
8
8
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
9
9
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Hostinger Mail API
3
3
  *
4
- * API Version: 1.3.0
4
+ * API Version: 1.4.0
5
5
  *
6
6
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
7
7
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger Mail API
5
5
  *
6
- * API Version: 1.3.0
6
+ * API Version: 1.4.0
7
7
  *
8
8
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
9
9
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Hostinger Mail API
3
3
  *
4
- * API Version: 1.3.0
4
+ * API Version: 1.4.0
5
5
  *
6
6
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
7
7
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger Mail API
5
5
  *
6
- * API Version: 1.3.0
6
+ * API Version: 1.4.0
7
7
  *
8
8
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
9
9
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
@@ -13,7 +13,7 @@ export class Configuration {
13
13
  var _a;
14
14
  this.accessToken = param.accessToken;
15
15
  this.basePath = param.basePath;
16
- this.baseOptions = Object.assign(Object.assign({}, param.baseOptions), { headers: Object.assign({ 'User-Agent': "hostinger-mail-typescript-sdk/1.19.9" }, (_a = param.baseOptions) === null || _a === void 0 ? void 0 : _a.headers) });
16
+ this.baseOptions = Object.assign(Object.assign({}, param.baseOptions), { headers: Object.assign({ 'User-Agent': "hostinger-mail-typescript-sdk/1.20.0" }, (_a = param.baseOptions) === null || _a === void 0 ? void 0 : _a.headers) });
17
17
  this.formDataCtor = param.formDataCtor;
18
18
  }
19
19
  /**
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Hostinger Mail API
3
3
  *
4
- * API Version: 1.3.0
4
+ * API Version: 1.4.0
5
5
  *
6
6
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
7
7
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
package/dist/esm/index.js CHANGED
@@ -3,7 +3,7 @@
3
3
  /**
4
4
  * Hostinger Mail API
5
5
  *
6
- * API Version: 1.3.0
6
+ * API Version: 1.4.0
7
7
  *
8
8
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
9
9
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Hostinger Mail API
3
3
  *
4
- * API Version: 1.3.0
4
+ * API Version: 1.4.0
5
5
  *
6
6
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
7
7
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
package/dist/index.js CHANGED
@@ -4,7 +4,7 @@
4
4
  /**
5
5
  * Hostinger Mail API
6
6
  *
7
- * API Version: 1.3.0
7
+ * API Version: 1.4.0
8
8
  *
9
9
  * NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
10
10
  * If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
@@ -0,0 +1,505 @@
1
+ # CalendarEventsApi
2
+
3
+ All URIs are relative to *https://api.mail.hostinger.com*
4
+
5
+ |Method | HTTP request | Description|
6
+ |------------- | ------------- | -------------|
7
+ |[**createCalendarEvent**](#createcalendarevent) | **POST** /api/v1/mailboxes/{mailboxResourceId}/calendars/{calendarUuid}/events | Create calendar event|
8
+ |[**deleteCalendarEvent**](#deletecalendarevent) | **DELETE** /api/v1/mailboxes/{mailboxResourceId}/calendars/{calendarUuid}/events/{eventUuid} | Delete calendar event|
9
+ |[**getCalendarEvent**](#getcalendarevent) | **GET** /api/v1/mailboxes/{mailboxResourceId}/calendars/{calendarUuid}/events/{eventUuid} | Get calendar event|
10
+ |[**listCalendarEvents**](#listcalendarevents) | **GET** /api/v1/mailboxes/{mailboxResourceId}/calendars/{calendarUuid}/events | List calendar events|
11
+ |[**replyToCalendarEvent**](#replytocalendarevent) | **POST** /api/v1/mailboxes/{mailboxResourceId}/calendars/{calendarUuid}/events/{eventUuid}/reply | Reply to calendar event|
12
+ |[**rescheduleCalendarEvent**](#reschedulecalendarevent) | **PUT** /api/v1/mailboxes/{mailboxResourceId}/calendars/{calendarUuid}/events/{eventUuid}/reschedule | Reschedule calendar event|
13
+ |[**updateCalendarEvent**](#updatecalendarevent) | **PUT** /api/v1/mailboxes/{mailboxResourceId}/calendars/{calendarUuid}/events/{eventUuid} | Update calendar event|
14
+
15
+ # **createCalendarEvent**
16
+ > V1CalendarEventsResource createCalendarEvent(v1CalendarEventsCreateRequest)
17
+
18
+ Create an event in one calendar of the mailbox. `calendarUuid` comes from `listCalendars`: use the calendar with `default` true unless another one is named. A calendar the mailbox can only read is rejected with `403` and code `ERR_EVENT_NOT_EDITABLE`. The mailbox becomes the organizer and every address in `attendees` immediately receives an email invitation, which cannot be recalled. Without attendees no email is sent. A timed event needs `allDay` false, `start`, `end` and `timeZone`. An all-day event needs `allDay` true and a `start` date; `end` is optional. Set `recurrenceRule` for a repeating event and `reminder` for an alarm. Returns the created event. Its `uuid` is the `eventUuid` for `getCalendarEvent`, `updateCalendarEvent`, `rescheduleCalendarEvent` and `deleteCalendarEvent`.
19
+
20
+ ### Example
21
+
22
+ ```typescript
23
+ import {
24
+ CalendarEventsApi,
25
+ Configuration,
26
+ V1CalendarEventsCreateRequest
27
+ } from '@hostinger/mail-sdk';
28
+
29
+ const configuration = new Configuration();
30
+ const apiInstance = new CalendarEventsApi(configuration);
31
+
32
+ let mailboxResourceId: string; //Resource ID of the managed mailbox the bearer token is authorized for. (default to undefined)
33
+ let calendarUuid: string; //Calendar identifier: the `uuid` of a calendar returned by `listCalendars`, or the `calendarUuid` of an event returned by `listCalendarEvents`. (default to undefined)
34
+ let v1CalendarEventsCreateRequest: V1CalendarEventsCreateRequest; //
35
+
36
+ const { status, data } = await apiInstance.createCalendarEvent(
37
+ mailboxResourceId,
38
+ calendarUuid,
39
+ v1CalendarEventsCreateRequest
40
+ );
41
+ ```
42
+
43
+ ### Parameters
44
+
45
+ |Name | Type | Description | Notes|
46
+ |------------- | ------------- | ------------- | -------------|
47
+ | **v1CalendarEventsCreateRequest** | **V1CalendarEventsCreateRequest**| | |
48
+ | **mailboxResourceId** | [**string**] | Resource ID of the managed mailbox the bearer token is authorized for. | defaults to undefined|
49
+ | **calendarUuid** | [**string**] | Calendar identifier: the `uuid` of a calendar returned by `listCalendars`, or the `calendarUuid` of an event returned by `listCalendarEvents`. | defaults to undefined|
50
+
51
+
52
+ ### Return type
53
+
54
+ **V1CalendarEventsResource**
55
+
56
+ ### Authorization
57
+
58
+ [BearerAuth](../README.md#BearerAuth)
59
+
60
+ ### HTTP request headers
61
+
62
+ - **Content-Type**: application/json
63
+ - **Accept**: application/json
64
+
65
+
66
+ ### HTTP response details
67
+ | Status code | Description | Response headers |
68
+ |-------------|-------------|------------------|
69
+ |**201** | Event created. | - |
70
+ |**401** | Missing or invalid credentials. | - |
71
+ |**403** | Token is not authorized to manage the requested mailbox. | - |
72
+ |**404** | Resource not found. | - |
73
+ |**422** | Request payload failed validation. `params` maps field name to an array of error messages. | - |
74
+ |**500** | Server-side failure. | - |
75
+ |**502** | Upstream service is unavailable or returned an unexpected response. | - |
76
+
77
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
78
+
79
+ # **deleteCalendarEvent**
80
+ > deleteCalendarEvent()
81
+
82
+ Delete an event, one occurrence of a recurring event, or a recurring event from one occurrence on. This cannot be undone. `calendarUuid` and `eventUuid` come from `listCalendarEvents`. For a one-off event omit `scope` and `recurrenceId`. For a recurring event, `scope` `this` removes only the occurrence at `recurrenceId`, `future` removes it and every later one, `all` (the default) deletes the whole series. An event with `editable` true can be deleted with any scope, and its attendees receive a cancellation or the updated series by email. An invitation from someone else on the own calendar of the mailbox can be deleted with `all` or `this`: the organizer receives a decline for the removed occurrences. Any other event is rejected with `403` and code `ERR_EVENT_NOT_EDITABLE`. `notifyAttendees` false deletes without sending any email.
83
+
84
+ ### Example
85
+
86
+ ```typescript
87
+ import {
88
+ CalendarEventsApi,
89
+ Configuration
90
+ } from '@hostinger/mail-sdk';
91
+
92
+ const configuration = new Configuration();
93
+ const apiInstance = new CalendarEventsApi(configuration);
94
+
95
+ let mailboxResourceId: string; //Resource ID of the managed mailbox the bearer token is authorized for. (default to undefined)
96
+ let calendarUuid: string; //Calendar identifier: the `uuid` of a calendar returned by `listCalendars`, or the `calendarUuid` of an event returned by `listCalendarEvents`. (default to undefined)
97
+ let eventUuid: string; //Event identifier: the `uuid` of an event returned by `listCalendarEvents`. Every occurrence of a recurring event has the same uuid; `recurrenceId` picks one occurrence. (default to undefined)
98
+ let scope: 'this' | 'future' | 'all'; //For a recurring event: `this` removes the occurrence at `recurrenceId`, `future` removes it and every later one, `all` deletes the whole series. Omitted means `all`. Required when `recurrenceId` is sent. (optional) (default to undefined)
99
+ let recurrenceId: string; //`recurrenceId` of one occurrence, copied unchanged from a `listCalendarEvents` item. Required when `scope` is `this` or `future`. A value that matches no occurrence, or any value on a one-off event, returns `404`. (optional) (default to undefined)
100
+ let notifyAttendees: 'true' | 'false' | '1' | '0'; //`false` deletes without emailing attendees a cancellation or update, or the organizer a decline. Omitted means `true`. (optional) (default to 'true')
101
+ let ifMatch: string; //Optional `etag` from `getCalendarEvent`. When the event changed since that call, nothing is deleted and the request fails with `412`: fetch the event again and retry. Omit it to apply the request to the current version. (optional) (default to undefined)
102
+
103
+ const { status, data } = await apiInstance.deleteCalendarEvent(
104
+ mailboxResourceId,
105
+ calendarUuid,
106
+ eventUuid,
107
+ scope,
108
+ recurrenceId,
109
+ notifyAttendees,
110
+ ifMatch
111
+ );
112
+ ```
113
+
114
+ ### Parameters
115
+
116
+ |Name | Type | Description | Notes|
117
+ |------------- | ------------- | ------------- | -------------|
118
+ | **mailboxResourceId** | [**string**] | Resource ID of the managed mailbox the bearer token is authorized for. | defaults to undefined|
119
+ | **calendarUuid** | [**string**] | Calendar identifier: the `uuid` of a calendar returned by `listCalendars`, or the `calendarUuid` of an event returned by `listCalendarEvents`. | defaults to undefined|
120
+ | **eventUuid** | [**string**] | Event identifier: the `uuid` of an event returned by `listCalendarEvents`. Every occurrence of a recurring event has the same uuid; `recurrenceId` picks one occurrence. | defaults to undefined|
121
+ | **scope** | [**&#39;this&#39; | &#39;future&#39; | &#39;all&#39;**]**Array<&#39;this&#39; &#124; &#39;future&#39; &#124; &#39;all&#39;>** | For a recurring event: &#x60;this&#x60; removes the occurrence at &#x60;recurrenceId&#x60;, &#x60;future&#x60; removes it and every later one, &#x60;all&#x60; deletes the whole series. Omitted means &#x60;all&#x60;. Required when &#x60;recurrenceId&#x60; is sent. | (optional) defaults to undefined|
122
+ | **recurrenceId** | [**string**] | &#x60;recurrenceId&#x60; of one occurrence, copied unchanged from a &#x60;listCalendarEvents&#x60; item. Required when &#x60;scope&#x60; is &#x60;this&#x60; or &#x60;future&#x60;. A value that matches no occurrence, or any value on a one-off event, returns &#x60;404&#x60;. | (optional) defaults to undefined|
123
+ | **notifyAttendees** | [**&#39;true&#39; | &#39;false&#39; | &#39;1&#39; | &#39;0&#39;**]**Array<&#39;true&#39; &#124; &#39;false&#39; &#124; &#39;1&#39; &#124; &#39;0&#39;>** | &#x60;false&#x60; deletes without emailing attendees a cancellation or update, or the organizer a decline. Omitted means &#x60;true&#x60;. | (optional) defaults to 'true'|
124
+ | **ifMatch** | [**string**] | Optional &#x60;etag&#x60; from &#x60;getCalendarEvent&#x60;. When the event changed since that call, nothing is deleted and the request fails with &#x60;412&#x60;: fetch the event again and retry. Omit it to apply the request to the current version. | (optional) defaults to undefined|
125
+
126
+
127
+ ### Return type
128
+
129
+ void (empty response body)
130
+
131
+ ### Authorization
132
+
133
+ [BearerAuth](../README.md#BearerAuth)
134
+
135
+ ### HTTP request headers
136
+
137
+ - **Content-Type**: Not defined
138
+ - **Accept**: application/json
139
+
140
+
141
+ ### HTTP response details
142
+ | Status code | Description | Response headers |
143
+ |-------------|-------------|------------------|
144
+ |**204** | Event deleted. | - |
145
+ |**401** | Missing or invalid credentials. | - |
146
+ |**403** | Token is not authorized to manage the requested mailbox. | - |
147
+ |**404** | Resource not found. | - |
148
+ |**412** | The resource changed since the etag sent in &#x60;If-Match&#x60; was read. Nothing was changed: fetch the resource again and retry. | - |
149
+ |**422** | Request payload failed validation. &#x60;params&#x60; maps field name to an array of error messages. | - |
150
+ |**500** | Server-side failure. | - |
151
+ |**502** | Upstream service is unavailable or returned an unexpected response. | - |
152
+
153
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
154
+
155
+ # **getCalendarEvent**
156
+ > V1CalendarEventsResource getCalendarEvent()
157
+
158
+ Retrieve the full details of one event: title, times, description, location, meeting link, recurrence rule, reminder, organizer, attendees with their answers, and its `etag`. `calendarUuid` and `eventUuid` come from `listCalendarEvents` (the `calendarUuid` and `uuid` of an item). For one occurrence of a recurring event pass the `recurrenceId` of the item; without it the whole series is returned and `recurrenceId` is null. A `recurrenceId` that matches no occurrence returns `404`. Call it before `updateCalendarEvent`, which replaces every field, so the values that should stay can be sent back. `replyable` true means the mailbox was invited by someone else and can answer with `replyToCalendarEvent`. `editable` true means the event can be changed or moved.
159
+
160
+ ### Example
161
+
162
+ ```typescript
163
+ import {
164
+ CalendarEventsApi,
165
+ Configuration
166
+ } from '@hostinger/mail-sdk';
167
+
168
+ const configuration = new Configuration();
169
+ const apiInstance = new CalendarEventsApi(configuration);
170
+
171
+ let mailboxResourceId: string; //Resource ID of the managed mailbox the bearer token is authorized for. (default to undefined)
172
+ let calendarUuid: string; //Calendar identifier: the `uuid` of a calendar returned by `listCalendars`, or the `calendarUuid` of an event returned by `listCalendarEvents`. (default to undefined)
173
+ let eventUuid: string; //Event identifier: the `uuid` of an event returned by `listCalendarEvents`. Every occurrence of a recurring event has the same uuid; `recurrenceId` picks one occurrence. (default to undefined)
174
+ let recurrenceId: string; //`recurrenceId` of one occurrence, copied unchanged from a `listCalendarEvents` item. Omit it for a one-off event or for the whole series. (optional) (default to undefined)
175
+
176
+ const { status, data } = await apiInstance.getCalendarEvent(
177
+ mailboxResourceId,
178
+ calendarUuid,
179
+ eventUuid,
180
+ recurrenceId
181
+ );
182
+ ```
183
+
184
+ ### Parameters
185
+
186
+ |Name | Type | Description | Notes|
187
+ |------------- | ------------- | ------------- | -------------|
188
+ | **mailboxResourceId** | [**string**] | Resource ID of the managed mailbox the bearer token is authorized for. | defaults to undefined|
189
+ | **calendarUuid** | [**string**] | Calendar identifier: the &#x60;uuid&#x60; of a calendar returned by &#x60;listCalendars&#x60;, or the &#x60;calendarUuid&#x60; of an event returned by &#x60;listCalendarEvents&#x60;. | defaults to undefined|
190
+ | **eventUuid** | [**string**] | Event identifier: the &#x60;uuid&#x60; of an event returned by &#x60;listCalendarEvents&#x60;. Every occurrence of a recurring event has the same uuid; &#x60;recurrenceId&#x60; picks one occurrence. | defaults to undefined|
191
+ | **recurrenceId** | [**string**] | &#x60;recurrenceId&#x60; of one occurrence, copied unchanged from a &#x60;listCalendarEvents&#x60; item. Omit it for a one-off event or for the whole series. | (optional) defaults to undefined|
192
+
193
+
194
+ ### Return type
195
+
196
+ **V1CalendarEventsResource**
197
+
198
+ ### Authorization
199
+
200
+ [BearerAuth](../README.md#BearerAuth)
201
+
202
+ ### HTTP request headers
203
+
204
+ - **Content-Type**: Not defined
205
+ - **Accept**: application/json
206
+
207
+
208
+ ### HTTP response details
209
+ | Status code | Description | Response headers |
210
+ |-------------|-------------|------------------|
211
+ |**200** | Event payload. | - |
212
+ |**401** | Missing or invalid credentials. | - |
213
+ |**403** | Token is not authorized to manage the requested mailbox. | - |
214
+ |**404** | Resource not found. | - |
215
+ |**422** | Request payload failed validation. &#x60;params&#x60; maps field name to an array of error messages. | - |
216
+ |**500** | Server-side failure. | - |
217
+ |**502** | Upstream service is unavailable or returned an unexpected response. | - |
218
+
219
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
220
+
221
+ # **listCalendarEvents**
222
+ > V1CalendarEventsCollection listCalendarEvents()
223
+
224
+ List the events of one calendar that overlap a time range. It covers one calendar only: get the calendars from `listCalendars` and call it for each. The range runs from `start` (inclusive) to `end` (exclusive), at most 32 days; for a longer period call it again with the next range. Recurring events are expanded: each occurrence is a separate item with the same `uuid` and its own `recurrenceId`. Results are not paginated. Items hold summary fields only. For description, location, attendees and organizer call `getCalendarEvent` with the `calendarUuid`, `uuid` (as `eventUuid`) and `recurrenceId` of the item. Times are in UTC; `timeZone` is the zone the event was created in. `participationStatus` is the answer of the mailbox to an invitation from someone else, null for its own events. `status` CANCELLED means the organizer cancelled the event.
225
+
226
+ ### Example
227
+
228
+ ```typescript
229
+ import {
230
+ CalendarEventsApi,
231
+ Configuration
232
+ } from '@hostinger/mail-sdk';
233
+
234
+ const configuration = new Configuration();
235
+ const apiInstance = new CalendarEventsApi(configuration);
236
+
237
+ let mailboxResourceId: string; //Resource ID of the managed mailbox the bearer token is authorized for. (default to undefined)
238
+ let calendarUuid: string; //Calendar identifier: the `uuid` of a calendar returned by `listCalendars`, or the `calendarUuid` of an event returned by `listCalendarEvents`. (default to undefined)
239
+ let start: string; //Start of the range, inclusive. ISO 8601 date-time with offset. (default to undefined)
240
+ let end: string; //End of the range, exclusive. ISO 8601 date-time after `start` and at most 32 days after it. (default to undefined)
241
+ let timeZone: string; //IANA time zone used to place all-day events and events without a time zone on days, also across a daylight saving change. Defaults to the fixed offset of `start`. (optional) (default to undefined)
242
+
243
+ const { status, data } = await apiInstance.listCalendarEvents(
244
+ mailboxResourceId,
245
+ calendarUuid,
246
+ start,
247
+ end,
248
+ timeZone
249
+ );
250
+ ```
251
+
252
+ ### Parameters
253
+
254
+ |Name | Type | Description | Notes|
255
+ |------------- | ------------- | ------------- | -------------|
256
+ | **mailboxResourceId** | [**string**] | Resource ID of the managed mailbox the bearer token is authorized for. | defaults to undefined|
257
+ | **calendarUuid** | [**string**] | Calendar identifier: the &#x60;uuid&#x60; of a calendar returned by &#x60;listCalendars&#x60;, or the &#x60;calendarUuid&#x60; of an event returned by &#x60;listCalendarEvents&#x60;. | defaults to undefined|
258
+ | **start** | [**string**] | Start of the range, inclusive. ISO 8601 date-time with offset. | defaults to undefined|
259
+ | **end** | [**string**] | End of the range, exclusive. ISO 8601 date-time after &#x60;start&#x60; and at most 32 days after it. | defaults to undefined|
260
+ | **timeZone** | [**string**] | IANA time zone used to place all-day events and events without a time zone on days, also across a daylight saving change. Defaults to the fixed offset of &#x60;start&#x60;. | (optional) defaults to undefined|
261
+
262
+
263
+ ### Return type
264
+
265
+ **V1CalendarEventsCollection**
266
+
267
+ ### Authorization
268
+
269
+ [BearerAuth](../README.md#BearerAuth)
270
+
271
+ ### HTTP request headers
272
+
273
+ - **Content-Type**: Not defined
274
+ - **Accept**: application/json
275
+
276
+
277
+ ### HTTP response details
278
+ | Status code | Description | Response headers |
279
+ |-------------|-------------|------------------|
280
+ |**200** | Events overlapping the range. | - |
281
+ |**401** | Missing or invalid credentials. | - |
282
+ |**403** | Token is not authorized to manage the requested mailbox. | - |
283
+ |**404** | Resource not found. | - |
284
+ |**422** | Request payload failed validation. &#x60;params&#x60; maps field name to an array of error messages. | - |
285
+ |**500** | Server-side failure. | - |
286
+ |**502** | Upstream service is unavailable or returned an unexpected response. | - |
287
+
288
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
289
+
290
+ # **replyToCalendarEvent**
291
+ > V1CalendarEventsResource replyToCalendarEvent(v1CalendarEventsReplyRequest)
292
+
293
+ Answer an invitation from someone else: accept, decline or tentatively accept. It saves the answer on the event and emails it to the organizer, which cannot be recalled. `calendarUuid` and `eventUuid` come from `listCalendarEvents`. It works only when `getCalendarEvent` returns `replyable` true. An event the mailbox organizes or is not invited to is rejected with `403` and code `ERR_EVENT_NOT_REPLYABLE`, an event the organizer cancelled with `409` and code `ERR_EVENT_CANCELLED`. Send the `recurrenceId` of an item to answer one occurrence of a recurring event, or omit it to answer the whole series. Returns the event with the new `participationStatus`.
294
+
295
+ ### Example
296
+
297
+ ```typescript
298
+ import {
299
+ CalendarEventsApi,
300
+ Configuration,
301
+ V1CalendarEventsReplyRequest
302
+ } from '@hostinger/mail-sdk';
303
+
304
+ const configuration = new Configuration();
305
+ const apiInstance = new CalendarEventsApi(configuration);
306
+
307
+ let mailboxResourceId: string; //Resource ID of the managed mailbox the bearer token is authorized for. (default to undefined)
308
+ let calendarUuid: string; //Calendar identifier: the `uuid` of a calendar returned by `listCalendars`, or the `calendarUuid` of an event returned by `listCalendarEvents`. (default to undefined)
309
+ let eventUuid: string; //Event identifier: the `uuid` of an event returned by `listCalendarEvents`. Every occurrence of a recurring event has the same uuid; `recurrenceId` picks one occurrence. (default to undefined)
310
+ let v1CalendarEventsReplyRequest: V1CalendarEventsReplyRequest; //
311
+ let ifMatch: string; //Optional `etag` from `getCalendarEvent`. When the event changed since that call, the answer is not saved and the request fails with `412`: fetch the event again and retry. Omit it to apply the request to the current version. (optional) (default to undefined)
312
+
313
+ const { status, data } = await apiInstance.replyToCalendarEvent(
314
+ mailboxResourceId,
315
+ calendarUuid,
316
+ eventUuid,
317
+ v1CalendarEventsReplyRequest,
318
+ ifMatch
319
+ );
320
+ ```
321
+
322
+ ### Parameters
323
+
324
+ |Name | Type | Description | Notes|
325
+ |------------- | ------------- | ------------- | -------------|
326
+ | **v1CalendarEventsReplyRequest** | **V1CalendarEventsReplyRequest**| | |
327
+ | **mailboxResourceId** | [**string**] | Resource ID of the managed mailbox the bearer token is authorized for. | defaults to undefined|
328
+ | **calendarUuid** | [**string**] | Calendar identifier: the &#x60;uuid&#x60; of a calendar returned by &#x60;listCalendars&#x60;, or the &#x60;calendarUuid&#x60; of an event returned by &#x60;listCalendarEvents&#x60;. | defaults to undefined|
329
+ | **eventUuid** | [**string**] | Event identifier: the &#x60;uuid&#x60; of an event returned by &#x60;listCalendarEvents&#x60;. Every occurrence of a recurring event has the same uuid; &#x60;recurrenceId&#x60; picks one occurrence. | defaults to undefined|
330
+ | **ifMatch** | [**string**] | Optional &#x60;etag&#x60; from &#x60;getCalendarEvent&#x60;. When the event changed since that call, the answer is not saved and the request fails with &#x60;412&#x60;: fetch the event again and retry. Omit it to apply the request to the current version. | (optional) defaults to undefined|
331
+
332
+
333
+ ### Return type
334
+
335
+ **V1CalendarEventsResource**
336
+
337
+ ### Authorization
338
+
339
+ [BearerAuth](../README.md#BearerAuth)
340
+
341
+ ### HTTP request headers
342
+
343
+ - **Content-Type**: application/json
344
+ - **Accept**: application/json
345
+
346
+
347
+ ### HTTP response details
348
+ | Status code | Description | Response headers |
349
+ |-------------|-------------|------------------|
350
+ |**200** | Event with the saved answer. | - |
351
+ |**401** | Missing or invalid credentials. | - |
352
+ |**403** | Token is not authorized to manage the requested mailbox. | - |
353
+ |**404** | Resource not found. | - |
354
+ |**409** | Conflict with the target resource. | - |
355
+ |**412** | The resource changed since the etag sent in &#x60;If-Match&#x60; was read. Nothing was changed: fetch the resource again and retry. | - |
356
+ |**422** | Request payload failed validation. &#x60;params&#x60; maps field name to an array of error messages. | - |
357
+ |**500** | Server-side failure. | - |
358
+ |**502** | Upstream service is unavailable or returned an unexpected response. | - |
359
+
360
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
361
+
362
+ # **rescheduleCalendarEvent**
363
+ > V1CalendarEventsResource rescheduleCalendarEvent(v1CalendarEventsRescheduleRequest)
364
+
365
+ Move an event to another time or change its length, keeping everything else (title, attendees, description and so on) as stored, so the event does not have to be fetched first. To change other fields use `updateCalendarEvent`. `calendarUuid` and `eventUuid` come from `listCalendarEvents`. Only an event with `editable` true can be moved; any other is rejected with `403` and code `ERR_EVENT_NOT_EDITABLE`. For a recurring event, `scope` `this` moves only the occurrence at `recurrenceId`, `future` ends the series before that occurrence and starts a new one with a new `uuid`, `all` (the default) moves the whole series: only the time of day and the length apply and the series keeps the date of its first occurrence. Attendees receive an email update unless `notifyAttendees` is false. Returns the moved event, or the moved occurrence for `scope` `this`.
366
+
367
+ ### Example
368
+
369
+ ```typescript
370
+ import {
371
+ CalendarEventsApi,
372
+ Configuration,
373
+ V1CalendarEventsRescheduleRequest
374
+ } from '@hostinger/mail-sdk';
375
+
376
+ const configuration = new Configuration();
377
+ const apiInstance = new CalendarEventsApi(configuration);
378
+
379
+ let mailboxResourceId: string; //Resource ID of the managed mailbox the bearer token is authorized for. (default to undefined)
380
+ let calendarUuid: string; //Calendar identifier: the `uuid` of a calendar returned by `listCalendars`, or the `calendarUuid` of an event returned by `listCalendarEvents`. (default to undefined)
381
+ let eventUuid: string; //Event identifier: the `uuid` of an event returned by `listCalendarEvents`. Every occurrence of a recurring event has the same uuid; `recurrenceId` picks one occurrence. (default to undefined)
382
+ let v1CalendarEventsRescheduleRequest: V1CalendarEventsRescheduleRequest; //
383
+ let ifMatch: string; //Optional `etag` from `getCalendarEvent`. When the event changed since that call, nothing is changed and the request fails with `412`: fetch the event again and retry. Omit it to apply the request to the current version. (optional) (default to undefined)
384
+
385
+ const { status, data } = await apiInstance.rescheduleCalendarEvent(
386
+ mailboxResourceId,
387
+ calendarUuid,
388
+ eventUuid,
389
+ v1CalendarEventsRescheduleRequest,
390
+ ifMatch
391
+ );
392
+ ```
393
+
394
+ ### Parameters
395
+
396
+ |Name | Type | Description | Notes|
397
+ |------------- | ------------- | ------------- | -------------|
398
+ | **v1CalendarEventsRescheduleRequest** | **V1CalendarEventsRescheduleRequest**| | |
399
+ | **mailboxResourceId** | [**string**] | Resource ID of the managed mailbox the bearer token is authorized for. | defaults to undefined|
400
+ | **calendarUuid** | [**string**] | Calendar identifier: the &#x60;uuid&#x60; of a calendar returned by &#x60;listCalendars&#x60;, or the &#x60;calendarUuid&#x60; of an event returned by &#x60;listCalendarEvents&#x60;. | defaults to undefined|
401
+ | **eventUuid** | [**string**] | Event identifier: the &#x60;uuid&#x60; of an event returned by &#x60;listCalendarEvents&#x60;. Every occurrence of a recurring event has the same uuid; &#x60;recurrenceId&#x60; picks one occurrence. | defaults to undefined|
402
+ | **ifMatch** | [**string**] | Optional &#x60;etag&#x60; from &#x60;getCalendarEvent&#x60;. When the event changed since that call, nothing is changed and the request fails with &#x60;412&#x60;: fetch the event again and retry. Omit it to apply the request to the current version. | (optional) defaults to undefined|
403
+
404
+
405
+ ### Return type
406
+
407
+ **V1CalendarEventsResource**
408
+
409
+ ### Authorization
410
+
411
+ [BearerAuth](../README.md#BearerAuth)
412
+
413
+ ### HTTP request headers
414
+
415
+ - **Content-Type**: application/json
416
+ - **Accept**: application/json
417
+
418
+
419
+ ### HTTP response details
420
+ | Status code | Description | Response headers |
421
+ |-------------|-------------|------------------|
422
+ |**200** | Rescheduled event. | - |
423
+ |**400** | The change would leave the event with more unique attendees across all of its occurrences than allowed. &#x60;params.maxAttendees&#x60; holds the limit. | - |
424
+ |**401** | Missing or invalid credentials. | - |
425
+ |**403** | Token is not authorized to manage the requested mailbox. | - |
426
+ |**404** | Resource not found. | - |
427
+ |**412** | The resource changed since the etag sent in &#x60;If-Match&#x60; was read. Nothing was changed: fetch the resource again and retry. | - |
428
+ |**422** | Request payload failed validation. &#x60;params&#x60; maps field name to an array of error messages. | - |
429
+ |**500** | Server-side failure. | - |
430
+ |**502** | Upstream service is unavailable or returned an unexpected response. | - |
431
+
432
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
433
+
434
+ # **updateCalendarEvent**
435
+ > V1CalendarEventsResource updateCalendarEvent(v1CalendarEventsUpdateRequest)
436
+
437
+ Change the details of an event: title, times, description, location, attendees, recurrence and so on. Every field replaces the stored value and an omitted optional field is cleared, so call `getCalendarEvent` first and send back the values that should stay. To only move an event in time, use `rescheduleCalendarEvent`. Only an event with `editable` true can be changed; any other is rejected with `403` and code `ERR_EVENT_NOT_EDITABLE`. For a recurring event, `scope` `this` changes only the occurrence at `recurrenceId`, `future` ends the series before that occurrence and starts a new one with a new `uuid`, `all` (the default) changes the whole series, keeping the date of its first occurrence. Attendees receive an email update, added attendees an invitation and removed ones a cancellation, unless `notifyAttendees` is false. Returns the changed event, or the changed occurrence for `scope` `this`.
438
+
439
+ ### Example
440
+
441
+ ```typescript
442
+ import {
443
+ CalendarEventsApi,
444
+ Configuration,
445
+ V1CalendarEventsUpdateRequest
446
+ } from '@hostinger/mail-sdk';
447
+
448
+ const configuration = new Configuration();
449
+ const apiInstance = new CalendarEventsApi(configuration);
450
+
451
+ let mailboxResourceId: string; //Resource ID of the managed mailbox the bearer token is authorized for. (default to undefined)
452
+ let calendarUuid: string; //Calendar identifier: the `uuid` of a calendar returned by `listCalendars`, or the `calendarUuid` of an event returned by `listCalendarEvents`. (default to undefined)
453
+ let eventUuid: string; //Event identifier: the `uuid` of an event returned by `listCalendarEvents`. Every occurrence of a recurring event has the same uuid; `recurrenceId` picks one occurrence. (default to undefined)
454
+ let v1CalendarEventsUpdateRequest: V1CalendarEventsUpdateRequest; //
455
+ let ifMatch: string; //Optional `etag` from `getCalendarEvent`. When the event changed since that call, nothing is changed and the request fails with `412`: fetch the event again and retry. Omit it to apply the request to the current version. (optional) (default to undefined)
456
+
457
+ const { status, data } = await apiInstance.updateCalendarEvent(
458
+ mailboxResourceId,
459
+ calendarUuid,
460
+ eventUuid,
461
+ v1CalendarEventsUpdateRequest,
462
+ ifMatch
463
+ );
464
+ ```
465
+
466
+ ### Parameters
467
+
468
+ |Name | Type | Description | Notes|
469
+ |------------- | ------------- | ------------- | -------------|
470
+ | **v1CalendarEventsUpdateRequest** | **V1CalendarEventsUpdateRequest**| | |
471
+ | **mailboxResourceId** | [**string**] | Resource ID of the managed mailbox the bearer token is authorized for. | defaults to undefined|
472
+ | **calendarUuid** | [**string**] | Calendar identifier: the &#x60;uuid&#x60; of a calendar returned by &#x60;listCalendars&#x60;, or the &#x60;calendarUuid&#x60; of an event returned by &#x60;listCalendarEvents&#x60;. | defaults to undefined|
473
+ | **eventUuid** | [**string**] | Event identifier: the &#x60;uuid&#x60; of an event returned by &#x60;listCalendarEvents&#x60;. Every occurrence of a recurring event has the same uuid; &#x60;recurrenceId&#x60; picks one occurrence. | defaults to undefined|
474
+ | **ifMatch** | [**string**] | Optional &#x60;etag&#x60; from &#x60;getCalendarEvent&#x60;. When the event changed since that call, nothing is changed and the request fails with &#x60;412&#x60;: fetch the event again and retry. Omit it to apply the request to the current version. | (optional) defaults to undefined|
475
+
476
+
477
+ ### Return type
478
+
479
+ **V1CalendarEventsResource**
480
+
481
+ ### Authorization
482
+
483
+ [BearerAuth](../README.md#BearerAuth)
484
+
485
+ ### HTTP request headers
486
+
487
+ - **Content-Type**: application/json
488
+ - **Accept**: application/json
489
+
490
+
491
+ ### HTTP response details
492
+ | Status code | Description | Response headers |
493
+ |-------------|-------------|------------------|
494
+ |**200** | Updated event. | - |
495
+ |**400** | The change would leave the event with more unique attendees across all of its occurrences than allowed. &#x60;params.maxAttendees&#x60; holds the limit. | - |
496
+ |**401** | Missing or invalid credentials. | - |
497
+ |**403** | Token is not authorized to manage the requested mailbox. | - |
498
+ |**404** | Resource not found. | - |
499
+ |**412** | The resource changed since the etag sent in &#x60;If-Match&#x60; was read. Nothing was changed: fetch the resource again and retry. | - |
500
+ |**422** | Request payload failed validation. &#x60;params&#x60; maps field name to an array of error messages. | - |
501
+ |**500** | Server-side failure. | - |
502
+ |**502** | Upstream service is unavailable or returned an unexpected response. | - |
503
+
504
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
505
+