'/posts', zValidator('json', z.object({ title: z.string(), body: z.string(), })), (c) => c.json({ ok: true, message: 'Created!', }, 201) ) export type AppType = typeof route 6 // client.ts import { hc } from 'hono/client' import type { AppType } from '../server' const client = hc< AppType>('/api') const res = await client.posts.$post({ json: { title: 'Hello', body: 'Hono RPC is cool', }, }) // data: { ok: boolean; message: string } const data = await res.json()