Skip to content

Upload generic MCP and inference metering to web-auth#67

Open
JaeLeex wants to merge 1 commit into
jl/mcp-trade-noninteractive-20260701from
jl/mcp-generic-metering-upload-20260701
Open

Upload generic MCP and inference metering to web-auth#67
JaeLeex wants to merge 1 commit into
jl/mcp-trade-noninteractive-20260701from
jl/mcp-generic-metering-upload-20260701

Conversation

@JaeLeex

@JaeLeex JaeLeex commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Adds cli/mcp_metering.py to POST generic rows to web-auth /api/metering/usage.
  • Reports allowed MCP tool calls from entitlement checks and inference cost from cost_metering.
  • Keeps upload inactive unless NUNCHI_METERING_URL, NUNCHI_METERING_TOKEN, and NUNCHI_ACCOUNT_ID are set.

Stack

Test plan

  • python3 -m pytest tests/test_mcp_metering.py -q
  • Run hosted runner with metering env and verify rows appear in web-auth /api/metering/status

Made with Cursor

Report allowed MCP tool calls and inference cost events to /api/metering/usage when runner metering env is configured.

Co-authored-by: Cursor <cursoragent@cursor.com>
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.

1 participant