---
title: "@togohq/sdk-node changelog"
canonical: https://www-stage.togohq.ai/changelog/sdk-node
entries: 11
---

# @togohq/sdk-node changelog

## @togohq/sdk-node 2.5.0 — Version 2.5.0 introduces new limits on event and property names and improves serverless function warnings

Released November 24, 2026 · Node.js SDK
Permalink: https://www-stage.togohq.ai/changelog/sdk-node/2.5.0

### New

- Event and Property Name Length: Event and property names can now be up to 255 characters, allowing for greater flexibility and compatibility with other tools.
- Serverless Warning: A warning is now logged when the timer sends in a serverless function, helping to identify potential data loss issues.

### Improved

- `onError` now includes the property name for reports about unusable names and cuts, providing more detailed error information.

### Fixed

- Serverless Warning Logic: The serverless warning now requires two timer sends with no flush between, correcting previous behavior.
- Memory Usage: Only the IDs of evicted events are held until they are reported, reducing memory usage during outages.

## @togohq/sdk-node 2.4.0 — Version 2.4.0 reports property names Togo cannot use

Released November 21, 2026 · Node.js SDK
Permalink: https://www-stage.togohq.ai/changelog/sdk-node/2.4.0

### New

- A property name over 64 characters, with a control character, or containing an email address is reported through `onError` as `property_name_invalid` (or `person_property_name_invalid` on a profile write). Togo could not query it.

### Improved

- With a live key, such a property is now dropped and the rest of the event is sent. With a test key it is sent as well, so `verify_tracking` reports it, and a property name starting with `$` is now reported as `property_reserved` too.

## @togohq/sdk-node 2.3.0 — Version 2.3.0 introduces app version and build options, and adds device manufacturer information

Released November 19, 2026 · Node.js SDK
Permalink: https://www-stage.togohq.ai/changelog/sdk-node/2.3.0

### New

- `init()` now accepts `appVersion` and `appBuild` options, sending the app object once per request. Each value must be 1–64 characters.
- DeviceInfoSchema now includes an optional `manufacturer` field, which is bounded at 64 characters and dropped if exceeded.

## @togohq/sdk-node 2.2.0 — Version 2.2.0 updates error and diagnostic codes in `onError`, requiring changes to error handlers

Released November 18, 2026 · Node.js SDK
Permalink: https://www-stage.togohq.ai/changelog/sdk-node/2.2.0

### Breaking

- BREAKING: `onError` codes `envelope_too_many_properties` and `shutdown_undelivered` are now `envelope_properties_too_many` and `shutdown_flush_failed`. Update handlers that switch on these names.

### Migration

Update `onError` handlers to use the new error code names.

Before:

```ts
onError((error) => {
  if (error.code === 'envelope_too_many_properties') {
    handleTooManyProperties();
  }
});
```

After:

```ts
onError((error) => {
  if (error.code === 'envelope_properties_too_many') {
    handleTooManyProperties();
  }
});
```

The old form stops working in @togohq/sdk-node 2.2.0.

## @togohq/sdk-node 2.1.0 — @togohq/sdk-node 2.1.0

Released November 14, 2026 · Node.js SDK
Permalink: https://www-stage.togohq.ai/changelog/sdk-node/2.1.0

### Breaking

- `email` and `name` are no longer keys of `set` or `setOnce`: pass them as the `email` and `name` parameters. A plain `email` or `name` key in `set` no longer type-checks, and the server drops one as `person_property_reserved`.
- A property key starting with `$` is reserved for Togo. Under a live key the SDK drops it, logs it once and still sends the event; under a test key it is sent, so `verify_tracking` reports `property_reserved` or `person_property_reserved`.

### New

- `init({ onError })` is called once for every event, or part of one, that will not be recorded, and once when the client stops sending. `flush()` waits for it. Pass it to your error tracker. Each error carries a `code`.
- `setPersonProperties({ email, name }, person)` sets a person's email address and name through typed parameters. `null` removes one.

### Fixed

- An empty or over-long event name is dropped on its own, instead of with the whole batch it was in.

### Migration

Pass email and name as parameters of `setPersonProperties()`, not as keys of `set`.

Before:

```ts
setPersonProperties({ set: { email: user.email, name: user.name } }, { userId });
```

After:

```ts
setPersonProperties({ email: user.email, name: user.name }, { userId });
```

