Skip to content

Commit 4caab67

Browse files
committed
describe new mime type stuff, add a real change log
1 parent 136941d commit 4caab67

File tree

4 files changed

+80
-95
lines changed

4 files changed

+80
-95
lines changed

content/index.md

Lines changed: 2 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -10,34 +10,6 @@ you have any problems or requests please contact
1010

1111
For the new API v3, start browsing the resources on the right >>
1212

13-
## Breaking BETA Changes
13+
View the [API Changelog](/v3/changelog) for information on existing and
14+
planned changes to the API.
1415

15-
We're making some small tweaks to the API during the BETA phase. Old
16-
behavior will be supported until the dates listed below. Please be sure
17-
to update your app in time.
18-
19-
### Behavior due to be removed by July 20th:
20-
21-
* `integrate_branch` on the [repo API](/v3/repos/#get) will no longer be
22-
returned.
23-
24-
### Changelog for breaking changes
25-
26-
#### Removed on June 15th:
27-
28-
* `gravatar_url` is being deprecated in favor of `avatar_url` for all
29-
responses that include users or orgs. A default size is no longer
30-
included in the url.
31-
* Creating new gists (both anonymously and with an authenticated user)
32-
should use `POST /gists` from now on. `POST /users/:user/gists` is no
33-
longer supported.
34-
35-
#### Removed on June 1st:
36-
37-
* Removed support for PUT verb on update requests. Use POST or PATCH
38-
instead.
39-
* Removed `.json` extension from all URLs.
40-
* No longer using the X-Next or X-Last headers. Pagination info is
41-
returned in the Link header instead.
42-
* JSON-P response has completely changed to a more consistent format.
43-
* Starring gists now uses PUT verb (instead of POST) and returns 204.

content/v3/changelog.md

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
---
2+
title: GitHub API Changelog
3+
---
4+
5+
# Current Version
6+
7+
The GitHub API version is currently in beta. The Accept mime type is
8+
`application/vnd.github.beta+json`. The `beta` mime type property will
9+
be valid until sometime in 2012. A notice will be given closer to the
10+
actual date.
11+
12+
We consider the beta API unbreakable, so please [file a support
13+
issue](https://github.com/contact) if you have problems.
14+
15+
## Upcoming Version
16+
17+
The API is expected to be finalized in late 2011.
18+
19+
### Expected Changes
20+
21+
* `integrate_branch` on the [repo API](/v3/repos/#get) will no longer be
22+
returned.
23+
24+
## Breaking Beta Changes
25+
26+
#### Removed on June 15th:
27+
28+
* `gravatar_url` is being deprecated in favor of `avatar_url` for all
29+
responses that include users or orgs. A default size is no longer
30+
included in the url.
31+
* Creating new gists (both anonymously and with an authenticated user)
32+
should use `POST /gists` from now on. `POST /users/:user/gists` is no
33+
longer supported.
34+
35+
#### Removed on June 1st:
36+
37+
* Removed support for PUT verb on update requests. Use POST or PATCH
38+
instead.
39+
* Removed `.json` extension from all URLs.
40+
* No longer using the X-Next or X-Last headers. Pagination info is
41+
returned in the Link header instead.
42+
* JSON-P response has completely changed to a more consistent format.
43+
* Starring gists now uses PUT verb (instead of POST) and returns 204.

content/v3/mime.md

Lines changed: 34 additions & 65 deletions
Original file line numberDiff line numberDiff line change
@@ -2,116 +2,85 @@
22
title: Custom Mime Types | GitHub API
33
---
44

5-
# Custom Mime Types
5+
# GitHub Mime Types
66

77
Custom mime types are used in the API to let consumers choose the format
88
of the data they wish to receive. This is done by adding one or more of
99
the following types to the `Accept` header when you make a request. Mime
1010
types are specific to resources, allowing them to change independently
1111
and support formats that other resources don't.
1212

13-
## Issue
13+
All GitHub mime types look like this:
1414

15-
The body of an issue can be written in [GitHub Flavored Markdown][gfm].
16-
These mime types are allowed:
15+
application/vnd.github[.version].param[+json]
16+
17+
The most basic mime types the API supports are:
18+
19+
application/json
20+
application/vnd.github+json
21+
22+
Neither of these specify a version, so you will always get the latest
23+
JSON representation of resources. If you're building an application and
24+
care about the stability of the API, specify a version like so:
25+
26+
application/vnd.github.beta+json
27+
28+
If you're specifying a property (such as full/raw/etc defined below),
29+
put the version before the property:
30+
31+
application/vnd.github.beta.raw+json
32+
33+
For specifics on versions, check the [API changelog](/v3/changelog).
34+
35+
## Comment Body Properties
36+
37+
The body of a comments can be written in [GitHub Flavored Markdown][gfm].
38+
Issues, Issue Comments, Pull Request Comments, and Gist Comments all
39+
accept these same mime types:
1740

1841
### Raw
1942

20-
application/vnd.github-issue.raw+json
43+
application/vnd.github.VERSION.raw+json
2144

2245
Return the raw markdown body. Response will include `body`. This is the
2346
default if you do not pass any specific mime type.
2447

2548
### Text
2649

27-
application/vnd.github-issue.text+json
50+
application/vnd.github.VERSION.text+json
2851

2952
Return a text only representation of the markdown body. Response will
3053
include `body_text`.
3154

3255
### Html
3356

34-
application/vnd.github-issue.html+json
57+
application/vnd.github.VERSION.html+json
3558

3659
Return html rendered from the body's markdown. Response will include
3760
`body_html`.
3861

3962
### Full
4063

41-
application/vnd.github-issue.full+json
64+
application/vnd.github.VERSION.full+json
4265

4366
Return raw, text and html representations. Response will include `body`,
4467
`body_text`, and `body_html`:
4568

46-
## Issue Comment
47-
48-
The body of an issue comment can also be written in [GitHub Flavored
49-
Markdown][gfm]. The semantics are identical to the Issue resource
50-
described above. These mime types are allowed:
51-
52-
application/vnd.github-issuecomment.raw+json
53-
application/vnd.github-issuecomment.text+json
54-
application/vnd.github-issuecomment.html+json
55-
application/vnd.github-issuecomment.full+json
56-
57-
## Commit Comment
58-
59-
The body of an commit comment can also be written in [GitHub Flavored
60-
Markdown][gfm]. The semantics are identical to the Issue resource
61-
described above. These mime types are allowed:
62-
63-
application/vnd.github-commitcomment.raw+json
64-
application/vnd.github-commitcomment.text+json
65-
application/vnd.github-commitcomment.html+json
66-
application/vnd.github-commitcomment.full+json
67-
68-
## Pull Request
69-
70-
The body of an pull request can also be written in [GitHub Flavored
71-
Markdown][gfm]. The semantics are identical to the Issue resource
72-
described above. These mime types are allowed:
73-
74-
application/vnd.github-pull.raw+json
75-
application/vnd.github-pull.text+json
76-
application/vnd.github-pull.html+json
77-
application/vnd.github-pull.full+json
78-
79-
## Pull Request Comment
80-
81-
The body of an pull request comment can also be written in [GitHub
82-
Flavored Markdown][gfm]. The semantics are identical to the Issue
83-
resource described above. These mime types are allowed:
84-
85-
application/vnd.github-pullcomment.raw+json
86-
application/vnd.github-pullcomment.text+json
87-
application/vnd.github-pullcomment.html+json
88-
application/vnd.github-pullcomment.full+json
89-
90-
## Gist Comment
91-
92-
The body of an gist comment can also be written in [GitHub
93-
Flavored Markdown][gfm]. The semantics are identical to the Issue
94-
resource described above. These mime types are allowed:
95-
96-
application/vnd.github-gistcomment.raw+json
97-
application/vnd.github-gistcomment.text+json
98-
application/vnd.github-gistcomment.html+json
99-
application/vnd.github-gistcomment.full+json
100-
101-
## Git Blob
69+
## Git Blob Properties
10270

10371
The following mime types are allowed when getting a blob:
10472

10573
### JSON
10674

75+
application/vnd.github.VERSION+json
10776
application/json
10877

10978
Return JSON representation of the blob with `content` as a base64
11079
encoded string. This is the default if nothing is passed.
11180

11281
### Raw
11382

114-
application/vnd.github-blob.raw
83+
application/vnd.github.VERSION.raw
11584

11685
Return the raw blob data.
11786

layouts/default.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ <h3><a href="#" class="js-expand-btn collapsed">&nbsp;</a><a href="/v3/">Summary
4343
<ul class="js-guides">
4444
<li><a href="/v3/oauth/">OAuth</a></li>
4545
<li><a href="/v3/mime/">Mime Types</a></li>
46+
<li><a href="/v3/changelog/">Changelog</a></li>
4647
<li><a href="/v3/libraries/">Libraries</a></li>
4748
</ul>
4849
</li>

0 commit comments

Comments
 (0)