Skip to content

IpfsBattery/java-ipfs-cluster-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

java-ipfs-cluster-api

A client library for the IPFS Cluster HTTP API, implemented in Java.

UNOFFICIAL AND ALPHA

This is a port of ipfs/java-ipfs-api adapted for the API exposed by ipfs/ipfs-cluster.

install

add this code to your project or make it to jar

Dependencies

This module requires ipfs-cluster to be running. It is assumed that the IPFS Cluster API is running on "127.0.0.1:9094".

Usage

To import the module:

IPFSCluster ipfsCluster = new IPFSCluster("127.0.0.1", 9094);

API

The API is currently a work-in-progress. The exposed methods are designed to be similar to ipfs-cluster-ctl provided in ipfs/ipfs-cluster.

ipfsCluster.id();
ipfsCluster.version();
ipfsCluster.pins.ls();
ipfsCluster.pins.ls(String CID);
ipfsCluster.pins.add(String CID);
ipfsCluster.pins.rm(String CID);
ipfsCluster.peers.ls();
ipfsCluster.peers.rm(String CID);
ipfsCluster.sync.sync();
ipfsCluster.sync.sync(String CID);
ipfsCluster.recover.recover();
ipfsCluster.recover.recover(String CID);
ipfsCluster.allocation.ls();
ipfsCluster.allocation(String CID);
ipfsCluster.health.graph();

The code is mostly from java-ipfs-api modified to consume the ipfs-cluster API.

About

A client library for the IPFS Cluster HTTP API, implemented in Java.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages