summaryrefslogtreecommitdiffstats
path: root/adenosine-pds/src/models.rs
diff options
context:
space:
mode:
Diffstat (limited to 'adenosine-pds/src/models.rs')
-rw-r--r--adenosine-pds/src/models.rs27
1 files changed, 27 insertions, 0 deletions
diff --git a/adenosine-pds/src/models.rs b/adenosine-pds/src/models.rs
index 8f855c5..9da6104 100644
--- a/adenosine-pds/src/models.rs
+++ b/adenosine-pds/src/models.rs
@@ -1,6 +1,23 @@
use serde;
#[allow(non_snake_case)]
+#[derive(Debug, serde::Deserialize, serde::Serialize, PartialEq, Eq)]
+pub struct AccountRequest {
+ pub email: String,
+ pub username: String,
+ pub password: String,
+ pub inviteCode: Option<String>,
+ pub recoveryKey: Option<String>,
+}
+
+#[allow(non_snake_case)]
+#[derive(Debug, serde::Deserialize, serde::Serialize, PartialEq, Eq)]
+pub struct SessionRequest {
+ pub username: String,
+ pub password: String,
+}
+
+#[allow(non_snake_case)]
#[derive(Debug, serde::Serialize, serde::Deserialize, Clone, PartialEq, Eq)]
pub struct AtpSession {
pub did: String,
@@ -8,3 +25,13 @@ pub struct AtpSession {
pub accessJwt: String,
pub refreshJwt: String,
}
+
+#[allow(non_snake_case)]
+#[derive(Debug, serde::Serialize, serde::Deserialize, Clone, PartialEq, Eq)]
+pub struct RepoDescribe {
+ pub name: String,
+ pub did: String,
+ pub didDoc: serde_json::Value,
+ pub collections: Vec<String>,
+ pub nameIsCorrect: bool,
+}