using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Web.Http;
using Newtonsoft.Json;
namespace MvcApplication1.Controllers
{
public class ListController : ApiController
{
[JsonObject]
public class ListDTO
{
[JsonProperty]
public IEnumerable<string> Items { get; set; }
}
[HttpGet]
public ListDTO Get()
{
return new ListDTO()
{
Items = new List<string>()
{
"Item 1",
"Item 2",
},
};
}
}
}