Should be possible, yes.
If you find the information what tells you you have "finished" the dungeon -> Killed last boss?
Then it would be an event you are able use some combat events to track if the name of the last boss (or maybe they got unique IDs meanwhile to identify them but I doubt this ) and it's health.
Maybe EVENT_TARGET_CHANGED (number eventCode, string unitTag) and EVENT_UNIT_DESTROYED (number eventCode, string unitTag) may help here.
If it was a raid you could use
EVENT_RAID_TRIAL_COMPLETE (number eventCode, string trialName, number score, number totalTime)
And you could use EVENT_ZONE_CHANGED for the zoneId to check what dungeon you are currently in.
Together with maybe LibZone.
Or other libraries that assist here.
Example API functions maybe usefull:
GetUnitName -> Name of the unit
IsUnitInDungeon -> Is the unit in a dungeon true/false
GetUnitPower -> Provide a powertype (CombatMechanicType) and check the value. Maybe not needed if the EVENT_UNIT_DESTROYED fires for boss unitTags if they die.
A unit could be the unitTag from the events above or "player" for yoruself.