API Reference
nuke.
layers
Lists the layers in a node. If no node is provided this will list all known layer names in this script.
node – Optional node parameter.
A list of layer names.