I am using homestead for a development server. I have both a test api and website running in the same instance, along with several other sites I'm messing with.
However, I also have another machine that I use for staging. It runs sites for testing before they get pushed to the live hosting server. That also has the last working published version of the api on it, which the staging website uses.
I'm a single developer here, so i do not have to share access with others. Of course, if you need to share the api with other developers than you would need it to be accessible outside your machine.