On production, your APIs will most likely be routed from the same domain as your website, or a subdomain, e.g. api.domain.co.uk. If you want to mimic this on localhost, you can use Nginx and Docker. Create a new directory nginx, within the directory, create two files, Dockerfile and nginx.config.
nginx | |---Dockerfile |---nginx.conf
nginx.conf
upstream credential { server host.docker.internal:4000 weight=1; }
upstream account { server host.docker.internal:4001 weight=1; }