Class: Rack::ServiceApiVersioning::ReportNoMatchingVersion
- Inherits:
-
HttpErrorResponse
- Object
- HttpErrorResponse
- Rack::ServiceApiVersioning::ReportNoMatchingVersion
- Defined in:
- lib/rack/service_api_versioning/report_no_matching_version.rb
Overview
Builds Rack::Response to halt request execution with an HTTP status code of 406 (“Not Acceptable”) when no presently available API Version has been specified in an HTTP Accept header.
Class Method Summary collapse
Methods inherited from HttpErrorResponse
Class Method Details
.call(api_versions:, code: 406) ⇒ Object
13 14 15 |
# File 'lib/rack/service_api_versioning/report_no_matching_version.rb', line 13 def self.call(api_versions:, code: 406) new(code, Internals.(api_versions)).call end |