Skip to content

docs(balance): document auto-refill behavior and account-menu indicator#583

Draft
Odrec wants to merge 2 commits into
LibreChat-AI:mainfrom
Odrec:docs/balance-refill-behavior
Draft

docs(balance): document auto-refill behavior and account-menu indicator#583
Odrec wants to merge 2 commits into
LibreChat-AI:mainfrom
Odrec:docs/balance-refill-behavior

Conversation

@Odrec
Copy link
Copy Markdown
Contributor

@Odrec Odrec commented May 21, 2026

Summary

Add an "Auto-refill behavior" section to the Balance object docs (librechat_yaml/object_structure/balance.mdx). Today, the page documents each individual config field but doesn't explain when a refill actually happens, which has been a source of user confusion.

The new section covers:

  • The two conditions a refill requires (tokenCredits ≤ 0 and the configured interval elapsed since the last refill).
  • The two triggers that apply the refill (sending a message and opening the app — the balance endpoint also runs the same eligibility check).
  • The semantics of a fresh user (no lastRefill set until a real refill happens; startBalance carries them until depletion).
  • The new account-settings popover indicator: green (+refillAmount) badge for 24 h after a refill (with a timestamp tooltip), or a muted "Next refill in X days" subtext otherwise.

Related

Tracks the LibreChat feature PR that introduces eager refill on balance read and the popover indicator: danny-avila/LibreChat#13233.

This docs PR is opened as a draft so it can be linked from the feature PR. It should be merged after the feature PR is merged and reaches a release, so the docs don't describe behavior that isn't yet shipped.

Add an "Auto-refill behavior" section to the Balance object docs covering:

- The two conditions a refill requires (balance ≤ 0 + interval elapsed).
- The two triggers (message send and balance read on app open).
- The semantics of a fresh user with no lastRefill.
- The green (+refillAmount) badge + "Next refill in X days" subtext shown
  in the account-settings popover.

Tracks LibreChat PR danny-avila/LibreChat#13233.
@vercel
Copy link
Copy Markdown

vercel Bot commented May 21, 2026

Someone is attempting to deploy a commit to the LibreChat's projects Team on Vercel.

A member of the Team first needs to authorize it.

Match the refreshed UX in danny-avila/LibreChat#13233 review round:
the green (+refillAmount) badge now signals refill availability
(useful spending headroom) rather than a 24h "just refilled" window,
and the "Next refill in X days" subtext only appears when the user
is actually waiting (balance at zero and not yet eligible).
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