-
Notifications
You must be signed in to change notification settings - Fork 477
Open
Labels
Description
Has anyone found a solution for getting grape-swagger to support multiple versions at the same time. For example I have a structure like
/lib/api/root.rb
lib/api/v1/root.rb
lib/api/v2/root.rb
lib/api/v4/root.rb
etc...
If I put the 'add_documentation api_version: "v1"' in any of the root.rb files, swagger does pick up all APIs underneath and mark them as v1 but obviously I'd want those under v2 and v3 to be marked appropriately.
I am able to for example put 'add_documentation api_version: "v2"' in the v2 root.rb but then I only get docs for v2. If I 'add_documentation api_version: '' in all of the root.rb files only 1 gets picked up.
So, is there any way to publish all versions via swagger? Thanks in advance!