internal Expense(ParsedJson json) { Id = json.GetInt("id"); PrimaryGroup = new Group(json.GetObject("group")); Name = json.GetString("name"); Notes = json.GetString("notes"); Price = json.GetDecimal("price"); Quantity = json.GetInt("quantity"); Archived = json.GetBool("archived"); CreatedAt = json.GetDateTime("created_at", false).Value; UpdatedAt = json.GetDateTime("updated_at", false).Value; Creator = new User(json.GetObject("creator")); Participants = json.GetArray("participants").ConvertAll(e => new User(e)); }