YAML-driven architecture diagrams for FigJam. Define your infrastructure as code and sync it live to FigJam.
- Diagram as Code: Define cloud architecture diagrams in YAML
- Multi-Provider Support: AWS, GCP, and Azure icons
- Live Sync: Edit YAML and watch FigJam update in real-time
- Incremental Updates: Only changed elements are updated (preserves manual adjustments)
- Containers: VPC/Subnet/VNet as nested frames
- Custom Icons: Bring your own icon sets
npm install -g figramOr run directly with npx:
npx figram <command>npx figram initThis creates a diagram.yaml template.
- Install from Figma Community (coming soon)
- Open a FigJam file
- Run the figram plugin from the plugins menu
npx figram diagram.yamlIn the FigJam plugin:
- Enter the
docIdfrom your YAML - Connect to
ws://127.0.0.1:3456
Your diagram will appear and sync automatically when you edit the YAML!
version: 1
docId: "my-architecture"
title: "Production Environment"
nodes:
- id: vpc
provider: aws
kind: network.vpc
label: "VPC 10.0.0.0/16"
layout: { x: 0, y: 0, w: 800, h: 500 }
- id: alb
provider: aws
kind: compute.lb.alb
label: "ALB"
parent: vpc
layout: { x: 100, y: 100 }
- id: ecs
provider: aws
kind: compute.container.ecs_service
label: "ECS Service"
parent: vpc
layout: { x: 100, y: 250 }
- id: rds
provider: aws
kind: database.rds
label: "RDS PostgreSQL"
parent: vpc
layout: { x: 300, y: 250 }
edges:
- id: alb_to_ecs
from: alb
to: ecs
label: "HTTP:80"
- id: ecs_to_rds
from: ecs
to: rds
label: "TCP:5432"Create a diagram.yaml template.
npx figram initConvert YAML to JSON format.
npx figram build diagram.yaml
# Output: diagram.jsonStart WebSocket server with file watching. This is the default command, so you can omit serve:
npx figram diagram.yaml
# or explicitly:
npx figram serve diagram.yamlOptions:
| Option | Description |
|---|---|
--port, -p |
Port number (default: 3456) |
--host |
Host to bind (default: 127.0.0.1) |
--no-watch |
Disable file watching |
--allow-remote |
Allow remote connections |
--secret |
Require secret for connection |
--icons |
Path to custom icons file |
| Provider | Description |
|---|---|
aws |
Amazon Web Services |
gcp |
Google Cloud Platform |
azure |
Microsoft Azure |
Containers (with w/h):
- AWS:
network.vpc,network.subnet - GCP:
network.vpc - Azure:
network.vnet
AWS Resources:
compute.ec2,compute.lambda,compute.lb.alb,compute.lb.nlbcompute.container.ecs,compute.container.ecs_service,compute.container.eksdatabase.rds,database.aurora,database.dynamodbstorage.s3,storage.efsnetwork.route53,network.cloudfront,network.api_gateway- and more...
GCP Resources:
compute.gce,compute.functions,compute.cloudruncompute.container.gkedatabase.cloudsql,database.firestore,database.spannerstorage.gcs- and more...
Azure Resources:
compute.vm,compute.functions,compute.appservicecompute.container.aks,compute.container.acidatabase.sql,database.cosmosdbstorage.blob,storage.files- and more...
See docs/en/yaml-specs.md for the complete list of supported kinds.
You can use your own icons by creating a figram-icons.yaml:
version: 1
icons:
my-service:
path: "./icons/my-service.png"
another-service:
path: "./icons/another.png"Then reference them in your diagram:
nodes:
- id: custom
kind: my-service
label: "My Custom Service"
layout: { x: 0, y: 0 }Start the server with the icons file:
npx figram serve diagram.yaml --icons figram-icons.yamlMIT