Function encodeClientToken