docs: document the whole environment surface, and guard it