Internet-Draft JSContact October 2022
Stepanek & Loffredo Expires 27 April 2023 [Page]
Workgroup:
Calendaring Extensions
Internet-Draft:
draft-ietf-calext-jscontact-04
Published:
Intended Status:
Standards Track
Expires:
Authors:
R. Stepanek
FastMail
M. Loffredo
IIT-CNR

JSContact: A JSON representation of contact data

Abstract

This specification defines a data model and JSON representation of contact card information that can be used for data storage and exchange in address book or directory applications. It aims to be an alternative to the vCard data format and to be unambiguous, extendable and simple to process. In contrast to the JSON-based jCard format, it is not a direct mapping from the vCard data model and expands semantics where appropriate.

Status of This Memo

This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79.

Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet-Drafts is at https://datatracker.ietf.org/drafts/current/.

Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress."

This Internet-Draft will expire on 27 April 2023.

Table of Contents

1. Introduction

This document defines a data model for contact card data normally used in address book or directory applications and services. It aims to be an alternative to the vCard data format [RFC6350] and to provide a JSON-based standard representation of contact card data.

The key design considerations for this data model are as follows:

The representation of this data model is defined in the I-JSON format [RFC7493], which is a strict subset of the JavaScript Object Notation (JSON) Data Interchange Format [RFC8259]. Using JSON is mostly a pragmatic choice: its widespread use makes Card easier to adopt, and the availability of production-ready JSON implementations eliminates a whole category of parser-related interoperability issues.

1.1. Relation to the xCard and jCard formats

The xCard [RFC6351] and jCard [RFC7095] specifications define alternative representations for vCard data, in XML and JSON format respectively. Both explicitly aim to not change the underlying data model. Accordingly, they are regarded as equal to vCard in the context of this document.

1.2. Terminology

The key words MUST, MUST NOT, REQUIRED, SHALL, SHALL NOT, SHOULD, SHOULD NOT, RECOMMENDED, NOT RECOMMENDED, MAY, and OPTIONAL in this document are to be interpreted as described in BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here.

1.3. Type Signatures

Type signatures are given for all JSON values in this document. The following conventions are used:

  • * - The type is undefined (the value could be any type, although permitted values may be constrained by the context of this value).
  • String - The JSON string type.
  • Number - The JSON number type.
  • Boolean - The JSON boolean type.
  • A[B] - A JSON object where the keys are all of type A, and the values are all of type B.
  • A[] - An array of values of type A.
  • A|B - The value is either of type A or of type B.

1.4. Data types

In addition to the standard JSON data types, a couple of additional data types are common to the definitions of JSContact objects and properties.

1.4.1. Id

Where Id is given as a data type, it means a String of at least 1 and a maximum of 255 octets in size, and it MUST only contain characters from the URL and Filename Safe base64url alphabet, as defined in Section 5 of [RFC4648], excluding the pad character (=). This means the allowed characters are the ASCII alphanumeric characters (A-Za-z0-9), hyphen (-), and underscore (_).

In many places in JSContact a JSON map is used where the map keys are of type Id and the map values are all the same type of object. This construction represents an unordered set of objects, with the added advantage that each entry has a name (the corresponding map key). This allows for more concise patching of objects, and, when applicable, for the objects in question to be referenced from other objects within the JSContact object. The map keys MUST be preserved across multiple versions of the JSContact object.

Unless otherwise specified for a particular property, there are no uniqueness constraints on an Id value (other than, of course, the requirement that you cannot have two values with the same key within a single JSON map). For example, two Card objects might use the same Ids in their respective photos properties. Or within the same Card object the same Id could appear in the emails and phones properties. These situations do not imply any semantic connections among the objects.

1.4.2. Int and UnsignedInt

Where Int is given as a data type, it means an integer in the range -253+1 <= value <= 2^53-1, the safe range for integers stored in a floating-point double, represented as a JSON Number.

Where UnsignedInt is given as a data type, it means an integer in the range 0 <= value <= 253-1, represented as a JSON Number.

1.4.3. PatchObject

A PatchObject is of type String[*], and represents an unordered set of patches on a JSON object. Each key is a path represented in a subset of JSON pointer format [RFC6901]. The paths have an implicit leading /, so each key is prefixed with / before applying the JSON pointer evaluation algorithm.

A patch within a PatchObject is only valid if all of the following conditions apply:

  1. The pointer MUST NOT reference inside an array (i.e., you MUST NOT insert/delete from an array; the array MUST be replaced in its entirety instead).
  2. All parts prior to the last (i.e., the value after the final slash) MUST already exist on the object being patched.
  3. There MUST NOT be two patches in the PatchObject where the pointer of one is the prefix of the pointer of the other, e.g., addresses/1/city and addresses.
  4. The value for the patch MUST be valid for the property being set (of the correct type and obeying any other applicable restrictions), or if null the property MUST be optional.

The value associated with each pointer determines how to apply that patch:

  • If null, remove the property from the patched object. If the key is not present in the parent, this a no-op.
  • If non-null, set the value given as the value for this property (this may be a replacement or addition to the object being patched).

A PatchObject does not define its own @type property. Instead, a @type property in a patch MUST be handled as any other patched property value.

