upload-dir
Uploads an entire directory of files.
Parameters
Option
Description
-n
The network to check,
testnet
or devnet
, defaults to testnet
.-t
The token to use when funding.
-w
Your private key.
--index-file
Name of the file to use as an index for manifests.
--provider-url
RPC URL to use.
Examples
Testnet
irys upload-dir ./myImages \
-t ethereum \
-w bf20......c9885307
Devnet
irys upload-dir ./myImages \
-n devnet \
-t ethereum \
-w bf20......c9885307 \
--provider-url https://rpc.sepolia.dev
ℹ️
RPC URLs change often, use a recent one from https://chainlist.org/ (opens in a new tab)
Downloading
Files uploaded via irys upload-dir
can be retrieved in one of two ways.
- Creating a URL with the format
https://gateway.irys.xyz/manifestId/:originalFileName]
. - Creating a URL using the transaction ID of each individual file uploaded with the format
https://gateway.irys.xyz/:transactonId
After a successful folder upload, two files are written to your local project directory:
[folder_name].csv
[folder_name].json
The example below highlights a folder called with a total of 5 files in it. The transaction ID for each file can be used to retrieve the uploaded data by forming a URL with the format https://gateway.irys.xyz]/transactionId