You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 5f05cd2
Browse filesBrowse the repository at this point in the historyBrowse files
/** ISO 8601 timestamp when the browser session expires. Omitted when the provider doesn't expose it. */
35
39
sessionExpiresAt?: string;
40
+
/**
41
+
* Ends the session. Equivalent to calling {@linkcode BrowserModule.endSession | endSession()} with this session's ID.
42
+
*/
43
+
end: ()=>Promise<void>;
36
44
}
37
45
38
46
/**
39
47
* Browser module for running browser automation from your backend.
40
48
*
41
-
* This module creates remote browser sessions that you can control with a CDP client library such as Playwright or Puppeteer. Base44 doesn't store browser state, so each session is independent.
49
+
* This module creates remote browser sessions that you can control with a CDP client library such as Playwright or Puppeteer. Base44 doesn't store browser state, so each session is independent. End each session when you're done with it. Otherwise it keeps running until the remote browser provider times it out.
42
50
*
43
51
* This module is only available to use with a client in service role authentication mode, which means it can only be used in backend environments.
* Use this when the session was created in a different request. Otherwise call `end()` on the session returned by {@linkcode getSession | getSession()}. Ending a session that has already ended succeeds, so it's safe to call more than once. The call fails with the `browser_session_not_found` error code if the ID wasn't issued to your app.
100
+
*
101
+
* @param sessionId - The `sessionId` returned by {@linkcode getSession | getSession()}, unchanged.
102
+
* @returns Promise that resolves when the session has ended.
103
+
*
104
+
* @example
105
+
* ```typescript
106
+
* // End a session whose ID was saved by an earlier request
107
+
* import { createClientFromRequest } from 'npm:@base44/sdk';
0 commit comments