Interface ISupportAssistantUsageStore
- Namespace
- Tharga.Team
- Assembly
- Tharga.Team.dll
Keeps the support assistant's usage records, and totals them.
public interface ISupportAssistantUsageStore : ISupportAssistantUsageSink
- Inherited Members
Remarks
A ISupportAssistantUsageSink that can also be read. AddThargaTeamRepository in
Tharga.Team.MongoDB registers one, as both.
Methods
DeleteForTeamAsync(string, CancellationToken)
Removes every record of a team, when the team is purged; returns how many.
Task<long> DeleteForTeamAsync(string teamKey, CancellationToken cancellationToken = default)
Parameters
teamKeystringcancellationTokenCancellationToken
Returns
GetTotalsAsync(DateTime, DateTime, string, CancellationToken)
The usage from from (inclusive) to to (exclusive), totalled per team,
provider and model; for one team when teamKey is given.
Task<SupportAssistantUsageTotal[]> GetTotalsAsync(DateTime from, DateTime to, string teamKey = null, CancellationToken cancellationToken = default)
Parameters
fromDateTimetoDateTimeteamKeystringcancellationTokenCancellationToken