Another option would be to tell Gson how to deserialize a CookbookDefinition by adding a new "CookbookDefinitionAdapter" in the ChefParser module, but IMO that would be more complex as we have to deal with different parsers for Chef versions 0.9 and later versions.