http/client_ip.ts

Read the resolved client IP off the Hono context.

Split from proxy.ts (which pulls hono/utils/ipaddr for trusted-proxy CIDR matching) so dispatch + route modules that only need to *read* the IP stay free of that value import — and the cross-process test surface that imports them stays free of the optional hono peer. The IP itself is set on the context by the trusted-proxy middleware in proxy.ts.

view source

Declarations
#

get_client_ip
#

http/client_ip.ts view source

(c: Context<any, any, {}>): string import {get_client_ip} from '@fuzdev/fuz_app/http/client_ip.js';

Client IP resolved by the trusted-proxy middleware, or 'unknown' if unset.

c

type Context<any, any, {}>

returns

string

Imported by
#