Show Menu
主題×

setCustomerIDs

setCustomerIDs 會設定 1 或多個機碼值組,定義客戶 ID 及其驗證狀態。
語法:
visitor.setCustomerIDs()
如下列程式碼範例所示,您可以設定單一或多個 ID。如需詳細資訊和範例,請參閱 客戶 ID 和驗證狀態
// Single ID with a single authentication state visitor.setCustomerIDs({ "userid":{ "id":"67312378756723456", "authState":Visitor.AuthState.AUTHENTICATED } }); //Multiple IDs with a single authentication state visitor.setCustomerIDs({ "userid":{ "id":"67312378756723456", "authState":Visitor.AuthState.AUTHENTICATED }, "dpuuid":"550e8400-e29b-41d4-a716-446655440000" });