Skip to main content
POST
Preview a write to a log

Authorizations

Authorization
string
header
required

Effective API key. Send Authorization: Bearer sk-eai-...

Path Parameters

id
string
required

Your organization’s ID for the program, chosen at its first upload: lowercase letters, digits, dots, underscores and hyphens. A rater’s program ID is its rater ID.

Required string length: 1 - 128
Pattern: ^[a-z0-9][a-z0-9._-]{0,127}$
log
string<uuid>
required

The log’s id: a UUID the caller chooses when it opens the log, such as the id of the case the log decides. One id has one log.

Body

application/json

One write: its commands, recorded together or not at all.

commands
object[]
required
Required array length: 1 - 500 elements
basedOn
integer

The last entry the writer read (its seq). The write is refused as stale when what it reads changed after it; a write elsewhere in the log is not. Omit to write against the head.

Required range: x >= 0
role
string

The role to act in, for a caller who holds several on this guideline. Defaults to the only one held.

Pattern: ^[a-z_][a-z0-9_]{0,63}$/u

Response

What the write would record and the verdict after it.

head
integer
required

The log’s last entry, which a what-if does not move.

entries
object[]
required

The entries the write would record.

verdict
object
required

The verdict after them.