Idea and suggestion for a battery powered system

i use ESP8266 with 2 x 18650 battery and eBay PSU

but i only need 6 x I/Os so depends on how many GPIO’s you need… how many does the Micro have?