POST
/
sessions
/
{session_id}
/
public-share
JavaScript
import BrowserUse from 'browser-use-sdk';

const client = new BrowserUse({
  apiKey: 'My API Key',
});

const shareView = await client.sessions.publicShare.create('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');

console.log(shareView.shareToken);
{
  "shareToken": "<string>",
  "shareUrl": "<string>",
  "viewCount": 123,
  "lastViewedAt": "2023-11-07T05:31:56Z"
}

Authorizations

X-Browser-Use-API-Key
string
header
required

Path Parameters

session_id
string<uuid>
required

Response

201
application/json

Successful Response

View model for representing a public share of a session.

Attributes: share_token: Token to access the public share. share_url: URL to access the public share. view_count: Number of times the public share has been viewed. last_viewed_at: Timestamp of the last time the public share was viewed (None if never viewed).