[ { "name": "abs", "summary": "Computes the absolute value of a number.", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = abs(-4)" ] }, { "name": "acos", "summary": "Computes the arccosine of a number (in radians).", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = acos(0.5)" ] }, { "name": "angleToMatchLengthX", "summary": "Returns the angle to match the given length for x.", "description": "", "tags": [], "args": [ { "name": "segment_name", "type": "string", "schema": { "type": "string" }, "required": true }, { "name": "to", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part001 = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([1, 3.82], %, 'seg01')\n |> angledLineToX([\n -angleToMatchLengthX('seg01', 10, %),\n 5\n ], %)\n |> close(%)\n |> extrude(5, %)" ] }, { "name": "angleToMatchLengthY", "summary": "Returns the angle to match the given length for y.", "description": "", "tags": [], "args": [ { "name": "segment_name", "type": "string", "schema": { "type": "string" }, "required": true }, { "name": "to", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part001 = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([1, 3.82], %, 'seg01')\n |> angledLineToX([\n -angleToMatchLengthY('seg01', 10, %),\n 5\n ], %)\n |> close(%)\n |> extrude(5, %)" ] }, { "name": "angledLine", "summary": "Draw an angled line.", "description": "", "tags": [], "args": [ { "name": "data", "type": "AngledLineData", "schema": { "description": "Data to draw an angled line.", "anyOf": [ { "description": "An angle and length with explicitly named parameters", "type": "object", "required": [ "angle", "length" ], "properties": { "angle": { "description": "The angle of the line.", "type": "number", "format": "double" }, "length": { "description": "The length of the line.", "type": "number", "format": "double" } } }, { "description": "An angle and length given as a pair", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } ] }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> angledLine({ angle: 45, length: 10 }, %, \"edge1\")\n |> line([10, 10], %)\n |> line([0, 10], %)\n |> close(%, \"edge2\")\n |> extrude(10, %)" ] }, { "name": "angledLineOfXLength", "summary": "Draw an angled line of a given x length.", "description": "", "tags": [], "args": [ { "name": "data", "type": "AngledLineData", "schema": { "description": "Data to draw an angled line.", "anyOf": [ { "description": "An angle and length with explicitly named parameters", "type": "object", "required": [ "angle", "length" ], "properties": { "angle": { "description": "The angle of the line.", "type": "number", "format": "double" }, "length": { "description": "The length of the line.", "type": "number", "format": "double" } } }, { "description": "An angle and length given as a pair", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } ] }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XZ')\n |> startProfileAt([0, 0], %)\n |> angledLineOfXLength({ angle: 45, length: 10 }, %, \"edge1\")\n |> line([10, 10], %)\n |> line([0, 10], %)\n |> close(%, \"edge2\")\n |> extrude(10, %)" ] }, { "name": "angledLineOfYLength", "summary": "Draw an angled line of a given y length.", "description": "", "tags": [], "args": [ { "name": "data", "type": "AngledLineData", "schema": { "description": "Data to draw an angled line.", "anyOf": [ { "description": "An angle and length with explicitly named parameters", "type": "object", "required": [ "angle", "length" ], "properties": { "angle": { "description": "The angle of the line.", "type": "number", "format": "double" }, "length": { "description": "The length of the line.", "type": "number", "format": "double" } } }, { "description": "An angle and length given as a pair", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } ] }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('YZ')\n |> startProfileAt([0, 0], %)\n |> angledLineOfYLength({ angle: 45, length: 10 }, %, \"edge1\")\n |> line([10, 10], %)\n |> line([0, 10], %)\n |> close(%, \"edge2\")\n |> extrude(10, %)\n |> fillet({ radius: 2, tags: [\"edge1\"] }, %)" ] }, { "name": "angledLineThatIntersects", "summary": "Draw an angled line that intersects with a given line.", "description": "", "tags": [], "args": [ { "name": "data", "type": "AngledLineThatIntersectsData", "schema": { "description": "Data for drawing an angled line that intersects with a given line.", "type": "object", "required": [ "angle", "intersectTag" ], "properties": { "angle": { "description": "The angle of the line.", "type": "number", "format": "double" }, "intersectTag": { "description": "The tag of the line to intersect with.", "type": "string" }, "offset": { "description": "The offset from the intersecting line.", "type": "number", "format": "double", "nullable": true } } }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part001 = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> lineTo([2, 2], %, \"yo\")\n |> lineTo([3, 1], %)\n |> angledLineThatIntersects({\n angle: 180,\n intersectTag: 'yo',\n offset: 12\n }, %, \"yo2\")\n |> line([4, 0], %)\n |> close(%, \"yo3\")\n |> extrude(10, %)" ] }, { "name": "angledLineToX", "summary": "Draw an angled line to a given x coordinate.", "description": "", "tags": [], "args": [ { "name": "data", "type": "AngledLineToData", "schema": { "description": "Data to draw an angled line to a point.", "type": "object", "required": [ "angle", "to" ], "properties": { "angle": { "description": "The angle of the line.", "type": "number", "format": "double" }, "to": { "description": "The point to draw to.", "type": "number", "format": "double" } } }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> angledLineToX({ angle: 45, to: 10 }, %, \"edge1\")\n |> line([10, 10], %)\n |> line([0, 10], %)\n |> close(%, \"edge2\")\n |> extrude(10, %)\n |> fillet({ radius: 2, tags: [\"edge1\"] }, %)" ] }, { "name": "angledLineToY", "summary": "Draw an angled line to a given y coordinate.", "description": "", "tags": [], "args": [ { "name": "data", "type": "AngledLineToData", "schema": { "description": "Data to draw an angled line to a point.", "type": "object", "required": [ "angle", "to" ], "properties": { "angle": { "description": "The angle of the line.", "type": "number", "format": "double" }, "to": { "description": "The point to draw to.", "type": "number", "format": "double" } } }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> angledLineToY({ angle: 45, to: 10 }, %, \"edge1\")\n |> line([10, 10], %)\n |> line([0, 10], %)\n |> close(%, \"edge2\")\n |> extrude(10, %)" ] }, { "name": "arc", "summary": "Draw an arc.", "description": "", "tags": [], "args": [ { "name": "data", "type": "ArcData", "schema": { "description": "Data to draw an arc.", "anyOf": [ { "description": "Angles and radius with an optional tag.", "type": "object", "required": [ "angle_end", "angle_start", "radius" ], "properties": { "angle_end": { "description": "The end angle.", "type": "number", "format": "double" }, "angle_start": { "description": "The start angle.", "type": "number", "format": "double" }, "radius": { "description": "The radius.", "type": "number", "format": "double" } } }, { "description": "Center, to and radius with an optional tag.", "type": "object", "required": [ "center", "radius", "to" ], "properties": { "center": { "description": "The center.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "radius": { "description": "The radius.", "type": "number", "format": "double" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } } ] }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('-YZ')\n |> startProfileAt([0, 0], %)\n |> arc({\n angle_start: 0,\n angle_end: 360,\n radius: 10\n }, %, \"edge1\")\n |> extrude(10, %)" ] }, { "name": "asin", "summary": "Computes the arcsine of a number (in radians).", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = asin(0.5)" ] }, { "name": "atan", "summary": "Computes the arctangent of a number (in radians).", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = atan(1.0)" ] }, { "name": "bezierCurve", "summary": "Draw a bezier curve.", "description": "", "tags": [], "args": [ { "name": "data", "type": "BezierData", "schema": { "description": "Data to draw a bezier curve.", "type": "object", "required": [ "control1", "control2", "to" ], "properties": { "control1": { "description": "The first control point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "control2": { "description": "The second control point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> bezierCurve({\n to: [10, 10],\n control1: [5, 0],\n control2: [5, 10]\n }, %, \"edge1\")\n |> close(%)\n |> extrude(10, %)" ] }, { "name": "ceil", "summary": "Computes the smallest integer greater than or equal to a number.", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = ceil(4.5)" ] }, { "name": "circle", "summary": "Sketch a circle.", "description": "", "tags": [], "args": [ { "name": "center", "type": "[number]", "schema": { "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "required": true }, { "name": "radius", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false }, { "name": "sketch_surface_or_group", "type": "SketchSurfaceOrGroup", "schema": { "description": "A sketch surface or a sketch group.", "anyOf": [ { "description": "A sketch group type.", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "required": true } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const circles = startSketchOn('XY')\n |> circle([5, 5], 1, %)\n |> patternLinear2d({\n axis: [1, 1],\n repetitions: 12,\n distance: 3\n }, %)\n\nconst rectangle = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 50], %)\n |> line([50, 0], %)\n |> line([0, -50], %)\n |> close(%)\n |> hole(circles, %)" ] }, { "name": "close", "summary": "Close the current sketch.", "description": "", "tags": [], "args": [ { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XZ')\n |> startProfileAt([0, 0], %)\n |> line([10, 10], %)\n |> line([10, 0], %)\n |> close(%)\n |> extrude(10, %)", "startSketchOn('YZ')\n |> startProfileAt([0, 0], %)\n |> line([10, 10], %)\n |> line([10, 0], %)\n |> close(%, \"edge1\")\n |> extrude(10, %)" ] }, { "name": "cos", "summary": "Computes the cosine of a number (in radians).", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const anotherVar = cos(2 * pi())" ] }, { "name": "e", "summary": "Return the value of Euler’s number `e`.", "description": "", "tags": [ "math" ], "args": [], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = e()" ] }, { "name": "extrude", "summary": "Extrudes by a given amount.", "description": "", "tags": [], "args": [ { "name": "length", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "sketch_group_set", "type": "SketchGroupSet", "schema": { "description": "A sketch group or a group of sketch groups.", "oneOf": [ { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "type": { "type": "string", "enum": [ "sketchGroup" ] }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "type": [ "object", "array" ], "items": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": [ "type" ], "properties": { "type": { "type": "string", "enum": [ "sketchGroups" ] } } } ] }, "required": true } ], "returnValue": { "name": "", "type": "ExtrudeGroupSet", "schema": { "description": "A extrude group or a group of extrude groups.", "oneOf": [ { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "type": { "type": "string", "enum": [ "extrudeGroup" ] }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "type": [ "object", "array" ], "items": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": [ "type" ], "properties": { "type": { "type": "string", "enum": [ "extrudeGroups" ] } } } ] }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 10], %)\n |> line([10, 0], %)\n |> line([0, -10], %)\n |> close(%)\n |> extrude(5, %)" ] }, { "name": "fillet", "summary": "Create fillets on tagged paths.", "description": "", "tags": [], "args": [ { "name": "data", "type": "FilletData", "schema": { "description": "Data for fillets.", "type": "object", "required": [ "radius", "tags" ], "properties": { "radius": { "description": "The radius of the fillet.", "type": "number", "format": "double" }, "tags": { "description": "The tags of the paths you want to fillet.", "type": "array", "items": { "description": "A string or a uuid.", "anyOf": [ { "description": "A uuid of an edge.", "type": "string", "format": "uuid" }, { "description": "A tag name of an edge.", "type": "string" } ] } } } }, "required": true }, { "name": "extrude_group", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part001 = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 10], %, \"thing\")\n |> line([10, 0], %)\n |> line([0, -10], %, \"thing2\")\n |> close(%)\n |> extrude(10, %)\n |> fillet({ radius: 2, tags: [\"thing\", \"thing2\"] }, %)" ] }, { "name": "floor", "summary": "Computes the largest integer less than or equal to a number.", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = floor(4.5)" ] }, { "name": "getEdge", "summary": "Get an edge on a 3D solid.", "description": "", "tags": [], "args": [ { "name": "tag", "type": "String", "schema": { "type": "string" }, "required": true }, { "name": "extrude_group", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "Uuid", "schema": { "type": "string", "format": "uuid" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const box = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 10], %)\n |> line([10, 0], %)\n |> line([0, -10], %, 'revolveAxis')\n |> close(%)\n |> extrude(10, %)\n\nconst sketch001 = startSketchOn('XY')\n |> startProfileAt([0, -10], %)\n |> line([0, -10], %)\n |> line([2, 0], %)\n |> line([0, 10], %)\n |> close(%)\n |> revolve({\n axis: getEdge('revolveAxis', box),\n angle: 90\n }, %)" ] }, { "name": "getExtrudeWallTransform", "summary": "Returns the extrude wall transform.", "description": "", "tags": [], "args": [ { "name": "surface_name", "type": "string", "schema": { "type": "string" }, "required": true }, { "name": "extrude_group", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "ExtrudeTransform", "schema": { "type": "object", "required": [ "__meta", "position", "rotation" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "position": { "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const box = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 10], %)\n |> line([10, 0], %)\n |> line([0, -10], %, \"surface\")\n |> close(%)\n |> extrude(5, %)\n\nconst transform = getExtrudeWallTransform('surface', box)" ] }, { "name": "getNextAdjacentEdge", "summary": "Get the next adjacent edge to the edge given.", "description": "", "tags": [], "args": [ { "name": "tag", "type": "String", "schema": { "type": "string" }, "required": true }, { "name": "extrude_group", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "Uuid", "schema": { "type": "string", "format": "uuid" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part001 = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 10], %, \"thing\")\n |> line([10, 0], %, \"thing1\")\n |> line([0, -10], %, \"thing2\")\n |> close(%, \"thing3\")\n |> extrude(10, %)\n |> fillet({\n radius: 2,\n tags: [getNextAdjacentEdge(\"thing3\", %)]\n }, %)" ] }, { "name": "getOppositeEdge", "summary": "Get the opposite edge to the edge given.", "description": "", "tags": [], "args": [ { "name": "tag", "type": "String", "schema": { "type": "string" }, "required": true }, { "name": "extrude_group", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "Uuid", "schema": { "type": "string", "format": "uuid" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part001 = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 10], %, \"thing\")\n |> line([10, 0], %)\n |> line([0, -10], %, \"thing2\")\n |> close(%)\n |> extrude(10, %)\n |> fillet({\n radius: 2,\n tags: [\"thing\", getOppositeEdge(\"thing\", %)]\n }, %)" ] }, { "name": "getPreviousAdjacentEdge", "summary": "Get the previous adjacent edge to the edge given.", "description": "", "tags": [], "args": [ { "name": "tag", "type": "String", "schema": { "type": "string" }, "required": true }, { "name": "extrude_group", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "Uuid", "schema": { "type": "string", "format": "uuid" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part001 = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 10], %, \"thing\")\n |> line([10, 0], %, \"thing1\")\n |> line([0, -10], %, \"thing2\")\n |> close(%, \"thing3\")\n |> extrude(10, %)\n |> fillet({\n radius: 2,\n tags: [getPreviousAdjacentEdge(\"thing3\", %)]\n }, %)" ] }, { "name": "helix", "summary": "Create a helix on a cylinder.", "description": "", "tags": [], "args": [ { "name": "data", "type": "HelixData", "schema": { "description": "Data for helices.", "type": "object", "required": [ "angle_start", "revolutions" ], "properties": { "angle_start": { "description": "Start angle (in degrees).", "type": "number", "format": "double" }, "ccw": { "description": "Is the helix rotation counter clockwise? The default is `false`.", "default": false, "type": "boolean" }, "length": { "description": "Length of the helix. If this argument is not provided, the height of the extrude group is used.", "type": "number", "format": "double", "nullable": true }, "revolutions": { "description": "Number of revolutions.", "type": "number", "format": "double" } } }, "required": true }, { "name": "extrude_group", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part001 = startSketchOn('XY')\n |> circle([5, 5], 10, %)\n |> extrude(10, %)\n |> helix({ revolutions: 16, angle_start: 0 }, %)" ] }, { "name": "hole", "summary": "Use a sketch to cut a hole in another sketch.", "description": "", "tags": [], "args": [ { "name": "hole_sketch_group", "type": "SketchGroupSet", "schema": { "description": "A sketch group or a group of sketch groups.", "oneOf": [ { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "type": { "type": "string", "enum": [ "sketchGroup" ] }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "type": [ "object", "array" ], "items": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": [ "type" ], "properties": { "type": { "type": "string", "enum": [ "sketchGroups" ] } } } ] }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const square = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 10], %)\n |> line([10, 0], %)\n |> line([0, -10], %)\n |> close(%)\n |> hole(circle([2, 2], .5, %), %)\n |> hole(circle([2, 8], .5, %), %)\n |> extrude(2, %)" ] }, { "name": "import", "summary": "Import a CAD file.", "description": "For formats lacking unit data (STL, OBJ, PLY), the default import unit is millimeters. Otherwise you can specify the unit by passing in the options parameter. If you import a gltf file, we will try to find the bin file and import it as well.\nImport paths are relative to the current project directory. This only works in the desktop app not in browser.", "tags": [ "norun" ], "args": [ { "name": "file_path", "type": "String", "schema": { "type": "string" }, "required": true }, { "name": "options", "type": "ImportFormat", "schema": { "description": "Import format specifier", "oneOf": [ { "description": "Autodesk Filmbox (FBX) format", "type": "object", "required": [ "type" ], "properties": { "type": { "type": "string", "enum": [ "fbx" ] } } }, { "description": "Binary glTF 2.0. We refer to this as glTF since that is how our customers refer to it, but this can also import binary glTF (glb).", "type": "object", "required": [ "type" ], "properties": { "type": { "type": "string", "enum": [ "gltf" ] } } }, { "description": "Wavefront OBJ format.", "type": "object", "required": [ "type", "units" ], "properties": { "coords": { "description": "Co-ordinate system of input data. Defaults to the [KittyCAD co-ordinate system.", "type": "object", "required": [ "forward", "up" ], "properties": { "forward": { "description": "Axis the front face of a model looks along.", "type": "object", "required": [ "axis", "direction" ], "properties": { "axis": { "description": "Axis specifier.", "oneOf": [ { "description": "'Y' axis.", "type": "string", "enum": [ "y" ] }, { "description": "'Z' axis.", "type": "string", "enum": [ "z" ] } ] }, "direction": { "description": "Specifies which direction the axis is pointing.", "oneOf": [ { "description": "Increasing numbers.", "type": "string", "enum": [ "positive" ] }, { "description": "Decreasing numbers.", "type": "string", "enum": [ "negative" ] } ] } } }, "up": { "description": "Axis pointing up and away from a model.", "type": "object", "required": [ "axis", "direction" ], "properties": { "axis": { "description": "Axis specifier.", "oneOf": [ { "description": "'Y' axis.", "type": "string", "enum": [ "y" ] }, { "description": "'Z' axis.", "type": "string", "enum": [ "z" ] } ] }, "direction": { "description": "Specifies which direction the axis is pointing.", "oneOf": [ { "description": "Increasing numbers.", "type": "string", "enum": [ "positive" ] }, { "description": "Decreasing numbers.", "type": "string", "enum": [ "negative" ] } ] } } } }, "nullable": true }, "type": { "type": "string", "enum": [ "obj" ] }, "units": { "description": "The units of the input data. This is very important for correct scaling and when calculating physics properties like mass, etc. Defaults to millimeters.", "oneOf": [ { "description": "Centimeters ", "type": "string", "enum": [ "cm" ] }, { "description": "Feet ", "type": "string", "enum": [ "ft" ] }, { "description": "Inches ", "type": "string", "enum": [ "in" ] }, { "description": "Meters ", "type": "string", "enum": [ "m" ] }, { "description": "Millimeters ", "type": "string", "enum": [ "mm" ] }, { "description": "Yards ", "type": "string", "enum": [ "yd" ] } ] } } }, { "description": "The PLY Polygon File Format.", "type": "object", "required": [ "type", "units" ], "properties": { "coords": { "description": "Co-ordinate system of input data. Defaults to the [KittyCAD co-ordinate system.", "type": "object", "required": [ "forward", "up" ], "properties": { "forward": { "description": "Axis the front face of a model looks along.", "type": "object", "required": [ "axis", "direction" ], "properties": { "axis": { "description": "Axis specifier.", "oneOf": [ { "description": "'Y' axis.", "type": "string", "enum": [ "y" ] }, { "description": "'Z' axis.", "type": "string", "enum": [ "z" ] } ] }, "direction": { "description": "Specifies which direction the axis is pointing.", "oneOf": [ { "description": "Increasing numbers.", "type": "string", "enum": [ "positive" ] }, { "description": "Decreasing numbers.", "type": "string", "enum": [ "negative" ] } ] } } }, "up": { "description": "Axis pointing up and away from a model.", "type": "object", "required": [ "axis", "direction" ], "properties": { "axis": { "description": "Axis specifier.", "oneOf": [ { "description": "'Y' axis.", "type": "string", "enum": [ "y" ] }, { "description": "'Z' axis.", "type": "string", "enum": [ "z" ] } ] }, "direction": { "description": "Specifies which direction the axis is pointing.", "oneOf": [ { "description": "Increasing numbers.", "type": "string", "enum": [ "positive" ] }, { "description": "Decreasing numbers.", "type": "string", "enum": [ "negative" ] } ] } } } }, "nullable": true }, "type": { "type": "string", "enum": [ "ply" ] }, "units": { "description": "The units of the input data. This is very important for correct scaling and when calculating physics properties like mass, etc. Defaults to millimeters.", "oneOf": [ { "description": "Centimeters ", "type": "string", "enum": [ "cm" ] }, { "description": "Feet ", "type": "string", "enum": [ "ft" ] }, { "description": "Inches ", "type": "string", "enum": [ "in" ] }, { "description": "Meters ", "type": "string", "enum": [ "m" ] }, { "description": "Millimeters ", "type": "string", "enum": [ "mm" ] }, { "description": "Yards ", "type": "string", "enum": [ "yd" ] } ] } } }, { "description": "SolidWorks part (SLDPRT) format.", "type": "object", "required": [ "type" ], "properties": { "type": { "type": "string", "enum": [ "sldprt" ] } } }, { "description": "ISO 10303-21 (STEP) format.", "type": "object", "required": [ "type" ], "properties": { "type": { "type": "string", "enum": [ "step" ] } } }, { "description": "ST**ereo**L**ithography format.", "type": "object", "required": [ "type", "units" ], "properties": { "coords": { "description": "Co-ordinate system of input data. Defaults to the [KittyCAD co-ordinate system.", "type": "object", "required": [ "forward", "up" ], "properties": { "forward": { "description": "Axis the front face of a model looks along.", "type": "object", "required": [ "axis", "direction" ], "properties": { "axis": { "description": "Axis specifier.", "oneOf": [ { "description": "'Y' axis.", "type": "string", "enum": [ "y" ] }, { "description": "'Z' axis.", "type": "string", "enum": [ "z" ] } ] }, "direction": { "description": "Specifies which direction the axis is pointing.", "oneOf": [ { "description": "Increasing numbers.", "type": "string", "enum": [ "positive" ] }, { "description": "Decreasing numbers.", "type": "string", "enum": [ "negative" ] } ] } } }, "up": { "description": "Axis pointing up and away from a model.", "type": "object", "required": [ "axis", "direction" ], "properties": { "axis": { "description": "Axis specifier.", "oneOf": [ { "description": "'Y' axis.", "type": "string", "enum": [ "y" ] }, { "description": "'Z' axis.", "type": "string", "enum": [ "z" ] } ] }, "direction": { "description": "Specifies which direction the axis is pointing.", "oneOf": [ { "description": "Increasing numbers.", "type": "string", "enum": [ "positive" ] }, { "description": "Decreasing numbers.", "type": "string", "enum": [ "negative" ] } ] } } } }, "nullable": true }, "type": { "type": "string", "enum": [ "stl" ] }, "units": { "description": "The units of the input data. This is very important for correct scaling and when calculating physics properties like mass, etc. Defaults to millimeters.", "oneOf": [ { "description": "Centimeters ", "type": "string", "enum": [ "cm" ] }, { "description": "Feet ", "type": "string", "enum": [ "ft" ] }, { "description": "Inches ", "type": "string", "enum": [ "in" ] }, { "description": "Meters ", "type": "string", "enum": [ "m" ] }, { "description": "Millimeters ", "type": "string", "enum": [ "mm" ] }, { "description": "Yards ", "type": "string", "enum": [ "yd" ] } ] } } } ], "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "ImportedGeometry", "schema": { "description": "Data for an imported geometry.", "type": "object", "required": [ "__meta", "id", "value" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The ID of the imported geometry.", "type": "string", "format": "uuid" }, "value": { "description": "The original file paths.", "type": "array", "items": { "type": "string" } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const model = import(\"thing.obj\")", "const model = import(\"cube.obj\", { type: \"obj\", units: \"m\" })", "const model = import(\"my_model.gltf\")", "const model = import(\"my_model.sldprt\")", "const model = import(\"my_model.step\")" ] }, { "name": "lastSegX", "summary": "Returns the last segment of x.", "description": "", "tags": [], "args": [ { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn(\"YZ\")\n |> startProfileAt([0, 0], %)\n |> line([5, 0], %, \"thing\")\n |> line([5, 5], %)\n |> line([0, lastSegX(%)], %)\n |> close(%)\n |> extrude(5, %)" ] }, { "name": "lastSegY", "summary": "Returns the last segment of y.", "description": "", "tags": [], "args": [ { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn(\"YZ\")\n |> startProfileAt([0, 0], %)\n |> line([5, 0], %, \"thing\")\n |> line([5, 5], %)\n |> line([0, lastSegY(%)], %)\n |> close(%)\n |> extrude(5, %)" ] }, { "name": "legAngX", "summary": "Returns the angle of the given leg for x.", "description": "", "tags": [ "utilities" ], "args": [ { "name": "hypotenuse", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "leg", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "legAngX(5, 3)" ] }, { "name": "legAngY", "summary": "Returns the angle of the given leg for y.", "description": "", "tags": [ "utilities" ], "args": [ { "name": "hypotenuse", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "leg", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "legAngY(5, 3)" ] }, { "name": "legLen", "summary": "Returns the length of the given leg.", "description": "", "tags": [ "utilities" ], "args": [ { "name": "hypotenuse", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "leg", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "legLen(5, 3)" ] }, { "name": "line", "summary": "Draw a line.", "description": "", "tags": [], "args": [ { "name": "delta", "type": "[number]", "schema": { "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('-XY')\n |> startProfileAt([0, 0], %)\n |> line([10, 10], %)\n |> line([20, 10], %, \"edge1\")\n |> close(%, \"edge2\")\n |> extrude(10, %)" ] }, { "name": "lineTo", "summary": "Draw a line to a point.", "description": "", "tags": [], "args": [ { "name": "to", "type": "[number]", "schema": { "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "fn rectShape = (pos, w, l) => {\n const rr = startSketchOn('YZ')\n |> startProfileAt([pos[0] - (w / 2), pos[1] - (l / 2)], %)\n |> lineTo([pos[0] + w / 2, pos[1] - (l / 2)], %, \"edge1\")\n |> lineTo([pos[0] + w / 2, pos[1] + l / 2], %, \"edge2\")\n |> lineTo([pos[0] - (w / 2), pos[1] + l / 2], %, \"edge3\")\n |> close(%, \"edge4\")\n return rr\n}\n\n// Create the mounting plate extrusion, holes, and fillets\nconst part = rectShape([0, 0], 20, 20)\n |> extrude(10, %)" ] }, { "name": "ln", "summary": "Computes the natural logarithm of the number.", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = ln(4)" ] }, { "name": "log", "summary": "Computes the logarithm of the number with respect to an arbitrary base.", "description": "The result might not be correctly rounded owing to implementation details; `log2()` can produce more accurate results for base 2, and `log10()` can produce more accurate results for base 10.", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "base", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = log(4, 2)" ] }, { "name": "log10", "summary": "Computes the base 10 logarithm of the number.", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = log10(4)" ] }, { "name": "log2", "summary": "Computes the base 2 logarithm of the number.", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = log2(4)" ] }, { "name": "max", "summary": "Computes the maximum of the given arguments.", "description": "", "tags": [ "math" ], "args": [ { "name": "args", "type": "[number]", "schema": { "type": "array", "items": { "type": "number", "format": "double" } }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = max(4, 5, 6)" ] }, { "name": "min", "summary": "Computes the minimum of the given arguments.", "description": "", "tags": [ "math" ], "args": [ { "name": "args", "type": "[number]", "schema": { "type": "array", "items": { "type": "number", "format": "double" } }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = min(4, 5, 6)" ] }, { "name": "patternCircular2d", "summary": "A circular pattern on a 2D sketch.", "description": "", "tags": [], "args": [ { "name": "data", "type": "CircularPattern2dData", "schema": { "description": "Data for a circular pattern on a 2D sketch.", "type": "object", "required": [ "arcDegrees", "center", "repetitions", "rotateDuplicates" ], "properties": { "arcDegrees": { "description": "The arc angle (in degrees) to place the repetitions. Must be greater than 0.", "type": "number", "format": "double" }, "center": { "description": "The center about which to make the pattern. This is a 2D vector.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "repetitions": { "description": "The number of repetitions. Must be greater than 0. This excludes the original entity. For example, if `repetitions` is 1, the original entity will be copied once.", "type": "integer", "format": "uint32", "minimum": 0.0 }, "rotateDuplicates": { "description": "Whether or not to rotate the duplicates as they are copied.", "type": "boolean" } } }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "[SketchGroup]", "schema": { "type": "array", "items": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part = startSketchOn('XY')\n |> circle([0, 0], 2, %)\n |> patternCircular2d({\n center: [20, 20],\n repetitions: 12,\n arcDegrees: 210,\n rotateDuplicates: true\n }, %)\n |> extrude(1, %)" ] }, { "name": "patternCircular3d", "summary": "A circular pattern on a 3D model.", "description": "", "tags": [], "args": [ { "name": "data", "type": "CircularPattern3dData", "schema": { "description": "Data for a circular pattern on a 3D model.", "type": "object", "required": [ "arcDegrees", "axis", "center", "repetitions", "rotateDuplicates" ], "properties": { "arcDegrees": { "description": "The arc angle (in degrees) to place the repetitions. Must be greater than 0.", "type": "number", "format": "double" }, "axis": { "description": "The axis around which to make the pattern. This is a 3D vector.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "center": { "description": "The center about which to make the pattern. This is a 3D vector.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "repetitions": { "description": "The number of repetitions. Must be greater than 0. This excludes the original entity. For example, if `repetitions` is 1, the original entity will be copied once.", "type": "integer", "format": "uint32", "minimum": 0.0 }, "rotateDuplicates": { "description": "Whether or not to rotate the duplicates as they are copied.", "type": "boolean" } } }, "required": true }, { "name": "extrude_group", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "[ExtrudeGroup]", "schema": { "type": "array", "items": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 1], %)\n |> line([1, 0], %)\n |> line([0, -1], %)\n |> close(%)\n |> extrude(1, %)\n |> patternCircular3d({\n axis: [1, 1, 0],\n center: [10, 0, 10],\n repetitions: 10,\n arcDegrees: 360,\n rotateDuplicates: true\n }, %)" ] }, { "name": "patternLinear2d", "summary": "A linear pattern on a 2D sketch.", "description": "", "tags": [], "args": [ { "name": "data", "type": "LinearPattern2dData", "schema": { "description": "Data for a linear pattern on a 2D sketch.", "type": "object", "required": [ "axis", "distance", "repetitions" ], "properties": { "axis": { "description": "The axis of the pattern. This is a 2D vector.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "distance": { "description": "The distance between each repetition. This can also be referred to as spacing.", "type": "number", "format": "double" }, "repetitions": { "description": "The number of repetitions. Must be greater than 0. This excludes the original entity. For example, if `repetitions` is 1, the original entity will be copied once.", "type": "integer", "format": "uint32", "minimum": 0.0 } } }, "required": true }, { "name": "sketch_group_set", "type": "SketchGroupSet", "schema": { "description": "A sketch group or a group of sketch groups.", "oneOf": [ { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "type": { "type": "string", "enum": [ "sketchGroup" ] }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "type": [ "object", "array" ], "items": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": [ "type" ], "properties": { "type": { "type": "string", "enum": [ "sketchGroups" ] } } } ] }, "required": true } ], "returnValue": { "name": "", "type": "[SketchGroup]", "schema": { "type": "array", "items": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part = startSketchOn('XY')\n |> circle([0, 0], 2, %)\n |> patternLinear2d({\n axis: [0, 1],\n repetitions: 12,\n distance: 2\n }, %)\n |> extrude(1, %)" ] }, { "name": "patternLinear3d", "summary": "A linear pattern on a 3D model.", "description": "", "tags": [], "args": [ { "name": "data", "type": "LinearPattern3dData", "schema": { "description": "Data for a linear pattern on a 3D model.", "type": "object", "required": [ "axis", "distance", "repetitions" ], "properties": { "axis": { "description": "The axis of the pattern.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "distance": { "description": "The distance between each repetition. This can also be referred to as spacing.", "type": "number", "format": "double" }, "repetitions": { "description": "The number of repetitions. Must be greater than 0. This excludes the original entity. For example, if `repetitions` is 1, the original entity will be copied once.", "type": "integer", "format": "uint32", "minimum": 0.0 } } }, "required": true }, { "name": "extrude_group", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "[ExtrudeGroup]", "schema": { "type": "array", "items": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 1], %)\n |> line([1, 0], %)\n |> line([0, -1], %)\n |> close(%)\n |> extrude(1, %)\n |> patternLinear3d({\n axis: [1, 0, 1],\n repetitions: 3,\n distance: 6\n }, %)" ] }, { "name": "pi", "summary": "Return the value of `pi`. Archimedes’ constant (π).", "description": "", "tags": [ "math" ], "args": [], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = pi() * 3.0" ] }, { "name": "pow", "summary": "Computes the number to a power.", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "pow", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = pow(4, 2)" ] }, { "name": "revolve", "summary": "Revolve a sketch around an axis.", "description": "", "tags": [], "args": [ { "name": "data", "type": "RevolveData", "schema": { "description": "Data for revolution surfaces.", "type": "object", "required": [ "axis" ], "properties": { "angle": { "description": "Angle to revolve (in degrees). Default is 360.", "default": null, "type": "number", "format": "double", "nullable": true }, "axis": { "description": "Axis of revolution.", "anyOf": [ { "description": "Axis of revolution.", "oneOf": [ { "description": "X-axis.", "type": "string", "enum": [ "X" ] }, { "description": "Y-axis.", "type": "string", "enum": [ "Y" ] }, { "description": "Z-axis.", "type": "string", "enum": [ "Z" ] }, { "description": "Flip the X-axis.", "type": "string", "enum": [ "-X" ] }, { "description": "Flip the Y-axis.", "type": "string", "enum": [ "-Y" ] }, { "description": "Flip the Z-axis.", "type": "string", "enum": [ "-Z" ] }, { "type": "object", "required": [ "custom" ], "properties": { "custom": { "type": "object", "required": [ "axis", "origin" ], "properties": { "axis": { "description": "The axis.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "origin": { "description": "The origin.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 } } } }, "additionalProperties": false } ] }, { "description": "Tagged edge.", "anyOf": [ { "description": "A uuid of an edge.", "type": "string", "format": "uuid" }, { "description": "A tag name of an edge.", "type": "string" } ] } ] } } }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "ExtrudeGroup", "schema": { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part001 = startSketchOn('XY')\n |> startProfileAt([4, 12], %)\n |> line([2, 0], %)\n |> line([0, -6], %)\n |> line([4, -6], %)\n |> line([0, -6], %)\n |> line([-3.75, -4.5], %)\n |> line([0, -5.5], %)\n |> line([-2, 0], %)\n |> close(%)\n |> revolve({ axis: 'y' }, %) // default angle is 360", "// A donut shape.\nconst sketch001 = startSketchOn('XY')\n |> circle([15, 0], 5, %)\n |> revolve({ angle: 360, axis: 'y' }, %)", "const part001 = startSketchOn('XY')\n |> startProfileAt([4, 12], %)\n |> line([2, 0], %)\n |> line([0, -6], %)\n |> line([4, -6], %)\n |> line([0, -6], %)\n |> line([-3.75, -4.5], %)\n |> line([0, -5.5], %)\n |> line([-2, 0], %)\n |> close(%)\n |> revolve({ axis: 'y', angle: 180 }, %)", "const part001 = startSketchOn('XY')\n |> startProfileAt([4, 12], %)\n |> line([2, 0], %)\n |> line([0, -6], %)\n |> line([4, -6], %)\n |> line([0, -6], %)\n |> line([-3.75, -4.5], %)\n |> line([0, -5.5], %)\n |> line([-2, 0], %)\n |> close(%)\n |> revolve({ axis: 'y', angle: 180 }, %)\nconst part002 = startSketchOn(part001, 'end')\n |> startProfileAt([4.5, -5], %)\n |> line([0, 5], %)\n |> line([5, 0], %)\n |> line([0, -5], %)\n |> close(%)\n |> extrude(5, %)", "const box = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 20], %)\n |> line([20, 0], %)\n |> line([0, -20], %)\n |> close(%)\n |> extrude(20, %)\n\nconst sketch001 = startSketchOn(box, \"END\")\n |> circle([10, 10], 4, %)\n |> revolve({ angle: -90, axis: 'y' }, %)", "const box = startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([0, 20], %)\n |> line([20, 0], %)\n |> line([0, -20], %, 'revolveAxis')\n |> close(%)\n |> extrude(20, %)\n\nconst sketch001 = startSketchOn(box, \"END\")\n |> circle([10, 10], 4, %)\n |> revolve({\n angle: 90,\n axis: getOppositeEdge('revolveAxis', box)\n }, %)" ] }, { "name": "segAng", "summary": "Returns the angle of the segment.", "description": "", "tags": [], "args": [ { "name": "segment_name", "type": "string", "schema": { "type": "string" }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const part001 = startSketchOn('XY')\n |> startProfileAt([4.83, 12.56], %)\n |> line([15.1, 2.48], %)\n |> line([3.15, -9.85], %, 'seg01')\n |> line([-15.17, -4.1], %)\n |> angledLine([segAng('seg01', %), 12.35], %)\n |> line([-13.02, 10.03], %)\n |> close(%)\n |> extrude(4, %)" ] }, { "name": "segEndX", "summary": "Returns the segment end of x.", "description": "", "tags": [], "args": [ { "name": "segment_name", "type": "string", "schema": { "type": "string" }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn(\"YZ\")\n |> startProfileAt([0, 0], %)\n |> line([5, 0], %, \"thing\")\n |> line([5, 5], %)\n |> line([segEndX(\"thing\", %), 5], %)\n |> close(%)\n |> extrude(5, %)" ] }, { "name": "segEndY", "summary": "Returns the segment end of y.", "description": "", "tags": [], "args": [ { "name": "segment_name", "type": "string", "schema": { "type": "string" }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn(\"YZ\")\n |> startProfileAt([0, 0], %)\n |> line([5, 0], %, \"thing\")\n |> line([5, 5], %)\n |> line([segEndY(\"thing\", %), 5], %)\n |> close(%)\n |> extrude(5, %)" ] }, { "name": "segLen", "summary": "Returns the length of the segment.", "description": "", "tags": [], "args": [ { "name": "segment_name", "type": "string", "schema": { "type": "string" }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn(\"YZ\")\n |> startProfileAt([0, 0], %)\n |> line([5, 0], %, \"thing\")\n |> line([5, 5], %)\n |> line([0, segLen(\"thing\", %)], %)\n |> close(%)\n |> extrude(5, %)" ] }, { "name": "sin", "summary": "Computes the sine of a number (in radians).", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = sin(2 * pi())" ] }, { "name": "sqrt", "summary": "Computes the square root of a number.", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = sqrt(4)" ] }, { "name": "startProfileAt", "summary": "Start a profile at a given point.", "description": "", "tags": [], "args": [ { "name": "to", "type": "[number]", "schema": { "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "required": true }, { "name": "sketch_surface", "type": "SketchSurface", "schema": { "description": "A sketch group type.", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([10, 10], %)\n |> line([10, 0], %)\n |> close(%)\n |> extrude(10, %)" ] }, { "name": "startSketchAt", "summary": "Start a sketch at a given point on the 'XY' plane.", "description": "", "tags": [], "args": [ { "name": "data", "type": "[number]", "schema": { "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "required": true } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchAt([0, 0])\n |> line([10, 10], %)\n |> line([20, 10], %, \"edge1\")\n |> close(%, \"edge2\")\n |> extrude(10, %)" ] }, { "name": "startSketchOn", "summary": "Start a sketch on a specific plane or face.", "description": "", "tags": [], "args": [ { "name": "data", "type": "SketchData", "schema": { "description": "Data for start sketch on. You can start a sketch on a plane or an extrude group.", "anyOf": [ { "description": "Data for a plane.", "oneOf": [ { "description": "The XY plane.", "type": "string", "enum": [ "XY" ] }, { "description": "The opposite side of the XY plane.", "type": "string", "enum": [ "-XY" ] }, { "description": "The XZ plane.", "type": "string", "enum": [ "XZ" ] }, { "description": "The opposite side of the XZ plane.", "type": "string", "enum": [ "-XZ" ] }, { "description": "The YZ plane.", "type": "string", "enum": [ "YZ" ] }, { "description": "The opposite side of the YZ plane.", "type": "string", "enum": [ "-YZ" ] }, { "description": "A defined plane.", "type": "object", "required": [ "plane" ], "properties": { "plane": { "type": "object", "required": [ "origin", "x_axis", "y_axis", "z_axis" ], "properties": { "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "x_axis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "y_axis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "z_axis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } }, "additionalProperties": false } ] }, { "description": "An extrude group is a collection of extrude surfaces.", "type": "object", "required": [ "__meta", "height", "id", "position", "rotation", "sketchGroupValues", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "endCapId": { "description": "The id of the extrusion end cap", "type": "string", "format": "uuid", "nullable": true }, "height": { "description": "The height of the extrude group.", "type": "number", "format": "double" }, "id": { "description": "The id of the extrude group.", "type": "string", "format": "uuid" }, "position": { "description": "The position of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the extrude group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sketchGroupValues": { "description": "The sketch group paths.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "startCapId": { "description": "The id of the extrusion start cap", "type": "string", "format": "uuid", "nullable": true }, "value": { "description": "The extrude surfaces.", "type": "array", "items": { "description": "An extrude surface.", "oneOf": [ { "description": "An extrude plane.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudePlane" ] } } }, { "description": "An extruded arc.", "type": "object", "required": [ "faceId", "id", "name", "position", "rotation", "sourceRange", "type" ], "properties": { "faceId": { "description": "The face id for the extrude plane.", "type": "string", "format": "uuid" }, "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "name": { "description": "The name.", "type": "string" }, "position": { "description": "The position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "extrudeArc" ] } } } ] } }, "xAxis": { "description": "The x-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the extrude group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "required": true }, { "name": "tag", "type": "SketchOnFaceTag", "schema": { "description": "A tag for sketch on face.", "anyOf": [ { "oneOf": [ { "description": "The start face as in before you extruded. This could also be known as the bottom face. But we do not call it bottom because it would be the top face if you extruded it in the opposite direction or flipped the camera.", "type": "string", "enum": [ "start" ] }, { "description": "The end face after you extruded. This could also be known as the top face. But we do not call it top because it would be the bottom face if you extruded it in the opposite direction or flipped the camera.", "type": "string", "enum": [ "end" ] } ] }, { "description": "A string tag for the face you want to sketch on.", "type": "string" } ], "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchSurface", "schema": { "description": "A sketch group type.", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> line([10, 10], %)\n |> line([20, 10], %, \"edge1\")\n |> close(%, \"edge2\")\n |> extrude(10, %)", "fn cube = (pos, scale) => {\n const sg = startSketchOn('XY')\n |> startProfileAt(pos, %)\n |> line([0, scale], %)\n |> line([scale, 0], %)\n |> line([0, -scale], %)\n |> close(%)\n |> extrude(scale, %)\n\n return sg\n}\n\nconst box = cube([0, 0], 20)\n\nconst part001 = startSketchOn(box, \"start\")\n |> startProfileAt([0, 0], %)\n |> line([10, 10], %)\n |> line([20, 10], %, \"edge1\")\n |> close(%)\n |> extrude(20, %)" ] }, { "name": "tan", "summary": "Computes the tangent of a number (in radians).", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = tan(2 * pi())" ] }, { "name": "tangentialArc", "summary": "Draw an arc.", "description": "", "tags": [], "args": [ { "name": "data", "type": "TangentialArcData", "schema": { "description": "Data to draw a tangential arc.", "anyOf": [ { "type": "object", "required": [ "offset", "radius" ], "properties": { "offset": { "description": "Offset of the arc, in degrees.", "type": "number", "format": "double" }, "radius": { "description": "Radius of the arc. Not to be confused with Raiders of the Lost Ark.", "type": "number", "format": "double" } } }, { "description": "A point where the arc should end. Must lie in the same plane as the current path pen position. Must not be colinear with current path pen position.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } ] }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('-YZ')\n |> startProfileAt([0, 0], %)\n |> line([10, 10], %, \"edge1\")\n |> tangentialArc({ radius: 10, offset: 90 }, %, \"edge1\")\n |> close(%)\n |> extrude(10, %)" ] }, { "name": "tangentialArcTo", "summary": "Draw an arc.", "description": "", "tags": [], "args": [ { "name": "to", "type": "[number]", "schema": { "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('-YZ')\n |> startProfileAt([0, 0], %)\n |> line([10, 10], %, \"edge0\")\n |> tangentialArcTo([10, 0], %)\n |> close(%)\n |> extrude(10, %)" ] }, { "name": "tau", "summary": "Return the value of `tau`. The full circle constant (τ). Equal to 2π.", "description": "", "tags": [ "math" ], "args": [], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = tau()" ] }, { "name": "toDegrees", "summary": "Converts a number from radians to degrees.", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = toDegrees(2 * pi())" ] }, { "name": "toRadians", "summary": "Converts a number from degrees to radians.", "description": "", "tags": [ "math" ], "args": [ { "name": "num", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true } ], "returnValue": { "name": "", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "const myVar = toRadians(180)" ] }, { "name": "xLine", "summary": "Draw a line on the x-axis.", "description": "", "tags": [], "args": [ { "name": "length", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('YZ')\n |> startProfileAt([0, 0], %)\n |> xLine(10, %)\n |> line([10, 10], %)\n |> close(%, \"edge1\")\n |> extrude(10, %)" ] }, { "name": "xLineTo", "summary": "Draw a line to a point on the x-axis.", "description": "", "tags": [], "args": [ { "name": "to", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> xLineTo(10, %, \"edge1\")\n |> line([10, 10], %)\n |> close(%, \"edge2\")\n |> extrude(10, %)" ] }, { "name": "yLine", "summary": "Draw a line on the y-axis.", "description": "", "tags": [], "args": [ { "name": "length", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XY')\n |> startProfileAt([0, 0], %)\n |> yLine(10, %)\n |> line([10, 10], %)\n |> close(%, \"edge1\")\n |> extrude(10, %)" ] }, { "name": "yLineTo", "summary": "Draw a line to a point on the y-axis.", "description": "", "tags": [], "args": [ { "name": "to", "type": "number", "schema": { "type": "number", "format": "double" }, "required": true }, { "name": "sketch_group", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, { "name": "tag", "type": "String", "schema": { "type": "string", "nullable": true }, "required": false } ], "returnValue": { "name": "", "type": "SketchGroup", "schema": { "description": "A sketch group is a collection of paths.", "type": "object", "required": [ "__meta", "id", "on", "position", "rotation", "start", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "description": "Metadata.", "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "entityId": { "description": "The plane id or face id of the sketch group.", "type": "string", "format": "uuid", "nullable": true }, "id": { "description": "The id of the sketch group.", "type": "string", "format": "uuid" }, "on": { "description": "What the sketch is on (can be a plane or a face).", "oneOf": [ { "description": "A plane.", "type": "object", "required": [ "__meta", "id", "origin", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "id": { "description": "The id of the plane.", "type": "string", "format": "uuid" }, "origin": { "description": "Origin of the plane.", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "type": { "type": "string", "enum": [ "plane" ] }, "value": { "description": "Type for a plane.", "oneOf": [ { "type": "string", "enum": [ "XY", "XZ", "YZ" ] }, { "description": "A custom plane.", "type": "string", "enum": [ "Custom" ] } ] }, "xAxis": { "description": "What should the plane’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the plane’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, { "description": "A face.", "type": "object", "required": [ "__meta", "faceId", "id", "sketchGroupId", "type", "value", "xAxis", "yAxis", "zAxis" ], "properties": { "__meta": { "type": "array", "items": { "description": "Metadata.", "type": "object", "required": [ "sourceRange" ], "properties": { "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } } }, "faceId": { "description": "the face id the sketch is on", "type": "string", "format": "uuid" }, "id": { "description": "The id of the face.", "type": "string", "format": "uuid" }, "sketchGroupId": { "description": "The original sketch group id of the object we are sketching on.", "type": "string", "format": "uuid" }, "type": { "type": "string", "enum": [ "face" ] }, "value": { "description": "The tag of the face.", "type": "string" }, "xAxis": { "description": "What should the face’s X axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "What should the face’s Y axis be?", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis (normal).", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } } ] }, "position": { "description": "The position of the sketch group.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 3, "minItems": 3 }, "rotation": { "description": "The rotation of the sketch group base plane.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 4, "minItems": 4 }, "start": { "description": "The starting path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 } } }, "value": { "description": "The paths in the sketch group.", "type": "array", "items": { "description": "A path.", "oneOf": [ { "description": "A path that goes to a point.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "ToPoint" ] } } }, { "description": "A arc that is tangential to the last path segment that goes to a point", "type": "object", "required": [ "__geoMeta", "ccw", "center", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "ccw": { "description": "arc's direction", "type": "boolean" }, "center": { "description": "the arc's center", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArcTo" ] } } }, { "description": "A arc that is tangential to the last path segment", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "TangentialArc" ] } } }, { "description": "A path that is horizontal.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type", "x" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Horizontal" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double" } } }, { "description": "An angled line to.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "AngledLineTo" ] }, "x": { "description": "The x coordinate.", "type": "number", "format": "double", "nullable": true }, "y": { "description": "The y coordinate.", "type": "number", "format": "double", "nullable": true } } }, { "description": "A base path.", "type": "object", "required": [ "__geoMeta", "from", "name", "to", "type" ], "properties": { "__geoMeta": { "description": "Metadata.", "type": "object", "required": [ "id", "sourceRange" ], "properties": { "id": { "description": "The id of the geometry.", "type": "string", "format": "uuid" }, "sourceRange": { "description": "The source range.", "type": "array", "items": { "type": "integer", "format": "uint", "minimum": 0.0 }, "maxItems": 2, "minItems": 2 } } }, "from": { "description": "The from point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "name": { "description": "The name of the path.", "type": "string" }, "to": { "description": "The to point.", "type": "array", "items": { "type": "number", "format": "double" }, "maxItems": 2, "minItems": 2 }, "type": { "type": "string", "enum": [ "Base" ] } } } ] } }, "xAxis": { "description": "The x-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "yAxis": { "description": "The y-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } }, "zAxis": { "description": "The z-axis of the sketch group base plane in the 3D space", "type": "object", "required": [ "x", "y", "z" ], "properties": { "x": { "type": "number", "format": "double" }, "y": { "type": "number", "format": "double" }, "z": { "type": "number", "format": "double" } } } } }, "required": true }, "unpublished": false, "deprecated": false, "examples": [ "startSketchOn('XZ')\n |> startProfileAt([0, 0], %)\n |> yLineTo(10, %, \"edge1\")\n |> line([10, 10], %)\n |> close(%, \"edge2\")\n |> extrude(10, %)\n |> fillet({ radius: 2, tags: [\"edge2\"] }, %)" ] } ]