Skip to content

Commit 7ea4b07

Browse files
feat: Enhance agent authentication with optional login page URL and auth ch…
1 parent 7c8a464 commit 7ea4b07

File tree

13 files changed

+686
-4
lines changed

13 files changed

+686
-4
lines changed

.stats.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
configured_endpoints: 74
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel%2Fkernel-3a68acd8c46e121c66be5b4c30bb4e962967840ca0f31070905baa39635fbc2d.yml
3-
openapi_spec_hash: 9453963fbb01de3e0afb462b16cdf115
4-
config_hash: 6dbe88d2ba9df1ec46cedbfdb7d00000
1+
configured_endpoints: 80
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel%2Fkernel-8a37652fa586b8932466d16285359a89988505f850787f8257d0c4c7053da173.yml
3+
openapi_spec_hash: 042765a113f6d08109e8146b302323ec
4+
config_hash: 113f1e5bc3567628a5d51c70bc00969d

api.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,3 +246,34 @@ Methods:
246246
- <code title="post /browser_pools/{id_or_name}/acquire">client.browserPools.<a href="./src/resources/browser-pools.ts">acquire</a>(idOrName, { ...params }) -> BrowserPoolAcquireResponse</code>
247247
- <code title="post /browser_pools/{id_or_name}/flush">client.browserPools.<a href="./src/resources/browser-pools.ts">flush</a>(idOrName) -> void</code>
248248
- <code title="post /browser_pools/{id_or_name}/release">client.browserPools.<a href="./src/resources/browser-pools.ts">release</a>(idOrName, { ...params }) -> void</code>
249+
250+
# Agents
251+
252+
## Auth
253+
254+
Types:
255+
256+
- <code><a href="./src/resources/agents/auth/auth.ts">AgentAuthDiscoverResponse</a></code>
257+
- <code><a href="./src/resources/agents/auth/auth.ts">AgentAuthInvocationResponse</a></code>
258+
- <code><a href="./src/resources/agents/auth/auth.ts">AgentAuthStartResponse</a></code>
259+
- <code><a href="./src/resources/agents/auth/auth.ts">AgentAuthSubmitResponse</a></code>
260+
- <code><a href="./src/resources/agents/auth/auth.ts">AuthAgent</a></code>
261+
- <code><a href="./src/resources/agents/auth/auth.ts">DiscoveredField</a></code>
262+
263+
Methods:
264+
265+
- <code title="get /agents/auth/{id}">client.agents.auth.<a href="./src/resources/agents/auth/auth.ts">retrieve</a>(id) -> AuthAgent</code>
266+
- <code title="post /agents/auth/start">client.agents.auth.<a href="./src/resources/agents/auth/auth.ts">start</a>({ ...params }) -> AgentAuthStartResponse</code>
267+
268+
### Invocations
269+
270+
Types:
271+
272+
- <code><a href="./src/resources/agents/auth/invocations.ts">InvocationExchangeResponse</a></code>
273+
274+
Methods:
275+
276+
- <code title="get /agents/auth/invocations/{invocation_id}">client.agents.auth.invocations.<a href="./src/resources/agents/auth/invocations.ts">retrieve</a>(invocationID) -> AgentAuthInvocationResponse</code>
277+
- <code title="post /agents/auth/invocations/{invocation_id}/discover">client.agents.auth.invocations.<a href="./src/resources/agents/auth/invocations.ts">discover</a>(invocationID, { ...params }) -> AgentAuthDiscoverResponse</code>
278+
- <code title="post /agents/auth/invocations/{invocation_id}/exchange">client.agents.auth.invocations.<a href="./src/resources/agents/auth/invocations.ts">exchange</a>(invocationID, { ...params }) -> InvocationExchangeResponse</code>
279+
- <code title="post /agents/auth/invocations/{invocation_id}/submit">client.agents.auth.invocations.<a href="./src/resources/agents/auth/invocations.ts">submit</a>(invocationID, { ...params }) -> AgentAuthSubmitResponse</code>

src/client.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ import {
7676
ProxyListResponse,
7777
ProxyRetrieveResponse,
7878
} from './resources/proxies';
79+
import { Agents } from './resources/agents/agents';
7980
import {
8081
BrowserCreateParams,
8182
BrowserCreateResponse,
@@ -859,6 +860,7 @@ export class Kernel {
859860
proxies: API.Proxies = new API.Proxies(this);
860861
extensions: API.Extensions = new API.Extensions(this);
861862
browserPools: API.BrowserPools = new API.BrowserPools(this);
863+
agents: API.Agents = new API.Agents(this);
862864
}
863865

864866
Kernel.Deployments = Deployments;
@@ -869,6 +871,7 @@ Kernel.Profiles = Profiles;
869871
Kernel.Proxies = Proxies;
870872
Kernel.Extensions = Extensions;
871873
Kernel.BrowserPools = BrowserPools;
874+
Kernel.Agents = Agents;
872875

873876
export declare namespace Kernel {
874877
export type RequestOptions = Opts.RequestOptions;
@@ -966,6 +969,8 @@ export declare namespace Kernel {
966969
type BrowserPoolReleaseParams as BrowserPoolReleaseParams,
967970
};
968971

972+
export { Agents as Agents };
973+
969974
export type AppAction = API.AppAction;
970975
export type BrowserExtension = API.BrowserExtension;
971976
export type BrowserProfile = API.BrowserProfile;

src/resources/agents.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
export * from './agents/index';

src/resources/agents/agents.ts

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
import { APIResource } from '../../core/resource';
4+
import * as AuthAPI from './auth/auth';
5+
import {
6+
AgentAuthDiscoverResponse,
7+
AgentAuthInvocationResponse,
8+
AgentAuthStartResponse,
9+
AgentAuthSubmitResponse,
10+
Auth,
11+
AuthAgent,
12+
AuthStartParams,
13+
DiscoveredField,
14+
} from './auth/auth';
15+
16+
export class Agents extends APIResource {
17+
auth: AuthAPI.Auth = new AuthAPI.Auth(this._client);
18+
}
19+
20+
Agents.Auth = Auth;
21+
22+
export declare namespace Agents {
23+
export {
24+
Auth as Auth,
25+
type AgentAuthDiscoverResponse as AgentAuthDiscoverResponse,
26+
type AgentAuthInvocationResponse as AgentAuthInvocationResponse,
27+
type AgentAuthStartResponse as AgentAuthStartResponse,
28+
type AgentAuthSubmitResponse as AgentAuthSubmitResponse,
29+
type AuthAgent as AuthAgent,
30+
type DiscoveredField as DiscoveredField,
31+
type AuthStartParams as AuthStartParams,
32+
};
33+
}

src/resources/agents/auth.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
export * from './auth/index';

0 commit comments

Comments
 (0)