API: tools

better-web-search-mcp


better-web-search-mcp / tools

tools#

Functions#

cacheFromConfig()#

cacheFromConfig(cfg?): Cache

Defined in: src/tools/index.ts:27

Build the shared cache from configuration.

BETTER_WEB_SEARCH_DISABLE_CACHE and BETTER_WEB_SEARCH_CACHE_PATH were parsed by the config loader and printed in the startup banner, but nothing ever passed them to the Cache: the server opened data/cache.db no matter what either said. Both are honored here.

Parameters#

ParameterType
cfgAppConfig

Returns#

Cache


registerTools()#

registerTools(server, cache?): void

Defined in: src/tools/index.ts:34

Parameters#

ParameterType
serverMcpServer
cache?Cache

Returns#

void