Lightlines
By google-labs-code

typed-service-contracts

google-labs-code655 installs

Type-safe TypeScript services with explicit errors.

What it does

Guides the implementation of type-safe TypeScript services with separate contracts, handlers, and explicit error results.

When to use it

Use when building CLIs or libraries, parsing complex inputs, requiring exhaustive error handling, or separating validation tests from business logic tests.

How to use it

It changes how the agent structures TypeScript services, separating schema-defined contracts from handlers that return errors as values.

What you provide

  • An existing project

Latest review

What you need · 1

The prescribed contracts use Zod to define and parse input and output schemas.


Access · 0

No additional actions listed.