This looks like it may have some side effects we might want to prevent. For example, would this do the server call now whenever the Credentials type was touched? It also looks like it might do this query  even if the environment variable or well known file were present. This could be prevented by doing the file checks first, doing this on-demand when get_default is called, and keeping a flag to make sure this query happens only once.