forked from yuzutech/kroki.io
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
726 lines (697 loc) · 48.8 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
<!DOCTYPE html>
<html lang="en" data-color-mode="light" data-light-theme="light" data-dark-theme="dark_dimmed">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="apple-touch-icon-precomposed" sizes="57x57" href="./assets/apple-touch-icon-57x57.png" />
<link rel="apple-touch-icon-precomposed" sizes="114x114" href="./assets/apple-touch-icon-114x114.png" />
<link rel="apple-touch-icon-precomposed" sizes="72x72" href="./assets/apple-touch-icon-72x72.png" />
<link rel="apple-touch-icon-precomposed" sizes="144x144" href="./assets/apple-touch-icon-144x144.png" />
<link rel="apple-touch-icon-precomposed" sizes="60x60" href="./assets/apple-touch-icon-60x60.png" />
<link rel="apple-touch-icon-precomposed" sizes="120x120" href="./assets/apple-touch-icon-120x120.png" />
<link rel="apple-touch-icon-precomposed" sizes="76x76" href="./assets/apple-touch-icon-76x76.png" />
<link rel="apple-touch-icon-precomposed" sizes="152x152" href="./assets/apple-touch-icon-152x152.png" />
<link rel="icon" type="image/png" href="./assets/favicon-196x196.png" sizes="196x196" />
<link rel="icon" type="image/png" href="./assets/favicon-96x96.png" sizes="96x96" />
<link rel="icon" type="image/png" href="./assets/favicon-32x32.png" sizes="32x32" />
<link rel="icon" type="image/png" href="./assets/favicon-16x16.png" sizes="16x16" />
<link rel="icon" type="image/png" href="./assets/favicon-128.png" sizes="128x128" />
<meta name="application-name" content="Kroki"/>
<meta name="msapplication-TileColor" content="#FFFFFF" />
<meta name="msapplication-TileImage" content="./assets/mstile-144x144.png" />
<meta name="msapplication-square70x70logo" content="./assets/mstile-70x70.png" />
<meta name="msapplication-square150x150logo" content="./assets/mstile-150x150.png" />
<meta name="msapplication-wide310x150logo" content="./assets/mstile-310x150.png" />
<meta name="msapplication-square310x310logo" content="./assets/mstile-310x310.png" />
<title>Kroki!</title>
<link rel="stylesheet" href="./css/main.min.css?v=1.3.0">
</head>
<body>
<section class="section">
<div class="container">
<div class="duo">
<div class="lead">
<a href="#">
<img class="title logo" src="assets/logo.svg" alt="logo"/>
</a>
<h1 class="subtitle">Creates <strong>diagrams</strong> from <strong>textual</strong> descriptions!</h1>
<div class="content">
<p>
Kroki provides a unified API with support for BlockDiag (BlockDiag, SeqDiag, ActDiag, NwDiag, PacketDiag, RackDiag),
BPMN, Bytefield, C4 (with PlantUML), D2, DBML, Ditaa, Erd, Excalidraw, GraphViz, Mermaid, Nomnoml, Pikchr, PlantUML, Structurizr, SvgBob, Symbolator, TikZ, UMLet, Vega, Vega-Lite, WaveDrom, WireViz...
and more to come!
</p>
</div>
<article class="message is-info is-important">
<div class="message-body">
<p><strong>📢 We're planning the future of Kroki, and we need your insights!</strong></p>
<p>Please take a moment to fill out <a href="https://forms.gle/2wLAsNCppAFqJ4a58">our short questionnaire</a> – your feedback is crucial in helping us grow.</p>
</div>
</article>
<div class="content carbonads-container">
<div class="carbonads-placeholder"><div class="loader"></div></div>
<script async src="//cdn.carbonads.com/carbon.js?serve=CEAIV53I&placement=krokiio" id="_carbonads_js"></script>
</div>
<h2 id="features" class="title is-2">Features<a class="anchor-link" href="#features">#</a></h2>
<div class="content">
<dl>
<dt><strong>Ready to use</strong></dt>
<dd>Diagrams libraries are written in a variety of languages: Haskell, Python, JavaScript, Go, PHP, Java... some also have C bindings.
Trust us, you have better things to do than install all the requirements to use them. Get started in no time!
</dd>
</dl>
<dl>
<dt><strong>Simple</strong></dt>
<dd>Kroki provides a unified API for all the diagram libraries. Learn once use diagrams anywhere!</dd>
</dl>
<dl>
<dt><strong>Free & Open source</strong></dt>
<dd>All the code is available on GitHub and our goal is to provide Kroki as a free service.</dd>
</dl>
<dl>
<dt><strong>Fast</strong></dt>
<dd>Built using a modern architecture, Kroki offers great performance.</dd>
</dl>
</div>
<h2 id="try" class="title is-2">Try<a class="anchor-link" href="#try">#</a></h2>
<div class="field">
<label class="label">Diagram</label>
<div class="control">
<div class="select">
<select id="select-diagram" aria-label="Diagram">
<option value="blockdiag">BlockDiag</option>
<option value="bpmn">BPMN</option>
<option value="bytefield">Bytefield</option>
<option value="seqdiag">SeqDiag</option>
<option value="actdiag">ActDiag</option>
<option value="nwdiag">NwDiag</option>
<option value="packetdiag">PacketDiag</option>
<option value="rackdiag">RackDiag</option>
<option value="c4plantuml">C4 with PlantUML</option>
<option value="d2">D2</option>
<option value="dbml">DBML</option>
<option value="ditaa">Ditaa</option>
<option value="erd">Erd</option>
<option value="excalidraw">Excalidraw</option>
<option value="graphviz">GraphViz</option>
<option value="mermaid">Mermaid</option>
<option value="nomnoml">Nomnoml</option>
<option value="pikchr">Pikchr</option>
<option selected value="plantuml">PlantUML</option>
<option value="structurizr">Structurizr</option>
<option value="svgbob">Svgbob</option>
<option value="symbolator">Symbolator</option>
<option value="tikz">TikZ</option>
<option value="vega">Vega</option>
<option value="vegalite">Vega-Lite</option>
<option value="wavedrom">WaveDrom</option>
<option value="wireviz">WireViz</option>
</select>
</div>
</div>
</div>
<div class="content">
<div class="columns try-columns">
<div class="column">
<div class="field">
<div class="control">
<textarea id="diagram-source" class="textarea code" placeholder="User -> Kroki: Hello" rows="25">skinparam ranksep 20
skinparam dpi 125
skinparam packageTitleAlignment left
rectangle "Main" {
(main.view)
(singleton)
}
rectangle "Base" {
(base.component)
(component)
(model)
}
rectangle "<b>main.ts</b>" as main_ts
(component) ..> (base.component)
main_ts ==> (main.view)
(main.view) --> (component)
(main.view) ...> (singleton)
(singleton) ---> (model)</textarea>
</div>
</div>
</div>
<div class="column">
<div id="diagram-result" class="diagram-plantuml">
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="506.5104px" preserveAspectRatio="none" style="width:391px;height:506px;background:#FFFFFF;" version="1.1" viewBox="0 0 391 506" width="391.9271px" zoomAndPan="magnify"><defs/><g><!--cluster Main--><g id="cluster_Main"><rect fill="none" height="197.9167" rx="3.2552" ry="3.2552" style="stroke:#181818;stroke-width:1.3020833333333333;" width="197.9167" x="9.1146" y="76.8229"/><text fill="#000000" font-family="sans-serif" font-size="18.2292" font-weight="bold" lengthAdjust="spacing" textLength="46.875" x="13.0208" y="96.3478">Main</text></g><!--cluster Base--><g id="cluster_Base"><rect fill="none" height="180.9896" rx="3.2552" ry="3.2552" style="stroke:#181818;stroke-width:1.3020833333333333;" width="368.4896" x="15.625" y="317.7083"/><text fill="#000000" font-family="sans-serif" font-size="18.2292" font-weight="bold" lengthAdjust="spacing" textLength="49.4792" x="19.5313" y="337.2332">Base</text></g><g id="elem_main.view"><ellipse cx="108.1593" cy="141.6305" fill="#F1F1F1" rx="78.2114" ry="19.2346" style="stroke:#181818;stroke-width:0.6510416666666666;"/><text fill="#000000" font-family="sans-serif" font-size="18.2292" lengthAdjust="spacing" textLength="87.2396" x="60.6333" y="146.5101">main.view</text></g><g id="elem_singleton"><ellipse cx="106.5449" cy="234.0581" fill="#F1F1F1" rx="75.2949" ry="19.2143" style="stroke:#181818;stroke-width:0.6510416666666666;"/><text fill="#000000" font-family="sans-serif" font-size="18.2292" lengthAdjust="spacing" textLength="83.3333" x="60.972" y="238.9377">singleton</text></g><g id="elem_base.component"><ellipse cx="258.8332" cy="453.5895" fill="#F1F1F1" rx="103.8852" ry="23.902" style="stroke:#181818;stroke-width:0.6510416666666666;"/><text fill="#000000" font-family="sans-serif" font-size="18.2292" lengthAdjust="spacing" textLength="153.6458" x="179.7338" y="458.0225">base.component</text></g><g id="elem_component"><ellipse cx="277.2395" cy="383.4427" fill="#F1F1F1" rx="85.1823" ry="20.1615" style="stroke:#181818;stroke-width:0.6510416666666666;"/><text fill="#000000" font-family="sans-serif" font-size="18.2292" lengthAdjust="spacing" textLength="104.1667" x="221.25" y="388.3223">component</text></g><g id="elem_model"><ellipse cx="91.3452" cy="383.5955" fill="#F1F1F1" rx="54.8868" ry="19.0121" style="stroke:#181818;stroke-width:0.6510416666666666;"/><text fill="#000000" font-family="sans-serif" font-size="18.2292" lengthAdjust="spacing" textLength="55.9896" x="59.4441" y="388.4751">model</text></g><!--entity main_ts--><g id="elem_main_ts"><rect fill="#F1F1F1" height="47.2616" rx="3.2552" ry="3.2552" style="stroke:#181818;stroke-width:0.6510416666666666;" width="100.2604" x="57.9427" y="9.1146"/><text fill="#000000" font-family="sans-serif" font-size="18.2292" font-weight="bold" lengthAdjust="spacing" textLength="74.2188" x="70.9635" y="39.0561">main.ts</text></g><!--link component to base.component--><g id="link_component_base.component"><path d="M272.1745,403.9844 C270.7161,409.362 269.1146,415.3516 267.526,421.224 " fill="none" id="component-to-base.component" style="stroke:#181818;stroke-width:1.3020833333333333;stroke-dasharray:7.0,7.0;"/><polygon fill="#181818" points="265.9115,427.2135,273.9873,417.2518,267.604,420.927,263.9288,414.5437,265.9115,427.2135" style="stroke:#181818;stroke-width:1.3020833333333333;"/></g><!--link main_ts to main.view--><g id="link_main_ts_main.view"><path d="M108.0729,56.4974 C108.0729,73.2292 108.0729,96.0677 108.0729,113.724 " fill="none" id="main_ts-to-main.view" style="stroke:#181818;stroke-width:2.6041666666666665;"/><polygon fill="#181818" points="108.0729,119.9609,113.2813,108.2422,108.0729,113.4505,102.8646,108.2422,108.0729,119.9609" style="stroke:#181818;stroke-width:2.6041666666666665;"/></g><!--link main.view to component--><g id="link_main.view_component"><path d="M139.6875,160.3646 C160.7161,173.0859 187.6823,192.1224 205.7292,214.8438 C239.9349,257.9036 260.7292,319.7526 270.5469,354.9349 " fill="none" id="main.view-to-component" style="stroke:#181818;stroke-width:1.3020833333333333;"/><polygon fill="#181818" points="272.1745,360.9635,274.1222,348.2883,270.4646,354.6817,264.0712,351.0241,272.1745,360.9635" style="stroke:#181818;stroke-width:1.3020833333333333;"/></g><!--link main.view to singleton--><g id="link_main.view_singleton"><path d="M107.7995,161.849 C107.6172,174.6094 107.3698,191.7578 107.1615,206.0286 " fill="none" id="main.view-to-singleton" style="stroke:#181818;stroke-width:1.3020833333333333;stroke-dasharray:7.0,7.0;"/><polygon fill="#181818" points="107.0703,212.513,112.4455,200.8699,107.1633,206.0033,102.0299,200.7211,107.0703,212.513" style="stroke:#181818;stroke-width:1.3020833333333333;"/></g><!--link singleton to model--><g id="link_singleton_model"><path d="M104.7917,254.2318 C102.0443,280.013 97.0443,326.8099 93.9323,356.0938 " fill="none" id="singleton-to-model" style="stroke:#181818;stroke-width:1.3020833333333333;"/><polygon fill="#181818" points="93.2682,362.2526,99.6863,351.1502,93.9565,355.7787,89.3281,350.0489,93.2682,362.2526" style="stroke:#181818;stroke-width:1.3020833333333333;"/></g></g></svg>
</div>
<article id="diagram-error" class="message is-danger is-invisible">
<div id="diagram-error-message" class="message-body">
</div>
</article>
</div>
</div>
<div class="highlight" id="diagram-url">
<pre><code class="language-http static"><span class="token verb-get">GET</span> <span class="token host">https://kroki.io</span>/<span class="token path">plantuml/svg/eNpljzEPgjAQhff-iguTDFQlcYMmuru5mwNO0tCWhjY6GP-7LRJTdHvv7r67d26QxuKEGiY0gyML5Y65b7GzEvblIalYbAfs6SK9oqOSvdFkPCi6ecYmaj2aXhFkZ5QmgycD2Ogg-V3SI4_OyTjgR5OzVwqc0NECNEHydtR2NGH3TK2dHjtSP3zViPmQd9W2ERmgg-iv3jGW4MC5-L-wTEJdi1XeRENRiFWOtMfnrclriQ5gJD-Z3x9beAM=</span></code></pre>
<button class="button is-small bd-copy"
data-clipboard-text="https://kroki.io/plantuml/svg/eNpljzEPgjAQhff-iguTDFQlcYMmuru5mwNO0tCWhjY6GP-7LRJTdHvv7r67d26QxuKEGiY0gyML5Y65b7GzEvblIalYbAfs6SK9oqOSvdFkPCi6ecYmaj2aXhFkZ5QmgycD2Ogg-V3SI4_OyTjgR5OzVwqc0NECNEHydtR2NGH3TK2dHjtSP3zViPmQd9W2ERmgg-iv3jGW4MC5-L-wTEJdi1XeRENRiFWOtMfnrclriQ5gJD-Z3x9beAM="
title="Copy to clipboard">
<svg fill="currentColor" viewBox="0 0 896 1024" xmlns="http://www.w3.org/2000/svg">
<path d="M128 768h256v64H128v-64z m320-384H128v64h320v-64z m128 192V448L384 640l192 192V704h320V576H576z m-288-64H128v64h160v-64zM128 704h160v-64H128v64z m576 64h64v128c-1 18-7 33-19 45s-27 18-45 19H64c-35 0-64-29-64-64V192c0-35 29-64 64-64h192C256 57 313 0 384 0s128 57 128 128h192c35 0 64 29 64 64v320h-64V320H64v576h640V768zM128 256h512c0-35-29-64-64-64h-64c-35 0-64-29-64-64s-29-64-64-64-64 29-64 64-29 64-64 64h-64c-35 0-64 29-64 64z"></path>
</svg>
Copy
</button>
</div>
</div>
<h2 id="examples" class="title is-2">Examples<a class="anchor-link" href="#examples">#</a></h2>
<div class="content">
<p>Looking for inspiration? Visit the <a href="./examples.html">examples</a> page.</p>
</div>
<h2 id="support" class="title is-2">Diagram types<a class="anchor-link" href="#support">#</a></h2>
<div class="content">
<p>The following diagram types and output formats are available:</p>
<div class="table-container">
<table class="table table-support is-bordered is-striped is-narrow is-hoverable is-fullwidth">
<thead>
<tr>
<th>Diagram Type</th>
<th>png</th>
<th>svg</th>
<th>jpeg</th>
<th>pdf</th>
<th><abbr title="txt or utxt (unicode)">txt</abbr></th>
<th>base64</th>
</tr>
</thead>
<tbody>
<tr>
<td><a href="https://github.com/blockdiag/blockdiag">BlockDiag</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td>✔️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/bpmn-io/bpmn-js">BPMN</a></td>
<td>️</td>
<td>✔️</td>
<td></td>
<td>️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/Deep-Symmetry/bytefield-svg/">Bytefield</a></td>
<td>️</td>
<td>✔️</td>
<td></td>
<td>️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/blockdiag/seqdiag">SeqDiag</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td>✔️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/blockdiag/actdiag">ActDiag</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td>✔️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/blockdiag/nwdiag">NwDiag</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td>✔️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/blockdiag/nwdiag">PacketDiag</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td>✔️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/blockdiag/nwdiag">RackDiag</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td>✔️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/RicardoNiepel/C4-PlantUML">C4 with PlantUML</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td>️✔️</td>
<td>️✔️</td>
<td>✔️</td>
</tr>
<tr>
<td><a href="https://github.com/terrastruct/d2">D2</a></td>
<td></td>
<td>✔️</td>
<td></td>
<td>️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/softwaretechnik-berlin/dbml-renderer">DBML</a></td>
<td></td>
<td>✔️</td>
<td></td>
<td>️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://ditaa.sourceforge.net">Ditaa</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td>️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/BurntSushi/erd">Erd</a></td>
<td>✔️</td>
<td>✔️</td>
<td>✔️</td>
<td>✔️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/excalidraw/excalidraw">Excalidraw</a></td>
<td>️</td>
<td>✔️</td>
<td>️</td>
<td>️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://www.graphviz.org/">GraphViz</a></td>
<td>✔️</td>
<td>✔️</td>
<td>✔️</td>
<td>✔️</td>
<td>️</td>
<td></td>
</tr>
<tr>
<td><a href="https://github.com/knsv/mermaid">Mermaid</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td></td>
<td>️</td>
<td></td>
</tr>
<tr>
<td><a href="https://github.com/skanaar/nomnoml">Nomnoml</a></td>
<td>️</td>
<td>✔️</td>
<td>️</td>
<td></td>
<td>️</td>
<td></td>
</tr>
<tr>
<td><a href="https://github.com/drhsqlite/pikchr">Pikchr</a></td>
<td>️</td>
<td>✔️</td>
<td>️</td>
<td>️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/plantuml/plantuml">PlantUML</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td>️✔️</td>
<td>️✔️</td>
<td>✔️</td>
</tr>
<tr>
<td><a href="https://github.com/structurizr/dsl">Structurizr</a></td>
<td>️✔️</td>
<td>✔️</td>
<td>️</td>
<td>️✔️</td>
<td>️✔️</td>
<td>✔️</td>
</tr>
<tr>
<td><a href="https://github.com/ivanceras/svgbob">Svgbob</a></td>
<td>️</td>
<td>✔️</td>
<td>️</td>
<td>️</td>
<td>️</td>
<td></td>
</tr>
<tr>
<td><a href="https://github.com/kevinpt/symbolator">Symbolator</a></td>
<td>️</td>
<td>✔️</td>
<td></td>
<td>️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/pgf-tikz/pgf">TikZ</a></td>
<td>✔️️</td>
<td>✔️</td>
<td>✔️️</td>
<td>️✔️</td>
<td>️</td>
<td></td>
</tr>
<tr>
<td><a href="https://github.com/umlet/umlet">UMlet</a></td>
<td>✔️</td>
<td>✔️</td>
<td>✔️</td>
<td>️</td>
<td>️</td>
<td></td>
</tr>
<tr>
<td><a href="https://github.com/vega/vega">Vega</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td>✔️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/vega/vega-lite">Vega-Lite</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td>✔️</td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/wavedrom/wavedrom">WaveDrom</a></td>
<td></td>
<td>✔️</td>
<td></td>
<td></td>
<td>️</td>
<td>️</td>
</tr>
<tr>
<td><a href="https://github.com/formatc1702/WireViz">WireViz</a></td>
<td>✔️</td>
<td>✔️</td>
<td></td>
<td></td>
<td>️</td>
<td>️</td>
</tr>
</tbody>
</table>
</div>
<p>You don't see your favorite diagram tool in this list, please let us know <a href="mailto:hello@kroki.io">👋 hello@kroki.io</a>.</p>
</div>
<h2 id="cheat-sheet" class="title is-2">Cheat sheet<a class="anchor-link" href="#cheat-sheet">#</a></h2>
<div class="content">
<a download="" target="_blank" class="download-cheat-sheet" href="assets/kroki_cheatsheet_20210515_v1.1_EN.pdf">
<img src="assets/kroki_cheatsheet_20210515_v1.1_EN.jpeg" alt="cheat sheet" />
📌 Download cheat sheet as PDF
</a>
</div>
<h2 id="install" class="title is-2">Install<a class="anchor-link" href="#install">#</a></h2>
<div class="content">
<p>
Kroki is available as a Free Service and as a Self-Managed instance.<br/>
</p>
<div class="tile is-parent is-ancestor">
<div class="tile is-child card">
<div class="card-content">
<p class="title is-4">
<svg aria-hidden="true" focusable="false" data-prefix="fal" data-icon="server" role="img" xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 512 512" class="svg-inline--fa fa-server fa-fw">
<path fill="currentColor"
d="M376 256c0-13.255 10.745-24 24-24s24 10.745 24 24-10.745 24-24 24-24-10.745-24-24zm-40 24c13.255 0 24-10.745 24-24s-10.745-24-24-24-24 10.745-24 24 10.745 24 24 24zm176-128c0 12.296-4.629 23.507-12.232 32 7.603 8.493 12.232 19.704 12.232 32v80c0 12.296-4.629 23.507-12.232 32 7.603 8.493 12.232 19.704 12.232 32v80c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48v-80c0-12.296 4.629-23.507 12.232-32C4.629 319.507 0 308.296 0 296v-80c0-12.296 4.629-23.507 12.232-32C4.629 175.507 0 164.296 0 152V72c0-26.51 21.49-48 48-48h416c26.51 0 48 21.49 48 48v80zm-480 0c0 8.822 7.178 16 16 16h416c8.822 0 16-7.178 16-16V72c0-8.822-7.178-16-16-16H48c-8.822 0-16 7.178-16 16v80zm432 48H48c-8.822 0-16 7.178-16 16v80c0 8.822 7.178 16 16 16h416c8.822 0 16-7.178 16-16v-80c0-8.822-7.178-16-16-16zm16 160c0-8.822-7.178-16-16-16H48c-8.822 0-16 7.178-16 16v80c0 8.822 7.178 16 16 16h416c8.822 0 16-7.178 16-16v-80zm-80-224c13.255 0 24-10.745 24-24s-10.745-24-24-24-24 10.745-24 24 10.745 24 24 24zm-64 0c13.255 0 24-10.745 24-24s-10.745-24-24-24-24 10.745-24 24 10.745 24 24 24zm64 240c-13.255 0-24 10.745-24 24s10.745 24 24 24 24-10.745 24-24-10.745-24-24-24zm-64 0c-13.255 0-24 10.745-24 24s10.745 24 24 24 24-10.745 24-24-10.745-24-24-24z"
class=""></path>
</svg>
Self-Managed
</p>
<div class="content">
<p>
Select this option if you want to download and install Kroki on your own infrastructure or in a cloud environment.
</p>
<article class="message is-info">
<div class="message-body">
Please note that Kroki Self-Managed requires Linux experience to install.
</div>
</article>
<p>Please refer to the documentation to <a href="https://docs.kroki.io/kroki/setup/install">install Kroki</a>.</p>
</div>
</div>
</div>
<div class="tile is-child card">
<div class="card-content">
<p class="title is-4">
<svg aria-hidden="true" focusable="false" data-prefix="fal" data-icon="cloud" role="img" xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 640 512" class="svg-inline--fa fa-cloud fa-fw">
<path fill="currentColor"
d="M571.7 238.8c2.8-9.9 4.3-20.2 4.3-30.8 0-61.9-50.1-112-112-112-16.7 0-32.9 3.6-48 10.8-31.6-45-84.3-74.8-144-74.8-94.4 0-171.7 74.5-175.8 168.2C39.2 220.2 0 274.3 0 336c0 79.6 64.4 144 144 144h368c70.7 0 128-57.2 128-128 0-47-25.8-90.8-68.3-113.2zM512 448H144c-61.9 0-112-50.1-112-112 0-56.8 42.2-103.7 97-111-.7-5.6-1-11.3-1-17 0-79.5 64.5-144 144-144 60.3 0 111.9 37 133.4 89.6C420 137.9 440.8 128 464 128c44.2 0 80 35.8 80 80 0 18.5-6.3 35.6-16.9 49.2C573 264.4 608 304.1 608 352c0 53-43 96-96 96z"
class=""></path>
</svg>
Free service
</p>
<div class="content">
<p>
Thanks to <a href="https://www.exoscale.com/" target="_blank" rel="noopener noreferrer">Exoscale</a>, which has kindly offered two servers,
we can provide Kroki as a <em>free service</em>!<br/>
However, some parts of the infrastructure are still host on other providers, so <strong>we are still looking for sponsors to cover all the
expenses.</strong>
</p>
<p>
If you are interested, please <a href="mailto:hello@kroki.io">👋 contact us</a>.
</p>
</div>
</div>
</div>
</div>
</div>
<h2 id="how" class="title is-2">How<a class="anchor-link" href="#how">#</a></h2>
<div class="content">
<p>
Kroki provides an HTTP API to create diagrams from textual descriptions.
Kroki handles both <code>GET</code> and <code>POST</code> requests.
When using <code>GET</code> requests, your diagram must be encoded in the URL using a deflate + base64 algorithm.
But don't worry, if you're not familiar with deflate or base64 (or if you don't want to use them),
you can also send your diagram as plain text using <code>POST</code> requests (<a href="#post-request">see below</a>).
</p>
<p>
Let's take an example with a <em>GraphViz</em> "Hello World":
</p>
<code class="snippet-name">hello.dot</code>
<pre><code class="language-graphviz">digraph G {Hello->World}</code></pre>
<p>
Here, we are using a Python one-liner to encode our diagram using deflate + base64:
</p>
<pre><code class="language-sh">cat hello.dot | python -c "import sys; import base64; import zlib; print(base64.urlsafe_b64encode(zlib.compress(sys.stdin.read().encode('utf-8'), 9)).decode('ascii'))"</code></pre>
<article class="message is-info">
<div class="message-body">
In the <a href="https://docs.kroki.io/kroki/setup/encode-diagram/">documentation</a>, we provide code examples that demonstrate how to encode a diagram
in Node.js, JavaScript, Java, Python and Go.
</div>
</article>
<p>
The above command will return a value that you can copy and paste at the end of the URL:
</p>
<pre><code class="language-http">GET /graphviz/svg/eNpLyUwvSizIUHBXqPZIzcnJ17ULzy_KSanlAgB1EAjQ</code></pre>
<p>
And here's the result:
</p>
<svg class="kroki-output" xmlns="http://www.w3.org/2000/svg" width="74pt" height="116pt" viewBox="0.00 0.00 74.29 116.00">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 112)">
<title>G</title>
<polygon fill="#ffffff" stroke="transparent" points="-4,4 -4,-112 70.2941,-112 70.2941,4 -4,4"/>
<!-- Hello -->
<g id="node1" class="node">
<title>Hello</title>
<ellipse fill="none" stroke="#000000" cx="33.1471" cy="-90" rx="30.5947" ry="18"/>
<text text-anchor="middle" x="33.1471" y="-86.3" font-family="Times,serif" font-size="14.00" fill="#000000">Hello</text>
</g>
<!-- World -->
<g id="node2" class="node">
<title>World</title>
<ellipse fill="none" stroke="#000000" cx="33.1471" cy="-18" rx="33.2948" ry="18"/>
<text text-anchor="middle" x="33.1471" y="-14.3" font-family="Times,serif" font-size="14.00" fill="#000000">World</text>
</g>
<!-- Hello->World -->
<g id="edge1" class="edge">
<title>Hello->World</title>
<path fill="none" stroke="#000000" d="M33.1471,-71.8314C33.1471,-64.131 33.1471,-54.9743 33.1471,-46.4166"/>
<polygon fill="#000000" stroke="#000000" points="36.6472,-46.4132 33.1471,-36.4133 29.6472,-46.4133 36.6472,-46.4132"/>
</g>
</g>
</svg>
<br/>
<p>Please note that the encoding process is lossless. As a matter of fact, you can also use a Python one-liner to decode an encoded diagram:</p>
<pre><code class="language-sh">echo "eNpLyUwvSizIUHBXqPZIzcnJ17ULzy_KSanlAgB1EAjQ" | python -c "import sys; import base64; import zlib; print(zlib.decompress(base64.urlsafe_b64decode(sys.stdin.read())).decode('utf8'))"</code></pre>
<p>
The above command will return:
</p>
<pre><code class="language-text">digraph G {Hello->World}</code></pre>
<h3 id="post-requests" class="title is-4">POST requests<a class="anchor-link" href="#post-requests">#</a></h3>
<p id="post-request">You can also call Kroki with <code>POST</code>:</p>
<pre><code class="language-http">POST /</code></pre>
<pre><code class="language-json">{
"diagram_source": "digraph G {Hello->World}",
"diagram_type": "graphviz",
"output_format": "svg"
}</code></pre>
<p>In this case, you don't need to encode your diagram.</p>
<p>
It's also possible to send your diagram as plain text using the <code>Content-Type</code> header.
The output format will be specified using the <code>Accept</code> header and the diagram source will be sent as the request body:
</p>
<pre><code class="language-http">POST /graphviz</code></pre>
<pre><code class="language-request">Accept: image/svg+xml
Content-Type: text/plain
digraph G {
Hello->World
}</code></pre>
<p>
You can also define the output format in the URL if you don't want to add an <code>Accept</code> header:
</p>
<pre><code class="language-http">POST /graphviz/svg</code></pre>
<pre><code class="language-request">Content-Type: text/plain
digraph G {
Hello->World
}</code></pre>
<p>
The same concept applies when sending the diagram as <code>JSON</code>:
</p>
<pre><code class="language-http">POST /graphviz/svg</code></pre>
<pre><code class="language-json">{
"diagram_source": "digraph G {Hello->World}"
}</code></pre>
<p>
Please note that you can interact with the API using <strong>any HTTP client</strong>.<br/>
If you want to learn more, head to <a href="https://docs.kroki.io/kroki/" target="_blank" rel="noopener noreferrer">our documentation</a>.
In particular, check out the <a href="https://docs.kroki.io/kroki/setup/usage/" target="_blank" rel="noopener noreferrer">Usage section</a> to find out how
to send requests to the Kroki API using:
</p>
<ul>
<li><a href="https://docs.kroki.io/kroki/setup/http-clients/" target="_blank" rel="noopener noreferrer"><em>cURL</em> and <em>HTTPie</em></a></li>
<li><a href="https://docs.kroki.io/kroki/setup/kroki-cli/" target="_blank" rel="noopener noreferrer">Kroki CLI</a></li>
</ul>
</div>
<h2 id="sponsors" class="title is-2">Sponsors<a class="anchor-link" href="#sponsors">#</a></h2>
<div class="content">
<p>
Thanks to our sponsors listed below, we are able to provide Kroki as a free service available to everyone.
</p>
<ul class="sponsors">
<li>
<a href="https://www.exoscale.com/?utm_source=kroki" target="_blank" rel="noopener noreferrer">
<img class="inline-exoscale" src="assets/exoscale-RGB-logo-fullcolor.svg" alt="Exoscale"/>
<span>A solid European cloud hosting alternative.</span>
</a>
</li>
<li>
<a href="https://terrastruct.com/?utm_source=kroki" target="_blank" rel="noopener noreferrer">
<img class="inline-terrastruct" src="assets/terrastruct-logo.svg" alt="Terrastruct"/>
<span>The diagramming tool for developers.</span>
</a>
</li>
<li>
<a href="https://zulip.com/?utm_source=kroki" target="_blank" rel="noopener noreferrer">
<img class="inline-zulip" src="assets/zulip-org-logo.svg" alt="Zulip"/>
<span>An open-source modern team chat app designed to keep both live and asynchronous conversations organized.</span>
</a>
</li>
<li>
<a href="https://utoolity.net/?utm_source=kroki" target="_blank" rel="noopener noreferrer">
<img class="inline-utoolity" src="assets/utoolity-logo.svg" alt="Utoolity"/>
<span>Utilities and tools to integrate Amazon Web Services (AWS) with Atlassian products.</span>
</a>
</li>
</ul>
<p>
Sponsors play a critical role, without them, we won't be able to provide Kroki as a free service.<br/>
To make Kroki sustainable, we need your support.
If you want to become a sponsor, please <a href="mailto:hello@kroki.io">👋 contact us</a>.
</p>
</div>
<h2 id="about" class="title is-2">About<a class="anchor-link" href="#about">#</a></h2>
<div class="content">
<p>
Kroki is a free service built and maintained by <a href="https://yuzutech.fr" target="_blank" rel="noopener noreferrer">Yuzu tech</a> and supported by <a href="https://www.exoscale.com/?utm_source=kroki" target="_blank" rel="noopener noreferrer">Exoscale</a>.
</p>
<p>
Kroki is <a href="https://github.com/yuzutech/kroki">an open source project</a> licensed under the <a
href="https://opensource.org/licenses/mit-license.php">MIT license</a>.<br/>
This means that Kroki is never going away; anyone can host this service with minimal resource requirements.
</p>
</div>
</div>
<aside class="menu">
<div id="anchors" class="anchors is-pinned">
<p class="menu-label">
Menu
</p>
<ul class="menu-list anchors-list">
<li><a href="#features">Features</a></li>
<li><a href="#try">Try</a></li>
<li><a href="#examples">Examples</a></li>
<li><a href="#support">Diagram types</a></li>
<li><a href="#cheat-sheet">Cheat sheet</a></li>
<li><a href="#install">Install</a></li>
<li><a href="#how">How</a></li>
<li><a href="#about">About</a></li>
<li><a href="#" id="back-top">Back to top ↑</a></li>
<li><hr class="menu-divider"/></li>
<li><a class="link has-icon" href="https://docs.kroki.io/kroki/" target="_blank" rel="noopener noreferrer"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16"><path d="M0 1.75A.75.75 0 0 1 .75 1h4.253c1.227 0 2.317.59 3 1.501A3.743 3.743 0 0 1 11.006 1h4.245a.75.75 0 0 1 .75.75v10.5a.75.75 0 0 1-.75.75h-4.507a2.25 2.25 0 0 0-1.591.659l-.622.621a.75.75 0 0 1-1.06 0l-.622-.621A2.25 2.25 0 0 0 5.258 13H.75a.75.75 0 0 1-.75-.75Zm7.251 10.324.004-5.073-.002-2.253A2.25 2.25 0 0 0 5.003 2.5H1.5v9h3.757a3.75 3.75 0 0 1 1.994.574ZM8.755 4.75l-.004 7.322a3.752 3.752 0 0 1 1.992-.572H14.5v-9h-3.495a2.25 2.25 0 0 0-2.25 2.25Z"></path></svg> Documentation</a></li>
<li><a class="link has-icon" href="https://kroki.zulipchat.com/" target="_blank" rel="noopener noreferrer"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16"><path d="M1.75 1h8.5c.966 0 1.75.784 1.75 1.75v5.5A1.75 1.75 0 0 1 10.25 10H7.061l-2.574 2.573A1.458 1.458 0 0 1 2 11.543V10h-.25A1.75 1.75 0 0 1 0 8.25v-5.5C0 1.784.784 1 1.75 1ZM1.5 2.75v5.5c0 .138.112.25.25.25h1a.75.75 0 0 1 .75.75v2.19l2.72-2.72a.749.749 0 0 1 .53-.22h3.5a.25.25 0 0 0 .25-.25v-5.5a.25.25 0 0 0-.25-.25h-8.5a.25.25 0 0 0-.25.25Zm13 2a.25.25 0 0 0-.25-.25h-.5a.75.75 0 0 1 0-1.5h.5c.966 0 1.75.784 1.75 1.75v5.5A1.75 1.75 0 0 1 14.25 12H14v1.543a1.458 1.458 0 0 1-2.487 1.03L9.22 12.28a.749.749 0 0 1 .326-1.275.749.749 0 0 1 .734.215l2.22 2.22v-2.19a.75.75 0 0 1 .75-.75h1a.25.25 0 0 0 .25-.25Z"></path></svg> Discussion</a></li>
</ul>
</div>
</aside>
</div>
</div>
</section>
<footer id="footer" class="footer">
<div class="content has-text-centered">
<p>
<img class="logo" src="assets/logo.svg" alt="logo"/> by <a href="https://yuzutech.fr" target="_blank" rel="noopener noreferrer">Yuzu tech</a>
</p>
<p>
<img class="vertical-exoscale" src="assets/exoscale-RGB-poweredby-positive-vertical.svg" alt="Exoscale"/>
</p>
</div>
</footer>
<script src="js/clipboard.js?v=2.0.6"></script>
<script src="js/prism-core.js?v=1.22.2"></script>
<script src="js/main.js?v=1.1.0"></script>
<script src="js/pako_deflate.min.js?v=1.0.11"></script>
</body>
</html>