Implementations MUST reject in its entirety a PatchObject if any of its patches is invalid. Implementations MUST NOT apply partial patches.

1.4.4. Resource

This data type defines a resource associated with the entity represented by this card, identified by a URI [RFC3986]. Several property definitions later in this document refer to the Resource data type as the basis for their property-specific value types. The Resource data type defines the properties that are common to all of them. Property definitions making use of Resource MAY define additional properties for their value types.

A Resource object has the following properties:

  • @type: String (mandatory). The allowed values are defined in the property definition that makes use of the Resource type.

    type: String (optional). The type of the resource. The allowed values are defined in the property definition that makes use of the Resource type.

  • uri: String (mandatory). The resource value. This MUST be a URI as defined in Section 3 of [RFC3986] and updates.
  • mediaType: String (optional). Used for URI resource values. Provides the media type [RFC2046] of the resource identified by the URI.
  • contexts: String[Boolean] (optional) The contexts in which to use this resource. Also see Section 1.6.1.
  • pref: UnsignedInt (optional) The preference of this resource in relation to other resources. Also see Section 1.6.3.
  • label: String (optional). A custom label for the value, see Section 1.6.2.

1.4.5. UTCDateTime

This is a string in [RFC3339] date-time format, with the further restrictions that any letters MUST be in uppercase, and the time offset MUST be the character Z. Fractional second values MUST NOT be included unless non-zero and MUST NOT have trailing zeros, to ensure there is only a single representation for each date-time.

For example, 2010-10-10T10:10:10.003Z is conformant, but 2010-10-10T10:10:10.000Z is invalid and is correctly encoded as 2010-10-10T10:10:10Z.

1.5. Property types

JSContact objects are represented as I-JSON objects [RFC7493] and the keys of such objects are called properties. Like all other content of I-JSON objects, property names MUST be encoded in UTF-8. This specification distinguishes between three kinds of properties: standard properties, vendor extension properties and unknown properties. The following sections define each kind.

1.5.1. Standard properties

Standard properties either are defined in this RFC document, or in any of its standard extensions. A property becomes standard only if its name and value type got registered according to the IANA property registry rules as outlined in Section 5.

Implementations MUST validate and preserve standard properties in JSContact data, and MUST reject invalid standard properties. A property is invalid if its name matches the name of a standard property but either the value violates the type definition of this standard property, or the property is not defined for the respective JSContact object type. This rule applies to all standard properties defined in this document. If an implementation supports a JSContact extension, this rule also applies to the standard properties defined in that extension. It does not apply to standard properties that are unknown to the implementation (see Section 1.5.3).

Standard property names MUST NOT contain the COLON character (U+003A). They SHOULD only contain US-ASCII alphanumeric characters (the ALPHA and DIGIT rules defined in Section 6.1 of [RFC2234]), but a notable exception of this rule is the @type property defined in later sections of this document. Standard property names SHOULD be notated in lower camel case.

1.5.2. Vendor-Extension Properties

Vendor-extension properties MAY be stored in JSContact data. These properties allow for experimentation or to store data that only is useful for one particular service or application. Implementations MUST preserve vendor extension properties in JSContact data, irrespective if they know their use.

Vendor extension property names MUST start with a vendor-specific prefix, followed by the COLON character (U+003A), followed by any other non-control ASCII or non-ASCII characters. The vendor-specific prefix SHOULD be a domain name under control of the service or application that sets the property, but it need not resolve in the Domain Name System [RFC1034] and [RFC1035]. The prefix ietf.org and its sub-domain names are reserved for IETF specifications.

The ABNF rule v-extension formally defines valid vendor extension property names. Note that vendor prefix allow for more values than are allowed as Internationalized Domain Names (IDN) [RFC8499]. This is to allow JSContact implementations simply validate property names without implementing the full set of rules that apply to domain names.

v-extension = v-prefix ":" v-string

v-prefix = v-label *("." v-label)

v-label = alnum-int / alnum-int *(alnum-int / "-") alnum-int

alnum-int = ALPHA / DIGIT / NON-ASCII
  ; see RFC 6350 Section 3.3

v-string = 1*(WSP / %x21-7E / NON-ASCII)
  ; any characters except CTLs, see RFC 6350 Section 3.3

The value of vendor extension properties can be any valid JSON value, and naming restrictions do not apply to such values. Specifically, if the property value is a JSON object then the keys of such objects need not be named as vendor extension properties.

The following all are valid examples of vendor extension properties.

{
  "@type": "Card",
  "example.com:foo": "bar",
  "example.com:foo2": {
    "bar": "baz"
  },
  "ietf.org:rfcXXXX/x-foo": "bar"
  ...
}
Figure 1

Vendors are strongly encouraged to specify new standard properties once a vendor-extension turns out to be useful also for other systems.

1.5.3. Unknown properties

Implementations may encounter JSContact data where a JSON object key does not match the name of a property known to that implementation. They MUST NOT treat such properties as invalid, instead, they MUST preserve them in the JSContact object. Implementations that create or update JSContact data MUST only set standard properties or vendor-extension properties, but MUST preserve any already existing unknown properties. This is to allow applications and services to interoperate without data loss, even if they do not implement the same set of JSContact extensions.

1.6. Common properties

Most of the properties in this document are specific to a single JSCalendar object type. Such properties are defined along with the respective object type. The properties in this section however are common to multiple data types and better be defined just once. Note that these properties MUST only be set for a JSCalendar object if they are explicitly mentioned to be allowed for this object type.

1.6.1. The contexts property

Type: String[Boolean]

This property associates contact information with one or more contexts in which it should be used. For example, someone might have distinct phone numbers for work and private contexts, and may set the desired context on the respective phone number in the phones (Section 2.3.3) property.

This document defines the following common contexts. Additional contexts may be defined in the properties or data types that make use of this property, may be registered in a future RFC, or be vendor-specific (Section 1.5.2).

  • private: The contact information may be used to contact in a private context.
  • work: The contact information may be used to contact in a professional context.

1.6.2. The label property

Type: String

This property allows to associate contact data with user-defined labels. Such labels may be set for phone numbers, email addresses, and others. Typically these labels are displayed along with their associated contact data in graphical user interfaces. While this specification does not place further restrictions on the value, implementors SHOULD take in mind that labels best be succinct, so that they properly display on graphical user interfaces with low resolution or devices with small screens.

1.6.3. The pref property

Type: UnsignedInt

This property allows to define a preference order for contact information. For example, a card holder may have two email addresses and prefer to be contacted with one of them.

Its value MUST be in the range 1 and 100. Lower values correspond to a higher level of preference, with 1 being most preferred. If no preference is set, then the contact information MUST be interpreted as being least preferred.

Note that the preference only is defined in relation to contact information of the same type. For example, the preference orders within emails and phone numbers are indendepent of each other.

1.7. Vendor-Extension Values

Some JSContact standard properties allow their values to be vendor-specific. One such example is the kind property Section 2.1.6, which enumerates its standard values but also allows for arbitrary vendor-extension values. Such vendor-extension values MUST be valid v-extensions as defined in Section 1.5.2 . This is an example for a vendor-extension value:

{
  "@type": "Card",
  "kind": "example.com:kind:foo",
  ...
}
Figure 2

Vendors are strongly encouraged to specify new standard values once a vendor-extension turns out to be useful also for other systems.

2. Card

MIME type: application/jscontact+json;type=card

A Card object stores information about a person, organization or company.

2.1. Metadata properties

2.1.1. @type

Type: String (mandatory).

Specifies the type of this object. This MUST be Card.

2.1.2. uid

Type: String (mandatory).

An identifier, used to associate the object as the same across different systems, addressbooks and views. [RFC4122] describes a range of established algorithms to generate universally unique identifiers (UUID), and the random or pseudo-random version is recommended. For compatibility with [RFC6350] UIDs, implementations MUST accept both URI and free-form text.

2.1.3. prodId

Type: String (optional).

The identifier for the product that created the Card object.

2.1.4. created

Type: UTCDateTime (optional).

The date and time when this Card object was created.

2.1.5. updated

Type: UTCDateTime (optional).

The date and time when the data in this Card object was last modified.

2.1.6. kind

Type: String (optional). The kind of the entity the Card represents.

The value MUST be either one of the following values, registered in a future RFC, or a vendor-specific value (Section 1.5.2):

  • individual: a single person
  • org: an organization
  • location: a named location
  • device: a device, such as appliances, computers, or network elements
  • application: a software application

2.1.7. relatedTo

Type: String[Relation] (optional).

Relates the object to other Card and CardGroup objects. This is represented as a map, where each key is the uid of the related Card or CardGroup and the value defines the relation. The Relation object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be Relation.
  • relation: String[Boolean] (optional, default: empty Object) Describes how the linked object is related to the linking object. The relation is defined as a set of relation types. If empty, the relationship between the two objects is unspecified. Keys in the set MUST be one of the RELATED property [RFC6350] type parameter values, or an IANA-registered value, or a vendor-specific value (Section 1.5.2). The value for each key in the set MUST be true.

2.1.8. locale

Type: String (optional).

This is the language tag, as defined in [RFC5646], that best describes the locale used for text in the card or card group. Note that such values MAY be localized in the localizations property Section 2.7.1.

2.2. Name and Organization properties

2.2.1. name

Type: Name (optional).

The name of the entity represented by this Card.

A Name object has the following properties

  • @type: Name (mandatory). Specifies the type of this object. This MUST be Name.
  • components: NameComponent[] (mandatory). The components making up the name. The component list MUST have at least one entry. Name components SHOULD be ordered such that their values joined by whitespace produce a valid full name of this entity. Doing so, implementations MAY ignore any components of type separator.
  • locale: String (optional). The locale of the name. The value MUST be a language tag as defined [RFC5646].

