First working version of custom serializers.