1// You can get it in wp_login. Use this instead
2add_action('set_logged_in_cookie', 'custom_get_logged_in_cookie', 10, 6);
3function custom_get_logged_in_cookie($logged_in_cookie, $expire, $expiration, $user_id, $logged_in_text, $token) {
4 // do something...
5}
6