Add JSON methods for setting and getting