public object Get() { string uuid = Context.Request.Query[Defines.IDENTIFIER]; if (string.IsNullOrEmpty(uuid)) { return(new StatusCodeResult((int)HttpStatusCode.NotFound)); } HttpResponseHeadersId id = new HttpResponseHeadersId(uuid); Site site = id.SiteId == null ? null : SiteHelper.GetSite(id.SiteId.Value); List <NameValueConfigurationElement> headers = CustomHeadersHelper.GetCustomHeaders(site, id.Path); // Set HTTP header for total count this.Context.Response.SetItemsCount(headers.Count()); return(new { custom_headers = headers.Select(h => CustomHeadersHelper.ToJsonModelRef(h, site, id.Path)) }); }