How can I generate a full swagger doc for Magento 2 REST API?
That's actually correct behavior.
You need to generate API credentials in magento backend, authenticate, and insert token like on the image below:
Token can be obtained from swagger web interface calling integrationAdminTokenServiceV1 or you can authenticate use curl:
curl -XPOST -H 'Content-Type: application/json' http://your-host/index.php/rest/V1/integration/admin/token -d '{ "username": "yourUsername", "password": "yourPassword" }'
To see the full list of services you may want to generate a full permissions token from the admin panel.
- log into admin panel
- Navigate to Systems -> Integrations (under Extensions section)
- click on "Add a new Integration" Button
- Fill in the required fields and move to API tab on the left, for "Resource Access" select All
- Hit save and in the grid view click on Authorize.
- Grab the Access Token generated (and save the rest of the info, of course).
- Navigate to /swagger and paste that access token to see the full list of REST services on your site.