execute_code. Use it with runtime introspection when exact symbols or properties are required.
Import policy
FreeCAD
Core document, geometry-value, console, configuration, units, and application services.
High-value symbols:
FreeCADGui
GUI, selection, viewport, active view, commands, workbench, and main window access.
High-value symbols:
Part
Boundary representation topology, primitive construction, wires, faces, solids, booleans, import/export, and geometric curves.
Construction symbols:
Sketcher
Sketch constraints and sketch object operations.
Primary constructor:
get_sketch, edit_sketch_geometry, and add_sketch_constraints when they cover the operation.
Draft
2D and lightweight object construction/modification.
Common creation functions:
Mesh
Mesh creation, import/export, and mesh features.
Common symbols:
MeshPart
Mesh/shape conversion utilities, when available.
Common operations:
TechDraw
Drawing pages, views, templates, dimensions, balloons, hatches, and rendered drawing outputs.
Common TypeIds:
list_techdraw_pages and get_techdraw_page for discovery/rendering.
Spreadsheet
Spreadsheet object TypeId:
Arch / BIM modules
Optional BIM/architecture modules. Import defensively.
Common creation functions:
Fem
Finite-element analysis containers, constraints, meshes, materials, and solver objects.
Use only for modeling/preparation unless authoritative simulation setup and validation are explicitly supplied. Do not certify engineering performance from object existence.
Common TypeIds include analysis containers and FEM objects; discover exact available types with doc.supportedTypes() and dir(Fem) in the active build.