Share one User type across services
Define User once in .syln with an optional name and a list of roles. Generate the TypeScript interface and Python dataclass so your API and workers agree on the shape.
View the schema
schema.syln
type User { id: string email: string name: string? roles: list<string> isActive: bool}TypeScript output
export interface User { id: string; email: string; name?: string; roles: string[]; isActive: boolean;}Python output
@dataclassclass User: id: str email: str name: Optional[str] roles: list[str] is_active: bool