Scripting API
Accessories
Every smart component in Artisan’s Components family can be created from a script. Each facade mirrors its panel’s Accept button exactly — same custom object type, same destination layer, same metal material — and the result is the same editable component the panel inserts. Each has its own page.
BailThe pendant bail, with optional O-ring.
BangleA bangle from width, height and aperture — open or closed.
BeadA bead with its stringing hole, square or round.
CharmA charm from a profile asset.
LinkA chain link, with optional twist.
Named pendantA name written as a solid, editable pendant.
HingeCut a hinge into an existing solid.
MilgrainA run of beads along a curve.
RopeTwisted strands along a curve.
VoronoiFill a closed curve with a Voronoi pattern.
HoneycombFill a closed curve with hexagonal cells.
Texture 3DEmboss a grayscale heightmap onto a surface.
ChainRepeat objects along a curve.
HuggieThe huggie earring — closed with hinge, or opened with post.
PatternA grid of copies, optionally flowed onto a surface.
Profile sweepA parametric sweep through closed profile curves.
User elementTag a selection as a named, Outliner-listed element.
EngravingText engraved around a ring band.
What each one starts from
The first thing to know about a component is what you have to give it. That decides whether you can build it out of nothing or whether something must already exist in the document.
| Starts from | Components |
|---|---|
| A plane — free-standing, built out of nothing | Bail, Bangle, Bead, Charm, Link, Named pendant, Huggie, Engraving |
| A curve | Milgrain, Rope, Voronoi, Honeycomb, Chain |
| A surface | Texture 3D |
| An existing solid or object | Hinge, Pattern, Profile sweep, User element |
In the free-standing components, an omitted or invalid plane uses the active view’s construction plane.
Conventions
The 0-keeps-default convention: every numeric parameter accepts 0 to mean “use the tool’s default (or my saved defaults)”. The exceptions are the parameters where 0 is itself meaningful — Link’s twistAngle, Hinge’s openingAngle, Huggie’s aperturePercentage, Pattern’s reverseMode and Profile sweep’s continuities — which use -1 instead.
profile does not mean the same thing everywhere: Bail and Bangle take a RING_PROFILE asset name, Charm takes a CHARM_PROFILE one, and Bead takes a fixed "SQUARE" / "ROUND" vocabulary rather than an asset at all.
What comes back
Unlike the gemsets and shanks, these facades hand back plain object ids, not parametric handles — there is no All(), no Find(id) and no setter to re-edit the component afterwards. Re-open it in its panel to change it, or delete and rebuild. The one exception is UserElementApi.List(), which names the elements in the document.
- All of these are licensed mutations — wrap them in a
Transactionfor one-step undo. - Passing an id that isn’t the expected kind fails with a clear message (“Object … is not a curve.”), and a computation that can’t succeed with the given inputs raises ”… computation failed” naming the tool.
Where the results land
Most components route their geometry to the metal layer with the document’s metal material, exactly like the panel’s Accept — but not all of them, and the difference matters if you are building a pipeline that expects everything on one layer.
| Lands on | Components |
|---|---|
| Metal layer, metal material — the norm | Bangle, Bead, Charm, Link, Milgrain, Rope, Huggie, Texture 3D, Engraving (its solid text; the curves go to the user layer) |
| Metal material, but the current layer | Bail, Named pendant |
| The source object’s attributes — layer, colour and material inherited | Hinge, Chain |
| Default attributes — no layer routing, no material | Pattern, Profile sweep |
| Mixed | Voronoi, Honeycomb — only some result shapes become editable components with the metal material; Honeycomb’s lattice curves land on the secondary object layer with default attributes |