Skip to main content

nym_api_requests/models/
geolocation.rs

1// Copyright 2026 - Nym Technologies SA <contact@nymtech.net>
2// SPDX-License-Identifier: GPL-3.0-only
3
4use crate::pagination::PaginatedResponse;
5use nym_geolocation_contract_common::GeolocationRecord;
6use serde::{Deserialize, Serialize};
7use tendermint::block::Height;
8use utoipa::ToSchema;
9
10#[derive(Debug, Clone, Serialize, Deserialize, ToSchema)]
11pub struct GeolocationEntriesRecordsResponse {
12    /// The height every record was pinned to - the same height the client obtained a quorum'd
13    /// snapshot for.
14    #[schema(value_type = String)]
15    pub height: Height,
16
17    /// The location entries and the whitelisted agents alike, exactly as committed.
18    pub entries: PaginatedResponse<GeolocationRecord>,
19}