Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v2 documentation in v1 #158

Open
isratrade opened this issue Oct 7, 2013 · 1 comment
Open

v2 documentation in v1 #158

isratrade opened this issue Oct 7, 2013 · 1 comment

Comments

@isratrade
Copy link

All the new methods in V2 controllers are also appears in V1 documentation

for example, Foreman API V2 has the following methods that are not in V1

GET /api/hosts/:id/puppetrun Force a puppet run on the agent.
PUT /api/hosts/:id/power Run power operation on host.
PUT /api/hosts/:id/boot Boot host from specified device.
POST /api/hosts/facts Upload facts for a host, creating the host if required.

However, they appear in V1 documentation in /apidoc/v1

@xofred
Copy link

xofred commented Mar 13, 2018

Solved it by luck!

Suppose u have a app/controllers/api/v1/users_controller.rb and app/controllers/api/v2/users_controller.rb.

Just add one line api_versions "2.0" in v2 controller

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants