Skip to content

Initial vc-api-mock implementation#1

Merged
djscruggs merged 6 commits into
mainfrom
initial-implementation
May 19, 2026
Merged

Initial vc-api-mock implementation#1
djscruggs merged 6 commits into
mainfrom
initial-implementation

Conversation

@djscruggs
Copy link
Copy Markdown
Collaborator

@djscruggs djscruggs commented May 16, 2026

Review Guide

Start with INITIAL_BUILD.md — it documents every design decision made during the initial build: the fake proof strategy, store injection pattern, mandatory pointer enforcement, single-use challenges, conformance test architecture, and what was intentionally left out.

Summary

  • Mock HTTP server for the VCALM / W3C VC API lifecycle
  • Full credential, presentation, workflow, exchange, status list, and interaction endpoints
  • In-memory store with per-test isolation via store injection
  • RFC 9457 ProblemDetails error formatting throughout
  • JSDoc + tsc --checkJs --noEmit for type safety (no TS compilation)
  • 79 tests: unit, integration, and conformance (runnable against real servers via VCALM_BASE_URL)
  • OpenAPI 3.0 spec at spec/oas.yaml, used by conformance validator at runtime
  • CI matrix: Node 18/20/22, lint + typecheck + test

Before merging

  • Delete INITIAL_BUILD.md — it is a reviewer aid, not permanent documentation. Remove it in a follow-up commit or squash before merge.

Test plan

  • npm test passes (79 tests)
  • npm run lint clean
  • npm run typecheck clean
  • npm run test:conformance passes against the mock

🤖 Generated with Claude Code

djscruggs and others added 4 commits May 16, 2026 10:56
Implements all VCALM/VC API endpoints: credential issue/verify/derive/status,
presentations, workflows and exchanges, challenges, status lists, and
interactions. Includes unit, integration, and conformance test suites,
OAS spec, CI config, and shared JSDoc typedefs with no @type {any} casts.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Import randomUUID from node:crypto explicitly instead of relying on
the global crypto object, which was only added in Node 19.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…429.

Use localWorkflowId and localExchangeId path parameter names to match
the upstream W3C VCALM spec. Add 413 and 429 response codes to
POST /presentations/verify.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Comment thread USE_CASES.md Outdated
Copy link
Copy Markdown

@BigBlueHat BigBlueHat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great! @PatStLouis is working on a new test suite approach, and this might be handy to add to the initial "implementations" list.

It may even work with parts of the existing test suites:

(though these two are going to likely be replaced with Patrick's work)

Thanks for tackling this @djscruggs!

- Update USE_CASES.md to include ecdsa-sd-2023
@djscruggs djscruggs merged commit d55b171 into main May 19, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants