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.110.0"
".": "0.111.0"
}
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

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


### Features

* Publish restricted_route_unavailable and unknown proxy_error codes ([64805ae](https://github.com/kernel/kernel-python-sdk/commit/64805ae68f0978264fb77801e8e94a470a039e94))
* Support native prepared Adyen Sessions checkout ([5f2df0a](https://github.com/kernel/kernel-python-sdk/commit/5f2df0a4170aa146eabb23f576195d1a06621925))

## [0.110.0](https://github.com/kernel/kernel-python-sdk/compare/v0.109.0...v0.110.0) (2026-09-18)


Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "kernel"
version = "0.110.0"
version = "0.111.0"
description = "The official Python library for the kernel API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion src/kernel/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "kernel"
__version__ = "0.110.0" # x-release-please-version
__version__ = "0.111.0" # x-release-please-version
4 changes: 2 additions & 2 deletions src/kernel/resources/vaults/items.py
Original file line number Diff line number Diff line change
Expand Up @@ -517,7 +517,7 @@ def perform_operation(
leave the outcome unknown; do not automatically retry.

Args:
checkout: Required when preparing an unused AgentCard card for a supported tokenization
checkout: Required when preparing an unused AgentCard card for a supported checkout
processor. Consent is bound to this browser and declared merchant origin, not a
tab. Wait for the item's ready_to_submit status before native Pay and submit
within its readiness deadline. Unused preparations expire automatically; every
Expand Down Expand Up @@ -1290,7 +1290,7 @@ async def perform_operation(
leave the outcome unknown; do not automatically retry.

Args:
checkout: Required when preparing an unused AgentCard card for a supported tokenization
checkout: Required when preparing an unused AgentCard card for a supported checkout
processor. Consent is bound to this browser and declared merchant origin, not a
tab. Wait for the item's ready_to_submit status before native Pay and submit
within its readiness deadline. Unused preparations expire automatically; every
Expand Down
19 changes: 16 additions & 3 deletions src/kernel/types/browsers/browser_proxy_error_event.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,23 @@ class Data(BrowserEventContext):
"provider_unreachable",
"provider_rejected",
"origin_tls_timeout",
"origin_response_incomplete",
"proxy_unavailable",
"restricted_route_unavailable",
"upstream_timeout",
"upstream_dns_failure",
"upstream_connect_failed",
"unknown",
]
"""
Proxy-layer error code: the X-Kernel-Proxy-Error response header value from a
branded 5xx error page served by the metro egress host-proxy. Values mirror what
the proxy emits: destination_blocked, provider_blacklisted,
provider_unreachable, provider_rejected, origin_tls_timeout, proxy_unavailable,
upstream_timeout, upstream_dns_failure, upstream_connect_failed. Unknown header
values are dropped.
provider_unreachable, provider_rejected, origin_tls_timeout,
origin_response_incomplete, proxy_unavailable, restricted_route_unavailable,
upstream_timeout, upstream_dns_failure, upstream_connect_failed. A header value
the browser image does not recognize is reported as unknown, with the header
value in raw_code.
"""

request_id: str
Expand All @@ -45,6 +50,14 @@ class Data(BrowserEventContext):
method: Optional[str] = None
"""HTTP method of the failed request, when known."""

raw_code: Optional[str] = None
"""Sanitized X-Kernel-Proxy-Error header value, present only when code is unknown.

Surrounding whitespace is removed, the value is lowercased, characters outside
[a-z0-9_] are replaced with \\__, and the result is truncated to at most 64
characters.
"""

resource_type: Optional[str] = None
"""CDP Network.ResourceType for the request, when known."""

Expand Down
2 changes: 1 addition & 1 deletion src/kernel/types/vaults/agentcard_checkout_preparation.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
class AgentcardCheckoutPreparation(BaseModel):
"""One-use processor-bound checkout preparation.

Keep the approval page open through token handoff. The amount is display-only and does not constrain the merchant's eventual charge.
Keep the approval page open through device handoff, including Adyen encryption. The amount is declared by the caller and does not constrain the merchant's eventual charge. Adyen device approval and browser Authorised responses are not capture or fulfillment evidence.
"""

browser_id: str
Expand Down
2 changes: 1 addition & 1 deletion src/kernel/types/vaults/agentcard_prepared_processor.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@

__all__ = ["AgentcardPreparedProcessor"]

AgentcardPreparedProcessor: TypeAlias = Literal["square", "braintree", "worldpay", "bambora", "mercado_pago"]
AgentcardPreparedProcessor: TypeAlias = Literal["square", "braintree", "worldpay", "bambora", "mercado_pago", "adyen"]
6 changes: 4 additions & 2 deletions src/kernel/types/vaults/card_vault_item_state.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,10 @@ class AgentCardCardState(BaseModel):
preparation: Optional[AgentcardCheckoutPreparation] = None
"""One-use processor-bound checkout preparation.

Keep the approval page open through token handoff. The amount is display-only
and does not constrain the merchant's eventual charge.
Keep the approval page open through device handoff, including Adyen encryption.
The amount is declared by the caller and does not constrain the merchant's
eventual charge. Adyen device approval and browser Authorised responses are not
capture or fulfillment evidence.
"""

status_reason: Optional[str] = None
Expand Down
2 changes: 1 addition & 1 deletion src/kernel/types/vaults/item_perform_operation_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class PrepareCheckoutVaultItemOperationRequest(TypedDict, total=False):

checkout: Required[VaultCheckoutContextParam]
"""
Required when preparing an unused AgentCard card for a supported tokenization
Required when preparing an unused AgentCard card for a supported checkout
processor. Consent is bound to this browser and declared merchant origin, not a
tab. Wait for the item's ready_to_submit status before native Pay and submit
within its readiness deadline. Unused preparations expire automatically; every
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@


class PrepareCheckoutVaultItemOperationRequestParam(TypedDict, total=False):
"""Prepare an unused AgentCard card for a supported tokenization checkout.
"""Prepare an unused AgentCard card for a supported checkout.

Deliver the returned approval URL and keep the approval page open. Poll the item until ready_to_submit, then submit native Pay before preparation.expires_at. Readiness lasts at most 30 seconds. Unused preparations expire automatically. Preparations are single-use even after failure or expiry; do not automatically retry and reconcile uncertain outcomes with the merchant.
"""

checkout: Required[VaultCheckoutContextParam]
"""
Required when preparing an unused AgentCard card for a supported tokenization
Required when preparing an unused AgentCard card for a supported checkout
processor. Consent is bound to this browser and declared merchant origin, not a
tab. Wait for the item's ready_to_submit status before native Pay and submit
within its readiness deadline. Unused preparations expire automatically; every
Expand Down
14 changes: 8 additions & 6 deletions src/kernel/types/vaults/vault_checkout_context_param.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,16 @@

class VaultCheckoutContextParam(TypedDict, total=False):
"""
Required when preparing an unused AgentCard card for a supported tokenization processor. Consent is bound to this browser and declared merchant origin, not a tab. Wait for the item's ready_to_submit status before native Pay and submit within its readiness deadline. Unused preparations expire automatically; every preparation is single-use, including after failure or expiry.
Required when preparing an unused AgentCard card for a supported checkout processor. Consent is bound to this browser and declared merchant origin, not a tab. Wait for the item's ready_to_submit status before native Pay and submit within its readiness deadline. Unused preparations expire automatically; every preparation is single-use, including after failure or expiry.
"""

browser_id: Required[str]
"""Active browser session with this vault bound to it."""

environment: Required[Literal["production", "sandbox", "shared"]]
"""
Use production or sandbox for Square, Braintree and Worldpay; shared for Bambora
and Mercado Pago. Shared endpoints do not establish test mode. Merchant
Use production or sandbox for Square, Braintree, Worldpay and Adyen; shared for
Bambora and Mercado Pago. Shared endpoints do not establish test mode. Merchant
credentials/configuration determine processor test mode, independently of the
AgentCard credential mode.
"""
Expand All @@ -32,8 +32,10 @@ class VaultCheckoutContextParam(TypedDict, total=False):
"""

psp: AgentcardPreparedProcessor
"""Tokenization processor.
"""Checkout processor.

Omit for Square compatibility. Non-Square processors require multi-processor
preparation enablement.
Omit for Square compatibility. Adyen supports fresh-card Sessions requests on
Adyen hosts only. Use public dummy card fields, not vault aliases. The unique
armed preparation is associated with the subsequent eligible request from this
browser and declared merchant origin; competing preparations are rejected.
"""
Loading