Rest api now accepts also JSON and persistence layer parses xml or json and inserts in database