implement to use JSON and object