---
title: "SDK library and tools"
canonical: https://trickest.com/docs/developer-tools/sdk/library-tools
description: "client.library; search the public catalog, resolve nodes, and manage private tools and modules."
---

# SDK library and tools

Examples use a server-side `client` from
[Client setup](/docs/developer-tools/sdk/client-setup), and resource IDs supplied
by your application.

## `client.library`

Public **tools**, **scripts**, **modules**, and **splitters**, plus helpers to build workflow nodes.

| Method                                                                 | Description                                              |
| ---------------------------------------------------------------------- | -------------------------------------------------------- |
| `search(params?, options?)`                                            | `AsyncGenerator<LibraryItem>`                            |
| `getTool(id)` / `getScript(id)` / `getModule(id)` / `getSplitter(id)`  | By id                                                    |
| `getLatestTool(name)` / `getLatestModule(id)`                          | Latest-version lookup; see the response note below |
| `searchSplitters(…)`                                                   | Splitter search                                          |
| `resolveToolNode(…)` / `resolveModuleNode(…)` / `resolveScriptNode(…)` | Node payloads for graph builders                         |
| `createTool(…)` / `updateTool(…)` / `deleteTool(…)`                    | Private tool YAML lifecycle                              |
| `getToolByName(name)`                                                  | Exact-name match within search results, or `null`        |
| `listTools(options?)`                                                  | Paginated private tools in vault                         |
| `createModule(…)` / `updateModule(…)` / `deleteModule(…)`              | Module lifecycle                                         |
| `listModules(…)`                                                       | Module search/list                                       |

```ts
for await (const item of client.library.search({
  query: "subfinder",
  types: "tool",
})) {
  console.log(item.name, item.id);
}

const resolved = await client.library.resolveToolNode("httpx");
if (!resolved.success || !resolved.data) {
  throw new Error(resolved.error ?? "Tool resolution failed");
}
console.log(resolved.data.node);
```

Resolution returns a node payload; it does not save the node into a workflow.
Pass existing node names through the second argument when resolving a node into
a graph that already contains nodes.

**Types:** `LibraryItem`, `LibrarySearchParams`, `ResolveNodeResponse`

<Info>
  **Concepts:** [Tools](/docs/key-concepts/building-blocks/tools),
  [Modules](/docs/key-concepts/building-blocks/modules). **CLI:** [Library,
  tools & modules](/docs/developer-tools/cli/library-tools-modules).
</Info>

### Latest-version response

`getLatestTool` and `getLatestModule` forward bulk API responses. The platform
returns an array, but the type declarations say `LibraryEntry`. Treat the
response as `unknown` and validate its shape before reading it. Do not assume
that the result is a single entry.

### Private tools vs `listTools`

`listTools()` returns the **paginated API envelope** `{ results, next, count, … }`; same
shape as the CLI `tool list` command, not a bare array.

```ts
const page = await client.library.listTools();
for (const tool of page.results) {
  console.log(tool.name);
}
```

## Related

<CardGroup cols={2}>
  <Card
    title="Workflows"
    icon="diagram-project"
    href="/docs/developer-tools/sdk/workflows"
  >
    Attach resolved nodes to workflows (via the platform graph APIs or CLI).
  </Card>
  <Card
    title="Runs"
    icon="play"
    href="/docs/developer-tools/sdk/runs-schedules"
  >
    Execute the saved workflow on a fleet.
  </Card>
</CardGroup>

---
_Markdown source of https://trickest.com/docs/developer-tools/sdk/library-tools._
