> Fetch clean Markdown by appending `.md` to any page URL under https://signalwire.com/docs or requesting it with the HTTP header `Accept: text/markdown`. The root index at https://signalwire.com/docs/llms.txt lists the available documentation indexes. # getTools > Return the SWAIG tool definitions this skill exposes. [ref-skillbase]: /docs/server-sdks/reference/typescript/agents/skill-base [ref-defineskilltool]: /docs/server-sdks/reference/typescript/agents/helpers#defineskilltool Return the SWAIG tool definitions this skill exposes. Called by the `SkillManager` at SWML render time to collect every tool that should appear in the agent's SWAIG block. The default implementation returns tools registered imperatively via `defineTool()`. Skills that build their tool list declaratively should override this method to return a static array. > **Info** > > This replaces the Python `register_tools()` abstract method. TS uses a pull > model: you return the list, rather than calling back into the agent once per > tool. ## **Returns** `SkillToolDefinition[]` — array of tool definitions. ## **Example — declarative override** ```typescript {8-17} import { SkillBase, type SkillToolDefinition } from '@signalwire/sdk'; class WeatherSkill extends SkillBase { static override SKILL_NAME = 'weather'; static override SKILL_DESCRIPTION = 'Provides weather information'; override getTools(): SkillToolDefinition[] { return [{ name: 'get_weather', description: 'Get current weather for a location', parameters: { location: { type: 'string', description: 'City name' }, }, required: ['location'], handler: async (args) => ({ response: `Weather in ${args.location}: sunny, 72F` }), }]; } } ``` Wrap an entry in [`defineSkillTool()`][ref-defineskilltool] to have the handler's `args` typed from the `parameters` schema instead of `Record`. ## **Example — imperative via defineTool()** ```typescript {5-13} class ConfigurableSkill extends SkillBase { static override SKILL_NAME = 'configurable'; static override SKILL_DESCRIPTION = 'Tools depend on config'; override async setup(): Promise { this.defineTool({ name: this.getConfig('tool_name', 'run'), description: this.getConfig('description', 'Run the action'), parameters: {}, handler: async () => ({ response: 'done' }), }); return true; } } ``` > Return the SWAIG tool definitions this skill exposes.