{"action":"created","issue":{"url":"https://api.github.com/repos/Starcounter/Starcounter/issues/2647","labels_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/2647/labels{/name}","comments_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/2647/comments","events_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/2647/events","html_url":"https://github.com/Starcounter/Starcounter/issues/2647","id":66836073,"number":2647,"title":"Response data for REST API","user":{"login":"miyconst","id":6435556,"avatar_url":"https://avatars.githubusercontent.com/u/6435556?v=3","gravatar_id":"","url":"https://api.github.com/users/miyconst","html_url":"https://github.com/miyconst","followers_url":"https://api.github.com/users/miyconst/followers","following_url":"https://api.github.com/users/miyconst/following{/other_user}","gists_url":"https://api.github.com/users/miyconst/gists{/gist_id}","starred_url":"https://api.github.com/users/miyconst/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miyconst/subscriptions","organizations_url":"https://api.github.com/users/miyconst/orgs","repos_url":"https://api.github.com/users/miyconst/repos","events_url":"https://api.github.com/users/miyconst/events{/privacy}","received_events_url":"https://api.github.com/users/miyconst/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Starcounter/Starcounter/labels/enhancement","name":"enhancement","color":"84b6eb"},{"url":"https://api.github.com/repos/Starcounter/Starcounter/labels/Newbie%20issues","name":"Newbie issues","color":"009800"},{"url":"https://api.github.com/repos/Starcounter/Starcounter/labels/question","name":"question","color":"02d7e1"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":12,"created_at":"2015-04-07T09:27:34Z","updated_at":"2015-07-01T08:38:47Z","closed_at":null,"body":"There should be a way to return clean JSON result for third side applications.\r\n\r\nApplications with own GUI would like to see clean API response. Lets take SignIn method for example.\r\n\r\nExpected:\r\n```javascript\r\n{\r\n    \"IsSignedIn\": true,\r\n    \"Message\": \"\",\r\n    \"FullName\": \"Konstantin Mi\",\r\n    \"ImageUrl\": \"https://lh3.googleusercontent.com/-XdUIqdMkCWA/AAAAAAAAAAI/AAAAAAAAAAA/4252rscbv5M/photo.jpg\"\r\n}\r\n```\r\n\r\nActual:\r\n```javascript\r\n{\r\n    \"_ver#c$\": 0,\r\n    \"_ver#s\": 0,\r\n    \"Html\": \"/Launcher/LauncherTemplate.html\",\r\n    \"homeThumbnail\": {\r\n    },\r\n    \"homeUrl\": \"\",\r\n    \"editingMode$\": false,\r\n    \"searchBar\": {\r\n        \"query$\": \"\",\r\n        \"searchEngineResultPageUrl$\": \"\",\r\n        \"feedback\": [\r\n        ]\r\n    },\r\n    \"results\": {\r\n    },\r\n    \"user\": {\r\n        \"Launcher\": {\r\n            \"Html\": \"\"\r\n        },\r\n        \"SignIn\": {\r\n            \"Uri\": \"\",\r\n            \"Html\": \"/SignIn/html/SignInPage.html\",\r\n            \"Username$\": \"\",\r\n            \"Password$\": \"\",\r\n            \"IsSignedIn\": true,\r\n            \"Message\": \"\",\r\n            \"FullName\": \"Konstantin Mi\",\r\n            \"ImageUrl\": \"https://lh3.googleusercontent.com/-XdUIqdMkCWA/AAAAAAAAAAI/AAAAAAAAAAA/4252rscbv5M/photo.jpg\",\r\n            \"SignInForm\": {\r\n                \"SignIn\": {\r\n                },\r\n                \"Launcher\": {\r\n                    \"Html\": \"\"\r\n                },\r\n                \"Html\": \"\"\r\n            }\r\n        },\r\n        \"Html\": \"/polyjuice/htmlmerger?SignIn=/SignIn/html/SignInPage.html\"\r\n    },\r\n    \"menu\": {\r\n        \"Launcher\": {\r\n            \"Html\": \"/Launcher/LauncherMenu.html\"\r\n        },\r\n        \"Html\": \"/polyjuice/htmlmerger?Launcher=/Launcher/LauncherMenu.html\"\r\n    },\r\n    \"launchpad\": {\r\n        \"icons\": {\r\n            \"Launcher\": {\r\n                \"Html\": \"\"\r\n            },\r\n            \"Html\": \"\"\r\n        },\r\n        \"names\": {\r\n            \"Launcher\": {\r\n                \"Html\": \"\"\r\n            },\r\n            \"Html\": \"\"\r\n        }\r\n    },\r\n    \"dashboard\": {\r\n    },\r\n    \"appFilter\": [\r\n    ],\r\n    \"uri\": \"\",\r\n    \"workspaces\": [\r\n    {\r\n        \"appName\": \"signin\",\r\n        \"master\": {\r\n            \"Launcher\": {\r\n                \"Html\": \"\"\r\n            },\r\n            \"SignIn\": {\r\n            },\r\n            \"Html\": \"\"\r\n        },\r\n        \"Html\": \"/Launcher/LauncherTemplate.html\"\r\n    }\r\n    ]\r\n}\r\n```"},"comment":{"url":"https://api.github.com/repos/Starcounter/Starcounter/issues/comments/117539982","html_url":"https://github.com/Starcounter/Starcounter/issues/2647#issuecomment-117539982","issue_url":"https://api.github.com/repos/Starcounter/Starcounter/issues/2647","id":117539982,"user":{"login":"warpech","id":566463,"avatar_url":"https://avatars.githubusercontent.com/u/566463?v=3","gravatar_id":"","url":"https://api.github.com/users/warpech","html_url":"https://github.com/warpech","followers_url":"https://api.github.com/users/warpech/followers","following_url":"https://api.github.com/users/warpech/following{/other_user}","gists_url":"https://api.github.com/users/warpech/gists{/gist_id}","starred_url":"https://api.github.com/users/warpech/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/warpech/subscriptions","organizations_url":"https://api.github.com/users/warpech/orgs","repos_url":"https://api.github.com/users/warpech/repos","events_url":"https://api.github.com/users/warpech/events{/privacy}","received_events_url":"https://api.github.com/users/warpech/received_events","type":"User","site_admin":false},"created_at":"2015-07-01T08:38:47Z","updated_at":"2015-07-01T08:38:47Z","body":"As @alemoi explained in the Hangout, the problem expressed in first message of this thread is solved with using `skipMiddlewareFilters` flag in the request handler. Explained here: http://starcounter.io/nightly-changes/addingskipping-middleware-filters/\r\n\r\nI think this is better than all the proposed solutions in this thread :+1:\r\n\r\n@alemoi, @miyconst if you're fine with this, we can close this issue"}}