Crates.io | processcube_engine_client |
lib.rs | processcube_engine_client |
version | 0.3.0 |
source | src |
created_at | 2023-11-14 11:23:21.949951 |
updated_at | 2023-11-21 10:04:16.937172 |
description | 5Minds ProcessCube® Engine client written in Rust |
homepage | |
repository | https://github.com/stefanluth/ProcessCube.Engine.Client.rs |
max_upload_size | |
id | 1034617 |
size | 107,387 |
A library and CLI tool written in Rust, to send requests to the 5Minds ProcessCube® Engine API.
This project was designed to work with the ProcessCube® Engine API provided in the Docker Image
5minds/processcube_engine:16.0.0
.
Older or newer versions might work, but support is not guaranteed.
Coverage of the available endpoints is currently rather limited.
Endpoint | Library | CLI |
---|---|---|
AnonymousSessions | ❌ | ❌ |
ApplicationInfo | ✅ | ✅ |
Correlations | ✅ | ✅ |
Cronjobs | ❌ | ❌ |
DataObjectInstances | ❌ | ❌ |
EmptyActivities | ❌ | ❌ |
Events | ✅ | ❌ |
ExternalTasks | ❌ | ❌ |
FlowNodeInstances | ✅ | ❌ |
ManualTasks | ❌ | ❌ |
Notifications | ❌ | ❌ |
ProcessDefinitions | ✅ | ✅ |
ProcessInstances | ❌ | ❌ |
ProcessModels | ✅ | ❌ |
UserMetadata | ❌ | ❌ |
UserTasks | ❌ | ❌ |
✅ Full Support - ❌ No Support - GET/POST/... Partial Support
If you just want to use the processcube_engine_client
CLI tool, you can use
cargo install processcube_engine_client
to install it. You should then be able to use it, e.g. processcube_engine_client application-info authority
When developing an application, you can use the library by adding this package to your project, i.e.
cargo add processcube_engine_client
A short usage example:
use processcube_engine_client::clients::{client_factory::ClientFactory, error::EngineError};
// Be sure to have a running ProcessCube® Engine at the given URL
const ENGINE_URL: &str = "http://localhost:10560";
const DUMMY_TOKEN: &str = "Bearer ZHVtbXlfdG9rZW4=";
#[tokio::main]
async fn main() -> Result<(), EngineError> {
let client_factory = ClientFactory::new(ENGINE_URL, DUMMY_TOKEN);
let client = client_factory.create_application_info_client();
let info = client.get_application_info().await?;
println!("{:#?}", info);
Ok(())
}
docker run -p 10560:80 5minds/processcube_engine:16.0.0
to start the 5Minds ProcessCube® EngineYou can now run cargo test
to run the tests, or cargo run --bin processcube_engine_client
to run the CLI tool.
Swagger documentation for the API can be found at http://localhost:10560/
.