Zally · JSON Structure

Zally Api Violation Structure

Violation Object

Type: object Properties: 8 Required: 4
API DesignAPI LintingAPI QualityOpen SourceOpenAPIZalando

Violation is a JSON Structure definition published by Zally, describing 8 properties, of which 4 are required. It conforms to the https://json-structure.org/meta/core/v0/# meta-schema.

Properties

title description violation_type rule_link paths pointer start_line end_line

Meta-schema: https://json-structure.org/meta/core/v0/#

JSON Structure

Raw ↑
{
  "$schema": "https://json-structure.org/meta/core/v0/#",
  "$id": "https://raw.githubusercontent.com/api-evangelist/zally/refs/heads/main/json-structure/zally-api-violation-structure.json",
  "name": "Violation",
  "description": "Violation Object",
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "Violation title",
      "example": "Example Name"
    },
    "description": {
      "type": "string",
      "description": "Violation text",
      "example": "Example description for this resource."
    },
    "violation_type": {
      "$ref": "#/components/schemas/RuleType"
    },
    "rule_link": {
      "type": "string",
      "description": "Violated rule URL",
      "example": "https://example.com/path/abc123"
    },
    "paths": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Violated paths",
      "example": [
        "/var/example/abc.log"
      ]
    },
    "pointer": {
      "type": "string",
      "description": "JsonPointer to the violated path in the specification",
      "example": "example-value"
    },
    "start_line": {
      "type": "int32",
      "example": 1,
      "description": "The line starting the violated location, if known"
    },
    "end_line": {
      "type": "int32",
      "example": 5,
      "description": "The line ending the violated location, if known"
    }
  },
  "required": [
    "title",
    "description",
    "violation_type",
    "paths"
  ]
}