Arduino mega with build in wifi

I bought AN MEGA 2860 WITH BUILD IN ESP8266

And I can't figure out how to set the ESP SO HE WILL BE MY WIFI MODULE
In general, what I want to do is to make a type of DATA LOGGER that will receive information FROM TEMP SENSORE AND WILL SEND IT TO https://thingspeak.com/
I have not found on the Internet
how to define that it will send via the built-in ESP
ALL I FOUND ONLINE IS HOW TO DO IT WITH OT A BUILED IN ESP

You can install ESP-link on ESP8266 then use the el-client library on Mega to send data to Thingspeak.

The setup is a little bit complex but I think SLIP protocol better than Serial.

Here the example for Mega:

have a look at Mega-WiFi_R3_ATmega2560_ESP8266

  1. program the ESP8266 to send data to thingspeak and test it - when it works
  2. program the Mega to acquire the data fromtemperature sensors - when it works
  3. program to mega to send sensor results over Serial3 to the ESP8266
  4. program the ESP8266 to receive the serial data and send it to thingspeak

having to program two microcontrollers and have them communicate with each other is a complication
what is the temperature sensor ? could you connect it to the ESP8266 and forget thr Mega
the ESP8266 could acquire the sensor data and transmit it to thingspeak

@FernandoGarcia that would be a good advice in 2016, not today

I would like to know what's the best alternative.

I have used yet ESP-link for MQTT.

so , i did as what the url told me
it upload somthing to the esp
and it ses
" Wrote 264512 bytes (195024 compressed) at 0x00000000 in 17.2 seconds (effective 123.2 kbit/s)...
Hash of data verified.

Leaving...
Hard resetting via RTS pin..."

part 2 ' i have a workinng code ',. for now its only sending the data to the serial monitor

have a look at Programming Wemos Mega + WiFi R3
it takes you thru programming the ESP8266 and the Mega - in particular setting the DIP switches at each stage