A NameComponent object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be NameComponent.
  • value: String (mandatory). The value of this name component.
  • type: String (mandatory). The type of this name component. The value MUST be either one of the following values, registered in a future RFC, or a vendor-specific value (Section 1.5.2):

    • prefix. The value is a honorific title(s), e.g. "Mr", "Ms", "Dr".
    • given. The value is a given name, also known as "first name", "personal name".
    • surname. The value is a surname, also known as "last name", "family name".
    • middle. The value is a middle name, also known as "additional name".
    • suffix. The value is a honorific suffix, e.g. "B.A.", "Esq.".
    • separator. A formatting separator for two name components. The value property of the component includes the verbatim separator, for example a newline character.
  • nth: UnsignedInt (optional, default: 1). Defines the rank of this name component to other name components of the same type. If set, the property value MUST be higher than or equal to 1.

    For example, two name components of type surname may have their nth property value set to 1 and 2, respectively. In this case, the first name component defines the surname, and the second name component the secondary surname.

    Note that this property value does not indicate the order in which to print name components of the same type. Some cultures print the secondary surname before the first surname, others the first before the second. Implementations SHOULD inspect the locale property of the Name object to determine the appropriate formatting. They MAY print name components in order of appearance in the components property of the Name object.

2.2.2. fullName

Type: String (optional).

The full name (e.g. the personal name and surname of an individual, the name of an organization) of the entity represented by this card. The purpose of this property is to define a name, even if the individual name components are not known. In addition, it is meant to provide alternative versions of the name for internationalisation. Implementations SHOULD prefer using the name property over this one and SHOULD NOT store the concatenated name component values in this property.

2.2.3. nickNames

Type: Id[NickName] (optional).

The nick names of the entity represented by this card. A NickName object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be NickName.
  • name: String (mandatory). The nick name.
  • contexts: String[Boolean] (optional) The contexts in which to use this nick name. Also see Section 1.6.1.
  • pref: UnsignedInt (optional) The preference of this nick name in relation to other nick names. Also see Section 1.6.3.
  • label: String (optional). A custom label for the nick name, see Section 1.6.2.

2.2.4. organizations

Type: Id[Organization] (optional).

The companies or organization names and units associated with this card. An Organization object has the following properties, of which at least one of name and units MUST be set:

  • @type: String (mandatory). Specifies the type of this object. This MUST be Organization.
  • name: String (optional). The name of this organization. If set, the value MUST be a non-empty string.
  • units: String[] (optional). A list of organizational unit names. If set, the list MUST contain at least one entry.

2.2.5. titles

Type : Id[Title] (optional).

The job titles or functional positions of the entity represented by this card. A Title has object the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be Title.
  • title: String (mandatory). The title of the entity represented by this card.
  • type: String (optional, default title). Describes the organizational or situational type of this title. Some organizations and individuals distinguish between titles as organizational positions and roles as more temporary assignments, such as in project management. If set, the property value MUST either be one of title and role, or be registered in a future RFC, or a vendor-specific value (Section 1.5.2).
  • organization: Id (optional). The id of the organization in which this title is held.

2.2.6. speakToAs

Type: SpeakToAs (optional).

Provides information how to address, speak to or refer to the entity that is represented by this card. A SpeakToAs object has the following properties, of which at least one property other than @type MUST be set:

  • @type: String (mandatory). Specifies the type of this object. This MUST be SpeakToAs.
  • grammaticalGender: String (optional). Defines which grammatical gender to use in salutations and other grammatical constructs. Allowed values are:

    Note that the grammatical gender does not allow to infer the gender identities or assigned sex of the contact.

  • pronouns: Id[Pronouns] (optional). Defines the pronouns that the contact chooses to use for themselves.

A Pronouns object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be Pronouns.
  • pronouns: String (mandatory). Defines the pronouns. Any value or form is allowed. Examples in English include she/her and they/them/theirs. The value MAY be overridden in the localizations property (Section 2.7.1).
  • contexts: String[Boolean] (optional) The contexts in which to use these pronouns. Also see Section 1.6.1.
  • pref: UnsignedInt (optional) The preference of these pronouns in relation to other pronouns in the same context. Also see Section 1.6.3.
  • label: String (optional). A custom label for the value, see Section 1.6.2.

2.3. Contact properties

2.3.1. emails

Type: Id[EmailAddress] (optional).

The email addresses to contact the entity represented by this card. An EmailAddress object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be EmailAddress.
  • email: String (mandatory). The email address. This MUST be an addr-spec value as defined in Section 3.4.1 of [RFC5322].
  • contexts: String[Boolean] (optional) The contexts in which to use this email address. Also see Section 1.6.1.
  • pref: UnsignedInt (optional) The preference of this email address in relation to other email addresses. Also see Section 1.6.3.
  • label: String (optional). A custom label for the value, see Section 1.6.2.

2.3.2. onlineServices

Type: Id[OnlineService] (optional).

The online services that are associated with the entity represented by this card. This can be messaging services, social media profiles, and other. An OnlineService object has the following properties, of which at least either the uri property or both the username and service properties MUST be set:

  • @type: String (mandatory). Specifies the type of this object. This MUST be OnlineService.
  • service: String (optional). The name of the online service or protocol. This SHOULD be the canonical service name including capitalisation. Examples are GitHub, kakao, Twitter, XMPP.
  • uri: String (optional). The service-specific URI of the entity represented by this card.
  • username: String (optional). The service-specific user name of the entity represented by this card. If this property is set, then the service property MUST be set.
  • contexts: String[Boolean] (optional) The contexts in which to use this service. Also see Section 1.6.1.
  • pref: UnsignedInt (optional) The preference of this service in relation to other services. Also see Section 1.6.3.
  • label: String (optional). A custom label for the value, see Section 1.6.2.

