Revert "JSON formatting"

This reverts commit 22d58b99e18eb0e00330f76ab0dafc050eccc3ca.
Revert "Revert "JSON formatting""

This reverts commit af134a59a255a607755869eb2ea5dd52dcf2cf4e.
Additional tests
Comment fixes and changed the function names

Matched othe function names to the original temp module