Nonautonomous integrable nonlinear Schrödinger equations with generalized external potentials