ruby-grape / ruby-grape/grape-swagger
Support for accept_version_header?
Nobody has claimed this yet.
- Dominant language
- Ruby
- Stars
- 1.1k
- Forks
- 479
- Avg merge
- 2d 14h
- Merged PRs (30d)
- 6
Description
I have:
class MyAPI < Grape::API
version :v1, using: :accept_version_header, cascade: true
...
add_swagger_documentation
end
When I go to http://localhost:3000/api/swagger, it wants to fetch its info from http://localhost:3000/api/v1/swagger_doc, which doesn't exist.
Is there a way to tell grape-swagger that I'm using accept_version_header?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the MyAPI configuration with version :v1 using :accept_version_header and add_swagger_documentation, then inspect how the /api/swagger endpoint builds its /api/v1/swagger_doc URL. Confirm whether the generated documentation request can use the Accept version header, and verify that the resulting Swagger documentation endpoint works.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ruby
- Domain
- api, documentation
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100