Tokei::Api::Models::Analysis
Model class representing repository analysis results
Constants
EMPTY_RESULT_JSON = JSON.parse("{}")
Constructors
Class methods
cleanup_old_data
Delete analyses older than the retention period (default: 30 days) Can be configured via RETENTION_DAYS environment variable
Search latest analysis by repository URL without loading large result JSON. Useful for summary/badge flows where only precomputed stats are needed.
Search latest analysis by repository URL with the full result JSON. Useful for flows that need language breakdown data.
Instance methods
analyzed_at
Sourcecode_comment_ratio
Sourceid
Sourcelanguage_count
Sourcerepo_url
Sourceresult
Sourcetop_language
Sourcetop_language_lines
Sourcetotal_blanks
Sourcetotal_code
Sourcetotal_comments
Source