publishing APIs conditionally