@shubhamrasal/groundline
Version:
Groundline GraphDB with IPFS persistence
30 lines • 999 B
TypeScript
import { ProvenanceLogEntry } from './graph-crdt.js';
import { type IPFSConfig } from './ipfs.js';
export declare class GraphIPFSManager {
private ipfsClient;
constructor(ipfsConfig?: IPFSConfig);
/**
* Initialize the IPFS client
*/
initialize(): Promise<void>;
/**
* Create a snapshot of the current graph state and upload to IPFS
* @returns CID of the uploaded snapshot
*/
snapshotToIPFS(): Promise<string>;
/**
* Load a graph snapshot from IPFS and apply it to the current graph
* @param cid Content identifier of the snapshot
*/
loadFromIPFS(cid: string): Promise<void>;
/**
* Get the current graph state with provenance information
*/
getGraphState(): {
nodes: [string, unknown][];
edges: [string, unknown][];
provenance: ProvenanceLogEntry[];
};
}
export declare function createGraphIPFSManager(config?: IPFSConfig): GraphIPFSManager;
//# sourceMappingURL=graph-ipfs.d.ts.map