Skip to content

Local Traffic Accounting Doc - #1460

Open
thibault-da wants to merge 5 commits into
mainfrom
tj-tea-initial-doc
Open

Local Traffic Accounting Doc#1460
thibault-da wants to merge 5 commits into
mainfrom
tj-tea-initial-doc

Conversation

@thibault-da

Copy link
Copy Markdown
Contributor

No description provided.

@mintlify

mintlify Bot commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
cantonfoundation 🟢 Ready View Preview Aug 25, 2026, 5:01 PM

💡 Tip: Enable Workflows to automatically generate PRs for you.

@thibault-da thibault-da changed the title Tj tea initial doc Local Traffic Accounting Doc Aug 25, 2026
The Ledger API exposes a service to interact with traffic accounts, available when
`traffic-enforcement.enabled = true`.

- gRPC service: https://github.com/digital-asset/canton/blob/main/community/traffic-enforcement/api/protobuf/com/digitalasset/canton/tea/v1/traffic_service.proto

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will update to a link to the reference API in the doc itself when available


- gRPC service: https://github.com/digital-asset/canton/blob/main/community/traffic-enforcement/api/protobuf/com/digitalasset/canton/tea/v1/traffic_service.proto

The same service is also available on the JSON API.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

@thibault-da

Copy link
Copy Markdown
Contributor Author

For some reason the mermaid diagrams don't render in the preview 🤷‍♂️

Accounting and enforcement are two separate switches, both disabled by default:

```hocon
canton.participants.<participant_name>.traffic-enforcement {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm thinking to bite the bullet and change the root-level name of the config to traffic-accounting since it's still not a GA-level feature. Not impacting this PR of course

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah good point. let's do it for 3.6. We can even cleanly deprecate it, it doesn't cost much more and avoid backwards compatibiliy discussion headaches, then we remove in 3.7

}
```

When `enabled` is false, the `TrafficService` is not exposed on the Ledger API, no accounting is performed, and no

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We didn't yet introduce the TrafficService. Can you introduce it briefly so clients don't need to interrupt the reading flow to search for it? Also, let's specify the HTTP endpoint as well (as that's actually what clients care about on LAPI): /traffic/accounts

@tudor-da tudor-da left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, nice stuff @thibault-da !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants