Documenso Reference ArchitectureCAUTION
Model-agnostic agent-skills platform with a harness-free canonical layer, verified adapters, and the ccpi package manager. Explore at tonsofskills.com.
Overview
Model-agnostic agent-skills platform with a harness-free canonical layer, verified adapters, and the ccpi package manager. Explore at tonsofskills.com.
4f83675ca38aOBSERVED · 2026-10-08Host compatibility
What the documentation claims. We have not run a compatibility test.
| Host | Status | Notes |
|---|---|---|
| claude-code | mentioned |
What it tells the agent
The instruction file, verbatim from the audited commit — this is the text the model reads, and the surface the audit's instruction layer examines. Quoted here so you can judge it without cloning anything.
--- name: documenso-reference-architecture description: 'Implement Documenso reference architecture with best-practice project layout. Use when designing new Documenso integrations, reviewing project structure, or establishing architecture standards for document signing applications. Trigger with phrases like "documenso architecture", "documenso best practices", "documenso project structure", "how to organize documenso". ' allowed-tools: Read, Grep version: 1.14.0 license: MIT author: Jeremy Longshore <[email protected]> tags: - saas - documenso - documenso-reference compatibility: Designed for Claude Code --- # Documenso Reference Architecture ## Instructions 1. Map document producers, templates, recipients, signing actions, audit records, webhooks, and retention boundaries to named owners. 2. Enforce least-privilege identity and separate development/staging/production workspaces and credentials. 3. Define idempotent lifecycle transitions, signed callbacks, redacted observability, and a rollback/incident path before production exposure. 4. Review architecture changes through normal security, data, and change-control processes. ## Output - A documented document/signing architecture with trust boundaries, ownership, and reversible integration points. ## Examples Route a synthetic development document through a scoped service identity, role-limited signer, validated webhook, and redacted audit metric. Promote the same versioned workflow through staging before a production canary; preserve a disabled/rollback path and do not include document URLs or signer identity in diagrams or logs. ## Overview Production-ready architecture for Documenso document signing integrations. Covers project layout, layered service architecture, webhook processing, and data flow. ## Prerequisites - Understanding of layered architecture principles - Documenso SDK knowledge (see `documenso-sdk-patterns`) - TypeScript project with Node.js 18+ ## Recommended Project Structure ``` my-signing-app/ ├── src/ │ ├── documenso/ │ │ ├── client.ts # Singleton SDK client │ │ ├── errors.ts # Custom error classes │ │ ├── retry.ts # Retry/backoff logic │ │ └── types.ts # Shared types │ ├── services/ │ │ ├── document-service.ts # Document CRUD operations │ │ ├── template-service.ts # Template-based workflows │ │ └── signing-service.ts # Orchestrates signing flows │ ├── webhooks/ │ │ ├── handler.ts # Express webhook router │ │ ├── verify.ts # Secret verification │ │ └── processors/ │ │ ├── document-completed.ts │ │ ├── document-signed.ts │ │ └── document-rejected.ts │ ├── api/ │ │ ├── health.ts # Health check endpoint │ │ └── routes.ts # API routes │ └── config/ │ └── index.ts # Environment configuration ├── scripts/ │ ├── verify-connection.ts # Quick health check │ ├── create-test-doc.ts # Test document generator │ └── cleanup-test-docs.ts # Test data cleanup ├── tests/ │ ├── unit/ │ │ └── document-service.test.ts │ ├── integration/ │ │ └── document-lifecycle.test.ts │ └── mocks/ │ └── documenso.ts # Mock client factory ├── .env.development ├── .env.production ├── docker-compose.yml # Self-hosted Documenso (dev) └── package.json ``` ## Layer Architecture ``` ┌─────────────────────────────────────────────────────────┐ │ API / Controllers │ │ Routes, request validation, response formatting │ ├─────────────────────────────────────────────────────────┤ │ Service Layer │ │ Business logic, orchestration, authorization │ │ (document-service, template-service, signing-service) │ ├─────────────────────────────────────────────────────────┤ │ Documenso Client Layer │ │ SDK wrapper, retry, error handling, caching │ │ (client.ts, retry.ts, errors.ts) │ ├─────────────────────────────────────────────────────────┤ │ External Services │ │ Documenso API, S3/GCS storage, email, database │ └─────────────────────────────────────────────────────────┘ ``` **Rules:** - Controllers never call Documenso directly -- always go through services - Services never import `@documenso/sdk-typescript` directly -- use the client wrapper - Webhook processors are isolated -- one file per event type - Error handling happens at the client layer, not in controllers ## Data Flow ``` User Request │ ▼ ┌──────────┐ POST /api/sign │ API │──────────────────────────────┐ │ Router │ │ └──────────┘ ▼ ┌──────────────┐ │ Signing │ │ Service │ └──────┬───────┘ │ ┌─────────────────────┼─────────────────────┐ ▼ ▼ ▼ ┌──────────┐ ┌──────────┐ ┌──────────┐ │ Template │ │ Document │ │ Your │ │ Service │ │ Service │ │ DB │ └────┬─────┘ └────┬─────┘ └──────────┘ │ │ └────────┬───────────┘ ▼ ┌──────────────┐ │ Documenso │ │ Client │──→ Documenso API │ (singleton) │ └──────────────┘ Webhook Flow: Documenso API ──POST──→ /webhooks/documenso │
Trust audit
CAUTIONgrade B · trust 89/100 Install with care. The audit found things worth knowing before you trust its output.
| Layer | What it checks | Result |
|---|---|---|
| L0 | Provenance & inventory | PASS |
| L1 | Static analysis of the code | PASS |
| L2 | Instruction surface (what it tells the agent) | FAIL |
| L3 | Class-specific surface | PASS |
| L4 | Behavioural (sandbox) | SKIPPED |
What the source does
- Filesystem
- none-observed
- Network
- none-observed
- Shell
- none-observed
- Dependencies
- pinned
- Secrets in source
- none-found
Findings (1)
cat > .env.example << 'EOF'
Gates applied: no_behavioural_pass.
4f83675ca38afull audit observations/trust-audit/skill/jeremylongshore__documenso-reference-architecture.json · Report an issue / request a re-scanAudit history
Every audit this skill has had.
| Date | Source | Verdict | Grade | Score | Change |
|---|---|---|---|---|---|
| 2026-10-08 | 4f83675ca38a | CAUTION | B | 89 | first audit |
Questions
What does the Documenso Reference Architecture skill do?
Model-agnostic agent-skills platform with a harness-free canonical layer, verified adapters, and the ccpi package manager. Explore at tonsofskills.com.
Is Documenso Reference Architecture safe to install?
With care. The audit graded it B (89/100) and found 1 thing worth knowing before you trust this skill, listed below with the exact line each was found on.
What can Documenso Reference Architecture access on my machine?
The audit observed no filesystem, network or shell use at all in its source.
Which assistants does Documenso Reference Architecture work with?
Its documentation mentions claude-code. That is what the text claims, not a compatibility test we ran.
How current is this page?
The grade is for one exact copy of the source (4f83675ca38a), read on 2026-10-08. The repository is watched, and a new audit runs when it changes — this is the first audit.