There is a light function, similar to the vertex and fragment. You can write it yourself, but it's kind of involved.
It might be a better idea to customize the standard material instead. You can use the drop down arrow to convert a standard material to a shader material, then add your code.