Skip to main content

The Constrained RESTful Application Language (CoRAL)
draft-hartke-t2trg-coral-08

The information below is for an old version of the document.
Document Type
This is an older version of an Internet-Draft whose latest revision state is "Replaced".
Author Klaus Hartke
Last updated 2019-03-11
Replaced by draft-ietf-core-coral
RFC stream (None)
Formats
Additional resources
Stream Stream state (No stream defined)
Consensus boilerplate Unknown
RFC Editor Note (None)
IESG IESG state I-D Exists
Telechat date (None)
Responsible AD (None)
Send notices to (None)
draft-hartke-t2trg-coral-08
quot;Tags for Identifying
              Languages", BCP 47, RFC 5646, DOI 10.17487/RFC5646,
              September 2009, <https://www.rfc-editor.org/info/rfc5646>.

   [RFC5789]  Dusseault, L. and J. Snell, "PATCH Method for HTTP",
              RFC 5789, DOI 10.17487/RFC5789, March 2010,
              <https://www.rfc-editor.org/info/rfc5789>.

   [RFC6573]  Amundsen, M., "The Item and Collection Link Relations",
              RFC 6573, DOI 10.17487/RFC6573, April 2012,
              <https://www.rfc-editor.org/info/rfc6573>.

   [RFC6690]  Shelby, Z., "Constrained RESTful Environments (CoRE) Link
              Format", RFC 6690, DOI 10.17487/RFC6690, August 2012,
              <https://www.rfc-editor.org/info/rfc6690>.

Hartke                 Expires September 12, 2019              [Page 37]
Internet-Draft  Constrained RESTful Application Language      March 2019

   [RFC7228]  Bormann, C., Ersue, M., and A. Keranen, "Terminology for
              Constrained-Node Networks", RFC 7228,
              DOI 10.17487/RFC7228, May 2014,
              <https://www.rfc-editor.org/info/rfc7228>.

   [RFC7230]  Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer
              Protocol (HTTP/1.1): Message Syntax and Routing",
              RFC 7230, DOI 10.17487/RFC7230, June 2014,
              <https://www.rfc-editor.org/info/rfc7230>.

   [RFC7231]  Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer
              Protocol (HTTP/1.1): Semantics and Content", RFC 7231,
              DOI 10.17487/RFC7231, June 2014,
              <https://www.rfc-editor.org/info/rfc7231>.

   [RFC7252]  Shelby, Z., Hartke, K., and C. Bormann, "The Constrained
              Application Protocol (CoAP)", RFC 7252,
              DOI 10.17487/RFC7252, June 2014,
              <https://www.rfc-editor.org/info/rfc7252>.

   [RFC7320]  Nottingham, M., "URI Design and Ownership", BCP 190,
              RFC 7320, DOI 10.17487/RFC7320, July 2014,
              <https://www.rfc-editor.org/info/rfc7320>.

   [RFC8132]  van der Stok, P., Bormann, C., and A. Sehgal, "PATCH and
              FETCH Methods for the Constrained Application Protocol
              (CoAP)", RFC 8132, DOI 10.17487/RFC8132, April 2017,
              <https://www.rfc-editor.org/info/rfc8132>.

   [RFC8187]  Reschke, J., "Indicating Character Encoding and Language
              for HTTP Header Field Parameters", RFC 8187,
              DOI 10.17487/RFC8187, September 2017,
              <https://www.rfc-editor.org/info/rfc8187>.

   [RFC8446]  Rescorla, E., "The Transport Layer Security (TLS) Protocol
              Version 1.3", RFC 8446, DOI 10.17487/RFC8446, August 2018,
              <https://www.rfc-editor.org/info/rfc8446>.

   [W3C.REC-html52-20171214]
              Faulkner, S., Eicholz, A., Leithead, T., Danilo, A., and
              S. Moon, "HTML 5.2", World Wide Web Consortium
              Recommendation REC-html52-20171214, December 2017,
              <https://www.w3.org/TR/2017/REC-html52-20171214>.

Hartke                 Expires September 12, 2019              [Page 38]
Internet-Draft  Constrained RESTful Application Language      March 2019

   [W3C.REC-rdf-schema-20140225]
              Brickley, D. and R. Guha, "RDF Schema 1.1", World Wide Web
              Consortium Recommendation REC-rdf-schema-20140225,
              February 2014,
              <http://www.w3.org/TR/2014/REC-rdf-schema-20140225>.

   [W3C.REC-rdf11-concepts-20140225]
              Cyganiak, R., Wood, D., and M. Lanthaler, "RDF 1.1
              Concepts and Abstract Syntax", World Wide Web Consortium
              Recommendation REC-rdf11-concepts-20140225, February 2014,
              <http://www.w3.org/TR/2014/REC-rdf11-concepts-20140225>.

   [W3C.REC-turtle-20140225]
              Prud&#039;hommeaux, E. and G. Carothers, "RDF 1.1 Turtle",
              World Wide Web Consortium Recommendation REC-turtle-
              20140225, February 2014,
              <http://www.w3.org/TR/2014/REC-turtle-20140225>.

   [W3C.REC-webarch-20041215]
              Jacobs, I. and N. Walsh, "Architecture of the World Wide
              Web, Volume One", World Wide Web Consortium
              Recommendation REC-webarch-20041215, December 2004,
              <http://www.w3.org/TR/2004/REC-webarch-20041215>.

Appendix A.  Core Vocabulary

   This section defines the core vocabulary for CoRAL: a set of link
   relation types, operation types, form field types, and metadata
   names.

   [[NOTE TO RFC EDITOR: Please replace all occurrences of "urn:TBD1" in
   this document with an IETF-controlled IRI, such as "urn:ietf:..." or
   "http://...ietf.org/...".]]

A.1.  Link Relation Types

   <http://www.w3.org/1999/02/22-rdf-syntax-ns#type>
      Indicates that the link's context is an instance of the class
      specified as the link's target, as defined by RDF Schema
      [W3C.REC-rdf-schema-20140225].

   <http://www.iana.org/assignments/relation/item>
      Indicates that the link's context is a collection and that the
      link's target is a member of that collection, as defined in
      Section 2.1 of RFC 6573 [RFC6573].

   <http://www.iana.org/assignments/relation/collection>

Hartke                 Expires September 12, 2019              [Page 39]
Internet-Draft  Constrained RESTful Application Language      March 2019

      Indicates that the link's target is a collection and that the
      link's context is a member of that collection, as defined in
      Section 2.2 of RFC 6573 [RFC6573].

A.2.  Operation Types

   <urn:TBD1#create>
      Indicates that the form's context is a collection and that a new
      item can be created in that collection by submitting a suitable
      representation.  This operation type is typically used with the
      POST method [RFC7231] [RFC7252].

   <urn:TBD1#update>
      Indicates that the form's context can be updated by submitting a
      suitable representation.  This operation type is typically used
      with the PUT method [RFC7231] [RFC7252], PATCH method [RFC5789]
      [RFC8132], or iPATCH method [RFC8132].

   <urn:TBD1#delete>
      Indicates that the form's context can be deleted.  This operation
      type is typically used with the DELETE method [RFC7231] [RFC7252].

   <urn:TBD1#search>
      Indicates that the form's context can be searched by submitting a
      search query.  This operation type is typically used with the POST
      method [RFC7231] [RFC7252] or FETCH method [RFC8132].

A.3.  Form Field Types

   <urn:TBD1#accept>
      Specifies an acceptable HTTP content type or CoAP content format
      for the request payload.  There may be multiple form fields of
      this type.  If a form does not include a form field of this type,
      the server accepts any or no request payload, depending on the
      operation type.

      For HTTP, the content type MUST be specified as a text string in
      the format defined in Section 3.1.1.1 of RFC 7231 [RFC7231]; the
      set of possible values is maintained in the IANA Media Types
      Registry.  For CoAP, the content format MUST be specified as an
      unsigned integer; the set of possible values is maintained in the
      IANA CoAP Content-Formats Registry.

A.4.  Representation Metadata

   <urn:TBD1#type>
      Specifies the HTTP content type or CoAP content format of the
      representation.

Hartke                 Expires September 12, 2019              [Page 40]
Internet-Draft  Constrained RESTful Application Language      March 2019

      For HTTP, the content type MUST be specified as a text string in
      the format defined in Section 3.1.1.1 of RFC 7231 [RFC7231]; the
      set of possible values is maintained in the IANA Media Types
      Registry.  For CoAP, the content format MUST be specified as an
      unsigned integer; the set of possible values is maintained in the
      IANA CoAP Content-Formats Registry.

      A metadata item of this type MUST NOT occur more than once.  If
      absent, its value defaults to content type "application/octet-
      stream" or content format 42.

Appendix B.  Default Dictionary

   This section defines a default dictionary that is assumed when the
   "application/coral+cbor" media type is used without a "dictionary"
   parameter.

      +-----+-------------------------------------------------------+
      | Key | Value                                                 |
      +-----+-------------------------------------------------------+
      |   0 | <http://www.w3.org/1999/02/22-rdf-syntax-ns#type>     |
      |   1 | <http://www.iana.org/assignments/relation/item>       |
      |   2 | <http://www.iana.org/assignments/relation/collection> |
      |   3 | <urn:TBD1#create>                                     |
      |   4 | <urn:TBD1#update>                                     |
      |   5 | <urn:TBD1#delete>                                     |
      |   6 | <urn:TBD1#search>                                     |
      |   7 | <urn:TBD1#accept>                                     |
      |   8 | <urn:TBD1#type>                                       |
      +-----+-------------------------------------------------------+

                        Table 2: Default Dictionary

Acknowledgements

   Thanks to Christian Amsuess for helpful comments and discussions that
   have shaped the document.

Author's Address

   Klaus Hartke
   Ericsson
   Torshamnsgatan 23
   Stockholm  SE-16483
   Sweden

   Email: klaus.hartke@ericsson.com

Hartke                 Expires September 12, 2019              [Page 41]