@north-light/sdk 0.3.780 → 0.3.781

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -8,7 +8,7 @@
8
8
 
9
9
  `@north-light/sdk` is the application-facing client for a crouter daemon (`crtrd`). Create an agent run, wait for a result checked against a Zod or Standard Schema, stream the run's text and tool calls to a UI, and use the daemon's other APIs: files, bash, documents ("memory" for the person's, `docs` for ones your app owns), crons, human requests, and the OAuth connection flow for apps whose users each have their own runtime. It is ESM-only.
10
10
 
11
- It is a client, not a runtime. It never runs an agent itself, and it does not bundle a model: the daemon it talks to does, using the provider that daemon is signed in to. In Node, `new Crouter()` connects to the local daemon over its unix socket and starts it on the first request if it is not running. In a browser or from another machine it needs the daemon's TCP URL and a bearer token. The lower-level contract it is built on is [`@north-light/api`](https://www.npmjs.com/package/@north-light/api); most applications should install this package instead.
11
+ It is a client, not a runtime. It never runs an agent itself, and it does not bundle a model: the runtime it talks to does. The runtime is the Northlight cloud control plane; the client needs its URL and a bearer token. The lower-level contract it is built on is [`@north-light/api`](https://www.npmjs.com/package/@north-light/api); most applications should install this package instead.
12
12
 
13
13
  [Docs](https://sdk.docs.northlight.ai) · [Quick setup](https://sdk.docs.northlight.ai/docs/quickstart) · [Guides](https://sdk.docs.northlight.ai/docs/guides/typed-results) · [Errors](https://sdk.docs.northlight.ai/docs/errors) · [Release notes](https://sdk.docs.northlight.ai/docs/release-notes) · [Running a daemon yourself](https://crouter.docs.northlight.ai/docs/sdk) · [crouter repository](https://github.com/Northlight-Systems/crouter)
14
14
 
@@ -25,12 +25,12 @@ npx @north-light/sdk@latest init my-app
25
25
  ```bash
26
26
  npm install @north-light/sdk zod # zod is optional; any Standard Schema works for output_schema
27
27
  npm install -g @north-light/cli # the daemon and the crtr CLI
28
- crtr # first run: the installer signs you in to a model provider
28
+ crtr sys signin # sign in to your Northlight account
29
29
  ```
30
30
 
31
31
  ## Connect
32
32
 
33
- In Node, `new Crouter()` uses the local unix socket and starts the daemon on the first request when the socket is cold. In a browser or a remote process, pass the daemon's TCP URL and its bearer token (`CRTRD_TOKEN`).
33
+ Pass the runtime's URL and a bearer token.
34
34
 
35
35
  ```ts
36
36
  const client = new Crouter({
@@ -119,7 +119,7 @@ CREATE INDEX connection_updated_at_idx ON connection (updated_at, user_id);
119
119
 
120
120
  ## Reference
121
121
 
122
- The [app builder docs](https://sdk.docs.northlight.ai) cover quick setup, concepts, guides, providers, errors and the generated reference. For a daemon you run yourself, the [SDK guide](https://crouter.docs.northlight.ai/docs/sdk) covers [client construction](https://crouter.docs.northlight.ai/docs/sdk/client), [Docker](https://crouter.docs.northlight.ai/docs/sdk/docker), [daemon errors](https://crouter.docs.northlight.ai/docs/sdk/errors), and the complete [resource map](https://crouter.docs.northlight.ai/docs/sdk/resources).
122
+ The [app builder docs](https://sdk.docs.northlight.ai) cover quick setup, concepts, guides, providers, errors and the generated reference. For the client's own reference, the [SDK guide](https://crouter.docs.northlight.ai/docs/sdk) covers [client construction](https://crouter.docs.northlight.ai/docs/sdk/client), [Docker](https://crouter.docs.northlight.ai/docs/sdk/docker), [daemon errors](https://crouter.docs.northlight.ai/docs/sdk/errors), and the complete [resource map](https://crouter.docs.northlight.ai/docs/sdk/resources).
123
123
 
124
124
  `@north-light/sdk/errors` exports `errorCodes`/`ErrorCode` (the daemon's codes), `sdkErrorCodes`/`SdkErrorCode` (the codes the SDK raises itself, such as `oauth_state_mismatch`; `CrouterError.code` is typed with them), and `mapError`, which turns a plain `APIError` into its status class (`NotFoundError`, …) for app tests.
125
125
 
@@ -2,7 +2,7 @@
2
2
  name: northlight
3
3
  description: "Use when building, debugging or shipping an app that signs people in with Northlight, starts runs on their Northlight runtime, or calls Northlight providers (sms, search, integrations, context, device) with @north-light/sdk."
4
4
  metadata:
5
- sdk-version: "0.3.780"
5
+ sdk-version: "0.3.781"
6
6
  ---
7
7
 
8
8
  # Building a Northlight app
@@ -27,7 +27,7 @@ Never text a person first: Comms refuses a send to anyone who has not texted you
27
27
 
28
28
  ## First: check this skill matches the SDK
29
29
 
30
- This skill is for SDK version `0.3.780`. If the project has `node_modules/@north-light/sdk/package.json`, compare its `version` with that number. If they differ, run `npx @north-light/sdk skill` in the project, then read the rewritten `.agents/skills/northlight/SKILL.md` (or `.claude/skills/northlight/SKILL.md`) instead of this copy. It needs no account. A project that has no SDK yet starts with `npx @north-light/sdk@latest init <dir>`.
30
+ This skill is for SDK version `0.3.781`. If the project has `node_modules/@north-light/sdk/package.json`, compare its `version` with that number. If they differ, run `npx @north-light/sdk skill` in the project, then read the rewritten `.agents/skills/northlight/SKILL.md` (or `.claude/skills/northlight/SKILL.md`) instead of this copy. It needs no account. A project that has no SDK yet starts with `npx @north-light/sdk@latest init <dir>`.
31
31
 
32
32
  ## Where things run
33
33
 
package/dist/version.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  /** This SDK's release version. Informational only: compatibility is the contract level, not this number. */
2
- export declare const SDK_VERSION = "0.3.780";
2
+ export declare const SDK_VERSION = "0.3.781";
3
3
  /** The release sent in `Crouter-Minimum-Runtime-Version` on every request. It is frozen, so a runtime from before the
4
4
  * contract level existed (which only knows this header) refuses this SDK, while every later runtime accepts it. */
5
5
  export declare const LEGACY_FLOOR = "0.3.423";
package/dist/version.js CHANGED
@@ -1,6 +1,6 @@
1
1
  // SDK_VERSION is written by scripts/release-version.mjs on every release; do not edit by hand.
2
2
  /** This SDK's release version. Informational only: compatibility is the contract level, not this number. */
3
- export const SDK_VERSION = '0.3.780';
3
+ export const SDK_VERSION = '0.3.781';
4
4
  // LEGACY_FLOOR is written once by `scripts/contract.mjs release`, at the first release that carries the contract level
5
5
  // (the `0.0.0` placeholder is replaced there and never again); do not edit by hand.
6
6
  /** The release sent in `Crouter-Minimum-Runtime-Version` on every request. It is frozen, so a runtime from before the
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@north-light/sdk",
3
- "version": "0.3.780",
3
+ "version": "0.3.781",
4
4
  "crouterContract": "1.84",
5
5
  "description": "Typed Node and browser client for running crouter agents through the crtrd /v1 API.",
6
6
  "type": "module",
@@ -44,9 +44,9 @@
44
44
  "prepublishOnly": "node -e \"if (process.env.npm_config_tag !== 'next') { console.error('@north-light/sdk publishes only with --tag next; scripts/promote-sdk.mjs is the only mover of latest.'); process.exit(1); }\""
45
45
  },
46
46
  "dependencies": {
47
- "@north-light/api": "0.3.780",
48
- "@north-light/identity": "0.3.780",
49
- "@north-light/plugin": "0.3.780",
47
+ "@north-light/api": "0.3.781",
48
+ "@north-light/identity": "0.3.781",
49
+ "@north-light/plugin": "0.3.781",
50
50
  "jose": "^6.2.1"
51
51
  },
52
52
  "peerDependencies": {