Hi saisuneel,
Automated openAPI document generation is not a feature currently implemented in CA APIm gateway.
This would be a pretty awesome feature !
Nevertheless one you write the specification attached to you API, you could respond to specific requests to your API (let's say a swagger boolean query parameter) with your document.