1
0
mirror of https://github.com/bitwarden/server.git synced 2025-04-28 08:12:22 -05:00
bitwarden/src/Core/Entities/OrganizationApiKey.cs
2022-08-29 16:06:55 -04:00

21 lines
502 B
C#

using System.ComponentModel.DataAnnotations;
using Bit.Core.Enums;
using Bit.Core.Utilities;
namespace Bit.Core.Entities;
public class OrganizationApiKey : ITableObject<Guid>
{
public Guid Id { get; set; }
public Guid OrganizationId { get; set; }
public OrganizationApiKeyType Type { get; set; }
[MaxLength(30)]
public string ApiKey { get; set; }
public DateTime RevisionDate { get; set; }
public void SetNewId()
{
Id = CoreHelpers.GenerateComb();
}
}