api/util/json: allow only one JSONAPIFunc as input, rather than chain