Skip to content

API Reference parrot_tools.cloudsploit.reports

github-actions[bot] edited this page Dec 2, 2026 · 4 revisions

parrot_tools.cloudsploit.reports

View source

Report generator for CloudSploit scan results.

Produces HTML and PDF reports from scan results and comparison data. Uses Jinja2 for templating and xhtml2pdf for PDF generation.

Alias ComparisonReport

Re-exported from parrot_tools.cloudsploit.models.ComparisonReport.

Attribute DEFAULT_MAX_FINDINGS

Alias EcrCollectionResult

Re-exported from parrot_tools.cloudsploit.models.EcrCollectionResult.

Alias EcrSeverity

Re-exported from parrot_tools.cloudsploit.models.EcrSeverity.

Class ReportGenerator

Generates HTML and PDF reports from CloudSploit scan results.

Reports include executive summary, severity breakdown charts, category breakdown, and detailed findings tables.

Method ReportGenerator.generate_html

Generate HTML report from scan results.

generate_html(result: ScanResult, output_path: Optional[str] = None, max_findings: int = DEFAULT_MAX_FINDINGS) -> str

Parameter Type Default Description
result ScanResult CloudSploit scan result.
output_path Optional[str] None File path to save report. If None, returns HTML string.
max_findings int DEFAULT_MAX_FINDINGS Maximum findings to include in the table.

Returns: str — HTML string if output_path is None, otherwise the file path.

Method ReportGenerator.generate_pdf

Generate PDF report from scan results.

generate_pdf(result: ScanResult, output_path: str, max_findings: int = DEFAULT_MAX_FINDINGS) -> str

Parameter Type Default Description
result ScanResult CloudSploit scan result.
output_path str File path to save the PDF.
max_findings int DEFAULT_MAX_FINDINGS Maximum findings to include in the table.

Returns: str — The file path of the generated PDF.

Method ReportGenerator.generate_comparison_html

Generate HTML comparison report.

generate_comparison_html(comparison: ComparisonReport, output_path: Optional[str] = None) -> str

Parameter Type Default Description
comparison ComparisonReport Comparison between two scan results.
output_path Optional[str] None File path to save report. If None, returns HTML string.

Returns: str — HTML string if output_path is None, otherwise the file path.

Method ReportGenerator.generate_comparison_pdf

Generate PDF comparison report.

generate_comparison_pdf(comparison: ComparisonReport, output_path: str) -> str

Parameter Type Default Description
comparison ComparisonReport Comparison between two scan results.
output_path str File path to save the PDF.

Returns: str — The file path of the generated PDF.

Method ReportGenerator.generate_ecr_html

Render an interactive HTML vulnerability report from ECR scan data.

Builds a view-model from result — sorting repos, grouping CVEs by package, truncating descriptions, resolving severity colours — then renders ecr_scan_report.html via the existing Jinja2 env.

generate_ecr_html(result: EcrCollectionResult, output_path: Optional[str] = None) -> str

Parameter Type Default Description
result EcrCollectionResult Collected ECR scan findings.
output_path Optional[str] None File path to write the HTML to. Parent directories are created automatically. When None, the rendered HTML string is returned instead.

Returns: str — Rendered HTML string when output_path is None, otherwise the absolute path of the written file (as a str).

Alias ScanResult

Re-exported from parrot_tools.cloudsploit.models.ScanResult.

Architecture

Clients

Bots & Agents

Memory

Knowledge

Tools & Toolkits

Flows

Experts

Skills

Stores & Loaders

MCP & A2A

Server & APIs

Integrations

Outputs & A2UI

Prompts

Security

Operations

Migration

SDD Tooling

LLM Wiki

Deployment

Decisions

API Reference

Clone this wiki locally