| Apr | MAY | Jun |
| 13 | ||
| 2017 | 2018 | 2019 |
COLLECTED BY
Collection: University of Oklahoma Libraries
POST /markdown
| Name | Type | Description |
|---|---|---|
text |
string |
Required. The Markdown text to render in HTML. Markdown content must be 400 KB or less. |
mode |
string |
The rendering mode. Can be either: * markdown to render a document in plain Markdown, just like README.md files are rendered. * gfm to render a document in GitHub Flavored Markdown, which creates links for user mentions as well as references to SHA-1 hashes, issues, and pull requests.Default: markdown
|
context |
string |
The repository context to use when creating references in gfm mode. Omit this parameter when using markdown mode. |
{
"text": "Hello world github/linguist#1 **cool**, and #1!",
"mode": "gfm",
"context": "github/gollum"
}
Status: 200 OK
Content-Type: text/html
Content-Length: 279
X-CommonMarker-Version: 0.17.4
<p>Hello world <a href="http://github.com/github/linguist/issues/1" class="issue-link" title="This is a simple issue">github/linguist#1</a> <strong>cool</strong>, and <a href="http://github.com/github/gollum/issues/1" class="issue-link" title="This is another issue">#1</a>!</p>
POST /markdown/raw
Content-Type header of text/plainortext/x-markdown) to this endpoint, rather than using JSON format. In raw mode, GitHub Flavored Markdown is not supported and Markdown will be rendered in plain format like a README.md file. Markdown content must be 400 KB or less.
curl https://api.github.com/markdown/raw -X "POST" -H "Content-Type: text/plain" -d "Hello world github/linguist#1 **cool**, and #1!"
Status: 200 OK
Content-Type: text/html
Content-Length: 68
X-CommonMarker-Version: 0.17.4
<p>Hello world github/linguist#1 <strong>cool</strong>, and #1!</p>