The browser ID is a universally unique identifier (UUID) that Sitecore CDP assigns to every user of your application. It associates sessions, events, and orders with the respective user.

To generate browser id at server side in this case using postman use following URL-

https://{{apiEndpoint}}/{{apiVersion}}/browser/create.json?client_key={{CLIENT_KEY}}&message={}

API Endpoint

{{apiEndpoint}} – API target endpoint depends on the region client key is available in. Following are the regions and url available at the point of writing this blog and as per this document

Europe – https://api.boxever.com

Asia Pacific – https://api-ap-southeast-2-production.boxever.com

United States – https://api-us.boxever.com

See here for more details on the Sitecore CDP Rest API

API Version

API Version is v1.2

Client Key

See here for more details on How to get Client Key and API Token

Get the client key from the Sandbox/CDP & Personalise portal.

Login to portal – https://app.boxever.com/#/

Top right click the clog icon. Select API Access option

Get teh client key from this page-

Request/Response-

Status- OK. The request was served successfuly

Anantmous(Guest) should be created. Browser ID is in “ref” field in the response

Check the guest details in portal with the Browser ID-

Goto the Guests page –

Search guests with browser id. (bid: <<browser id>>)

This should the Guest Type as Visitor which means its Anonymous and not yet known or uniquely identified.

CURL code snippet-

curl --location -g --request GET 'https://api.boxever.com/v1.2/browser/create.json?client_key=<<client key>>&message={}'

C# code snippet-

var client = new RestClient("https://api.boxever.com/v1.2/browser/create.json?client_key=<<client key>>&message={}");
client.Timeout = -1;
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);

Python code snippet-

import http.client

conn = http.client.HTTPSConnection("api.boxever.com")
payload = ''
headers = {}
conn.request("GET", "/v1.2/browser/create.json?client_key=<<code key>>&message=%7B%7D", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))

References

Preparing to integrate with Sitecore CDP

Understanding integration details

Loading