ARISTA-CV-MIB DEFINITIONS ::= BEGIN

IMPORTS
   MODULE-COMPLIANCE,
   OBJECT-GROUP, NOTIFICATION-GROUP      FROM SNMPv2-CONF
   MODULE-IDENTITY, OBJECT-TYPE,
   NOTIFICATION-TYPE                     FROM SNMPv2-SMI
   TEXTUAL-CONVENTION, DateAndTime       FROM SNMPv2-TC
   aristaMibs                            FROM ARISTA-SMI-MIB;

aristaCvMIB MODULE-IDENTITY
   LAST-UPDATED "202305020000Z"  -- 02 May 2023
   ORGANIZATION "Arista Networks, Inc."
   CONTACT-INFO
      "Arista Networks, Inc.

       Postal: 5453 Great America Parkway
               Santa Clara, CA 9505

       Tel: +1 408 547-5500

       E-mail: snmp@arista.com"
   DESCRIPTION  "The MIB for notifications sent by CloudVision (CV)."
      REVISION      "202305020000Z"
      DESCRIPTION
         "Added aristaCvComponents and aristaCvRuleId"
      REVISION           "202207270000Z"
      DESCRIPTION
         "Initial revision."
   ::= { aristaMibs 33 }

-- Textual Conventions
CvString ::= TEXTUAL-CONVENTION
   DISPLAY-HINT "65535t"
   STATUS       current
   DESCRIPTION
      "This data type is used for UTF-8 text sent in CV alert notifications."
   SYNTAX       OCTET STRING

aristaCvNotifications         OBJECT IDENTIFIER ::= { aristaCvMIB 0 }
aristaCvObjects               OBJECT IDENTIFIER ::= { aristaCvMIB 1 }
aristaCvConformance           OBJECT IDENTIFIER ::= { aristaCvMIB 2 }

--
-- ARISTA CV MIB Objects
--

aristaCvAlertEventType OBJECT-TYPE
   SYNTAX CvString
   MAX-ACCESS  accessible-for-notify
   STATUS      current
   DESCRIPTION
      "The type of the event."
   ::= { aristaCvObjects 1 }

aristaCvAlertDescription OBJECT-TYPE
   SYNTAX CvString
   MAX-ACCESS  accessible-for-notify
   STATUS      current
   DESCRIPTION
      "The description of the event."
   ::= { aristaCvObjects 2 }

aristaCvAlertSeverity OBJECT-TYPE
   SYNTAX INTEGER {
      info(1),
      warning(2),
      error(3),
      critical(4)
   }
   MAX-ACCESS  accessible-for-notify
   STATUS      current
   DESCRIPTION
      "The severity of the event."
   ::= { aristaCvObjects 3 }

aristaCvAlertTimestamp OBJECT-TYPE
   SYNTAX DateAndTime
   MAX-ACCESS  accessible-for-notify
   STATUS      current
   DESCRIPTION
      "The timestamp of the alert (fired time/resolved time)."
   ::= { aristaCvObjects 4 }

aristaCvAlertKey OBJECT-TYPE
   SYNTAX CvString
   MAX-ACCESS  accessible-for-notify
   STATUS      current
   DESCRIPTION
      "The key of the event (unique with firing timestamp)."
   ::= { aristaCvObjects 5 }

aristaCvAlertSource OBJECT-TYPE
   SYNTAX CvString
   MAX-ACCESS  accessible-for-notify
   STATUS      current
   DESCRIPTION
      "The URL to the CloudVision page for this event."
   ::= { aristaCvObjects 6 }

aristaCvComponents OBJECT-TYPE
   SYNTAX CvString
   MAX-ACCESS  accessible-for-notify
   STATUS      current
   DESCRIPTION
      "The components associated with this event, in a comma-separated value format; each value
      represents a single component.
      For devices the hostname is used and the device ID is used when hostname is
      unavailable; for interfaces the interface ID is used followed by '@' followed by the
      device component.
      For example: 'device123,Eth1@device123'"
   ::= { aristaCvObjects 7 }

aristaCvRuleId OBJECT-TYPE
   SYNTAX CvString
   MAX-ACCESS  accessible-for-notify
   STATUS      current
   DESCRIPTION
      "The label of the event generation rule which generated this event"
   ::= { aristaCvObjects 8 }

--
-- ARISTA CV MIB Notifications
--

aristaCvAlertFiringNotification NOTIFICATION-TYPE
   OBJECTS {
      aristaCvAlertEventType,
      aristaCvAlertDescription,
      aristaCvAlertSeverity,
      aristaCvAlertTimestamp,
      aristaCvAlertKey,
      aristaCvAlertSource,
      aristaCvComponents,
      aristaCvRuleId
   }
   STATUS             current
   DESCRIPTION
      "Alert for a new firing CloudVision event."
  ::= { aristaCvNotifications 1 }

aristaCvAlertResolvedNotification NOTIFICATION-TYPE
   OBJECTS {
      aristaCvAlertEventType,
      aristaCvAlertDescription,
      aristaCvAlertSeverity,
      aristaCvAlertTimestamp,
      aristaCvAlertKey,
      aristaCvAlertSource,
      aristaCvComponents,
      aristaCvRuleId
   }
   STATUS             current
   DESCRIPTION
      "Alert for a resolved CloudVision event."
  ::= { aristaCvNotifications 2 }

--
-- ARISTA CV MIB Conformance
--

aristaCvCompliances OBJECT IDENTIFIER ::= { aristaCvConformance 1 }
aristaCvGroups      OBJECT IDENTIFIER ::= { aristaCvConformance 2 }

aristaCvCompliance MODULE-COMPLIANCE
   STATUS  current
   DESCRIPTION
      "The compliance statement for SNMP entities which implement
       the ARISTA CV MIB."
   MODULE  -- this module
      MANDATORY-GROUPS { aristaCvObjectsGroup,
                         aristaCvNotificationsGroup
       }
   ::= { aristaCvCompliances 1 }

aristaCvObjectsGroup    OBJECT-GROUP
   OBJECTS {
      aristaCvAlertEventType,
      aristaCvAlertDescription,
      aristaCvAlertSeverity,
      aristaCvAlertTimestamp,
      aristaCvAlertKey,
      aristaCvAlertSource,
      aristaCvComponents,
      aristaCvRuleId
   }
   STATUS  current
   DESCRIPTION
      "The collection of objects in the ARISTA CV MIB."
   ::= { aristaCvGroups 1 }

aristaCvNotificationsGroup  NOTIFICATION-GROUP
   NOTIFICATIONS {
      aristaCvAlertFiringNotification,
      aristaCvAlertResolvedNotification
   }
   STATUS  current
   DESCRIPTION
      "The collection of notifications in the ARISTA CV MIB."
    ::= { aristaCvGroups 2 }

END