2.3.3. phones

Type: Id[Phone] (optional).

The phone numbers to contact the entity represented by this card. A Phone object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be Phone.
  • phone: String (mandatory). The phone value, as either a URI or a free-text phone number. Typical URI schemes are the [RFC3966] tel or [RFC3261] sip schemes, but any URI scheme is allowed.
  • features: String[Boolean] (optional). The set of contact features that this phone number may be used for. The set is represented as an object, with each key being a method type. The boolean value MUST be true. The method type MUST be either one of the following values, registered in a future RFC, or a vendor-specific value (Section 1.5.2):

    • voice The number is for calling by voice.
    • fax The number is for sending faxes.
    • pager The number is for a pager or beeper.
    • text The number supports text messages (SMS).
    • cell The number is for a cell phone.
    • textphone The number is for a device for people with hearing or speech difficulties.
    • video The number supports video conferencing.
  • contexts: String[Boolean] (optional) The contexts in which to use this number. Also see Section 1.6.1.
  • pref: UnsignedInt (optional) The preference of this number in relation to other numbers. Also see Section 1.6.3.
  • label: String (optional). A custom label for the value, see Section 1.6.2.

2.3.4. preferredContactChannels

Type : String[ContactChannelPreference[]] (optional)

Defines which channel the entity represented by this card prefers to be contacted with. The keys in the object MUST be either one of the following values, registered in a future RFC, or a vendor-specific value (Section 1.5.2):

The values in the object are a (possibly empty) list of preferences for this contact channel. A valid ContactChannelPreference object MUST have at least one of its properties set in addition to the @type property.

A ContactChannelPreference object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be ContactChannelPreference.
  • contexts: String[Boolean] (optional). Defines the contexts in which to use this contact channel. Also see Section 1.6.1.
  • pref: UnsignedInt (optional). Defines the preference of this contact channel in relation to other contact channels with the same contexts. Also see Section 1.6.3.

2.3.5. preferredLanguages

Type : String[LanguagePreference[]] (optional)

Defines the preferred languages for contacting the entity associated with this card. The keys in the object MUST be [RFC5646] language tags. The values are a (possibly empty) list of contact language preferences for this language. A valid LanguagePreference object MUST have at least one of its properties set in addition to the @type property.

A LanguagePreference object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be LanguagePreference.
  • contexts: String[Boolean] (optional). Defines the contexts in which to use this language. Also see Section 1.6.1.
  • pref: UnsignedInt (optional). Defines the preference of this language in relation to other languages of the same contexts. Also see Section 1.6.3.

2.4. Calendaring and Scheduling properties

2.4.1. calendars

Type: Id[CalendarResource] (optional).

These are resources for calendaring, such as calendars to lookup free-busy information for the entity represented by this card. A CalendarResource object has all properties of the Resource (Section 1.4.4) data type, with the following additional definitions:

  • The @type property value MUST be CalendarResource.

The type property value MUST be one of the following, or be defined in a future RFC or vendor-specific:

  • calendar The resource is a calendar that contains entries such as calendar events or tasks.
  • freeBusy The resource allows for free-busy lookups, for example to schedule group events.

2.4.2. schedulingAddresses

Type: Id[SchedulingAddress] (optional).

The scheduling addresses by which the entity may receive calendar scheduling invitations. A SchedulingAddress object has all properties of the Resource (Section 1.4.4) data type, with the following additional definitions:

  • The @type property value MUST be SchedulingAddress.
  • The type property value either is not set or it MUST be a valid object key of the JSCalendar sendTo property, as specified in Section 4.4.6 of [RFC8984] and future JSCalendar RFCs.

2.5. Address and Location properties

2.5.1. addresses

Type: Id[Address] (optional).

A map of address ids to Address objects, containing physical locations. An Address object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be Address.
  • fullAddress: String (optional). The complete address, excluding type and label. This property is mainly useful to represent addresses of which the individual address components are unknown, or to provide localized representations.
  • street: StreetComponent[] (optional). The street address. The concatenation of the component values, separated by whitespace, SHOULD result in a valid street address for the address locale. Doing so, implementations MAY ignore any separator components. The StreetComponent object type is defined in the paragraph below.

  • locality: String (optional). The city, town, village, post town, or other locality within which the street address may be found.
  • region: String (optional). The province, such as a state, county, or canton within which the locality may be found.
  • country: String (optional). The country name.
  • postcode: String (optional). The postal code, post code, ZIP code or other short code associated with the address by the relevant country's postal system.
  • countryCode: String (optional). The ISO-3166-1 country code.
  • coordinates: String (optional) A [RFC5870] "geo:" URI for the address.
  • timeZone: String (optional) Identifies the time zone this address is located in. This MUST be a time zone name registered in the IANA Time Zone Database
  • contexts: String[Boolean] (optional). The contexts of the address information. The boolean value MUST be true. In addition to the common contexts (Section 1.6.1), allowed key values are:

    • billing An address to be used for billing.
    • postal An address to be used for delivering physical items.
  • pref: UnsignedInt (optional) The preference of this address in relation to other addresses. Also see Section 1.6.3.
  • label: String (optional). A custom label for the value, see Section 1.6.2.

