syntax = "proto3"; import "buf/validate/validate.proto"; package audit.v1; option go_package = "./audit;auditV1"; option java_multiple_files = true; option java_package = "com.schwarz.stackit.audit.v1"; enum ObjectName { OBJECT_NAME_UNSPECIFIED = 0; // If the action happens on system level and doesn't relate to a known ObjectType. OBJECT_NAME_SYSTEM = 1; } // The type of the object the audit event refers to. // Relevant for type-detection and lookups in the routing. enum ObjectType { OBJECT_TYPE_UNSPECIFIED = 0; OBJECT_TYPE_ORGANIZATION = 1; OBJECT_TYPE_FOLDER = 2; OBJECT_TYPE_PROJECT = 3; } message ObjectIdentifier { // Identifier of the respective entity (e.g. Identifier of an organization) string identifier = 1 [(buf.validate.field).required = true, (buf.validate.field).string.uuid = true]; // Type of the respective entity relevant for routing ObjectType type = 2 [(buf.validate.field).required = true, (buf.validate.field).enum.defined_only = true]; }