From 37d3e277f98b068f23c5fc85e7b26269c254827c Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 9 Jul 2026 23:07:50 +0000 Subject: [PATCH 1/4] docs(openapi): describe unified concurrency limit, deprecate max_pooled_sessions (CUS-275) --- .stats.yml | 4 ++-- src/resources/organization/limits.ts | 27 +++++++++++++------------ src/resources/projects/limits.ts | 30 +++++++++++++++++----------- 3 files changed, 34 insertions(+), 27 deletions(-) diff --git a/.stats.yml b/.stats.yml index 3f7dec3b..c7028199 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 125 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel/kernel-ba32039d3975da7aa6d28e5184f0a44c9fbfe36ab7dbc71985d14e2ecc0867b9.yml -openapi_spec_hash: a9f32fc90c2add2ae85af828c298e35b +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel/kernel-db45aab5b114bc0848eab997c85bfc02a653be9f929f8d090ec24187462733ee.yml +openapi_spec_hash: 82f4282312699f8d54bec207e981efe8 config_hash: 06186eb40e0058a2a87ac251fc07415d diff --git a/src/resources/organization/limits.ts b/src/resources/organization/limits.ts index 53f2f5c0..f0948cbd 100644 --- a/src/resources/organization/limits.ts +++ b/src/resources/organization/limits.ts @@ -9,8 +9,9 @@ import { RequestOptions } from '../../internal/request-options'; */ export class Limits extends APIResource { /** - * Get the organization's concurrent session ceiling and the default per-project - * concurrency cap applied to projects without an explicit override. + * Get the organization's concurrency limit — the maximum browsers running at once + * across on-demand sessions and browser pool reservations — and the default + * per-project concurrency cap applied to projects without an explicit override. */ retrieve(options?: RequestOptions): APIPromise { return this._client.get('/org/limits', options); @@ -19,8 +20,7 @@ export class Limits extends APIResource { /** * Set the default per-project concurrency cap applied to projects without an * explicit override. Set the value to 0 to remove the default; omit to leave it - * unchanged. The default cannot exceed the organization's concurrent session - * ceiling. + * unchanged. The default cannot exceed the organization's concurrency limit. */ update(body: LimitUpdateParams, options?: RequestOptions): APIPromise { return this._client.patch('/org/limits', { body, ...options }); @@ -29,7 +29,7 @@ export class Limits extends APIResource { export interface OrgLimits { /** - * Default maximum concurrent browser sessions applied to every project that has no + * Default maximum concurrent browsers applied to every project that has no * explicit per-project override. Null means no org-level default, so such projects * are uncapped (only the org-wide limit applies). Applies to existing and newly * created projects. @@ -37,8 +37,9 @@ export interface OrgLimits { default_project_max_concurrent_sessions?: number | null; /** - * The organization's effective concurrent browser session ceiling, from its plan - * or an override. Read-only and shared across all projects in the org; a + * The organization's effective concurrency limit — the maximum browsers running at + * once, covering both on-demand sessions and browser pool reservations — from its + * plan or an override. Read-only and shared across all projects in the org; a * per-project default cannot exceed it. */ max_concurrent_sessions?: number; @@ -46,18 +47,18 @@ export interface OrgLimits { export interface UpdateOrgLimitsRequest { /** - * Default maximum concurrent browser sessions for projects without an explicit - * override. Set to 0 to remove the default; omit to leave unchanged. Cannot exceed - * the organization's concurrent session ceiling. + * Default maximum concurrent browsers for projects without an explicit override. + * Set to 0 to remove the default; omit to leave unchanged. Cannot exceed the + * organization's concurrency limit. */ default_project_max_concurrent_sessions?: number | null; } export interface LimitUpdateParams { /** - * Default maximum concurrent browser sessions for projects without an explicit - * override. Set to 0 to remove the default; omit to leave unchanged. Cannot exceed - * the organization's concurrent session ceiling. + * Default maximum concurrent browsers for projects without an explicit override. + * Set to 0 to remove the default; omit to leave unchanged. Cannot exceed the + * organization's concurrency limit. */ default_project_max_concurrent_sessions?: number | null; } diff --git a/src/resources/projects/limits.ts b/src/resources/projects/limits.ts index 52ec16ac..d1a3e53c 100644 --- a/src/resources/projects/limits.ts +++ b/src/resources/projects/limits.ts @@ -49,14 +49,16 @@ export interface ProjectLimits { max_concurrent_invocations?: number | null; /** - * Maximum concurrent browser sessions for this project. Null means no - * project-level cap. + * Maximum concurrent browsers for this project, covering both on-demand sessions + * (`browsers.create()`) and browser pool reservations. Null means no project-level + * cap. */ max_concurrent_sessions?: number | null; /** - * Maximum pooled sessions capacity for this project. Null means no project-level - * cap. + * @deprecated Deprecated: pooled browsers now count toward + * `max_concurrent_sessions`. Always null once the unified concurrency limit is + * enabled for your organization. */ max_pooled_sessions?: number | null; } @@ -69,14 +71,16 @@ export interface UpdateProjectLimitsRequest { max_concurrent_invocations?: number | null; /** - * Maximum concurrent browser sessions for this project. Set to 0 to remove the - * cap; omit to leave unchanged. + * Maximum concurrent browsers for this project, covering both on-demand sessions + * and browser pool reservations. Set to 0 to remove the cap; omit to leave + * unchanged. */ max_concurrent_sessions?: number | null; /** - * Maximum pooled sessions capacity for this project. Set to 0 to remove the cap; - * omit to leave unchanged. + * @deprecated Deprecated: pooled browsers now count toward + * `max_concurrent_sessions`. Requests that set this field are rejected with a 400 + * once the unified concurrency limit is enabled for your organization. */ max_pooled_sessions?: number | null; } @@ -89,14 +93,16 @@ export interface LimitUpdateParams { max_concurrent_invocations?: number | null; /** - * Maximum concurrent browser sessions for this project. Set to 0 to remove the - * cap; omit to leave unchanged. + * Maximum concurrent browsers for this project, covering both on-demand sessions + * and browser pool reservations. Set to 0 to remove the cap; omit to leave + * unchanged. */ max_concurrent_sessions?: number | null; /** - * Maximum pooled sessions capacity for this project. Set to 0 to remove the cap; - * omit to leave unchanged. + * @deprecated Deprecated: pooled browsers now count toward + * `max_concurrent_sessions`. Requests that set this field are rejected with a 400 + * once the unified concurrency limit is enabled for your organization. */ max_pooled_sessions?: number | null; } From 2fe41244b7e184914c6858a9533132d65b4380ba Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 10 Jul 2026 13:46:00 +0000 Subject: [PATCH 2/4] feat: Add name-only rename for profiles and proxies --- .stats.yml | 8 +- api.md | 3 + src/client.ts | 7 +- src/resources/index.ts | 9 +- src/resources/profiles.ts | 78 +++++++++- src/resources/proxies.ts | 213 +++++++++++++++++++++++++++ tests/api-resources/profiles.test.ts | 17 +++ tests/api-resources/proxies.test.ts | 17 +++ 8 files changed, 344 insertions(+), 8 deletions(-) diff --git a/.stats.yml b/.stats.yml index c7028199..09109a9b 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ -configured_endpoints: 125 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel/kernel-db45aab5b114bc0848eab997c85bfc02a653be9f929f8d090ec24187462733ee.yml -openapi_spec_hash: 82f4282312699f8d54bec207e981efe8 -config_hash: 06186eb40e0058a2a87ac251fc07415d +configured_endpoints: 127 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel/kernel-bc33d13e669972493e9ab0da82a71999822dc049eb14b113f446753c917ffcdb.yml +openapi_spec_hash: 133a2e0d0cdc4023f98b3c2e589cf5d8 +config_hash: 77ee715aa17061166f9a02b264a21b8d diff --git a/api.md b/api.md index d729ebd3..f7950f3e 100644 --- a/api.md +++ b/api.md @@ -252,6 +252,7 @@ Methods: - client.profiles.create({ ...params }) -> Profile - client.profiles.retrieve(idOrName) -> Profile +- client.profiles.update(idOrName, { ...params }) -> Profile - client.profiles.list({ ...params }) -> ProfilesOffsetPagination - client.profiles.delete(idOrName) -> void - client.profiles.download(idOrName) -> Response @@ -289,6 +290,7 @@ Types: - ProxyCreateResponse - ProxyRetrieveResponse +- ProxyUpdateResponse - ProxyListResponse - ProxyCheckResponse @@ -296,6 +298,7 @@ Methods: - client.proxies.create({ ...params }) -> ProxyCreateResponse - client.proxies.retrieve(id) -> ProxyRetrieveResponse +- client.proxies.update(id, { ...params }) -> ProxyUpdateResponse - client.proxies.list({ ...params }) -> ProxyListResponsesOffsetPagination - client.proxies.delete(id) -> void - client.proxies.check(id, { ...params }) -> ProxyCheckResponse diff --git a/src/client.ts b/src/client.ts index db4f3c37..7dd7a576 100644 --- a/src/client.ts +++ b/src/client.ts @@ -123,7 +123,7 @@ import { InvocationUpdateResponse, Invocations, } from './resources/invocations'; -import { ProfileCreateParams, ProfileListParams, Profiles } from './resources/profiles'; +import { ProfileCreateParams, ProfileListParams, ProfileUpdateParams, Profiles } from './resources/profiles'; import { Proxies, ProxyCheckParams, @@ -134,6 +134,8 @@ import { ProxyListResponse, ProxyListResponsesOffsetPagination, ProxyRetrieveResponse, + ProxyUpdateParams, + ProxyUpdateResponse, } from './resources/proxies'; import { Auth } from './resources/auth/auth'; import { @@ -1122,6 +1124,7 @@ export declare namespace Kernel { export { Profiles as Profiles, type ProfileCreateParams as ProfileCreateParams, + type ProfileUpdateParams as ProfileUpdateParams, type ProfileListParams as ProfileListParams, }; @@ -1131,10 +1134,12 @@ export declare namespace Kernel { Proxies as Proxies, type ProxyCreateResponse as ProxyCreateResponse, type ProxyRetrieveResponse as ProxyRetrieveResponse, + type ProxyUpdateResponse as ProxyUpdateResponse, type ProxyListResponse as ProxyListResponse, type ProxyCheckResponse as ProxyCheckResponse, type ProxyListResponsesOffsetPagination as ProxyListResponsesOffsetPagination, type ProxyCreateParams as ProxyCreateParams, + type ProxyUpdateParams as ProxyUpdateParams, type ProxyListParams as ProxyListParams, type ProxyCheckParams as ProxyCheckParams, }; diff --git a/src/resources/index.ts b/src/resources/index.ts index a7fdf353..797de87a 100644 --- a/src/resources/index.ts +++ b/src/resources/index.ts @@ -120,7 +120,12 @@ export { type InvocationListResponsesOffsetPagination, } from './invocations'; export { Organization } from './organization/organization'; -export { Profiles, type ProfileCreateParams, type ProfileListParams } from './profiles'; +export { + Profiles, + type ProfileCreateParams, + type ProfileUpdateParams, + type ProfileListParams, +} from './profiles'; export { Projects, type CreateProjectRequest, @@ -135,9 +140,11 @@ export { Proxies, type ProxyCreateResponse, type ProxyRetrieveResponse, + type ProxyUpdateResponse, type ProxyListResponse, type ProxyCheckResponse, type ProxyCreateParams, + type ProxyUpdateParams, type ProxyListParams, type ProxyCheckParams, type ProxyListResponsesOffsetPagination, diff --git a/src/resources/profiles.ts b/src/resources/profiles.ts index aa78a014..29708d84 100644 --- a/src/resources/profiles.ts +++ b/src/resources/profiles.ts @@ -16,6 +16,11 @@ export class Profiles extends APIResource { /** * Create a browser profile that can be used to load state into future browser * sessions. + * + * @example + * ```ts + * const profile = await client.profiles.create(); + * ``` */ create(body: ProfileCreateParams, options?: RequestOptions): APIPromise { return this._client.post('/profiles', { body, ...options }); @@ -23,13 +28,52 @@ export class Profiles extends APIResource { /** * Retrieve details for a single profile by its ID or name. + * + * @example + * ```ts + * const profile = await client.profiles.retrieve( + * 'id_or_name', + * ); + * ``` */ retrieve(idOrName: string, options?: RequestOptions): APIPromise { return this._client.get(path`/profiles/${idOrName}`, options); } + /** + * Update a profile's name. Names must be unique within the logical project; during + * the default-project migration, unscoped profiles and profiles in the org default + * project are treated as the same project. Duplicate-name conflicts are checked + * before update but are best-effort because there is no backing unique index. + * Renaming a profile while a browser session references it by name may prevent + * that session's changes from saving; prefer renaming when the profile is not in + * use. + * + * @example + * ```ts + * const profile = await client.profiles.update('id_or_name', { + * name: 'my-renamed-profile', + * }); + * ``` + */ + update( + idOrName: string, + body: ProfileUpdateParams, + options?: RequestOptions, + ): APIPromise { + return this._client.patch(path`/profiles/${idOrName}`, { body, ...options }); + } + /** * List profiles with optional filtering and pagination. + * + * @example + * ```ts + * // Automatically fetches more pages as needed. + * for await (const profile of client.profiles.list()) { + * // ... + * } + * ``` */ list( query: ProfileListParams | null | undefined = {}, @@ -40,6 +84,11 @@ export class Profiles extends APIResource { /** * Delete a profile by its ID or by its name. + * + * @example + * ```ts + * await client.profiles.delete('id_or_name'); + * ``` */ delete(idOrName: string, options?: RequestOptions): APIPromise { return this._client.delete(path`/profiles/${idOrName}`, { @@ -50,6 +99,16 @@ export class Profiles extends APIResource { /** * Returns a zstd-compressed tar file of the full user-data directory. + * + * @example + * ```ts + * const response = await client.profiles.download( + * 'id_or_name', + * ); + * + * const content = await response.blob(); + * console.log(content); + * ``` */ download(idOrName: string, options?: RequestOptions): APIPromise { return this._client.get(path`/profiles/${idOrName}/download`, { @@ -62,11 +121,22 @@ export class Profiles extends APIResource { export interface ProfileCreateParams { /** - * Optional name of the profile. Must be unique within the project. + * Optional name of the profile. Must be unique within the logical project; during + * the default-project migration, unscoped profiles and profiles in the org default + * project are treated as the same project. */ name?: string; } +export interface ProfileUpdateParams { + /** + * New profile name. Must be unique within the logical project; during the + * default-project migration, unscoped profiles and profiles in the org default + * project are treated as the same project. + */ + name: string; +} + export interface ProfileListParams extends OffsetPaginationParams { /** * Search profiles by name or ID. @@ -75,7 +145,11 @@ export interface ProfileListParams extends OffsetPaginationParams { } export declare namespace Profiles { - export { type ProfileCreateParams as ProfileCreateParams, type ProfileListParams as ProfileListParams }; + export { + type ProfileCreateParams as ProfileCreateParams, + type ProfileUpdateParams as ProfileUpdateParams, + type ProfileListParams as ProfileListParams, + }; } export { type ProfilesOffsetPagination }; diff --git a/src/resources/proxies.ts b/src/resources/proxies.ts index 3dda98f5..a9295fae 100644 --- a/src/resources/proxies.ts +++ b/src/resources/proxies.ts @@ -13,6 +13,13 @@ import { path } from '../internal/utils/path'; export class Proxies extends APIResource { /** * Create a new proxy configuration in the resolved project. + * + * @example + * ```ts + * const proxy = await client.proxies.create({ + * type: 'datacenter', + * }); + * ``` */ create(body: ProxyCreateParams, options?: RequestOptions): APIPromise { return this._client.post('/proxies', { body, ...options }); @@ -20,13 +27,43 @@ export class Proxies extends APIResource { /** * Retrieve a proxy in the resolved project by ID. + * + * @example + * ```ts + * const proxy = await client.proxies.retrieve('id'); + * ``` */ retrieve(id: string, options?: RequestOptions): APIPromise { return this._client.get(path`/proxies/${id}`, options); } + /** + * Update a proxy's name. Proxy names are not unique and are not ID-or-name + * addressable on this endpoint; duplicate names are allowed. Name-based + * session-create lookups can remain ambiguous until callers resolve proxies by ID + * or the API adds a stronger uniqueness contract. + * + * @example + * ```ts + * const proxy = await client.proxies.update('id', { + * name: 'my-renamed-proxy', + * }); + * ``` + */ + update(id: string, body: ProxyUpdateParams, options?: RequestOptions): APIPromise { + return this._client.patch(path`/proxies/${id}`, { body, ...options }); + } + /** * List proxies in the resolved project. + * + * @example + * ```ts + * // Automatically fetches more pages as needed. + * for await (const proxyListResponse of client.proxies.list()) { + * // ... + * } + * ``` */ list( query: ProxyListParams | null | undefined = {}, @@ -37,6 +74,11 @@ export class Proxies extends APIResource { /** * Soft delete a proxy. Sessions referencing it are not modified. + * + * @example + * ```ts + * await client.proxies.delete('id'); + * ``` */ delete(id: string, options?: RequestOptions): APIPromise { return this._client.delete(path`/proxies/${id}`, { @@ -52,6 +94,11 @@ export class Proxies extends APIResource { * 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. + * + * @example + * ```ts + * const response = await client.proxies.check('id'); + * ``` */ check( id: string, @@ -376,6 +423,162 @@ export namespace ProxyRetrieveResponse { } } +/** + * Configuration for routing traffic through a proxy. + */ +export interface ProxyUpdateResponse { + /** + * Proxy type to use. In terms of quality for avoiding bot-detection, from best to + * worst: `mobile` > `residential` > `isp` > `datacenter`. + */ + type: 'datacenter' | 'isp' | 'residential' | 'mobile' | 'custom'; + + id?: string; + + /** + * Hostnames that should bypass the parent proxy and connect directly. + */ + bypass_hosts?: Array; + + /** + * Configuration specific to the selected proxy `type`. + */ + config?: + | ProxyUpdateResponse.DatacenterProxyConfig + | ProxyUpdateResponse.IspProxyConfig + | ProxyUpdateResponse.ResidentialProxyConfig + | ProxyUpdateResponse.MobileProxyConfig + | ProxyUpdateResponse.CustomProxyConfig; + + /** + * IP address that the proxy uses when making requests. + */ + ip_address?: string; + + /** + * Timestamp of the last health check performed on this proxy. + */ + last_checked?: string; + + /** + * Readable name of the proxy. + */ + name?: string; + + /** + * Protocol to use for the proxy connection. + */ + protocol?: 'http' | 'https'; + + /** + * Current health status of the proxy. + */ + status?: 'available' | 'unavailable'; +} + +export namespace ProxyUpdateResponse { + /** + * Configuration for a datacenter proxy. + */ + export interface DatacenterProxyConfig { + /** + * ISO 3166 country code. Defaults to US if not provided. + */ + country?: string; + } + + /** + * Configuration for an ISP proxy. + */ + export interface IspProxyConfig { + /** + * ISO 3166 country code. Defaults to US if not provided. + */ + country?: string; + } + + /** + * Configuration for residential proxies. + */ + export interface ResidentialProxyConfig { + /** + * Autonomous system number. See https://bgp.potaroo.net/cidr/autnums.html + */ + asn?: string; + + /** + * City name (no spaces, e.g. `sanfrancisco`). If provided, `country` must also be + * provided. + */ + city?: string; + + /** + * ISO 3166 country code. + */ + country?: string; + + /** + * @deprecated Operating system of the residential device. + */ + os?: 'windows' | 'macos' | 'android'; + + /** + * Two-letter state code. + */ + state?: string; + + /** + * US ZIP code. + */ + zip?: string; + } + + /** + * Configuration for mobile proxies. + */ + export interface MobileProxyConfig { + /** + * Provider city alias. Mobile carrier routing can make observed geo vary. + */ + city?: string; + + /** + * ISO 3166 country code + */ + country?: string; + + /** + * US-only state code. Mobile carrier routing can make observed geo vary. + */ + state?: string; + } + + /** + * Configuration for a custom proxy (e.g., private proxy server). + */ + export interface CustomProxyConfig { + /** + * Proxy host address or IP. + */ + host: string; + + /** + * Proxy port. + */ + port: number; + + /** + * Whether the proxy has a password. + */ + has_password?: boolean; + + /** + * Username for proxy authentication. + */ + username?: string; + } +} + /** * Configuration for routing traffic through a proxy. */ @@ -824,6 +1027,14 @@ export namespace ProxyCreateParams { } } +export interface ProxyUpdateParams { + /** + * New proxy name. Proxy names are trimmed and length-checked only; duplicates are + * allowed because proxies are updated by ID, not by name. + */ + name: string; +} + export interface ProxyListParams extends OffsetPaginationParams { /** * Search proxies by name, host, IP address, or ID. @@ -853,10 +1064,12 @@ export declare namespace Proxies { export { type ProxyCreateResponse as ProxyCreateResponse, type ProxyRetrieveResponse as ProxyRetrieveResponse, + type ProxyUpdateResponse as ProxyUpdateResponse, type ProxyListResponse as ProxyListResponse, type ProxyCheckResponse as ProxyCheckResponse, type ProxyListResponsesOffsetPagination as ProxyListResponsesOffsetPagination, type ProxyCreateParams as ProxyCreateParams, + type ProxyUpdateParams as ProxyUpdateParams, type ProxyListParams as ProxyListParams, type ProxyCheckParams as ProxyCheckParams, }; diff --git a/tests/api-resources/profiles.test.ts b/tests/api-resources/profiles.test.ts index 0bbb5574..2cfe7ecc 100644 --- a/tests/api-resources/profiles.test.ts +++ b/tests/api-resources/profiles.test.ts @@ -32,6 +32,23 @@ describe('resource profiles', () => { expect(dataAndResponse.response).toBe(rawResponse); }); + // Mock server tests are disabled + test.skip('update: only required params', async () => { + const responsePromise = client.profiles.update('id_or_name', { name: 'my-renamed-profile' }); + const rawResponse = await responsePromise.asResponse(); + expect(rawResponse).toBeInstanceOf(Response); + const response = await responsePromise; + expect(response).not.toBeInstanceOf(Response); + const dataAndResponse = await responsePromise.withResponse(); + expect(dataAndResponse.data).toBe(response); + expect(dataAndResponse.response).toBe(rawResponse); + }); + + // Mock server tests are disabled + test.skip('update: required and optional params', async () => { + const response = await client.profiles.update('id_or_name', { name: 'my-renamed-profile' }); + }); + // Mock server tests are disabled test.skip('list', async () => { const responsePromise = client.profiles.list(); diff --git a/tests/api-resources/proxies.test.ts b/tests/api-resources/proxies.test.ts index e64b2747..00eff027 100644 --- a/tests/api-resources/proxies.test.ts +++ b/tests/api-resources/proxies.test.ts @@ -43,6 +43,23 @@ describe('resource proxies', () => { expect(dataAndResponse.response).toBe(rawResponse); }); + // Mock server tests are disabled + test.skip('update: only required params', async () => { + const responsePromise = client.proxies.update('id', { name: 'my-renamed-proxy' }); + const rawResponse = await responsePromise.asResponse(); + expect(rawResponse).toBeInstanceOf(Response); + const response = await responsePromise; + expect(response).not.toBeInstanceOf(Response); + const dataAndResponse = await responsePromise.withResponse(); + expect(dataAndResponse.data).toBe(response); + expect(dataAndResponse.response).toBe(rawResponse); + }); + + // Mock server tests are disabled + test.skip('update: required and optional params', async () => { + const response = await client.proxies.update('id', { name: 'my-renamed-proxy' }); + }); + // Mock server tests are disabled test.skip('list', async () => { const responsePromise = client.proxies.list(); From 670f7c32c4c63064198a53bab24117354a26832d Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 10 Jul 2026 14:19:19 +0000 Subject: [PATCH 3/4] feat: Document name uniqueness and query match semantics --- .stats.yml | 4 +-- src/resources/api-keys.ts | 5 ++-- src/resources/auth/connections.ts | 40 ++++++++++++++++++++------- src/resources/browser-pools.ts | 3 +- src/resources/credential-providers.ts | 3 +- src/resources/credentials.ts | 3 +- src/resources/extensions.ts | 3 +- src/resources/profiles.ts | 2 +- src/resources/proxies.ts | 3 +- 9 files changed, 46 insertions(+), 20 deletions(-) diff --git a/.stats.yml b/.stats.yml index 09109a9b..b058b75d 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 127 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel/kernel-bc33d13e669972493e9ab0da82a71999822dc049eb14b113f446753c917ffcdb.yml -openapi_spec_hash: 133a2e0d0cdc4023f98b3c2e589cf5d8 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel/kernel-6c7cbaefd8a84ec26a1677681f37041323290080dac3fd1a409bb7cd01dd2ae3.yml +openapi_spec_hash: 75085a25c8a5cdb5417f0dbfad0ed6b6 config_hash: 77ee715aa17061166f9a02b264a21b8d diff --git a/src/resources/api-keys.ts b/src/resources/api-keys.ts index a82e2c32..96b17f31 100644 --- a/src/resources/api-keys.ts +++ b/src/resources/api-keys.ts @@ -141,7 +141,8 @@ export interface APIKey { masked_key: string; /** - * API key name + * Label for the API key. API keys are not addressable by name; use the ID or key + * identifier for stable references. */ name: string; @@ -188,7 +189,7 @@ export interface CreatedAPIKey extends APIKey { export interface APIKeyCreateParams { /** - * API key name (1-255 characters) + * Label for the API key (1-255 characters). API keys are not addressable by name. */ name: string; diff --git a/src/resources/auth/connections.ts b/src/resources/auth/connections.ts index 67d067b7..9e5f8a49 100644 --- a/src/resources/auth/connections.ts +++ b/src/resources/auth/connections.ts @@ -729,7 +729,9 @@ export interface ManagedAuthCreateRequest { /** * Proxy selection. Provide either id or name. The proxy must be in the same - * project as the resource referencing it. + * project as the resource referencing it. When selecting by name, the name must + * match exactly one active proxy in the project. Ambiguous names return a 400; use + * id for stable references. */ proxy?: ManagedAuthCreateRequest.Proxy; @@ -778,7 +780,9 @@ export namespace ManagedAuthCreateRequest { /** * Proxy selection. Provide either id or name. The proxy must be in the same - * project as the resource referencing it. + * project as the resource referencing it. When selecting by name, the name must + * match exactly one active proxy in the project. Ambiguous names return a 400; use + * id for stable references. */ export interface Proxy { /** @@ -917,7 +921,9 @@ export interface ManagedAuthUpdateRequest { /** * Proxy selection. Provide either id or name. The proxy must be in the same - * project as the resource referencing it. + * project as the resource referencing it. When selecting by name, the name must + * match exactly one active proxy in the project. Ambiguous names return a 400; use + * id for stable references. */ proxy?: ManagedAuthUpdateRequest.Proxy; @@ -964,7 +970,9 @@ export namespace ManagedAuthUpdateRequest { /** * Proxy selection. Provide either id or name. The proxy must be in the same - * project as the resource referencing it. + * project as the resource referencing it. When selecting by name, the name must + * match exactly one active proxy in the project. Ambiguous names return a 400; use + * id for stable references. */ export interface Proxy { /** @@ -1320,7 +1328,9 @@ export interface ConnectionCreateParams { /** * Proxy selection. Provide either id or name. The proxy must be in the same - * project as the resource referencing it. + * project as the resource referencing it. When selecting by name, the name must + * match exactly one active proxy in the project. Ambiguous names return a 400; use + * id for stable references. */ proxy?: ConnectionCreateParams.Proxy; @@ -1369,7 +1379,9 @@ export namespace ConnectionCreateParams { /** * Proxy selection. Provide either id or name. The proxy must be in the same - * project as the resource referencing it. + * project as the resource referencing it. When selecting by name, the name must + * match exactly one active proxy in the project. Ambiguous names return a 400; use + * id for stable references. */ export interface Proxy { /** @@ -1430,7 +1442,9 @@ export interface ConnectionUpdateParams { /** * Proxy selection. Provide either id or name. The proxy must be in the same - * project as the resource referencing it. + * project as the resource referencing it. When selecting by name, the name must + * match exactly one active proxy in the project. Ambiguous names return a 400; use + * id for stable references. */ proxy?: ConnectionUpdateParams.Proxy; @@ -1477,7 +1491,9 @@ export namespace ConnectionUpdateParams { /** * Proxy selection. Provide either id or name. The proxy must be in the same - * project as the resource referencing it. + * project as the resource referencing it. When selecting by name, the name must + * match exactly one active proxy in the project. Ambiguous names return a 400; use + * id for stable references. */ export interface Proxy { /** @@ -1512,7 +1528,9 @@ export interface ConnectionListParams extends OffsetPaginationParams { export interface ConnectionLoginParams { /** * Proxy selection. Provide either id or name. The proxy must be in the same - * project as the resource referencing it. + * project as the resource referencing it. When selecting by name, the name must + * match exactly one active proxy in the project. Ambiguous names return a 400; use + * id for stable references. */ proxy?: ConnectionLoginParams.Proxy; @@ -1526,7 +1544,9 @@ export interface ConnectionLoginParams { export namespace ConnectionLoginParams { /** * Proxy selection. Provide either id or name. The proxy must be in the same - * project as the resource referencing it. + * project as the resource referencing it. When selecting by name, the name must + * match exactly one active proxy in the project. Ambiguous names return a 400; use + * id for stable references. */ export interface Proxy { /** diff --git a/src/resources/browser-pools.ts b/src/resources/browser-pools.ts index a810bc8f..0b0bc160 100644 --- a/src/resources/browser-pools.ts +++ b/src/resources/browser-pools.ts @@ -737,7 +737,8 @@ export namespace BrowserPoolUpdateParams { export interface BrowserPoolListParams extends OffsetPaginationParams { /** - * Search browser pools by name or ID. + * Case-insensitive substring match against browser pool name. IDs match by exact + * value. */ query?: string; } diff --git a/src/resources/credential-providers.ts b/src/resources/credential-providers.ts index 601cf269..d85d198e 100644 --- a/src/resources/credential-providers.ts +++ b/src/resources/credential-providers.ts @@ -346,7 +346,8 @@ export interface CredentialProviderUpdateParams { export interface CredentialProviderListParams extends OffsetPaginationParams { /** - * Search credential providers by name or ID. + * Case-insensitive substring match against credential provider name. IDs match by + * exact value. */ query?: string; } diff --git a/src/resources/credentials.ts b/src/resources/credentials.ts index 09aba3a2..da4992a1 100644 --- a/src/resources/credentials.ts +++ b/src/resources/credentials.ts @@ -326,7 +326,8 @@ export interface CredentialListParams extends OffsetPaginationParams { domain?: string; /** - * Search credentials by name, domain, or ID. + * Case-insensitive substring match against credential name or domain. IDs match by + * exact value. */ query?: string; } diff --git a/src/resources/extensions.ts b/src/resources/extensions.ts index 809c2a3e..e5d0dbd0 100644 --- a/src/resources/extensions.ts +++ b/src/resources/extensions.ts @@ -250,7 +250,8 @@ export interface ExtensionUploadResponse { export interface ExtensionListParams extends OffsetPaginationParams { /** - * Search extensions by name or ID. + * Case-insensitive substring match against extension name. IDs match by exact + * value. */ query?: string; } diff --git a/src/resources/profiles.ts b/src/resources/profiles.ts index 29708d84..8b50420c 100644 --- a/src/resources/profiles.ts +++ b/src/resources/profiles.ts @@ -139,7 +139,7 @@ export interface ProfileUpdateParams { export interface ProfileListParams extends OffsetPaginationParams { /** - * Search profiles by name or ID. + * Case-insensitive substring match against profile name or ID. */ query?: string; } diff --git a/src/resources/proxies.ts b/src/resources/proxies.ts index a9295fae..b3cbefbb 100644 --- a/src/resources/proxies.ts +++ b/src/resources/proxies.ts @@ -1037,7 +1037,8 @@ export interface ProxyUpdateParams { export interface ProxyListParams extends OffsetPaginationParams { /** - * Search proxies by name, host, IP address, or ID. + * Case-insensitive substring match against proxy name, host, or IP address. IDs + * match by exact value. */ query?: string; } From 13eaaf30ec57916857d8e19d40a2e3dba315711a Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 10 Jul 2026 14:19:48 +0000 Subject: [PATCH 4/4] release: 0.77.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 14 ++++++++++++++ package.json | 2 +- src/version.ts | 2 +- 4 files changed, 17 insertions(+), 3 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 5f3243d4..bec5fdbf 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.76.0" + ".": "0.77.0" } diff --git a/CHANGELOG.md b/CHANGELOG.md index a8b606f8..25338fab 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,19 @@ # Changelog +## 0.77.0 (2026-07-10) + +Full Changelog: [v0.76.0...v0.77.0](https://github.com/kernel/kernel-node-sdk/compare/v0.76.0...v0.77.0) + +### Features + +* Add name-only rename for profiles and proxies ([2fe4124](https://github.com/kernel/kernel-node-sdk/commit/2fe41244b7e184914c6858a9533132d65b4380ba)) +* Document name uniqueness and query match semantics ([670f7c3](https://github.com/kernel/kernel-node-sdk/commit/670f7c32c4c63064198a53bab24117354a26832d)) + + +### Documentation + +* **openapi:** describe unified concurrency limit, deprecate max_pooled_sessions (CUS-275) ([37d3e27](https://github.com/kernel/kernel-node-sdk/commit/37d3e277f98b068f23c5fc85e7b26269c254827c)) + ## 0.76.0 (2026-07-09) Full Changelog: [v0.75.0...v0.76.0](https://github.com/kernel/kernel-node-sdk/compare/v0.75.0...v0.76.0) diff --git a/package.json b/package.json index 7757d07a..6de27b6e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@onkernel/sdk", - "version": "0.76.0", + "version": "0.77.0", "description": "The official TypeScript library for the Kernel API", "author": "Kernel <>", "types": "dist/index.d.ts", diff --git a/src/version.ts b/src/version.ts index 2c80dbec..c5f6a2a4 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const VERSION = '0.76.0'; // x-release-please-version +export const VERSION = '0.77.0'; // x-release-please-version