improving client and payment object deserialization