Revert faulty merge

The merge breaks the "run without api key" functionality added in the last
commits.

This reverts commit e1d1146633725a734566a654626728a954f11f44, reversing
changes made to 62b5ae463225fa667b30c0e6ce7d63b8e882876d.