---
title: "usage-bar"
url: "https://claudemods.dev/ja/builds/usage-bar-2760b5"
source: "https://github.com/jimmyeao/claude-code-bars/tree/main/plugins/usage-bar"
source_type: "github"
repo: "https://github.com/jimmyeao/claude-code-bars/tree/main/plugins/usage-bar"
author: "jimmyeao"
author_handle: "jimmyeao"
stars: 0
category: "ダッシュボード・HUD"
categories: ["hud"]
tags: ["above-prompt", "cost", "hooks", "plugin", "rate-limits", "statusline", "usage"]
permission_level: 0
scan_complete: true
install: "claude plugin marketplace add jimmyeao/claude-code-bars\nclaude plugin install usage-bar"
added: "2026-10-05T19:41:59.560Z"
updated: "2026-10-03T15:51:58Z"
locale: "ja"
content_locale: "ja"
---

# usage-bar

プランの使用量制限をプロンプト上部に時間枠ごとの色付きバーで表示し、時計の進みより速く使っている時間枠を示します。`/usage-bar` で切り替えます。

## Description

# usage-bar

プランの使用量制限をプロンプト上部にバーで表示し、時計の進みより速く使っている時間枠を示します（表示例であり、実際の数値ではありません）。

```
Usage  ·  amber = using a window faster than its clock  ·  session $12.19
Session █████████████████████░░░░░  79% used  ·  47% of time  ·  32 pts ahead of the clock  ·  resets in 2h 40m
Week    ███░░░░░░░░░░░░░░░░░░░░░░░  10% used  ·  61% of time  ·  resets in 2d 18h
```

- **制限時間枠ごとに 1 本のバー**：エンジンが報告するのは `Session`（5 時間）、`Week`（7 日）、ゲートウェイの支出制限を表す `Spend` です。色は時間枠を示します。塗りつぶし部分が使用済み、網掛け部分が残りです。
- **`% of time`** は、リセット時刻から計算した時間枠の経過割合です。
- **フラグ**は表示された 2 つの数値を比較します。5 ポイントを超えて先行すると `% used` がアンバーになり、`N pts ahead of the clock` が追加されます。25 ポイントを超えて先行するか、使用量が 95% 以上になると赤になります。長さが不明な時間枠（支出制限）には時計がないため、ほぼ満杯のときだけフラグが付きます。
- **セッションコスト**はヘッダー行に表示されます。

## 使い方

`/usage-bar` で切り替えます。各セッションでは最初から有効です。

## 仕組み

- `$.session.usage()` から、直近の API 応答に含まれるレート制限時間枠とセッションコストを読み取ります。
- 各プロンプトとターン完了後に更新し、カウントダウンが進み続けるよう 1 分ごとにも更新します。
- `AbovePrompt` バンドに描画し、そこに描画する他のバンドの上に重ねます。アンケート表示中は場所を空けます。

## 制限

- エンジンが報告する時間枠だけを表示します。モデル別の行（たとえば Sonnet のみ）はないため、`/usage` のすべての行とは一致しません。
- サブスクリプションプランを利用していない場合は描画する制限がなく、"No plan limits reported for this account." と表示します。
- 時間枠の長さは 5 時間と 7 日と仮定します。実際の長さが異なる場合、`% of time` は概算です。

## Install

```
claude plugin marketplace add jimmyeao/claude-code-bars
claude plugin install usage-bar
```

## Original README

# usage-bar

Draws your plan usage limits as bars above the prompt, and flags a window you are using faster than its clock (illustrative output, not real figures):

```
Usage  ·  amber = using a window faster than its clock  ·  session $12.19
Session █████████████████████░░░░░  79% used  ·  47% of time  ·  32 pts ahead of the clock  ·  resets in 2h 40m
Week    ███░░░░░░░░░░░░░░░░░░░░░░░  10% used  ·  61% of time  ·  resets in 2d 18h
```

- **One bar per limit window** the engine reports: `Session` (5 hours), `Week` (7 days), and `Spend` for a gateway spend limit. The colour says which window it is. The solid part is what you have used, the shaded part is what is left.
- **`% of time`** is how much of the window has already passed, worked out from its reset time.
- **The flag** compares the two printed numbers. More than 5 points ahead turns `% used` amber and adds `N pts ahead of the clock`. More than 25 points ahead, or 95% used or more, turns it red. A window with no known length (the spend limit) has no clock, so it is flagged only when nearly full.
- **Session cost** appears in the header line.

## Use

`/usage-bar` toggles it. It starts on in every session.

## How it works

- Reads `$.session.usage()`: the rate-limit windows from the last API response, and the session cost.
- Refreshes after each prompt and finished turn, and once a minute so the countdowns keep moving.
- Draws in the `AbovePrompt` band, on top of whatever other band mods draw there. It steps aside while a survey is showing.

## Limits

- It shows only the windows the engine reports. There are no per-model rows (for example Sonnet-only), so it will not match every line of `/usage`.
- Off a subscription plan there are no limits to draw, and it says "No plan limits reported for this account."
- The 5-hour and 7-day window lengths are assumed. If a window is not exactly that long, `% of time` is approximate.
