Skip to main content
POST
/
profiles
Create Profile
const options = {
  method: 'POST',
  headers: {'X-Browser-Use-API-Key': '<api-key>', 'Content-Type': 'application/json'},
  body: JSON.stringify({name: '<string>', userId: '<string>'})
};

fetch('https://api.browser-use.com/api/v2/profiles', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z",
  "userId": "<string>",
  "name": "<string>",
  "lastUsedAt": "2023-11-07T05:31:56Z",
  "cookieDomains": [
    "<string>"
  ]
}

Authorizations

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

Body

application/json

Request model for creating a new profile.

name
string | null

Optional name for the profile

Maximum string length: 100
userId
string | null

Your internal user identifier for this profile. Use this to associate a profile with a user in your system.

Maximum string length: 255

Response

Successful Response

View model for representing a profile. A profile lets you preserve the login state between sessions.

We recommend that you create a separate profile for each user of your app. You can assign a user_id to each profile to easily identify which user the profile belongs to.

id
string<uuid>
required

Unique identifier for the profile

createdAt
string<date-time>
required

Timestamp when the profile was created

updatedAt
string<date-time>
required

Timestamp when the profile was last updated

userId
string | null

Your internal user identifier for this profile. Use this to associate a profile with a user in your system.

name
string | null

Optional name for the profile

lastUsedAt
string<date-time> | null

Timestamp when the profile was last used

List of domain URLs that have cookies stored for this profile