Yes you can have a wireless enabled light.
There is good readme.md available on how to install micropython in
ESP8266. Please refer the link
Once you install this firmware you can connect the device first time for configuration using serial port with baud rate 115200. For windows the serial driver is available. Read the hardware spec of Node mcu which gives the link for windows driver.
You can access the device through WEBREPL. Refer the docs here.
However you need to do the below steps
This needs to be added to a file called boot.py/main.py which resided in the core of ESP8266. You can do this the first time when you login through the serial console.
The steps below will help you to pair the ESP8266 to wireless network.
wlan = network.WLAN(network.STA_IF) # create station interface
wlan.active(True) # activate the interface
wlan.scan() # scan for access points
wlan.isconnected() # check if the station is connected to an AP
wlan.connect('essid', 'password') # connect to an AP
wlan.config('mac') # get the interface's MAC adddress
wlan.ifconfig() # get the interface's IP/netmask/gw/DNS addresses
Once you get this done. You can use ssdp discovery to get the ip of the device.
There is sufficient code to send and get repsponse which you can reuse to trigger and get response from ESP8266. This means your raspberry pi can talk to ESP8266 (Trigger and collect data.)
There is also a module called machine. This enables to control the GPIO in ESP8266 the same way as you use GPIO module in raspberry pi. There is a very good documentation available with all the above mentioned details in the link below.
Hope this helps.