use proxy if one is defined