improving data conversion
improvements on chaining. changing name of apierrors to apistatus to be more understandable