Forum Discussion

smaloney's avatar
smaloney
Occasional Contributor
2 years ago

Refactoring API definition does not properly update the version in the spec in ReadyAPI.

Our team have been going through some Swagger updates lately, and it has caused several of our old endpoints to no longer be application while adding new endpionts.  So, we are refactoring our API's.  We have been using the refactor option, but I'm noticing the spec version is not updated in readyapi after the new refactored API has been pulled in.  In this case today, we went from 1.0.40 to 1.0.6 (yes I know that does not make sense, but that is what our dev team did).  1.0.40 was updated back in Sept 2022, while 1.0.6 was updated Jan 2023.  1.0.6 removed several old endpoints and added some new ones.  The import seemed to work ok, but the spec version does not update in ReadyAPI.  I've noticed this on other imports where the version progression is logical, such as going from 1.0.4 to 1.0.5...same thing.  The spec number is not updated.  See screenshots so it is clear which spec number I'm talking about.  After the refactored API is pulled in, I'm renaming it to the right version in the left panel just so we are clear which spec was imported.  This appears to be a bug...does anyone know if it has been logged yet?  I can't seem to find anything on it.

 

 

1 Reply

  • Taz's avatar
    Taz
    Contributor

    Not sure if it relates but we had an issue where parameterised api's did not have parameter names that match exactly with the declared variables.  For example if the parameter is .../{testId}/... but the property behind it is TestId or just id, then ReadyAPI failed to import or update the APIs from swagger.