C4System architectureMedium

Subscription billing — C4 context diagram

C4 system context for a billing platform: two kinds of users, one platform boundary, and the payment, tax, and email providers dashed at the edges.

Subscription billing — C4 context diagram preview

What this diagram shows

Step 01
One boundary

Everything the team owns sits inside the platform boundary. Data stores and workers stay out of the context view — they belong one zoom level down.

Step 02
Externals stay dashed

Payment, tax, and email providers render dashed at the edges — fixed dependencies the team integrates with but does not control.

Step 03
Zoom in when needed

The same declaration style scales down a level: swap C4Context for C4Container and break the billing system into its deployable pieces.

About c4 diagrams

C4 diagrams describe a software system at deliberate zoom levels — the system in its environment, the deployable containers inside it, and the components inside those. Use them when an architecture needs to be communicated to different audiences without redrawing from scratch.

This template is written in Mermaid — plain text you can edit, version in git, and regenerate the image from any time.

View Mermaid sourcePlain-text diagram syntax — copy or edit directly.
diagram.mmd
1C4Context
2 title System contextsubscription billing platform
3 Person(customer, "Customer", "Manages plan and payment details")
4 Person(finance, "Finance Team", "Reviews revenue and reconciles payouts")
5 System_Boundary(platform, "Billing platform") {
6 System(billing, "Billing System", "Subscriptions, proration, invoicing, dunning")
7 }
8 System_Ext(psp, "Payment Processor", "Cards, wallets, payouts")
9 System_Ext(tax, "Tax Service", "Tax rates and filings")
10 System_Ext(email, "Email Provider", "Receipts and dunning notices")
11 Rel(customer, billing, "Manages billing in", "HTTPS")
12 Rel(finance, billing, "Reviews revenue in", "HTTPS")
13 BiRel(billing, psp, "Charges and webhooks", "HTTPS")
14 Rel(billing, tax, "Quotes tax", "HTTPS")
15 Rel(billing, email, "Sends receipts", "API")