uid now uses track.sessionId() as a backup. Corrected uri -> url. Added comments.