Adds an HTTP entity-header to be used when creating entries. This header value is a "slug" (i.e. short name identifying the entry) that the server might use when creating an atom:id and/or URI for the entry.


Proposed (Author: ThomasBroyer)


Same as PaceSlugHeader3.

Here is the [WWW]definition of "slug" from Wikipedia:


Add to draft-protocol-09, before section 8.2:

8.2 Slug: Header

The value of the Slug entity-header is a "slug", i.e. a short name 
identifying a resource.

  Slug = "Slug" ":" *TEXT

The syntax of this header MUST conform to the augmented BNF grammar
in section 2.1 of the HTTP/1.1 specification [RFC2616]. The TEXT
rule is described in section 2.2 of the same document. To include 
characters outside [ISO88591] in the Slug header, they need to be 
encoded according to the rules of [RFC2047].

When posting a resource to a collection in order to add a new member, 
the server might use this information when creating the IRI of the 
newly-created resource (for instance by using some or all of the 
words in the last IRI segment). It might eventually also use it when 
creating the atom:id or as the title of a media link entry (see 
section 8.5).

When sent by a client in subsequent PUT requests to update the member 
resource, the server MUST NOT change the atom:id of the entry or 
"media link entry" and SHOULD NOT change the IRI of the resource as 
well, or SHOULD put a redirection in place, most likely a 301 (Moved

Servers MAY ignore the Slug entity-header (i.e. not even storing it) 
or they MAY alter its value in any way before using it; for example, 
they might filter out some characters or replace accented letters with 
non-accented ones, spaces with underscores, etc.

Renumber following subsections and update section 8.3 (Example) to use the Slug entity-header:

8.3 Example

Below, the client sends a POST request containing an Atom Entry 
representation to the URI of the Collection:

    POST /myblog/entries HTTP/1.1
    User- Agent: Thingio/1.0
    Content- Type: application/atom+xml
    Content- Length: nnn
    Slug: =?utf-8?q?Bill=20de=20h=C3=93ra?=

    <?xml version="1.0" ?>
    <entry xmlns="">
      <title>Bill de h&#xD3;ra: one of the Atom Publishing Protocol editors</title>
      <author><name>John Doe</name></author>
      <content>Some text.</content>

The server signals a successful creation with a status code of 201. 
The response includes a "Location" header indicating the URI of the 
Atom Entry and a representation of that Entry in the body of the 

    HTTP/1.1 201 Created
    Date: Fri, 7 Oct 2005 17:17:11 GMT
    Content- Length: nnn
    Content- Type: application/atom+xml; charset="utf-8"
    Content- Location:
    Slug: =?utf-8?q?Bill=20de=20h=C3=93ra?=

    <?xml version="1.0"?>
    <entry xmlns="">
      <title>Bill de h&#xD3;ra: one of the Atom Publishing Protocol editors</title>
      <author><name>John Doe</name></author>
      <content>Some text.</content>
      <link rel="edit" 

Note that the Entry created by the server might not match exactly 
the Entry POSTed by the client. In particular, a server MAY change 
the values of various elements in the Entry such as the atom:id, 
atom:updated and atom:author values and MAY choose to remove or 
add other elements and attributes, or change element and attribute 

In particular, the publishing system in this example created a new 
atom:id for the entry, based on the slug, and added an 
atom:published element.

Note: the example in section 8.5.2 (renumbered from 8.4.2) could be updated to use the "Slug" entity-header as well.