A StreetComponent object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be StreetComponent.
  • type: String (mandatory). The type of this street component. The value MUST be either one of the following values, registered in a future RFC, or a vendor-specific value (Section 1.5.2):

    • name. The street name.
    • number. The street number.
    • apartment. The apartment number or identifier.
    • room. The room number or identifier.
    • extension. The extension designation or box number.
    • direction. The cardinal direction, e.g. "North".
    • building. The building or building part this address is located in.
    • floor. The floor this address is located on.
    • postOfficeBox. The post office box number or identifier.
    • separator. A separator for two street components. The value property of the component includes the verbatim separator, for example a newline character.
    • unknown. A street component value for which no type is known.
  • value: String (mandatory). The value of this street component.

2.6. Resource properties

2.6.1. cryptoKeys

Type: Id[CryptoResource] (optional).

These are cryptographic resources such as public keys and certificates associated with the entity represented by this card. A CryptoResource object has all properties of the Resource (Section 1.4.4) data type, with the following additional definitions:

  • The @type property value MUST be CryptoResource.
  • The type property value either is not set, is defined in a future RFC or vendor-specific.

2.6.2. directories

Type: Id[DirectoryResource] (optional).

These are directory service resources, such as entries in a directory or organizational directories for lookup. A DirectoryResource object has all properties of the Resource (Section 1.4.4) data type, with the following additional definitions:

  • The @type property value MUST be DirectoryResource.

The type property value MUST be one of the following, or be defined in a future RFC or vendor-specific:

  • directory The resource is a directory service where the entity represented by this card is part of. This typically is an organizational directory that also contains associated entities, e.g. co-workers and management in a company directory.
  • entry The resource is a directory entry of the entity represented by this card. In contrast to the directory type, this is the specific URI for the entity within a directory.

2.6.4. media

Type: Id[MediaResource] (optional).

These are media resources such as photographs, avatars or sounds associated with the entity represented by this card. A MediaResource object has all properties of the Resource (Section 1.4.4) data type, with the following additional definitions:

  • The @type property value MUST be MediaResource.

The type property value must be one of the following, or be defined in a future RFC or vendor-specific:

  • photo The resource is a photograph or avatar.
  • sound The resource is audio media, e.g. to specify the proper pronunciation of the name property contents.
  • logo The resource is a graphic image or logo associated with entity represented by this card.

2.7. Multilingual properties

2.7.1. localizations

Type: String[PatchObject] (optional).

A map of language tags [RFC5646] to patches, which localize a property value into the locale of the respective language tag. The paths in the PatchObject keys are relative to the Card object that includes the localizations property. A patch MUST NOT target the localizations property.

The following example shows a Card object, where one of its addresses Tokyo is localized for the jp locale.

  "@type": "Card",
  ...
  "addresses": {
    "addr1": {
      "@type": "Address",
      "locality": "Tokyo",
     }
   },
   "localizations": {
     "jp": {
        "addresses/addr1/locality":"東京"
     }
   }
Figure 3

2.8. Additional properties

2.8.1. anniversaries

Type : Id[Anniversary] (optional).

These are memorable dates and events for the entity represented by this card. An Anniversary object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be Anniversary.
  • type: String (optional). Specifies the type of the anniversary. This RFC predefines the following types, but implementations MAY use additional values:

    • birth: a birth day anniversary
    • death: a death day anniversary
  • date: Timestamp|PartialDate (mandatory).

    The date of this anniversary in the Gregorian calendar. This MUST either be a whole or partial calendar date or a complete UTC timestamp (see the definition of the Timestamp and PartialDate object types below).

  • place: Address (optional). An address associated with this anniversary, e.g. the place of birth or death.
  • label: String (optional). A custom label for the value, see Section 1.6.2.

A Timestamp object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be Timestamp.
  • utc: UTCDateTime (mandatory). Specifies the point in time in UTC time.

A PartialDate object represents a complete or partial calendar date in the Gregorian calendar. It represents either a complete date, or a year, or a month in a year, or a day in a month. It has the following properties, of which at least year or month and day MUST be set:

  • @type: String (mandatory). Specifies the type of this object. This MUST be PartialDate.
  • year: Int (optional). This is the calendar year.
  • month: Int (optional). This is the calendar month, represented as the integers 1 <= month <= 12. If this property is set then either year or day MUST be set.
  • day: Int (optional). This is the calendar month day, represented as the integers 1 <= day <= 31, depending on the validity within the month and year. If this property is set then month MUST be set.
  • calendarScale: String (optional). This is the calendar system in which this date occurs, in lowercase. This MUST be either a CLDR-registered calendar system name [CLDR] or a vendor-specific value). Note that the year, month and day still MUST be represented in the Gregorian calendar.

2.8.2. personalInfo

Type: Id[PersonalInformation] (optional).

