MCPcopy
hub / github.com/codeaashu/claude-code / findToolByName

Function findToolByName

src/Tool.ts:358–360  ·  view source on GitHub ↗
(tools: Tools, name: string)

Source from the content-addressed store, hash-verified

356 * Finds a tool by name or alias from a list of tools.
357 */
358export function findToolByName(tools: Tools, name: string): Tool | undefined {
359 return tools.find(t => toolMatchesName(t, name))
360}
361
362export type Tool<
363 Input extends AnyObject = AnyObject,

Callers 15

queryLoopFunction · 0.85
ToolSearchTool.tsFile · 0.85
callFunction · 0.85
extractLastToolInfoFunction · 0.85
MessagesImplFunction · 0.85
VerboseToolUseFunction · 0.85
AssistantToolUseMessageFunction · 0.85
GroupedToolUseContentFunction · 0.85
useGetToolFromMessagesFunction · 0.85
renderToolActivityFunction · 0.85
handleOrphanedPermissionFunction · 0.85

Calls 1

toolMatchesNameFunction · 0.85

Tested by

no test coverage detected