import { Hono } from 'hono' import type * as App from '../../../App.js' import * as Activities from './activities.js' import * as Balances from './balances.js' import * as Valuation from './valuation.js' /** * Composes the `/v1/addresses/:address/*` route surface from the * address-scoped sub-routers exported by each resource module. The handlers, * schemas, and paths live with the resource they describe (activities, * balances, valuation); this composer only aggregates them so docs grouping * stays by tag while URLs stay nested under the parent resource. * * Only subject-relative resources live here — rows that cannot be interpreted * without the path address (activity classification, held-token balances, * holdings valuation). Plain filtered views of canonical collections are * reached via search params instead (`GET /transactions?address=…`, * `GET /transfers?address=…`, `GET /transactions/receipts?address=…`). */ export function addresses(options: addresses.Options = {}) { return new Hono() .route('/', Activities.addresses({ fx: options.fx })) .route('/', Balances.addresses({ fx: options.fx })) .route('/', Valuation.addresses({ fx: options.fx })) } export declare namespace addresses { /** Options for the address-scoped route composer. */ type Options = { /** FX configuration for the valuation endpoint. */ fx?: Valuation.addresses.Fx | undefined } }