Added date support in adherence. Better json encoding