open-index/open-npm huggingface dataset:
npm package: @scalepad/sdk-controlmap
Description: Thin typed ScalePad ControlMap helper package used by the ScalePad CLI.
Latest version: 0.1.3

# @scalepad/sdk-controlmap

Thin typed helper package for the ScalePad ControlMap API.

The primary supported developer interface is the [`@scalepad/cli`](https://www.npmjs.com/package/@scalepad/cli). This package exists to support generated client access and CLI internals.
npm package: @scalepad/sdk-lm
Description: Thin typed ScalePad Lifecycle Manager helper package used by the ScalePad CLI.
Latest version: 0.1.3

# @scalepad/sdk-lm

Thin typed client for selected ScalePad Lifecycle Manager API routes used by the ScalePad CLI.

`@scalepad/cli` is the primary supported developer interface right now. Use this package when you need a lightweight programmatic helper for a subset of Lifecycle Manager workflows.

## Install

```bash
npm install @scalepad/sdk-lm
```

## Usage

```ts
import { createLifecycleManagerClient } from "@scalepad/sdk-lm";

const client = createLifecycleManagerClient({
  apiKey: process.env.SCALEPAD_API_KEY!,
  validateResponses: true
});

const actionItems = await client.listActionItems({ pageSize: 10 });
console.log(actionItems.data);
```

## API

The package exports a generated client plus a small convenience wrapper.

Wrapper helpers:

- `createLifecycleManagerClient(config)`
- `ScalepadLifecycleManagerClient`
- `listActionItems(query)`
- `getActionItem(id)`
- `paginateActionItemPages(query)`
- `paginateActionItems(query)`
- `collectAllActionItems(query)`

Generated and schema exports:

- `GeneratedLifecycleManagerClient`
- `lifecycleManagerOperations`
- `ScalepadLmApiError`
- `paths`

## Client configuration

```ts
type LifecycleManagerClientConfig = {
  apiKey: string;
  baseUrl?: string;
  fetchImpl?: typeof fetch;
  userAgent?: string;
  timeoutMs?: number;
  maxRetries?: number;
  retry?: Partial<RetryConfig>;
  validateResponses?: boolean;
};
```

- `apiKey` is required and is sent as `x-api-key`
- `baseUrl` defaults to `https://api.scalepad.com`
- `fetchImpl` lets you inject a custom fetch implementation
- `userAgent` defaults to `@scalepad/cli`
- `timeoutMs` defaults to `30000`
- `maxRetries` is kept for backward compatibility and overrides `retry.maxRetries` when set
- `retry.retryOn429` and `retry.retryOn5xx` control safe-method retries
- `retry.retryUnsafeMethods` defaults to `false`
- `validateResponses` enables basic runtime envelope validation for wrapper methods

## List queries

List endpoints accept this shared shape:

```ts
type ListQuery = {
  cursor?: string;
  pageSize?: number;
  filters?: Record<string, string>;
  sort?: string;
};
```

Filters are translated to `filter[field]=expression` query parameters, and `pageSize` is translated to `page_size`.

## Pagination helpers

Wrapper list methods still support manual cursor pagination through `ListQuery`, and the package now also exports helper iterators:

```ts
for await (const actionItem of client.paginateActionItems({ pageSize: 100 })) {
  console.log(actionItem.id);
}

const allActionItems = await client.collectAllActionItems({ pageSize: 200 });
```

## Error handling

Failed requests throw richer typed errors:

- `ScalepadLmApiError` for general API failures
- `AuthenticationError`
- `AuthorizationError`
- `RateLimitError`
- `ServerError`
- `TimeoutError`
- `NetworkError`
- `ResponseValidationError`

## Development

This package is generated from the checked-in OpenAPI spec in the monorepo root. To refresh or rebuild it:

```bash
pnpm fetch:specs
pnpm generate:sdk
pnpm --filter @scalepad/sdk-lm build
```
npm package: @scalepad/sdk-quoter
Description: Thin typed ScalePad Quoter helper package used by the ScalePad CLI.
Latest version: 0.1.3

# @scalepad/sdk-quoter

Thin typed helper package for the ScalePad Quoter API.

The primary supported developer interface is the [`@scalepad/cli`](https://www.npmjs.com/package/@scalepad/cli). This package exists to support generated client access and CLI internals.