iCAN Docs
icantool.appGithub
  • iCAN
    • Background
    • Intro
    • Functions
    • Strengths
    • API
    • Architecture Diagram
    • User Manual
    • Roadmap
    • Team
  • ADDITIONAL RESOURCES
    • Github
    • Twitter
  • Doc in Chinese
Powered by GitBook
On this page
  • Background
  • Intro
  • Functions
  • Strengths
  • API
  • Types
  • iCAN Interface
  • Hub Interface
  • Architecture Diagram
  • User Manual
  • Create Management Hub
  • Management Hub Page
  • Operate On Canister
  • Roadmap
  • Team

iCAN

“The best easy-to-use Canister Management Platform on IC”

Background

  1. Currently, developers can only manage their canister by the NNS wallet and the DFX command line.

  2. The NNS wallet only displays basic information about Canister. And developers can’t easily use the NNS wallet to manage the Canisters.Only Canister id without other information makes it impossible for developers using NNS wallet to manage their canisters conveniently.

  3. Hard to manage canister status by the DFX CLI.

Intro

Easy to use UI interface to deploy and manage your CANISTERS

  1. iCAN = “I” C + “Canister”

    It is an on-chain Canister management tool built on IC.

  2. iCAN helps developers manage the Canister by a graphical interface, to create contracts, download WebAssembly modules, manage Canister indicators, etc.

Functions

  1. Detailed Management

    • Dynamic change of Canister’s Settings.

    • More convenient Canister Management.

    • Detailed description of Canister.

  2. Status Detection

    • Support top up canisters directly using ICP, and deposit Cycles to Canister directly.

    • Timely feedback on the status of Canister, so that developers can understand the current status of Canister and manage it in time.

  3. Creation and Deletion

    • Graphical Canister management Interface.

    • Be able to create & delete Canisters, and automatically reclaim Cycles.

  4. Support Import

    • Import Canisters created before to your own hub.

  5. WebAssembly Control

    • Download the latest WebAssembly.

Strengths

The iCAN Developer Platform helps developers manage Canister. The future goal is to become a comprehensive contract management platform on IC.

  1. Create Management Hub in random subnet

    • By the random subnet hub, you can choose which subnet you want your canister to be created.

  2. Convenient Management

    • You can name the canisters, tag them or give them a description so that you can manage them conveniently

  3. Trustless Management

    • Hub Canister is only controlled by yourself, which supports a trustless hosting service

API

Introduce the public interface of iCAN Canister and Hub Canister

Types

    module{
    
        public type Error = {
            #Invalid_Caller;
            #Invalid_CanisterId;
            #No_Wasm;
            #No_Record;
            #Insufficient_Cycles;
            #Ledger_Transfer_Failed : Nat; // value : log id
            #Create_Canister_Failed : Nat;
        };
    
        public type Canister = {
            name : Text;
            description : Text;
            canister_id : Principal;
            wasm : ?[Nat8];
        };
    
        public type Status = {
            cycle_balance : Nat;
            memory : Nat;
        };
    
        public type UpdateSettingsArgs = {
            canister_id : Principal;
            settings : canister_settings
        };
    
        public type TransformArgs = {
            icp_amount : Nat64; // e8s
            to_canister_id : Principal
        };
    
        public type DeployArgs = {
            name : Text;
            description : Text;
            settings : ?canister_settings;
            deploy_arguments : ?[Nat8];
            wasm : ?[Nat8];
            cycle_amount : Nat;
            preserve_wasm : Bool;
        };
    
        public type canister_settings = {
            freezing_threshold : ?Nat;
            controllers : ?[Principal];
            memory_allocation : ?Nat;
            compute_allocation : ?Nat;
        };
    
    };

iCAN Interface

    // iCAN Canister Public Service Interface
    public type iCAN = actor{

        // get your own hubs' info (call this function use your identity)
        // @return array of (Hub Name, Hub Canister Id)
        getHub : query () -> async [(Text, Principal)];

        // get current hub wasm and cycle withdraw wasm in use
        // @return (hub wasm, cycle withdraw wasm)
        getWasms : query () -> async ([Nat8], [Nat8]);

        // get administrators of ican at present
        // @return array of administrators
        getAdministrators : query () -> async [Principal];

        // create canister management hub
        // @param name : hub name
        // @param amount : icp e8s amount
        createHub : (name : Text, amount : Nat64) -> async Result.Result<Principal, Error>;

        // add hub info to your hubs
        // @param name : hub name
        // @param hub_id : hub canister principal
        addHub : (name : Text, hub_id : Principal) -> async Text;

        // delete hub from your hub set
        deleteHub : (hub_id : Principal) -> async Result.Result<(), Error>;

        // transform icp to cycles and deposit the cycles to target cansiter
        transformIcp : (args : TransformArgs) -> async Result.Result<(), Error>;

    };

