home-ops-public

APIレート制限パターン / API Rate Limit Pattern

Public-safe pattern for small home-ops automations that call GitHub, a password manager, VPN APIs, or AI tools.

GitHub、password manager、VPN API、AI toolsを使う小さな自宅運用自動化向けの公開用パターンです。

原則 / Principles

推奨動作 / Suggested Behavior

State Action
Healthy / no change local log only
Temporary 429 backoff and retry a few times
Repeated 429 stop and notify operations channel
Needs approval create/update one GitHub issue
Needs human work create/update one GitHub issue

backoff例 / Backoff Shape

attempt 1: wait 10s
attempt 2: wait 40s
attempt 3: wait 90s
attempt 4: wait 160s
attempt 5: stop and report

Use the service-provided Retry-After header when available.

Retry-After headerがある場合は、それを優先します。

password managerの注意 / Password Manager Note

Password manager APIs can be the first bottleneck in a home automation stack.

自宅運用では、GitHubよりpassword managerの制限が先に詰まることがあります。

Recommended:

GitHubの注意 / GitHub Note

For small repos, GitHub App or Actions limits are usually enough if polling is low-frequency.

小規模repoなら、低頻度pollingであればGitHub AppやActionsの制限は通常十分です。

Still: