Skip to main content

4. Link Relation Types

Link relation types identify the semantics of links between resources.

Purpose

Semantic Identification

  • Defines the meaning of the relationship
  • Example: "copyright" indicates target contains copyright terms
  • Can indicate target resource attributes or behaviors
  • Example: "service" implies a protocol interface

Not Media Types

Relation types are distinct from media types:

  • Don't identify representation format
  • Only describe how resources are related
  • Media type determined by Content-Type header

Types of Relation Types

4.1. Registered Relation Types

Characteristics:

  • Well-defined tokens registered with IANA
  • Promote reuse across applications
  • Case-insensitive comparison
  • Must conform to reg-rel-type ABNF rule

Naming Guidelines:

  • Appropriate specificity level
  • Application-specific semantics → specific names
  • General semantics → general names

Constraints:

  • MUST NOT constrain context IRI media type
  • MUST NOT constrain target IRI media types
  • CAN specify target resource behaviors
  • CAN specify allowable HTTP methods/media types

Application Data:

  • Registry can include application-specific data
  • Example: browser archiving behavior
  • Registered via Link Relation Application Data registry

4.2. Extension Relation Types

Definition:

  • URI that uniquely identifies the relation type
  • For applications not using registered types
  • URI may point to semantic definition

Usage Guidelines:

  • Clients SHOULD NOT automatically access URI
  • Avoids server burden
  • Comparison: case-insensitive string match
  • Lowercase URIs recommended

Serialization:

  • Required to be absolute URIs in Link headers
  • Must be quoted if containing semicolon (;) or comma (,)
  • Other serializations may use different forms (e.g., CURIEs)

Registry: IANA Link Relation Types