Identify your devices
To help you identify, search, and filter devices in your Cobrowse dashboard, it's helpful to specify any meaningful metadata.
You may add any custom key/value pairs you'd like, and they will all be searchable and filterable in your online dashboard. We've added a few placeholders for convenience only - all fields are optional.
Web
iOS
Android
React Native
Xamarin
MacOS
Windows
1
CobrowseIO.customData = {
2
user_id: "<your_user_id>",
3
user_name: "<your_user_name>",
4
user_email: "<your_user_email>",
5
device_id: "<your_device_id>",
6
device_name: "<your_device_name>"
7
};
Copied!
Swift
1
CobrowseIO.instance().customData = [
2
kCBIOUserIdKey: "<your_user_id>" as NSObject,
3
kCBIOUserNameKey: "<your_user_name>" as NSObject,
4
kCBIOUserEmailKey: "<your_user_email>" as NSObject,
5
kCBIODeviceIdKey: "<your_device_id>" as NSObject,
6
kCBIODeviceNameKey: "<your_device_name>" as NSObject
7
]
Copied!
Objective-C
1
CobrowseIO.instance.customData = @{
2
kCBIOUserIdKey: @"<your_user_id>",
3
kCBIOUserNameKey: @"<your_user_name>",
4
kCBIOUserEmailKey: @"<your_user_email>",
5
kCBIODeviceIdKey: @"<your_device_id>",
6
kCBIODeviceNameKey: @"<your_device_name>"
7
};
Copied!
1
HashMap<String, Object> customData = new HashMap<>();
2
customData.put("user_id", "<your_user_id>");
3
customData.put("user_name", "<your_user_name>");
4
customData.put("user_email", "<your_user_email>");
5
customData.put("device_id", "<your_device_id>");
6
customData.put("device_name", "<your_device_name>");
7
CobrowseIO.instance().customData(customData);
Copied!
1
CobrowseIO.customData = {
2
user_id: "<your_user_id>",
3
user_name: "<your_user_name>",
4
user_email: "<your_user_email>",
5
device_id: "<your_device_id>",
6
device_name: "<your_device_name>"
7
};
Copied!
1
CobrowseIO.Instance.CustomData = new Dictionary<string, object>
2
{
3
{ CobrowseIO.UserIdKey, "<your_user_id>" },
4
{ CobrowseIO.UserNameKey, "<your_user_name>" },
5
{ CobrowseIO.UserEmailKey, "<your_user_email>" },
6
{ CobrowseIO.DeviceIdKey, "<your_device_id>" },
7
{ CobrowseIO.DeviceNameKey, "<your_device_name>" }
8
};
Copied!
Swift
1
CobrowseIO.instance().customData = [
2
kCBIOUserIdKey: "<your_user_id>" as NSObject,
3
kCBIOUserNameKey: "<your_user_name>" as NSObject,
4
kCBIOUserEmailKey: "<your_user_email>" as NSObject,
5
kCBIODeviceIdKey: "<your_device_id>" as NSObject,
6
kCBIODeviceNameKey: "<your_device_name>" as NSObject
7
]
Copied!
Objective-C
1
CobrowseIO.instance.customData = @{
2
kCBIOUserIdKey: @"<your_user_id>",
3
kCBIOUserNameKey: @"<your_user_name>",
4
kCBIOUserEmailKey: @"<your_user_email>",
5
kCBIODeviceIdKey: @"<your_device_id>",
6
kCBIODeviceNameKey: @"<your_device_name>"
7
};
Copied!
1
CobrowseIO.Instance.CustomData = new Dictionary<string, object>()
2
{
3
{ CobrowseIO.UserIdKey, "<your_user_id>" },
4
{ CobrowseIO.UserNameKey, "<your_user_name>" },
5
{ CobrowseIO.UserEmailKey, "<your_user_email>" },
6
{ CobrowseIO.DeviceIdKey, "<your_device_id>" },
7
{ CobrowseIO.DeviceNameKey, "<your_device_name>" }
8
};
Copied!
Last modified 1yr ago
Copy link