Raise an error if the username exceeds the character limit

the api returns a HTTP 400 error code, if the username is more than 15 chars. This is rather uninformative. 

This change ensures this is checked before sending the request, and that the caller gets an indication how to rectify the problem.