Skip to content
Merged
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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ dist-deno
/*.tgz
.idea/
.eslintcache
oidc
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.45.0"
".": "0.46.0"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 104
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel%2Fkernel-20310988401243aa5c4a2e2ac6cba5dd90873fb7b83497a2d50c691352c0dd7b.yml
openapi_spec_hash: e19e650b4b2c8c8fde1f739c4aab6b33
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel%2Fkernel-f7024f4171c7c4ec558de1c27f338b1089ffddd0d2dbfdb9bb9f9c2abe8f47bf.yml
openapi_spec_hash: ced43682b49e73a2862f99b49abb4fcd
config_hash: 16e4457a0bb26e98a335a1c2a572290a
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
# Changelog

## 0.46.0 (2026-04-06)

Full Changelog: [v0.45.0...v0.46.0](https://github.com/kernel/kernel-node-sdk/compare/v0.45.0...v0.46.0)

### Features

* Add optional url parameter to proxy check endpoint ([eb53ca2](https://github.com/kernel/kernel-node-sdk/commit/eb53ca23e7ec879ff93ca9c3b76413f98c6dbd87))


### Bug Fixes

* **internal:** gitignore generated `oidc` dir ([2e37932](https://github.com/kernel/kernel-node-sdk/commit/2e3793282c496980415e3fac8cedaaff49d143a5))

## 0.45.0 (2026-03-30)

Full Changelog: [v0.44.0...v0.45.0](https://github.com/kernel/kernel-node-sdk/compare/v0.44.0...v0.45.0)
Expand Down
2 changes: 1 addition & 1 deletion api.md
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ Methods:
- <code title="get /proxies/{id}">client.proxies.<a href="./src/resources/proxies.ts">retrieve</a>(id) -> ProxyRetrieveResponse</code>
- <code title="get /proxies">client.proxies.<a href="./src/resources/proxies.ts">list</a>() -> ProxyListResponse</code>
- <code title="delete /proxies/{id}">client.proxies.<a href="./src/resources/proxies.ts">delete</a>(id) -> void</code>
- <code title="post /proxies/{id}/check">client.proxies.<a href="./src/resources/proxies.ts">check</a>(id) -> ProxyCheckResponse</code>
- <code title="post /proxies/{id}/check">client.proxies.<a href="./src/resources/proxies.ts">check</a>(id, { ...params }) -> ProxyCheckResponse</code>

# Extensions

Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

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.45.0",
"version": "0.46.0",
"description": "The official TypeScript library for the Kernel API",
"author": "Kernel <>",
"types": "dist/index.d.ts",
Expand Down
2 changes: 2 additions & 0 deletions src/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ import {
import { ProfileCreateParams, ProfileListParams, Profiles } from './resources/profiles';
import {
Proxies,
ProxyCheckParams,
ProxyCheckResponse,
ProxyCreateParams,
ProxyCreateResponse,
Expand Down Expand Up @@ -1021,6 +1022,7 @@ export declare namespace Kernel {
type ProxyListResponse as ProxyListResponse,
type ProxyCheckResponse as ProxyCheckResponse,
type ProxyCreateParams as ProxyCreateParams,
type ProxyCheckParams as ProxyCheckParams,
};

export {
Expand Down
1 change: 1 addition & 0 deletions src/resources/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -103,4 +103,5 @@ export {
type ProxyListResponse,
type ProxyCheckResponse,
type ProxyCreateParams,
type ProxyCheckParams,
} from './proxies';
32 changes: 29 additions & 3 deletions src/resources/proxies.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,19 @@ export class Proxies extends APIResource {
}

/**
* Run a health check on the proxy to verify it's working.
* Run a health check on the proxy to verify it's working. Optionally specify a URL
* to test reachability against a specific target. For ISP and datacenter proxies,
* this reliably tests whether the target site is reachable from the proxy's stable
* exit IP. For residential and mobile proxies, the exit node varies between
* requests, so this validates proxy configuration and connectivity rather than
* guaranteeing site-specific reachability.
*/
check(id: string, options?: RequestOptions): APIPromise<ProxyCheckResponse> {
return this._client.post(path`/proxies/${id}/check`, options);
check(
id: string,
body: ProxyCheckParams | null | undefined = {},
options?: RequestOptions,
): APIPromise<ProxyCheckResponse> {
return this._client.post(path`/proxies/${id}/check`, { body, ...options });
}
}

Expand Down Expand Up @@ -1183,12 +1192,29 @@ export namespace ProxyCreateParams {
}
}

export interface ProxyCheckParams {
/**
* An optional URL to test reachability against. If provided, the proxy check will
* test connectivity to this URL instead of the default test URLs. Only HTTP and
* HTTPS schemes are allowed, and the URL must resolve to a public IP address. For
* ISP and datacenter proxies, the exit IP is stable, so a successful check
* reliably indicates that subsequent browser sessions will reach the target site
* with the same IP. For residential and mobile proxies, the exit node changes
* between requests, so a successful check validates proxy configuration but does
* not guarantee that a subsequent browser session will use the same exit IP or
* reach the same site — it is useful for verifying credentials and connectivity,
* not for predicting site-specific behavior.
*/
url?: string;
}

export declare namespace Proxies {
export {
type ProxyCreateResponse as ProxyCreateResponse,
type ProxyRetrieveResponse as ProxyRetrieveResponse,
type ProxyListResponse as ProxyListResponse,
type ProxyCheckResponse as ProxyCheckResponse,
type ProxyCreateParams as ProxyCreateParams,
type ProxyCheckParams as ProxyCheckParams,
};
}
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.45.0'; // x-release-please-version
export const VERSION = '0.46.0'; // x-release-please-version
8 changes: 8 additions & 0 deletions tests/api-resources/proxies.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,4 +78,12 @@ describe('resource proxies', () => {
expect(dataAndResponse.data).toBe(response);
expect(dataAndResponse.response).toBe(rawResponse);
});

// Mock server tests are disabled
test.skip('check: request options and params are passed correctly', async () => {
// ensure the request options are being passed correctly by passing an invalid HTTP method in order to cause an error
await expect(
client.proxies.check('id', { url: 'url' }, { path: '/_stainless_unknown_path' }),
).rejects.toThrow(Kernel.NotFoundError);
});
});
Loading