Skip to content

Conversation

@SteffenDE
Copy link
Contributor

This commit adds support for the unstable usage reporting over ACP: https://agentclientprotocol.com/rfds/session-usage

I decided to always calculate the totals on each message, but we could also decide to keep this as extra state for an ACP session, so we only need to look at the sdk response for the most recent message.

Closes #12298.

How did you verify your code works?

I verified this with Tidewave, which shows usage information in the UI if supported by the ACP agent.

image

@SteffenDE
Copy link
Contributor Author

SteffenDE commented Feb 5, 2026

Important: There's currently an issue with the ACP typescript SDK where it wants those usage numbers as BigInt, but it fails to then serialize the ACP message. This should be fixed soon and I'll update the PR when it's ready.

Edit: fixed now!

@SteffenDE SteffenDE marked this pull request as draft February 5, 2026 14:06
@github-actions
Copy link
Contributor

github-actions bot commented Feb 5, 2026

The following comment was made by an LLM, it may be inaccurate:

No duplicate PRs found

This commit adds support for the unstable usage reporting
over ACP: https://agentclientprotocol.com/rfds/session-usage

I decided to always calculate the totals on each message, but
we could also decide to keep this as extra state for an ACP
session, so we only need to look at the sdk response for the
most recent message.
@SteffenDE SteffenDE marked this pull request as ready for review February 5, 2026 15:37
@rekram1-node
Copy link
Collaborator

/review

@github-actions
Copy link
Contributor

github-actions bot commented Feb 5, 2026

lgtm

@rekram1-node rekram1-node merged commit 8ddef97 into anomalyco:dev Feb 5, 2026
3 of 4 checks passed
kyashrathore pushed a commit to kyashrathore/Claxedo that referenced this pull request Feb 7, 2026
kyashrathore pushed a commit to kyashrathore/Claxedo that referenced this pull request Feb 8, 2026
fanjia1024 pushed a commit to fanjia1024/opencode that referenced this pull request Feb 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE]: ACP: add session usage reporting

2 participants