Translating and orientating points correctly into Revit

Hello All,

Just to explain the context around this Dynamo script and what it does.

This script extracts x,y,z beacon points from an online BIM platform using a “Get” API request using CPython. When a Revit model is uploaded to this online BIM platform, it takes the Revit project base point as the point of origin. The problem I am facing is that the correct location of the beacons only appear when I am using a Revit model that has the project base point and internal origin aligned. If not, the beacons appear far away from the intended location. I think the node that is supposed to translate the point List of the beacons from the online platform into Revit points as the problem (the code in this node is below). It appears to be translating the point list based on the difference between the origin and base point but I am not sure what could be the problem here. Please let me know if you require any further clarifications here

angle = Element.GetParameterValueByName(PBP, “Angle to True North”);
degrees = angle > 0;
Base_Point = Coordinates.BasePoint();
Zvector = Vector.ZAxis();
vector = Vector.ByTwoPoints(CoordinateSystem.Origin(CoordinateSystem.Identity()),Coordinates.BasePoint());
points = Geometry.Translate(pointList, vector);
points2 = Geometry.Rotate(points<1L>, Base_Point<1L>, Zvector<1L>, angle<1L>);

Sounds like the BIM platform is reporting the geometry from the internal origin, not the base point. You’ll have to convert to the project base accordingly. hard to say without knowing what platform and how they’re working.