Skip to content

Commit

Permalink
feat: Update API, based on the latest lexicon schemas (#165)
Browse files Browse the repository at this point in the history
  • Loading branch information
sugyan authored May 1, 2024
1 parent 75637fe commit d4a3cbb
Show file tree
Hide file tree
Showing 9 changed files with 87 additions and 4 deletions.
1 change: 1 addition & 0 deletions atrium-api/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
.atproto
.server
.create_session(Input {
auth_factor_token: None,
identifier: "[email protected]".into(),
password: "hunter2".into(),
})
Expand Down
7 changes: 7 additions & 0 deletions atrium-api/src/agent.rs
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ where
.atproto
.server
.create_session(crate::com::atproto::server::create_session::Input {
auth_factor_token: None,
identifier: identifier.as_ref().into(),
password: password.as_ref().into(),
})
Expand Down Expand Up @@ -194,6 +195,7 @@ mod tests {
did: "did:web:example.com".parse().expect("valid"),
did_doc: None,
email: None,
email_auth_factor: None,
email_confirmed: None,
handle: "example.com".parse().expect("valid"),
refresh_jwt: String::from("refresh"),
Expand Down Expand Up @@ -256,6 +258,7 @@ mod tests {
did: session.did.clone(),
did_doc: session.did_doc.clone(),
email: session.email.clone(),
email_auth_factor: session.email_auth_factor,
email_confirmed: session.email_confirmed,
handle: session.handle.clone(),
}),
Expand Down Expand Up @@ -287,6 +290,7 @@ mod tests {
did: session.did.clone(),
did_doc: session.did_doc.clone(),
email: session.email.clone(),
email_auth_factor: session.email_auth_factor,
email_confirmed: session.email_confirmed,
handle: session.handle.clone(),
}),
Expand Down Expand Up @@ -326,6 +330,7 @@ mod tests {
did: session.did.clone(),
did_doc: session.did_doc.clone(),
email: session.email.clone(),
email_auth_factor: session.email_auth_factor,
email_confirmed: session.email_confirmed,
handle: session.handle.clone(),
}),
Expand Down Expand Up @@ -378,6 +383,7 @@ mod tests {
did: session.did.clone(),
did_doc: session.did_doc.clone(),
email: session.email.clone(),
email_auth_factor: session.email_auth_factor,
email_confirmed: session.email_confirmed,
handle: session.handle.clone(),
}),
Expand Down Expand Up @@ -424,6 +430,7 @@ mod tests {
did: session.did.clone(),
did_doc: session.did_doc.clone(),
email: session.email.clone(),
email_auth_factor: session.email_auth_factor,
email_confirmed: session.email_confirmed,
handle: session.handle.clone(),
}),
Expand Down
15 changes: 15 additions & 0 deletions atrium-api/src/app/bsky/actor/defs.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions atrium-api/src/com/atproto/server/create_session.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions atrium-api/src/com/atproto/server/get_session.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions atrium-api/src/com/atproto/server/update_email.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

34 changes: 34 additions & 0 deletions atrium-api/src/tools/ozone/moderation/defs.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 12 additions & 4 deletions atrium-api/src/tools/ozone/moderation/emit_event.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions atrium-api/src/tools/ozone/moderation/query_statuses.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit d4a3cbb

Please sign in to comment.