Ghpython component message does not update

I am trying to create a ghpython component that retrieves connected gh component’s object type.
Also trying to add input parameters name and description through ghpythonlib.
I realised editing ghenv.component.message does not update when I add the input params this way.
What am I missing here?

ghenv.Component.Message = "Test 1"

import Grasshopper

# Define an input parameter with a name, nickname, and description
param_name = "Gh Object"
param_nickname = "O"
param_description = "Retrieve connected GH object"

# Create a new input parameter using Grasshopper's Parameter class
input_param = Grasshopper.Kernel.Parameters.Param_GenericObject()
input_param.Name = param_name
input_param.NickName = param_nickname
input_param.Description = param_description


input_data = input_param.VolatileData