## Summary 5 improvements, 5 bug fixes. ## Improvements - Add experimental Node.js 24 and 26 task runtimes. Set `runtime` to `experimental-node-24` or `experimental-node-26` in `trigger.config.ts`. ([#4085](https://github.com/triggerdotdev/trigger.dev/pull/4085)) - Add `defaultRegion` to the project GET and list API responses; null when unset. ([#4146](https://github.com/triggerdotdev/trigger.dev/pull/4146)) ## Server changes These changes affect the self-hosted Docker image and Trigger.dev Cloud: - Transient internal sync failures are now retried quietly instead of surfacing as errors. ([#4270](https://github.com/triggerdotdev/trigger.dev/pull/4270)) - Optionally route ClickHouse read traffic to a read replica while writes stay on the primary. Set `CLICKHOUSE_READER_URL` to move all reads, or target the busiest paths with `RUNS_LIST_CLICKHOUSE_URL` (runs list) and `EVENTS_READER_CLICKHOUSE_URL` (traces, spans, logs). All optional; unset keeps current behavior. ([#4081](https://github.com/triggerdotdev/trigger.dev/pull/4081)) - Remove the deprecated realtime stream write endpoint used by retired v3 task clients. ([#4250](https://github.com/triggerdotdev/trigger.dev/pull/4250)) - Fix batchTrigger requests that set a per-item idempotency key failing with an error instead of creating and deduplicating the runs ([#4271](https://github.com/triggerdotdev/trigger.dev/pull/4271)) - Speed up idempotency checks on `batchTrigger` calls that use idempotency keys. Large batches against a task with a big run history no longer degrade to multi-second lookups. ([#4255](https://github.com/triggerdotdev/trigger.dev/pull/4255)) - The "Preview branches" usage on the Limits page now counts only preview branches. ([#4283](https://github.com/triggerdotdev/trigger.dev/pull/4283)) - Avoid opening a redundant database connection pool when the legacy and primary databases are the same server, preventing connection usage from doubling. ([#4253](https://github.com/triggerdotdev/trigger.dev/pull/4253)) - Fix pages occasionally loading unstyled or failing to load during a deploy. The dashboard now reloads automatically to recover. ([#4282](https://github.com/triggerdotdev/trigger.dev/pull/4282)) <details> <summary>Raw changeset output</summary> # Releases ## @trigger.dev/build@4.5.5 ### Patch Changes - Updated dependencies: - `@trigger.dev/core@4.5.5` ## trigger.dev@4.5.5 ### Patch Changes - Add experimental Node.js 24 and 26 task runtimes. Set `runtime` to `experimental-node-24` or `experimental-node-26` in `trigger.config.ts`. ([#4085](https://github.com/triggerdotdev/trigger.dev/pull/4085)) - Updated dependencies: - `@trigger.dev/core@4.5.5` - `@trigger.dev/build@4.5.5` - `@trigger.dev/schema-to-json@4.5.5` ## @trigger.dev/core@4.5.5 ### Patch Changes - Add experimental Node.js 24 and 26 task runtimes. Set `runtime` to `experimental-node-24` or `experimental-node-26` in `trigger.config.ts`. ([#4085](https://github.com/triggerdotdev/trigger.dev/pull/4085)) - Add `defaultRegion` to the project GET and list API responses; null when unset. ([#4146](https://github.com/triggerdotdev/trigger.dev/pull/4146)) ## @trigger.dev/python@4.5.5 ### Patch Changes - Updated dependencies: - `@trigger.dev/core@4.5.5` - `@trigger.dev/build@4.5.5` - `@trigger.dev/sdk@4.5.5` ## @trigger.dev/react-hooks@4.5.5 ### Patch Changes - Updated dependencies: - `@trigger.dev/core@4.5.5` ## @trigger.dev/redis-worker@4.5.5 ### Patch Changes - Updated dependencies: - `@trigger.dev/core@4.5.5` ## @trigger.dev/rsc@4.5.5 ### Patch Changes - Updated dependencies: - `@trigger.dev/core@4.5.5` ## @trigger.dev/schema-to-json@4.5.5 ### Patch Changes - Updated dependencies: - `@trigger.dev/core@4.5.5` ## @trigger.dev/sdk@4.5.5 ### Patch Changes - Updated dependencies: - `@trigger.dev/core@4.5.5` </details> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@trigger.dev/schema-to-json
Convert various schema validation libraries to JSON Schema format.
Installation
npm install @trigger.dev/schema-to-json
Important: Bundle Safety
This package is designed to be bundle-safe. It does NOT bundle any schema libraries (zod, yup, etc.) as dependencies. Instead:
- Built-in conversions work immediately (ArkType, Zod 4, TypeBox)
- External conversions (Zod 3, Yup, Effect) require the conversion libraries to be available at runtime
This design ensures that:
- ✅ Your bundle size stays small
- ✅ You only include the schema libraries you actually use
- ✅ Tree-shaking works properly
- ✅ No unnecessary dependencies are installed
Supported Schema Libraries
- ✅ Zod - Full support
- Zod 4: Native support via built-in
toJsonSchemamethod (no external deps needed) - Zod 3: Requires
zod-to-json-schemato be installed
- Zod 4: Native support via built-in
- ✅ Yup - Requires
@sodaru/yup-to-json-schemato be installed - ✅ ArkType - Native support (built-in
toJsonSchemamethod) - ✅ Effect/Schema - Requires
effector@effect/schemato be installed - ✅ TypeBox - Native support (already JSON Schema compliant)
- ⏳ Valibot - Coming soon
- ⏳ Superstruct - Coming soon
- ⏳ Runtypes - Coming soon
Usage
Basic Usage (Built-in conversions only)
import { schemaToJsonSchema } from '@trigger.dev/schema-to-json';
import { type } from 'arktype';
// Works immediately for schemas with built-in conversion
const arkSchema = type({
name: 'string',
age: 'number',
});
const result = schemaToJsonSchema(arkSchema);
console.log(result);
// { jsonSchema: {...}, schemaType: 'arktype' }
Full Usage (With external conversion libraries)
import { schemaToJsonSchema, initializeSchemaConverters } from '@trigger.dev/schema-to-json';
import { z } from 'zod';
// Initialize converters once in your app (loads conversion libraries if available)
await initializeSchemaConverters();
// Now you can convert Zod 3, Yup, and Effect schemas
const zodSchema = z.object({
name: z.string(),
age: z.number(),
email: z.string().email(),
});
const result = schemaToJsonSchema(zodSchema);
console.log(result);
// {
// jsonSchema: {
// type: 'object',
// properties: {
// name: { type: 'string' },
// age: { type: 'number' },
// email: { type: 'string', format: 'email' }
// },
// required: ['name', 'age', 'email']
// },
// schemaType: 'zod'
// }
API
schemaToJsonSchema(schema, options?)
Convert a schema to JSON Schema format.
Parameters:
schema- The schema to convertoptions(optional)name- Name to use for the schema (supported by some converters)additionalProperties- Additional properties to merge into the result
Returns:
{ jsonSchema, schemaType }- The converted JSON Schema and detected typeundefined- If the schema cannot be converted
initializeSchemaConverters()
Initialize the external conversion libraries. Call this once in your application if you need to convert schemas that don't have built-in JSON Schema support (Zod 3, Yup, Effect).
Returns: Promise<void>
canConvertSchema(schema)
Check if a schema can be converted to JSON Schema.
Returns: boolean
detectSchemaType(schema)
Detect the type of schema.
Returns: 'zod' | 'yup' | 'arktype' | 'effect' | 'valibot' | 'superstruct' | 'runtypes' | 'typebox' | 'unknown'
areConvertersInitialized()
Check which conversion libraries are available.
Returns: { zod: boolean, yup: boolean, effect: boolean }
Peer Dependencies
Each schema library is an optional peer dependency. Install only the ones you need:
# For Zod
npm install zod
# For Yup
npm install yup
# For ArkType
npm install arktype
# For Effect
npm install effect @effect/schema
# For TypeBox
npm install @sinclair/typebox
License
MIT