add from_hash in Client