Openwhisk Client Rust

Description

This project Openwhisk-client-Rust is a Rust client library to access the Openwhisk API. This Project comes with Native and Wasm Support.

Setup

Prerequisites

This Project requies latest verion of rust to be installed and configured.

Configuration

The parameters of APIHOST, NAMESPACE and AUTHTOKEN will be used to access the OpenWhisk services.

Configure your Openwhisk client by setting the whisk properties.

let wsk_properties = WskProperties::new( "<Openwhisk_Auth_Token>", "<Openwhisk_API_Host>", <insecure(Bool: for secure or insecure connection )>, "<Namespace>" );

Usage

Examples

``` let wskproperties = WskProperties::new( "", "", " ); let client = OpenwhiskClient::::new(Some(&wskproperties));

client.actions().invoke("your action name",serde_json::json!({"key":"value"}),true,true).unwrap();

```

``` let wskproperties = WskProperties::new( "", "", " ); let client = OpenwhiskClient::::new(Some(&wskproperties));

let triggers = client.triggers().list().unwrap(); ```

``` let wskproperties = WskProperties::new( "", "", " ); let client = OpenwhiskClient::::new(Some(&wskproperties)); let properties = client.rules().list().unwrap();

```

Contributions

Contributions welcome particularly for enhancement of this library and also adding new functionality which helps in seamless interaction with Openwhisk Apis in rust applications.

Follow these steps for contributing

References

Special thanks to Openwhisk-go-client for inspiring us to develop Openwhisk Client in rust

License

Licensed under Apache-2.0