Skip to content

Commit 90cb376

Browse files
authored
Merge pull request #117 from kernel/release-please--branches--main--changes--next
release: 0.67.0
2 parents ea6b94d + 516dcec commit 90cb376

19 files changed

Lines changed: 86 additions & 56 deletions

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "0.66.0"
2+
".": "0.67.0"
33
}

.stats.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 119
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel/kernel-e66c3f8aedccc39104386a3ec619f3fdcef7e8b00d9e5aa82e414a1b387351c2.yml
3-
openapi_spec_hash: afeddf18ebc3da1521b3e6f6739411fa
4-
config_hash: 80eef1b592110714ea55cd26c470fabb
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel/kernel-51549f813f3002e18c6ca8d850cc0c7932828d511c151e0412c73b6798d19e30.yml
3+
openapi_spec_hash: ee77b293c4bda91c1a32cfdd12b8739e
4+
config_hash: 57567e00b41af47cef1b78e51b747aa0

CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,18 @@
11
# Changelog
22

3+
## 0.67.0 (2026-06-11)
4+
5+
Full Changelog: [v0.66.0...v0.67.0](https://github.com/kernel/kernel-python-sdk/compare/v0.66.0...v0.67.0)
6+
7+
### Features
8+
9+
* Add project_id SDK client option mapped to X-Kernel-Project-Id ([1799732](https://github.com/kernel/kernel-python-sdk/commit/17997322232374c6c49d99333b564a0537f247c0))
10+
11+
12+
### Documentation
13+
14+
* **api:** correct project-scoping descriptions in OpenAPI spec ([5929332](https://github.com/kernel/kernel-python-sdk/commit/592933283ff7bf0e6596ddbfbc4851e285a1d36e))
15+
316
## 0.66.0 (2026-06-10)
417

518
Full Changelog: [v0.65.0...v0.66.0](https://github.com/kernel/kernel-python-sdk/compare/v0.65.0...v0.66.0)

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "kernel"
3-
version = "0.66.0"
3+
version = "0.67.0"
44
description = "The official Python library for the kernel API"
55
dynamic = ["readme"]
66
license = "Apache-2.0"

src/kernel/_client.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,13 +100,16 @@ class Kernel(SyncAPIClient):
100100
api_key: str
101101
browser_route_cache: BrowserRouteCache
102102

103+
project_id: str | None
104+
103105
_environment: Literal["production", "development"] | NotGiven
104106
_browser_routing: BrowserRoutingConfig
105107

106108
def __init__(
107109
self,
108110
*,
109111
api_key: str | None = None,
112+
project_id: str | None = None,
110113
environment: Literal["production", "development"] | NotGiven = not_given,
111114
base_url: str | httpx.URL | None | NotGiven = not_given,
112115
timeout: float | Timeout | None | NotGiven = not_given,
@@ -140,6 +143,8 @@ def __init__(
140143
)
141144
self.api_key = api_key
142145

146+
self.project_id = project_id
147+
143148
self._environment = environment
144149

145150
base_url_env = os.environ.get("KERNEL_BASE_URL")
@@ -309,6 +314,7 @@ def default_headers(self) -> dict[str, str | Omit]:
309314
return {
310315
**super().default_headers,
311316
"X-Stainless-Async": "false",
317+
"X-Kernel-Project-Id": self.project_id if self.project_id is not None else Omit(),
312318
**self._custom_headers,
313319
}
314320

@@ -347,6 +353,7 @@ def copy(
347353
self,
348354
*,
349355
api_key: str | None = None,
356+
project_id: str | None = None,
350357
environment: Literal["production", "development"] | None = None,
351358
base_url: str | httpx.URL | None = None,
352359
timeout: float | Timeout | None | NotGiven = not_given,
@@ -383,6 +390,7 @@ def copy(
383390
http_client = http_client or self._client
384391
return self.__class__(
385392
api_key=api_key or self.api_key,
393+
project_id=project_id or self.project_id,
386394
base_url=base_url or self.base_url,
387395
environment=environment or self._environment,
388396
timeout=self.timeout if isinstance(timeout, NotGiven) else timeout,
@@ -437,13 +445,16 @@ class AsyncKernel(AsyncAPIClient):
437445
api_key: str
438446
browser_route_cache: BrowserRouteCache
439447

448+
project_id: str | None
449+
440450
_environment: Literal["production", "development"] | NotGiven
441451
_browser_routing: BrowserRoutingConfig
442452

443453
def __init__(
444454
self,
445455
*,
446456
api_key: str | None = None,
457+
project_id: str | None = None,
447458
environment: Literal["production", "development"] | NotGiven = not_given,
448459
base_url: str | httpx.URL | None | NotGiven = not_given,
449460
timeout: float | Timeout | None | NotGiven = not_given,
@@ -477,6 +488,8 @@ def __init__(
477488
)
478489
self.api_key = api_key
479490

491+
self.project_id = project_id
492+
480493
self._environment = environment
481494

482495
base_url_env = os.environ.get("KERNEL_BASE_URL")
@@ -646,6 +659,7 @@ def default_headers(self) -> dict[str, str | Omit]:
646659
return {
647660
**super().default_headers,
648661
"X-Stainless-Async": f"async:{get_async_library()}",
662+
"X-Kernel-Project-Id": self.project_id if self.project_id is not None else Omit(),
649663
**self._custom_headers,
650664
}
651665

@@ -684,6 +698,7 @@ def copy(
684698
self,
685699
*,
686700
api_key: str | None = None,
701+
project_id: str | None = None,
687702
environment: Literal["production", "development"] | None = None,
688703
base_url: str | httpx.URL | None = None,
689704
timeout: float | Timeout | None | NotGiven = not_given,
@@ -720,6 +735,7 @@ def copy(
720735
http_client = http_client or self._client
721736
return self.__class__(
722737
api_key=api_key or self.api_key,
738+
project_id=project_id or self.project_id,
723739
base_url=base_url or self.base_url,
724740
environment=environment or self._environment,
725741
timeout=self.timeout if isinstance(timeout, NotGiven) else timeout,

src/kernel/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

33
__title__ = "kernel"
4-
__version__ = "0.66.0" # x-release-please-version
4+
__version__ = "0.67.0" # x-release-please-version

src/kernel/resources/auth/connections.py

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,8 @@ def create(
136136
137137
login_url: Optional login page URL to skip discovery
138138
139-
proxy: Proxy selection. Provide either id or name. The proxy must belong to the
140-
caller's org.
139+
proxy: Proxy selection. Provide either id or name. The proxy must be in the same
140+
project as the resource referencing it.
141141
142142
record_session: Whether to record browser sessions for this connection by default. Useful for
143143
debugging. Can be overridden per-login. Defaults to false.
@@ -264,8 +264,8 @@ def update(
264264
265265
login_url: Login page URL. Set to empty string to clear.
266266
267-
proxy: Proxy selection. Provide either id or name. The proxy must belong to the
268-
caller's org.
267+
proxy: Proxy selection. Provide either id or name. The proxy must be in the same
268+
project as the resource referencing it.
269269
270270
record_session: Whether to record browser sessions for this connection by default
271271
@@ -457,8 +457,8 @@ def login(
457457
credentials are stored.
458458
459459
Args:
460-
proxy: Proxy selection. Provide either id or name. The proxy must belong to the
461-
caller's org.
460+
proxy: Proxy selection. Provide either id or name. The proxy must be in the same
461+
project as the resource referencing it.
462462
463463
record_session: Override the connection's default for recording this login's browser session.
464464
When omitted, the connection's record_session default is used.
@@ -653,8 +653,8 @@ async def create(
653653
654654
login_url: Optional login page URL to skip discovery
655655
656-
proxy: Proxy selection. Provide either id or name. The proxy must belong to the
657-
caller's org.
656+
proxy: Proxy selection. Provide either id or name. The proxy must be in the same
657+
project as the resource referencing it.
658658
659659
record_session: Whether to record browser sessions for this connection by default. Useful for
660660
debugging. Can be overridden per-login. Defaults to false.
@@ -781,8 +781,8 @@ async def update(
781781
782782
login_url: Login page URL. Set to empty string to clear.
783783
784-
proxy: Proxy selection. Provide either id or name. The proxy must belong to the
785-
caller's org.
784+
proxy: Proxy selection. Provide either id or name. The proxy must be in the same
785+
project as the resource referencing it.
786786
787787
record_session: Whether to record browser sessions for this connection by default
788788
@@ -974,8 +974,8 @@ async def login(
974974
credentials are stored.
975975
976976
Args:
977-
proxy: Proxy selection. Provide either id or name. The proxy must belong to the
978-
caller's org.
977+
proxy: Proxy selection. Provide either id or name. The proxy must be in the same
978+
project as the resource referencing it.
979979
980980
record_session: Override the connection's default for recording this login's browser session.
981981
When omitted, the connection's record_session default is used.

src/kernel/resources/browser_pools.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -109,8 +109,8 @@ def create(
109109
specified, the matching profile will be loaded into the browser session.
110110
Profiles must be created beforehand.
111111
112-
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy
113-
belonging to the caller's org.
112+
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy in
113+
the same project as the browser session.
114114
115115
start_url: Optional URL to navigate to when a new browser is warmed into the pool.
116116
Best-effort: failures to navigate do not fail pool fill. Only applied to
@@ -256,8 +256,8 @@ def update(
256256
specified, the matching profile will be loaded into the browser session.
257257
Profiles must be created beforehand.
258258
259-
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy
260-
belonging to the caller's org.
259+
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy in
260+
the same project as the browser session.
261261
262262
size: Number of browsers to maintain in the pool. The maximum size is determined by
263263
your organization's pooled sessions limit (the sum of all pool sizes cannot
@@ -338,7 +338,7 @@ def list(
338338
timeout: float | httpx.Timeout | None | NotGiven = not_given,
339339
) -> SyncOffsetPagination[BrowserPool]:
340340
"""
341-
List browser pools owned by the caller's organization.
341+
List browser pools in the resolved project.
342342
343343
Args:
344344
limit: Limit the number of browser pools to return.
@@ -630,8 +630,8 @@ async def create(
630630
specified, the matching profile will be loaded into the browser session.
631631
Profiles must be created beforehand.
632632
633-
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy
634-
belonging to the caller's org.
633+
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy in
634+
the same project as the browser session.
635635
636636
start_url: Optional URL to navigate to when a new browser is warmed into the pool.
637637
Best-effort: failures to navigate do not fail pool fill. Only applied to
@@ -777,8 +777,8 @@ async def update(
777777
specified, the matching profile will be loaded into the browser session.
778778
Profiles must be created beforehand.
779779
780-
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy
781-
belonging to the caller's org.
780+
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy in
781+
the same project as the browser session.
782782
783783
size: Number of browsers to maintain in the pool. The maximum size is determined by
784784
your organization's pooled sessions limit (the sum of all pool sizes cannot
@@ -859,7 +859,7 @@ def list(
859859
timeout: float | httpx.Timeout | None | NotGiven = not_given,
860860
) -> AsyncPaginator[BrowserPool, AsyncOffsetPagination[BrowserPool]]:
861861
"""
862-
List browser pools owned by the caller's organization.
862+
List browser pools in the resolved project.
863863
864864
Args:
865865
limit: Limit the number of browser pools to return.

src/kernel/resources/browsers/browsers.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -216,8 +216,8 @@ def create(
216216
specified, the matching profile will be loaded into the browser session.
217217
Profiles must be created beforehand.
218218
219-
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy
220-
belonging to the caller's org.
219+
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy in
220+
the same project as the browser session.
221221
222222
start_url: Optional URL to open when the browser session is created. Navigation is
223223
best-effort, so navigation failures do not prevent the session from being
@@ -794,8 +794,8 @@ async def create(
794794
specified, the matching profile will be loaded into the browser session.
795795
Profiles must be created beforehand.
796796
797-
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy
798-
belonging to the caller's org.
797+
proxy_id: Optional proxy to associate to the browser session. Must reference a proxy in
798+
the same project as the browser session.
799799
800800
start_url: Optional URL to open when the browser session is created. Navigation is
801801
best-effort, so navigation failures do not prevent the session from being

src/kernel/resources/credentials.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -212,10 +212,9 @@ def list(
212212
extra_body: Body | None = None,
213213
timeout: float | httpx.Timeout | None | NotGiven = not_given,
214214
) -> SyncOffsetPagination[Credential]:
215-
"""List credentials owned by the caller's organization.
215+
"""List credentials in the resolved project.
216216
217-
Credential values are not
218-
returned.
217+
Credential values are not returned.
219218
220219
Args:
221220
domain: Filter by domain
@@ -509,10 +508,9 @@ def list(
509508
extra_body: Body | None = None,
510509
timeout: float | httpx.Timeout | None | NotGiven = not_given,
511510
) -> AsyncPaginator[Credential, AsyncOffsetPagination[Credential]]:
512-
"""List credentials owned by the caller's organization.
511+
"""List credentials in the resolved project.
513512
514-
Credential values are not
515-
returned.
513+
Credential values are not returned.
516514
517515
Args:
518516
domain: Filter by domain

0 commit comments

Comments
 (0)