Skip to content

Provide a mechanism to return deprecated and supported version on UnsupportedApiVersion response #187

Closed
@AshishBoobun

Description

@AshishBoobun

The Report API Versions option returns the supported and deprecated version (in the response header) only if a client requested a "supported version" endpoint. Otherwise, if a "non-supported version" of the API is requested, the default UnsupportedApiVersion is return as follows:

{
    "error": {
        "code": "UnsupportedApiVersion",
        "message": "The requested resource with API version '1' does not support HTTP method 'GET'.",
        "innerError": {
            "message": "No route providing a controller name with API version '1' was found to match HTTP method 'GET' and request URI 'http://blahUrl/api/v1/blaResource'."
        }
    }
}

I guess it is helpful (from a consuming client perspective) to return the api-deprecated-versions and api-supported-versions header when the UnsupportedApiVersion response error is returned?

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions