Skip to content

Documents

Documents let integrations store structured notes and fetch rendered PDFs.

Endpoints

  • GET /api/v1/documents
  • POST /api/v1/documents
  • GET /api/v1/documents/{document_id}
  • PATCH /api/v1/documents/{document_id}
  • GET /api/v1/documents/{document_id}/view-pdf

Document types

  • note
  • report

The current schema describes notes as user-editable and reports as LLM-generated.

Create a note

curl -sS -X POST "https://app.vulnetic.ai/api/v1/documents" \
  -H "<AUTH_HEADER_NAME>: YOUR_API_CREDENTIAL" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "Acme assessment notes",
    "description": "Tracking notes for the production assessment",
    "content": {
      "summary": "Initial triage complete",
      "next_steps": [
        "Validate access control on admin routes",
        "Review file upload sanitization"
      ]
    }
  }'

List documents

curl -sS "https://app.vulnetic.ai/api/v1/documents?document_type=note&sort_by=updated_at&sort_order=desc" \
  -H "<AUTH_HEADER_NAME>: YOUR_API_CREDENTIAL"

Update a document

curl -sS -X PATCH "https://app.vulnetic.ai/api/v1/documents/55555555-5555-5555-5555-555555555555" \
  -H "<AUTH_HEADER_NAME>: YOUR_API_CREDENTIAL" \
  -H "Content-Type: application/json" \
  -d '{
    "description": "Updated after authenticated validation",
    "content": {
      "summary": "Authenticated triage complete",
      "next_steps": [
        "Retest stored XSS fix",
        "Render final PDF"
      ]
    }
  }'

Render a PDF

curl -sS "https://app.vulnetic.ai/api/v1/documents/55555555-5555-5555-5555-555555555555/view-pdf" \
  -H "<AUTH_HEADER_NAME>: YOUR_API_CREDENTIAL" \
  -o document.pdf

Note

The current OpenAPI response block for view-pdf is loosely modeled. The route description clearly says it renders a visible document as an inline PDF, so the published reference should eventually document the exact response media type and headers.