idnits 2.17.1 draft-ietf-calext-jscalendar-06.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (August 30, 2018) is 2059 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) -- Looks like a reference, but probably isn't: '1' on line 2414 -- Looks like a reference, but probably isn't: '2' on line 2417 -- Looks like a reference, but probably isn't: '3' on line 2419 Summary: 0 errors (**), 0 flaws (~~), 1 warning (==), 4 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Calendaring extensions N. Jenkins 3 Internet-Draft R. Stepanek 4 Intended status: Standards Track FastMail 5 Expires: March 3, 2019 August 30, 2018 7 JSCalendar: A JSON representation of calendar data 8 draft-ietf-calext-jscalendar-06 10 Abstract 12 This specification defines a data model and JSON representation of 13 calendar data that can be used for storage and data exchange in a 14 calendaring and scheduling environment. It aims to be an alternative 15 to the widely deployed iCalendar data format and to be unambiguous, 16 extendable and simple to process. 18 Status of This Memo 20 This Internet-Draft is submitted in full conformance with the 21 provisions of BCP 78 and BCP 79. 23 Internet-Drafts are working documents of the Internet Engineering 24 Task Force (IETF). Note that other groups may also distribute 25 working documents as Internet-Drafts. The list of current Internet- 26 Drafts is at https://datatracker.ietf.org/drafts/current/. 28 Internet-Drafts are draft documents valid for a maximum of six months 29 and may be updated, replaced, or obsoleted by other documents at any 30 time. It is inappropriate to use Internet-Drafts as reference 31 material or to cite them other than as "work in progress." 33 This Internet-Draft will expire on March 3, 2019. 35 Copyright Notice 37 Copyright (c) 2018 IETF Trust and the persons identified as the 38 document authors. All rights reserved. 40 This document is subject to BCP 78 and the IETF Trust's Legal 41 Provisions Relating to IETF Documents 42 (https://trustee.ietf.org/license-info) in effect on the date of 43 publication of this document. Please review these documents 44 carefully, as they describe your rights and restrictions with respect 45 to this document. Code Components extracted from this document must 46 include Simplified BSD License text as described in Section 4.e of 47 the Trust Legal Provisions and are provided without warranty as 48 described in the Simplified BSD License. 50 Table of Contents 52 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 4 53 1.1. Relation to the iCalendar format . . . . . . . . . . . . 4 54 1.2. Notational Conventions . . . . . . . . . . . . . . . . . 5 55 2. JSCalendar objects . . . . . . . . . . . . . . . . . . . . . 5 56 2.1. JSEvent . . . . . . . . . . . . . . . . . . . . . . . . . 5 57 2.2. JSTask . . . . . . . . . . . . . . . . . . . . . . . . . 5 58 2.3. JSGroup . . . . . . . . . . . . . . . . . . . . . . . . . 6 59 3. Structure of JSCalendar objects . . . . . . . . . . . . . . . 6 60 3.1. Type signatures . . . . . . . . . . . . . . . . . . . . . 6 61 3.2. Data Types . . . . . . . . . . . . . . . . . . . . . . . 7 62 3.2.1. UTCDate . . . . . . . . . . . . . . . . . . . . . . . 7 63 3.2.2. LocalDate . . . . . . . . . . . . . . . . . . . . . . 7 64 3.2.3. Duration . . . . . . . . . . . . . . . . . . . . . . 7 65 3.2.4. PatchObject . . . . . . . . . . . . . . . . . . . . . 8 66 3.2.5. Identifiers . . . . . . . . . . . . . . . . . . . . . 8 67 3.2.6. Normalization and equivalence . . . . . . . . . . . . 8 68 3.3. Custom property extensions and values . . . . . . . . . . 9 69 4. Common JSCalendar properties . . . . . . . . . . . . . . . . 9 70 4.1. Metadata properties . . . . . . . . . . . . . . . . . . . 9 71 4.1.1. @type . . . . . . . . . . . . . . . . . . . . . . . . 9 72 4.1.2. uid . . . . . . . . . . . . . . . . . . . . . . . . . 10 73 4.1.3. relatedTo . . . . . . . . . . . . . . . . . . . . . . 10 74 4.1.4. prodId . . . . . . . . . . . . . . . . . . . . . . . 11 75 4.1.5. created . . . . . . . . . . . . . . . . . . . . . . . 11 76 4.1.6. updated . . . . . . . . . . . . . . . . . . . . . . . 11 77 4.1.7. sequence . . . . . . . . . . . . . . . . . . . . . . 12 78 4.1.8. method . . . . . . . . . . . . . . . . . . . . . . . 12 79 4.2. What and where properties . . . . . . . . . . . . . . . . 12 80 4.2.1. title . . . . . . . . . . . . . . . . . . . . . . . . 12 81 4.2.2. description . . . . . . . . . . . . . . . . . . . . . 12 82 4.2.3. descriptionContentType . . . . . . . . . . . . . . . 12 83 4.2.4. locations . . . . . . . . . . . . . . . . . . . . . . 12 84 4.2.5. virtualLocations . . . . . . . . . . . . . . . . . . 13 85 4.2.6. links . . . . . . . . . . . . . . . . . . . . . . . . 14 86 4.2.7. locale . . . . . . . . . . . . . . . . . . . . . . . 15 87 4.2.8. keywords . . . . . . . . . . . . . . . . . . . . . . 15 88 4.2.9. categories . . . . . . . . . . . . . . . . . . . . . 15 89 4.2.10. color . . . . . . . . . . . . . . . . . . . . . . . . 16 90 4.3. Recurrence properties . . . . . . . . . . . . . . . . . . 16 91 4.3.1. recurrenceRule . . . . . . . . . . . . . . . . . . . 16 92 4.3.2. recurrenceOverrides . . . . . . . . . . . . . . . . . 21 93 4.3.3. excluded . . . . . . . . . . . . . . . . . . . . . . 22 94 4.4. Sharing and scheduling properties . . . . . . . . . . . . 22 95 4.4.1. priority . . . . . . . . . . . . . . . . . . . . . . 22 96 4.4.2. freeBusyStatus . . . . . . . . . . . . . . . . . . . 22 97 4.4.3. privacy . . . . . . . . . . . . . . . . . . . . . . . 23 98 4.4.4. replyTo . . . . . . . . . . . . . . . . . . . . . . . 24 99 4.4.5. participants . . . . . . . . . . . . . . . . . . . . 25 100 4.5. Alerts properties . . . . . . . . . . . . . . . . . . . . 27 101 4.5.1. useDefaultAlerts . . . . . . . . . . . . . . . . . . 27 102 4.5.2. alerts . . . . . . . . . . . . . . . . . . . . . . . 27 103 4.6. Multilingual properties . . . . . . . . . . . . . . . . . 29 104 4.6.1. localizations . . . . . . . . . . . . . . . . . . . . 29 105 5. Type-specific JSCalendar properties . . . . . . . . . . . . . 30 106 5.1. JSEvent properties . . . . . . . . . . . . . . . . . . . 30 107 5.1.1. start . . . . . . . . . . . . . . . . . . . . . . . . 30 108 5.1.2. timeZone . . . . . . . . . . . . . . . . . . . . . . 30 109 5.1.3. duration . . . . . . . . . . . . . . . . . . . . . . 30 110 5.1.4. isAllDay . . . . . . . . . . . . . . . . . . . . . . 31 111 5.1.5. status . . . . . . . . . . . . . . . . . . . . . . . 31 112 5.2. JSTask properties . . . . . . . . . . . . . . . . . . . . 31 113 5.2.1. due . . . . . . . . . . . . . . . . . . . . . . . . . 31 114 5.2.2. start . . . . . . . . . . . . . . . . . . . . . . . . 32 115 5.2.3. timeZone . . . . . . . . . . . . . . . . . . . . . . 32 116 5.2.4. estimatedDuration . . . . . . . . . . . . . . . . . . 32 117 5.2.5. statusUpdatedAt . . . . . . . . . . . . . . . . . . . 32 118 5.2.6. isAllDay . . . . . . . . . . . . . . . . . . . . . . 32 119 5.2.7. progress . . . . . . . . . . . . . . . . . . . . . . 33 120 5.2.8. status . . . . . . . . . . . . . . . . . . . . . . . 33 121 5.3. JSGroup properties . . . . . . . . . . . . . . . . . . . 34 122 5.3.1. entries . . . . . . . . . . . . . . . . . . . . . . . 34 123 5.3.2. source . . . . . . . . . . . . . . . . . . . . . . . 35 124 6. Conversion from and to iCalendar . . . . . . . . . . . . . . 35 125 6.1. JSEvent . . . . . . . . . . . . . . . . . . . . . . . . . 35 126 6.2. JSTask . . . . . . . . . . . . . . . . . . . . . . . . . 36 127 6.3. JSGroup . . . . . . . . . . . . . . . . . . . . . . . . . 38 128 6.4. Common properties . . . . . . . . . . . . . . . . . . . . 38 129 6.5. Locations and participants . . . . . . . . . . . . . . . 40 130 6.6. Unknown properties . . . . . . . . . . . . . . . . . . . 43 131 7. JSCalendar object examples . . . . . . . . . . . . . . . . . 43 132 7.1. Simple event . . . . . . . . . . . . . . . . . . . . . . 43 133 7.2. Simple task . . . . . . . . . . . . . . . . . . . . . . . 44 134 7.3. Simple group . . . . . . . . . . . . . . . . . . . . . . 44 135 7.4. All-day event . . . . . . . . . . . . . . . . . . . . . . 44 136 7.5. Task with a due date . . . . . . . . . . . . . . . . . . 45 137 7.6. Event with end time-zone . . . . . . . . . . . . . . . . 45 138 7.7. Floating-time event (with recurrence) . . . . . . . . . . 46 139 7.8. Event with multiple locations and localization . . . . . 46 140 7.9. Recurring event with overrides . . . . . . . . . . . . . 47 141 7.10. Recurring event with participants . . . . . . . . . . . . 48 142 8. Security Considerations . . . . . . . . . . . . . . . . . . . 50 143 9. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 50 144 10. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 50 145 11. References . . . . . . . . . . . . . . . . . . . . . . . . . 50 146 11.1. Normative References . . . . . . . . . . . . . . . . . . 50 147 11.2. Informative References . . . . . . . . . . . . . . . . . 52 148 11.3. URIs . . . . . . . . . . . . . . . . . . . . . . . . . . 53 149 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 53 151 1. Introduction 153 This document defines a data model for calendar event and task 154 objects, or groups of such objects, in electronic calendar 155 applications and systems. It aims to be unambiguous, extendable and 156 simple to process. 158 The key design considerations for this data model are as follows: 160 o The attributes of the calendar entry represented must be described 161 as a simple key-value pair, reducing complexity of its 162 representation. 164 o The data model should avoid all ambiguities and make it difficult 165 to make mistakes during implementation. 167 o Most of the initial set of attributes should be taken from the 168 iCalendar data format ([RFC5545], also see Section 1.1), but the 169 specification should add new attributes or value types, or not 170 support existing ones, where appropriate. Conversion between the 171 data formats need not fully preserve semantic meaning. 173 o Extensions, such as new properties and components, MUST NOT lead 174 to requiring an update to this document. 176 The representation of this data model is defined in the I-JSON format 177 [RFC7493], which is a strict subset of the JavaScript Object Notation 178 (JSON) Data Interchange Format [RFC8259]. Using JSON mostly is a 179 pragmatic choice: its widespread use should help to speed up 180 JSCalendar adoption and a wide range of production-ready JSON 181 implementations allows to decrease interoperability issues. 183 1.1. Relation to the iCalendar format 185 The iCalendar data format [RFC5545], a widely deployed interchange 186 format for calendaring and scheduling data, has served calendaring 187 vendors for a long while, but contains some ambiguities and pitfalls 188 that can not be overcome without backward-incompatible changes. 190 For example, iCalendar defines various formats for local times, UTC 191 time and dates, which confuses new users. Other sources for errors 192 are the requirement for custom time-zone definitions within a single 193 calendar component, as well as the iCalendar format itself; the 194 latter causing interoperability issues due to misuse of CR LF 195 terminated strings, line continuations and subtle differences between 196 iCalendar parsers. Lastly, up until recently the iCalendar format 197 did not allow to express the difference between two calendar 198 components, which results in verbose exchanges during scheduling. 200 Some of these issues were addressed by the jCal [RFC7265] format, 201 which is a direct mapping between iCalendar and JSON. However, it 202 did not attempt to extend or update iCalendar semantics. 204 1.2. Notational Conventions 206 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 207 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 208 document are to be interpreted as described in [RFC2119]. 210 The underlying format used for this specification is JSON. 211 Consequently, the terms "object" and "array" as well as the four 212 primitive types (strings, numbers, booleans, and null) are to be 213 interpreted as described in Section 1 of[RFC8259]. 215 Some examples in this document contain "partial" JSON documents used 216 for illustrative purposes. In these examples, three periods "..." 217 are used to indicate a portion of the document that has been removed 218 for compactness. 220 2. JSCalendar objects 222 This section describes the calendar object types specified by 223 JSCalendar. 225 2.1. JSEvent 227 MIME type: "application/calendar+json;type=jsevent" 229 A JSEvent represents a scheduled amount of time on a calendar, 230 typically a meeting, appointment, reminder or anniversary. Multiple 231 participants may partake in the event at multiple locations. 233 The @type (Section 4.1.1) property value MUST be "jsevent". 235 2.2. JSTask 237 MIME type: "application/calendar+json;type=jstask" 239 A JSTask represents an action-item, assignment, to-do or work item . 241 The @type (Section 4.1.1) property value MUST be "jstask". 243 A JSTask may start and be due at certain points in time, may take 244 some estimated time to complete and may recur; none of which is 245 required. This notably differs from JSEvent (Section 2.1) which is 246 required to start at a certain point in time and typically takes some 247 non-zero duration to complete. 249 2.3. JSGroup 251 MIME type: "application/calendar+json;type=jsgroup" 253 A JSGroup is a collection of JSEvent (Section 2.1) and JSTask 254 (Section 2.2) objects. Typically, objects are grouped by topic (e.g. 255 by keywords) or calendar membership. 257 The @type (Section 4.1.1) property value MUST be "jsgroup". 259 3. Structure of JSCalendar objects 261 A JSCalendar object is a JSON object, which MUST be valid I-JSON (a 262 stricter subset of JSON), as specified in [RFC8259]. Property names 263 and values are case-sensitive. 265 The object has a collection of properties, as specified in the 266 following sections. Unless otherwise specified, all properties are 267 mandatory. Optional properties may have a default value, if 268 explicitly specified in the property definition. 270 3.1. Type signatures 272 Types signatures are given for all JSON objects in this document. 273 The following conventions are used: 275 o "Boolean|String": The value is either a JSON "Boolean" value, or a 276 JSON "String" value. 278 o "Foo": Any name that is not a native JSON type means an object for 279 which the properties (and their types) are defined elsewhere 280 within this document. 282 o "Foo[]": An array of objects of type "Foo". 284 o "String[Foo]": A JSON "Object" being used as a map (associative 285 array), where all the values are of type "Foo". 287 3.2. Data Types 289 In addition to the standard JSON data types, the following data types 290 are used in this specification: 292 3.2.1. UTCDate 294 This is a string in [RFC3339] "date-time" format, with the further 295 restrictions that any letters MUST be in upper-case, the time 296 component MUST be included and the time MUST be in UTC. Fractional 297 second values MUST NOT be included unless non-zero and MUST NOT have 298 trailing zeros, to ensure there is only a single representation for 299 each date-time. 301 For example "2010-10-10T10:10:10.003Z" is OK, but 302 "2010-10-10T10:10:10.000Z" is invalid and MUST be encoded as 303 "2010-10-10T10:10:10Z". 305 In common notation, it should be of the form "YYYY-MM-DDTHH:MM:SSZ". 307 3.2.2. LocalDate 309 This is a date-time string _with no time-zone/offset information_. 310 It is otherwise in the same format as UTCDate: "YYYY-MM-DDTHH:MM:SS". 311 The time-zone to associate the LocalDate with comes from an 312 associated property, or if no time-zone is associated it defines 313 _floating time_. Floating date-times are not tied to any specific 314 time-zone. Instead, they occur in every timezone at the same _wall- 315 clock_ time (as opposed to the same instant point in time). 317 3.2.3. Duration 319 A duration is represented by a subset of ISO8601 duration format, as 320 specified by the following ABNF: 322 dur-secfrac = "." 1*DIGIT 323 dur-second = 1*DIGIT [dur-secfrac] "S" 324 dur-minute = 1*DIGIT "M" [dur-second] 325 dur-hour = 1*DIGIT "H" [dur-minute] 326 dur-time = "T" (dur-hour / dur-minute / dur-second) 327 dur-day = 1*DIGIT "D" 328 dur-week = 1*DIGIT "W" 330 duration = "P" (dur-day [dur-time] / dur-time / dur-week) 332 In addition, the duration MUST NOT include fractional second values 333 unless the fraction is non-zero. 335 3.2.4. PatchObject 337 A *PatchObject* is of type "String[*|null]", and represents an 338 unordered set of patches on a JSON object. The keys are a path in a 339 subset of [RFC6901] JSON pointer format, with an implicit leading "/" 340 (i.e. prefix each key with "/" before applying the JSON pointer 341 evaluation algorithm). 343 A patch within a PatchObject is only valid, if all of the following 344 conditions apply: 346 1. The pointer MUST NOT reference inside an array (i.e. it MUST NOT 347 insert/delete from an array; the array MUST be replaced in its 348 entirety instead). 350 2. When evaluating a path, all parts prior to the last (i.e. the 351 value after the final slash) MUST exist. 353 3. There MUST NOT be two patches in the PatchObject where the 354 pointer of one is the prefix of the pointer of the other, e.g. 355 "alerts/foo/offset" and "alerts". 357 The value associated with each pointer is either: 359 o "null": Remove the property from the patched object. If not 360 present in the parent, this a no-op. 362 o Anything else: The value to replace the inherited property on the 363 patch object with (if present) or add to the property (if not 364 present). 366 Implementations MUST reject a PatchObject if any of its patches are 367 invalid. 369 3.2.5. Identifiers 371 If not noted otherwise, properties that define identifiers MUST be 372 string values, MUST be at least 1 character in length and maximum 256 373 octets in size, and MUST only contain characters from the "URL and 374 Filename safe" Base 64 Alphabet, as defined in section 5 of 375 [RFC4648]. This is the ASCII alphanumeric characters (A-Za-z0-9), 376 hyphen (-), and underscore (_). 378 3.2.6. Normalization and equivalence 380 JSCalendar aims to provide unambiguous definitions for value types 381 and properties, but does not define a general normalization or 382 equivalence method for JSCalendar objects and types. This is because 383 the notion of equivalence might range from byte-level equivalence to 384 semantic equivalence, depending on the respective use case (for 385 example, the CalDAV protocol [RFC4791] requires octet equivalence of 386 the encoded calendar object to determine ETag equivalence). 388 Normalization of JSCalendar objects is hindered because of the 389 following reasons: 391 o Custom JSCalendar properties may contain arbitrary JSON values, 392 including arrays. However, equivalence of arrays might or might 393 not depend on the order of elements, depending on the respective 394 property definition. 396 o Several JSCalendar property values are defined as URIs and MIME 397 types, but normalization of these types is inherently protocol and 398 scheme-specific, depending on the use-case of the equivalence 399 definition (see section 6 of [RFC3986]). 401 Considering this, the definition of equivalence and normalization is 402 left to client and server implementations and to be negotiated by a 403 calendar exchange protocol or defined by another RFC. 405 3.3. Custom property extensions and values 407 Vendors MAY add additional properties to the calendar object to 408 support their custom features. The names of these properties MUST be 409 prefixed with a domain name controlled by the vendor to avoid 410 conflict, e.g. "example.com/customprop". 412 Some JSCalendar properties allow vendor-specific value extensions. 413 If so, vendor specific values MUST be prefixed with a domain name 414 controlled by the vendor, e.g. "example.com/customrel", unless 415 otherwise noted. 417 4. Common JSCalendar properties 419 This section describes the properties that are common to the various 420 JSCalendar object types. Specific JSCalendar object types may only 421 support a subset of these properties. The object type definitions in 422 Section 5 describe the set of supported properties per type. 424 4.1. Metadata properties 426 4.1.1. @type 428 Type: "String" 429 Specifies the type which this object represents. This MUST be one of 430 the following values, registered in a future RFC, or a vendor- 431 specific value: 433 o "jsevent": a JSCalendar event (Section 2.1). 435 o "jstask": a JSCalendar task (Section 2.2). 437 o "jsgroup": a JSCalendar group (Section 2.3). 439 A valid JSCalendar object MUST include this property. 441 4.1.2. uid 443 Type: "String" 445 A globally unique identifier, used to associate the object as the 446 same across different systems, calendars and views. The value of 447 this property MUST be unique across _all_ JSCalendar objects, even if 448 they are of different type. [RFC4122] describes a range of 449 established algorithms to generate universally unique identifiers 450 (UUID), and the random or pseudo-random version is recommended to 451 use. 453 For compatibility with [RFC5545] UIDs, implementations MUST be able 454 to receive and persist values of at least 255 octets for this 455 property, but they MUST NOT truncate values in the middle of a UTF-8 456 multi-octet sequence. 458 A valid JSCalendar object MUST include this property. 460 4.1.3. relatedTo 462 Type: "String[Relation]" (optional) 464 Relates the object to other JSCalendar objects. This is represented 465 as a map of the uids of the related objects to information about the 466 relation. 468 A *Relation* object has the following properties: 470 o *relation*: "String[]" Describes how the linked object is related 471 to this object. 473 The strings in the array MUST each be at most one of the following 474 values, registered in a future RFC, or a vendor-specific value: 476 * "first": The linked object is the first in the series this 477 object is part of. 479 * "next": The linked object is the next in the series this object 480 is part of. 482 * "child": The linked object is a subpart of this object. 484 * "parent": This object is part of the overall linked object. 486 If an object is split to make a "this and future" change to a 487 recurrence, the original object MUST be truncated to end at the 488 previous occurrence before this split, and a new object created to 489 represent all the objects after the split. A "relation=["next"]" 490 relatedTo property MUST be set on the original object with the uid of 491 the new object. A "relation=["first"]" relatedTo property with the 492 UID of the first object in the series MUST be set on the new object. 493 Clients can then follow these UIDs to get the complete set of objects 494 if the user wishes to modify them all at once. 496 4.1.4. prodId 498 Type: "String" (optional) 500 The identifier for the product that created the JSCalendar object. 502 The vendor of the implementation SHOULD ensure that this is a 503 globally unique identifier, using some technique such as an FPI 504 value, as defined in [ISO.9070.1991]. It MUST only use characters of 505 an iCalendar TEXT data value (see section 3.3.11 in [RFC5545]). 507 This property SHOULD NOT be used to alter the interpretation of an 508 JSCalendar object beyond the semantics specified in this document. 509 For example, it is not to be used to further the understanding of 510 non-standard properties. 512 4.1.5. created 514 Type: "UTCDate" (optional) 516 The date and time this object was initially created. 518 4.1.6. updated 520 Type: "UTCDate" 522 The date and time the data in this object was last modified. 524 4.1.7. sequence 526 Type: "Number" (optional, default:"0") 528 Initially zero, this MUST be a non-negative integer that is 529 monotonically incremented each time a change is made to the object. 531 4.1.8. method 533 Type: "String" (optional) 535 The iTIP ([RFC5546]) method, in lower-case. Used for scheduling. 537 4.2. What and where properties 539 4.2.1. title 541 Type: "String" (optional, default:"") 543 A short summary of the object. 545 4.2.2. description 547 Type: "String" (optional, default:"") 549 A longer-form text description of the object. The content is 550 formatted according to the *descriptionContentType* property. 552 4.2.3. descriptionContentType 554 Type: "String" (optional, default:"text/plain") 556 Describes the media type ([RFC6838]) of the contents of the 557 "description" property. Media types MUST be sub-types of type 558 "text", and SHOULD be "text/plain" or "text/html" ([MIME]). They MAY 559 define parameters and the "charset" parameter MUST be "utf-8", if 560 specified. Descriptions of type "text/html" MAY contain "cid" URLs 561 ([RFC2392]) to reference links in the calendar object by use of the 562 *cid* property of the *Link* object. 564 4.2.4. locations 566 Type: "String[Location]" (optional) 568 A map of location ids to Location objects, representing locations 569 associated with the object. A location id may be any valid [RFC6901] 570 JSON pointer and need only be unique to this object; a UUID is a 571 practical choice. 573 A *Location* object has the following properties. It must define at 574 least one other property than *rel*. 576 o *name*: "String" (optional, default:"") The human-readable name of 577 the location. 579 o *description*: "String" (optional) Human-readable, plain-text 580 instructions for accessing this location. This may be an address, 581 set of directions, door access code, etc. 583 o *rel*: "String" (optional) The relation type of this location to 584 the JSCalendar object. 586 This MUST be either one of the following values, registered in a 587 future RFC, or a vendor-specific value. Any value the client or 588 server doesn't understand should be treated the same as if this 589 property is omitted. 591 * "start": The JSCalendar object starts at this location. 593 * "end": The JSCalendar object ends at this location. 595 o *timeZone*: "String" (optional) A time-zone for this location. 597 If omitted, the *timeZone* from the JSCalendar object MUST be 598 presumed when a time-zone is needed in relation to this location. 600 o *coordinates*: "String" (optional) An [RFC5870] "geo:" URI for the 601 location. 603 o *linkIds*: "String[]" (optional) A list of ids for links to 604 alternate representations of this location. 606 For example, an alternative representation could be in vCard 607 format. 609 4.2.5. virtualLocations 611 Type: "String[VirtualLocation]" (optional) 613 A map of ids to VirtualLocation objects, representing virtual 614 locations, such as video conferences or chat rooms, associated with 615 the object. A virtual location id may be any valid [RFC6901] JSON 616 pointer and need only be unique to this object; a UUID is a practical 617 choice. 619 A *VirtualLocation* object has the following properties. 621 o *name*: "String" (optional, default:"") The human-readable name of 622 the virtual location. 624 o *description*: "String" (optional) Human-readable plain-text 625 instructions for accessing this location. This may be an address, 626 set of directions, door access code, etc. 628 o *uri*: "String" A URI that represents how to connect to this 629 virtual location. 631 This may be a telephone number (represented as 632 "tel:+1-555-555-555") for a teleconference, a web address for 633 online chat, or any custom URI. 635 4.2.6. links 637 Type: "String[Link]" (optional) 639 A map of link ids to Link objects, representing external resources 640 associated with the object. A link id may be any valid [RFC6901] 641 JSON pointer and need only be unique to this object; the href or a 642 UUID are practical choices. 644 A *Link* object has the following properties: 646 o *href*: "String" A URI from which the resource may be fetched. 648 This MAY be a "data:" URL, but it is recommended that the file be 649 hosted on a server to avoid embedding arbitrarily large data in 650 JSCalendar object instances. 652 o *cid* "String" (optional) This MUST be a valid "content-id" value 653 according to the definition of section 2 in [RFC2392]. The 654 identifier MUST be unique within this JSCalendar object but has no 655 meaning beyond that. Specifically, it MAY be different from the 656 link identifier in the enclosing *links* property. 658 o *type*: "String" (optional) The content-type [RFC6838] of the 659 resource, if known. 661 o *size*: "Number" (optional) The size, in bytes, of the resource 662 when fully decoded (i.e. the number of bytes in the file the user 663 would download), if known. 665 o *rel*: "String" (optional) Identifies the relation of the linked 666 resource to the object. If set, the value MUST be a registered 667 relation type (see [RFC8288] and IANA Link Relations [1]). 669 Links with a rel of "enclosure" SHOULD be considered by the client 670 as attachments for download. 672 Links with a rel of "describedby" SHOULD be considered by the 673 client to be an alternate representation of the description. 675 Links with a rel of "icon" SHOULD be considered by the client to 676 be an image that it MAY use when presenting the calendar data to a 677 user. The *display* property MAY be set to indicate the purpose 678 of this image. 680 o *display*: "String" (optional) Describes the intended purpose of a 681 link to an image. If set, the *rel* property MUST be set to 682 "icon". The value MUST be either one of the following values, 683 registered in a future RFC, or a vendor-specific value: 685 * "badge": an image inline with the title of the object 687 * "graphic": a full image replacement for the object itself 689 * "fullsize": an image that is used to enhance the object 691 * "thumbnail": a smaller variant of "fullsize " to be used when 692 space for the image is constrained 694 o *title*: "String" (optional) A human-readable plain-text 695 description of the resource. 697 4.2.7. locale 699 Type: "String" (optional) 701 The [RFC5646] language tag that best describes the locale used for 702 the calendar object, if known. 704 4.2.8. keywords 706 Type: "String[Boolean]" (optional) 708 A set of keywords or tags that relate to the object. The set is 709 represented as a map, with the keys being the keywords. The value 710 for each key in the map MUST be "true". 712 4.2.9. categories 714 Type: "String[Boolean]" (optional) 715 A set of categories that relate to the calendar object. The set is 716 represented as a map, with the keys being the categories specified as 717 URIs. The value for each key in the map MUST be "true". 719 In contrast to *keywords*, categories typically are structured. For 720 example, a vendor owning the domain "example.com" might define the 721 categories "http://example.com/categories/sports/american-football"" 722 and "http://example.com/categories/music/r-b". 724 4.2.10. color 726 Type: "String" (optional) 728 Specifies a color clients MAY use when displaying this calendar 729 object. The value is a case-insensitive color name taken from the 730 CSS3 set of names, defined in Section 4.3 of W3C.REC- 731 css3-color-20110607 [2] or a CSS3 RGB color hex value. 733 4.3. Recurrence properties 735 4.3.1. recurrenceRule 737 Type: "Recurrence" 739 Defines a recurrence rule (repeating pattern) for recurring calendar 740 objects. 742 A *Recurrence* object is a JSON object mapping of a RECUR value type 743 in iCalendar, see [RFC5545] and[RFC7529]. A JSEvent recurs by 744 applying the recurrence rule (and *recurrenceOverrides*) to the 745 *start* date/time. A JSTask recurs by applying the recurrence rule 746 (and *recurrenceOverrides*) to its *start* date/time, if defined. If 747 the task does not define a start date-time, it recurs by its *due* 748 date-time. If it neither defines a start or due date-time, it MUST 749 NOT define a *recurrenceRule*. 751 A Recurrence object has the following properties: 753 o *frequency*: "String" This MUST be one of the following values: 755 * "yearly" 757 * "monthly" 759 * "weekly" 761 * "daily" 762 * "hourly" 764 * "minutely" 766 * "secondly" 768 To convert from iCalendar, simply lower-case the FREQ part. 770 o *interval*: "Number"(optional, default:"1") The INTERVAL part from 771 iCal. If included, it MUST be an integer "x >= 1". 773 o *rscale*: "String"(optional, default:""gregorian"") The RSCALE 774 part from iCalendar RSCALE [RFC7529], converted to lower-case. 776 o *skip*: "String"(optional, default:""omit"") The SKIP part from 777 iCalendar RSCALE [RFC7529], converted to lower-case. 779 o *firstDayOfWeek*: "String"(optional, default:""mo"") The WKST part 780 from iCalendar, represented as a lower-case abbreviated two-letter 781 English day of the week. If included, it MUST be one of the 782 following values: ""mo"|"tu"|"we"|"th"|"fr"|"sa"|"su"". 784 o *byDay*: "NDay[]" (optional) An *NDay* object has the following 785 properties: 787 * *day*: "String" The day-of-the-week part of the BYDAY value in 788 iCalendar, lower-cased. MUST be one of the following values: 789 ""mo"|"tu"|"we"|"th"|"fr"|"sa"|"su"". 791 * *nthOfPeriod*: "Number" (optional) The ordinal part of the 792 BYDAY value in iCalendar (e.g. ""+1"" or ""-3""). If present, 793 rather than representing every occurrence of the weekday 794 defined in the *day* property of this *NDay*, it represents 795 only a specific instance within the recurrence period. The 796 value can be positive or negative, but MUST NOT be zero. A 797 negative integer means nth-last of period. 799 o *byMonthDay*: "Number[]" (optional) The BYMONTHDAY part from 800 iCalendar. The array MUST have at least one entry if included. 802 o *byMonth*: "String[]" (optional) The BYMONTH part from iCalendar. 803 Each entry is a string representation of a number, starting from 804 "1" for the first month in the calendar (e.g. ""1" " means 805 ""January"" with Gregorian calendar), with an optional ""L"" 806 suffix (see [RFC7529]) for leap months (this MUST be upper-case, 807 e.g. ""3L""). The array MUST have at least one entry if included. 809 o *byYearDay*: "Number[]"(optional) The BYYEARDAY part from 810 iCalendar. The array MUST have at least one entry if included. 812 o *byWeekNo*: "Number[]"(optional) The BYWEEKNO part from iCalendar. 813 The array MUST have at least one entry if included. 815 o *byHour*: "Number[]"(optional) The BYHOUR part from iCalendar. 816 The array MUST have at least one entry if included. 818 o *byMinute*: "Number[]"(optional) The BYMINUTE part from iCalendar. 819 The array MUST have at least one entry if included. 821 o *bySecond*: "Number[]"(optional) The BYSECOND part from iCalendar. 822 The array MUST have at least one entry if included. 824 o *bySetPosition*: "Number[]"(optional) The BYSETPOS part from 825 iCalendar. The array MUST have at least one entry if included. 827 o *count*: "Number"(optional) The COUNT part from iCalendar. This 828 MUST NOT be included if an *until* property is specified. 830 o *until*: "LocalDate"(optional) The UNTIL part from iCalendar. 831 This MUST NOT be included if a *count* property is specified. 832 Note, as in iCalendar, this date is presumed to be in the time- 833 zone specified in *timeZone*. It is not a UTC time. 835 A recurrence rule specifies a set of set of date-times for recurring 836 calendar objects. A recurrence rule has the following semantics: 838 1. A set of candidates is generated. This is every second within a 839 period defined by the frequency property: 841 * *yearly*: every second from midnight on the 1st January 842 (inclusive) to midnight the following 1st January (exclusive) 844 * *monthly*: every second from midnight on the 1st of a month 845 (inclusive) to midnight on the 1st of the following month 846 (exclusive) 848 * *weekly*: every second from midnight (inclusive) on the first 849 day of the week (as defined by the firstDayOfWeek property, or 850 Monday if omitted), to midnight 7 days later (exclusive). 852 * *daily*: every second from midnight at the start of the day 853 (inclusive) to midnight at the end of the day (exclusive). 855 * *hourly*: every second from the beginning of the hour 856 (inclusive) to the beginning of the next hour (exclusive). 858 * *minutely*: every second from the beginning of the minute 859 (inclusive) to the beginning of the next minute (exclusive). 861 * *secondly*: the second itself, only. 863 2. Each date-time candidate is compared against all of the byX 864 properties of the rule except bySetPosition. If any property in 865 the rule does not match the date-time, it is eliminated. Each 866 byX property is an array; the date-time matches the property if 867 it matches any of the values in the array. The properties have 868 the following semantics: 870 * *byMonth*: the date-time is in the given month. 872 * *byMonthDay*: the date-time is on the given day of the month. 873 Negative numbers mean the nth last day of the month. 875 * *byDay*: the date-time is on the given day of the week. If 876 the day is prefixed by a number, it is the nth occurrence of 877 that day of the week within the month (if frequency is 878 monthly) or year (if frequency is yearly). Negative numbers 879 means nth last occurrence within that period. 881 * *byYearDay*: the date-time is on the nth day of year. 882 Negative numbers mean the nth last day of the year. 884 * *byWeekNo*: the date-time is in the nth week of the year. 885 Negative numbers mean the nth last week of the year. This 886 corresponds to weeks according to week numbering as defined in 887 ISO.8601.2004, with a week defined as a seven day period, 888 starting on the firstDayOfWeek property value or Monday if 889 omitted. Week number one of the calendar year is the first 890 week that contains at least four days in that calendar year. 892 * *byHour*: the date-time has the given hour value. 894 * *byMinute*: the date-time has the given minute value. 896 * *bySecond*: the date-time has the given second value. 898 3. If a bySetPosition property is included, this is now applied to 899 the ordered list of remaining dates (this property specifies the 900 indexes of date-times to keep; all others should be eliminated. 901 Negative numbers are indexes from the end of the list, with -1 902 being the list item). 904 4. Any date-times before the start date of the event are eliminated 905 (see below for why this might be needed). 907 5. If further dates are required (we have not reached the until 908 date, or count limit) skip the next (interval - 1) sets of 909 candidates, then continue from step 1. 911 When determining the set of occurrence dates for an event or task, 912 the following extra rules must be applied: 914 1. The start date-time is always the first occurrence in the 915 expansion (and is counted if the recurrence is limited by a 916 "count" property), even if it would normally not match the rule. 918 2. The first set of candidates to consider is that which would 919 contain the start date-time. This means the first set may 920 include candidates before the start; such candidates are 921 eliminated from the results in step (4) as outlined before. 923 3. The following properties MUST be implicitly added to the rule 924 under the given conditions: 926 * If frequency > "secondly" and no bySecond property: Add a 927 bySecond property with the sole value being the seconds value 928 of the start date-time. 930 * If frequency > "minutely" and no byMinute property: Add a 931 byMinute property with the sole value being the minutes value 932 of the start date-time. 934 * If frequency > "hourly" and no byHour property: Add a byHour 935 property with the sole value being the hours value of the 936 start date-time. 938 * If frequency is "weekly" and no byDay property: Add a byDay 939 property with the sole value being the day-of-the-week of the 940 start date-time. 942 * If frequency is "monthly" and no byDay property and no 943 byMonthDay property: Add a byMonthDay property with the sole 944 value being the day-of-the-month of the start date-time. 946 * If frequency is "yearly" and no byYearDay property: 948 + if there are no byMonth or byWeekNo properties, and either 949 there is a byMonthDay property or there is no byDay 950 property: Add a byMonth property with the sole value being 951 the month of the start date-time. 953 + if there is no byMonthDay, byWeekNo or byDay properties: 954 Add a byMonthDay property with the sole value being the 955 day-of-the-month of the start date-time. 957 + if there is a byWeekNo property and no byMonthDay or byDay 958 properties: Add a byDay property with the sole value being 959 the day-of-the-week of the start date-time. 961 4.3.2. recurrenceOverrides 963 Type: "LocalDate[PatchObject]" (optional) 965 A map of the recurrence-ids (the date-time of the start of the 966 occurrence) to an object of patches to apply to the generated 967 occurrence object. 969 If the recurrence-id does not match an expanded start date from a 970 recurrence rule, it is to be treated as an additional occurrence 971 (like an RDATE from iCalendar). The patch object may often be empty 972 in this case. 974 If the patch object defines the *excluded* property to be "true", 975 then the recurring calendar object does not occur at the recurrence- 976 id date-time (like an EXDATE from iCalendar). Such a patch object 977 MUST NOT patch any other property. 979 By default, an occurrence inherits all properties from the main 980 object except the start (or due) date-time, which is shifted to the 981 new start time of the LocalDate key. However, individual properties 982 of the occurrence can be modified by a patch, or multiple patches. 983 It is valid to patch the start property value, and this patch takes 984 precedence over the LocalDate key. Both the LocalDate key as well as 985 the patched start date-time may occur before the original JSCalendar 986 object's start or due date. 988 A pointer in the PatchObject MUST NOT start with one of the following 989 prefixes; any patch with such a key MUST be ignored: 991 o @type 993 o uid 995 o relatedTo 997 o prodId 999 o method 1000 o isAllDay 1002 o recurrenceRule 1004 o recurrenceOverrides 1006 o replyTo 1008 4.3.3. excluded 1010 Type: "Boolean" (optional, default:"false") 1012 Defines if this object is an overridden, excluded instance of a 1013 recurring JSCalendar object (also see Section 4.3.2). If this 1014 property value is "true", this calendar object instance MUST be 1015 treated as if not existent. 1017 4.4. Sharing and scheduling properties 1019 4.4.1. priority 1021 Type: "Number" (optional, default:"0") 1023 Specifies a priority for the calendar object. This may be used as 1024 part of scheduling systems to help resolve conflicts for a time 1025 period. 1027 The priority is specified as an integer in the range 0 to 9. A value 1028 of 0 specifies an undefined priority. A value of 1 is the highest 1029 priority. A value of 2 is the second highest priority. Subsequent 1030 numbers specify a decreasing ordinal priority. A value of 9 is the 1031 lowest priority. Other integer values are reserved for future use. 1033 4.4.2. freeBusyStatus 1035 Type: "String"(optional, default:"busy") 1037 Specifies how this property should be treated when calculating free- 1038 busy state. The value MUST be one of: 1040 o ""free"": The object should be ignored when calculating whether 1041 the user is busy. 1043 o ""busy"": The object should be included when calculating whether 1044 the user is busy. 1046 4.4.3. privacy 1048 Type: "String"(optional, default:"public") 1050 Calendar objects are normally collected together and may be shared 1051 with other users. The privacy property allows the object owner to 1052 indicate that it should not be shared, or should only have the time 1053 information shared but the details withheld. Enforcement of the 1054 restrictions indicated by this property are up to the 1055 implementations. 1057 This property MUST NOT affect the information sent to scheduled 1058 participants; it is only interpreted when the object is shared as 1059 part of a shared calendar. 1061 The value MUST be either one of the following values, registered in a 1062 future RFC, or a vendor-specific value. Vendor specific values MUST 1063 be prefixed with a domain name controlled by the vendor, e.g. 1064 "example.com/topsecret". Any value the client or server doesn't 1065 understand should be preserved but treated as equivalent to 1066 "private". 1068 o "public": The full details of the object are visible to those whom 1069 the object's calendar is shared with. 1071 o "private": The details of the object are hidden; only the basic 1072 time and metadata is shared. Implementations MUST ensure the 1073 following properties are stripped when the object is accessed by a 1074 sharee: 1076 * title 1078 * description 1080 * locations 1082 * links 1084 * locale 1086 * localizations 1088 * participants 1090 * replyTo 1092 In addition, any patches in "recurrenceOverrides" whose key is 1093 prefixed with one of the above properties MUST be stripped. 1095 o "secret": The object is hidden completely (as though it did not 1096 exist) when the calendar is shared. 1098 4.4.4. replyTo 1100 Type: "String[String]" (optional) 1102 Represents methods by which participants may submit their RSVP 1103 response to the organizer of the calendar object. The keys in the 1104 property value are the available methods. The value is a URI to use 1105 that method. Future methods may be defined in future specifications; 1106 a calendar client MUST ignore any method it does not understand. 1108 The following methods are defined: 1110 o "imip": The organizer accepts an iMIP [RFC6047] response. The 1111 value MUST be a "mailto:" URI. 1113 o "web": There is a web page where the user may submit the RSVP 1114 response using a browser. The value MUST be a "https:" URI 1115 Template ([RFC6570]) in level 1 format. The template MAY contain 1116 variables that MUST be expanded from the JSCalendar object as 1117 defined in table Table 1. Calendar clients SHOULD be prepared to 1118 handle authentication requests from the respective web page and 1119 for the participant email, but this specification does not mandate 1120 any specific mechanism. 1122 +--------------+----------------------------------------------------+ 1123 | Variable | Expand to | 1124 +--------------+----------------------------------------------------+ 1125 | email | The *email* property value of the replying | 1126 | | *Participant* object. | 1127 | | | 1128 | uid | The *uid* property value of the JSCalendar object. | 1129 | | | 1130 | sequence | The *sequence* property value of the JSCalendar | 1131 | | object. | 1132 | | | 1133 | recurrenceId | The recurrence-id when replying for a single | 1134 | | occurrence of a recurring JSCalendar object. The | 1135 | | LocalDate-typed value is the recurrence-id of a | 1136 | | non-overridden recurrence, or the key of a | 1137 | | recurrenceOverride of this JSCalendar object. | 1138 +--------------+----------------------------------------------------+ 1140 Table 1: replyTo URI Template variables 1142 4.4.5. participants 1144 Type: "String[Participant]" (optional) 1146 A map of participant ids to participants, describing their 1147 participation in the calendar object. A participant id may be any 1148 valid [RFC6901] JSON pointer and need only be unique to this calendar 1149 object; the email address of the participant is a good choice. 1151 A *Participant* object has the following properties: 1153 o *name*: "String" The display name of the participant (e.g. "Joe 1154 Bloggs"). 1156 o *email*: "String" The email address for the participant. 1158 o *kind*: "String" (optional) What kind of entity this participant 1159 is, if known. 1161 This MUST be either one of the following values, registered in a 1162 future RFC, or a vendor-specific value. Any value the client or 1163 server doesn't understand should be treated the same as if this 1164 property is omitted. 1166 * "individual": a single person 1168 * "group": a collection of people invited as a whole 1170 * "resource": a non-human resource, e.g. a projector 1172 * "location": a physical location involved in the calendar object 1173 that needs to be scheduled, e.g. a conference room. 1175 o *roles*: "String[]" A list of roles that this participant 1176 fulfills. 1178 At least one value MUST be specified for the participant. This 1179 MUST be either one of the following values, registered in a future 1180 RFC, or a vendor-specific value. Any value the client or server 1181 doesn't understand should be preserved but ignored. 1183 * "owner": The participant is an owner of the object. 1185 * "attendee": The participant is an attendee of the calendar 1186 object. 1188 * "chair": The participant is in charge of the calendar object 1189 when it occurs. 1191 o *locationId*: "String" (optional) The location at which this 1192 participant is expected to be attending. 1194 If the value does not correspond to any location id in the 1195 *locations* property of the instance, this MUST be treated the 1196 same as if the participant's locationId were omitted. 1198 o *rsvpResponse*: "String"(optional, default:"needs-action") The 1199 RSVP response, if any, of this participant. 1201 The value MUST be either one of the following values, registered 1202 in a future RFC, or a vendor-specific value: 1204 * "needs-action": No status yet set by the participant. 1206 * "accepted": The invited participant will participate. 1208 * "declined": The invited participant will not participate. 1210 * "tentative": The invited participant may participate. 1212 o *participation*: "String"(optional, default:"required") The 1213 required participation of this participant. 1215 The value MUST be either one of the following values, registered 1216 in a future RFC, or a vendor-specific value. Any value the client 1217 or server doesn't understand should be treated the same as 1218 "required". 1220 * "non-participant": Indicates a participant who is copied for 1221 information purposes only. 1223 * "optional": Indicates a participant whose participation is 1224 optional. 1226 * "required": Indicates a participant whose participation is 1227 required. 1229 o *rsvpWanted*: "Boolean"(optional, default:"false") If true, the 1230 organizer is expecting the participant to notify them of their 1231 status. 1233 o *scheduleSequence*: "Number"(optional, default:"0") The sequence 1234 number of the last response from the participant. If defined, 1235 this MUST be a non-negative integer. 1237 This can be used to determine whether the participant has sent a 1238 new RSVP following significant changes to the calendar object, and 1239 to determine if future responses are responding to a current or 1240 older view of the data. 1242 o *scheduleUpdated*: "UTCDate" (optional) The *updated* property of 1243 the last iMIP response from the participant. 1245 This can be compared to the *updated* timestamp in future iMIP 1246 responses to determine if the response is older or newer than the 1247 current data. 1249 o *invitedBy*: "String" (optional) The participant id of the 1250 participant who invited this one, if known. 1252 o *delegatedTo*: "String[]" (optional) A list of participant ids of 1253 participants that this participant has delegated their 1254 participation to. This MUST be omitted if none (rather than an 1255 empty array). 1257 o *delegatedFrom*: "String[]" (optional) A list of participant ids 1258 that this participant is acting as a delegate for. This MUST be 1259 omitted if none (rather than an empty array). 1261 o *memberOf*: "String[]" (optional) A list of group participants 1262 that were invited to this calendar object, which caused this 1263 participant to be invited due to their membership of the group(s). 1264 This MUST be omitted if none (rather than an empty array). 1266 o *linkIds*: "String[]" (optional) Links to more information about 1267 this participant, for example in vCard format. 1269 4.5. Alerts properties 1271 4.5.1. useDefaultAlerts 1273 Type: "Boolean" (optional, default:"false") 1275 If "true", use the user's default alerts and ignore the value of the 1276 *alerts* property. Fetching user defaults is dependent on the API 1277 from which this JSCalendar object is being fetched, and is not 1278 defined in this specification. If an implementation cannot determine 1279 the user's default alerts, or none are set, it MUST process the 1280 alerts property as if useDefaultAlerts is set to "false". 1282 4.5.2. alerts 1284 Type: "String[Alert]" (optional) 1285 A map of alert ids to Alert objects, representing alerts/reminders to 1286 display or send the user for this calendar object. An alert id may 1287 be any valid [RFC6901] JSON pointer and need only be unique to this 1288 calendar object; a globally unique id is a practical choice (also see 1289 Section 4.1.2)). 1291 An *Alert* Object has the following properties: 1293 o *relativeTo*: "String" (optional, default:"before-start") 1294 Specifies where the offset is relative to for the alarm to 1295 trigger. The value MUST be one of: 1297 * "before-start" 1299 * "after-start" 1301 * "before-end" 1303 * "after-end" 1305 o *offset*: "Duration" The offset from the start and end/due of the 1306 calendar object to fire the alert. If the calendar object does 1307 not define a time-zone, the user's default time-zone SHOULD be 1308 used when determining the offset, if known. Otherwise, the time- 1309 zone to use is implementation specific. 1311 o *acknowledged*: "UTCDate" (optional) 1313 When the user has permanently dismissed the alert the client MUST 1314 set this to the current time in UTC. Other clients which sync 1315 this property can then automatically dismiss or suppress duplicate 1316 alerts (alerts with the same alert id that triggered on or before 1317 this date-time). 1319 For a recurring calendar object, the *acknowledged* property of 1320 the parent object MUST be updated, unless the alert is already 1321 overridden in *recurrenceOverrides*. 1323 o *snoozed*: "UTCDate" (optional) 1325 If the user temporarily dismisses the alert, this is the UTC date- 1326 time after which it should trigger again. Setting this property 1327 on an instance of a recurring calendar object MUST update the 1328 alarm on the master object, unless the respective instance already 1329 is defined in "recurrenceOverrides". It MUST NOT generate an 1330 override for the sole use of snoozing an alarm. 1332 o *action*: "String" (optional, default:"display") Describes how to 1333 alert the user. 1335 The value MUST be at most one of the following values, registered 1336 in a future RFC, or a vendor-specific value: 1338 * "display": The alert should be displayed as appropriate for the 1339 current device and user context. 1341 * "email": The alert should trigger an email sent out to the 1342 user, notifying about the alert. This action is typically only 1343 appropriate for server implementations. 1345 4.6. Multilingual properties 1347 4.6.1. localizations 1349 Type: "String[PatchObject]" (optional) 1351 A map of [RFC5646] language tags to patch objects, which localize the 1352 calendar object into the locale of the respective language tag. 1354 See the description of PatchObject (Section 3.2.4) for the structure 1355 of the PatchObject. The patches are applied to the top-level object. 1356 In addition to all the restrictions on patches specified there, the 1357 pointer also MUST NOT start with one of the following prefixes; any 1358 patch with a such a key MUST be ignored: 1360 o @type 1362 o due 1364 o duration 1366 o freeBusyStatus 1368 o localization 1370 o method 1372 o participants 1374 o prodId 1376 o progress 1378 o relatedTo 1379 o sequence 1381 o start 1383 o status 1385 o timeZone 1387 o uid 1389 o useDefaultAlerts 1391 Note that this specification does not define how to maintain validity 1392 of localized content. For example, a client application changing a 1393 JSCalendar object's title property might also need to update any 1394 localizations of this property. Client implementations SHOULD 1395 provide the means to manage localizations, but how to achieve this is 1396 specific to the application's workflow and requirements. 1398 5. Type-specific JSCalendar properties 1400 5.1. JSEvent properties 1402 In addition to the common JSCalendar object properties (Section 4) a 1403 JSEvent has the following properties: 1405 5.1.1. start 1407 Type: "LocalDate" e.g. "2015-09-02T00:00:00" 1409 The date/time the event would start in the event's time-zone. 1411 A valid JSEvent MUST include this property. 1413 5.1.2. timeZone 1415 Type: "String|null" (optional, default:"null") 1417 The IANA Time Zone Database [3] name for the time-zone the event is 1418 scheduled in, or "null" for floating time. If omitted, this MUST be 1419 presumed to be "null" (i.e. floating time). 1421 5.1.3. duration 1423 Type: "Duration", e.g. "P2DT3H" (optional, default: "P0D") 1425 The zero or positive duration of the event in absolute time (i.e. in 1426 UTC time; ignoring DST shifts). To get the end date in the event 1427 time-zone, convert start into UTC, then add the duration, then 1428 convert the result into the appropriate time-zone. 1430 A JSEvent MAY be end in a different time-zone (e.g. a plane flight 1431 crossing time-zones). In this case, the JSEvent MUST specify the end 1432 time-zone in a *location* property value that defines its *rel* to be 1433 "end" and the end time-zone in its *timeZone* property. 1435 5.1.4. isAllDay 1437 Type: "Boolean" (optional, default:"false") 1439 Specifies if the event an all day event, such as a birthday or public 1440 holiday. 1442 If *isAllDay* is true, then the following restrictions apply: 1444 o the *start* property MUST have a time component of "T00:00:00". 1446 o the *duration* property MUST only include a day component. 1448 Note that all-day events MAY be bound to a specific time-zone, as 1449 defined by the *timeZone* property. 1451 5.1.5. status 1453 Type: "String" (optional, default:"confirmed") 1455 The scheduling status (Section 4.4) of a JSEvent. If set, it MUST be 1456 one of: 1458 o "confirmed": Indicates the event is definite. 1460 o "cancelled": Indicates the event is cancelled. 1462 o "tentative": Indicates the event is tentative. 1464 5.2. JSTask properties 1466 In addition to the common JSCalendar object properties (Section 4) a 1467 JSTask has the following properties: 1469 5.2.1. due 1471 Type: "LocalDate" (optional) e.g. "2015-09-02T00:00:00" 1473 The date/time the task is due in the task's time-zone. 1475 5.2.2. start 1477 Type: "LocalDate" (optional) e.g. "2015-09-02T00:00:00" 1479 The date/time the task should start in the task's time-zone. 1481 5.2.3. timeZone 1483 Type: "String|null" (optional, default:"null") 1485 The IANA Time Zone Database name for the time-zone the task is 1486 scheduled in, or "null" for floating time. If omitted, this MUST be 1487 presumed to be "null" (i.e. floating time). 1489 5.2.4. estimatedDuration 1491 Type: "Duration" (optional), e.g. "P2DT3H" 1493 Specifies the estimated positive duration of time the task takes to 1494 complete. 1496 5.2.5. statusUpdatedAt 1498 Type: "UTCDate" (optional), e.g. "2016-06-13T12:00:00Z" 1500 Specifies the date/time the task status properties was last updated. 1502 If the task is recurring and has future instances, a client may want 1503 to keep track of the last status update timestamp of a specific task 1504 recurrence, but leave other instances unchanged. One way to achieve 1505 this is by overriding the statusUpdatedAt property in the task 1506 *recurrenceOverrides*. However, this could produce a long list of 1507 timestamps for regularly recurring tasks. An alternative approach is 1508 to split the JSTask into a current, single instance of JSTask with 1509 this instance status update time and a future recurring instance. 1510 Also see the definition of the *relatedTo* on splitting. 1512 5.2.6. isAllDay 1514 Type: "Boolean" (optional, default:"false") 1516 Specifies if the task is an all day task. 1518 If *isAllDay* is true, then the *start* and *due* properties MUST 1519 have a time component of "T00:00:00". Note that the 1520 *estimatedDuration* property MAY contain a non-zero time duration. 1521 All-day tasks MAY be bound to a specific time-zone, as defined by the 1522 *timeZone* property. 1524 5.2.7. progress 1526 In addition to the common properties of a *Participant* object 1527 (Section 4.4.5), a Participant within a JSTask supports the following 1528 property: 1530 o *progress*: "ParticipantProgress" (optional) The progress of the 1531 participant for this task, if known. This property MUST NOT be 1532 set if the *rsvpResponse* of this participant is any other value 1533 but "accepted". 1535 A *ParticipantProgress* object has the following properties: 1537 o *status*: "String" Describes the completion status of the 1538 participant's progress. 1540 The value MUST be at most one of the following values, registered 1541 in a future RFC, or a vendor-specific value: 1543 * "completed": The participant completed their progress. 1545 * "in-process": The participant processes this task. 1547 * "failed": The participant failed to complete their progress. 1549 o *timestamp*: "UTCDate" Describes the last time when the 1550 participant progress got updated. 1552 5.2.8. status 1554 Type: "String" 1556 Defines the overall status of this task. If omitted, the default 1557 status (Section 4.4) of a JSTask is defined as follows (in order of 1558 evaluation): 1560 o "completed": if all the *ParticipantProgress* status of the task 1561 participants is "completed". 1563 o "failed": if at least one *ParticipantProgress* status of the task 1564 participants is "failed". 1566 o "in-process": if at least one *ParticipantProgress* status of the 1567 task participants is "in-process". 1569 o "needs-action": If none of the other criteria match. 1571 If set, it MUST be one of: 1573 o "needs-action": Indicates the task needs action. 1575 o "completed": Indicates the task is completed. 1577 o "in-process": Indicates the task is in process. 1579 o "cancelled": Indicates the task is cancelled. 1581 o "pending": Indicates the task has been created and accepted for 1582 processing, but not yet started. 1584 o "failed": Indicates the task failed. 1586 5.3. JSGroup properties 1588 JSGroup supports the following JSCalendar properties (Section 4): 1590 o @type 1592 o uid 1594 o created 1596 o updated 1598 o categories 1600 o keywords 1602 o name 1604 o description 1606 o color 1608 o links 1610 as well as the following JSGroup-specific properties: 1612 5.3.1. entries 1614 Type: "String[JSTask|JSEvent]" 1616 A collection of group members. This is represented as a map of the 1617 *uid* property value to the JSCalendar object member having that uid. 1618 Implementations MUST ignore entries of unknown type. 1620 5.3.2. source 1622 Type: "String" (optional) 1624 The source from which updated versions of this group may be retrieved 1625 from. The value MUST be a URI. 1627 6. Conversion from and to iCalendar 1629 This section specifies which JSCalendar properties can be mapped from 1630 and to iCalendar format. Implementations SHOULD follow these 1631 conversion guidelines. Still, JSCalendar does not restrict itself to 1632 iCalendar and conversion between these two formats MAY be lossy. 1634 6.1. JSEvent 1636 The iCalendar counterpart to *JSEvent* is the VEVENT component type 1637 [RFC5545]. A VEVENT component that is a direct child of a VCALENDAR 1638 component is equivalent to a standalone JSEvent. A VEVENT component 1639 *within* a VEVENT maps to the entries of the JSEvent 1640 *recurrenceOverrides* property. 1642 +----------+--------------------------------------------------------+ 1643 | Property | iCalendar counterpart | 1644 +----------+--------------------------------------------------------+ 1645 | isAllDay | True, if the type of the DTSTART property in iCalendar | 1646 | | is DATE. When translating from JSCalendar the | 1647 | | iCalendar DTSTART property is of DATE value type, if | 1648 | | the *isAllDay* property is set to true and the | 1649 | | *timeZone* property is null. | 1650 | | | 1651 | start | Corresponds to the DTSTART property in iCalendar. Note | 1652 | | that time-zone information is stored separately in | 1653 | | JSEvent. | 1654 | | | 1655 | timeZone | Corresponds to the TZID part of the DTSTART property | 1656 | | in iCalendar. If the event has a different end time- | 1657 | | zone to start time-zone, this should be added as a | 1658 | | JSCalendar *location* with just a *timeZone* property | 1659 | | and "rel="end"". | 1660 | | | 1661 | duration | Corresponds to the DURATION or DSTART+DTEND properties | 1662 | | in iCalendar. | 1663 +----------+--------------------------------------------------------+ 1665 Table 2: Translation between JSEvent and iCalendar 1667 6.2. JSTask 1669 The iCalendar counterpart to *JSTask* is the VTODO component type 1670 [RFC5545]. A VTODO component that is a direct child of a VCALENDAR 1671 component is equivalent to a standalone JSTask. A VTODO component 1672 *within* a master VTODO maps to the entries of the JSTask 1673 *recurrenceOverrides* property. 1675 +-------------------+-----------------------------------------------+ 1676 | Property | iCalendar counterpart | 1677 +-------------------+-----------------------------------------------+ 1678 | isAllDay | True, if the type of the DTSTART property in | 1679 | | iCalendar is DATE. When translating from | 1680 | | JSCalendar the iCalendar DTSTART property is | 1681 | | of DATE value type, if the *isAllDay* | 1682 | | property is set to true and the *timeZone* | 1683 | | property is null. | 1684 | | | 1685 | due | Corresponds to the DUE and DTSTART+DURATION | 1686 | | properties in iCalendar. When mapping | 1687 | | iCalendar VTODOs with DTSTART+DURATION, the | 1688 | | due date is the result of adding DURATION to | 1689 | | DTSTART in the DTSTART time-zone. | 1690 | | | 1691 | start | Corresponds to the DTSTART property in | 1692 | | iCalendar. | 1693 | | | 1694 | timeZone | Corresponds to the TZID part of the | 1695 | | DTSTART/DUE properties in iCalendar. If the | 1696 | | task has a different end time-zone to start | 1697 | | or due time-zone, this should be added as a | 1698 | | JSCalendar *location* with just a *timeZone* | 1699 | | property and "rel="end"". | 1700 | | | 1701 | estimatedDuration | Corresponds to the ESTIMATED-DURATION | 1702 | | iCalendar property in the RFC draft | 1703 | | [draft-apthorp-ical-tasks]. | 1704 | | | 1705 | statusUpdatedAt | Maps to the COMPLETED iCalendar property. The | 1706 | | JSTask status property MUST have value | 1707 | | "completed". | 1708 | | | 1709 | progress | Corresponds to the PARTSTAT and COMPLETED | 1710 | | properties in iCalendar, including the | 1711 | | definitions in the RFC draft | 1712 | | [draft-apthorp-ical-tasks]. | 1713 | | | 1714 | status | Corresponds to the STATUS property in | 1715 | | iCalendar, including the definitions in the | 1716 | | RFC draft [draft-apthorp-ical-tasks]. | 1717 +-------------------+-----------------------------------------------+ 1719 Table 3: Translation between JSTask and iCalendar 1721 6.3. JSGroup 1723 A JSGroup converts to a iCalendar VCALENDAR containing VEVENT or 1724 VTODO components. 1726 +----------+--------------------------------------------------------+ 1727 | Property | iCalendar counterpart | 1728 +----------+--------------------------------------------------------+ 1729 | entries | The VEVENT and VTODO components within a top-level | 1730 | | VCALENDAR component. | 1731 | | | 1732 | source | Corresponds to the SOURCE property in iCalendar. | 1733 +----------+--------------------------------------------------------+ 1735 Table 4: Translation between JSGroup and iCalendar 1737 6.4. Common properties 1739 +------------------------+------------------------------------------+ 1740 | Property | iCalendar counterpart | 1741 +------------------------+------------------------------------------+ 1742 | alerts | An *Alert* corresponds to the VALARM | 1743 | | component in iCalendar, where the | 1744 | | *action* is determined by the iCalendar | 1745 | | ACTION property value (e.g., both | 1746 | | "DISPLAY" and "AUDIO" actions map to a | 1747 | | JSCalendar *display* action, and | 1748 | | similarly for "EMAIL"). The | 1749 | | *relativeTo* and *offset* properties | 1750 | | corresponds to the iCalendar TRIGGER | 1751 | | property. | 1752 | | | 1753 | categories | Corresponds to the CONCEPT property in | 1754 | | iCalendar, see in the RFC draft | 1755 | | [draft-ietf-calext-ical-relations]. | 1756 | | | 1757 | color | Corresponds to the COLOR property in | 1758 | | iCalendar, as specified in [RFC7986]. | 1759 | | | 1760 | created | Corresponds to the CREATED property in | 1761 | | iCalendar. | 1762 | | | 1763 | description | Corresponds to the DESCRIPTION property | 1764 | | and its ALTREP parameters in iCalendar. | 1765 | | | 1766 | descriptionContentType | Implementation-specific. | 1767 | | | 1768 | freeBusyStatus | Corresponds to the TRANSP property in | 1769 | | iCalendar. | 1770 | | | 1771 | keywords | Corresponds to the CATEGORIES property | 1772 | | in iCalendar, as specified in [RFC7986]. | 1773 | | | 1774 | links | Corresponds to the ATTACH ([RFC5545]) or | 1775 | | IMAGE ([RFC7986]) properties with a URI | 1776 | | value type set to the link "href". | 1777 | | ([RFC7986]). The *type* property | 1778 | | corresponds to the FMTTYPE parameter, | 1779 | | the *size* property to the SIZE | 1780 | | parameter. Mapping all other properties | 1781 | | is implementation-specific. | 1782 | | | 1783 | locale | Corresponds to the LANGUAGE parameter in | 1784 | | iCalendar, which is added to individual | 1785 | | properties. When converting from | 1786 | | iCalendar, one language must be picked | 1787 | | as the main locale for the object, and | 1788 | | all properties in other languages moved | 1789 | | to the localizations JSEvent property. | 1790 | | | 1791 | localizations | Implementation-specific. | 1792 | | | 1793 | locations | See Section 6.5. | 1794 | | | 1795 | method | Corresponds to the METHOD property of | 1796 | | the embedding VCALENDAR in iCalendar. | 1797 | | | 1798 | participants | See Section 6.5. | 1799 | | | 1800 | priority | Corresponds to the PRIORITY property in | 1801 | | iCalendar. | 1802 | | | 1803 | privacy | Corresponds to the CLASS property in | 1804 | | iCalendar. | 1805 | | | 1806 | prodId | Corresponds to the PRODID property in | 1807 | | iCalendar. | 1808 | | | 1809 | recurrenceOverrides | Corresponds to the RDATE and EXDATE | 1810 | | properties in iCalendar, plus VEVENT | 1811 | | (for JSEvent) or VTODO (for JSTask) | 1812 | | instances with a recurrence-id. | 1813 | | | 1814 | recurrenceRule | Corresponds to the RRULE property in | 1815 | | iCalendar. See the property definition | 1816 | | at section Section 4.3.1 how to map a | 1817 | | RRULE value. | 1818 | | | 1819 | relatedTo | Corresponds to the RELATED-TO property | 1820 | | in iCalendar. | 1821 | | | 1822 | replyTo | An iCalendar ORGANIZER with one of the | 1823 | | mapped URIs as value. If URIs are | 1824 | | defined for both the "imip" and "web" | 1825 | | type, it is recommended to map the | 1826 | | "imip" value to the calendar address | 1827 | | value of the ORGANIZER. | 1828 | | | 1829 | sequence | Corresponds to the SEQUENCE property in | 1830 | | iCalendar. | 1831 | | | 1832 | status | Corresponds to the STATUS property in | 1833 | | iCalendar (converted to lower-case). | 1834 | | | 1835 | title | Corresponds to the SUMMARY property in | 1836 | | iCalendar. | 1837 | | | 1838 | uid | Corresponds to the UID property in | 1839 | | iCalendar. | 1840 | | | 1841 | updated | Corresponds to the DTSTAMP and LAST- | 1842 | | MODIFIED properties in iCalendar. (These | 1843 | | are only different in the iTIP case, and | 1844 | | the difference is not actually useful.) | 1845 +------------------------+------------------------------------------+ 1847 Table 5: Translation between JSCalendar and iCalendar 1849 6.5. Locations and participants 1851 Both JSCalendar participants and locations have counterparts in 1852 iCalendar but provide richer representation. 1854 The following table outlines translation of JSCalendar participants. 1855 Where iCalendar has distinct properties for ORGANIZER and ATTENDEE, 1856 these are merged in JSCalendar into the Participant object type. 1858 +--------------------------------------------------+----------------+ 1859 | Property | iCalendar | 1860 | | counterpart | 1861 +--------------------------------------------------+----------------+ 1862 | delegatedFrom | the DELEGATED- | 1863 | | FROM parameter | 1864 | | | 1865 | delegatedTo | email | 1866 | | | 1867 | the value of the ORGANIZER or ATTENDEE property | kind | 1868 | | | 1869 | the CUTYPE parameter | linkIds | 1870 | | | 1871 | Implementation-specific. | locationId | 1872 | | | 1873 | Implementation-specific. When mapping from | memberOf | 1874 | iCalendar to JSCalendar this may be the | | 1875 | JSCalendar identifier of a CONFERENCE property | | 1876 | that has the MODERATOR feature defined in its | | 1877 | FEATURE parameter values. If multiple such | | 1878 | CONFERENCE properties are defined in iCalendar, | | 1879 | then the one with the most interactive features | | 1880 | is chosen. | | 1881 | | | 1882 | the MEMBER parameter | name | 1883 | | | 1884 | the CN parameter | participation | 1885 | | | 1886 | Maps to the standard iCalendar ROLE parameter | roles | 1887 | values REQ-PARTICIPANT, OPT-PARTICIPANT and NON- | | 1888 | PARTICIPANT. | | 1889 | | | 1890 | The "chair" role maps to the standard iCalendar | rsvpResponse | 1891 | ROLE parameter value "chair", with an implicit | | 1892 | participant of value "required". The mapping of | | 1893 | non-required chairs and other roles is | | 1894 | implementation-specific, but using "x-name" | | 1895 | parameter values is recommended. | | 1896 | | | 1897 | the PARTSTAT parameter | the DELEGATED- | 1898 | | TO parameter | 1899 | | | 1900 | scheduleSequence | the SEQUENCE | 1901 | | property of | 1902 | | the | 1903 | | participant's | 1904 | | latest iMIP | 1905 | | message | 1906 | | | 1907 | scheduleUpdated | the DTSTAMP | 1908 | | property of | 1909 | | the | 1910 | | participant's | 1911 | | latest iMIP | 1912 | | message | 1913 +--------------------------------------------------+----------------+ 1915 Table 6: Translation of Participant between JSCalendar and iCalendar 1917 The iCalendar counterpart for JSCalendar Location objects is the 1918 iCalendar [RFC5545] LOCATION property, or implementation-specific. 1920 +-------------+-----------------------------------------------------+ 1921 | Property | iCalendar counterpart | 1922 +-------------+-----------------------------------------------------+ 1923 | name | Corresponds to the LOCATION property value. | 1924 | | | 1925 | description | Implementation-specific. | 1926 | | | 1927 | rel | Implementation-specific. | 1928 | | | 1929 | timeZone | Implementation-specific. | 1930 | | | 1931 | coordinates | Implementation-specific. Consider using a GEO | 1932 | | iCalendar property, along with one LOCATION. | 1933 | | | 1934 | uri | Corresponds to the LOCATION ALTREP parameter. | 1935 | | | 1936 | linkIds | Implementation-specific. | 1937 +-------------+-----------------------------------------------------+ 1939 Table 7: Translation of Location between JSCalendar and iCalendar 1941 The iCalendar counterpart for JSCalendar VirtualLocation objects is 1942 the iCalendar [RFC7986] CONFERENCE property, or implementation- 1943 specific. 1945 +--------------+--------------------------------------------------+ 1946 | Property | iCalendar counterpart | 1947 +--------------+--------------------------------------------------+ 1948 | name | Corresponds to the CONFERENCE LABEL parameter. | 1949 | | | 1950 | description | Implementation-specific. | 1951 | | | 1952 | uri | Corresponds to the CONFERENCE property value. | 1953 +--------------+--------------------------------------------------+ 1955 Table 8: Translation of VirtualLocation between JSCalendar and 1956 iCalendar 1958 6.6. Unknown properties 1960 Both JSCalendar and iCalendar calendar objects may contain properties 1961 that are not expressible in the other format. This specification 1962 does not mandate how to preserve these properties. Instead, it 1963 leaves negotiation on how to treat unknown properties to client and 1964 server implementations and their protocol used to exchange calendar 1965 objects. 1967 Two notable options to represent and preserve arbitrary iCalendar 1968 object properties in JSCalendar are: 1970 o *JCal*: Define iCalendar properties in JCal format ([RFC7265]) in 1971 a vendor-specific property of the JCalendar object. The JCal- 1972 formatted value may either only contain iCalendar properties that 1973 were not mapped to JSCalendar properties, or contain the complete 1974 iCalendar object representation. 1976 o *Alternate link*: Define an alternate link (Section 4.2.6) value 1977 pointing to the iCalendar representation of the JSCalendar object. 1978 E.g. the alternative representation of a VEVENT would be 1979 represented as a link with rel "alternate" and type "text/ 1980 calendar;component=VEVENT". 1982 7. JSCalendar object examples 1984 The following examples illustrate several aspects of the JSCalendar 1985 data model and format. The examples may omit mandatory or additional 1986 properties, which is indicated by a placeholder property with key 1987 "...". While most of the examples use calendar event objects, they 1988 are also illustrative for tasks. 1990 7.1. Simple event 1992 This example illustrates a simple one-time event. It specifies a 1993 one-time event that begins on January 15, 2018 at 1pm New York local 1994 time and ends after 1 hour. 1996 { 1997 "@type": "jsevent", 1998 "uid": "2a358cee-6489-4f14-a57f-c104db4dc2f1", 1999 "updated": "2018-01-15T18:00:00Z", 2000 "title": "Some event", 2001 "start": "2018-01-15T13:00:00", 2002 "timeZone": "America/New_York", 2003 "duration": "PT1H" 2004 } 2006 7.2. Simple task 2008 This example illustrates a simple task for a plain to-do item. 2010 { 2011 "@type": "jstask", 2012 "uid": "2a358cee-6489-4f14-a57f-c104db4dc2f2", 2013 "updated": "2018-01-15T18:00:00Z", 2014 "title": "Do something" 2015 } 2017 7.3. Simple group 2019 This example illustrates a simple calendar object group that contains 2020 an event and a task. 2022 { 2023 "@type": "jsgroup", 2024 "uid": "2a358cee-6489-4f14-a57f-c104db4dc343", 2025 "updated": "2018-01-15T18:00:00Z", 2026 "name": "A simple group", 2027 "entries": [ 2028 { 2029 "@type": "jsevent", 2030 "uid": "2a358cee-6489-4f14-a57f-c104db4dc2f1", 2031 "updated": "2018-01-15T18:00:00Z", 2032 "title": "Some event", 2033 "start": "2018-01-15T13:00:00", 2034 "timeZone": "America/New_York", 2035 "duration": "PT1H" 2036 }, 2037 { 2038 "@type": "jstask", 2039 "uid": "2a358cee-6489-4f14-a57f-c104db4dc2f2", 2040 "updated": "2018-01-15T18:00:00Z", 2041 "title": "Do something" 2042 } 2043 ] 2044 } 2046 7.4. All-day event 2048 This example illustrates an event for an international holiday. It 2049 specifies an all-day event on April 1 that occurs every year since 2050 the year 1900. 2052 { 2053 "...": "", 2054 "title": "April Fool's Day", 2055 "isAllDay": true, 2056 "start": "1900-04-01T00:00:00", 2057 "duration": "P1D", 2058 "recurrenceRule": { 2059 "frequency": "yearly" 2060 } 2061 } 2063 7.5. Task with a due date 2065 This example illustrates a task with a due date. It is a reminder to 2066 buy groceries before 6pm Vienna local time on January 19, 2018. The 2067 calendar user expects to need 1 hour for shopping. 2069 { 2070 "...": "", 2071 "title": "Buy groceries", 2072 "due": "2018-01-19T18:00:00", 2073 "timeZone": "Europe/Vienna", 2074 "estimatedDuration": "PT1H" 2075 } 2077 7.6. Event with end time-zone 2079 This example illustrates the use of end time-zones by use of an 2080 international flight. The flight starts on April 1, 2018 at 9am in 2081 Berlin local time. The duration of the flight is scheduled at 10 2082 hours 30 minutes. The time at the flights destination is in the same 2083 time-zone as Tokyo. Calendar clients could use the end time-zone to 2084 display the arrival time in Tokyo local time and highlight the time- 2085 zone difference of the flight. 2087 { 2088 "...": "", 2089 "title": "Flight XY51 from FRA to NRT", 2090 "start": "2018-04-01T09:00:00", 2091 "timeZone": "Europe/Berlin", 2092 "duration": "PT10H30M", 2093 "locations": { 2094 "2a358cee-6489-4f14-a57f-c104db4dc2f1": { 2095 "rel": "end", 2096 "timeZone": "Asia/Tokyo" 2097 } 2098 } 2099 } 2101 7.7. Floating-time event (with recurrence) 2103 This example illustrates the use of floating-time. Since January 1, 2104 2018, a calendar user blocks 30 minutes every day to practice Yoga at 2105 7am local time, in whatever time-zone the user is located on that 2106 date. 2108 { 2109 "...": "", 2110 "title": "Yoga", 2111 "start": "2018-01-01T07:00:00", 2112 "duration": "PT30M", 2113 "recurrenceRule": { 2114 "frequency": "daily" 2115 } 2116 } 2118 7.8. Event with multiple locations and localization 2120 This example illustrates an event that happens at both a physical and 2121 a virtual location. Fans can see a live convert on premises or 2122 online. The event title and descriptions are localized. (Note: the 2123 localization of the event description contains an UTF-8 encoded 2124 German Umlaut. This character may have been replaced with ASCII 2125 characters in the plain-text rendering of this RFC document) 2126 { 2127 "...": "", 2128 "title": "Live from Music Bowl: The Band", 2129 "description": "Go see the biggest music event ever!", 2130 "locale": "en", 2131 "start": "2018-07-04T17:00:00", 2132 "timeZone": "America/New_York", 2133 "duration": "PT3H", 2134 "locations": { 2135 "c0503d30-8c50-4372-87b5-7657e8e0fedd": { 2136 "name": "The Music Bowl", 2137 "description": "Music Bowl, Central Park, New York", 2138 "coordinates": "geo:40.7829,73.9654" 2139 } 2140 }, 2141 "virtualLocations": { 2142 "6f3696c6-1e07-47d0-9ce1-f50014b0041a": { 2143 "name": "Free live Stream from Music Bowl", 2144 "uri": "https://stream.example.com/the_band_2018" 2145 } 2146 }, 2147 "localizations": { 2148 "de": { 2149 "title": "Live von der Music Bowl: The Band!", 2150 "description": "Schau dir das groesste Musikereignis an!", 2151 "virtualLocations/6f3696c6-1e07-47d0-9ce1-f50014b0041a/name": 2152 "Gratis Live-Stream aus der Music Bowl" 2153 } 2154 } 2155 } 2157 7.9. Recurring event with overrides 2159 This example illustrates the use of recurrence overrides. A math 2160 course at a University is held for the first time on January 8, 2018 2161 at 9am London time and occurs every week until June 25, 2018. Each 2162 lecture lasts for one hour and 30 minutes and is located at the 2163 Mathematics department. This event has exceptional occurrences: at 2164 the last occurrence of the course is an exam, which lasts for 2 hours 2165 and starts at 10am. Also, the location of the exam differs from the 2166 usual location. On April 2 no course is held. On January 5 at 2pm 2167 is an optional introduction course, that occurs before the first 2168 regular lecture. 2170 { 2171 "...": "", 2172 "title": "Calculus I", 2173 "start": "2018-01-08T09:00:00", 2174 "timeZone": "Europe/London", 2175 "duration": "PT1H30M", 2176 "locations": { 2177 "2a358cee-6489-4f14-a57f-c104db4dc2f1": { 2178 "title": "Math lab room 1", 2179 "description": "Math Lab I, Department of Mathematics" 2180 } 2181 }, 2182 "recurrenceRule": { 2183 "frequency": "weekly", 2184 "until": "2018-06-25T09:00:00" 2185 }, 2186 "recurrenceOverrides": { 2187 "2018-01-05T14:00:00": { 2188 "title": "Introduction to Calculus I (optional)" 2189 }, 2190 "2018-04-02T09:00:00": { 2191 "excluded": "true" 2192 }, 2193 "2018-06-25T09:00:00": { 2194 "title": "Calculus I Exam", 2195 "start": "2018-06-25T10:00:00", 2196 "duration": "PT2H", 2197 "locations": { 2198 "2a358cee-6489-4f14-a57f-c104db4dc2f1": { 2199 "title": "Big Auditorium", 2200 "description": "Big Auditorium, Other Road" 2201 } 2202 } 2203 } 2204 } 2205 } 2207 7.10. Recurring event with participants 2209 This example illustrates scheduled events. A team meeting occurs 2210 every week since January 8, 2018 at 9am Johannesburg time. The event 2211 owner also chairs the event. Participants meet in a virtual meeting 2212 room. An attendee has accepted the invitation, but on March 8, 2018 2213 he is unavailable and declined participation for this occurrence. 2215 { 2216 "...": "", 2217 "title": "FooBar team meeting", 2218 "start": "2018-01-08T09:00:00", 2219 "timeZone": "Africa/Johannesburg", 2220 "duration": "PT1H", 2221 "locations": { 2222 "2a358cee-6489-4f14-a57f-c104db4dc2f1": { 2223 "title": "ChatMe meeting room", 2224 "rel": "virtual", 2225 "features": [ 2226 "audio", 2227 "chat", 2228 "video" 2229 ], 2230 "uri": "https://chatme.example.com?id=1234567" 2231 } 2232 }, 2233 "recurrenceRule": { 2234 "frequency": "weekly" 2235 }, 2236 "replyTo": { 2237 "imip": "zoe@foobar.example.com" 2238 }, 2239 "participants": { 2240 "tom@foobar.example.com": { 2241 "name": "Tom Tool", 2242 "email": "tom@foobar.example.com", 2243 "rsvpResponse": "accepted", 2244 "roles": [ 2245 "attendee" 2246 ] 2247 }, 2248 "zoe@foobar.example.com": { 2249 "name": "Zoe Zelda", 2250 "email": "zoe@foobar.example.com", 2251 "rsvpResponse": "accepted", 2252 "roles": [ 2253 "owner", 2254 "chair" 2255 ] 2256 }, 2257 "...": "" 2258 }, 2259 "recurrenceOverrides": { 2260 "2018-03-08T09:00:00": { 2261 "participants/tom@foobar.example.com/rsvpResponse": "declined" 2262 } 2263 } 2264 } 2266 8. Security Considerations 2268 The use of JSON as a format does have its own inherent security risks 2269 as discussed in Section 12 of [RFC8259]. Even though JSON is 2270 considered a safe subset of JavaScript, it should be kept in mind 2271 that a flaw in the parser processing JSON could still impose a 2272 threat, which doesn't arise with conventional iCalendar data. 2274 With this in mind, a parser for JSON data aware of the security 2275 implications should be used for the format described in this 2276 document. For example, the use of JavaScript's "eval()" function is 2277 considered an unacceptable security risk, as described in Section 12 2278 of[RFC8259]. A native parser with full awareness of the JSON format 2279 should be preferred. 2281 9. IANA Considerations 2283 This document amends the "application/calendar" MIME media type 2284 defined in [RFC7265]. 2286 New optional parameter: "type" with value being one of "jsevent", 2287 "jstask", "jsgroup". The parameter MUST NOT occur more than once. 2289 10. Acknowledgments 2291 The authors would like to thank the members of CalConnect for their 2292 valuable contributions. This specification originated from the work 2293 of the API technical committee of CalConnect, the Calendaring and 2294 Scheduling Consortium. 2296 11. References 2298 11.1. Normative References 2300 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 2301 Requirement Levels", BCP 14, RFC 2119, 2302 DOI 10.17487/RFC2119, March 1997, 2303 . 2305 [RFC2392] Levinson, E., "Content-ID and Message-ID Uniform Resource 2306 Locators", RFC 2392, DOI 10.17487/RFC2392, August 1998, 2307 . 2309 [RFC3339] Klyne, G. and C. Newman, "Date and Time on the Internet: 2310 Timestamps", RFC 3339, DOI 10.17487/RFC3339, July 2002, 2311 . 2313 [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform 2314 Resource Identifier (URI): Generic Syntax", STD 66, 2315 RFC 3986, DOI 10.17487/RFC3986, January 2005, 2316 . 2318 [RFC4122] Leach, P., Mealling, M., and R. Salz, "A Universally 2319 Unique IDentifier (UUID) URN Namespace", RFC 4122, 2320 DOI 10.17487/RFC4122, July 2005, 2321 . 2323 [RFC4648] Josefsson, S., "The Base16, Base32, and Base64 Data 2324 Encodings", RFC 4648, DOI 10.17487/RFC4648, October 2006, 2325 . 2327 [RFC4791] Daboo, C., Desruisseaux, B., and L. Dusseault, 2328 "Calendaring Extensions to WebDAV (CalDAV)", RFC 4791, 2329 DOI 10.17487/RFC4791, March 2007, 2330 . 2332 [RFC5545] Desruisseaux, B., Ed., "Internet Calendaring and 2333 Scheduling Core Object Specification (iCalendar)", 2334 RFC 5545, DOI 10.17487/RFC5545, September 2009, 2335 . 2337 [RFC5546] Daboo, C., Ed., "iCalendar Transport-Independent 2338 Interoperability Protocol (iTIP)", RFC 5546, 2339 DOI 10.17487/RFC5546, December 2009, 2340 . 2342 [RFC5646] Phillips, A., Ed. and M. Davis, Ed., "Tags for Identifying 2343 Languages", BCP 47, RFC 5646, DOI 10.17487/RFC5646, 2344 September 2009, . 2346 [RFC5870] Mayrhofer, A. and C. Spanring, "A Uniform Resource 2347 Identifier for Geographic Locations ('geo' URI)", 2348 RFC 5870, DOI 10.17487/RFC5870, June 2010, 2349 . 2351 [RFC6047] Melnikov, A., Ed., "iCalendar Message-Based 2352 Interoperability Protocol (iMIP)", RFC 6047, 2353 DOI 10.17487/RFC6047, December 2010, 2354 . 2356 [RFC6570] Gregorio, J., Fielding, R., Hadley, M., Nottingham, M., 2357 and D. Orchard, "URI Template", RFC 6570, 2358 DOI 10.17487/RFC6570, March 2012, 2359 . 2361 [RFC6838] Freed, N., Klensin, J., and T. Hansen, "Media Type 2362 Specifications and Registration Procedures", BCP 13, 2363 RFC 6838, DOI 10.17487/RFC6838, January 2013, 2364 . 2366 [RFC6901] Bryan, P., Ed., Zyp, K., and M. Nottingham, Ed., 2367 "JavaScript Object Notation (JSON) Pointer", RFC 6901, 2368 DOI 10.17487/RFC6901, April 2013, 2369 . 2371 [RFC7265] Kewisch, P., Daboo, C., and M. Douglass, "jCal: The JSON 2372 Format for iCalendar", RFC 7265, DOI 10.17487/RFC7265, May 2373 2014, . 2375 [RFC7493] Bray, T., Ed., "The I-JSON Message Format", RFC 7493, 2376 DOI 10.17487/RFC7493, March 2015, 2377 . 2379 [RFC7529] Daboo, C. and G. Yakushev, "Non-Gregorian Recurrence Rules 2380 in the Internet Calendaring and Scheduling Core Object 2381 Specification (iCalendar)", RFC 7529, 2382 DOI 10.17487/RFC7529, May 2015, 2383 . 2385 [RFC7986] Daboo, C., "New Properties for iCalendar", RFC 7986, 2386 DOI 10.17487/RFC7986, October 2016, 2387 . 2389 [RFC8259] Bray, T., Ed., "The JavaScript Object Notation (JSON) Data 2390 Interchange Format", STD 90, RFC 8259, 2391 DOI 10.17487/RFC8259, December 2017, 2392 . 2394 [RFC8288] Nottingham, M., "Web Linking", RFC 8288, 2395 DOI 10.17487/RFC8288, October 2017, 2396 . 2398 11.2. Informative References 2400 [draft-apthorp-ical-tasks] 2401 "Task Extensions to iCalendar", 2402 . 2404 [draft-ietf-calext-ical-relations] 2405 "Support for iCalendar Relationships", 2406 . 2409 [MIME] "IANA Media Types", . 2412 11.3. URIs 2414 [1] https://www.iana.org/assignments/link-relations/link- 2415 relations.xhtml 2417 [2] https://www.w3.org/TR/2011/REC-css3-color-20110607/#svg-color 2419 [3] http://www.iana.org/time-zones 2421 Authors' Addresses 2423 Neil Jenkins 2424 FastMail 2425 PO Box 234 2426 Collins St West 2427 Melbourne VIC 8007 2428 Australia 2430 Email: neilj@fastmailteam.com 2431 URI: https://www.fastmail.com 2433 Robert Stepanek 2434 FastMail 2435 PO Box 234 2436 Collins St West 2437 Melbourne VIC 8007 2438 Australia 2440 Email: rsto@fastmailteam.com 2441 URI: https://www.fastmail.com