API Reference
Command
New-ImageTopology
Creates a topology diagram image.
Remarks
Renders ChartForgeX topology definitions to PNG, SVG, HTML, GIF, or APNG output. GIF and APNG sample the route configured by Motion.
Examples
Create a service topology diagram
PS>
New-ImageTopology -TopologyDefinition {
New-ImageTopologyNode -Id api -Label API -Kind Service -Status Healthy -Symbol API
New-ImageTopologyNode -Id db -Label Database -Kind Database -Status Warning -Symbol SQL
New-ImageTopologyEdge -SourceNodeId api -TargetNodeId db -Label '32 ms' -Kind Dependency -Status Warning -Direction Forward
} -Title 'Service map' -Layout Layered -Direction LeftToRight -FilePath service-map.png
Creates a transparent-ready PNG topology diagram from a PowerShell DSL.
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.
Syntax
New-ImageTopology [-ActiveScenarioId <String>] [-CanvasSurfaceStyle <Plain|Panel|PanelGrid>] [-Direction <TopToBottom|LeftToRight|BottomToTop|RightToLeft>] -FilePath <String> [-FitContentToViewport] [-Height <Int32>] [-InteractiveHtml] [-Layout <Manual>] [-Motion <TopologyMotionOptions>] [-NodeDisplayMode <Card>] [-NoEdgeLabels] [-NoGroups] [-NoLegend] [-NoScenarioControls] [-NoScenarioPanel] [-NoStatusBadges] [-NoTitle] [-Padding <Int32>] [-PassThru] [-ScenarioControlMode <Buttons|Checkboxes>] [-ScenarioDefinition <ScriptBlock>] [-ScenarioUrlState] [-Show] [-Subtitle <String>] [-Theme <Light|Dark>] [-Title <String>] -TopologyDefinition <ScriptBlock> [-Transparent] [-VisualStyle <Default|MonitoringDashboard>] [-Width <Int32>] [<CommonParameters>]#Parameter set:
ScriptBlockParameters
- ActiveScenarioId String
- Scenario activated for static highlighting or when interactive HTML first loads.
- CanvasSurfaceStyle TopologyCanvasSurfaceStyle
- Canvas surface style.
- Possible values:
Plain,Panel,PanelGrid - Direction TopologyLayoutDirection
- Topology layout direction.
- Possible values:
TopToBottom,LeftToRight,BottomToTop,RightToLeft - FilePath String
- Output file path. The extension selects PNG, SVG, HTML, GIF, or APNG output.
- FitContentToViewport SwitchParameter
- Scale topology content down to remain inside the requested viewport.
- Height Int32
- Viewport height in pixels.
- InteractiveHtml SwitchParameter
- Enable lightweight interactions for HTML output.
- Layout TopologyLayoutMode
- Topology layout mode.
- Possible values:
Manual,GroupGrid,HubAndSpoke,Layered,Matrix,DenseGrouped,Geographic,ForceDirected,RelationshipRadial,MindMap - Motion TopologyMotionOptions
- Script-free route motion used by SVG, GIF, APNG, and sampled PNG output.
- NodeDisplayMode TopologyNodeDisplayMode
- Node presentation mode.
- Possible values:
Card,CompactCard,Tile,Pill,Icon,Artwork,Dot,Hidden - NoEdgeLabels SwitchParameter
- Hide edge labels.
- NoGroups SwitchParameter
- Hide topology groups.
- NoLegend SwitchParameter
- Hide the topology legend.
- NoScenarioControls SwitchParameter
- Hide scenario controls in interactive HTML output.
- NoScenarioPanel SwitchParameter
- Hide the compact scenario detail panel in interactive HTML output.
- NoStatusBadges SwitchParameter
- Hide status badges.
- NoTitle SwitchParameter
- Hide the topology title.
- Padding Int32
- Viewport padding in pixels.
- PassThru SwitchParameter
- Write the generated topology chart to the pipeline after rendering.
- ScenarioControlMode TopologyHtmlScenarioControlMode
- Scenario control presentation used by interactive HTML output.
- Possible values:
Buttons,Checkboxes - ScenarioDefinition ScriptBlock
- Script block that emits topology scenarios.
- ScenarioUrlState SwitchParameter
- Synchronize the active scenario with the HTML page query string.
- Show SwitchParameter
- Open the generated file after creation.
- Subtitle String
- Topology subtitle.
- Theme String
- Topology theme name.
- Possible values:
Light,Dark - Title String
- Topology title.
- TopologyDefinition ScriptBlock
- Script block that emits topology groups, nodes, edges, or a topology chart.
- Transparent SwitchParameter
- Use a transparent diagram canvas.
- VisualStyle TopologyVisualStyle
- Reusable visual style.
- Possible values:
Default,MonitoringDashboard - Width Int32
- Viewport width in pixels.
Outputs
ChartForgeX.Topology.TopologyChart
New-ImageTopology [-ActiveScenarioId <String>] [-CanvasSurfaceStyle <Plain|Panel|PanelGrid>] [-Chart <TopologyChart>] [-Definition <Object[]>] [-Direction <TopToBottom|LeftToRight|BottomToTop|RightToLeft>] [-Edge <TopologyEdge[]>] -FilePath <String> [-FitContentToViewport] [-Group <TopologyGroup[]>] [-Height <Int32>] [-InteractiveHtml] [-Layout <Manual>] [-Motion <TopologyMotionOptions>] [-Node <TopologyNode[]>] [-NodeDisplayMode <Card>] [-NoEdgeLabels] [-NoGroups] [-NoLegend] [-NoScenarioControls] [-NoScenarioPanel] [-NoStatusBadges] [-NoTitle] [-Padding <Int32>] [-PassThru] [-Scenario <TopologyScenario[]>] [-ScenarioControlMode <Buttons|Checkboxes>] [-ScenarioDefinition <ScriptBlock>] [-ScenarioUrlState] [-Show] [-Subtitle <String>] [-Theme <Light|Dark>] [-Title <String>] [-Transparent] [-VisualStyle <Default|MonitoringDashboard>] [-Width <Int32>] [<CommonParameters>]#Parameter set:
DefinitionParameters
- ActiveScenarioId String
- Scenario activated for static highlighting or when interactive HTML first loads.
- CanvasSurfaceStyle TopologyCanvasSurfaceStyle
- Canvas surface style.
- Possible values:
Plain,Panel,PanelGrid - Chart TopologyChart
- Topology chart provided directly.
- Definition Object[]
- Topology objects provided directly or from the pipeline.
- Direction TopologyLayoutDirection
- Topology layout direction.
- Possible values:
TopToBottom,LeftToRight,BottomToTop,RightToLeft - Edge TopologyEdge[]
- Topology edges provided directly.
- FilePath String
- Output file path. The extension selects PNG, SVG, HTML, GIF, or APNG output.
- FitContentToViewport SwitchParameter
- Scale topology content down to remain inside the requested viewport.
- Group TopologyGroup[]
- Topology groups provided directly.
- Height Int32
- Viewport height in pixels.
- InteractiveHtml SwitchParameter
- Enable lightweight interactions for HTML output.
- Layout TopologyLayoutMode
- Topology layout mode.
- Possible values:
Manual,GroupGrid,HubAndSpoke,Layered,Matrix,DenseGrouped,Geographic,ForceDirected,RelationshipRadial,MindMap - Motion TopologyMotionOptions
- Script-free route motion used by SVG, GIF, APNG, and sampled PNG output.
- Node TopologyNode[]
- Topology nodes provided directly.
- NodeDisplayMode TopologyNodeDisplayMode
- Node presentation mode.
- Possible values:
Card,CompactCard,Tile,Pill,Icon,Artwork,Dot,Hidden - NoEdgeLabels SwitchParameter
- Hide edge labels.
- NoGroups SwitchParameter
- Hide topology groups.
- NoLegend SwitchParameter
- Hide the topology legend.
- NoScenarioControls SwitchParameter
- Hide scenario controls in interactive HTML output.
- NoScenarioPanel SwitchParameter
- Hide the compact scenario detail panel in interactive HTML output.
- NoStatusBadges SwitchParameter
- Hide status badges.
- NoTitle SwitchParameter
- Hide the topology title.
- Padding Int32
- Viewport padding in pixels.
- PassThru SwitchParameter
- Write the generated topology chart to the pipeline after rendering.
- Scenario TopologyScenario[]
- Topology scenarios provided directly.
- ScenarioControlMode TopologyHtmlScenarioControlMode
- Scenario control presentation used by interactive HTML output.
- Possible values:
Buttons,Checkboxes - ScenarioDefinition ScriptBlock
- Script block that emits topology scenarios.
- ScenarioUrlState SwitchParameter
- Synchronize the active scenario with the HTML page query string.
- Show SwitchParameter
- Open the generated file after creation.
- Subtitle String
- Topology subtitle.
- Theme String
- Topology theme name.
- Possible values:
Light,Dark - Title String
- Topology title.
- Transparent SwitchParameter
- Use a transparent diagram canvas.
- VisualStyle TopologyVisualStyle
- Reusable visual style.
- Possible values:
Default,MonitoringDashboard - Width Int32
- Viewport width in pixels.
Outputs
ChartForgeX.Topology.TopologyChart