Hi, Serial 1 not going to work for mega+esp8266 shield.
You need change it to Serial 3 . And read this topic, maybe will help you.