57 lines
		
	
	
		
			1.7 KiB
		
	
	
	
		
			JSON
		
	
	
	
	
	
			
		
		
	
	
			57 lines
		
	
	
		
			1.7 KiB
		
	
	
	
		
			JSON
		
	
	
	
	
	
{
 | 
						|
  "$id": "https://stella-ops.org/schemas/notify/notify-event@1.json",
 | 
						|
  "$schema": "http://json-schema.org/draft-07/schema#",
 | 
						|
  "title": "Notify Event Envelope",
 | 
						|
  "type": "object",
 | 
						|
  "required": ["eventId", "kind", "tenant", "ts", "payload"],
 | 
						|
  "properties": {
 | 
						|
    "eventId": {"type": "string", "format": "uuid"},
 | 
						|
    "kind": {
 | 
						|
      "type": "string",
 | 
						|
      "description": "Event kind identifier (e.g. scanner.report.ready).",
 | 
						|
      "enum": [
 | 
						|
        "scanner.report.ready",
 | 
						|
        "scanner.scan.completed",
 | 
						|
        "scheduler.rescan.delta",
 | 
						|
        "attestor.logged",
 | 
						|
        "zastava.admission",
 | 
						|
        "feedser.export.completed",
 | 
						|
        "vexer.export.completed"
 | 
						|
      ]
 | 
						|
    },
 | 
						|
    "version": {"type": "string"},
 | 
						|
    "tenant": {"type": "string"},
 | 
						|
    "ts": {"type": "string", "format": "date-time"},
 | 
						|
    "actor": {"type": "string"},
 | 
						|
    "scope": {
 | 
						|
      "type": "object",
 | 
						|
      "properties": {
 | 
						|
        "namespace": {"type": "string"},
 | 
						|
        "repo": {"type": "string"},
 | 
						|
        "digest": {"type": "string"},
 | 
						|
        "component": {"type": "string"},
 | 
						|
        "image": {"type": "string"},
 | 
						|
        "labels": {"$ref": "#/$defs/stringMap"},
 | 
						|
        "attributes": {"$ref": "#/$defs/stringMap"}
 | 
						|
      },
 | 
						|
      "additionalProperties": false
 | 
						|
    },
 | 
						|
    "payload": {
 | 
						|
      "type": "object",
 | 
						|
      "description": "Event specific body; see individual schemas for shapes.",
 | 
						|
      "additionalProperties": true
 | 
						|
    },
 | 
						|
    "attributes": {"$ref": "#/$defs/stringMap"}
 | 
						|
  },
 | 
						|
  "additionalProperties": false,
 | 
						|
  "$defs": {
 | 
						|
    "stringMap": {
 | 
						|
      "type": "object",
 | 
						|
      "patternProperties": {
 | 
						|
        ".*": {"type": "string"}
 | 
						|
      },
 | 
						|
      "additionalProperties": false
 | 
						|
    }
 | 
						|
  }
 | 
						|
}
 |