SmartDraw's Open API

The SmartDraw Open API allows you to create extensions that let you skip the drawing process and generate diagrams from data automatically.

Class diagram example

Build a class diagram from the source code

Decision tree example

Show decisions in your project as a decision tree

Database diagram

Visualize relationships in your database

What Makes SmartDraw's API Easy

Other diagramming API's, like Visio's for example, require you to specify the coordinates of every shape and line in the diagram. This makes generating a diagram with code tedious and complex.

The SmartDraw API is very different because it leverages SmartDraw's intelligent formatting engine, the ability to automatically format and connect shapes on a page based on their relationships.

SmartDraw simple to use API

Using the VisualScript SDK, you can build your own extensions that represent data as a diagram.

You add these applications as Extensions that are incorporated into the user interface. Learn more about Extensions.

SmartDraw Extensions

The VisualScript SDK

The VisualScript SDK provides an object model that allows a developer to build an extension that turns data into diagrams for SmartDraw.

It is the foundation of SmartDraw's Open API. It's easy to use because it leverages SmartDraw's intelligent formatting to make specifying a tree or a flow as simple as specifying the parents and children. No positioning information is needed because the intelligent formatting engine knows how to lay them out perfectly on the page.

This simple JavaScript is rendered as an org chart:

{
				var vs = new VS.Document(); //Create a new VisualScript document
				var theShape= vs.GetTheShape();
				var myConnector=theShape.AddShapeConnector(VS.ShapeConnectorTypes.OrgChart);  //add the org chart connector to the top shape
				myConnector.AddShape(); //add the first shape to the connector
				myConnector.AddShape(); //add the second shape to the connector
				}
			
Simple org chart described using VisualScript

Without this power it would not be practical to generate the kind of diagrams you need with code.

Documentation for VisualScript

Learn how to write SmartDraw Extensions using the VisualScript SDK.

VisualScript SDK
VisualScript SDK

Learn the methods for building visuals available in the SDK. Learn how to use the SDK.

VisualScript cookbook
VisualScript Cookbook

Learn how to build diagrams using VisualScript SDK. Learn more.

VisualScript cookbook
VSON Markup Reference

An overview of all the objects and constants available in the VSON markup language. Learn more.

Documentation for Extensions

There are two ways to create an extension in SmartDraw using VisualScript markup.

JavaScript extension tutorial
JavaScript Extension

Generate code and the related UI directly in the SmartDraw app using a built-in editor. Learn more.

REST extension tutorial
REST Extension

Build an end-user UI to access your extension, but generate the script at an external point. Learn more.

Click Here to Get Expert Help

Contact Us
By continuing to use the website, you consent to the use of cookies.   Read More