Hub Interface

    public type Hub = actor{

        // get current version hub canister's wasm
        // @return Wasm Version
        getVersion : query() -> async Nat;

        // get owners of this hub canister
        // @return owners array
        getOwners : query() -> async [Principal];

        // get status of hub canister ( owner only )
        getStatus : query() -> async Result.Result<Status, Error>;

        // get canisters managed by this hub ( owner only )
        getCanisters : query() -> async Result.Result<[Canister], Error>;

        // get wasm of specified canister ( owner only )
        getWasm : query (canister_id : Principal) -> async Result.Result<[Nat8], Error>;

        // put canister into hub ( not matter if not controlled by hub canister ) ( owner only )
        // @param c : should be put into hub canister
        putCanister : (c : Canister) -> async Result.Result<(), Error>;

        // deploy canister by hub canister  ( owner only )
        // @return #ok(new canister's principal) or #err(Error)
        deployCanister : (args : DeployArgs) -> async Result.Result<Principal, Error>;

        // update canister settings  ( owner only )
        updateCanisterSettings : (args : UpdateSettingsArgs) -> async Result.Result<(), Error>;

        // start the specify canister, which should be controlled by hub canister  ( owner only )
        // @param principal : target canister's principal
        startCanister : (principal : Principal) -> async Result.Result<(), Error>;

        // stop canister ( owner only )
        // @param principal : target canister's principal
        stopCanister : (principal : Principal) -> async Result.Result<(), Error>;

        // deposit cycles to target canister ( equal to top up to target canister)
        // @param id : target canister principal, cycle amount : how much cycles should be top up
        depositCycles(id : Principal, cycle_amount : Nat, ) : async Result.Result<(), Error>;

        // delete canister from hub canister and withdraw cycles from it ( owner only )
        // @param canister's principal
        delCanister : ( id : Principal ) -> async Result.Result<(), Error>;

        // install cycle wasm to hub canister ( owner only )
        // @param wasm : cycle wasm blob (you can deploy your own cycle wasm to your hub canister)
        installCycleWasm : (wasm : [Nat8]) -> async Result.Result<(), Error>;

        // change hub owner ( owner only )
        // @param : new owners array
        changeOwner : (newOwners : [Principal]) -> async Result.Result<(), Error>;

    };

Architecture Diagram

User Manual

Log in

Click the icon to log by using II (Internet Identity).

Create Management Hub

  1. Use the wallet or exchange to recharge ICP to the above address (this is an address held by Canister which can’t transfer out after recharging, please top up as needed, if you need to return the ICP, please contact us).

  2. Enter the name of the Management Hub and the number of ICP used to create the Management Hub, in addition to the fee required for transferring and creating the canister, Excess ICP will be converted into cycles and stored in the Management hub.

3.Click the “Create” button to create your canister. This process takes some time, please be patient.

Management Hub Page

Management Hub is your personal canister manager, which is a canister only controlled by yourself.

Hub Status

The status information of Hub is displayed here, including memory usage and cycles balance.

Next, all operation in the Management Hub, including canister creation and canister top-up, use the inner balance of cycles here. Therefore, if you don't have enough cycles, you can click the “Add cycles” button in the upper right corner to top up.

Enter the amount you want to top up, click the “Add” button, and then wait patiently for the recharge to complete (it takes a little time to convert ICP into cycles).

Create canister

1. Click the “+” button.

2. Enter the name and introduction of your canisters.

  • Init cycles balance is the initial cycles balance, with a minimum value of 0.2T.

3. Click wasm file to upload your file with the size of 2m.

  • If you need to modify the following three parameters, please click the “Advanced” button.

4. Click the “Create” button and wait for the creation to complete.

Operate On Canister

The above is an example of creating a successful canister.

Click to expand the display details, and the upper right corner can jump to icscan to view the canister.

Click the “Options” button to operate the canisters.The following four methods are provided: Install, Add cycles, Delete and Stop & Start.

Install

Add cycles

Add cycles to the canister. It uses cycles in the Management Hub.

Delete

If you want to delete this canister, click the “delete” button and then click the “Yes” button in the pop-up window. After deletion, its cycle balance will return to the Management hub (if the cycles balance is less than 0.01T, it will not be recovered.).

Stop & Start

Stop or start this canister.

Roadmap

2022Q2 MVP launch.

2022Q3 Full support for the current Canister management.

  1. Import Canisters Created Before.

  2. Support Deploy Actor Class Canister.

  3. Support Add More Administrators to Hub Canister ( Support Team Cooperation ).

  4. Open source iCAN and hand over to the community DAO.

It supports one click creation of specific types of canisters (asset canisters, NFT canisters) and uploading front-end assets.

2022Q4 Launch the Log Management Platform. Support data rollback.

2022Q4-2023 Become the best Canister management platform and developer infrastructure for IC.

Team

Mixlabs is a leading-edge technology laboratory in the blockchain direction composed of top universities and community developers in Asia. It is mainly engaged in cutting-edge technology research, incubation and ecological support in the blockchain direction.

NextBackground

Last updated 3 years ago

Click to upload the compiled wasm file. Then select "install", "reinstall" and "upgrade" mode, according to your needs. Please check for these three modes.

the official documents