XYZ(x,y,z).ToPoint() not working

Dear All,

need help on problem below;

i am trying to create a python script to get coordinates of the Electrical pit, to be filled in project parameters of those pits.

my problem is i am not able to change XYZ to point geometry.

error screenshot and script screenshot is attached.

Thanks in Advance.

error

Import the RevitNodes library.

Thanks for Reply.

its there already.

Change your import to this

clr.AddReference("RevitNodes")
import Revit
clr.ImportExtensions(Revit.Elements)

Thanks for the help. it works now.