Skip to main content

reifydb_core/interface/catalog/
token.rs

1// SPDX-License-Identifier: AGPL-3.0-or-later
2// Copyright (c) 2026 ReifyDB
3
4use reifydb_value::value::{datetime::DateTime, identity::IdentityId};
5use serde::{Deserialize, Serialize};
6
7pub type TokenId = u64;
8
9#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
10pub struct Token {
11	pub id: TokenId,
12	pub token: String,
13	pub identity: IdentityId,
14	pub expires_at: Option<DateTime>,
15	pub created_at: DateTime,
16}