Validate API versioning in the response header
Preconditions (3)
Step 1: Send a GET request to the API endpoint with version v1 in the URL (e.g., https://api.example.com/v1/resource)
Step 2: Check the response status code is 200
Step 3: Verify the response header 'API-Version' exists
Step 4: Verify the 'API-Version' header value is 'v1'
Step 5: Send a GET request to the API endpoint with version v2 in the URL (e.g., https://api.example.com/v2/resource)
Step 6: Check the response status code is 200
Step 7: Verify the response header 'API-Version' exists
Step 8: Verify the 'API-Version' header value is 'v2'
✅ Expected Result: The API responds with status 200 for both versions and the 'API-Version' header matches the requested version.