Agent skill · software engineering · jeremylongshore
documenso-sdk-patterns
Apply production-ready Documenso SDK patterns for TypeScript and Python.
Why this skill is useful
Provides specific implementation patterns and error handling strategies for the Documenso SDK that the AI wouldn't reliably generate on its own.
What it needs
Requires documenso account access. About 4k tokens when loaded. Last updated 2026-08-07. 2,604 stars on the source repository.
What this skill does
Documenso SDK Patterns Output A scoped SDK boundary with document authorization, idempotency, redacted telemetry, and safe error handling. A test-backed client design that never logs signing URLs, document content, signer PII, or credentials. Examples Instantiate the SDK with a development secret reference, create a synthetic test document with a stable idempotency key, and assert the mocked request shape in unit tests. For one development integration check, record only correlation ID and lifecycle state; never log document or signer payloads. Overview Production-ready patterns for the Documenso TypeScript SDK (@documenso/sdk-typescript) and Python SDK. Covers singleton clients, typed wrappers, error handling, retry logic, and testing patterns. Prerequisites Completed documenso-install-auth setup Familiarity with async/await and TypeScript generics Understanding of error handling best practices Instructions Pattern 1: Singleton Client with Configuration Pattern 2: Typed Document Service Pattern 3: Error Handling Wrapper Pattern 4: Retry with Exponential Backoff Pattern 5: Python Service Pattern Pattern 6: Testing with Mocks Error Handling Pattern Issue Cause Solution -------------- ------- ---------- Client not initialized Missing env var Check DOCUMENSOAPIKEY is set Singleton stale after key rotation Cached client Call resetClient() Retry loop on 401 Non-retryable treated as retryable Check retryable flag Type mismatch on field type Wrong enum string Use union type from SDK Resources TypeScript SDK Source Python SDK Source SDK Documents API Zod for Validation Next Steps Apply patterns in documenso-core-workflow-a for document creation workflows.
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills jeremylongshore/documenso-sdk-patterns--225bbc