title: How to set userId in FirebaseAnalytics for Unity3D?
body: <p>I am integrating Firebase-Analytics for my unity project. During Firebase initialisation I have to call this method as shown in the official <a href="https://github.com/firebase/quickstart-unity/blob/master/analytics/testapp/Assets/TestApp/UIHandler.cs" rel="nofollow noreferrer">quickstart example project</a>.</p>
  
  <p><code>// Set the user ID.
  FirebaseAnalytics.SetUserId("uber_user_510");</code></p>
  
  <p>How can I get this user ID for both Android &amp; iOS platform in my Unity project?</p>
  
  <p><strong>From the official <a href="https://firebase.google.com/docs/reference/android/com/google/firebase/analytics/FirebaseAnalytics#setUserId(java.lang.String)" rel="nofollow noreferrer">documentation</a>:</strong></p>
  
  <p><code>public void setUserId (String id)</code></p>
  
  <p>Sets the user ID property.</p>
  
  <p>Parameters:
  The user ID to ascribe to the user of this app on this device, which must be non-empty and no more than 36 characters long. Setting the ID to null removes the user ID.</p>