Skip to content

Sequence

Best for a request/response exchange — who calls whom, in order, and what each message carries.

sequenceDiagram
actor User
participant Web as Web Client
Web->>API: POST /login {email, pw}
API-->>Web: 200 {token}
API->>API: validate

Arrows: ->> call, -->> dashed reply, -> / -->, -x lost, -) async. Text after : is the message. participant X as Label aliases; actor X draws a person. Note over X: text (also left of / right of) pins a note to a lifeline.

alt / loop / opt / par blocks are accepted but their grouping frames don’t render — keep the flow linear.