Questionnaire
Parse security questionnaires, generate answers from approved evidence, save reviewer edits, stream progress, and export completed files.
List security questionnaires
/v1/questionnaireList saved security questionnaires for an organization so teams can track customer reviews, answer status, and response history.
Responses
200List of questionnaires
curl --request GET \
--url https://api.complianz.ai/v1/questionnaire \
--header 'X-API-Key: <api-key>'Get security questionnaire details
/v1/questionnaire/{id}Retrieve one saved security questionnaire, including extracted questions, generated answers, and review context for the requesting client.
Path parameters
idstringrequiredResponses
200Questionnaire details
curl --request GET \
--url https://api.complianz.ai/v1/questionnaire/<id> \
--header 'X-API-Key: <api-key>'Delete a security questionnaire
/v1/questionnaire/{id}Delete a saved security questionnaire when a customer review or vendor assessment no longer needs to be retained.
Path parameters
idstringrequiredResponses
200Questionnaire deleted
curl --request DELETE \
--url https://api.complianz.ai/v1/questionnaire/<id> \
--header 'X-API-Key: <api-key>'Generate answers for a questionnaire
/v1/questionnaire/{id}/auto-answerStarts background answer generation for an already-parsed questionnaire and returns a run handle immediately. Poll GET /v1/questionnaire/:id until answeredQuestions equals totalQuestions, then read the answers from its questions.
Path parameters
idstringrequiredResponses
200
questionnaireIdstringrequiredThe questionnaire whose answers are being generated.
runIdstringrequiredBackground run identifier for the generation job (Trigger.dev run id).
publicAccessTokenstringrequiredToken for tracking the run via Trigger.dev realtime. Optional — MCP/agent clients should poll GET /v1/questionnaire/:id instead.
statusstringrequiredAlways 'generating' on a successful trigger. Poll GET /v1/questionnaire/:id; answers are ready once answeredQuestions equals totalQuestions.
totalQuestionsnumberrequiredTotal number of questions in the questionnaire.
answeredQuestionsnumberrequiredQuestions already answered at the moment generation was triggered (answers without a value are (re)generated).
messagestringrequiredHuman-readable summary of what to do next.
{
"questionnaireId": "qst_6a179d26c4ad2c1c816ee16d",
"runId": "run_cmpotsz153eac0ultc1ya87f5",
"publicAccessToken": "pat_...",
"status": "generating",
"totalQuestions": 23,
"answeredQuestions": 0,
"message": "Generating answers for 23 questions. Poll GET /v1/questionnaire/qst_... until answeredQuestions reaches totalQuestions."
}curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/<id>/auto-answer \
--header 'X-API-Key: <api-key>'Parse questionnaire content
/v1/questionnaire/parseParse questionnaire content from a submitted payload so teams can extract security questions before generating or reviewing answers.
Request body
Responses
200Parsed questionnaire content
{}curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/parse \
--header 'X-API-Key: <api-key>' \
--header 'Content-Type: application/json' \
--data '{}'Answer one questionnaire question
/v1/questionnaire/answer-singleGenerate an answer for one security questionnaire item using the organization evidence library and return source references for review.
Request body
questionstringrequiredSecurity questionnaire question to answer.
questionIndexnumberrequiredZero-based index of this question in the questionnaire or page batch.
totalQuestionsnumberrequiredTotal number of questions in the current questionnaire or page batch.
organizationIdstringrequiredOrganization ID for validation. The API uses the authenticated active organization and overwrites this value server-side.
questionnaireIdstringOptional questionnaire record to save the generated answer into. Omit for webpage-only answer generation.
Responses
200Generated single answer result
successbooleandataobjectShow child attributes
questionIndexnumberquestionstringanswerstringsourcesobject[]errorstring{
"success": true,
"data": {
"questionIndex": 0,
"question": "string",
"answer": "string",
"sources": [
{}
],
"error": "string"
}
}curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/answer-single \
--header 'X-API-Key: <api-key>' \
--header 'Content-Type: application/json' \
--data '{
"question": "Do you encrypt customer data at rest?",
"questionIndex": 0,
"totalQuestions": 12,
"organizationId": "org_abc123",
"questionnaireId": "qst_abc123"
}'Save questionnaire answer
/v1/questionnaire/save-answerSave a manual or AI-generated security questionnaire answer for later review, export, and audit tracking.
Request body
Responses
200Save manual or generated answer
successbooleanerrorstring{
"success": true,
"error": "string"
}curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/save-answer \
--header 'X-API-Key: <api-key>' \
--header 'Content-Type: application/json' \
--data '{}'Delete questionnaire answer
/v1/questionnaire/delete-answerDelete a stored questionnaire answer when it should be removed from the active response set.
Request body
Responses
200Delete questionnaire answer
successbooleanerrorstring{
"success": true,
"error": "string"
}curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/delete-answer \
--header 'X-API-Key: <api-key>' \
--header 'Content-Type: application/json' \
--data '{}'Export a security questionnaire
/v1/questionnaire/exportExport a saved security questionnaire response package as PDF, CSV, or XLSX for customer and vendor security reviews.
Request body
Responses
200Export questionnaire by ID to specified format
curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/export \
--header 'X-API-Key: <api-key>' \
--header 'Content-Type: application/json' \
--data '{}'Start questionnaire parsing
/v1/questionnaire/upload-and-parseUpload a questionnaire payload and start asynchronous parsing, returning a run ID for real-time progress tracking.
Request body
organizationIdstringrequiredOrganization ID (set automatically from auth context).
fileNamestringrequiredName of the questionnaire file.
fileTypestringrequiredMIME type of the file (PDF, image, XLSX, CSV, TXT).
fileDatastringBase64-encoded file contents. For the web UI / direct callers. AI/MCP clients should instead upload via /v1/uploads/presign and pass `s3Key` — base64 through an LLM is impractically slow. Provide exactly one of fileData or s3Key.
s3KeystringKey of a file already uploaded via /v1/uploads/presign (purpose=questionnaire). The server fetches the bytes from storage — no base64 needed. Provide exactly one of fileData or s3Key.
Responses
200Upload file and trigger async parsing. Returns runId for realtime tracking.
runIdstringpublicAccessTokenstring{
"runId": "string",
"publicAccessToken": "string"
}curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/upload-and-parse \
--header 'X-API-Key: <api-key>' \
--header 'Content-Type: application/json' \
--data '{
"organizationId": "org_abc123",
"fileName": "vendor-security-questionnaire.xlsx",
"fileType": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
"fileData": "string",
"s3Key": "org_abc/uploads/questionnaire/1735000000-questionnaire.xlsx"
}'Upload and parse questionnaire file
/v1/questionnaire/upload-and-parse/uploadUpload a security questionnaire file, extract questions, save the parsed questionnaire, and return its identifier and question count.
Responses
200Upload file, parse questions (no answers), save to DB, return questionnaireId
questionnaireIdstringtotalQuestionsnumber{
"questionnaireId": "string",
"totalQuestions": 0
}curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/upload-and-parse/upload \
--header 'X-API-Key: <api-key>'Auto-answer uploaded questionnaire
/v1/questionnaire/parse/uploadUpload a questionnaire file and generate answer exports from approved organization evidence in PDF, CSV, or XLSX format.
Responses
201
curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/parse/upload \
--header 'X-API-Key: <api-key>'Export generated questionnaire answers
/v1/questionnaire/answers/exportGenerate and export questionnaire answers from a submitted payload using approved organization evidence.
Request body
Responses
201
curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/answers/export \
--header 'X-API-Key: <api-key>' \
--header 'Content-Type: application/json' \
--data '{}'Upload and export generated answers
/v1/questionnaire/answers/export/uploadUpload a questionnaire file and return generated answer exports in PDF, CSV, or XLSX format.
Responses
201
curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/answers/export/upload \
--header 'X-API-Key: <api-key>'Stream generated questionnaire answers
/v1/questionnaire/auto-answerStream generated questionnaire answers over server-sent events so clients can show progress while answers are produced.
Request body
Responses
201
curl --request POST \
--url https://api.complianz.ai/v1/questionnaire/auto-answer \
--header 'X-API-Key: <api-key>' \
--header 'Content-Type: application/json' \
--data '{}'