cloudvision.api.arista.auditlog.v1 package
Module contents
- class cloudvision.api.arista.auditlog.v1.Attributes(user: str | None = <PLACEHOLDER>, timestamp: ~datetime.datetime = <PLACEHOLDER>, severity: ~cloudvision.api.arista.auditlog.v1.Severity = <PLACEHOLDER>, device_name: str | None = <PLACEHOLDER>, service: str | None = <PLACEHOLDER>, message: str | None = <PLACEHOLDER>, tags: ~cloudvision.api.fmp.MapStringString = <PLACEHOLDER>)[source]
Bases:
MessageAttributes are fields that make up the audit log.
- device_name: str | None = <PLACEHOLDER>
device_name of the device for which audit log is sent.
- message: str | None = <PLACEHOLDER>
message in the audit log. eg: “user logged in”
- service: str | None = <PLACEHOLDER>
service name for which audit log is added. eg: aaa, accesscontrol, inventory
- severity: Severity = <PLACEHOLDER>
severity is level of importance or urgency of the audit log message. eg: Debug, Info, Error
- tags: ___fmp__.MapStringString = <PLACEHOLDER>
tags associated with the audit log. eg: tags: {mnemonic: DEVICE_PROVISIONING_SUCCESS}
- timestamp: datetime = <PLACEHOLDER>
timestamp at which the log was generated. eg: 2006-01-02T15:04:05.000Z
- user: str | None = <PLACEHOLDER>
user is the CloudVision user to which the log corresponds to.
- class cloudvision.api.arista.auditlog.v1.Auditlog(key: ~cloudvision.api.arista.auditlog.v1.AuditlogKey = <PLACEHOLDER>, attributes: ~cloudvision.api.arista.auditlog.v1.Attributes = <PLACEHOLDER>, log: str | None = <PLACEHOLDER>)[source]
Bases:
MessageAuditlog contains the different fields as well as the formatted log.
- attributes: Attributes = <PLACEHOLDER>
attributes are the different fields that make up the audit log.
- key: AuditlogKey = <PLACEHOLDER>
key is the unique key for each message.
- log: str | None = <PLACEHOLDER>
log is the formatted log message containing the different attributes including timestamp, serviceName, severity , userName in addition to the message. May 17 12:50:54 host service Message: user logged in, User: abc
- class cloudvision.api.arista.auditlog.v1.AuditlogKey(id: str | None = <PLACEHOLDER>)[source]
Bases:
MessageAuditlogKey is the unique key for each message.
- id: str | None = <PLACEHOLDER>
id is the unique uuid for an audit log.
- class cloudvision.api.arista.auditlog.v1.AuditlogRequest(key: 'AuditlogKey' = <PLACEHOLDER>, time: datetime.datetime = <PLACEHOLDER>)[source]
Bases:
Message- key: AuditlogKey = <PLACEHOLDER>
Key uniquely identifies a Auditlog instance to retrieve. This value must be populated.
- time: datetime = <PLACEHOLDER>
Time indicates the time for which you are interested in the data. If no time is given, the server will use the time at which it makes the request.
- class cloudvision.api.arista.auditlog.v1.AuditlogResponse(value: 'Auditlog' = <PLACEHOLDER>, time: datetime.datetime = <PLACEHOLDER>)[source]
Bases:
Message- time: datetime = <PLACEHOLDER>
Time carries the (UTC) timestamp of the last-modification of the Auditlog instance in this response.
- class cloudvision.api.arista.auditlog.v1.AuditlogServiceBase[source]
Bases:
ServiceBase- async get_all(auditlog_stream_request: AuditlogStreamRequest) AsyncIterator[AuditlogStreamResponse][source]
- async get_meta(auditlog_stream_request: AuditlogStreamRequest) MetaResponse[source]
- async get_one(auditlog_request: AuditlogRequest) AuditlogResponse[source]
- async get_some(auditlog_some_request: AuditlogSomeRequest) AsyncIterator[AuditlogSomeResponse][source]
- async subscribe(auditlog_stream_request: AuditlogStreamRequest) AsyncIterator[AuditlogStreamResponse][source]
- async subscribe_meta(auditlog_stream_request: AuditlogStreamRequest) AsyncIterator[MetaResponse][source]
- class cloudvision.api.arista.auditlog.v1.AuditlogServiceStub(channel: Channel, *, timeout: float | None = None, deadline: Deadline | None = None, metadata: Mapping[str, str | bytes] | Collection[Tuple[str, str | bytes]] | None = None)[source]
Bases:
ServiceStub- async get_all(auditlog_stream_request: AuditlogStreamRequest, *, timeout: float | None = None, deadline: Deadline | None = None, metadata: MetadataLike | None = None) AsyncIterator[AuditlogStreamResponse][source]
- async get_meta(auditlog_stream_request: AuditlogStreamRequest, *, timeout: float | None = None, deadline: Deadline | None = None, metadata: MetadataLike | None = None) MetaResponse[source]
- async get_one(auditlog_request: AuditlogRequest, *, timeout: float | None = None, deadline: Deadline | None = None, metadata: MetadataLike | None = None) AuditlogResponse[source]
- async get_some(auditlog_some_request: AuditlogSomeRequest, *, timeout: float | None = None, deadline: Deadline | None = None, metadata: MetadataLike | None = None) AsyncIterator[AuditlogSomeResponse][source]
- async subscribe(auditlog_stream_request: AuditlogStreamRequest, *, timeout: float | None = None, deadline: Deadline | None = None, metadata: MetadataLike | None = None) AsyncIterator[AuditlogStreamResponse][source]
- async subscribe_meta(auditlog_stream_request: AuditlogStreamRequest, *, timeout: float | None = None, deadline: Deadline | None = None, metadata: MetadataLike | None = None) AsyncIterator[MetaResponse][source]
- class cloudvision.api.arista.auditlog.v1.AuditlogSomeRequest(keys: List[ForwardRef('AuditlogKey')] = <PLACEHOLDER>, time: datetime.datetime = <PLACEHOLDER>)[source]
Bases:
Message- keys: List[AuditlogKey] = <PLACEHOLDER>
- time: datetime = <PLACEHOLDER>
Time indicates the time for which you are interested in the data. If no time is given, the server will use the time at which it makes the request.
- class cloudvision.api.arista.auditlog.v1.AuditlogSomeResponse(value: 'Auditlog' = <PLACEHOLDER>, error: str | None = <PLACEHOLDER>, time: datetime.datetime = <PLACEHOLDER>)[source]
Bases:
Message- error: str | None = <PLACEHOLDER>
Error is an optional field. It should be filled when there is an error in the GetSome process.
- time: datetime = <PLACEHOLDER>
Time carries the (UTC) timestamp of the last-modification of the Auditlog instance in this response.
- class cloudvision.api.arista.auditlog.v1.AuditlogStreamRequest(filter: List[ForwardRef('Filter')] = <PLACEHOLDER>, time: '__time__.TimeBounds' = <PLACEHOLDER>)[source]
Bases:
Message- filter: List[Filter] = <PLACEHOLDER>
For each Auditlog in the list, all populated fields are considered ANDed together as a filtering operation. Similarly, the list itself is ORed such that any individual filter that matches a given Auditlog is streamed to the user.
- time: __time__.TimeBounds = <PLACEHOLDER>
TimeRange allows limiting response data to within a specified time window. If this field is populated, at least one of the two time fields are required.
For GetAll, the fields start and end can be used as follows:
end: Returns the state of each Auditlog at end. * Each Auditlog response is fully-specified (all fields set).
start: Returns the state of each Auditlog at start, followed by updates until now. * Each Auditlog response at start is fully-specified, but updates may be partial.
start and end: Returns the state of each Auditlog at start, followed by updates until end. * Each Auditlog response at start is fully-specified, but updates until end may
be partial.
- class cloudvision.api.arista.auditlog.v1.AuditlogStreamResponse(value: 'Auditlog' = <PLACEHOLDER>, time: datetime.datetime = <PLACEHOLDER>, type: '__subscriptions__.Operation' = <PLACEHOLDER>)[source]
Bases:
Message- time: datetime = <PLACEHOLDER>
Time holds the timestamp of this Auditlog’s last modification.
- type: __subscriptions__.Operation = <PLACEHOLDER>
Operation indicates how the Auditlog value in this response should be considered. Under non-subscribe requests, this value should always be INITIAL. In a subscription, once all initial data is streamed and the client begins to receive modification updates, you should not see INITIAL again.
- class cloudvision.api.arista.auditlog.v1.Category(type: ~cloudvision.api.arista.auditlog.v1.CategoryType = <PLACEHOLDER>, identifier: str | None = <PLACEHOLDER>, custom_type: str | None = <PLACEHOLDER>)[source]
Bases:
MessageCategory organizes audit logs into different groups using the CategoryType and the identifier eg: filter:[{category:{type:CATEGORY_TYPE_INVENTORY,identifier:abc}}] filters all logs associated with the service “inventory” and device abc
- custom_type: str | None = <PLACEHOLDER>
custom_type is a custom category that can be created by the user. this is used if none of the existing categories can support the users’s usecase.
- identifier: str | None = <PLACEHOLDER>
identifier is the object with which we want to filter the category. eg: fetch all logs from the device with id abc Here the category is inventory and the identifier is abc.
- type: CategoryType = <PLACEHOLDER>
type of the category.
- class cloudvision.api.arista.auditlog.v1.CategoryType(value: int)[source]
Bases:
EnumCategoryType is the type of the category
- ACCESSCONTROL = CategoryType.ACCESSCONTROL
CATEGORY_TYPE_ACCESSCONTROL categoryType the identifier for this category is a custom identifier defined by the user.
- CHANGECONTROL = CategoryType.CHANGECONTROL
CATEGORY_TYPE_CHANGECONTROL categoryType the identifier for this category is a custom identifier defined by the user.
- CONFIGLET = CategoryType.CONFIGLET
CATEGORY_TYPE_CONFIGLET categoryType the identifier for this category is a custom identifier defined by the user.
- EXECACTION = CategoryType.EXECACTION
CATEGORY_TYPE_EXECACTION categoryType the identifier for this category is a custom identifier defined by the user.
- IMAGE = CategoryType.IMAGE
CATEGORY_TYPE_IMAGE categoryType the identifier for this category is a custom identifier defined by the user.
- INVENTORY = CategoryType.INVENTORY
CATEGORY_TYPE_INVENTORY categoryType the identifier for this category is the deviceId
- LABEL = CategoryType.LABEL
CATEGORY_TYPE_LABEL categoryType the identifier for this category is a custom identifier defined by the user.
- ROLE = CategoryType.ROLE
CATEGORY_TYPE_ROLE categoryType the identifier for this category is a custom identifier defined by the user.
- SNAPSHOT = CategoryType.SNAPSHOT
CATEGORY_TYPE_SNAPSHOT categoryType the identifier for this category is a custom identifier defined by the user.
- UNSPECIFIED = CategoryType.UNSPECIFIED
CATEGORY_TYPE_UNSPECIFIED categoryType
- USER = CategoryType.USER
CATEGORY_TYPE_USER categoryType the identifier for this category is a custom identifier defined by the user.
- name: str | None
- value: int
- class cloudvision.api.arista.auditlog.v1.Filter(category: ~cloudvision.api.arista.auditlog.v1.Category = <PLACEHOLDER>, queries: ~cloudvision.api.fmp.RepeatedString = <PLACEHOLDER>, tags: ~cloudvision.api.fmp.MapStringString = <PLACEHOLDER>, severity: ~cloudvision.api.arista.auditlog.v1.Severity = <PLACEHOLDER>, user: str | None = <PLACEHOLDER>)[source]
Bases:
MessageFilter are the different filters that can be applied.
- category: Category = <PLACEHOLDER>
category filters based on category of the logs. eg: {filter:[{category:{custom_type: abc}}]} filters all logs associated with the service abc.
- queries: ___fmp__.RepeatedString = <PLACEHOLDER>
queries is the list of strings that should be present in the log. eg: {filter:[{queries:{values:[abc]}}]} searches for all logs containing the string abc.
- severity: Severity = <PLACEHOLDER>
severity is level of importance or urgency of the audit log message.
- tags: ___fmp__.MapStringString = <PLACEHOLDER>
tags filters based on tags associated with the log. eg: {filter:[{tags:{values:{id:xyz}}}]} searches for all logs associates with the tag id:xyz.
- user: str | None = <PLACEHOLDER>
user filters the audit logs by given username across categories.
- class cloudvision.api.arista.auditlog.v1.MetaResponse(time: datetime.datetime = <PLACEHOLDER>, type: '__subscriptions__.Operation' = <PLACEHOLDER>, count: int | None = <PLACEHOLDER>)[source]
Bases:
Message- count: int | None = <PLACEHOLDER>
Count is the number of items present under the conditions of the request.
- time: datetime = <PLACEHOLDER>
Time holds the timestamp of the last item included in the metadata calculation.
- type: __subscriptions__.Operation = <PLACEHOLDER>
Operation indicates how the value in this response should be considered. Under non-subscribe requests, this value should always be INITIAL. In a subscription, once all initial data is streamed and the client begins to receive modification updates, you should not see INITIAL again.
- class cloudvision.api.arista.auditlog.v1.Severity(value: int)[source]
Bases:
EnumSeverity is the level of criticality of the log.
- ALERT = Severity.ALERT
SEVERITY_ALERT severity
- CRITICAL = Severity.CRITICAL
SEVERITY_CRITICAL severity
- DEBUG = Severity.DEBUG
SEVERITY_DEBUG severity
- EMERGENCY = Severity.EMERGENCY
SEVERITY_EMERGENCY severity
- ERROR = Severity.ERROR
SEVERITY_ERROR severity
- INFO = Severity.INFO
SEVERITY_INFO severity
- NOTICE = Severity.NOTICE
SEVERITY_NOTICE severity
- UNSPECIFIED = Severity.UNSPECIFIED
SEVERITY_UNSPECIFIED severity
- WARNING = Severity.WARNING
SEVERITY_WARNING severity
- name: str | None
- value: int