npm / @effect/platform-bun
@effect/platform-bun
What changed in @effect/platform-bun 0.82 to 4, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-30.
12 breaking2 security262 new APIs and options5 behavior and defaults9 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli init@effect/platform-bun 4275 changes
Breaking changes 4
Default redacted names AWSAccessKeyId, Signature, sig, and X-Goog-Signature move from Headers.CurrentRedactedNames to UrlParams.CurrentRedactedNames; a custom list replaces these defaults.
Esc now ends terminal key input by default and cancels CLI prompts with Terminal.QuitError; pass a shouldQuit predicate to make to keep Esc non-cancelling.
Effect ecosystem packages share a single version; use the matching v4 version of this platform-specific package alongside effect.
Server WebSockets now close with code 1000 on success, 1001 on interruption, or 1011 on failure, while preserving explicit close codes.
Security 2
The decoder does not read external resources or expand entities declared in a DOCTYPE, preventing external entity and entity expansion attacks.
Sensitive query values and URL credentials are redacted in HTTP spans, request inspection, and error messages; URLs sent over the wire are unchanged.
New APIs and options 257
Applies an edit script to an array.
Applies a text edit script to a string.
Adds a context reference for specifying the statement that starts a top-level transaction instead of the client's BEGIN; defaults to undefined.
Checks whether a version's precedence is within an inclusive range.
Adds a constructor for ranges matching versions within inclusive bounds.
Returns the next major release.
Returns the next minor release.
Returns the next patch release.
Returns the first pre-release of the next major version.
Returns the first pre-release of the next minor version.
Returns the first pre-release of the next patch version.
Returns the next pre-release.
Adds a constructor for ranges matching versions compatible with a version.
Constrains a version's precedence to an inclusive range.
Adds a reason for a closed client, transport, or legacy HTTP session.
Computes a minimal code point edit script between two strings.
Adds an event interface for XML comments, holding the text between comment tags.
Registers a compactor for one row event of a group.
Adds an interface for the numeric components and identifiers of a version.
Adds an API that joins byte chunks into one new Uint8Array.
Adds a reason for invalid client or toolkit options.
Adds a model that tracks writes to suppress their echoes on the same RPC connection.
Adds a zip entry type whose uncompressed content is held in memory.
Adds an interface for provider-specific response metadata keyed by provider name, which provider packages can augment.
Answers each decision with a Result containing a validated answer or a Decision.Unanswered reason; input encoding and provider failures still fail the effect, and token usage covers the whole call.
Adds an interface for per-decision outcomes, token usage, and response metadata for the whole request.
Adds an event interface for the XML declaration at the start of a document.
Creates a channel that parses UTF-8 bytes of one JSON document and emits the elements of one of its arrays.
Creates a channel that decodes UTF-8 XML bytes into events.
Creates a channel that decodes zip archive bytes into entries.
Adds JSON array decoding options.
Adds an interface for options for the XML decoders.
Creates a channel that parses UTF-8 bytes of one JSON document and decodes the elements of one of its arrays with a schema.
Creates a channel that parses the text of one JSON document and decodes the elements of one of its arrays with a schema.
Creates a channel that parses the text of one JSON document and emits the elements of one of its arrays.
Creates a channel that decodes XML text chunks into events.
Adds a type for required fields whose string, number, or Uint8Array values can form keys without derive.
Computes a minimal edit script between arrays, comparing items with Equal.equals.
Classifies the change between two versions by release type.
Creates a function that computes a minimal edit script between arrays using a custom equivalence.
Creates a directory entry.
Adds an event interface for a document type declaration.
Adds the Edit type representing one run of an edit script.
Adds an interface for a run of items present only in the before sequence.
Adds an interface for a run of items present in both sequences.
Adds an interface for a run of items present only in the after sequence.
Adds an interface for an element collected by elements, with its attributes and children.
Creates a channel that collects the elements at a path into trees.
Adds an interface for options for elements.
Creates a channel that writes a stream of values as UTF-8 bytes of one JSON array.
Creates a channel that writes events as UTF-8 XML bytes.
Creates a channel that encodes entries into zip archive bytes.
Adds an API that encodes a value into a padded URL-safe Base64 string.
Creates a channel that encodes values with a schema and writes them as UTF-8 bytes of one JSON array.
Creates a channel that encodes values with a schema and writes them as the text of one JSON array.
Creates a channel that writes a stream of values as the text of one JSON array.
Creates a channel that writes events as XML text.
Adds an event interface for an end tag.
Adds a gauge tracking the mailbox size of each entity resident on the current runner.
Adds a gauge tracking the largest mailbox size among the entities of each type resident on the current runner.
Adds a zip entry type consisting of a header and a stream of uncompressed body bytes.
Adds a type for the kind of object described by a zip entry.
Checks whether two versions are structurally equal, including build metadata.
Adds byte-by-byte equality comparison for byte sequences.
Provides structural equivalence for versions, including build metadata.
Adds the event type produced by decoders and consumed by encoders.
Adds an interface for a row type that syncs through an EventLog.
Adds a constructor for a range matching exactly one version.
Adds options for file entries.
Adds options for file entries whose content is streamed.
Formats a version as its canonical string, including pre-release identifiers and build metadata.
Adds canonical formatting for a range.
Adds an interface for options to fromApi.
Converts a version, version string, or version components into a SemVer.
Adds conversion of a range or range string into a SemVerRange.
Converts a version, version string, or version components into a SemVer and throws SemVerError for invalid input.
Adds conversion of a range or range string into a SemVerRange, throwing SemVer.SemVerError for invalid input.
Adds a constructor for ranges matching versions with higher precedence.
Adds a constructor for ranges matching versions with at least the given precedence.
Builds a handler for a row event to pass to handlers.handle.
Adds a context reference for a transaction wrapping event handlers during remote batch replay and local write or writeMany operations.
Checks whether a version has build metadata.
Adds a type for zip entry metadata.
Creates a Streamable HTTP transport with request-owned JSON or SSE responses.
Adds an error for streaming request payloads that exceed a schema-declared limit; it responds with an empty 413 Payload Too Large and is ignored by error reporters.
Adds a runtime identifier used to mark and detect HttpApiPayloadTooLarge values.
Adds a reason for a non-success HTTP status; JSON-RPC error bodies supply code, data, and description.
Adds a type for values accepted by fromInput: a version, version string literal, or version components.
Adds the type of values accepted by fromInput: a range or a range string.
Inverts an edit script so it turns the after sequence back into the before sequence.
Checks whether the first version has higher precedence than the second.
Checks whether the first version has higher or equal precedence than the second.
Checks whether a version is in initial development, meaning its major version is 0.
Adds a check for whether a value is a JsonArrayError.
Checks whether the first version has lower precedence than the second.
Checks whether the first version has lower or equal precedence than the second.
Adds a guard that returns whether a value is an MCP client.
Adds a guard that checks whether a value is an McpClientError.
Adds a guard that checks whether a value is an McpClientError reason.
Checks whether a version has pre-release identifiers.
Checks whether a value is a SemVer.
Checks whether a value is a SemVerError.
Adds a check for whether a value is a SemVerRange.
Checks whether a value is a TextDiffError.
Adds a check for whether a value is an XmlError.
Checks whether a value is a ZipError.
Adds an error raised when JSON array encoding or decoding fails.
Adds a type for JSON-RPC messages exchanged by MCP peers.
Adds a schema for JSON-RPC messages exchanged by MCP peers.
Adds a type for JSON-RPC notifications without a request identifier.
Adds a schema for JSON-RPC notifications without a request identifier.
Adds a type for JSON-RPC requests.
Adds a schema for JSON-RPC requests.
Adds a type for JSON-RPC responses carrying exactly one result or remote error.
Adds a schema for JSON-RPC responses carrying a result or remote error.
Adds a type for a row key declared from one or more fields.
Adds a type for the values of a row's declared key fields.
Provides a connected MCP client over Streamable HTTP using the HTTP client.
Provides a connected MCP client over stdio using the child process spawner.
Adds a constructor for ranges matching versions with lower precedence.
Adds a constructor for ranges matching versions with at most the given precedence.
Adds a reason for a message or discovery scan exceeding a client limit.
Computes a minimal line-level edit script between two strings.
Constructs and connects a client using the supplied MCP transport service and its protocol adapter.
Defines a row type as a single event.
Creates a version from its components and throws SemVerError for invalid components.
Adds a check for whether a range matches a version.
Adds options controlling how pre-release versions match a range.
Returns the version with higher precedence, preferring the first on ties.
Adds selection of the matching version with the highest precedence.
Adds scoped Effect clients for MCP servers that discover tools, prompts, and resources. Tool-reported errors are results by default; supplying a schema turns them into a ToolError reason retaining the original result.
Adds an error wrapping an MCP client or transport failure reason.
Adds a union type for MCP client and transport failure reasons.
Adds a schema for the reasons carried by an McpClientError.
Adds a type for the compression method of a zip entry.
Returns the version with lower precedence, preferring the first on ties.
Adds selection of the matching version with the lowest precedence.
Adds an unstable type describing why a decoder rejected a line.
Adds lexicographic ordering by unsigned byte value, with prefixes before longer sequences that start with them.
Orders versions by Semantic Versioning precedence.
Adds an unstable type for a validated answer or the reason the decision is unanswered.
Adds an unstable type for settled results keyed by decision name.
Parses a strict Semantic Versioning 2.0.0 string.
Adds parsing for npm-style version ranges.
Parses a strict Semantic Versioning 2.0.0 string and throws SemVerError for invalid input.
Adds parsing for npm-style version ranges, throwing SemVer.SemVerError for invalid input.
Adds a type for optional non-key fields of a patch payload.
Adds a type for decoded payloads of row events.
Adds a type for the schema of a row event's payload, derived from the row schema.
Adds a type for a row's primary key, using the key value for a string-typed single-field key and string otherwise.
Adds an event interface for processing instructions.
Adds a reason for a JSON-RPC error or a message invalid for the selected protocol.
Adds a type for supported MCP wire protocol revisions.
Adds an interface representing a provider refusal to answer a decision.
Registers a series backed by caller-supplied hooks, for gauges whose value is read when metrics are snapshotted rather than pushed with updates.
Adds a handle for a series registered with Metric.registerUnsafe.
Removes pre-release identifiers and build metadata from a version.
Adds a type naming version changes, matching npm's release types.
Adds a model for a local entry's remote-assigned sequence.
Removes the series of a metric for the current attributes from the metric registry.
Removes the series of a metric for the attributes in the provided Context from the metric registry in that Context.
Adds a type for required fields that can be part of a declared row key.
Adds immutable Semantic Versioning 2.0.0 values with strict parsing, canonical formatting, precedence ordering, and version bumps.
Adds an unstable type-level representation of SemVer.
Adds an unstable schema for SemVer values.
Adds an error raised for invalid version strings, ranges, or components.
Adds an unstable type-level representation of SemVerFromString.
Adds an unstable schema that parses a Semantic Versioning 2.0.0 string into a SemVer.
Adds an interface representing an npm-style version range.
Adds an unstable type-level representation of SemVerRange.
Adds an unstable schema for SemVerRange values.
Adds an unstable type-level representation of SemVerRangeFromString.
Adds an unstable schema that parses an npm-style version range string into a SemVerRange.
Adds an unstable reviver for persisted Schema.SemVerRange declarations.
Adds an unstable reviver for persisted Schema.SemVer declarations.
Adds an event interface for start tags, with attributes in document order.
Starts a scoped subprocess using newline-delimited JSON-RPC.
Adds a schema for a stream of newline-delimited JSON elements.
Adds an event interface for character data inside the root element.
Adds a module for computing, applying, inverting and formatting array and text edit scripts using Myers' algorithm.
Adds an error for edit scripts that do not fit the input they are applied to.
Adds a constructor for ranges matching patch-level changes of a version.
Adds a reason for an operation that exceeds its deadline.
Derives a JSON codec that also accepts null values written by Go's encoding/json for nil pointers, slices, and maps.
Adds a reason for a tool execution error and retains the complete result.
Discovers remote tools and binds their handlers using the standard Toolkit implementation.
Adds a transport interface for exchanging JSON-RPC messages with one MCP server using its protocol adapter, and a service supplied by the built-in transport constructors and layers.
Adds a reason for connection failures involving process or HTTP request startup, writes, reads, or early termination.
Adds an unstable interface describing the reason and description of the first failed answer validation check.
Formats a line edit script as a unified diff.
Adds a constant representing the MCP error code returned when a server does not support the protocol version requested by a client.
Adds a reason for unsupported operations or tool results that cannot be converted for a language model.
Adds a combinator that asks the server to switch the connection to another protocol by setting the Connection: Upgrade and Upgrade headers.
Adds the return value model for client methods on endpoints declared with HttpApiSchema.Upgrade, containing the 101 Switching Protocols response headers and upgraded connection.
Adds a reason for request payloads, tool arguments, or results that fail schema validation.
Adds a type for version string literals accepted by fromInput.
Replaces a version's build metadata and throws SemVerError for invalid identifiers.
Replaces a version's pre-release identifiers and throws SemVerError for invalid identifiers.
Adds a type for row events returned by a row's set, patch, and remove constructors.
Adds a schema for a written entry's id and the sequence at which the server stores it, including acknowledgements for entries written again in partly known batches.
Adds an error raised when XML cannot be decoded or encoded.
Adds a module for encoding and decoding zip archives as streams in Effect channels; encryption, other compression methods, and split archives are not supported.
Error raised when a zip archive cannot be encoded or decoded.
Creates a channel that decodes tar archive bytes into entries.
Creates a directory entry for a tar archive.
Creates a channel that encodes entries into tar archive bytes.
Adds a tar entry interface representing a header and a stream of exactly header.size body bytes.
Adds the options interface for entry constructors.
Adds a type for the kind of filesystem object described by a tar entry.
Creates a regular file entry from in-memory content.
Creates a regular file entry whose content is streamed from body.
Creates a hard link entry pointing at another entry of the archive.
Adds an interface for tar entry metadata.
Checks whether a value is a TarError.
Creates a symbolic link entry pointing at target.
Adds an error raised when a tar archive cannot be encoded or decoded.
Adds an API for checking whether a URL parameter name is redacted.
Adds an API for explicit redaction of URL parameter values.
Adds an API for explicitly redacting URLs.
Adds UDP socket support on Bun.
Adds a helper for name server inputs in the platform Dns services.
Node and Bun WebSocket clients can send handshake headers alongside subprotocols through socket constructors, channels, and layers.
Adds a service tag for the scheduled time of the cron run currently executing.
Adds an unstable schema for HTTP date header values, decoded as DateTime.Utc, and a type-level representation.
Adds a type for an encrypted batch stored by a remote server, including the remote sequence of its first entry.
Formats a DateTime as an IMF-fixdate HTTP date.
Formats a Retry-After value as a header value: the delay as whole seconds, or the date as an IMF-fixdate.
Adds an unstable API that registers a batch compaction handler for an event group.
Adds an error returned when a header value does not match its grammar.
Adds an error reason describing which header value failed to parse.
Checks whether a value is a HeaderParseError.
Adds a registry of reactivity keys and the ID type each key accepts.
Adds the keys accepted by the public reactivity APIs.
Adds a layer that detects terminal capabilities from Stdio and the current ConfigProvider.
Provides a layer that resolves directories for the host platform.
Provides a layer that resolves directories for a specified platform.
Creates a resolver that reads the environment from the current ConfigProvider on every call, using platform conventions.
Adds an error for invalid non-empty NDJSON frames; its cause field preserves the original JSON parsing error.
Parses an HTTP date header value into a UTC DateTime.
Sets the schema parse options used by RpcClient and RpcServer when encoding and decoding an RPC's payload, success values, stream chunks, and exits.
Parses a Retry-After header value.
Adds a type representing a parsed Retry-After header value.
Adds an unstable schema for parsed Retry-After header values and a type-level representation.
Creates a Retry-After value from an HTTP date.
Adds an interface for a Retry-After value given as an HTTP date.
Computes how long to wait for a Retry-After value, measured from now in epoch milliseconds.
Creates a Retry-After value from a delay.
Adds an interface for a Retry-After value given as a delay.
Provides an Equivalence instance for Retry-After values.
Adds an unstable schema that decodes Retry-After header values with Headers.parseRetryAfter, and a type-level representation.
Adds a timer tracking how long the current runner takes to release a shard after reassignment, lock loss or shutdown handoff.
Adds a reference to the current process's terminal capabilities and an interface for its terminal rendering flags.
Returns the original Web Response of a fetch-backed HttpClientResponse.
Adds options for xForwardedHeaders.
Adds an identifier for a UserDirectories service.
Adds an interface for resolving the directories where an application keeps its files.
Adds a service tag for the user directory resolver.
Behavior and default changes 5
Adds a range matching every release, written *.
The module is experimental and may receive breaking changes in patch releases.
Unless a CliOutput.Formatter is provided, built-in Command help, version, and error output follows canColor.
Every module and directly importable export now has an explicit stability tag; stable follows strict semver, while unstable may receive breaking changes in minor releases.
The default reads NO_COLOR, FORCE_COLOR, TERM, and the current process's TTY state; the layer reads the same variables through ConfigProvider and the TTY state of Stdio.
Fixes and other changes 7
Bumps a version by release type.
When self.close is unavailable, Bun worker finalizers now complete before exit.
Accepts address inputs.
Server middleware such as HttpMiddleware.logger and HttpMiddleware.tracer now reports status 101 for a successful WebSocket upgrade instead of the handler's discarded response status.
Readers no longer throw when a pull is interrupted or its scope closes during a read; consumed bytes are preserved in order across interruption and normal EOF, and discarded when the reader scope closes.
The Bun package provides the platform Crypto service.
HTTP request scopes retain the handler's failure exit through response handling and middleware.
@effect/platform-bun 0.914 changes
New APIs and options 2
Cluster RPC serialization buffer limits can now be configured.
Adds the extendEnv option for spawning commands with a clean environment.
Fixes and other changes 2
WebSocket compression now preserves options and compresses outgoing messages.
Server WebSockets now close with code 1001 (Going Away) instead of 1011 when the handler fiber is only interrupted.
@effect/platform-bun 0.872 changes
New APIs and options 2
Added the isTTY property to Terminal.
Added the rows property to Terminal.
@effect/platform-bun 0.829 changes
Breaking changes 8
The Bun cluster HTTP runner is now available from @effect/cluster as BunClusterHttp.
The platform-bun runner name was replaced by @effect/cluster/BunClusterHttp.
The Bun cluster socket runner is now available from @effect/cluster as BunClusterSocket.
The platform-bun runner name was replaced by @effect/cluster/BunClusterSocket.
Shard locks now use database advisory locks, requiring stable database sessions; load balancers or proxies that rotate connections may cause issues.
The EntityNotManagedByRunner error has been removed.
@effect/cluster no longer requires a Shard Manager and instead uses the RunnerStorage service to track runner state.
The ShardManager module has been removed; remove Shard Manager deployments and use the updated platform layers.
New APIs and options 1
Added a layer that uses the Kubernetes API to track runner health and liveness; using it requires a service account with permission to read pod information.