use crate::scalar::ID;
use serde::{Deserialize, Serialize};
#[derive(Serialize, Deserialize, Clone, Debug)]
pub struct IndexMetadata {
pub id: ID,
pub time: u64,
pub block_height: u32,
pub block_id: String,
}
impl IndexMetadata {
pub fn schema_fragment() -> &'static str {
r#"
type IndexMetadataEntity @entity {
id: ID!
time: U64!
block_height: U32!
block_id: Bytes32!
}
"#
}
}