Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/joranhonig/pydantic-sarif


https://github.com/joranhonig/pydantic-sarif

Last synced: about 1 month ago
JSON representation

Awesome Lists containing this project

README

        

# PySarif

This is a simple pydantic model for the SARIF format, generated with datamodel-codegen.

## Installation

```bash
pip install pysarif
```

### Usage
`StaticAnalysisResultsFormatSarifVersion210JsonSchema` is likely the class that you'll be referencing the most.

## Example

```python
from pydantic_sarif.model import StaticAnalysisResultsFormatSarifVersion210JsonSchema as Report

example_json = """
"""
report: Report = Report.parse_raw(example_json)

assert report.version == "2.1.0"
```