Skip to main content
Glama
neka-nat
by neka-nat

create_object

Add Part, Draft, PartDesign, or FEM objects to FreeCAD documents by specifying object type, name, and properties. Includes optional screenshot of the created object.

Instructions

Create a new object in FreeCAD. Object type is starts with "Part::" or "Draft::" or "PartDesign::" or "Fem::".

Args:
    doc_name: The name of the document to create the object in.
    obj_type: The type of the object to create (e.g. 'Part::Box', 'Part::Cylinder', 'Draft::Circle', 'PartDesign::Body', etc.).
    obj_name: The name of the object to create.
    obj_properties: The properties of the object to create.

Returns:
    A message indicating the success or failure of the object creation and a screenshot of the object.

Examples:
    If you want to create a cylinder with a height of 30 and a radius of 10, you can use the following data.
    ```json
    {
        "doc_name": "MyCylinder",
        "obj_name": "Cylinder",
        "obj_type": "Part::Cylinder",
        "obj_properties": {
            "Height": 30,
            "Radius": 10,
            "Placement": {
                "Base": {
                    "x": 10,
                    "y": 10,
                    "z": 0
                },
                "Rotation": {
                    "Axis": {
                        "x": 0,
                        "y": 0,
                        "z": 1
                    },
                    "Angle": 45
                }
            },
            "ViewObject": {
                "ShapeColor": [0.5, 0.5, 0.5, 1.0]
            }
        }
    }
    ```

    If you want to create a circle with a radius of 10, you can use the following data.
    ```json
    {
        "doc_name": "MyCircle",
        "obj_name": "Circle",
        "obj_type": "Draft::Circle",
    }
    ```

    If you want to create a FEM analysis, you can use the following data.
    ```json
    {
        "doc_name": "MyFEMAnalysis",
        "obj_name": "FemAnalysis",
        "obj_type": "Fem::AnalysisPython",
    }
    ```

    If you want to create a FEM constraint, you can use the following data.
    ```json
    {
        "doc_name": "MyFEMConstraint",
        "obj_name": "FemConstraint",
        "obj_type": "Fem::ConstraintFixed",
        "analysis_name": "MyFEMAnalysis",
        "obj_properties": {
            "References": [
                {
                    "object_name": "MyObject",
                    "face": "Face1"
                }
            ]
        }
    }
    ```

    If you want to create a FEM mechanical material, you can use the following data.
    ```json
    {
        "doc_name": "MyFEMAnalysis",
        "obj_name": "FemMechanicalMaterial",
        "obj_type": "Fem::MaterialCommon",
        "analysis_name": "MyFEMAnalysis",
        "obj_properties": {
            "Material": {
                "Name": "MyMaterial",
                "Density": "7900 kg/m^3",
                "YoungModulus": "210 GPa",
                "PoissonRatio": 0.3
            }
        }
    }
    ```

    If you want to create a FEM mesh, you can use the following data.
    The `Part` property is required.
    ```json
    {
        "doc_name": "MyFEMMesh",
        "obj_name": "FemMesh",
        "obj_type": "Fem::FemMeshGmsh",
        "analysis_name": "MyFEMAnalysis",
        "obj_properties": {
            "Part": "MyObject",
            "ElementSizeMax": 10,
            "ElementSizeMin": 0.1,
            "MeshAlgorithm": 2
        }
    }
    ```

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
analysis_nameNo
doc_nameYes
obj_nameYes
obj_propertiesNo
obj_typeYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It does well by specifying the return format ('A message indicating success or failure and a screenshot'), which is crucial information not in the input schema. However, it doesn't mention potential side effects (e.g., whether creation modifies existing documents), error conditions, or performance characteristics that would be helpful for a mutation tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with purpose and parameter explanations, but the examples section is extremely long (6 detailed examples spanning multiple object types). While valuable for parameter semantics, this makes the description verbose. Some examples could be consolidated or referenced rather than fully expanded to improve conciseness while maintaining utility.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity (5 parameters, nested objects, 0% schema coverage, no annotations), the description provides exceptional completeness. It explains all parameters thoroughly, includes return value information, and provides extensive examples covering multiple use cases. The presence of an output schema reduces the need to document return values, but the description still adds valuable context about the screenshot inclusion.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage, the description must fully compensate - and it does excellently. It explains all 5 parameters in detail: 'doc_name' (document to create object in), 'obj_type' (type with specific prefixes and examples), 'obj_name' (name of object), 'obj_properties' (properties of object), and even documents the optional 'analysis_name' parameter through multiple examples. The extensive examples provide concrete syntax and format guidance beyond what the bare schema offers.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Create a new object in FreeCAD' with specific object type prefixes ('Part::', 'Draft::', etc.). It distinguishes this from sibling tools like 'create_document' (which creates documents) and 'delete_object'/'edit_object' (which modify existing objects). The verb 'create' is specific and the resource 'object in FreeCAD' is well-defined.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage through examples showing different object types (Part::Box, Draft::Circle, Fem::AnalysisPython), but doesn't explicitly state when to use this tool versus alternatives like 'create_document' or 'edit_object'. The examples provide contextual guidance but lack explicit 'when-to-use' or 'when-not-to-use' statements that would help an agent choose between sibling tools.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/neka-nat/freecad-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server