Book: The TypeScript Type System — From Generics to DSL-Level Types Also by me: The TypeScript Library — the 5-book collection My project: Hermes IDE | GitHub — an IDE for developers who ship with Claude Code and other AI coding tools Me: xgabriel.com | GitHub You open a service file in someone else's repo and see this near the top: import { api } from " ./client " ; type CreateUserArgs = Parameters < typeof api . users . create > [ 0 ]; type CreateUserResult = Awaited < ReturnType < typeof api . users . create >> ; async function onSubmit ( form : CreateUserArgs ): Promise < CreateUserResult > { return api . users . create ( form ); } Enter fullscreen mode Exit fullscreen mode No interface. No DTO file. No generated types from a schema. The function pulled its argument shape and its resolved return type straight out of api.users.create (whatever that function is). If api.users.create changes signature, onSubmit either updates with it or fails to compile. The contract is the function.…