Fixed json bug, fixed docs and examples