The best place to start creating bots is with the starcraft API. THis is available at https://github.com/Blizzard/s2client-api
This contains examples tutorials on how to create a starcraft 2 bots
The deepmind python library: https://github.com/deepmind/pysc2
is a great place to start for running minigames, and using machine learning techniques to overcome challenges.
A good place to go to start creating SC2 bots is the Command Center framework available at https://github.com/davechurchill/commandcenter
The c++ api has documentation as part of the github repository. Hosted online for your convenience. Documentation hosted here.