Skip to main content

nil_payload/
report.rs

1// Copyright (C) Call of Nil contributors
2// SPDX-License-Identifier: AGPL-3.0-only
3
4use nil_core::report::ReportId;
5use nil_core::world::config::WorldId;
6use serde::{Deserialize, Serialize};
7use std::collections::HashSet;
8
9#[derive(Clone, Debug, Deserialize, Serialize)]
10#[serde(rename_all = "camelCase")]
11pub struct GetReportRequest {
12  pub world: WorldId,
13  pub id: ReportId,
14}
15
16#[derive(Clone, Debug, Deserialize, Serialize)]
17#[serde(rename_all = "camelCase")]
18pub struct GetReportsRequest {
19  pub world: WorldId,
20  pub ids: HashSet<ReportId>,
21  #[serde(default)]
22  pub limit: Option<usize>,
23}