Skip to main content
A user reaches a gateway, which routes requests to services and storage. This is a relationship overview, not a deployment specification. Microservices architecture diagram rendered from the linked complete source Open the full-size SVG · Download PNG to inspect the connections and labels. The image is generated from the complete source below.

Reproduce this diagram

You need Go 1.25 or later and Git. The complete source is samples/topology/microservice/input.d2.
On Windows, build isotopo.exe and invoke that executable. Open out-microservice/topology.html. Record the revision before adapting the source; the published SVG is regenerated from this source when the renderer or sample changes.

Make it your own

Copy the source to a separate file before editing. Use a text editor for D2 changes; Studio can preview the result.

Rename a service

Change a node label while keeping its ID so its edges remain connected.

Add a dependency

Add a node and an edge in D2, then render again to recompute graph layout.

Inspect a different layout

Render with --layout elk and compare the resulting routes; the best arrangement depends on your graph.

Verify and publish

For your edited copy, substitute its path. Compare the top-down and isometric views, inspect remaining diagnostics, and verify the intended relationship directions. See quality checks and publishing.