Expand description
License validation for Logicaffeine verification.
Uses the Stripe-based license system. License keys are Stripe subscription
IDs (sub_* format) validated against the Logicaffeine API.
§Usage
ⓘ
use logicaffeine_verify::LicenseValidator;
let validator = LicenseValidator::new();
match validator.validate("sub_abc123xyz") {
Ok(plan) => println!("License valid: {} plan", plan),
Err(e) => eprintln!("License error: {}", e),
}§License Tiers
| Plan | Verification | Price |
|---|---|---|
| Free | No | $0 |
| Supporter | No | $5/mo |
| Pro | Yes | $25/mo |
| Premium | Yes | $50/mo |
| Lifetime | Yes | $50/seat |
| Enterprise | Yes | Custom |
§Validation Flow
- Format check: Key must start with
sub_ - Cache check: Return cached result if fresh (< 24 hours)
- API validation: Call
api.logicaffeine.com/validate - Fallback: Use stale cache if network fails
§Caching
Results are cached for 24 hours at:
- macOS/Linux:
~/.cache/logos/verification_license.json - Windows:
%LOCALAPPDATA%\logos\verification_license.json
Structs§
- License
Validator - License validator that checks keys against the API with caching.
Enums§
- License
Plan - License plan tiers.