Updating OpenAPI file assigns new Stoplight stable IDs
Originally posted by user markg to the Stoplight Community on 04/20/2023 at 18:14 ET.
Hi there, I uploaded an OpenAPI spec generated by a third-party tool to get started. I then copied the Stoplight stable IDs that Stoplight generated into our OpenAPI spec, so that our resources and models would stay at the same URLs.
But when I uploaded it again (which I couldn't find a way to do other than like, copying the OpenAPI spec text into the Code tab in the Studio), it assigns totally new Stoplight IDs to them, overwriting the ones that were assigned before.
Is there a way to update our OpenAPI file without these stable IDs getting overwritten? Thank you!
Skinghar (Staff) [05/16/2023 - 10:26 ET]
Hello Markg, After deeper investigation and speaking with engineering. You are seeing expected behavior. They shared a suggestion of the following to try to assist you.
"What they could do is: remove all old documents they want to replace with new ones import new documents (seems like they could use the import feature we have, no need to copy&paste anything, https://docs.stoplight.io/docs/platform/58bf119ddff88-work-with-files#import-file) now, in code view, manually re-assign all the IDs publish the changes"
Hope this helps!