aboutsummaryrefslogtreecommitdiffstats
path: root/rust/fatcat-openapi/src/lib.rs
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2019-09-19 00:38:00 -0700
committerBryan Newbold <bnewbold@robocracy.org>2020-05-10 13:08:45 -0700
commita9b23947c49275a11765c8a752c154b98c69b531 (patch)
tree0c8bef53cfb66b81996721fcab92d90ec1c4376c /rust/fatcat-openapi/src/lib.rs
parent228a9245ea3680e11164f58367310406402d306b (diff)
downloadfatcat-a9b23947c49275a11765c8a752c154b98c69b531.tar.gz
fatcat-a9b23947c49275a11765c8a752c154b98c69b531.zip
WIP: update rust codegen script
Only Cargo.toml project metadata updated.
Diffstat (limited to 'rust/fatcat-openapi/src/lib.rs')
-rw-r--r--rust/fatcat-openapi/src/lib.rs3137
1 files changed, 2272 insertions, 865 deletions
diff --git a/rust/fatcat-openapi/src/lib.rs b/rust/fatcat-openapi/src/lib.rs
index 59255193..164c0beb 100644
--- a/rust/fatcat-openapi/src/lib.rs
+++ b/rust/fatcat-openapi/src/lib.rs
@@ -1,45 +1,58 @@
-#![allow(missing_docs, trivial_casts, unused_variables, unused_mut, unused_imports, unused_extern_crates, non_camel_case_types)]
-extern crate serde;
-#[macro_use]
-extern crate serde_derive;
-extern crate serde_json;
-
-extern crate chrono;
-extern crate futures;
-
-#[macro_use]
-extern crate lazy_static;
-#[macro_use]
-extern crate log;
-
-// Logically this should be in the client and server modules, but rust doesn't allow `macro_use` from a module.
-#[cfg(any(feature = "client", feature = "server"))]
-#[macro_use]
-extern crate hyper;
-
-extern crate swagger;
+#![allow(
+ missing_docs,
+ trivial_casts,
+ unused_variables,
+ unused_mut,
+ unused_imports,
+ unused_extern_crates,
+ non_camel_case_types
+)]
use futures::Stream;
use std::io::Error;
-#[allow(unused_imports)]
-use std::collections::HashMap;
-
+#[deprecated(note = "Import futures directly")]
pub use futures::Future;
+#[deprecated(note = "Import swagger-rs directly")]
+pub use swagger::{ApiError, ContextWrapper};
-#[cfg(any(feature = "client", feature = "server"))]
-mod mimetypes;
+pub const BASE_PATH: &'static str = "/v0";
+pub const API_VERSION: &'static str = "0.3.1";
-pub use swagger::{ApiError, Context, ContextWrapper};
+#[derive(Debug, PartialEq)]
+#[must_use]
+pub enum AcceptEditgroupResponse {
+ /// Merged Successfully
+ MergedSuccessfully(models::Success),
+ /// Bad Request
+ BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
+ /// Not Found
+ NotFound(models::ErrorResponse),
+ /// Edit Conflict
+ EditConflict(models::ErrorResponse),
+ /// Generic Error
+ GenericError(models::ErrorResponse),
+}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum AuthCheckResponse {
/// Success
Success(models::Success),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Generic Error
@@ -47,6 +60,7 @@ pub enum AuthCheckResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum AuthOidcResponse {
/// Found
Found(models::AuthOidcResult),
@@ -55,7 +69,10 @@ pub enum AuthOidcResponse {
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Conflict
@@ -65,13 +82,17 @@ pub enum AuthOidcResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum CreateAuthTokenResponse {
/// Success
Success(models::AuthTokenResult),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Generic Error
@@ -79,35 +100,17 @@ pub enum CreateAuthTokenResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetChangelogResponse {
- /// Success
- Success(Vec<models::ChangelogEntry>),
- /// Bad Request
- BadRequest(models::ErrorResponse),
- /// Generic Error
- GenericError(models::ErrorResponse),
-}
-
-#[derive(Debug, PartialEq)]
-pub enum GetChangelogEntryResponse {
- /// Found Changelog Entry
- FoundChangelogEntry(models::ChangelogEntry),
- /// Bad Request
- BadRequest(models::ErrorResponse),
- /// Not Found
- NotFound(models::ErrorResponse),
- /// Generic Error
- GenericError(models::ErrorResponse),
-}
-
-#[derive(Debug, PartialEq)]
+#[must_use]
pub enum CreateContainerResponse {
/// Created Entity
CreatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -117,13 +120,17 @@ pub enum CreateContainerResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum CreateContainerAutoBatchResponse {
/// Created Editgroup
CreatedEditgroup(models::Editgroup),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -133,13 +140,17 @@ pub enum CreateContainerAutoBatchResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteContainerResponse {
- /// Deleted Entity
- DeletedEntity(models::EntityEdit),
+#[must_use]
+pub enum CreateCreatorResponse {
+ /// Created Entity
+ CreatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -149,13 +160,17 @@ pub enum DeleteContainerResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteContainerEditResponse {
- /// Deleted Edit
- DeletedEdit(models::Success),
+#[must_use]
+pub enum CreateCreatorAutoBatchResponse {
+ /// Created Editgroup
+ CreatedEditgroup(models::Editgroup),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -165,23 +180,19 @@ pub enum DeleteContainerEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetContainerResponse {
- /// Found Entity
- FoundEntity(models::ContainerEntity),
- /// Bad Request
- BadRequest(models::ErrorResponse),
- /// Not Found
- NotFound(models::ErrorResponse),
- /// Generic Error
- GenericError(models::ErrorResponse),
-}
-
-#[derive(Debug, PartialEq)]
-pub enum GetContainerEditResponse {
- /// Found Edit
- FoundEdit(models::EntityEdit),
+#[must_use]
+pub enum CreateEditgroupResponse {
+ /// Successfully Created
+ SuccessfullyCreated(models::Editgroup),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -189,11 +200,19 @@ pub enum GetContainerEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetContainerHistoryResponse {
- /// Found Entity History
- FoundEntityHistory(Vec<models::EntityHistoryEntry>),
+#[must_use]
+pub enum CreateEditgroupAnnotationResponse {
+ /// Created
+ Created(models::EditgroupAnnotation),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -201,11 +220,19 @@ pub enum GetContainerHistoryResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetContainerRedirectsResponse {
- /// Found Entity Redirects
- FoundEntityRedirects(Vec<String>),
+#[must_use]
+pub enum CreateFileResponse {
+ /// Created Entity
+ CreatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -213,11 +240,19 @@ pub enum GetContainerRedirectsResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetContainerRevisionResponse {
- /// Found Entity Revision
- FoundEntityRevision(models::ContainerEntity),
+#[must_use]
+pub enum CreateFileAutoBatchResponse {
+ /// Created Editgroup
+ CreatedEditgroup(models::Editgroup),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -225,11 +260,19 @@ pub enum GetContainerRevisionResponse {
}
#[derive(Debug, PartialEq)]
-pub enum LookupContainerResponse {
- /// Found Entity
- FoundEntity(models::ContainerEntity),
+#[must_use]
+pub enum CreateFilesetResponse {
+ /// Created Entity
+ CreatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -237,13 +280,17 @@ pub enum LookupContainerResponse {
}
#[derive(Debug, PartialEq)]
-pub enum UpdateContainerResponse {
- /// Updated Entity
- UpdatedEntity(models::EntityEdit),
+#[must_use]
+pub enum CreateFilesetAutoBatchResponse {
+ /// Created Editgroup
+ CreatedEditgroup(models::Editgroup),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -253,13 +300,17 @@ pub enum UpdateContainerResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateCreatorResponse {
+#[must_use]
+pub enum CreateReleaseResponse {
/// Created Entity
CreatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -269,13 +320,17 @@ pub enum CreateCreatorResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateCreatorAutoBatchResponse {
+#[must_use]
+pub enum CreateReleaseAutoBatchResponse {
/// Created Editgroup
CreatedEditgroup(models::Editgroup),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -285,13 +340,17 @@ pub enum CreateCreatorAutoBatchResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteCreatorResponse {
- /// Deleted Entity
- DeletedEntity(models::EntityEdit),
+#[must_use]
+pub enum CreateWebcaptureResponse {
+ /// Created Entity
+ CreatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -301,13 +360,17 @@ pub enum DeleteCreatorResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteCreatorEditResponse {
- /// Deleted Edit
- DeletedEdit(models::Success),
+#[must_use]
+pub enum CreateWebcaptureAutoBatchResponse {
+ /// Created Editgroup
+ CreatedEditgroup(models::Editgroup),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -317,11 +380,19 @@ pub enum DeleteCreatorEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetCreatorResponse {
- /// Found Entity
- FoundEntity(models::CreatorEntity),
+#[must_use]
+pub enum CreateWorkResponse {
+ /// Created Entity
+ CreatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -329,11 +400,19 @@ pub enum GetCreatorResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetCreatorEditResponse {
- /// Found Edit
- FoundEdit(models::EntityEdit),
+#[must_use]
+pub enum CreateWorkAutoBatchResponse {
+ /// Created Editgroup
+ CreatedEditgroup(models::Editgroup),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -341,11 +420,19 @@ pub enum GetCreatorEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetCreatorHistoryResponse {
- /// Found Entity History
- FoundEntityHistory(Vec<models::EntityHistoryEntry>),
+#[must_use]
+pub enum DeleteContainerResponse {
+ /// Deleted Entity
+ DeletedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -353,11 +440,19 @@ pub enum GetCreatorHistoryResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetCreatorRedirectsResponse {
- /// Found Entity Redirects
- FoundEntityRedirects(Vec<String>),
+#[must_use]
+pub enum DeleteContainerEditResponse {
+ /// Deleted Edit
+ DeletedEdit(models::Success),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -365,11 +460,19 @@ pub enum GetCreatorRedirectsResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetCreatorReleasesResponse {
- /// Found
- Found(Vec<models::ReleaseEntity>),
+#[must_use]
+pub enum DeleteCreatorResponse {
+ /// Deleted Entity
+ DeletedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -377,11 +480,19 @@ pub enum GetCreatorReleasesResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetCreatorRevisionResponse {
- /// Found Entity Revision
- FoundEntityRevision(models::CreatorEntity),
+#[must_use]
+pub enum DeleteCreatorEditResponse {
+ /// Deleted Edit
+ DeletedEdit(models::Success),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -389,11 +500,19 @@ pub enum GetCreatorRevisionResponse {
}
#[derive(Debug, PartialEq)]
-pub enum LookupCreatorResponse {
- /// Found Entity
- FoundEntity(models::CreatorEntity),
+#[must_use]
+pub enum DeleteFileResponse {
+ /// Deleted Entity
+ DeletedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -401,13 +520,17 @@ pub enum LookupCreatorResponse {
}
#[derive(Debug, PartialEq)]
-pub enum UpdateCreatorResponse {
- /// Updated Entity
- UpdatedEntity(models::EntityEdit),
+#[must_use]
+pub enum DeleteFileEditResponse {
+ /// Deleted Edit
+ DeletedEdit(models::Success),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -417,31 +540,37 @@ pub enum UpdateCreatorResponse {
}
#[derive(Debug, PartialEq)]
-pub enum AcceptEditgroupResponse {
- /// Merged Successfully
- MergedSuccessfully(models::Success),
+#[must_use]
+pub enum DeleteFilesetResponse {
+ /// Deleted Entity
+ DeletedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
- /// Edit Conflict
- EditConflict(models::ErrorResponse),
/// Generic Error
GenericError(models::ErrorResponse),
}
#[derive(Debug, PartialEq)]
-pub enum CreateEditgroupResponse {
- /// Successfully Created
- SuccessfullyCreated(models::Editgroup),
+#[must_use]
+pub enum DeleteFilesetEditResponse {
+ /// Deleted Edit
+ DeletedEdit(models::Success),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -451,13 +580,17 @@ pub enum CreateEditgroupResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateEditgroupAnnotationResponse {
- /// Created
- Created(models::EditgroupAnnotation),
+#[must_use]
+pub enum DeleteReleaseResponse {
+ /// Deleted Entity
+ DeletedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -467,11 +600,19 @@ pub enum CreateEditgroupAnnotationResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetEditgroupResponse {
- /// Found
- Found(models::Editgroup),
+#[must_use]
+pub enum DeleteReleaseEditResponse {
+ /// Deleted Edit
+ DeletedEdit(models::Success),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -479,13 +620,17 @@ pub enum GetEditgroupResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetEditgroupAnnotationsResponse {
- /// Success
- Success(Vec<models::EditgroupAnnotation>),
+#[must_use]
+pub enum DeleteWebcaptureResponse {
+ /// Deleted Entity
+ DeletedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -495,11 +640,19 @@ pub enum GetEditgroupAnnotationsResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetEditgroupsReviewableResponse {
- /// Found
- Found(Vec<models::Editgroup>),
+#[must_use]
+pub enum DeleteWebcaptureEditResponse {
+ /// Deleted Edit
+ DeletedEdit(models::Success),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -507,13 +660,17 @@ pub enum GetEditgroupsReviewableResponse {
}
#[derive(Debug, PartialEq)]
-pub enum UpdateEditgroupResponse {
- /// Updated Editgroup
- UpdatedEditgroup(models::Editgroup),
+#[must_use]
+pub enum DeleteWorkResponse {
+ /// Deleted Entity
+ DeletedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -523,11 +680,19 @@ pub enum UpdateEditgroupResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetEditorResponse {
- /// Found
- Found(models::Editor),
+#[must_use]
+pub enum DeleteWorkEditResponse {
+ /// Deleted Edit
+ DeletedEdit(models::Success),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -535,25 +700,21 @@ pub enum GetEditorResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetEditorAnnotationsResponse {
+#[must_use]
+pub enum GetChangelogResponse {
/// Success
- Success(Vec<models::EditgroupAnnotation>),
+ Success(Vec<models::ChangelogEntry>),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
- /// Not Found
- NotFound(models::ErrorResponse),
/// Generic Error
GenericError(models::ErrorResponse),
}
#[derive(Debug, PartialEq)]
-pub enum GetEditorEditgroupsResponse {
- /// Found
- Found(Vec<models::Editgroup>),
+#[must_use]
+pub enum GetChangelogEntryResponse {
+ /// Found Changelog Entry
+ FoundChangelogEntry(models::ChangelogEntry),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -563,15 +724,12 @@ pub enum GetEditorEditgroupsResponse {
}
#[derive(Debug, PartialEq)]
-pub enum UpdateEditorResponse {
- /// Updated Editor
- UpdatedEditor(models::Editor),
+#[must_use]
+pub enum GetContainerResponse {
+ /// Found Entity
+ FoundEntity(models::ContainerEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -579,15 +737,12 @@ pub enum UpdateEditorResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateFileResponse {
- /// Created Entity
- CreatedEntity(models::EntityEdit),
+#[must_use]
+pub enum GetContainerEditResponse {
+ /// Found Edit
+ FoundEdit(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -595,15 +750,12 @@ pub enum CreateFileResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateFileAutoBatchResponse {
- /// Created Editgroup
- CreatedEditgroup(models::Editgroup),
+#[must_use]
+pub enum GetContainerHistoryResponse {
+ /// Found Entity History
+ FoundEntityHistory(Vec<models::EntityHistoryEntry>),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -611,15 +763,12 @@ pub enum CreateFileAutoBatchResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteFileResponse {
- /// Deleted Entity
- DeletedEntity(models::EntityEdit),
+#[must_use]
+pub enum GetContainerRedirectsResponse {
+ /// Found Entity Redirects
+ FoundEntityRedirects(Vec<String>),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -627,15 +776,12 @@ pub enum DeleteFileResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteFileEditResponse {
- /// Deleted Edit
- DeletedEdit(models::Success),
+#[must_use]
+pub enum GetContainerRevisionResponse {
+ /// Found Entity Revision
+ FoundEntityRevision(models::ContainerEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -643,9 +789,10 @@ pub enum DeleteFileEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetFileResponse {
+#[must_use]
+pub enum GetCreatorResponse {
/// Found Entity
- FoundEntity(models::FileEntity),
+ FoundEntity(models::CreatorEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -655,7 +802,8 @@ pub enum GetFileResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetFileEditResponse {
+#[must_use]
+pub enum GetCreatorEditResponse {
/// Found Edit
FoundEdit(models::EntityEdit),
/// Bad Request
@@ -667,7 +815,8 @@ pub enum GetFileEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetFileHistoryResponse {
+#[must_use]
+pub enum GetCreatorHistoryResponse {
/// Found Entity History
FoundEntityHistory(Vec<models::EntityHistoryEntry>),
/// Bad Request
@@ -679,7 +828,8 @@ pub enum GetFileHistoryResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetFileRedirectsResponse {
+#[must_use]
+pub enum GetCreatorRedirectsResponse {
/// Found Entity Redirects
FoundEntityRedirects(Vec<String>),
/// Bad Request
@@ -691,9 +841,23 @@ pub enum GetFileRedirectsResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetFileRevisionResponse {
+#[must_use]
+pub enum GetCreatorReleasesResponse {
+ /// Found
+ Found(Vec<models::ReleaseEntity>),
+ /// Bad Request
+ BadRequest(models::ErrorResponse),
+ /// Not Found
+ NotFound(models::ErrorResponse),
+ /// Generic Error
+ GenericError(models::ErrorResponse),
+}
+
+#[derive(Debug, PartialEq)]
+#[must_use]
+pub enum GetCreatorRevisionResponse {
/// Found Entity Revision
- FoundEntityRevision(models::FileEntity),
+ FoundEntityRevision(models::CreatorEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -703,9 +867,10 @@ pub enum GetFileRevisionResponse {
}
#[derive(Debug, PartialEq)]
-pub enum LookupFileResponse {
- /// Found Entity
- FoundEntity(models::FileEntity),
+#[must_use]
+pub enum GetEditgroupResponse {
+ /// Found
+ Found(models::Editgroup),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -715,13 +880,17 @@ pub enum LookupFileResponse {
}
#[derive(Debug, PartialEq)]
-pub enum UpdateFileResponse {
- /// Updated Entity
- UpdatedEntity(models::EntityEdit),
+#[must_use]
+pub enum GetEditgroupAnnotationsResponse {
+ /// Success
+ Success(Vec<models::EditgroupAnnotation>),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -731,15 +900,12 @@ pub enum UpdateFileResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateFilesetResponse {
- /// Created Entity
- CreatedEntity(models::EntityEdit),
+#[must_use]
+pub enum GetEditgroupsReviewableResponse {
+ /// Found
+ Found(Vec<models::Editgroup>),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -747,15 +913,12 @@ pub enum CreateFilesetResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateFilesetAutoBatchResponse {
- /// Created Editgroup
- CreatedEditgroup(models::Editgroup),
+#[must_use]
+pub enum GetEditorResponse {
+ /// Found
+ Found(models::Editor),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -763,13 +926,17 @@ pub enum CreateFilesetAutoBatchResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteFilesetResponse {
- /// Deleted Entity
- DeletedEntity(models::EntityEdit),
+#[must_use]
+pub enum GetEditorAnnotationsResponse {
+ /// Success
+ Success(Vec<models::EditgroupAnnotation>),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -779,15 +946,12 @@ pub enum DeleteFilesetResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteFilesetEditResponse {
- /// Deleted Edit
- DeletedEdit(models::Success),
+#[must_use]
+pub enum GetEditorEditgroupsResponse {
+ /// Found
+ Found(Vec<models::Editgroup>),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -795,9 +959,10 @@ pub enum DeleteFilesetEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetFilesetResponse {
+#[must_use]
+pub enum GetFileResponse {
/// Found Entity
- FoundEntity(models::FilesetEntity),
+ FoundEntity(models::FileEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -807,7 +972,8 @@ pub enum GetFilesetResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetFilesetEditResponse {
+#[must_use]
+pub enum GetFileEditResponse {
/// Found Edit
FoundEdit(models::EntityEdit),
/// Bad Request
@@ -819,7 +985,8 @@ pub enum GetFilesetEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetFilesetHistoryResponse {
+#[must_use]
+pub enum GetFileHistoryResponse {
/// Found Entity History
FoundEntityHistory(Vec<models::EntityHistoryEntry>),
/// Bad Request
@@ -831,7 +998,8 @@ pub enum GetFilesetHistoryResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetFilesetRedirectsResponse {
+#[must_use]
+pub enum GetFileRedirectsResponse {
/// Found Entity Redirects
FoundEntityRedirects(Vec<String>),
/// Bad Request
@@ -843,9 +1011,10 @@ pub enum GetFilesetRedirectsResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetFilesetRevisionResponse {
+#[must_use]
+pub enum GetFileRevisionResponse {
/// Found Entity Revision
- FoundEntityRevision(models::FilesetEntity),
+ FoundEntityRevision(models::FileEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -855,15 +1024,12 @@ pub enum GetFilesetRevisionResponse {
}
#[derive(Debug, PartialEq)]
-pub enum UpdateFilesetResponse {
- /// Updated Entity
- UpdatedEntity(models::EntityEdit),
+#[must_use]
+pub enum GetFilesetResponse {
+ /// Found Entity
+ FoundEntity(models::FilesetEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -871,15 +1037,12 @@ pub enum UpdateFilesetResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateReleaseResponse {
- /// Created Entity
- CreatedEntity(models::EntityEdit),
+#[must_use]
+pub enum GetFilesetEditResponse {
+ /// Found Edit
+ FoundEdit(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -887,15 +1050,12 @@ pub enum CreateReleaseResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateReleaseAutoBatchResponse {
- /// Created Editgroup
- CreatedEditgroup(models::Editgroup),
+#[must_use]
+pub enum GetFilesetHistoryResponse {
+ /// Found Entity History
+ FoundEntityHistory(Vec<models::EntityHistoryEntry>),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -903,15 +1063,12 @@ pub enum CreateReleaseAutoBatchResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteReleaseResponse {
- /// Deleted Entity
- DeletedEntity(models::EntityEdit),
+#[must_use]
+pub enum GetFilesetRedirectsResponse {
+ /// Found Entity Redirects
+ FoundEntityRedirects(Vec<String>),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -919,15 +1076,12 @@ pub enum DeleteReleaseResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteReleaseEditResponse {
- /// Deleted Edit
- DeletedEdit(models::Success),
+#[must_use]
+pub enum GetFilesetRevisionResponse {
+ /// Found Entity Revision
+ FoundEntityRevision(models::FilesetEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -935,6 +1089,7 @@ pub enum DeleteReleaseEditResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum GetReleaseResponse {
/// Found Entity
FoundEntity(models::ReleaseEntity),
@@ -947,6 +1102,7 @@ pub enum GetReleaseResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum GetReleaseEditResponse {
/// Found Edit
FoundEdit(models::EntityEdit),
@@ -959,6 +1115,7 @@ pub enum GetReleaseEditResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum GetReleaseFilesResponse {
/// Found
Found(Vec<models::FileEntity>),
@@ -971,6 +1128,7 @@ pub enum GetReleaseFilesResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum GetReleaseFilesetsResponse {
/// Found
Found(Vec<models::FilesetEntity>),
@@ -983,6 +1141,7 @@ pub enum GetReleaseFilesetsResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum GetReleaseHistoryResponse {
/// Found Entity History
FoundEntityHistory(Vec<models::EntityHistoryEntry>),
@@ -995,6 +1154,7 @@ pub enum GetReleaseHistoryResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum GetReleaseRedirectsResponse {
/// Found Entity Redirects
FoundEntityRedirects(Vec<String>),
@@ -1007,6 +1167,7 @@ pub enum GetReleaseRedirectsResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum GetReleaseRevisionResponse {
/// Found Entity Revision
FoundEntityRevision(models::ReleaseEntity),
@@ -1019,6 +1180,7 @@ pub enum GetReleaseRevisionResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum GetReleaseWebcapturesResponse {
/// Found
Found(Vec<models::WebcaptureEntity>),
@@ -1031,9 +1193,10 @@ pub enum GetReleaseWebcapturesResponse {
}
#[derive(Debug, PartialEq)]
-pub enum LookupReleaseResponse {
+#[must_use]
+pub enum GetWebcaptureResponse {
/// Found Entity
- FoundEntity(models::ReleaseEntity),
+ FoundEntity(models::WebcaptureEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -1043,15 +1206,12 @@ pub enum LookupReleaseResponse {
}
#[derive(Debug, PartialEq)]
-pub enum UpdateReleaseResponse {
- /// Updated Entity
- UpdatedEntity(models::EntityEdit),
+#[must_use]
+pub enum GetWebcaptureEditResponse {
+ /// Found Edit
+ FoundEdit(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1059,15 +1219,12 @@ pub enum UpdateReleaseResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateWebcaptureResponse {
- /// Created Entity
- CreatedEntity(models::EntityEdit),
+#[must_use]
+pub enum GetWebcaptureHistoryResponse {
+ /// Found Entity History
+ FoundEntityHistory(Vec<models::EntityHistoryEntry>),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1075,15 +1232,12 @@ pub enum CreateWebcaptureResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateWebcaptureAutoBatchResponse {
- /// Created Editgroup
- CreatedEditgroup(models::Editgroup),
+#[must_use]
+pub enum GetWebcaptureRedirectsResponse {
+ /// Found Entity Redirects
+ FoundEntityRedirects(Vec<String>),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1091,15 +1245,12 @@ pub enum CreateWebcaptureAutoBatchResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteWebcaptureResponse {
- /// Deleted Entity
- DeletedEntity(models::EntityEdit),
+#[must_use]
+pub enum GetWebcaptureRevisionResponse {
+ /// Found Entity Revision
+ FoundEntityRevision(models::WebcaptureEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1107,15 +1258,12 @@ pub enum DeleteWebcaptureResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteWebcaptureEditResponse {
- /// Deleted Edit
- DeletedEdit(models::Success),
+#[must_use]
+pub enum GetWorkResponse {
+ /// Found Entity
+ FoundEntity(models::WorkEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1123,9 +1271,10 @@ pub enum DeleteWebcaptureEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetWebcaptureResponse {
- /// Found Entity
- FoundEntity(models::WebcaptureEntity),
+#[must_use]
+pub enum GetWorkEditResponse {
+ /// Found Edit
+ FoundEdit(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -1135,9 +1284,10 @@ pub enum GetWebcaptureResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetWebcaptureEditResponse {
- /// Found Edit
- FoundEdit(models::EntityEdit),
+#[must_use]
+pub enum GetWorkHistoryResponse {
+ /// Found Entity History
+ FoundEntityHistory(Vec<models::EntityHistoryEntry>),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -1147,9 +1297,10 @@ pub enum GetWebcaptureEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetWebcaptureHistoryResponse {
- /// Found Entity History
- FoundEntityHistory(Vec<models::EntityHistoryEntry>),
+#[must_use]
+pub enum GetWorkRedirectsResponse {
+ /// Found Entity Redirects
+ FoundEntityRedirects(Vec<String>),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -1159,9 +1310,10 @@ pub enum GetWebcaptureHistoryResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetWebcaptureRedirectsResponse {
- /// Found Entity Redirects
- FoundEntityRedirects(Vec<String>),
+#[must_use]
+pub enum GetWorkReleasesResponse {
+ /// Found
+ Found(Vec<models::ReleaseEntity>),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -1171,9 +1323,10 @@ pub enum GetWebcaptureRedirectsResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetWebcaptureRevisionResponse {
+#[must_use]
+pub enum GetWorkRevisionResponse {
/// Found Entity Revision
- FoundEntityRevision(models::WebcaptureEntity),
+ FoundEntityRevision(models::WorkEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Found
@@ -1183,15 +1336,12 @@ pub enum GetWebcaptureRevisionResponse {
}
#[derive(Debug, PartialEq)]
-pub enum UpdateWebcaptureResponse {
- /// Updated Entity
- UpdatedEntity(models::EntityEdit),
+#[must_use]
+pub enum LookupContainerResponse {
+ /// Found Entity
+ FoundEntity(models::ContainerEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1199,15 +1349,12 @@ pub enum UpdateWebcaptureResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateWorkResponse {
- /// Created Entity
- CreatedEntity(models::EntityEdit),
+#[must_use]
+pub enum LookupCreatorResponse {
+ /// Found Entity
+ FoundEntity(models::CreatorEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1215,15 +1362,12 @@ pub enum CreateWorkResponse {
}
#[derive(Debug, PartialEq)]
-pub enum CreateWorkAutoBatchResponse {
- /// Created Editgroup
- CreatedEditgroup(models::Editgroup),
+#[must_use]
+pub enum LookupFileResponse {
+ /// Found Entity
+ FoundEntity(models::FileEntity),
/// Bad Request
BadRequest(models::ErrorResponse),
- /// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
- /// Forbidden
- Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1231,13 +1375,30 @@ pub enum CreateWorkAutoBatchResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteWorkResponse {
- /// Deleted Entity
- DeletedEntity(models::EntityEdit),
+#[must_use]
+pub enum LookupReleaseResponse {
+ /// Found Entity
+ FoundEntity(models::ReleaseEntity),
+ /// Bad Request
+ BadRequest(models::ErrorResponse),
+ /// Not Found
+ NotFound(models::ErrorResponse),
+ /// Generic Error
+ GenericError(models::ErrorResponse),
+}
+
+#[derive(Debug, PartialEq)]
+#[must_use]
+pub enum UpdateContainerResponse {
+ /// Updated Entity
+ UpdatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -1247,13 +1408,17 @@ pub enum DeleteWorkResponse {
}
#[derive(Debug, PartialEq)]
-pub enum DeleteWorkEditResponse {
- /// Deleted Edit
- DeletedEdit(models::Success),
+#[must_use]
+pub enum UpdateCreatorResponse {
+ /// Updated Entity
+ UpdatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -1263,11 +1428,19 @@ pub enum DeleteWorkEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetWorkResponse {
- /// Found Entity
- FoundEntity(models::WorkEntity),
+#[must_use]
+pub enum UpdateEditgroupResponse {
+ /// Updated Editgroup
+ UpdatedEditgroup(models::Editgroup),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1275,11 +1448,19 @@ pub enum GetWorkResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetWorkEditResponse {
- /// Found Edit
- FoundEdit(models::EntityEdit),
+#[must_use]
+pub enum UpdateEditorResponse {
+ /// Updated Editor
+ UpdatedEditor(models::Editor),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1287,11 +1468,19 @@ pub enum GetWorkEditResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetWorkHistoryResponse {
- /// Found Entity History
- FoundEntityHistory(Vec<models::EntityHistoryEntry>),
+#[must_use]
+pub enum UpdateFileResponse {
+ /// Updated Entity
+ UpdatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1299,11 +1488,19 @@ pub enum GetWorkHistoryResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetWorkRedirectsResponse {
- /// Found Entity Redirects
- FoundEntityRedirects(Vec<String>),
+#[must_use]
+pub enum UpdateFilesetResponse {
+ /// Updated Entity
+ UpdatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1311,11 +1508,19 @@ pub enum GetWorkRedirectsResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetWorkReleasesResponse {
- /// Found
- Found(Vec<models::ReleaseEntity>),
+#[must_use]
+pub enum UpdateReleaseResponse {
+ /// Updated Entity
+ UpdatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1323,11 +1528,19 @@ pub enum GetWorkReleasesResponse {
}
#[derive(Debug, PartialEq)]
-pub enum GetWorkRevisionResponse {
- /// Found Entity Revision
- FoundEntityRevision(models::WorkEntity),
+#[must_use]
+pub enum UpdateWebcaptureResponse {
+ /// Updated Entity
+ UpdatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
+ /// Not Authorized
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
+ /// Forbidden
+ Forbidden(models::ErrorResponse),
/// Not Found
NotFound(models::ErrorResponse),
/// Generic Error
@@ -1335,13 +1548,17 @@ pub enum GetWorkRevisionResponse {
}
#[derive(Debug, PartialEq)]
+#[must_use]
pub enum UpdateWorkResponse {
/// Updated Entity
UpdatedEntity(models::EntityEdit),
/// Bad Request
BadRequest(models::ErrorResponse),
/// Not Authorized
- NotAuthorized { body: models::ErrorResponse, www_authenticate: String },
+ NotAuthorized {
+ body: models::ErrorResponse,
+ www_authenticate: String,
+ },
/// Forbidden
Forbidden(models::ErrorResponse),
/// Not Found
@@ -1351,91 +1568,335 @@ pub enum UpdateWorkResponse {
}
/// API
-pub trait Api {
- fn auth_check(&self, role: Option<String>, context: &Context) -> Box<dyn Future<Item = AuthCheckResponse, Error = ApiError> + Send>;
+pub trait Api<C> {
+ fn accept_editgroup(
+ &self,
+ editgroup_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = AcceptEditgroupResponse, Error = ApiError> + Send>;
+
+ fn auth_check(
+ &self,
+ role: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = AuthCheckResponse, Error = ApiError> + Send>;
+
+ fn auth_oidc(
+ &self,
+ oidc_params: models::AuthOidc,
+ context: &C,
+ ) -> Box<dyn Future<Item = AuthOidcResponse, Error = ApiError> + Send>;
+
+ fn create_auth_token(
+ &self,
+ editor_id: String,
+ duration_seconds: Option<i32>,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateAuthTokenResponse, Error = ApiError> + Send>;
+
+ fn create_container(
+ &self,
+ editgroup_id: String,
+ entity: models::ContainerEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateContainerResponse, Error = ApiError> + Send>;
+
+ fn create_container_auto_batch(
+ &self,
+ auto_batch: models::ContainerAutoBatch,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateContainerAutoBatchResponse, Error = ApiError> + Send>;
+
+ fn create_creator(
+ &self,
+ editgroup_id: String,
+ entity: models::CreatorEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateCreatorResponse, Error = ApiError> + Send>;
- fn auth_oidc(&self, oidc_params: models::AuthOidc, context: &Context) -> Box<dyn Future<Item = AuthOidcResponse, Error = ApiError> + Send>;
+ fn create_creator_auto_batch(
+ &self,
+ auto_batch: models::CreatorAutoBatch,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateCreatorAutoBatchResponse, Error = ApiError> + Send>;
- fn create_auth_token(&self, editor_id: String, duration_seconds: Option<i32>, context: &Context) -> Box<dyn Future<Item = CreateAuthTokenResponse, Error = ApiError> + Send>;
+ fn create_editgroup(
+ &self,
+ editgroup: models::Editgroup,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateEditgroupResponse, Error = ApiError> + Send>;
- fn get_changelog(&self, limit: Option<i64>, context: &Context) -> Box<dyn Future<Item = GetChangelogResponse, Error = ApiError> + Send>;
+ fn create_editgroup_annotation(
+ &self,
+ editgroup_id: String,
+ annotation: models::EditgroupAnnotation,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateEditgroupAnnotationResponse, Error = ApiError> + Send>;
- fn get_changelog_entry(&self, index: i64, context: &Context) -> Box<dyn Future<Item = GetChangelogEntryResponse, Error = ApiError> + Send>;
+ fn create_file(
+ &self,
+ editgroup_id: String,
+ entity: models::FileEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateFileResponse, Error = ApiError> + Send>;
- fn create_container(&self, editgroup_id: String, entity: models::ContainerEntity, context: &Context) -> Box<dyn Future<Item = CreateContainerResponse, Error = ApiError> + Send>;
+ fn create_file_auto_batch(
+ &self,
+ auto_batch: models::FileAutoBatch,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateFileAutoBatchResponse, Error = ApiError> + Send>;
- fn create_container_auto_batch(&self, auto_batch: models::ContainerAutoBatch, context: &Context) -> Box<dyn Future<Item = CreateContainerAutoBatchResponse, Error = ApiError> + Send>;
+ fn create_fileset(
+ &self,
+ editgroup_id: String,
+ entity: models::FilesetEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateFilesetResponse, Error = ApiError> + Send>;
- fn delete_container(&self, editgroup_id: String, ident: String, context: &Context) -> Box<dyn Future<Item = DeleteContainerResponse, Error = ApiError> + Send>;
+ fn create_fileset_auto_batch(
+ &self,
+ auto_batch: models::FilesetAutoBatch,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateFilesetAutoBatchResponse, Error = ApiError> + Send>;
- fn delete_container_edit(&self, editgroup_id: String, edit_id: String, context: &Context) -> Box<dyn Future<Item = DeleteContainerEditResponse, Error = ApiError> + Send>;
+ fn create_release(
+ &self,
+ editgroup_id: String,
+ entity: models::ReleaseEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateReleaseResponse, Error = ApiError> + Send>;
- fn get_container(&self, ident: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetContainerResponse, Error = ApiError> + Send>;
+ fn create_release_auto_batch(
+ &self,
+ auto_batch: models::ReleaseAutoBatch,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateReleaseAutoBatchResponse, Error = ApiError> + Send>;
- fn get_container_edit(&self, edit_id: String, context: &Context) -> Box<dyn Future<Item = GetContainerEditResponse, Error = ApiError> + Send>;
+ fn create_webcapture(
+ &self,
+ editgroup_id: String,
+ entity: models::WebcaptureEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateWebcaptureResponse, Error = ApiError> + Send>;
- fn get_container_history(&self, ident: String, limit: Option<i64>, context: &Context) -> Box<dyn Future<Item = GetContainerHistoryResponse, Error = ApiError> + Send>;
+ fn create_webcapture_auto_batch(
+ &self,
+ auto_batch: models::WebcaptureAutoBatch,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateWebcaptureAutoBatchResponse, Error = ApiError> + Send>;
- fn get_container_redirects(&self, ident: String, context: &Context) -> Box<dyn Future<Item = GetContainerRedirectsResponse, Error = ApiError> + Send>;
+ fn create_work(
+ &self,
+ editgroup_id: String,
+ entity: models::WorkEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateWorkResponse, Error = ApiError> + Send>;
- fn get_container_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetContainerRevisionResponse, Error = ApiError> + Send>;
+ fn create_work_auto_batch(
+ &self,
+ auto_batch: models::WorkAutoBatch,
+ context: &C,
+ ) -> Box<dyn Future<Item = CreateWorkAutoBatchResponse, Error = ApiError> + Send>;
- fn lookup_container(
+ fn delete_container(
&self,
- issnl: Option<String>,
- wikidata_qid: Option<String>,
- expand: Option<String>,
- hide: Option<String>,
- context: &Context,
- ) -> Box<dyn Future<Item = LookupContainerResponse, Error = ApiError> + Send>;
+ editgroup_id: String,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteContainerResponse, Error = ApiError> + Send>;
- fn update_container(&self, editgroup_id: String, ident: String, entity: models::ContainerEntity, context: &Context) -> Box<dyn Future<Item = UpdateContainerResponse, Error = ApiError> + Send>;
+ fn delete_container_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteContainerEditResponse, Error = ApiError> + Send>;
- fn create_creator(&self, editgroup_id: String, entity: models::CreatorEntity, context: &Context) -> Box<dyn Future<Item = CreateCreatorResponse, Error = ApiError> + Send>;
+ fn delete_creator(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteCreatorResponse, Error = ApiError> + Send>;
- fn create_creator_auto_batch(&self, auto_batch: models::CreatorAutoBatch, context: &Context) -> Box<dyn Future<Item = CreateCreatorAutoBatchResponse, Error = ApiError> + Send>;
+ fn delete_creator_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteCreatorEditResponse, Error = ApiError> + Send>;
- fn delete_creator(&self, editgroup_id: String, ident: String, context: &Context) -> Box<dyn Future<Item = DeleteCreatorResponse, Error = ApiError> + Send>;
+ fn delete_file(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteFileResponse, Error = ApiError> + Send>;
- fn delete_creator_edit(&self, editgroup_id: String, edit_id: String, context: &Context) -> Box<dyn Future<Item = DeleteCreatorEditResponse, Error = ApiError> + Send>;
+ fn delete_file_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteFileEditResponse, Error = ApiError> + Send>;
- fn get_creator(&self, ident: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetCreatorResponse, Error = ApiError> + Send>;
+ fn delete_fileset(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteFilesetResponse, Error = ApiError> + Send>;
- fn get_creator_edit(&self, edit_id: String, context: &Context) -> Box<dyn Future<Item = GetCreatorEditResponse, Error = ApiError> + Send>;
+ fn delete_fileset_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteFilesetEditResponse, Error = ApiError> + Send>;
- fn get_creator_history(&self, ident: String, limit: Option<i64>, context: &Context) -> Box<dyn Future<Item = GetCreatorHistoryResponse, Error = ApiError> + Send>;
+ fn delete_release(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteReleaseResponse, Error = ApiError> + Send>;
- fn get_creator_redirects(&self, ident: String, context: &Context) -> Box<dyn Future<Item = GetCreatorRedirectsResponse, Error = ApiError> + Send>;
+ fn delete_release_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteReleaseEditResponse, Error = ApiError> + Send>;
- fn get_creator_releases(&self, ident: String, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetCreatorReleasesResponse, Error = ApiError> + Send>;
+ fn delete_webcapture(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteWebcaptureResponse, Error = ApiError> + Send>;
- fn get_creator_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetCreatorRevisionResponse, Error = ApiError> + Send>;
+ fn delete_webcapture_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteWebcaptureEditResponse, Error = ApiError> + Send>;
- fn lookup_creator(
+ fn delete_work(
&self,
- orcid: Option<String>,
- wikidata_qid: Option<String>,
+ editgroup_id: String,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteWorkResponse, Error = ApiError> + Send>;
+
+ fn delete_work_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = DeleteWorkEditResponse, Error = ApiError> + Send>;
+
+ fn get_changelog(
+ &self,
+ limit: Option<i64>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetChangelogResponse, Error = ApiError> + Send>;
+
+ fn get_changelog_entry(
+ &self,
+ index: i64,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetChangelogEntryResponse, Error = ApiError> + Send>;
+
+ fn get_container(
+ &self,
+ ident: String,
expand: Option<String>,
hide: Option<String>,
- context: &Context,
- ) -> Box<dyn Future<Item = LookupCreatorResponse, Error = ApiError> + Send>;
+ context: &C,
+ ) -> Box<dyn Future<Item = GetContainerResponse, Error = ApiError> + Send>;
+
+ fn get_container_edit(
+ &self,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetContainerEditResponse, Error = ApiError> + Send>;
+
+ fn get_container_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetContainerHistoryResponse, Error = ApiError> + Send>;
- fn update_creator(&self, editgroup_id: String, ident: String, entity: models::CreatorEntity, context: &Context) -> Box<dyn Future<Item = UpdateCreatorResponse, Error = ApiError> + Send>;
+ fn get_container_redirects(
+ &self,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetContainerRedirectsResponse, Error = ApiError> + Send>;
- fn accept_editgroup(&self, editgroup_id: String, context: &Context) -> Box<dyn Future<Item = AcceptEditgroupResponse, Error = ApiError> + Send>;
+ fn get_container_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetContainerRevisionResponse, Error = ApiError> + Send>;
- fn create_editgroup(&self, editgroup: models::Editgroup, context: &Context) -> Box<dyn Future<Item = CreateEditgroupResponse, Error = ApiError> + Send>;
+ fn get_creator(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetCreatorResponse, Error = ApiError> + Send>;
- fn create_editgroup_annotation(
+ fn get_creator_edit(
&self,
- editgroup_id: String,
- annotation: models::EditgroupAnnotation,
- context: &Context,
- ) -> Box<dyn Future<Item = CreateEditgroupAnnotationResponse, Error = ApiError> + Send>;
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetCreatorEditResponse, Error = ApiError> + Send>;
+
+ fn get_creator_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetCreatorHistoryResponse, Error = ApiError> + Send>;
+
+ fn get_creator_redirects(
+ &self,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetCreatorRedirectsResponse, Error = ApiError> + Send>;
+
+ fn get_creator_releases(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetCreatorReleasesResponse, Error = ApiError> + Send>;
+
+ fn get_creator_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetCreatorRevisionResponse, Error = ApiError> + Send>;
- fn get_editgroup(&self, editgroup_id: String, context: &Context) -> Box<dyn Future<Item = GetEditgroupResponse, Error = ApiError> + Send>;
+ fn get_editgroup(
+ &self,
+ editgroup_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetEditgroupResponse, Error = ApiError> + Send>;
- fn get_editgroup_annotations(&self, editgroup_id: String, expand: Option<String>, context: &Context) -> Box<dyn Future<Item = GetEditgroupAnnotationsResponse, Error = ApiError> + Send>;
+ fn get_editgroup_annotations(
+ &self,
+ editgroup_id: String,
+ expand: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetEditgroupAnnotationsResponse, Error = ApiError> + Send>;
fn get_editgroups_reviewable(
&self,
@@ -1443,13 +1904,14 @@ pub trait Api {
limit: Option<i64>,
before: Option<chrono::DateTime<chrono::Utc>>,
since: Option<chrono::DateTime<chrono::Utc>>,
- context: &Context,
+ context: &C,
) -> Box<dyn Future<Item = GetEditgroupsReviewableResponse, Error = ApiError> + Send>;
- fn update_editgroup(&self, editgroup_id: String, editgroup: models::Editgroup, submit: Option<bool>, context: &Context)
- -> Box<dyn Future<Item = UpdateEditgroupResponse, Error = ApiError> + Send>;
-
- fn get_editor(&self, editor_id: String, context: &Context) -> Box<dyn Future<Item = GetEditorResponse, Error = ApiError> + Send>;
+ fn get_editor(
+ &self,
+ editor_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetEditorResponse, Error = ApiError> + Send>;
fn get_editor_annotations(
&self,
@@ -1457,7 +1919,7 @@ pub trait Api {
limit: Option<i64>,
before: Option<chrono::DateTime<chrono::Utc>>,
since: Option<chrono::DateTime<chrono::Utc>>,
- context: &Context,
+ context: &C,
) -> Box<dyn Future<Item = GetEditorAnnotationsResponse, Error = ApiError> + Send>;
fn get_editor_editgroups(
@@ -1466,84 +1928,239 @@ pub trait Api {
limit: Option<i64>,
before: Option<chrono::DateTime<chrono::Utc>>,
since: Option<chrono::DateTime<chrono::Utc>>,
- context: &Context,
+ context: &C,
) -> Box<dyn Future<Item = GetEditorEditgroupsResponse, Error = ApiError> + Send>;
- fn update_editor(&self, editor_id: String, editor: models::Editor, context: &Context) -> Box<dyn Future<Item = UpdateEditorResponse, Error = ApiError> + Send>;
-
- fn create_file(&self, editgroup_id: String, entity: models::FileEntity, context: &Context) -> Box<dyn Future<Item = CreateFileResponse, Error = ApiError> + Send>;
+ fn get_file(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetFileResponse, Error = ApiError> + Send>;
- fn create_file_auto_batch(&self, auto_batch: models::FileAutoBatch, context: &Context) -> Box<dyn Future<Item = CreateFileAutoBatchResponse, Error = ApiError> + Send>;
+ fn get_file_edit(
+ &self,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetFileEditResponse, Error = ApiError> + Send>;
- fn delete_file(&self, editgroup_id: String, ident: String, context: &Context) -> Box<dyn Future<Item = DeleteFileResponse, Error = ApiError> + Send>;
+ fn get_file_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetFileHistoryResponse, Error = ApiError> + Send>;
- fn delete_file_edit(&self, editgroup_id: String, edit_id: String, context: &Context) -> Box<dyn Future<Item = DeleteFileEditResponse, Error = ApiError> + Send>;
+ fn get_file_redirects(
+ &self,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetFileRedirectsResponse, Error = ApiError> + Send>;
- fn get_file(&self, ident: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetFileResponse, Error = ApiError> + Send>;
+ fn get_file_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetFileRevisionResponse, Error = ApiError> + Send>;
- fn get_file_edit(&self, edit_id: String, context: &Context) -> Box<dyn Future<Item = GetFileEditResponse, Error = ApiError> + Send>;
+ fn get_fileset(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetFilesetResponse, Error = ApiError> + Send>;
- fn get_file_history(&self, ident: String, limit: Option<i64>, context: &Context) -> Box<dyn Future<Item = GetFileHistoryResponse, Error = ApiError> + Send>;
+ fn get_fileset_edit(
+ &self,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetFilesetEditResponse, Error = ApiError> + Send>;
- fn get_file_redirects(&self, ident: String, context: &Context) -> Box<dyn Future<Item = GetFileRedirectsResponse, Error = ApiError> + Send>;
+ fn get_fileset_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetFilesetHistoryResponse, Error = ApiError> + Send>;
- fn get_file_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetFileRevisionResponse, Error = ApiError> + Send>;
+ fn get_fileset_redirects(
+ &self,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetFilesetRedirectsResponse, Error = ApiError> + Send>;
- fn lookup_file(
+ fn get_fileset_revision(
&self,
- md5: Option<String>,
- sha1: Option<String>,
- sha256: Option<String>,
+ rev_id: String,
expand: Option<String>,
hide: Option<String>,
- context: &Context,
- ) -> Box<dyn Future<Item = LookupFileResponse, Error = ApiError> + Send>;
+ context: &C,
+ ) -> Box<dyn Future<Item = GetFilesetRevisionResponse, Error = ApiError> + Send>;
- fn update_file(&self, editgroup_id: String, ident: String, entity: models::FileEntity, context: &Context) -> Box<dyn Future<Item = UpdateFileResponse, Error = ApiError> + Send>;
-
- fn create_fileset(&self, editgroup_id: String, entity: models::FilesetEntity, context: &Context) -> Box<dyn Future<Item = CreateFilesetResponse, Error = ApiError> + Send>;
+ fn get_release(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetReleaseResponse, Error = ApiError> + Send>;
- fn create_fileset_auto_batch(&self, auto_batch: models::FilesetAutoBatch, context: &Context) -> Box<dyn Future<Item = CreateFilesetAutoBatchResponse, Error = ApiError> + Send>;
+ fn get_release_edit(
+ &self,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetReleaseEditResponse, Error = ApiError> + Send>;
- fn delete_fileset(&self, editgroup_id: String, ident: String, context: &Context) -> Box<dyn Future<Item = DeleteFilesetResponse, Error = ApiError> + Send>;
+ fn get_release_files(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetReleaseFilesResponse, Error = ApiError> + Send>;
- fn delete_fileset_edit(&self, editgroup_id: String, edit_id: String, context: &Context) -> Box<dyn Future<Item = DeleteFilesetEditResponse, Error = ApiError> + Send>;
+ fn get_release_filesets(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetReleaseFilesetsResponse, Error = ApiError> + Send>;
- fn get_fileset(&self, ident: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetFilesetResponse, Error = ApiError> + Send>;
+ fn get_release_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetReleaseHistoryResponse, Error = ApiError> + Send>;
- fn get_fileset_edit(&self, edit_id: String, context: &Context) -> Box<dyn Future<Item = GetFilesetEditResponse, Error = ApiError> + Send>;
+ fn get_release_redirects(
+ &self,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetReleaseRedirectsResponse, Error = ApiError> + Send>;
- fn get_fileset_history(&self, ident: String, limit: Option<i64>, context: &Context) -> Box<dyn Future<Item = GetFilesetHistoryResponse, Error = ApiError> + Send>;
+ fn get_release_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetReleaseRevisionResponse, Error = ApiError> + Send>;
- fn get_fileset_redirects(&self, ident: String, context: &Context) -> Box<dyn Future<Item = GetFilesetRedirectsResponse, Error = ApiError> + Send>;
+ fn get_release_webcaptures(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetReleaseWebcapturesResponse, Error = ApiError> + Send>;
- fn get_fileset_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetFilesetRevisionResponse, Error = ApiError> + Send>;
+ fn get_webcapture(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetWebcaptureResponse, Error = ApiError> + Send>;
- fn update_fileset(&self, editgroup_id: String, ident: String, entity: models::FilesetEntity, context: &Context) -> Box<dyn Future<Item = UpdateFilesetResponse, Error = ApiError> + Send>;
+ fn get_webcapture_edit(
+ &self,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetWebcaptureEditResponse, Error = ApiError> + Send>;
- fn create_release(&self, editgroup_id: String, entity: models::ReleaseEntity, context: &Context) -> Box<dyn Future<Item = CreateReleaseResponse, Error = ApiError> + Send>;
+ fn get_webcapture_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetWebcaptureHistoryResponse, Error = ApiError> + Send>;
- fn create_release_auto_batch(&self, auto_batch: models::ReleaseAutoBatch, context: &Context) -> Box<dyn Future<Item = CreateReleaseAutoBatchResponse, Error = ApiError> + Send>;
+ fn get_webcapture_redirects(
+ &self,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetWebcaptureRedirectsResponse, Error = ApiError> + Send>;
- fn delete_release(&self, editgroup_id: String, ident: String, context: &Context) -> Box<dyn Future<Item = DeleteReleaseResponse, Error = ApiError> + Send>;
+ fn get_webcapture_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetWebcaptureRevisionResponse, Error = ApiError> + Send>;
- fn delete_release_edit(&self, editgroup_id: String, edit_id: String, context: &Context) -> Box<dyn Future<Item = DeleteReleaseEditResponse, Error = ApiError> + Send>;
+ fn get_work(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetWorkResponse, Error = ApiError> + Send>;
- fn get_release(&self, ident: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetReleaseResponse, Error = ApiError> + Send>;
+ fn get_work_edit(
+ &self,
+ edit_id: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetWorkEditResponse, Error = ApiError> + Send>;
- fn get_release_edit(&self, edit_id: String, context: &Context) -> Box<dyn Future<Item = GetReleaseEditResponse, Error = ApiError> + Send>;
+ fn get_work_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetWorkHistoryResponse, Error = ApiError> + Send>;
- fn get_release_files(&self, ident: String, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetReleaseFilesResponse, Error = ApiError> + Send>;
+ fn get_work_redirects(
+ &self,
+ ident: String,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetWorkRedirectsResponse, Error = ApiError> + Send>;
- fn get_release_filesets(&self, ident: String, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetReleaseFilesetsResponse, Error = ApiError> + Send>;
+ fn get_work_releases(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetWorkReleasesResponse, Error = ApiError> + Send>;
- fn get_release_history(&self, ident: String, limit: Option<i64>, context: &Context) -> Box<dyn Future<Item = GetReleaseHistoryResponse, Error = ApiError> + Send>;
+ fn get_work_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = GetWorkRevisionResponse, Error = ApiError> + Send>;
- fn get_release_redirects(&self, ident: String, context: &Context) -> Box<dyn Future<Item = GetReleaseRedirectsResponse, Error = ApiError> + Send>;
+ fn lookup_container(
+ &self,
+ issnl: Option<String>,
+ wikidata_qid: Option<String>,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = LookupContainerResponse, Error = ApiError> + Send>;
- fn get_release_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetReleaseRevisionResponse, Error = ApiError> + Send>;
+ fn lookup_creator(
+ &self,
+ orcid: Option<String>,
+ wikidata_qid: Option<String>,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = LookupCreatorResponse, Error = ApiError> + Send>;
- fn get_release_webcaptures(&self, ident: String, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetReleaseWebcapturesResponse, Error = ApiError> + Send>;
+ fn lookup_file(
+ &self,
+ md5: Option<String>,
+ sha1: Option<String>,
+ sha256: Option<String>,
+ expand: Option<String>,
+ hide: Option<String>,
+ context: &C,
+ ) -> Box<dyn Future<Item = LookupFileResponse, Error = ApiError> + Send>;
fn lookup_release(
&self,
@@ -1559,139 +2176,362 @@ pub trait Api {
mag: Option<String>,
expand: Option<String>,
hide: Option<String>,
- context: &Context,
+ context: &C,
) -> Box<dyn Future<Item = LookupReleaseResponse, Error = ApiError> + Send>;
- fn update_release(&self, editgroup_id: String, ident: String, entity: models::ReleaseEntity, context: &Context) -> Box<dyn Future<Item = UpdateReleaseResponse, Error = ApiError> + Send>;
+ fn update_container(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::ContainerEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = UpdateContainerResponse, Error = ApiError> + Send>;
- fn create_webcapture(&self, editgroup_id: String, entity: models::WebcaptureEntity, context: &Context) -> Box<dyn Future<Item = CreateWebcaptureResponse, Error = ApiError> + Send>;
+ fn update_creator(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::CreatorEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = UpdateCreatorResponse, Error = ApiError> + Send>;
- fn create_webcapture_auto_batch(&self, auto_batch: models::WebcaptureAutoBatch, context: &Context) -> Box<dyn Future<Item = CreateWebcaptureAutoBatchResponse, Error = ApiError> + Send>;
+ fn update_editgroup(
+ &self,
+ editgroup_id: String,
+ editgroup: models::Editgroup,
+ submit: Option<bool>,
+ context: &C,
+ ) -> Box<dyn Future<Item = UpdateEditgroupResponse, Error = ApiError> + Send>;
- fn delete_webcapture(&self, editgroup_id: String, ident: String, context: &Context) -> Box<dyn Future<Item = DeleteWebcaptureResponse, Error = ApiError> + Send>;
+ fn update_editor(
+ &self,
+ editor_id: String,
+ editor: models::Editor,
+ context: &C,
+ ) -> Box<dyn Future<Item = UpdateEditorResponse, Error = ApiError> + Send>;
- fn delete_webcapture_edit(&self, editgroup_id: String, edit_id: String, context: &Context) -> Box<dyn Future<Item = DeleteWebcaptureEditResponse, Error = ApiError> + Send>;
+ fn update_file(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::FileEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = UpdateFileResponse, Error = ApiError> + Send>;
- fn get_webcapture(&self, ident: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetWebcaptureResponse, Error = ApiError> + Send>;
+ fn update_fileset(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::FilesetEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = UpdateFilesetResponse, Error = ApiError> + Send>;
- fn get_webcapture_edit(&self, edit_id: String, context: &Context) -> Box<dyn Future<Item = GetWebcaptureEditResponse, Error = ApiError> + Send>;
+ fn update_release(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::ReleaseEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = UpdateReleaseResponse, Error = ApiError> + Send>;
- fn get_webcapture_history(&self, ident: String, limit: Option<i64>, context: &Context) -> Box<dyn Future<Item = GetWebcaptureHistoryResponse, Error = ApiError> + Send>;
+ fn update_webcapture(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::WebcaptureEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = UpdateWebcaptureResponse, Error = ApiError> + Send>;
- fn get_webcapture_redirects(&self, ident: String, context: &Context) -> Box<dyn Future<Item = GetWebcaptureRedirectsResponse, Error = ApiError> + Send>;
+ fn update_work(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::WorkEntity,
+ context: &C,
+ ) -> Box<dyn Future<Item = UpdateWorkResponse, Error = ApiError> + Send>;
+}
- fn get_webcapture_revision(
+/// API without a `Context`
+pub trait ApiNoContext {
+ fn accept_editgroup(
&self,
- rev_id: String,
- expand: Option<String>,
- hide: Option<String>,
- context: &Context,
- ) -> Box<dyn Future<Item = GetWebcaptureRevisionResponse, Error = ApiError> + Send>;
+ editgroup_id: String,
+ ) -> Box<dyn Future<Item = AcceptEditgroupResponse, Error = ApiError> + Send>;
- fn update_webcapture(&self, editgroup_id: String, ident: String, entity: models::WebcaptureEntity, context: &Context) -> Box<dyn Future<Item = UpdateWebcaptureResponse, Error = ApiError> + Send>;
+ fn auth_check(
+ &self,
+ role: Option<String>,
+ ) -> Box<dyn Future<Item = AuthCheckResponse, Error = ApiError> + Send>;
- fn create_work(&self, editgroup_id: String, entity: models::WorkEntity, context: &Context) -> Box<dyn Future<Item = CreateWorkResponse, Error = ApiError> + Send>;
+ fn auth_oidc(
+ &self,
+ oidc_params: models::AuthOidc,
+ ) -> Box<dyn Future<Item = AuthOidcResponse, Error = ApiError> + Send>;
- fn create_work_auto_batch(&self, auto_batch: models::WorkAutoBatch, context: &Context) -> Box<dyn Future<Item = CreateWorkAutoBatchResponse, Error = ApiError> + Send>;
+ fn create_auth_token(
+ &self,
+ editor_id: String,
+ duration_seconds: Option<i32>,
+ ) -> Box<dyn Future<Item = CreateAuthTokenResponse, Error = ApiError> + Send>;
- fn delete_work(&self, editgroup_id: String, ident: String, context: &Context) -> Box<dyn Future<Item = DeleteWorkResponse, Error = ApiError> + Send>;
+ fn create_container(
+ &self,
+ editgroup_id: String,
+ entity: models::ContainerEntity,
+ ) -> Box<dyn Future<Item = CreateContainerResponse, Error = ApiError> + Send>;
- fn delete_work_edit(&self, editgroup_id: String, edit_id: String, context: &Context) -> Box<dyn Future<Item = DeleteWorkEditResponse, Error = ApiError> + Send>;
+ fn create_container_auto_batch(
+ &self,
+ auto_batch: models::ContainerAutoBatch,
+ ) -> Box<dyn Future<Item = CreateContainerAutoBatchResponse, Error = ApiError> + Send>;
- fn get_work(&self, ident: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetWorkResponse, Error = ApiError> + Send>;
+ fn create_creator(
+ &self,
+ editgroup_id: String,
+ entity: models::CreatorEntity,
+ ) -> Box<dyn Future<Item = CreateCreatorResponse, Error = ApiError> + Send>;
- fn get_work_edit(&self, edit_id: String, context: &Context) -> Box<dyn Future<Item = GetWorkEditResponse, Error = ApiError> + Send>;
+ fn create_creator_auto_batch(
+ &self,
+ auto_batch: models::CreatorAutoBatch,
+ ) -> Box<dyn Future<Item = CreateCreatorAutoBatchResponse, Error = ApiError> + Send>;
- fn get_work_history(&self, ident: String, limit: Option<i64>, context: &Context) -> Box<dyn Future<Item = GetWorkHistoryResponse, Error = ApiError> + Send>;
+ fn create_editgroup(
+ &self,
+ editgroup: models::Editgroup,
+ ) -> Box<dyn Future<Item = CreateEditgroupResponse, Error = ApiError> + Send>;
- fn get_work_redirects(&self, ident: String, context: &Context) -> Box<dyn Future<Item = GetWorkRedirectsResponse, Error = ApiError> + Send>;
+ fn create_editgroup_annotation(
+ &self,
+ editgroup_id: String,
+ annotation: models::EditgroupAnnotation,
+ ) -> Box<dyn Future<Item = CreateEditgroupAnnotationResponse, Error = ApiError> + Send>;
- fn get_work_releases(&self, ident: String, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetWorkReleasesResponse, Error = ApiError> + Send>;
+ fn create_file(
+ &self,
+ editgroup_id: String,
+ entity: models::FileEntity,
+ ) -> Box<dyn Future<Item = CreateFileResponse, Error = ApiError> + Send>;
- fn get_work_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>, context: &Context) -> Box<dyn Future<Item = GetWorkRevisionResponse, Error = ApiError> + Send>;
+ fn create_file_auto_batch(
+ &self,
+ auto_batch: models::FileAutoBatch,
+ ) -> Box<dyn Future<Item = CreateFileAutoBatchResponse, Error = ApiError> + Send>;
- fn update_work(&self, editgroup_id: String, ident: String, entity: models::WorkEntity, context: &Context) -> Box<dyn Future<Item = UpdateWorkResponse, Error = ApiError> + Send>;
-}
+ fn create_fileset(
+ &self,
+ editgroup_id: String,
+ entity: models::FilesetEntity,
+ ) -> Box<dyn Future<Item = CreateFilesetResponse, Error = ApiError> + Send>;
-/// API without a `Context`
-pub trait ApiNoContext {
- fn auth_check(&self, role: Option<String>) -> Box<dyn Future<Item = AuthCheckResponse, Error = ApiError> + Send>;
+ fn create_fileset_auto_batch(
+ &self,
+ auto_batch: models::FilesetAutoBatch,
+ ) -> Box<dyn Future<Item = CreateFilesetAutoBatchResponse, Error = ApiError> + Send>;
- fn auth_oidc(&self, oidc_params: models::AuthOidc) -> Box<dyn Future<Item = AuthOidcResponse, Error = ApiError> + Send>;
+ fn create_release(
+ &self,
+ editgroup_id: String,
+ entity: models::ReleaseEntity,
+ ) -> Box<dyn Future<Item = CreateReleaseResponse, Error = ApiError> + Send>;
- fn create_auth_token(&self, editor_id: String, duration_seconds: Option<i32>) -> Box<dyn Future<Item = CreateAuthTokenResponse, Error = ApiError> + Send>;
+ fn create_release_auto_batch(
+ &self,
+ auto_batch: models::ReleaseAutoBatch,
+ ) -> Box<dyn Future<Item = CreateReleaseAutoBatchResponse, Error = ApiError> + Send>;
- fn get_changelog(&self, limit: Option<i64>) -> Box<dyn Future<Item = GetChangelogResponse, Error = ApiError> + Send>;
+ fn create_webcapture(
+ &self,
+ editgroup_id: String,
+ entity: models::WebcaptureEntity,
+ ) -> Box<dyn Future<Item = CreateWebcaptureResponse, Error = ApiError> + Send>;
- fn get_changelog_entry(&self, index: i64) -> Box<dyn Future<Item = GetChangelogEntryResponse, Error = ApiError> + Send>;
+ fn create_webcapture_auto_batch(
+ &self,
+ auto_batch: models::WebcaptureAutoBatch,
+ ) -> Box<dyn Future<Item = CreateWebcaptureAutoBatchResponse, Error = ApiError> + Send>;
- fn create_container(&self, editgroup_id: String, entity: models::ContainerEntity) -> Box<dyn Future<Item = CreateContainerResponse, Error = ApiError> + Send>;
+ fn create_work(
+ &self,
+ editgroup_id: String,
+ entity: models::WorkEntity,
+ ) -> Box<dyn Future<Item = CreateWorkResponse, Error = ApiError> + Send>;
- fn create_container_auto_batch(&self, auto_batch: models::ContainerAutoBatch) -> Box<dyn Future<Item = CreateContainerAutoBatchResponse, Error = ApiError> + Send>;
+ fn create_work_auto_batch(
+ &self,
+ auto_batch: models::WorkAutoBatch,
+ ) -> Box<dyn Future<Item = CreateWorkAutoBatchResponse, Error = ApiError> + Send>;
- fn delete_container(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteContainerResponse, Error = ApiError> + Send>;
+ fn delete_container(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteContainerResponse, Error = ApiError> + Send>;
- fn delete_container_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteContainerEditResponse, Error = ApiError> + Send>;
+ fn delete_container_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteContainerEditResponse, Error = ApiError> + Send>;
- fn get_container(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetContainerResponse, Error = ApiError> + Send>;
+ fn delete_creator(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteCreatorResponse, Error = ApiError> + Send>;
- fn get_container_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetContainerEditResponse, Error = ApiError> + Send>;
+ fn delete_creator_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteCreatorEditResponse, Error = ApiError> + Send>;
- fn get_container_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetContainerHistoryResponse, Error = ApiError> + Send>;
+ fn delete_file(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteFileResponse, Error = ApiError> + Send>;
- fn get_container_redirects(&self, ident: String) -> Box<dyn Future<Item = GetContainerRedirectsResponse, Error = ApiError> + Send>;
+ fn delete_file_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteFileEditResponse, Error = ApiError> + Send>;
- fn get_container_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetContainerRevisionResponse, Error = ApiError> + Send>;
+ fn delete_fileset(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteFilesetResponse, Error = ApiError> + Send>;
- fn lookup_container(
+ fn delete_fileset_edit(
&self,
- issnl: Option<String>,
- wikidata_qid: Option<String>,
- expand: Option<String>,
- hide: Option<String>,
- ) -> Box<dyn Future<Item = LookupContainerResponse, Error = ApiError> + Send>;
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteFilesetEditResponse, Error = ApiError> + Send>;
- fn update_container(&self, editgroup_id: String, ident: String, entity: models::ContainerEntity) -> Box<dyn Future<Item = UpdateContainerResponse, Error = ApiError> + Send>;
+ fn delete_release(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteReleaseResponse, Error = ApiError> + Send>;
- fn create_creator(&self, editgroup_id: String, entity: models::CreatorEntity) -> Box<dyn Future<Item = CreateCreatorResponse, Error = ApiError> + Send>;
+ fn delete_release_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteReleaseEditResponse, Error = ApiError> + Send>;
+
+ fn delete_webcapture(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteWebcaptureResponse, Error = ApiError> + Send>;
- fn create_creator_auto_batch(&self, auto_batch: models::CreatorAutoBatch) -> Box<dyn Future<Item = CreateCreatorAutoBatchResponse, Error = ApiError> + Send>;
+ fn delete_webcapture_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteWebcaptureEditResponse, Error = ApiError> + Send>;
- fn delete_creator(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteCreatorResponse, Error = ApiError> + Send>;
+ fn delete_work(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteWorkResponse, Error = ApiError> + Send>;
- fn delete_creator_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteCreatorEditResponse, Error = ApiError> + Send>;
+ fn delete_work_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteWorkEditResponse, Error = ApiError> + Send>;
- fn get_creator(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetCreatorResponse, Error = ApiError> + Send>;
+ fn get_changelog(
+ &self,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetChangelogResponse, Error = ApiError> + Send>;
- fn get_creator_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetCreatorEditResponse, Error = ApiError> + Send>;
+ fn get_changelog_entry(
+ &self,
+ index: i64,
+ ) -> Box<dyn Future<Item = GetChangelogEntryResponse, Error = ApiError> + Send>;
- fn get_creator_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetCreatorHistoryResponse, Error = ApiError> + Send>;
+ fn get_container(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetContainerResponse, Error = ApiError> + Send>;
- fn get_creator_redirects(&self, ident: String) -> Box<dyn Future<Item = GetCreatorRedirectsResponse, Error = ApiError> + Send>;
+ fn get_container_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetContainerEditResponse, Error = ApiError> + Send>;
- fn get_creator_releases(&self, ident: String, hide: Option<String>) -> Box<dyn Future<Item = GetCreatorReleasesResponse, Error = ApiError> + Send>;
+ fn get_container_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetContainerHistoryResponse, Error = ApiError> + Send>;
- fn get_creator_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetCreatorRevisionResponse, Error = ApiError> + Send>;
+ fn get_container_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetContainerRedirectsResponse, Error = ApiError> + Send>;
- fn lookup_creator(
+ fn get_container_revision(
&self,
- orcid: Option<String>,
- wikidata_qid: Option<String>,
+ rev_id: String,
expand: Option<String>,
hide: Option<String>,
- ) -> Box<dyn Future<Item = LookupCreatorResponse, Error = ApiError> + Send>;
+ ) -> Box<dyn Future<Item = GetContainerRevisionResponse, Error = ApiError> + Send>;
- fn update_creator(&self, editgroup_id: String, ident: String, entity: models::CreatorEntity) -> Box<dyn Future<Item = UpdateCreatorResponse, Error = ApiError> + Send>;
+ fn get_creator(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetCreatorResponse, Error = ApiError> + Send>;
- fn accept_editgroup(&self, editgroup_id: String) -> Box<dyn Future<Item = AcceptEditgroupResponse, Error = ApiError> + Send>;
+ fn get_creator_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetCreatorEditResponse, Error = ApiError> + Send>;
- fn create_editgroup(&self, editgroup: models::Editgroup) -> Box<dyn Future<Item = CreateEditgroupResponse, Error = ApiError> + Send>;
+ fn get_creator_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetCreatorHistoryResponse, Error = ApiError> + Send>;
- fn create_editgroup_annotation(&self, editgroup_id: String, annotation: models::EditgroupAnnotation) -> Box<dyn Future<Item = CreateEditgroupAnnotationResponse, Error = ApiError> + Send>;
+ fn get_creator_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetCreatorRedirectsResponse, Error = ApiError> + Send>;
- fn get_editgroup(&self, editgroup_id: String) -> Box<dyn Future<Item = GetEditgroupResponse, Error = ApiError> + Send>;
+ fn get_creator_releases(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetCreatorReleasesResponse, Error = ApiError> + Send>;
- fn get_editgroup_annotations(&self, editgroup_id: String, expand: Option<String>) -> Box<dyn Future<Item = GetEditgroupAnnotationsResponse, Error = ApiError> + Send>;
+ fn get_creator_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetCreatorRevisionResponse, Error = ApiError> + Send>;
+
+ fn get_editgroup(
+ &self,
+ editgroup_id: String,
+ ) -> Box<dyn Future<Item = GetEditgroupResponse, Error = ApiError> + Send>;
+
+ fn get_editgroup_annotations(
+ &self,
+ editgroup_id: String,
+ expand: Option<String>,
+ ) -> Box<dyn Future<Item = GetEditgroupAnnotationsResponse, Error = ApiError> + Send>;
fn get_editgroups_reviewable(
&self,
@@ -1701,9 +2541,10 @@ pub trait ApiNoContext {
since: Option<chrono::DateTime<chrono::Utc>>,
) -> Box<dyn Future<Item = GetEditgroupsReviewableResponse, Error = ApiError> + Send>;
- fn update_editgroup(&self, editgroup_id: String, editgroup: models::Editgroup, submit: Option<bool>) -> Box<dyn Future<Item = UpdateEditgroupResponse, Error = ApiError> + Send>;
-
- fn get_editor(&self, editor_id: String) -> Box<dyn Future<Item = GetEditorResponse, Error = ApiError> + Send>;
+ fn get_editor(
+ &self,
+ editor_id: String,
+ ) -> Box<dyn Future<Item = GetEditorResponse, Error = ApiError> + Send>;
fn get_editor_annotations(
&self,
@@ -1721,80 +2562,204 @@ pub trait ApiNoContext {
since: Option<chrono::DateTime<chrono::Utc>>,
) -> Box<dyn Future<Item = GetEditorEditgroupsResponse, Error = ApiError> + Send>;
- fn update_editor(&self, editor_id: String, editor: models::Editor) -> Box<dyn Future<Item = UpdateEditorResponse, Error = ApiError> + Send>;
-
- fn create_file(&self, editgroup_id: String, entity: models::FileEntity) -> Box<dyn Future<Item = CreateFileResponse, Error = ApiError> + Send>;
+ fn get_file(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetFileResponse, Error = ApiError> + Send>;
- fn create_file_auto_batch(&self, auto_batch: models::FileAutoBatch) -> Box<dyn Future<Item = CreateFileAutoBatchResponse, Error = ApiError> + Send>;
+ fn get_file_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetFileEditResponse, Error = ApiError> + Send>;
- fn delete_file(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteFileResponse, Error = ApiError> + Send>;
+ fn get_file_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetFileHistoryResponse, Error = ApiError> + Send>;
- fn delete_file_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteFileEditResponse, Error = ApiError> + Send>;
+ fn get_file_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetFileRedirectsResponse, Error = ApiError> + Send>;
- fn get_file(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetFileResponse, Error = ApiError> + Send>;
+ fn get_file_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetFileRevisionResponse, Error = ApiError> + Send>;
- fn get_file_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetFileEditResponse, Error = ApiError> + Send>;
+ fn get_fileset(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetFilesetResponse, Error = ApiError> + Send>;
- fn get_file_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetFileHistoryResponse, Error = ApiError> + Send>;
+ fn get_fileset_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetFilesetEditResponse, Error = ApiError> + Send>;
- fn get_file_redirects(&self, ident: String) -> Box<dyn Future<Item = GetFileRedirectsResponse, Error = ApiError> + Send>;
+ fn get_fileset_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetFilesetHistoryResponse, Error = ApiError> + Send>;
- fn get_file_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetFileRevisionResponse, Error = ApiError> + Send>;
+ fn get_fileset_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetFilesetRedirectsResponse, Error = ApiError> + Send>;
- fn lookup_file(
+ fn get_fileset_revision(
&self,
- md5: Option<String>,
- sha1: Option<String>,
- sha256: Option<String>,
+ rev_id: String,
expand: Option<String>,
hide: Option<String>,
- ) -> Box<dyn Future<Item = LookupFileResponse, Error = ApiError> + Send>;
+ ) -> Box<dyn Future<Item = GetFilesetRevisionResponse, Error = ApiError> + Send>;
- fn update_file(&self, editgroup_id: String, ident: String, entity: models::FileEntity) -> Box<dyn Future<Item = UpdateFileResponse, Error = ApiError> + Send>;
-
- fn create_fileset(&self, editgroup_id: String, entity: models::FilesetEntity) -> Box<dyn Future<Item = CreateFilesetResponse, Error = ApiError> + Send>;
+ fn get_release(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetReleaseResponse, Error = ApiError> + Send>;
- fn create_fileset_auto_batch(&self, auto_batch: models::FilesetAutoBatch) -> Box<dyn Future<Item = CreateFilesetAutoBatchResponse, Error = ApiError> + Send>;
+ fn get_release_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetReleaseEditResponse, Error = ApiError> + Send>;
- fn delete_fileset(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteFilesetResponse, Error = ApiError> + Send>;
+ fn get_release_files(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetReleaseFilesResponse, Error = ApiError> + Send>;
- fn delete_fileset_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteFilesetEditResponse, Error = ApiError> + Send>;
+ fn get_release_filesets(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetReleaseFilesetsResponse, Error = ApiError> + Send>;
- fn get_fileset(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetFilesetResponse, Error = ApiError> + Send>;
+ fn get_release_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetReleaseHistoryResponse, Error = ApiError> + Send>;
- fn get_fileset_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetFilesetEditResponse, Error = ApiError> + Send>;
+ fn get_release_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetReleaseRedirectsResponse, Error = ApiError> + Send>;
- fn get_fileset_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetFilesetHistoryResponse, Error = ApiError> + Send>;
+ fn get_release_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetReleaseRevisionResponse, Error = ApiError> + Send>;
- fn get_fileset_redirects(&self, ident: String) -> Box<dyn Future<Item = GetFilesetRedirectsResponse, Error = ApiError> + Send>;
+ fn get_release_webcaptures(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetReleaseWebcapturesResponse, Error = ApiError> + Send>;
- fn get_fileset_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetFilesetRevisionResponse, Error = ApiError> + Send>;
+ fn get_webcapture(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetWebcaptureResponse, Error = ApiError> + Send>;
- fn update_fileset(&self, editgroup_id: String, ident: String, entity: models::FilesetEntity) -> Box<dyn Future<Item = UpdateFilesetResponse, Error = ApiError> + Send>;
+ fn get_webcapture_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetWebcaptureEditResponse, Error = ApiError> + Send>;
- fn create_release(&self, editgroup_id: String, entity: models::ReleaseEntity) -> Box<dyn Future<Item = CreateReleaseResponse, Error = ApiError> + Send>;
+ fn get_webcapture_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetWebcaptureHistoryResponse, Error = ApiError> + Send>;
- fn create_release_auto_batch(&self, auto_batch: models::ReleaseAutoBatch) -> Box<dyn Future<Item = CreateReleaseAutoBatchResponse, Error = ApiError> + Send>;
+ fn get_webcapture_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetWebcaptureRedirectsResponse, Error = ApiError> + Send>;
- fn delete_release(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteReleaseResponse, Error = ApiError> + Send>;
+ fn get_webcapture_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetWebcaptureRevisionResponse, Error = ApiError> + Send>;
- fn delete_release_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteReleaseEditResponse, Error = ApiError> + Send>;
+ fn get_work(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetWorkResponse, Error = ApiError> + Send>;
- fn get_release(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetReleaseResponse, Error = ApiError> + Send>;
+ fn get_work_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetWorkEditResponse, Error = ApiError> + Send>;
- fn get_release_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetReleaseEditResponse, Error = ApiError> + Send>;
+ fn get_work_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetWorkHistoryResponse, Error = ApiError> + Send>;
- fn get_release_files(&self, ident: String, hide: Option<String>) -> Box<dyn Future<Item = GetReleaseFilesResponse, Error = ApiError> + Send>;
+ fn get_work_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetWorkRedirectsResponse, Error = ApiError> + Send>;
- fn get_release_filesets(&self, ident: String, hide: Option<String>) -> Box<dyn Future<Item = GetReleaseFilesetsResponse, Error = ApiError> + Send>;
+ fn get_work_releases(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetWorkReleasesResponse, Error = ApiError> + Send>;
- fn get_release_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetReleaseHistoryResponse, Error = ApiError> + Send>;
+ fn get_work_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetWorkRevisionResponse, Error = ApiError> + Send>;
- fn get_release_redirects(&self, ident: String) -> Box<dyn Future<Item = GetReleaseRedirectsResponse, Error = ApiError> + Send>;
+ fn lookup_container(
+ &self,
+ issnl: Option<String>,
+ wikidata_qid: Option<String>,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = LookupContainerResponse, Error = ApiError> + Send>;
- fn get_release_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetReleaseRevisionResponse, Error = ApiError> + Send>;
+ fn lookup_creator(
+ &self,
+ orcid: Option<String>,
+ wikidata_qid: Option<String>,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = LookupCreatorResponse, Error = ApiError> + Send>;
- fn get_release_webcaptures(&self, ident: String, hide: Option<String>) -> Box<dyn Future<Item = GetReleaseWebcapturesResponse, Error = ApiError> + Send>;
+ fn lookup_file(
+ &self,
+ md5: Option<String>,
+ sha1: Option<String>,
+ sha256: Option<String>,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = LookupFileResponse, Error = ApiError> + Send>;
fn lookup_release(
&self,
@@ -1812,209 +2777,496 @@ pub trait ApiNoContext {
hide: Option<String>,
) -> Box<dyn Future<Item = LookupReleaseResponse, Error = ApiError> + Send>;
- fn update_release(&self, editgroup_id: String, ident: String, entity: models::ReleaseEntity) -> Box<dyn Future<Item = UpdateReleaseResponse, Error = ApiError> + Send>;
+ fn update_container(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::ContainerEntity,
+ ) -> Box<dyn Future<Item = UpdateContainerResponse, Error = ApiError> + Send>;
- fn create_webcapture(&self, editgroup_id: String, entity: models::WebcaptureEntity) -> Box<dyn Future<Item = CreateWebcaptureResponse, Error = ApiError> + Send>;
+ fn update_creator(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::CreatorEntity,
+ ) -> Box<dyn Future<Item = UpdateCreatorResponse, Error = ApiError> + Send>;
- fn create_webcapture_auto_batch(&self, auto_batch: models::WebcaptureAutoBatch) -> Box<dyn Future<Item = CreateWebcaptureAutoBatchResponse, Error = ApiError> + Send>;
+ fn update_editgroup(
+ &self,
+ editgroup_id: String,
+ editgroup: models::Editgroup,
+ submit: Option<bool>,
+ ) -> Box<dyn Future<Item = UpdateEditgroupResponse, Error = ApiError> + Send>;
- fn delete_webcapture(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteWebcaptureResponse, Error = ApiError> + Send>;
+ fn update_editor(
+ &self,
+ editor_id: String,
+ editor: models::Editor,
+ ) -> Box<dyn Future<Item = UpdateEditorResponse, Error = ApiError> + Send>;
- fn delete_webcapture_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteWebcaptureEditResponse, Error = ApiError> + Send>;
+ fn update_file(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::FileEntity,
+ ) -> Box<dyn Future<Item = UpdateFileResponse, Error = ApiError> + Send>;
- fn get_webcapture(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetWebcaptureResponse, Error = ApiError> + Send>;
+ fn update_fileset(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::FilesetEntity,
+ ) -> Box<dyn Future<Item = UpdateFilesetResponse, Error = ApiError> + Send>;
- fn get_webcapture_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetWebcaptureEditResponse, Error = ApiError> + Send>;
+ fn update_release(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::ReleaseEntity,
+ ) -> Box<dyn Future<Item = UpdateReleaseResponse, Error = ApiError> + Send>;
+
+ fn update_webcapture(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::WebcaptureEntity,
+ ) -> Box<dyn Future<Item = UpdateWebcaptureResponse, Error = ApiError> + Send>;
- fn get_webcapture_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetWebcaptureHistoryResponse, Error = ApiError> + Send>;
+ fn update_work(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::WorkEntity,
+ ) -> Box<dyn Future<Item = UpdateWorkResponse, Error = ApiError> + Send>;
+}
+
+/// Trait to extend an API to make it easy to bind it to a context.
+pub trait ContextWrapperExt<'a, C>
+where
+ Self: Sized,
+{
+ /// Binds this API to a context.
+ fn with_context(self: &'a Self, context: C) -> ContextWrapper<'a, Self, C>;
+}
- fn get_webcapture_redirects(&self, ident: String) -> Box<dyn Future<Item = GetWebcaptureRedirectsResponse, Error = ApiError> + Send>;
+impl<'a, T: Api<C> + Sized, C> ContextWrapperExt<'a, C> for T {
+ fn with_context(self: &'a T, context: C) -> ContextWrapper<'a, T, C> {
+ ContextWrapper::<T, C>::new(self, context)
+ }
+}
- fn get_webcapture_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetWebcaptureRevisionResponse, Error = ApiError> + Send>;
+impl<'a, T: Api<C>, C> ApiNoContext for ContextWrapper<'a, T, C> {
+ fn accept_editgroup(
+ &self,
+ editgroup_id: String,
+ ) -> Box<dyn Future<Item = AcceptEditgroupResponse, Error = ApiError> + Send> {
+ self.api().accept_editgroup(editgroup_id, &self.context())
+ }
- fn update_webcapture(&self, editgroup_id: String, ident: String, entity: models::WebcaptureEntity) -> Box<dyn Future<Item = UpdateWebcaptureResponse, Error = ApiError> + Send>;
+ fn auth_check(
+ &self,
+ role: Option<String>,
+ ) -> Box<dyn Future<Item = AuthCheckResponse, Error = ApiError> + Send> {
+ self.api().auth_check(role, &self.context())
+ }
- fn create_work(&self, editgroup_id: String, entity: models::WorkEntity) -> Box<dyn Future<Item = CreateWorkResponse, Error = ApiError> + Send>;
+ fn auth_oidc(
+ &self,
+ oidc_params: models::AuthOidc,
+ ) -> Box<dyn Future<Item = AuthOidcResponse, Error = ApiError> + Send> {
+ self.api().auth_oidc(oidc_params, &self.context())
+ }
- fn create_work_auto_batch(&self, auto_batch: models::WorkAutoBatch) -> Box<dyn Future<Item = CreateWorkAutoBatchResponse, Error = ApiError> + Send>;
+ fn create_auth_token(
+ &self,
+ editor_id: String,
+ duration_seconds: Option<i32>,
+ ) -> Box<dyn Future<Item = CreateAuthTokenResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_auth_token(editor_id, duration_seconds, &self.context())
+ }
- fn delete_work(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteWorkResponse, Error = ApiError> + Send>;
+ fn create_container(
+ &self,
+ editgroup_id: String,
+ entity: models::ContainerEntity,
+ ) -> Box<dyn Future<Item = CreateContainerResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_container(editgroup_id, entity, &self.context())
+ }
- fn delete_work_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteWorkEditResponse, Error = ApiError> + Send>;
+ fn create_container_auto_batch(
+ &self,
+ auto_batch: models::ContainerAutoBatch,
+ ) -> Box<dyn Future<Item = CreateContainerAutoBatchResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_container_auto_batch(auto_batch, &self.context())
+ }
- fn get_work(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetWorkResponse, Error = ApiError> + Send>;
+ fn create_creator(
+ &self,
+ editgroup_id: String,
+ entity: models::CreatorEntity,
+ ) -> Box<dyn Future<Item = CreateCreatorResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_creator(editgroup_id, entity, &self.context())
+ }
- fn get_work_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetWorkEditResponse, Error = ApiError> + Send>;
+ fn create_creator_auto_batch(
+ &self,
+ auto_batch: models::CreatorAutoBatch,
+ ) -> Box<dyn Future<Item = CreateCreatorAutoBatchResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_creator_auto_batch(auto_batch, &self.context())
+ }
- fn get_work_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetWorkHistoryResponse, Error = ApiError> + Send>;
+ fn create_editgroup(
+ &self,
+ editgroup: models::Editgroup,
+ ) -> Box<dyn Future<Item = CreateEditgroupResponse, Error = ApiError> + Send> {
+ self.api().create_editgroup(editgroup, &self.context())
+ }
- fn get_work_redirects(&self, ident: String) -> Box<dyn Future<Item = GetWorkRedirectsResponse, Error = ApiError> + Send>;
+ fn create_editgroup_annotation(
+ &self,
+ editgroup_id: String,
+ annotation: models::EditgroupAnnotation,
+ ) -> Box<dyn Future<Item = CreateEditgroupAnnotationResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_editgroup_annotation(editgroup_id, annotation, &self.context())
+ }
- fn get_work_releases(&self, ident: String, hide: Option<String>) -> Box<dyn Future<Item = GetWorkReleasesResponse, Error = ApiError> + Send>;
+ fn create_file(
+ &self,
+ editgroup_id: String,
+ entity: models::FileEntity,
+ ) -> Box<dyn Future<Item = CreateFileResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_file(editgroup_id, entity, &self.context())
+ }
- fn get_work_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetWorkRevisionResponse, Error = ApiError> + Send>;
+ fn create_file_auto_batch(
+ &self,
+ auto_batch: models::FileAutoBatch,
+ ) -> Box<dyn Future<Item = CreateFileAutoBatchResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_file_auto_batch(auto_batch, &self.context())
+ }
- fn update_work(&self, editgroup_id: String, ident: String, entity: models::WorkEntity) -> Box<dyn Future<Item = UpdateWorkResponse, Error = ApiError> + Send>;
-}
+ fn create_fileset(
+ &self,
+ editgroup_id: String,
+ entity: models::FilesetEntity,
+ ) -> Box<dyn Future<Item = CreateFilesetResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_fileset(editgroup_id, entity, &self.context())
+ }
-/// Trait to extend an API to make it easy to bind it to a context.
-pub trait ContextWrapperExt<'a>
-where
- Self: Sized,
-{
- /// Binds this API to a context.
- fn with_context(self: &'a Self, context: Context) -> ContextWrapper<'a, Self>;
-}
+ fn create_fileset_auto_batch(
+ &self,
+ auto_batch: models::FilesetAutoBatch,
+ ) -> Box<dyn Future<Item = CreateFilesetAutoBatchResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_fileset_auto_batch(auto_batch, &self.context())
+ }
-impl<'a, T: Api + Sized> ContextWrapperExt<'a> for T {
- fn with_context(self: &'a T, context: Context) -> ContextWrapper<'a, T> {
- ContextWrapper::<T>::new(self, context)
+ fn create_release(
+ &self,
+ editgroup_id: String,
+ entity: models::ReleaseEntity,
+ ) -> Box<dyn Future<Item = CreateReleaseResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_release(editgroup_id, entity, &self.context())
}
-}
-impl<'a, T: Api> ApiNoContext for ContextWrapper<'a, T> {
- fn auth_check(&self, role: Option<String>) -> Box<dyn Future<Item = AuthCheckResponse, Error = ApiError> + Send> {
- self.api().auth_check(role, &self.context())
+ fn create_release_auto_batch(
+ &self,
+ auto_batch: models::ReleaseAutoBatch,
+ ) -> Box<dyn Future<Item = CreateReleaseAutoBatchResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_release_auto_batch(auto_batch, &self.context())
}
- fn auth_oidc(&self, oidc_params: models::AuthOidc) -> Box<dyn Future<Item = AuthOidcResponse, Error = ApiError> + Send> {
- self.api().auth_oidc(oidc_params, &self.context())
+ fn create_webcapture(
+ &self,
+ editgroup_id: String,
+ entity: models::WebcaptureEntity,
+ ) -> Box<dyn Future<Item = CreateWebcaptureResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_webcapture(editgroup_id, entity, &self.context())
}
- fn create_auth_token(&self, editor_id: String, duration_seconds: Option<i32>) -> Box<dyn Future<Item = CreateAuthTokenResponse, Error = ApiError> + Send> {
- self.api().create_auth_token(editor_id, duration_seconds, &self.context())
+ fn create_webcapture_auto_batch(
+ &self,
+ auto_batch: models::WebcaptureAutoBatch,
+ ) -> Box<dyn Future<Item = CreateWebcaptureAutoBatchResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_webcapture_auto_batch(auto_batch, &self.context())
}
- fn get_changelog(&self, limit: Option<i64>) -> Box<dyn Future<Item = GetChangelogResponse, Error = ApiError> + Send> {
- self.api().get_changelog(limit, &self.context())
+ fn create_work(
+ &self,
+ editgroup_id: String,
+ entity: models::WorkEntity,
+ ) -> Box<dyn Future<Item = CreateWorkResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_work(editgroup_id, entity, &self.context())
}
- fn get_changelog_entry(&self, index: i64) -> Box<dyn Future<Item = GetChangelogEntryResponse, Error = ApiError> + Send> {
- self.api().get_changelog_entry(index, &self.context())
+ fn create_work_auto_batch(
+ &self,
+ auto_batch: models::WorkAutoBatch,
+ ) -> Box<dyn Future<Item = CreateWorkAutoBatchResponse, Error = ApiError> + Send> {
+ self.api()
+ .create_work_auto_batch(auto_batch, &self.context())
}
- fn create_container(&self, editgroup_id: String, entity: models::ContainerEntity) -> Box<dyn Future<Item = CreateContainerResponse, Error = ApiError> + Send> {
- self.api().create_container(editgroup_id, entity, &self.context())
+ fn delete_container(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteContainerResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_container(editgroup_id, ident, &self.context())
}
- fn create_container_auto_batch(&self, auto_batch: models::ContainerAutoBatch) -> Box<dyn Future<Item = CreateContainerAutoBatchResponse, Error = ApiError> + Send> {
- self.api().create_container_auto_batch(auto_batch, &self.context())
+ fn delete_container_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteContainerEditResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_container_edit(editgroup_id, edit_id, &self.context())
}
- fn delete_container(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteContainerResponse, Error = ApiError> + Send> {
- self.api().delete_container(editgroup_id, ident, &self.context())
+ fn delete_creator(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteCreatorResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_creator(editgroup_id, ident, &self.context())
}
- fn delete_container_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteContainerEditResponse, Error = ApiError> + Send> {
- self.api().delete_container_edit(editgroup_id, edit_id, &self.context())
+ fn delete_creator_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteCreatorEditResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_creator_edit(editgroup_id, edit_id, &self.context())
}
- fn get_container(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetContainerResponse, Error = ApiError> + Send> {
- self.api().get_container(ident, expand, hide, &self.context())
+ fn delete_file(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteFileResponse, Error = ApiError> + Send> {
+ self.api().delete_file(editgroup_id, ident, &self.context())
}
- fn get_container_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetContainerEditResponse, Error = ApiError> + Send> {
- self.api().get_container_edit(edit_id, &self.context())
+ fn delete_file_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteFileEditResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_file_edit(editgroup_id, edit_id, &self.context())
}
- fn get_container_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetContainerHistoryResponse, Error = ApiError> + Send> {
- self.api().get_container_history(ident, limit, &self.context())
+ fn delete_fileset(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteFilesetResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_fileset(editgroup_id, ident, &self.context())
}
- fn get_container_redirects(&self, ident: String) -> Box<dyn Future<Item = GetContainerRedirectsResponse, Error = ApiError> + Send> {
- self.api().get_container_redirects(ident, &self.context())
+ fn delete_fileset_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteFilesetEditResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_fileset_edit(editgroup_id, edit_id, &self.context())
}
- fn get_container_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetContainerRevisionResponse, Error = ApiError> + Send> {
- self.api().get_container_revision(rev_id, expand, hide, &self.context())
+ fn delete_release(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteReleaseResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_release(editgroup_id, ident, &self.context())
}
- fn lookup_container(
+ fn delete_release_edit(
&self,
- issnl: Option<String>,
- wikidata_qid: Option<String>,
- expand: Option<String>,
- hide: Option<String>,
- ) -> Box<dyn Future<Item = LookupContainerResponse, Error = ApiError> + Send> {
- self.api().lookup_container(issnl, wikidata_qid, expand, hide, &self.context())
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteReleaseEditResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_release_edit(editgroup_id, edit_id, &self.context())
}
- fn update_container(&self, editgroup_id: String, ident: String, entity: models::ContainerEntity) -> Box<dyn Future<Item = UpdateContainerResponse, Error = ApiError> + Send> {
- self.api().update_container(editgroup_id, ident, entity, &self.context())
+ fn delete_webcapture(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteWebcaptureResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_webcapture(editgroup_id, ident, &self.context())
}
- fn create_creator(&self, editgroup_id: String, entity: models::CreatorEntity) -> Box<dyn Future<Item = CreateCreatorResponse, Error = ApiError> + Send> {
- self.api().create_creator(editgroup_id, entity, &self.context())
+ fn delete_webcapture_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteWebcaptureEditResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_webcapture_edit(editgroup_id, edit_id, &self.context())
}
- fn create_creator_auto_batch(&self, auto_batch: models::CreatorAutoBatch) -> Box<dyn Future<Item = CreateCreatorAutoBatchResponse, Error = ApiError> + Send> {
- self.api().create_creator_auto_batch(auto_batch, &self.context())
+ fn delete_work(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ ) -> Box<dyn Future<Item = DeleteWorkResponse, Error = ApiError> + Send> {
+ self.api().delete_work(editgroup_id, ident, &self.context())
}
- fn delete_creator(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteCreatorResponse, Error = ApiError> + Send> {
- self.api().delete_creator(editgroup_id, ident, &self.context())
+ fn delete_work_edit(
+ &self,
+ editgroup_id: String,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = DeleteWorkEditResponse, Error = ApiError> + Send> {
+ self.api()
+ .delete_work_edit(editgroup_id, edit_id, &self.context())
}
- fn delete_creator_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteCreatorEditResponse, Error = ApiError> + Send> {
- self.api().delete_creator_edit(editgroup_id, edit_id, &self.context())
+ fn get_changelog(
+ &self,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetChangelogResponse, Error = ApiError> + Send> {
+ self.api().get_changelog(limit, &self.context())
}
- fn get_creator(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetCreatorResponse, Error = ApiError> + Send> {
- self.api().get_creator(ident, expand, hide, &self.context())
+ fn get_changelog_entry(
+ &self,
+ index: i64,
+ ) -> Box<dyn Future<Item = GetChangelogEntryResponse, Error = ApiError> + Send> {
+ self.api().get_changelog_entry(index, &self.context())
}
- fn get_creator_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetCreatorEditResponse, Error = ApiError> + Send> {
- self.api().get_creator_edit(edit_id, &self.context())
+ fn get_container(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetContainerResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_container(ident, expand, hide, &self.context())
}
- fn get_creator_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetCreatorHistoryResponse, Error = ApiError> + Send> {
- self.api().get_creator_history(ident, limit, &self.context())
+ fn get_container_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetContainerEditResponse, Error = ApiError> + Send> {
+ self.api().get_container_edit(edit_id, &self.context())
}
- fn get_creator_redirects(&self, ident: String) -> Box<dyn Future<Item = GetCreatorRedirectsResponse, Error = ApiError> + Send> {
- self.api().get_creator_redirects(ident, &self.context())
+ fn get_container_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetContainerHistoryResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_container_history(ident, limit, &self.context())
}
- fn get_creator_releases(&self, ident: String, hide: Option<String>) -> Box<dyn Future<Item = GetCreatorReleasesResponse, Error = ApiError> + Send> {
- self.api().get_creator_releases(ident, hide, &self.context())
+ fn get_container_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetContainerRedirectsResponse, Error = ApiError> + Send> {
+ self.api().get_container_redirects(ident, &self.context())
}
- fn get_creator_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetCreatorRevisionResponse, Error = ApiError> + Send> {
- self.api().get_creator_revision(rev_id, expand, hide, &self.context())
+ fn get_container_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetContainerRevisionResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_container_revision(rev_id, expand, hide, &self.context())
}
- fn lookup_creator(
+ fn get_creator(
&self,
- orcid: Option<String>,
- wikidata_qid: Option<String>,
+ ident: String,
expand: Option<String>,
hide: Option<String>,
- ) -> Box<dyn Future<Item = LookupCreatorResponse, Error = ApiError> + Send> {
- self.api().lookup_creator(orcid, wikidata_qid, expand, hide, &self.context())
+ ) -> Box<dyn Future<Item = GetCreatorResponse, Error = ApiError> + Send> {
+ self.api().get_creator(ident, expand, hide, &self.context())
}
- fn update_creator(&self, editgroup_id: String, ident: String, entity: models::CreatorEntity) -> Box<dyn Future<Item = UpdateCreatorResponse, Error = ApiError> + Send> {
- self.api().update_creator(editgroup_id, ident, entity, &self.context())
+ fn get_creator_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetCreatorEditResponse, Error = ApiError> + Send> {
+ self.api().get_creator_edit(edit_id, &self.context())
}
- fn accept_editgroup(&self, editgroup_id: String) -> Box<dyn Future<Item = AcceptEditgroupResponse, Error = ApiError> + Send> {
- self.api().accept_editgroup(editgroup_id, &self.context())
+ fn get_creator_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetCreatorHistoryResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_creator_history(ident, limit, &self.context())
}
- fn create_editgroup(&self, editgroup: models::Editgroup) -> Box<dyn Future<Item = CreateEditgroupResponse, Error = ApiError> + Send> {
- self.api().create_editgroup(editgroup, &self.context())
+ fn get_creator_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetCreatorRedirectsResponse, Error = ApiError> + Send> {
+ self.api().get_creator_redirects(ident, &self.context())
}
- fn create_editgroup_annotation(&self, editgroup_id: String, annotation: models::EditgroupAnnotation) -> Box<dyn Future<Item = CreateEditgroupAnnotationResponse, Error = ApiError> + Send> {
- self.api().create_editgroup_annotation(editgroup_id, annotation, &self.context())
+ fn get_creator_releases(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetCreatorReleasesResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_creator_releases(ident, hide, &self.context())
}
- fn get_editgroup(&self, editgroup_id: String) -> Box<dyn Future<Item = GetEditgroupResponse, Error = ApiError> + Send> {
+ fn get_creator_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetCreatorRevisionResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_creator_revision(rev_id, expand, hide, &self.context())
+ }
+
+ fn get_editgroup(
+ &self,
+ editgroup_id: String,
+ ) -> Box<dyn Future<Item = GetEditgroupResponse, Error = ApiError> + Send> {
self.api().get_editgroup(editgroup_id, &self.context())
}
- fn get_editgroup_annotations(&self, editgroup_id: String, expand: Option<String>) -> Box<dyn Future<Item = GetEditgroupAnnotationsResponse, Error = ApiError> + Send> {
- self.api().get_editgroup_annotations(editgroup_id, expand, &self.context())
+ fn get_editgroup_annotations(
+ &self,
+ editgroup_id: String,
+ expand: Option<String>,
+ ) -> Box<dyn Future<Item = GetEditgroupAnnotationsResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_editgroup_annotations(editgroup_id, expand, &self.context())
}
fn get_editgroups_reviewable(
@@ -2024,14 +3276,14 @@ impl<'a, T: Api> ApiNoContext for ContextWrapper<'a, T> {
before: Option<chrono::DateTime<chrono::Utc>>,
since: Option<chrono::DateTime<chrono::Utc>>,
) -> Box<dyn Future<Item = GetEditgroupsReviewableResponse, Error = ApiError> + Send> {
- self.api().get_editgroups_reviewable(expand, limit, before, since, &self.context())
- }
-
- fn update_editgroup(&self, editgroup_id: String, editgroup: models::Editgroup, submit: Option<bool>) -> Box<dyn Future<Item = UpdateEditgroupResponse, Error = ApiError> + Send> {
- self.api().update_editgroup(editgroup_id, editgroup, submit, &self.context())
+ self.api()
+ .get_editgroups_reviewable(expand, limit, before, since, &self.context())
}
- fn get_editor(&self, editor_id: String) -> Box<dyn Future<Item = GetEditorResponse, Error = ApiError> + Send> {
+ fn get_editor(
+ &self,
+ editor_id: String,
+ ) -> Box<dyn Future<Item = GetEditorResponse, Error = ApiError> + Send> {
self.api().get_editor(editor_id, &self.context())
}
@@ -2042,7 +3294,8 @@ impl<'a, T: Api> ApiNoContext for ContextWrapper<'a, T> {
before: Option<chrono::DateTime<chrono::Utc>>,
since: Option<chrono::DateTime<chrono::Utc>>,
) -> Box<dyn Future<Item = GetEditorAnnotationsResponse, Error = ApiError> + Send> {
- self.api().get_editor_annotations(editor_id, limit, before, since, &self.context())
+ self.api()
+ .get_editor_annotations(editor_id, limit, before, since, &self.context())
}
fn get_editor_editgroups(
@@ -2052,150 +3305,285 @@ impl<'a, T: Api> ApiNoContext for ContextWrapper<'a, T> {
before: Option<chrono::DateTime<chrono::Utc>>,
since: Option<chrono::DateTime<chrono::Utc>>,
) -> Box<dyn Future<Item = GetEditorEditgroupsResponse, Error = ApiError> + Send> {
- self.api().get_editor_editgroups(editor_id, limit, before, since, &self.context())
- }
-
- fn update_editor(&self, editor_id: String, editor: models::Editor) -> Box<dyn Future<Item = UpdateEditorResponse, Error = ApiError> + Send> {
- self.api().update_editor(editor_id, editor, &self.context())
+ self.api()
+ .get_editor_editgroups(editor_id, limit, before, since, &self.context())
}
- fn create_file(&self, editgroup_id: String, entity: models::FileEntity) -> Box<dyn Future<Item = CreateFileResponse, Error = ApiError> + Send> {
- self.api().create_file(editgroup_id, entity, &self.context())
+ fn get_file(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetFileResponse, Error = ApiError> + Send> {
+ self.api().get_file(ident, expand, hide, &self.context())
}
- fn create_file_auto_batch(&self, auto_batch: models::FileAutoBatch) -> Box<dyn Future<Item = CreateFileAutoBatchResponse, Error = ApiError> + Send> {
- self.api().create_file_auto_batch(auto_batch, &self.context())
+ fn get_file_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetFileEditResponse, Error = ApiError> + Send> {
+ self.api().get_file_edit(edit_id, &self.context())
}
- fn delete_file(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteFileResponse, Error = ApiError> + Send> {
- self.api().delete_file(editgroup_id, ident, &self.context())
+ fn get_file_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetFileHistoryResponse, Error = ApiError> + Send> {
+ self.api().get_file_history(ident, limit, &self.context())
}
- fn delete_file_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteFileEditResponse, Error = ApiError> + Send> {
- self.api().delete_file_edit(editgroup_id, edit_id, &self.context())
+ fn get_file_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetFileRedirectsResponse, Error = ApiError> + Send> {
+ self.api().get_file_redirects(ident, &self.context())
}
- fn get_file(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetFileResponse, Error = ApiError> + Send> {
- self.api().get_file(ident, expand, hide, &self.context())
+ fn get_file_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetFileRevisionResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_file_revision(rev_id, expand, hide, &self.context())
}
- fn get_file_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetFileEditResponse, Error = ApiError> + Send> {
- self.api().get_file_edit(edit_id, &self.context())
+ fn get_fileset(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetFilesetResponse, Error = ApiError> + Send> {
+ self.api().get_fileset(ident, expand, hide, &self.context())
}
- fn get_file_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetFileHistoryResponse, Error = ApiError> + Send> {
- self.api().get_file_history(ident, limit, &self.context())
+ fn get_fileset_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetFilesetEditResponse, Error = ApiError> + Send> {
+ self.api().get_fileset_edit(edit_id, &self.context())
}
- fn get_file_redirects(&self, ident: String) -> Box<dyn Future<Item = GetFileRedirectsResponse, Error = ApiError> + Send> {
- self.api().get_file_redirects(ident, &self.context())
+ fn get_fileset_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetFilesetHistoryResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_fileset_history(ident, limit, &self.context())
}
- fn get_file_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetFileRevisionResponse, Error = ApiError> + Send> {
- self.api().get_file_revision(rev_id, expand, hide, &self.context())
+ fn get_fileset_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetFilesetRedirectsResponse, Error = ApiError> + Send> {
+ self.api().get_fileset_redirects(ident, &self.context())
}
- fn lookup_file(
+ fn get_fileset_revision(
&self,
- md5: Option<String>,
- sha1: Option<String>,
- sha256: Option<String>,
+ rev_id: String,
expand: Option<String>,
hide: Option<String>,
- ) -> Box<dyn Future<Item = LookupFileResponse, Error = ApiError> + Send> {
- self.api().lookup_file(md5, sha1, sha256, expand, hide, &self.context())
- }
-
- fn update_file(&self, editgroup_id: String, ident: String, entity: models::FileEntity) -> Box<dyn Future<Item = UpdateFileResponse, Error = ApiError> + Send> {
- self.api().update_file(editgroup_id, ident, entity, &self.context())
+ ) -> Box<dyn Future<Item = GetFilesetRevisionResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_fileset_revision(rev_id, expand, hide, &self.context())
}
- fn create_fileset(&self, editgroup_id: String, entity: models::FilesetEntity) -> Box<dyn Future<Item = CreateFilesetResponse, Error = ApiError> + Send> {
- self.api().create_fileset(editgroup_id, entity, &self.context())
+ fn get_release(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetReleaseResponse, Error = ApiError> + Send> {
+ self.api().get_release(ident, expand, hide, &self.context())
}
- fn create_fileset_auto_batch(&self, auto_batch: models::FilesetAutoBatch) -> Box<dyn Future<Item = CreateFilesetAutoBatchResponse, Error = ApiError> + Send> {
- self.api().create_fileset_auto_batch(auto_batch, &self.context())
+ fn get_release_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetReleaseEditResponse, Error = ApiError> + Send> {
+ self.api().get_release_edit(edit_id, &self.context())
}
- fn delete_fileset(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteFilesetResponse, Error = ApiError> + Send> {
- self.api().delete_fileset(editgroup_id, ident, &self.context())
+ fn get_release_files(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetReleaseFilesResponse, Error = ApiError> + Send> {
+ self.api().get_release_files(ident, hide, &self.context())
}
- fn delete_fileset_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteFilesetEditResponse, Error = ApiError> + Send> {
- self.api().delete_fileset_edit(editgroup_id, edit_id, &self.context())
+ fn get_release_filesets(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetReleaseFilesetsResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_release_filesets(ident, hide, &self.context())
}
- fn get_fileset(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetFilesetResponse, Error = ApiError> + Send> {
- self.api().get_fileset(ident, expand, hide, &self.context())
+ fn get_release_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetReleaseHistoryResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_release_history(ident, limit, &self.context())
}
- fn get_fileset_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetFilesetEditResponse, Error = ApiError> + Send> {
- self.api().get_fileset_edit(edit_id, &self.context())
+ fn get_release_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetReleaseRedirectsResponse, Error = ApiError> + Send> {
+ self.api().get_release_redirects(ident, &self.context())
}
- fn get_fileset_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetFilesetHistoryResponse, Error = ApiError> + Send> {
- self.api().get_fileset_history(ident, limit, &self.context())
+ fn get_release_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetReleaseRevisionResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_release_revision(rev_id, expand, hide, &self.context())
}
- fn get_fileset_redirects(&self, ident: String) -> Box<dyn Future<Item = GetFilesetRedirectsResponse, Error = ApiError> + Send> {
- self.api().get_fileset_redirects(ident, &self.context())
+ fn get_release_webcaptures(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetReleaseWebcapturesResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_release_webcaptures(ident, hide, &self.context())
}
- fn get_fileset_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetFilesetRevisionResponse, Error = ApiError> + Send> {
- self.api().get_fileset_revision(rev_id, expand, hide, &self.context())
+ fn get_webcapture(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetWebcaptureResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_webcapture(ident, expand, hide, &self.context())
}
- fn update_fileset(&self, editgroup_id: String, ident: String, entity: models::FilesetEntity) -> Box<dyn Future<Item = UpdateFilesetResponse, Error = ApiError> + Send> {
- self.api().update_fileset(editgroup_id, ident, entity, &self.context())
+ fn get_webcapture_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetWebcaptureEditResponse, Error = ApiError> + Send> {
+ self.api().get_webcapture_edit(edit_id, &self.context())
}
- fn create_release(&self, editgroup_id: String, entity: models::ReleaseEntity) -> Box<dyn Future<Item = CreateReleaseResponse, Error = ApiError> + Send> {
- self.api().create_release(editgroup_id, entity, &self.context())
+ fn get_webcapture_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetWebcaptureHistoryResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_webcapture_history(ident, limit, &self.context())
}
- fn create_release_auto_batch(&self, auto_batch: models::ReleaseAutoBatch) -> Box<dyn Future<Item = CreateReleaseAutoBatchResponse, Error = ApiError> + Send> {
- self.api().create_release_auto_batch(auto_batch, &self.context())
+ fn get_webcapture_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetWebcaptureRedirectsResponse, Error = ApiError> + Send> {
+ self.api().get_webcapture_redirects(ident, &self.context())
}
- fn delete_release(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteReleaseResponse, Error = ApiError> + Send> {
- self.api().delete_release(editgroup_id, ident, &self.context())
+ fn get_webcapture_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetWebcaptureRevisionResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_webcapture_revision(rev_id, expand, hide, &self.context())
}
- fn delete_release_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteReleaseEditResponse, Error = ApiError> + Send> {
- self.api().delete_release_edit(editgroup_id, edit_id, &self.context())
+ fn get_work(
+ &self,
+ ident: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetWorkResponse, Error = ApiError> + Send> {
+ self.api().get_work(ident, expand, hide, &self.context())
}
- fn get_release(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetReleaseResponse, Error = ApiError> + Send> {
- self.api().get_release(ident, expand, hide, &self.context())
+ fn get_work_edit(
+ &self,
+ edit_id: String,
+ ) -> Box<dyn Future<Item = GetWorkEditResponse, Error = ApiError> + Send> {
+ self.api().get_work_edit(edit_id, &self.context())
}
- fn get_release_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetReleaseEditResponse, Error = ApiError> + Send> {
- self.api().get_release_edit(edit_id, &self.context())
+ fn get_work_history(
+ &self,
+ ident: String,
+ limit: Option<i64>,
+ ) -> Box<dyn Future<Item = GetWorkHistoryResponse, Error = ApiError> + Send> {
+ self.api().get_work_history(ident, limit, &self.context())
}
- fn get_release_files(&self, ident: String, hide: Option<String>) -> Box<dyn Future<Item = GetReleaseFilesResponse, Error = ApiError> + Send> {
- self.api().get_release_files(ident, hide, &self.context())
+ fn get_work_redirects(
+ &self,
+ ident: String,
+ ) -> Box<dyn Future<Item = GetWorkRedirectsResponse, Error = ApiError> + Send> {
+ self.api().get_work_redirects(ident, &self.context())
}
- fn get_release_filesets(&self, ident: String, hide: Option<String>) -> Box<dyn Future<Item = GetReleaseFilesetsResponse, Error = ApiError> + Send> {
- self.api().get_release_filesets(ident, hide, &self.context())
+ fn get_work_releases(
+ &self,
+ ident: String,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetWorkReleasesResponse, Error = ApiError> + Send> {
+ self.api().get_work_releases(ident, hide, &self.context())
}
- fn get_release_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetReleaseHistoryResponse, Error = ApiError> + Send> {
- self.api().get_release_history(ident, limit, &self.context())
+ fn get_work_revision(
+ &self,
+ rev_id: String,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = GetWorkRevisionResponse, Error = ApiError> + Send> {
+ self.api()
+ .get_work_revision(rev_id, expand, hide, &self.context())
}
- fn get_release_redirects(&self, ident: String) -> Box<dyn Future<Item = GetReleaseRedirectsResponse, Error = ApiError> + Send> {
- self.api().get_release_redirects(ident, &self.context())
+ fn lookup_container(
+ &self,
+ issnl: Option<String>,
+ wikidata_qid: Option<String>,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = LookupContainerResponse, Error = ApiError> + Send> {
+ self.api()
+ .lookup_container(issnl, wikidata_qid, expand, hide, &self.context())
}
- fn get_release_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetReleaseRevisionResponse, Error = ApiError> + Send> {
- self.api().get_release_revision(rev_id, expand, hide, &self.context())
+ fn lookup_creator(
+ &self,
+ orcid: Option<String>,
+ wikidata_qid: Option<String>,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = LookupCreatorResponse, Error = ApiError> + Send> {
+ self.api()
+ .lookup_creator(orcid, wikidata_qid, expand, hide, &self.context())
}
- fn get_release_webcaptures(&self, ident: String, hide: Option<String>) -> Box<dyn Future<Item = GetReleaseWebcapturesResponse, Error = ApiError> + Send> {
- self.api().get_release_webcaptures(ident, hide, &self.context())
+ fn lookup_file(
+ &self,
+ md5: Option<String>,
+ sha1: Option<String>,
+ sha256: Option<String>,
+ expand: Option<String>,
+ hide: Option<String>,
+ ) -> Box<dyn Future<Item = LookupFileResponse, Error = ApiError> + Send> {
+ self.api()
+ .lookup_file(md5, sha1, sha256, expand, hide, &self.context())
}
fn lookup_release(
@@ -2213,96 +3601,109 @@ impl<'a, T: Api> ApiNoContext for ContextWrapper<'a, T> {
expand: Option<String>,
hide: Option<String>,
) -> Box<dyn Future<Item = LookupReleaseResponse, Error = ApiError> + Send> {
+ self.api().lookup_release(
+ doi,
+ wikidata_qid,
+ isbn13,
+ pmid,
+ pmcid,
+ core,
+ arxiv,
+ jstor,
+ ark,
+ mag,
+ expand,
+ hide,
+ &self.context(),
+ )
+ }
+
+ fn update_container(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::ContainerEntity,
+ ) -> Box<dyn Future<Item = UpdateContainerResponse, Error = ApiError> + Send> {
self.api()
- .lookup_release(doi, wikidata_qid, isbn13, pmid, pmcid, core, arxiv, jstor, ark, mag, expand, hide, &self.context())
- }
-
- fn update_release(&self, editgroup_id: String, ident: String, entity: models::ReleaseEntity) -> Box<dyn Future<Item = UpdateReleaseResponse, Error = ApiError> + Send> {
- self.api().update_release(editgroup_id, ident, entity, &self.context())
- }
-
- fn create_webcapture(&self, editgroup_id: String, entity: models::WebcaptureEntity) -> Box<dyn Future<Item = CreateWebcaptureResponse, Error = ApiError> + Send> {
- self.api().create_webcapture(editgroup_id, entity, &self.context())
+ .update_container(editgroup_id, ident, entity, &self.context())
}
- fn create_webcapture_auto_batch(&self, auto_batch: models::WebcaptureAutoBatch) -> Box<dyn Future<Item = CreateWebcaptureAutoBatchResponse, Error = ApiError> + Send> {
- self.api().create_webcapture_auto_batch(auto_batch, &self.context())
- }
-
- fn delete_webcapture(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteWebcaptureResponse, Error = ApiError> + Send> {
- self.api().delete_webcapture(editgroup_id, ident, &self.context())
- }
-
- fn delete_webcapture_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteWebcaptureEditResponse, Error = ApiError> + Send> {
- self.api().delete_webcapture_edit(editgroup_id, edit_id, &self.context())
- }
-
- fn get_webcapture(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetWebcaptureResponse, Error = ApiError> + Send> {
- self.api().get_webcapture(ident, expand, hide, &self.context())
- }
-
- fn get_webcapture_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetWebcaptureEditResponse, Error = ApiError> + Send> {
- self.api().get_webcapture_edit(edit_id, &self.context())
- }
-
- fn get_webcapture_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetWebcaptureHistoryResponse, Error = ApiError> + Send> {
- self.api().get_webcapture_history(ident, limit, &self.context())
- }
-
- fn get_webcapture_redirects(&self, ident: String) -> Box<dyn Future<Item = GetWebcaptureRedirectsResponse, Error = ApiError> + Send> {
- self.api().get_webcapture_redirects(ident, &self.context())
- }
-
- fn get_webcapture_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetWebcaptureRevisionResponse, Error = ApiError> + Send> {
- self.api().get_webcapture_revision(rev_id, expand, hide, &self.context())
- }
-
- fn update_webcapture(&self, editgroup_id: String, ident: String, entity: models::WebcaptureEntity) -> Box<dyn Future<Item = UpdateWebcaptureResponse, Error = ApiError> + Send> {
- self.api().update_webcapture(editgroup_id, ident, entity, &self.context())
- }
-
- fn create_work(&self, editgroup_id: String, entity: models::WorkEntity) -> Box<dyn Future<Item = CreateWorkResponse, Error = ApiError> + Send> {
- self.api().create_work(editgroup_id, entity, &self.context())
- }
-
- fn create_work_auto_batch(&self, auto_batch: models::WorkAutoBatch) -> Box<dyn Future<Item = CreateWorkAutoBatchResponse, Error = ApiError> + Send> {
- self.api().create_work_auto_batch(auto_batch, &self.context())
- }
-
- fn delete_work(&self, editgroup_id: String, ident: String) -> Box<dyn Future<Item = DeleteWorkResponse, Error = ApiError> + Send> {
- self.api().delete_work(editgroup_id, ident, &self.context())
- }
-
- fn delete_work_edit(&self, editgroup_id: String, edit_id: String) -> Box<dyn Future<Item = DeleteWorkEditResponse, Error = ApiError> + Send> {
- self.api().delete_work_edit(editgroup_id, edit_id, &self.context())
+ fn update_creator(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::CreatorEntity,
+ ) -> Box<dyn Future<Item = UpdateCreatorResponse, Error = ApiError> + Send> {
+ self.api()
+ .update_creator(editgroup_id, ident, entity, &self.context())
}
- fn get_work(&self, ident: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetWorkResponse, Error = ApiError> + Send> {
- self.api().get_work(ident, expand, hide, &self.context())
+ fn update_editgroup(
+ &self,
+ editgroup_id: String,
+ editgroup: models::Editgroup,
+ submit: Option<bool>,
+ ) -> Box<dyn Future<Item = UpdateEditgroupResponse, Error = ApiError> + Send> {
+ self.api()
+ .update_editgroup(editgroup_id, editgroup, submit, &self.context())
}
- fn get_work_edit(&self, edit_id: String) -> Box<dyn Future<Item = GetWorkEditResponse, Error = ApiError> + Send> {
- self.api().get_work_edit(edit_id, &self.context())
+ fn update_editor(
+ &self,
+ editor_id: String,
+ editor: models::Editor,
+ ) -> Box<dyn Future<Item = UpdateEditorResponse, Error = ApiError> + Send> {
+ self.api().update_editor(editor_id, editor, &self.context())
}
- fn get_work_history(&self, ident: String, limit: Option<i64>) -> Box<dyn Future<Item = GetWorkHistoryResponse, Error = ApiError> + Send> {
- self.api().get_work_history(ident, limit, &self.context())
+ fn update_file(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::FileEntity,
+ ) -> Box<dyn Future<Item = UpdateFileResponse, Error = ApiError> + Send> {
+ self.api()
+ .update_file(editgroup_id, ident, entity, &self.context())
}
- fn get_work_redirects(&self, ident: String) -> Box<dyn Future<Item = GetWorkRedirectsResponse, Error = ApiError> + Send> {
- self.api().get_work_redirects(ident, &self.context())
+ fn update_fileset(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::FilesetEntity,
+ ) -> Box<dyn Future<Item = UpdateFilesetResponse, Error = ApiError> + Send> {
+ self.api()
+ .update_fileset(editgroup_id, ident, entity, &self.context())
}
- fn get_work_releases(&self, ident: String, hide: Option<String>) -> Box<dyn Future<Item = GetWorkReleasesResponse, Error = ApiError> + Send> {
- self.api().get_work_releases(ident, hide, &self.context())
+ fn update_release(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::ReleaseEntity,
+ ) -> Box<dyn Future<Item = UpdateReleaseResponse, Error = ApiError> + Send> {
+ self.api()
+ .update_release(editgroup_id, ident, entity, &self.context())
}
- fn get_work_revision(&self, rev_id: String, expand: Option<String>, hide: Option<String>) -> Box<dyn Future<Item = GetWorkRevisionResponse, Error = ApiError> + Send> {
- self.api().get_work_revision(rev_id, expand, hide, &self.context())
+ fn update_webcapture(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::WebcaptureEntity,
+ ) -> Box<dyn Future<Item = UpdateWebcaptureResponse, Error = ApiError> + Send> {
+ self.api()
+ .update_webcapture(editgroup_id, ident, entity, &self.context())
}
- fn update_work(&self, editgroup_id: String, ident: String, entity: models::WorkEntity) -> Box<dyn Future<Item = UpdateWorkResponse, Error = ApiError> + Send> {
- self.api().update_work(editgroup_id, ident, entity, &self.context())
+ fn update_work(
+ &self,
+ editgroup_id: String,
+ ident: String,
+ entity: models::WorkEntity,
+ ) -> Box<dyn Future<Item = UpdateWorkResponse, Error = ApiError> + Send> {
+ self.api()
+ .update_work(editgroup_id, ident, entity, &self.context())
}
}
@@ -2311,13 +3712,19 @@ pub mod client;
// Re-export Client as a top-level name
#[cfg(feature = "client")]
-pub use self::client::Client;
+pub use client::Client;
#[cfg(feature = "server")]
pub mod server;
// Re-export router() as a top-level name
#[cfg(feature = "server")]
-pub use self::server::router;
+pub use self::server::Service;
+
+#[cfg(feature = "server")]
+pub mod context;
pub mod models;
+
+#[cfg(any(feature = "client", feature = "server"))]
+pub(crate) mod header;