OpenAPI Documents Empty
I upgraded my project to .NET 9, added the OpenAPI services on lines 6 and 16. Then when I go to
https://localhost:<port>/openapi/v1.json
I get a blank page. The port seems fine since none of the other ports connect to a page, this one does but there's nothing. I don't know what's wrong here. The only thing off I see in my output is 'Middleware: The WebRootPath was not found: C:<project directory>\wwwroot. Static files may be unavailable'

5 Replies
it should work, did u f12 and see the api response for the request?
i got this

404 means it cant find the document?
i think OpenAPI wasnt set up correctly but idk what exactly went wrong
moving the app.MapOpenApi out seemed to fix it

It means it doesn't find the document