PUT
Update (fill in) an audit

Authorizations

Authorization
string
header
required

Obtain a token via POST /api/v1/oauth/token (password grant) and send it as Authorization: Bearer <token>.

Path Parameters

database
string
required

Project identifier (each project has its own database). Obtain it from GET /api/v2/data/projects.

auditId
string
required

Body

application/json
_id
string
_rev
string
type
string
Example:

"IB.EdBundle.Document.Audit"

name
string
template
string

Source audit template id.

groupId
string

Template group reference.

status
string

The audit's status. New audits start In Progress; set it to completed (and fill dates.completionDate) with the audit update when the audit is finished.

Treat completed and Completed as equivalent: filters match the value exactly, so a query for finished audits must pass both. dates.completionDate — empty on a new audit, filled once it is finished — is the sturdier signal.

Example:

"In Progress"

archived
string
isPublished
boolean
tags
string[]
dates
object
author
object
participants
object
questions
object[]

The question tree with its answers, exactly two levels deep: this array holds categories, and each category holds questions. It is copied from the template when the audit is created; fill it in by setting each question's answer and send the whole document back with PUT.

maps
object[]
signature
object[]

Response

Write acknowledgement; rev is the audit's new _rev.

The database's acknowledgement of a write. rev is the document's new _rev.

ok
boolean
Example:

true

id
string
rev
string
Example:

"2-9a1c…"