Added client ID generation and added documentation