Suggest you try to make it work on your PC using a scripting language first to figure out the URLs and OAuth first before attempting to port to ESP8266. The ESP8266 may not have sufficient resources to reliably handle the https:// encryption that's needed.