Using the MinIO CLI
Leverage the Recall S3 adapter with MinIO.
Run the adapter
Start the adapter with the binary installed and flags described in the installation page.
This will start the adapter on port 8014
by default. Also, recall the --network
flag can,
optionally, be provided to point to a specific Recall chain environment, and logging can be enabled
by passing the -v
flag.
You MUST own tokens and credits to create a bucket and store data, respectively. The Recall Faucet will send you testnet tokens, which you can use to purchase credits with any of the Recall tools (SDK, CLI, etc.). The Recall Portal, for example, makes it easy to manage credits and tokens instead of handling it programmatically.
Run the S3 client
You can now use an S3-compatible client like MinIO to interact with Recall. First, make sure you have the MinIO client installed, such as with Homebrew on Mac:
Then, add Recall as an alias to the MinIO configuration, and be sure to specify the API version as
S3v4
. The URL shown below is the default port for the adapter, but you can change it by specifying
the --address
flag.
You can verify the alias was set properly with mc alias list
:
Create a bucket
Now, you can directly use MinIO to write or read data! Start by creating a bucket:
This will create the bucket called foo
under your recall
alias. But, recall that the bucket will
actually get used under <0x_address>.<bucket_name>
. The step below shows how to check the actual
bucket name.
Check the bucket name
You can check the buckets under your alias with mc ls recall
. This will list the bucket above with
the name we used:
When you interact with the bucket, you can either use the aliased or expanded format: the custom alias name, or the alias prefixed with the public key (and a period delimiter). See the bucket usage section for more details.
Write & read data
You can write to the address that identifies the bucket, where you'd replace 0x90f7...
with your
system-defined bucket name:
Then, you can read the data back via stdout, or download it to a file: