Added BasePayloadTypeAdapter to fix Serialization Issues

Subclasses of BasePayload were not properly serialized as Gson lacked an adapter to convert from the parent to its base class. This left much of the API unusable as the userId, nor anonymousId, was not included in the rest call despite being set on the various payload objects.