API 概要に戻る

markdown-render

POST1 クレジット

Renders GitHub-flavored Markdown to either sanitized HTML or plain text. The HTML output is sanitized server-side (no script tags, no inline event handlers).

エンドポイント

POST https://x114.org/api/v1/markdown-render

リクエストボディ

POST ボディに JSON として送信します。

NameTypeRequiredDescription
markdownstringrequiredThe Markdown source. Up to 1 MB of UTF-8.

レスポンスボディ

成功時に返される JSON (HTTP 200)。

NameTypeRequiredDescription
okbooleanrequiredTrue on success.
htmlstringrequiredThe rendered HTML (GitHub-flavored Markdown, raw HTML disabled).

curl -X POST https://x114.org/api/v1/markdown-render \
  -H "Authorization: Bearer sk_..." \
  -H "Content-Type: application/json" \
  -d '{"markdown":"# Hello\n\n**world**"}'

メモ

  • Raw HTML inside the Markdown source is stripped before rendering — script tags and inline event handlers cannot reach the output.
ブラウザで試す

無料ツールならコードを書かずに同じ結果が得られます。

ツールを開く