Skip to content

Commit 6ef46ba

Browse files
feat(api): api update (#127)
1 parent 3535bba commit 6ef46ba

File tree

3 files changed

+16
-8
lines changed

3 files changed

+16
-8
lines changed

.stats.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
configured_endpoints: 18
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/browserbase%2Fbrowserbase-f1ba1f2c1512973c1640f7e2d27c72c4f5c49ec07e70b026d52818e7f8b1468e.yml
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/browserbase%2Fbrowserbase-6a5cbe2f816042d594335d77f9600cd47cdb9c21d9d60971a2eca87983061c72.yml

src/resources/sessions/sessions.ts

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -113,9 +113,10 @@ export interface Session {
113113
memoryUsage?: number;
114114

115115
/**
116-
* Arbitrary user metadata to attach to the session.
116+
* Arbitrary user metadata to attach to the session. To learn more about user
117+
* metadata, see [User Metadata](/features/sessions#user-metadata).
117118
*/
118-
userMetadata?: unknown;
119+
userMetadata?: Record<string, unknown>;
119120
}
120121

121122
export interface SessionLiveURLs {
@@ -210,9 +211,10 @@ export interface SessionCreateResponse {
210211
memoryUsage?: number;
211212

212213
/**
213-
* Arbitrary user metadata to attach to the session.
214+
* Arbitrary user metadata to attach to the session. To learn more about user
215+
* metadata, see [User Metadata](/features/sessions#user-metadata).
214216
*/
215-
userMetadata?: unknown;
217+
userMetadata?: Record<string, unknown>;
216218
}
217219

218220
export type SessionListResponse = Array<Session>;
@@ -258,9 +260,10 @@ export interface SessionCreateParams {
258260
timeout?: number;
259261

260262
/**
261-
* Arbitrary user metadata to attach to the session.
263+
* Arbitrary user metadata to attach to the session. To learn more about user
264+
* metadata, see [User Metadata](/features/sessions#user-metadata).
262265
*/
263-
userMetadata?: unknown;
266+
userMetadata?: Record<string, unknown>;
264267
}
265268

266269
export namespace SessionCreateParams {
@@ -450,6 +453,11 @@ export interface SessionUpdateParams {
450453
}
451454

452455
export interface SessionListParams {
456+
/**
457+
* Query sessions by user metadata. See
458+
* [Querying Sessions by User Metadata](/features/sessions#querying-sessions-by-user-metadata)
459+
* for the schema of this query.
460+
*/
453461
q?: string;
454462

455463
status?: 'RUNNING' | 'ERROR' | 'TIMED_OUT' | 'COMPLETED';

tests/api-resources/sessions/sessions.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ describe('resource sessions', () => {
4646
proxies: true,
4747
region: 'us-west-2',
4848
timeout: 60,
49-
userMetadata: {},
49+
userMetadata: { foo: 'bar' },
5050
});
5151
});
5252

0 commit comments

Comments
 (0)