|
1 | 1 | use rocket::serde::Serialize; |
2 | 2 | use std::collections::HashSet; |
3 | 3 |
|
| 4 | +/// The response for the `GET /@me` route. |
4 | 5 | #[derive(Serialize, Debug)] |
5 | 6 | #[serde(crate = "rocket::serde")] |
6 | | -pub(crate) struct UserInfoResponse { |
7 | | - pub(crate) user: User, |
8 | | - pub(crate) linked_accounts: UserLinkedAccounts, |
| 7 | +pub(super) struct UserInfoResponse { |
| 8 | + pub(super) user: User, |
| 9 | + pub(super) linked_accounts: UserLinkedAccounts, |
9 | 10 | } |
10 | 11 |
|
| 12 | +/// The user's primary account link. |
11 | 13 | #[derive(Serialize, Debug)] |
12 | 14 | #[serde(crate = "rocket::serde")] |
13 | | -pub(crate) struct User { |
14 | | - pub(crate) discord_uid: String, |
15 | | - pub(crate) roblox_uid: String, |
| 15 | +pub(super) struct User { |
| 16 | + /// The user's Discord ID. |
| 17 | + pub(super) discord_uid: String, |
| 18 | + /// The user's Roblox ID. |
| 19 | + pub(super) roblox_uid: String, |
16 | 20 | } |
17 | 21 |
|
| 22 | +/// The user's account links (verification history). |
18 | 23 | #[derive(Serialize, Default, Debug)] |
19 | 24 | #[serde(crate = "rocket::serde")] |
20 | | -pub(crate) struct UserLinkedAccounts { |
21 | | - pub(crate) discord: HashSet<String>, |
22 | | - pub(crate) roblox: HashSet<String>, |
| 25 | +pub(super) struct UserLinkedAccounts { |
| 26 | + /// All Discord IDs associated with the user. |
| 27 | + pub(super) discord: HashSet<String>, |
| 28 | + /// All Roblox IDs associated with the user. |
| 29 | + pub(super) roblox: HashSet<String>, |
23 | 30 | } |
0 commit comments