@sergei lozenkov Thanks for reaching out. When importing an OpenAPI document into Azure APIM, it's essential to validate the JSON beforehand to avoid issues during the import process. Using either Swagger Editor or openapi-spec-validator is a reliable way to catch any issues before importing into APIM. However, note that API import limitations exist, and some features may not be supported. Please refer to the official documentation for details on these restrictions and ensure that your OpenAPI document adheres to these limitations to avoid import failures.
https://learn.microsoft.com/en-us/azure/api-management/api-management-api-import-restrictions
Unfortunately, there is no automation process available for validating OpenAPI documents before importing them into APIM. If the OpenAPI Specification Validator does not show any errors or warnings, but you are still getting an error when importing the document into Azure APIM, it's possible that there is an issue with the Azure APIM service. In this case, you may need to contact Azure support for further assistance.
I hope this helps. Let me know if you have any other questions.