> 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. # loadSkill > Instantiate a skill class and add it; returns a [success, error] tuple. [ref-addskill]: /docs/server-sdks/reference/typescript/agents/skill-manager/add-skill [ref-skillbase]: /docs/server-sdks/reference/typescript/agents/skill-base Construct a skill instance from the provided class and add it via [`addSkill`][ref-addskill]. Catches any throw from `addSkill` and returns a `[success, errorMessage]` tuple — matching the Python SDK's `load_skill` return contract. ## **Parameters** **`skillClass`** `typeof SkillBase` — required A concrete subclass of [`SkillBase`][ref-skillbase]. --- **`config`** `SkillConfig` Optional configuration forwarded to the skill constructor. --- ## **Returns** `Promise<[boolean, string]>` — `[true, '']` on success, `[false, errorMessage]` on any validation or setup failure. ## **Example** ```typescript {3} import { MyCustomSkill } from './my-skill.js'; const [ok, err] = await agent.skillManager.loadSkill(MyCustomSkill, { api_key: 'secret' }); if (!ok) console.error(err); ``` > Instantiate a skill class and add it; returns a [success, error] tuple.