AzureCosmosDbLogAuthEvent Method

Logs an event caused by a user during an authentication process (login, logout, MFA, forgotten password, etc.)

Definition

Namespace: MobileTrack.DataContainers.Cosmos
Assembly: MobileTrack.DataContainers (in MobileTrack.DataContainers.dll) Version: 0.8+34f1bbd8dc6b32752cfce829cbed66e15113d7ba
public Task LogAuthEvent(
	AccountDto user,
	string ipAddress,
	EventId userEvent,
	IIdLabel impactedObject,
	Guid impactedObjectCompanyId,
	IIdLabel? snapShotResource = null,
	CancellationToken cancellationToken = default
)

Parameters

user  AccountDto
User causing the event
ipAddress  String
IP Address of the user
userEvent  EventId
Invoked event
impactedObject  IIdLabel
Object that was impacted by the event (e.g. the newly created object)
impactedObjectCompanyId  Guid
Company the impactedObject belongs to.
snapShotResource  IIdLabel  (Optional)
Snapshot resource
cancellationToken  CancellationToken  (Optional)
Cancellation token

Return Value

Task
Log creation Task

Implements

IAzureCosmosDbLogAuthEvent(AccountDto, String, EventId, IIdLabel, Guid, IIdLabel, CancellationToken)

Exceptions

ArgumentNullExceptionThrown if user or impactedObject was
ArgumentExceptionThrown if ipAddress is IsNullOrWhiteSpace(String)

See Also