Plant component: Include max and min values to the plant state attributes

Is it possible to include the min and max values set in config of the plant component into the plant state as attributes? The reason for doing this is that I want to be able to create automations and notifications based on e.g. the minimum moisture or brightness (eg turn on water or light) without having to define min and max levels more than one place, ie in the plant config. Would be very convenient when having several sensors.

I know basic Python, but after looking at the code I see this is a few levels up from my competence level.

Plant component:

I guess I would like to have them reported in the list by the red arrow when looking at the plant state:

From your link:

It also supports setting minimum and maximum values for each measurement and will change its state to “problem” if it is not within those limits.

Is that what you want? You could then trigger off that.

I have set minimum and maximum for every measurement. Now I want to read those min and max values…

Did you ask about something like this?

I built it using the button-card:

1 Like

I am not looking for a Lovelace-card per se, but you may nevertheless have solved what I am looking for since you probably are using the values I am looking for if you are populating them from the plant component. Could you please share the code for this?

So no one knows how to access the plant attributes?

I think this may clarify the issue a bit:

{{ state_attr('plant.107', 'moisture') }} will give the current moisture level for a specific plant (named 107 in this case). What I would like to get hold of is also something like {{ state_attr('plant.107', 'min_moisture') }} and {{ state_attr('plant.107', 'max_moisture') }} for the same plant, but these attributes are not present in the plant.107 entity today…