Skip to main content
POST
Prettier Config Generator

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
ioFormat
enum<string>

Output Format

Available options:
json,
yaml,
esm,
cjs,
pkg
ioPrintWidth
number

printWidth

Required range: 20 <= x <= 200
ioTabWidth
number

tabWidth

Required range: 1 <= x <= 16
ioUseTabs
boolean

useTabs — indent with tabs instead of spaces

ioSemi
boolean

semi — print semicolons at end of statements

ioSingleQuote
boolean

singleQuote — use single quotes instead of double

ioQuoteProps
enum<string>

quoteProps

Available options:
as-needed,
consistent,
preserve
ioTrailingComma
enum<string>

trailingComma

Available options:
all,
es5,
none
ioBracketSpacing
boolean

bracketSpacing — spaces inside object literals { foo }

ioBracketSameLine
boolean

bracketSameLine — keep > of multi-line HTML/JSX on last line

ioArrowParens
enum<string>

arrowParens

Available options:
always,
avoid
ioEndOfLine
enum<string>

endOfLine

Available options:
lf,
crlf,
cr,
auto
ioJsxSingleQuote
boolean

jsxSingleQuote — use single quotes in JSX attributes

ioSingleAttributePerLine
boolean

singleAttributePerLine — one HTML/JSX attribute per line

ioProseWrap
enum<string>

proseWrap

Available options:
preserve,
always,
never
ioHtmlWhitespace
enum<string>

htmlWhitespaceSensitivity

Available options:
css,
strict,
ignore
ioOverrideMarkdown
boolean

Markdown (*.md, *.mdx) — proseWrap: always, printWidth: 100

ioOverrideHtml
boolean

HTML (*.html) — printWidth: 120, singleAttributePerLine: true

ioOverrideYaml
boolean

YAML (*.yml, *.yaml) — tabWidth: 2, singleQuote: false

ioOverrideJson
boolean

JSON (*.json) — printWidth: 200, trailingComma: none

ioIncludeHeader
boolean

Include descriptive header comment (JS/YAML formats only)

ioIncludeIgnore
boolean

Also generate a .prettierignore template

Response

Tool output

tool
string
required
tool_version
string
required

Output-contract version for this tool. Currently "1" for all tools.

outputs
object
required
credits_used
integer
required

Credits this call consumed, after any settlement refund. 0 when metering is disabled.

request_id
string
credits_remaining
integer | null

Credits left in the current monthly allowance, or null when metering is disabled.