summaryrefslogtreecommitdiffstats
path: root/rust/fatcat-api/examples/client.rs
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2018-06-30 17:34:22 -0700
committerBryan Newbold <bnewbold@robocracy.org>2018-06-30 17:34:22 -0700
commitf4064c19ec140987e15c64e80a3bf0c70025b31b (patch)
treee89548d5d5f350f65e9c294a34c71a2225a14099 /rust/fatcat-api/examples/client.rs
parent3ed7db573438d3620d295813a81237acb91155cb (diff)
downloadfatcat-f4064c19ec140987e15c64e80a3bf0c70025b31b.tar.gz
fatcat-f4064c19ec140987e15c64e80a3bf0c70025b31b.zip
history for container entities
Diffstat (limited to 'rust/fatcat-api/examples/client.rs')
-rw-r--r--rust/fatcat-api/examples/client.rs11
1 files changed, 9 insertions, 2 deletions
diff --git a/rust/fatcat-api/examples/client.rs b/rust/fatcat-api/examples/client.rs
index 28fac094..93b2d21d 100644
--- a/rust/fatcat-api/examples/client.rs
+++ b/rust/fatcat-api/examples/client.rs
@@ -13,8 +13,9 @@ use clap::{App, Arg};
#[allow(unused_imports)]
use fatcat::{AcceptEditgroupResponse, ApiError, ApiNoContext, ContextWrapperExt, CreateContainerBatchResponse, CreateContainerResponse, CreateCreatorBatchResponse, CreateCreatorResponse,
CreateEditgroupResponse, CreateFileBatchResponse, CreateFileResponse, CreateReleaseBatchResponse, CreateReleaseResponse, CreateWorkBatchResponse, CreateWorkResponse,
- GetContainerResponse, GetCreatorReleasesResponse, GetCreatorResponse, GetEditgroupResponse, GetEditorChangelogResponse, GetEditorResponse, GetFileResponse, GetReleaseFilesResponse,
- GetReleaseResponse, GetStatsResponse, GetWorkReleasesResponse, GetWorkResponse, LookupContainerResponse, LookupCreatorResponse, LookupFileResponse, LookupReleaseResponse};
+ GetContainerHistoryResponse, GetContainerResponse, GetCreatorReleasesResponse, GetCreatorResponse, GetEditgroupResponse, GetEditorChangelogResponse, GetEditorResponse, GetFileResponse,
+ GetReleaseFilesResponse, GetReleaseResponse, GetStatsResponse, GetWorkReleasesResponse, GetWorkResponse, LookupContainerResponse, LookupCreatorResponse, LookupFileResponse,
+ LookupReleaseResponse};
#[allow(unused_imports)]
use futures::{future, stream, Future, Stream};
@@ -31,6 +32,7 @@ fn main() {
"CreateReleaseBatch",
"CreateWorkBatch",
"GetContainer",
+ "GetContainerHistory",
"GetCreator",
"GetCreatorReleases",
"GetEditgroup",
@@ -140,6 +142,11 @@ fn main() {
println!("{:?} (X-Span-ID: {:?})", result, client.context().x_span_id.clone().unwrap_or(String::from("<none>")));
}
+ Some("GetContainerHistory") => {
+ let result = client.get_container_history("id_example".to_string(), Some(789)).wait();
+ println!("{:?} (X-Span-ID: {:?})", result, client.context().x_span_id.clone().unwrap_or(String::from("<none>")));
+ }
+
Some("GetCreator") => {
let result = client.get_creator("id_example".to_string()).wait();
println!("{:?} (X-Span-ID: {:?})", result, client.context().x_span_id.clone().unwrap_or(String::from("<none>")));