Licence lifecycle
proHow the signed licence is verified, refreshed and allowed to lapse, and what happens when the network is gone.
The licence is a signed JSON document at ~/.config/grith/license.key. It carries the account,
team, plan, seat count, issue and expiry timestamps, a feature list and an Ed25519 signature.
The public key is compiled into the binary, so verification is entirely local - grith never
asks a server whether you are entitled, it checks a signature and a date.
Paid licences are issued for 32 days and refreshed daily. The plan string in the licence decides
the tier; [general] plan_tier in your config decides nothing.
Refresh
The daemon runs a licence loop that wakes every hour. On every wake it re-applies the cached licence before doing any network work, so an expired licence downgrades the running daemon to Community within the hour even if it is offline or logged out.
A refresh is due every 24 hours. Force one:
$ grith pro refreshgrith pro refresh reuses the daemon's exact outcome policy, so it behaves identically:
| Outcome | What grith does |
|---|---|
| Fresh licence returned | Written atomically, gate re-applied at once, next refresh in 24h. |
| Transient failure (network, DNS, TLS, 5xx) | Retry after 15 minutes, then 60, then 360. Abandoned after 48 hours and picked up on the normal cadence. |
Hard failure (401, 403, other 4xx, or the server answering valid: false) | The cached licence is kept until its own expiry date. |
⚠️Revocation is not instant
A revoked or unauthorised refresh is a hard failure, and grith deliberately keeps the cached licence rather than rolling a machine back mid-session. Pro ends when the cached licence reaches its expiry date, not when the revocation is issued.
Grace windows
When valid_until passes, Pro does not stop dead.
| Licence | Soft grace | Extended grace | After that |
|---|---|---|---|
| Default | 1 day | up to 3 days | Community |
| Air-gapped contract | 7 days | up to 30 days | Community |
Both grace bands keep Pro features running; grith pro status reports which one you are in and
how many days past expiry you are.
Air-gapped contract licences
Some contract licences carry an air_gapped flag. It is part of the signed payload, set when
the licence is issued, and it changes two things: scheduled refresh is switched off entirely,
and the grace windows widen to 7 and 30 days. grith pro status shows
Refresh: disabled (air-gapped contract licence).
The first licence still arrives over the network - grith pro login has to reach api.grith.ai
once. After that a machine can verify and run on the cached file with no connectivity at all.
Trials
A trial runs 14 days on one seat and grants the full Pro tier. One trial per team and one per email address, recorded permanently, so a second signup does not reset it.
$ grith pro start-trialIf the machine is not linked to an account yet, this runs the browser sign-in first, then activates the trial and installs the licence.
Offline behaviour, in one line
A machine with a valid cached licence keeps full Pro with no network. When the licence expires, grace runs out and the daemon drops to Community on its next hourly wake - no server involved in that decision either.