Defines personal information about the entity represented by this card. A PersonalInformation object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be PersonalInformation.
  • type: String (mandatory). Specifies the type for this personal information. The value MUST be one of the following, or be registered in a future RFC or vendor-specific (Section 1.5.2):

    • expertise: a field of expertise or credential
    • hobby: a hobby
    • interest: an interest
  • value: String (mandatory). The actual information. This generally is free-text, but future specifications MAY restrict allowed values depending on the type of this PersonalInformation.
  • level: String (optional) Indicates the level of expertise, or engagement in hobby or interest. The value MUST be one of the following, or be registered in a future RFC or vendor-specific (Section 1.5.2): high, medium and low.
  • label: String (optional). A custom label for the value, see Section 1.6.2.

2.8.3. notes

Type: Note[] (optional).

Free-text notes associated with this card. A Note object has the following properties:

  • @type: String (mandatory). Specifies the type of this object. This MUST be Note.
  • note: String (mandatory). The free text value of this note.

  • language: String (optional). The human language in which the main content of this note is written in. The property value MUST be a valid language tag as defined [RFC5646].

2.8.4. keywords

Type: String[Boolean] (optional). A set of free-text keywords, also known as tags. The set is represented as an object, with each key being a keyword. The boolean value MUST be true.

3. CardGroup

MIME type: application/jscontact+json;type=cardgroup

A CardGroup object represents a group of cards. Its members may be Cards or CardGroups.

3.1. Group properties

3.1.1. @type

Type: String (mandatory).

Specifies the type of this object. This MUST be CardGroup.

3.1.2. uid

Type: String (mandatory). The uid of this group, an identifier globally unique within both CardGroup and Card uid values. Also see Section 2.1.2.

3.1.3. members

Type: String[Boolean] (mandatory). The members of this group.

The set is represented as an object, with each key being the uid of another Card or CardGroup. The boolean value MUST be true.

3.1.4. card

Type: Card (optional). The card that represents this group. The uid property of the card MUST match the value of the card group uid property.

4. Implementation Status

NOTE: Please remove this section and the reference to [RFC7942] prior to publication as an RFC. This section records the status of known implementations of the protocol defined by this specification at the time of posting of this Internet-Draft, and is based on a proposal described in [RFC7942]. The description of implementations in this section is intended to assist the IETF in its decision processes in progressing drafts to RFCs. Please note that the listing of any individual implementation here does not imply endorsement by the IETF. Furthermore, no effort has been spent to verify the information presented here that was supplied by IETF contributors. This is not intended as, and must not be construed to be, a catalog of available implementations or their features. Readers are advised to note that other implementations may exist. According to [RFC7942], "this will allow reviewers and working groups to assign due consideration to documents that have the benefit of running code, which may serve as evidence of valuable experimentation and feedback that have made the implemented protocols more mature. It is up to the individual working groups to use this information as they see fit".

4.1. IIT-CNR/Registro.it

  • Responsible Organization: Institute of Informatics and Telematics of National Research Council (IIT-CNR)/Registro.it
  • Location: https://rdap.pubtest.nic.it/
  • Description: This implementation includes support for RDAP queries using data from the public test environment of .it ccTLD. The RDAP server returns responses including Card in place of jCard when queries contain the parameter jscard=1.
  • Level of Maturity: This is an "alpha" test implementation.
  • Coverage: This implementation includes all of the features described in this specification.
  • Contact Information: Mario Loffredo, mario.loffredo@iit.cnr.it

5. IANA Considerations

This section will be completed before IESG Last Call.

6. Security Considerations

This section will be completed before IESG Last Call.

7. References

7.1. Normative References