The old form stops working in @togohq/sdk-node 2.1.0.

## @togohq/sdk-node 2.0.0 — Version 2.0.0 introduces experiment tracking and removes custom session ID support

Released November 12, 2026 · Node.js SDK
Permalink: https://www-stage.togohq.ai/changelog/sdk-node/2.0.0

### Breaking

- Custom session ID support via `init({ sessionId })` and `SessionIdMode 'custom'` is removed.

### New

- `getExperiment()` is now available for experiment tracking, sending `$experiment_entered` events.

### Improved

- The SDK now forwards session IDs from the browser's `getSessionId()` only, without sending `$session_started`.

### Fixed

- The reserved-name log in the Node SDK now correctly follows other drops, and non-string names are logged.

### Migration

Replace custom session ID usage with ordinary event properties.

Before:

```js
init({ sessionId: 'custom-id' });
```

After:

```js
track('event_name', { sessionId: 'custom-id' });
```

The old form stops working in @togohq/sdk-node 2.0.0.

## @togohq/sdk-node 1.3.1 — Version 1.3.1 corrects the 1.3.0 changelog

Released November 5, 2026 · Node.js SDK
Permalink: https://www-stage.togohq.ai/changelog/sdk-node/1.3.1

### Fixed

- The 1.3.0 entry in this changelog now describes the Node SDK's changes: `withFlush()`, `flushIntervalSeconds` replacing `flushIntervalMs`, the `batchSize` range and the `flush()` retry. It had listed browser-only session changes.

## @togohq/sdk-node 1.3.0 — Version 1.3.0 adds withFlush() for serverless handlers and takes the flush interval in seconds

Released November 5, 2026 · Node.js SDK
Permalink: https://www-stage.togohq.ai/changelog/sdk-node/1.3.0

### Breaking

- `flushIntervalSeconds` (10 to 60, default 10) replaces `flushIntervalMs`. A `flushIntervalMs` passed to `init()` is ignored, with a warning naming the replacement.

### New

- `withFlush(handler)` wraps a serverless handler so the queue is sent after it returns or throws, with its result passed through unchanged.

### Improved

- `batchSize` accepts 100 to 500. A value outside that range is moved into it, with a warning.
- `flush()` retries a network failure or a server error within a 2-second budget before it resolves, and never retries a `429`.

### Migration

Replace `flushIntervalMs` with `flushIntervalSeconds`, and wrap serverless handlers in `withFlush()`.

Before:

```ts
const analytics = init({ writeKey, flushIntervalMs: 10_000 });
```

After:

```ts
const analytics = init({ writeKey, flushIntervalSeconds: 10 });
export const handler = analytics.withFlush(async (event) => {
  analytics.track('order_paid', {}, { userId: event.userId });
});
```

The old form stops working in @togohq/sdk-node 1.3.0.

## @togohq/sdk-node 1.2.0 — This version introduces event ID returns and updates terminology for event definitions

Released November 4, 2026 · Node.js SDK
Permalink: https://www-stage.togohq.ai/changelog/sdk-node/1.2.0

### Breaking

- Terminology updated: "declare" and "contract" are now "define" and "definition" across the SDK, aligning with internal naming conventions.

### New

- `track()`, `identify()`, and `setPersonProperties()` now return the `eventId` of the event they queued, or `undefined` when no event is sent.

### Migration

Update code to use the new terminology for event definitions.

Before:

```js
declareEvent(); // uses 'declare' terminology
```

After:

```js
defineEvent(); // uses 'define' terminology
```

The old form stops working in @togohq/sdk-node 1.2.0.

## @togohq/sdk-node 1.1.0 — This version introduces default properties and fixes an event value handling issue

Released October 29, 2026 · Node.js SDK
Permalink: https://www-stage.togohq.ai/changelog/sdk-node/1.1.0

### New

- `init({ defaultProperties })` now supports default properties, fixed at initialization and stamped on every `track()` call.

### Fixed

- An undefined event value no longer erases a default property, ensuring consistent property handling.

## @togohq/sdk-node 1.0.0 — The first stable release

Released October 24, 2026 · Node.js SDK
Permalink: https://www-stage.togohq.ai/changelog/sdk-node/1.0.0

### Improved

- Semantic versioning. The public API is now stable: from this version on, a breaking change ships only in a new major version.
