diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 954743f..2e534d6 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.79.0" + ".": "0.80.0" } diff --git a/.stats.yml b/.stats.yml index 3807b2f..9e32666 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-e04362b2c82b88f4f7fb43209c764fa9fdf37fe98932e142547be43a1e99c50b.yml -openapi_spec_hash: b16e79bfd6cac36090c815a8184b9e09 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel/kernel-5b9eb5cdadbc7a5f404f5c2cec40f726e5fece54bf8e2dd29ab5c7700eb44f0e.yml +openapi_spec_hash: 63dd0798a4c0ed6477af50fff397f5dc config_hash: 77ee715aa17061166f9a02b264a21b8d diff --git a/CHANGELOG.md b/CHANGELOG.md index 318f1e3..66a5802 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,14 @@ # Changelog +## 0.80.0 (2026-07-17) + +Full Changelog: [v0.79.0...v0.80.0](https://github.com/kernel/kernel-node-sdk/compare/v0.79.0...v0.80.0) + +### Features + +* Add example to ProxyCheckRequest.url so API reference sample shows it ([bd1c0ca](https://github.com/kernel/kernel-node-sdk/commit/bd1c0ca24864a06051c2deb0ef97d46a5d822caa)) +* **managed-auth:** add TS CUA worker contract (KERNEL-1456) ([0a5405f](https://github.com/kernel/kernel-node-sdk/commit/0a5405f257c7fd6138f1a25adba598b672f30b06)) + ## 0.79.0 (2026-07-15) Full Changelog: [v0.78.1...v0.79.0](https://github.com/kernel/kernel-node-sdk/compare/v0.78.1...v0.79.0) diff --git a/package.json b/package.json index 7cb0200..ef5dd88 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@onkernel/sdk", - "version": "0.79.0", + "version": "0.80.0", "description": "The official TypeScript library for the Kernel API", "author": "Kernel <>", "types": "dist/index.d.ts", diff --git a/src/resources/auth/connections.ts b/src/resources/auth/connections.ts index 9e5f8a4..b956717 100644 --- a/src/resources/auth/connections.ts +++ b/src/resources/auth/connections.ts @@ -352,6 +352,12 @@ export interface ManagedAuth { | 'requires_sms_code' | 'requires_email_code'; + /** + * Canonical choices awaiting selection. Prefer this over pending_sso_buttons, + * mfa_options, and sign_in_options when present. + */ + choices?: Array | null; + /** * Reference to credentials for the auth connection. Use one of: * @@ -383,6 +389,12 @@ export interface ManagedAuth { */ external_action_message?: string | null; + /** + * Canonical fields awaiting input. Prefer this over discovered_fields when + * present. + */ + fields?: Array | null; + /** * When the current flow expires (null when no flow in progress). A flow past this * timestamp is no longer valid and its `flow_status` will be `EXPIRED`. Clients @@ -503,6 +515,43 @@ export interface ManagedAuth { } export namespace ManagedAuth { + /** + * Canonical auth-flow choice awaiting user selection. + */ + export interface Choice { + /** + * Stable choice identifier for canonical submit. + */ + id: string; + + /** + * Human-readable choice label. + */ + label: string; + + /** + * Choice type. + */ + type: + | 'mfa_method' + | 'sso_provider' + | 'sign_in_method' + | 'auth_method' + | 'identifier_method' + | 'account' + | 'other'; + + /** + * Additional context for the choice. + */ + description?: string | null; + + /** + * Selector for the visible choice, when available. + */ + observed_selector?: string | null; + } + /** * Reference to credentials for the auth connection. Use one of: * @@ -579,6 +628,41 @@ export namespace ManagedAuth { required?: boolean; } + /** + * Canonical field awaiting user input. + */ + export interface Field { + /** + * Stable field identifier for canonical submit. + */ + id: string; + + /** + * Credential reference name to store the submitted value under. + */ + ref: string; + + /** + * Managed-auth field type. + */ + type: 'identifier' | 'password' | 'code' | 'totp_code' | 'totp_secret' | 'text'; + + /** + * Human-readable label shown to the user. + */ + label?: string; + + /** + * Selector for the visible field, when available. + */ + observed_selector?: string | null; + + /** + * Whether this field is required. + */ + required?: boolean; + } + /** * An MFA method option for verification */ @@ -989,10 +1073,17 @@ export namespace ManagedAuthUpdateRequest { /** * Request to submit field values, click an SSO button, select an MFA method, or - * select a sign-in option. Provide exactly one of fields, sso_button_selector, - * sso_provider, mfa_option_id, or sign_in_option_id. + * select a sign-in option. Prefer canonical selected_choice_id/field_values when + * the API returns fields/choices; legacy + * fields/sso_button_selector/sso_provider/mfa_option_id/sign_in_option_id remain + * supported during deprecation. */ export interface SubmitFieldsRequest { + /** + * Canonical map of field ID to submitted value. + */ + field_values?: { [key: string]: string }; + /** * Map of field name to value */ @@ -1003,6 +1094,11 @@ export interface SubmitFieldsRequest { */ mfa_option_id?: string; + /** + * Canonical choice ID selected by the user. + */ + selected_choice_id?: string; + /** * The sign-in option ID to select (when sign_in_options were returned) */ @@ -1064,6 +1160,12 @@ export namespace ConnectionFollowResponse { */ timestamp: string; + /** + * Canonical choices awaiting selection. Prefer this over pending_sso_buttons, + * mfa_options, and sign_in_options when present. + */ + choices?: Array; + /** * Fields awaiting input (present when flow_step=AWAITING_INPUT; may also be * present with AWAITING_EXTERNAL_ACTION as fallback actions). @@ -1086,6 +1188,12 @@ export namespace ConnectionFollowResponse { */ external_action_message?: string; + /** + * Canonical fields awaiting input. Prefer this over discovered_fields when + * present. + */ + fields?: Array; + /** * Type of the current flow. */ @@ -1133,6 +1241,43 @@ export namespace ConnectionFollowResponse { } export namespace ManagedAuthStateEvent { + /** + * Canonical auth-flow choice awaiting user selection. + */ + export interface Choice { + /** + * Stable choice identifier for canonical submit. + */ + id: string; + + /** + * Human-readable choice label. + */ + label: string; + + /** + * Choice type. + */ + type: + | 'mfa_method' + | 'sso_provider' + | 'sign_in_method' + | 'auth_method' + | 'identifier_method' + | 'account' + | 'other'; + + /** + * Additional context for the choice. + */ + description?: string | null; + + /** + * Selector for the visible choice, when available. + */ + observed_selector?: string | null; + } + /** * A discovered form field */ @@ -1180,6 +1325,41 @@ export namespace ConnectionFollowResponse { required?: boolean; } + /** + * Canonical field awaiting user input. + */ + export interface Field { + /** + * Stable field identifier for canonical submit. + */ + id: string; + + /** + * Credential reference name to store the submitted value under. + */ + ref: string; + + /** + * Managed-auth field type. + */ + type: 'identifier' | 'password' | 'code' | 'totp_code' | 'totp_secret' | 'text'; + + /** + * Human-readable label shown to the user. + */ + label?: string; + + /** + * Selector for the visible field, when available. + */ + observed_selector?: string | null; + + /** + * Whether this field is required. + */ + required?: boolean; + } + /** * An MFA method option for verification */ @@ -1562,6 +1742,11 @@ export namespace ConnectionLoginParams { } export interface ConnectionSubmitParams { + /** + * Canonical map of field ID to submitted value. + */ + field_values?: { [key: string]: string }; + /** * Map of field name to value */ @@ -1572,6 +1757,11 @@ export interface ConnectionSubmitParams { */ mfa_option_id?: string; + /** + * Canonical choice ID selected by the user. + */ + selected_choice_id?: string; + /** * The sign-in option ID to select (when sign_in_options were returned) */ diff --git a/src/version.ts b/src/version.ts index 68f919f..bc177f4 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const VERSION = '0.79.0'; // x-release-please-version +export const VERSION = '0.80.0'; // x-release-please-version diff --git a/tests/api-resources/proxies.test.ts b/tests/api-resources/proxies.test.ts index 800ba2c..ddac608 100644 --- a/tests/api-resources/proxies.test.ts +++ b/tests/api-resources/proxies.test.ts @@ -116,7 +116,7 @@ describe('resource proxies', () => { 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' }), + client.proxies.check('id', { url: 'https://example.com' }, { path: '/_stainless_unknown_path' }), ).rejects.toThrow(Kernel.NotFoundError); }); });