[RFC1034]
Mockapetris, P., "Domain names - concepts and facilities", STD 13, RFC 1034, DOI 10.17487/RFC1034, , <https://www.rfc-editor.org/info/rfc1034>.
[RFC1035]
Mockapetris, P., "Domain names - implementation and specification", STD 13, RFC 1035, DOI 10.17487/RFC1035, , <https://www.rfc-editor.org/info/rfc1035>.
[RFC2046]
Freed, N. and N. Borenstein, "Multipurpose Internet Mail Extensions (MIME) Part Two: Media Types", RFC 2046, DOI 10.17487/RFC2046, , <https://www.rfc-editor.org/info/rfc2046>.
[RFC2119]
Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/RFC2119, , <https://www.rfc-editor.org/info/rfc2119>.
[RFC2234]
Crocker, D., Ed. and P. Overell, "Augmented BNF for Syntax Specifications: ABNF", RFC 2234, DOI 10.17487/RFC2234, , <https://www.rfc-editor.org/info/rfc2234>.
[RFC4122]
Leach, P., Mealling, M., and R. Salz, "A Universally Unique IDentifier (UUID) URN Namespace", RFC 4122, DOI 10.17487/RFC4122, , <https://www.rfc-editor.org/info/rfc4122>.
[RFC5646]
Phillips, A., Ed. and M. Davis, Ed., "Tags for Identifying Languages", BCP 47, RFC 5646, DOI 10.17487/RFC5646, , <https://www.rfc-editor.org/info/rfc5646>.
[RFC5870]
Mayrhofer, A. and C. Spanring, "A Uniform Resource Identifier for Geographic Locations ('geo' URI)", RFC 5870, DOI 10.17487/RFC5870, , <https://www.rfc-editor.org/info/rfc5870>.
[RFC6350]
Perreault, S., "vCard Format Specification", RFC 6350, DOI 10.17487/RFC6350, , <https://www.rfc-editor.org/info/rfc6350>.
[RFC6351]
Perreault, S., "xCard: vCard XML Representation", RFC 6351, DOI 10.17487/RFC6351, , <https://www.rfc-editor.org/info/rfc6351>.
[RFC6901]
Bryan, P., Ed., Zyp, K., and M. Nottingham, Ed., "JavaScript Object Notation (JSON) Pointer", RFC 6901, DOI 10.17487/RFC6901, , <https://www.rfc-editor.org/info/rfc6901>.
[RFC7095]
Kewisch, P., "jCard: The JSON Format for vCard", RFC 7095, DOI 10.17487/RFC7095, , <https://www.rfc-editor.org/info/rfc7095>.
[RFC7493]
Bray, T., Ed., "The I-JSON Message Format", RFC 7493, DOI 10.17487/RFC7493, , <https://www.rfc-editor.org/info/rfc7493>.
[RFC7942]
Sheffer, Y. and A. Farrel, "Improving Awareness of Running Code: The Implementation Status Section", BCP 205, RFC 7942, DOI 10.17487/RFC7942, , <https://www.rfc-editor.org/info/rfc7942>.
[RFC8174]
Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, , <https://www.rfc-editor.org/info/rfc8174>.
[RFC8259]
Bray, T., Ed., "The JavaScript Object Notation (JSON) Data Interchange Format", STD 90, RFC 8259, DOI 10.17487/RFC8259, , <https://www.rfc-editor.org/info/rfc8259>.
[RFC8984]
Jenkins, N. and R. Stepanek, "JSCalendar: A JSON Representation of Calendar Data", RFC 8984, DOI 10.17487/RFC8984, , <https://www.rfc-editor.org/info/rfc8984>.

7.2. Informative References

[CLDR]
"Unicode Common Locale Data Repository", <http://cldr.unicode.org/>.
[RFC3261]
Rosenberg, J., Schulzrinne, H., Camarillo, G., Johnston, A., Peterson, J., Sparks, R., Handley, M., and E. Schooler, "SIP: Session Initiation Protocol", RFC 3261, DOI 10.17487/RFC3261, , <https://www.rfc-editor.org/info/rfc3261>.
[RFC3339]
Klyne, G. and C. Newman, "Date and Time on the Internet: Timestamps", RFC 3339, DOI 10.17487/RFC3339, , <https://www.rfc-editor.org/info/rfc3339>.
[RFC3966]
Schulzrinne, H., "The tel URI for Telephone Numbers", RFC 3966, DOI 10.17487/RFC3966, , <https://www.rfc-editor.org/info/rfc3966>.
[RFC3986]
Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform Resource Identifier (URI): Generic Syntax", STD 66, RFC 3986, DOI 10.17487/RFC3986, , <https://www.rfc-editor.org/info/rfc3986>.
[RFC4648]
Josefsson, S., "The Base16, Base32, and Base64 Data Encodings", RFC 4648, DOI 10.17487/RFC4648, , <https://www.rfc-editor.org/info/rfc4648>.
[RFC5322]
Resnick, P., Ed., "Internet Message Format", RFC 5322, DOI 10.17487/RFC5322, , <https://www.rfc-editor.org/info/rfc5322>.
[RFC6473]
Saint-Andre, P., "vCard KIND:application", RFC 6473, DOI 10.17487/RFC6473, , <https://www.rfc-editor.org/info/rfc6473>.
[RFC6474]
Li, K. and B. Leiba, "vCard Format Extensions: Place of Birth, Place and Date of Death", RFC 6474, DOI 10.17487/RFC6474, , <https://www.rfc-editor.org/info/rfc6474>.
[RFC6715]
Cauchie, D., Leiba, B., and K. Li, "vCard Format Extensions: Representing vCard Extensions Defined by the Open Mobile Alliance (OMA) Converged Address Book (CAB) Group", RFC 6715, DOI 10.17487/RFC6715, , <https://www.rfc-editor.org/info/rfc6715>.
[RFC6869]
Salgueiro, G., Clarke, J., and P. Saint-Andre, "vCard KIND:device", RFC 6869, DOI 10.17487/RFC6869, , <https://www.rfc-editor.org/info/rfc6869>.
[RFC8499]
Hoffman, P., Sullivan, A., and K. Fujiwara, "DNS Terminology", BCP 219, RFC 8499, DOI 10.17487/RFC8499, , <https://www.rfc-editor.org/info/rfc8499>.
[RFC8605]
Hollenbeck, S. and R. Carney, "vCard Format Extensions: ICANN Extensions for the Registration Data Access Protocol (RDAP)", RFC 8605, DOI 10.17487/RFC8605, , <https://www.rfc-editor.org/info/rfc8605>.

Authors' Addresses

Robert Stepanek
FastMail
PO Box 234, Collins St West
Melbourne VIC 8007
Australia
Mario Loffredo
IIT-CNR
Via Moruzzi,1
56124 Pisa
Italy