{"action":"created","issue":{"url":"https://api.github.com/repos/gangverk/flask-swagger/issues/10","labels_url":"https://api.github.com/repos/gangverk/flask-swagger/issues/10/labels{/name}","comments_url":"https://api.github.com/repos/gangverk/flask-swagger/issues/10/comments","events_url":"https://api.github.com/repos/gangverk/flask-swagger/issues/10/events","html_url":"https://github.com/gangverk/flask-swagger/issues/10","id":88450740,"number":10,"title":"Method/route combinations appear in swagger documentation output that are not in the code","user":{"login":"JasonWWalton","id":8796970,"avatar_url":"https://avatars.githubusercontent.com/u/8796970?v=3","gravatar_id":"","url":"https://api.github.com/users/JasonWWalton","html_url":"https://github.com/JasonWWalton","followers_url":"https://api.github.com/users/JasonWWalton/followers","following_url":"https://api.github.com/users/JasonWWalton/following{/other_user}","gists_url":"https://api.github.com/users/JasonWWalton/gists{/gist_id}","starred_url":"https://api.github.com/users/JasonWWalton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JasonWWalton/subscriptions","organizations_url":"https://api.github.com/users/JasonWWalton/orgs","repos_url":"https://api.github.com/users/JasonWWalton/repos","events_url":"https://api.github.com/users/JasonWWalton/events{/privacy}","received_events_url":"https://api.github.com/users/JasonWWalton/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-06-15T14:57:36Z","updated_at":"2015-06-21T18:43:46Z","closed_at":null,"body":"Permutations of routes and methods appear as documented operations in the swagger output that aren't present in the code.  Other applications rely on the JSON output of swagger, and the superfluity of operations breaks that.\r\n\r\n```mod.add_url_rule('/edges/', defaults={'annotation_id': None}, methods=['GET'])\r\n   mod.add_url_rule('/edges/', methods=['POST'])\r\n   mod.add_url_rule('/edges/<int:annotation_id>/', methods=['GET', 'PUT', 'PATCH', 'DELETE'])```\r\n\r\ni.e. The code defines a route at ```/edges/``` with \"GET\" and \"POST\" methods.  The code also defines a route at ```/edges/<int:annotation_id>/``` with \"GET\", \"PUT\", \"PATCH\", and \"DELETE\" methods.  [This is a total of 2 routes and 5 method verbs.]  The swagger output shows a list of 10 operations, which includes combinations of verbs and routes that don't exist in code (e.g. \"POST\" for the ```/edges/<int:annotation_id>/``` route, and \"PUT\" for the ```/edges/``` route)."},"comment":{"url":"https://api.github.com/repos/gangverk/flask-swagger/issues/comments/113940429","html_url":"https://github.com/gangverk/flask-swagger/issues/10#issuecomment-113940429","issue_url":"https://api.github.com/repos/gangverk/flask-swagger/issues/10","id":113940429,"user":{"login":"atlithorn","id":467317,"avatar_url":"https://avatars.githubusercontent.com/u/467317?v=3","gravatar_id":"","url":"https://api.github.com/users/atlithorn","html_url":"https://github.com/atlithorn","followers_url":"https://api.github.com/users/atlithorn/followers","following_url":"https://api.github.com/users/atlithorn/following{/other_user}","gists_url":"https://api.github.com/users/atlithorn/gists{/gist_id}","starred_url":"https://api.github.com/users/atlithorn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/atlithorn/subscriptions","organizations_url":"https://api.github.com/users/atlithorn/orgs","repos_url":"https://api.github.com/users/atlithorn/repos","events_url":"https://api.github.com/users/atlithorn/events{/privacy}","received_events_url":"https://api.github.com/users/atlithorn/received_events","type":"User","site_admin":false},"created_at":"2015-06-21T18:43:46Z","updated_at":"2015-06-21T18:43:46Z","body":"Jason, could you provide a little test script (similar to example.py in the repo) so I can reproduce this and figure out what's going on?\r\nI have seen @ibratoev's solution and it looks good but I want to reproduce this for myself before merging the code and I have been unable to do so via the description in your bug report."}}