IPFS (InterPlanetary File System) plugin for ElizaOS that enables decentralized file storage and retrieval.
- Add and pin files to IPFS
- Retrieve files by CID (Content Identifier)
- Read text content from IPFS
- Standalone Helia node (no external daemon required)
- Automatic content pinning
bun add @elizaos/plugin-ipfsAdd the following environment variables to your .env file:
# Optional: Directory for IPFS data storage (defaults to ./ipfs-data)
IPFS_DATA_DIR=/path/to/ipfs-data
# Optional: Enable IPFS gateway (defaults to false)
IPFS_ENABLE_GATEWAY=false
# Optional: Gateway port (defaults to 8080)
IPFS_GATEWAY_PORT=8080Add the plugin to your agent configuration:
import ipfsPlugin from '@elizaos/plugin-ipfs';
const agent = {
plugins: [ipfsPlugin],
// ... other config
};Add a file to IPFS and pin it.
Example: "Add this file to IPFS: /path/to/file.txt"
Retrieve a file from IPFS by its CID.
Example: "Get the file with CID: QmXxx..."
Read text content from IPFS.
Example: "Show me the content of QmXxx..."
MIT