Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "0.111.0"
".": "0.112.0"
}
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
# Changelog

## [0.112.0](https://github.com/kernel/kernel-node-sdk/compare/v0.111.0...v0.112.0) (2026-09-23)


### Features

* Add profiles to browser pool acquire ([0b0f348](https://github.com/kernel/kernel-node-sdk/commit/0b0f348c33f9e9c372b31dbcfd19b505a26057ef))
* Correct monitor_disconnected description on computed state ([809b9c8](https://github.com/kernel/kernel-node-sdk/commit/809b9c8be2eb8919389bc5369e8a8a3cc5590182))
* Filter archived telemetry events by type ([dc46ab2](https://github.com/kernel/kernel-node-sdk/commit/dc46ab213c0333cd16510c789a3fc10cb4bc0383))
* Publish iframe and worker browser target types ([3d555d7](https://github.com/kernel/kernel-node-sdk/commit/3d555d700e9854a2ec1d095d484d916abea4541e))

## [0.111.0](https://github.com/kernel/kernel-node-sdk/compare/v0.110.0...v0.111.0) (2026-09-22)


Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@onkernel/sdk",
"version": "0.111.0",
"version": "0.112.0",
"description": "The official TypeScript library for the Kernel API",
"author": "Kernel <>",
"types": "dist/index.d.ts",
Expand Down
10 changes: 9 additions & 1 deletion src/resources/browser-pools.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1066,6 +1066,13 @@ export interface BrowserPoolAcquireParams {
*/
name?: string;

/**
* Profile selection for the browser session. Provide either id or name. If
* specified, the matching profile will be loaded into the browser session.
* Profiles must be created beforehand.
*/
profile?: Shared.BrowserProfile;

/**
* Optional URL to navigate the acquired browser to. Overrides the pool's start_url
* for this acquire only. Best-effort: failures to navigate do not fail the
Expand Down Expand Up @@ -1200,7 +1207,8 @@ export interface BrowserPoolReleaseParams {
* Defaults to true. A reused browser keeps the configuration it was created with,
* so it does not pick up pool configuration changes made while it was in use.
* Release with `reuse: false`, or flush the pool afterward, to rebuild it with the
* current configuration.
* current configuration. Browsers loaded with an acquire-time profile are always
* destroyed and replaced, even when reuse is true.
*/
reuse?: boolean;
}
Expand Down
60 changes: 49 additions & 11 deletions src/resources/browsers/telemetry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@ export class Telemetry extends APIResource {
/**
* Reads a page of telemetry events for the browser session. To page through
* results, pass the X-Next-Offset value from the previous response as offset and
* repeat while X-Has-More is true. Returns an empty list when telemetry data is
* unavailable.
* repeat while X-Has-More is true. The category and type filters apply within each
* page, so a filtered page may be empty while X-Has-More is true. Returns an empty
* list when telemetry data is unavailable.
*
* @example
* ```ts
Expand Down Expand Up @@ -2979,7 +2980,14 @@ export interface BrowserEventContext {
/**
* CDP target type of the page that produced the event.
*/
target_type?: 'page' | 'background_page' | 'service_worker' | 'shared_worker' | 'other';
target_type?:
| 'page'
| 'iframe'
| 'worker'
| 'background_page'
| 'service_worker'
| 'shared_worker'
| 'other';

/**
* URL relevant to this event — page URL for navigation and page events, request
Expand Down Expand Up @@ -3283,8 +3291,12 @@ export namespace BrowserLiveViewDisconnectEvent {

/**
* The CDP connection to Chrome was lost. Telemetry events may be dropped until
* monitor_reconnected arrives. Treat any in-progress computed state (network_idle,
* page_layout_settled) as unreliable until then.
* monitor_reconnected arrives. In-progress computed state is discarded rather than
* paused, so computed events still pending for the current navigation
* (network_idle, page_layout_settled, page_navigation_settled) never fire.
* monitor_reconnected does not restore them. After reattachment a fresh state
* machine starts, so computed events can resume before the next navigation and
* carry empty navigation context until one occurs.
*/
export interface BrowserMonitorDisconnectedEvent {
category: 'monitor';
Expand Down Expand Up @@ -3769,7 +3781,14 @@ export namespace BrowserPageCrashedEvent {
/**
* CDP target type of the page that produced the event.
*/
target_type: 'page' | 'background_page' | 'service_worker' | 'shared_worker' | 'other';
target_type:
| 'page'
| 'iframe'
| 'worker'
| 'background_page'
| 'service_worker'
| 'shared_worker'
| 'other';

/**
* URL the page was on when its renderer process crashed.
Expand Down Expand Up @@ -4135,7 +4154,14 @@ export namespace BrowserPageNavigationEvent {
/**
* CDP target type of the page that produced the event.
*/
target_type?: 'page' | 'background_page' | 'service_worker' | 'shared_worker' | 'other';
target_type?:
| 'page'
| 'iframe'
| 'worker'
| 'background_page'
| 'service_worker'
| 'shared_worker'
| 'other';

/**
* URL navigated to.
Expand Down Expand Up @@ -4222,7 +4248,14 @@ export namespace BrowserPageTabOpenedEvent {
/**
* CDP target type of the page that produced the event.
*/
target_type?: 'page' | 'background_page' | 'service_worker' | 'shared_worker' | 'other';
target_type?:
| 'page'
| 'iframe'
| 'worker'
| 'background_page'
| 'service_worker'
| 'shared_worker'
| 'other';

/**
* Initial page title of the new tab.
Expand Down Expand Up @@ -4830,9 +4863,7 @@ export interface TelemetryEventsParams extends OffsetPaginationParams {
* Read direction. asc (default) reads oldest first, starting from since or the
* offset cursor. desc reads newest first: each request returns one page of up to
* limit records ending at the offset cursor (or until, or the newest archived
* event); combining desc with since is rejected with a 400. In either direction
* the category filter applies within the page, so a filtered page may be empty
* while X-Has-More is true.
* event); combining desc with since is rejected with a 400.
*/
order?: string;

Expand All @@ -4842,6 +4873,13 @@ export interface TelemetryEventsParams extends OffsetPaginationParams {
*/
since?: string;

/**
* Restrict results to these event types, such as page_crashed or
* captcha_challenge_result. Repeat the parameter for multiple values. Combines
* with category: when both are set an event must match both.
*/
type?: Array<string>;

/**
* End of the window (exclusive): an RFC-3339 timestamp, or a duration like 5m
* meaning that long ago.
Expand Down
2 changes: 1 addition & 1 deletion src/version.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const VERSION = '0.111.0'; // x-release-please-version
export const VERSION = '0.112.0'; // x-release-please-version
1 change: 1 addition & 0 deletions tests/api-resources/browsers/telemetry.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ describe('resource telemetry', () => {
offset: 0,
order: 'order',
since: 'since',
type: ['string'],
until: 'until',
},
{ path: '/_stainless_unknown_path' },
Expand Down
Loading