Container Diagram¶
c4.diagrams.container.ContainerDiagram ¶
c4.diagrams.container.Container ¶
Bases: Element
Represents an application or service container in a C4 Container diagram.
A container can be a web application, API, worker, or any executable unit of deployment. It may optionally include technology and shape hints.
__init__ ¶
__init__(
label: str | Required = not_provided,
description: str = "",
technology: str = "",
sprite: str = "",
tags: str = "",
link: str = "",
base_shape: str = "",
alias: str | EmptyStr = empty,
) -> None
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
label
|
str | Required
|
Human-readable name of the container. |
not_provided
|
description
|
str
|
Optional description of the container's purpose. |
''
|
technology
|
str
|
The technology stack used by the container. |
''
|
sprite
|
str
|
Optional sprite identifier for visual representation. |
''
|
tags
|
str
|
Comma-separated tags for filtering or styling. |
''
|
link
|
str
|
Optional URL for external documentation or navigation. |
''
|
base_shape
|
str
|
Optional base shape override for rendering. |
''
|
alias
|
str | EmptyStr
|
Unique identifier for the container. |
empty
|
c4.diagrams.container.ContainerDb ¶
c4.diagrams.container.ContainerQueue ¶
c4.diagrams.container.ContainerExt ¶
c4.diagrams.container.ContainerDbExt ¶
c4.diagrams.container.ContainerQueueExt ¶
c4.diagrams.container.ContainerBoundary ¶
Bases: Boundary
Represents a boundary grouping containers within a system.
__init__ ¶
__init__(
label: str | Required = not_provided,
description: str = "",
tags: str = "",
link: str = "",
alias: str | EmptyStr = empty,
) -> None
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
label
|
str | Required
|
Displayed label of the boundary. Defaults to |
not_provided
|
description
|
str
|
Optional human-readable description of the boundary. |
''
|
tags
|
str
|
Optional comma-separated tags for styling or filtering. |
''
|
link
|
str
|
URL associated with the boundary for navigation or documentation. |
''
|
alias
|
str | EmptyStr
|
Unique identifier for the boundary. |
empty
|