@tryengrave/proto
v0.1.3
Published
Engrave API contracts: Zod schemas as the single source of truth, OpenAPI 3.1 generated.
Readme
@tryengrave/proto
The API contracts for Engrave — Zod schemas as the single source of truth for request/response shapes, with an OpenAPI 3.1 document generated from them.
npm install @tryengrave/protoWhat it's for
One definition, three uses: runtime validation, TypeScript types, and the OpenAPI spec — all derived from the same Zod schemas so they can never drift apart. Import it to type your calls to the Engrave API, validate payloads at your own boundary, or generate a client.
Usage
import { z } from "zod"
import { /* schemas */ } from "@tryengrave/proto"
// Parse at your boundary — types and validation come from the same schema
const parsed = SomeRequestSchema.parse(payload)The generated OpenAPI 3.1 document ships with the package and is served live at api.tryengrave.com/openapi.json.
Part of Engrave — immutable audit evidence, verifiable by anyone. · API docs · MIT
