Having an issue with sending data to an API on the web.
My goal is:
To send a HTTP GET to an API, only need the send an URL.
My actions are:
I have been looking at the post: https://community.mongoose-os.com/t/how-to-call-restful-api-in-esp8266-mongoose-os/77
I am not great at C and I am having trouble understanding how to use/create the event handler.
This is the code I have added:
struct mg_connection *mg_connect_http( struct mg_mgr *mgr, MG_CB(mg_event_handler_t event_handler, void *user_data), apiUrl, NULL, NULL); mg_connect_http(mgos_get_mgr(), event_handler, apiUrl, NULL, NULL);
The result I see is:
My code wont build.
My expectation & question is:
A full example of creating the event handler and using it to do a HTTP GET would be awesome.
Thanks in advance,