add next param to api auth checker