मुख्य सामग्री पर जाएँ
Skillpedia
विविध81k · #1600

cost-export

यह क्या करती है

यह स्किल आपका दर्ज AI खर्च का डेटा ऐसे रूप में सहेजती है जिसे दूसरे मॉनिटरिंग टूल दिखा सकें। जो लोग अपना AI खर्च किसी साझा डैशबोर्ड पर देखना चाहते हैं, उनके लिए यह है।

कब इस्तेमाल करें

  • ✓जब आप चाहते हों कि AI खर्च Grafana या किसी मिलते-जुलते डैशबोर्ड पर दिखे।
  • ✓जब आप रिपोर्टिंग के लिए खर्च का सारांश किसी वेब पते पर भेजना चाहें।
  • ✓जब आप चाहते हों कि खर्च का डेटा शेड्यूल पर नियमित रूप से ताज़ा हो।

Skill का लिंक

https://github.com/ruvnet/ruflo/blob/main/plugins/ruflo-cost-tracker/skills/cost-export/SKILL.md

इसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।

कैसे इस्तेमाल करें

सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।

पेस्ट करने के लिए तैयार मैसेज

इस skill से मेरी मदद करो: https://github.com/ruvnet/ruflo/blob/main/plugins/ruflo-cost-tracker/skills/cost-export/SKILL.md इस लिंक की SKILL.md फ़ाइल पढ़ो और मेरे काम में उसके निर्देशों का पालन करो।
क्या आप चाहते हैं कि आपका AI ऐसी skills खुद ढूँढे?मुफ़्त Skillpedia MCP इंस्टॉल करें: बस एक लाइन, और हर काम से पहले यह 15,000+ skills में खोजता है।1 मिनट में इंस्टॉल करें →

AI से क्या माँगें: उदाहरण

“मेरा AI खर्च का डेटा निर्यात कीजिए, ताकि मैं उसे अपने डैशबोर्ड पर देख सकूँ।”

हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।

यह कैसे काम करती है

स्किल सहेजे गए खर्च रिकॉर्ड पढ़ती है और उन्हें या तो Prometheus के लिए टेक्स्ट फ़ाइल में लिखती है, या आपके दिए वेब पते पर JSON संदेश के रूप में भेजती है। बिना फ़्लैग के यह स्क्रीन पर JSON दिखाती है।

तकनीकी सामग्री (मूल SKILL.md)

लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।

Cost Export

Pulls every session-* and budget-config-* record from cost-tracking and emits in formats consumable by external observability systems. Without this, cost data lives only inside the AgentDB namespace; with it, the same data lights up dashboards.

When to use

  • After any cost-track run, to refresh metrics for Grafana / Datadog / Prometheus.
  • Cron-friendly via /loop 5m to keep external dashboards near-real-time.
  • One-shot to a webhook for ad-hoc reporting (Slack, custom endpoint).

Steps

  1. Pick a format — textfile collector for Prometheus / Grafana, or webhook POST for everything else:

    # Prometheus node_exporter textfile collector
    node plugins/ruflo-cost-tracker/scripts/export.mjs --prometheus /var/lib/node_exporter/textfile_collector/cost_tracker.prom
    
    # Webhook (POSTs JSON; add auth via env)
    EXPORT_WEBHOOK_HEADER='Authorization: Bearer $TOKEN' \
      node plugins/ruflo-cost-tracker/scripts/export.mjs --webhook https://hooks.example.com/cost-tracker
    
    # Stdout JSON (default if no flag)
    node plugins/ruflo-cost-tracker/scripts/export.mjs
    
  2. Inspect what's emitted — Prometheus output includes:

    cost_tracker_total_usd                                    <gauge>
    cost_tracker_tier_total_usd{tier="opus|sonnet|haiku"}     <gauge>
    cost_tracker_session_total_usd{session="<8-char>"}        <gauge>
    cost_tracker_session_messages{session="<8-char>"}         <counter>
    cost_tracker_budget_usd                                   <gauge>  (if budget configured)
    cost_tracker_budget_utilization                           <gauge>  (spent / budget)
    
  3. Webhook payload shape — the JSON the webhook receives matches the stdout JSON: { exportedAt, sessions: [...], budget, totalUsd, byTier }. Headers may be added via EXPORT_WEBHOOK_HEADER='K1: V1, K2: V2' (comma-separated).

Env overrides

Env Default Purpose
EXPORT_NAMESPACE cost-tracking Override target namespace
EXPORT_WEBHOOK_HEADER unset Comma-separated K: V pairs for webhook auth
EXPORT_QUIET=1 unset Suppress non-error confirmation output

Cross-references

  • cost-track — produces the data this skill exports
  • cost-budget-check — the same cost_tracker_budget_* metrics are alertable in Prometheus
  • node_exporter textfile collector docs (Prometheus convention) — drop the .prom file in the collector directory and Prometheus picks it up
अक्सर पूछे जाने वाले सवाल

Prometheus टेक्स्ट फ़ाइल क्या है?

यह एक सादी फ़ाइल है जिसमें मीट्रिक की पंक्तियाँ होती हैं, जिन्हें node exporter कलेक्टर पढ़कर डैशबोर्ड पर दिखा सकता है।

क्या वेबहुक में लॉगिन जोड़ सकते हैं?

हाँ। एक एनवायरनमेंट सेटिंग अनुरोध के साथ हेडर भेज सकती है, जैसे ऑथराइज़ेशन टोकन।

क्या यह डिफ़ॉल्ट रूप से कहीं डेटा भेजती है?

नहीं। आप फ़ाइल या वेबहुक विकल्प न चुनें तो यह स्क्रीन पर JSON दिखाती है।

जानकारी

लेखक का मूल विवरण

Export cost-tracking telemetry in Prometheus textfile or webhook JSON formats — for external observability (Grafana, Datadog, custom dashboards)

repo: ruvnet/ruflo

लोकप्रियता

GitHub स्टार
81k
रैंकिंग में स्थान
#1600
लाइसेंस
MIT
अपडेट की गई
2/11/2026

क्या यह skill काम की है?

0

लॉग इन करें वोट करने के लिए।

कमेंट

  • …

इस repository की और skills

agent-adaptive-coordinator

81k

आपके एजेंट को काम बदलने पर AI एजेंटों के समूह को बाँटने और फिर से संतुलित करने में मदद करती है, और काम के हिसाब से लेआउट चुनती है।

AI और एजेंटएजेंट

agent-agent

81k

आपके एजेंट को बड़े लक्ष्य को क्रमबद्ध कार्यों की योजना में बदलना सिखाती है, और स्थिति बदलने पर योजना फिर से बनाना भी।

AI और एजेंटएजेंट

agent-agentic-payments

81k

AI खरीदारी के लिए खर्च के आदेश मैनेज करने में मदद करती है, जिसमें खर्च की सीमा, समय अवधि, व्यापारी नियम और signed मंज़ूरियाँ शामिल हैं।

AI और एजेंटएजेंट

agent-analyze-code-quality

81k

आपके एजेंट को कोड की गुणवत्ता जाँचने में मदद करती है, बिना फ़ाइलें बदले code smells, technical debt और refactoring के सुझाव खोजकर।

कोडिंगसामान्य कोडिंग

मिलती-जुलती skills