Skip to main content
POST
Format policy

Authorizations

klef.session
string
cookie
required

Cookie-based session. Obtain by completing the /auth/login/{provider} OAuth flow; the /auth/callback response sets the klef.session cookie that subsequent requests send automatically.

Body

application/json

A document to format. PolicyId names the policy it would be saved over, so it formats against the catalogs the editor compiles it with; leave it out for a document that is not saved anywhere.

source
string
required
Minimum string length: 1
policyId
null | string<uuid>

Response

OK

The envelope for a single-resource response: result on success, otherwise null with one or more errors.

result
null | object
required
errors
object[]
required