Skip to content

Commit 190079f

Browse files
committed
Merge branch 'gh-pages' into profile-extensions
2 parents 8510772 + 12febcb commit 190079f

File tree

417 files changed

+21491
-97
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

417 files changed

+21491
-97
lines changed

_config.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,23 +16,22 @@ whitelist:
1616
- jekyll-gist
1717
- jemoji
1818
incremental: false
19-
highlighter: rouge
2019
gist:
2120
noscript: false
2221
# customize github pages
2322
quiet: false
23+
markdown: kramdown
24+
highlighter: rouge
2425
kramdown:
2526
input: GFM
2627
hard_wrap: false
28+
auto_ids: false
2729
template: '' # cannot customize
2830
math_engine: mathjax # cannot customize
2931
syntax_highligher: rouge # cannot customize
30-
jailed: false
32+
3133
gems:
3234
- jekyll-redirect-from
33-
markdown: redcarpet
34-
redcarpet:
35-
extensions: ["tables"]
3635

3736
exclude:
3837
- Rakefile
@@ -43,6 +42,7 @@ exclude:
4342
- .gitignore
4443
- ./public
4544
- ./stylesheets/*.scss
45+
4646
port: 9876
4747

4848
collections:

_format/1.0/index.md

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,7 @@ and versioning.
5555
## <a href="#document-structure" id="document-structure" class="headerlink"></a> Document Structure
5656

5757
This section describes the structure of a JSON API document, which is identified
58-
by the media type [`application/vnd.api+json`]
59-
(http://www.iana.org/assignments/media-types/application/vnd.api+json).
58+
by the media type [`application/vnd.api+json`](http://www.iana.org/assignments/media-types/application/vnd.api+json).
6059
JSON API documents are defined in JavaScript Object Notation (JSON)
6160
[[RFC7159](http://tools.ietf.org/html/rfc7159)].
6261

@@ -520,7 +519,7 @@ The following `self` link is simply a URL:
520519

521520
```json
522521
"links": {
523-
"self": "http://example.com/posts",
522+
"self": "http://example.com/posts"
524523
}
525524
```
526525

@@ -622,11 +621,11 @@ The following characters **MUST NOT** be used in member names:
622621
- U+003E GREATER-THAN SIGN, ">"
623622
- U+003F QUESTION MARK, "?"
624623
- U+0040 COMMERCIAL AT, "@"
625-
- U+005C REVERSE SOLIDUS, "\"
624+
- U+005C REVERSE SOLIDUS, "&#x5c;"
626625
- U+005E CIRCUMFLEX ACCENT, "^"
627626
- U+0060 GRAVE ACCENT, "&#x60;"
628627
- U+007B LEFT CURLY BRACKET, "{"
629-
- U+007C VERTICAL LINE, "|"
628+
- U+007C VERTICAL LINE, "&#x7c;"
630629
- U+007D RIGHT CURLY BRACKET, "}"
631630
- U+007E TILDE, "~"
632631
- U+007F DELETE
@@ -1173,7 +1172,7 @@ Accept: application/vnd.api+json
11731172

11741173
If a relationship is provided in the `relationships` member of the
11751174
[resource object][resource objects], its value **MUST** be a relationship object with a `data`
1176-
member. The value of this key represents the linkage the new resource is to
1175+
member. The value of this key represents the [linkage][resource linkage] the new resource is to
11771176
have.
11781177

11791178
#### <a href="#crud-creating-client-ids" id="crud-creating-client-ids" class="headerlink"></a> Client-Generated IDs
@@ -1273,6 +1272,11 @@ had returned it back in a `201` response.
12731272
A server **MAY** return `403 Forbidden` in response to an unsupported request
12741273
to create a resource.
12751274

1275+
##### <a href="#crud-creating-responses-404" id="crud-creating-responses-404" class="headerlink"></a> 404 Not Found
1276+
1277+
A server **MUST** return `404 Not Found` when processing a request that
1278+
references a related resource that does not exist.
1279+
12761280
##### <a href="#crud-creating-responses-409" id="crud-creating-responses-409" class="headerlink"></a> 409 Conflict
12771281

12781282
A server **MUST** return `409 Conflict` when processing a `POST` request to
@@ -1720,6 +1724,11 @@ request is successful and no content is returned.
17201724
A server **MUST** return a `200 OK` status code if a deletion request is
17211725
successful and the server responds with only top-level [meta] data.
17221726

1727+
##### <a href="#crud-deleting-responses-404" id="crud-deleting-responses-404" class="headerlink"></a> 404 NOT FOUND
1728+
1729+
A server **SHOULD** return a `404 Not Found` status code if a deletion request fails
1730+
due to the resource not existing.
1731+
17231732
##### <a href="#crud-deleting-responses-other" id="crud-deleting-responses-other" class="headerlink"></a> Other Responses
17241733

17251734
A server **MAY** respond with other HTTP status codes.

_format/1.0/normative-statements.json

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,7 @@ layout: null
181181
{ "id": "create-responses-202", "type": "normative-statements" },
182182
{ "id": "create-responses-204", "type": "normative-statements" },
183183
{ "id": "create-responses-403", "type": "normative-statements" },
184+
{ "id": "create-responses-404-related", "type": "normative-statements" },
184185
{ "id": "create-responses-409-exists", "type": "normative-statements" },
185186
{ "id": "create-responses-409-bad-type", "type": "normative-statements" },
186187
{ "id": "create-responses-409-error-details", "type": "normative-statements" },
@@ -239,6 +240,7 @@ layout: null
239240
{ "id": "delete-202-status", "type": "normative-statements" },
240241
{ "id": "delete-204-status", "type": "normative-statements" },
241242
{ "id": "delete-200-status", "type": "normative-statements" },
243+
{ "id": "delete-404-status", "type": "normative-statements" },
242244
{ "id": "deleting-other-status", "type": "normative-statements" },
243245
{ "id": "deleting-other-details", "type": "normative-statements" },
244246
{ "id": "deleting-http-semantics", "type": "normative-statements" }
@@ -1769,6 +1771,19 @@ layout: null
17691771
}
17701772
}
17711773
},
1774+
{
1775+
"id": "create-responses-404-related",
1776+
"type": "normative-statements",
1777+
"attributes": {
1778+
"level": "MAY",
1779+
"description": "A server **MUST** return `404 Not Found` when processing a request that references a related resource that does not exist."
1780+
},
1781+
"relationships": {
1782+
"section": {
1783+
"data": { "id": "creating-updating-deleting", "type": "sections" }
1784+
}
1785+
}
1786+
},
17721787
{
17731788
"id": "create-responses-409-exists",
17741789
"type": "normative-statements",
@@ -2523,6 +2538,19 @@ layout: null
25232538
}
25242539
}
25252540
},
2541+
{
2542+
"id": "delete-404-status",
2543+
"type": "normative-statements",
2544+
"attributes": {
2545+
"level": "SHOULD",
2546+
"description": "A server **SHOULD** return a 404 Not Found status code if a deletion request fails due to the resource not existing."
2547+
},
2548+
"relationships": {
2549+
"section": {
2550+
"data": { "id": "creating-updating-deleting", "type": "sections" }
2551+
}
2552+
}
2553+
},
25262554
{
25272555
"id": "deleting-other-status",
25282556
"type": "normative-statements",
@@ -2631,7 +2659,7 @@ layout: null
26312659
"id": "error-object-key",
26322660
"type": "normative-statements",
26332661
"attributes": {
2634-
"level": "SHOULD",
2662+
"level": "MUST",
26352663
"description": "Error objects **MUST** be returned as an array keyed by `errors` in the top level of a JSON API document."
26362664
},
26372665
"relationships": {

_format/1.1/index.md

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,10 @@ negotiation and versioning.
6161

6262
## <a href="#document-structure" id="document-structure" class="headerlink"></a> Document Structure
6363

64-
This section describes the structure of a JSON API document. JSON API documents
65-
are defined in JavaScript Object Notation (JSON)[[RFC4627](http://tools.ietf.org/html/rfc4627)].
64+
This section describes the structure of a JSON API document, which is identified
65+
by the media type [`application/vnd.api+json`](http://www.iana.org/assignments/media-types/application/vnd.api+json).
66+
JSON API documents are defined in JavaScript Object Notation (JSON)
67+
[[RFC7159](http://tools.ietf.org/html/rfc7159)].
6668

6769
Although the same media type is used for both request and response documents,
6870
certain aspects are only applicable to one or the other. These differences are
@@ -673,11 +675,11 @@ The following characters **MUST NOT** be used in member names:
673675
- U+003E GREATER-THAN SIGN, ">"
674676
- U+003F QUESTION MARK, "?"
675677
- U+0040 COMMERCIAL AT, "@"
676-
- U+005C REVERSE SOLIDUS, "\"
678+
- U+005C REVERSE SOLIDUS, "&#x5c;"
677679
- U+005E CIRCUMFLEX ACCENT, "^"
678680
- U+0060 GRAVE ACCENT, "&#x60;"
679681
- U+007B LEFT CURLY BRACKET, "{"
680-
- U+007C VERTICAL LINE, "|"
682+
- U+007C VERTICAL LINE, "&#x7c;"
681683
- U+007D RIGHT CURLY BRACKET, "}"
682684
- U+007E TILDE, "~"
683685
- U+007F DELETE
@@ -1244,7 +1246,7 @@ Accept: application/vnd.api+json
12441246

12451247
If a relationship is provided in the `relationships` member of the
12461248
[resource object][resource objects], its value **MUST** be a relationship object with a `data`
1247-
member. The value of this key represents the linkage the new resource is to
1249+
member. The value of this key represents the [linkage][resource linkage] the new resource is to
12481250
have.
12491251

12501252
#### <a href="#crud-creating-client-ids" id="crud-creating-client-ids" class="headerlink"></a> Client-Generated IDs
@@ -1345,6 +1347,11 @@ had returned it back in a `201` response.
13451347
A server **MAY** return `403 Forbidden` in response to an unsupported request
13461348
to create a resource.
13471349

1350+
##### <a href="#crud-creating-responses-404" id="crud-creating-responses-404" class="headerlink"></a> 404 Not Found
1351+
1352+
A server **MUST** return `404 Not Found` when processing a request that
1353+
references a related resource that does not exist.
1354+
13481355
##### <a href="#crud-creating-responses-409" id="crud-creating-responses-409" class="headerlink"></a> 409 Conflict
13491356

13501357
A server **MUST** return `409 Conflict` when processing a `POST` request to
@@ -1792,6 +1799,11 @@ request is successful and no content is returned.
17921799
A server **MUST** return a `200 OK` status code if a deletion request is
17931800
successful and the server responds with only top-level [meta] data.
17941801

1802+
##### <a href="#crud-deleting-responses-404" id="crud-deleting-responses-404" class="headerlink"></a> 404 NOT FOUND
1803+
1804+
A server **SHOULD** return a `404 Not Found` status code if a deletion request fails
1805+
due to the resource not existing.
1806+
17951807
##### <a href="#crud-deleting-responses-other" id="crud-deleting-responses-other" class="headerlink"></a> Other Responses
17961808

17971809
A server **MAY** respond with other HTTP status codes.

_format/1.1/normative-statements.json

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,7 @@ layout: null
185185
{ "id": "create-responses-202", "type": "normative-statements" },
186186
{ "id": "create-responses-204", "type": "normative-statements" },
187187
{ "id": "create-responses-403", "type": "normative-statements" },
188+
{ "id": "create-responses-404-related", "type": "normative-statements" },
188189
{ "id": "create-responses-409-exists", "type": "normative-statements" },
189190
{ "id": "create-responses-409-bad-type", "type": "normative-statements" },
190191
{ "id": "create-responses-409-error-details", "type": "normative-statements" },
@@ -243,6 +244,7 @@ layout: null
243244
{ "id": "delete-202-status", "type": "normative-statements" },
244245
{ "id": "delete-204-status", "type": "normative-statements" },
245246
{ "id": "delete-200-status", "type": "normative-statements" },
247+
{ "id": "delete-404-status", "type": "normative-statements" },
246248
{ "id": "deleting-other-status", "type": "normative-statements" },
247249
{ "id": "deleting-other-details", "type": "normative-statements" },
248250
{ "id": "deleting-http-semantics", "type": "normative-statements" }
@@ -1825,6 +1827,19 @@ layout: null
18251827
}
18261828
}
18271829
},
1830+
{
1831+
"id": "create-responses-404-related",
1832+
"type": "normative-statements",
1833+
"attributes": {
1834+
"level": "MAY",
1835+
"description": "A server **MUST** return `404 Not Found` when processing a request that references a related resource that does not exist."
1836+
},
1837+
"relationships": {
1838+
"section": {
1839+
"data": { "id": "creating-updating-deleting", "type": "sections" }
1840+
}
1841+
}
1842+
},
18281843
{
18291844
"id": "create-responses-409-exists",
18301845
"type": "normative-statements",
@@ -2579,6 +2594,19 @@ layout: null
25792594
}
25802595
}
25812596
},
2597+
{
2598+
"id": "delete-404-status",
2599+
"type": "normative-statements",
2600+
"attributes": {
2601+
"level": "SHOULD",
2602+
"description": "A server **SHOULD** return a 404 Not Found status code if a deletion request fails due to the resource not existing."
2603+
},
2604+
"relationships": {
2605+
"section": {
2606+
"data": { "id": "creating-updating-deleting", "type": "sections" }
2607+
}
2608+
}
2609+
},
25822610
{
25832611
"id": "deleting-other-status",
25842612
"type": "normative-statements",
@@ -2687,7 +2715,7 @@ layout: null
26872715
"id": "error-object-key",
26882716
"type": "normative-statements",
26892717
"attributes": {
2690-
"level": "SHOULD",
2718+
"level": "MUST",
26912719
"description": "Error objects **MUST** be returned as an array keyed by `errors` in the top level of a JSON API document."
26922720
},
26932721
"relationships": {

_layouts/page.html

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,18 @@
77

88
{% comment %}
99
Below, we're either dealing with a generic page or a page from the
10-
specification collection. Generic pages have a title, so we identify
11-
them that way. For specification pages, we build the title dynamically to
12-
take into account the version number and its relationship to the latest version.
10+
specification collection. For generic pages, we get a title just by
11+
reading page.title but, for specification pages, we build their title
12+
dynamically to take into account the page's version number and its
13+
relationship to the latest version.
1314
{% endcomment %}
1415

15-
{% if page.title %}
16-
{% comment %}We're on a generic page.{% endcomment %}
17-
{% assign page_title = page.title %}
18-
19-
{% else %}
16+
{% if page.is_spec_page %}
2017
{% capture page_title %}
2118
{% include title_for_version.md is_latest_version=page.is_latest_version is_upcoming_version=page.is_upcoming_version version=page.version %}
2219
{% endcapture %}
20+
{% else %}
21+
{% assign page_title = page.title %}
2322
{% endif %}
2423
<title>JSON API &mdash; {{page_title|strip }}</title>
2524

@@ -117,19 +116,15 @@ <h2>A specification for building APIs in JSON</h2>
117116
</select>
118117
</div>
119118
{% else %}
120-
<h1 class="sidebar-top">{{ page.title }}</h1>
119+
<h1 class="sidebar-top">{{ page_title }}</h1>
121120
{% endif %}
122121
</nav>
123122
</div>
124123
{% endif %}
125124
<div class="content">
126125
{% unless page.show_masthead %}
127126
<h1>
128-
{% if page.is_spec_page %}
129-
{{ page_title }}
130-
{% else %}
131-
{{ page.title }}
132-
{% endif %}
127+
{{ page_title }}
133128
</h1>
134129
{% endunless %}
135130
<section>

about/index.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ There are five primary editors of this specification:
2525
## <a href="#roadmap" id="roadmap" class="headerlink"></a> Roadmap
2626

2727
### <a href="#roadmap-1-1" id="roadmap-1-1" class="headerlink"></a> 1.1
28-
**Targeted Release Date:** September 30th, 2015
2928

3029
* Embedding / creating multiple related resources in a single request
3130
* Extension support

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy