completed json object for push, refactor functions