Starting from a light instance tag, mi_query(miQ_INST_ITEM... gets you the light tag (miSCENE_LIGHT). Then miQ_LIGHT_SHADER gets you the light shader function definition (miSCENE_FUNCTION). Then miQ_FUNC_DECL gets you the function declaration (miSCENE_FUNCTION_DECL) for the light shader. (You should check for null tags at each stage). mi_api_parameter_lookup gives you the offset into miFunction:

arameters for your "colour" parameter, given a particular declaration.
Code:
miBoolean mi_api_parameter_lookup(
miParam_type *type, /* type of <name> */
miBoolean *is_array, /* true for arrays */
int *offs, /* offset in param blk */
miTag decl_tag, /* decl to look up in */
miBoolean out, /* output or input? */
char *name) /* name to look up */
Make sure you mi_mem_strdup the param name before passing it in. When you have the offsets, mi_db_access/mi_db_unpin the light shader, then offset into miFunction:

arameters with that, cast to miColor*, dereference it and that's your light colour. That works if it's not connected to a subshader; if it is, you can get the tag from the ghost area of the parameters array.... take a look at how the mi_eval macro works, and the geoshader data structure docs for Functions.