# Vault Creation - CLI Guide

{% stepper %}
{% step %}

### Download The CLI File <a href="#step-1-download-the-cli-file" id="step-1-download-the-cli-file"></a>

* Visit the Prodigy.Fi CLI repository: <https://github.com/prodigyfi/dci-cli>
* Click the green **Code** button in the top-right corner.
* Select **Download ZIP** and save the file to your computer (eg; in your Downloads folder).
* Unzip the file to access the dci-cli-main folder.

<figure><img src="https://1498879445-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0xUM1AtBZof4xC0ubVWO%2Fuploads%2FGyHBWGYVZ2sYphjwrfhm%2Fimage.png?alt=media&#x26;token=87a4616e-4d32-4707-afeb-b2e44eb72588" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Install A Code Editor <a href="#step-2-install-a-code-editor" id="step-2-install-a-code-editor"></a>

* Download and install a code editor, such as Visual Studio Code, if you don’t have one.
* Open the dci-cli-main folder in your code editor:
* In Visual Studio Code, click **File** > **Open Folder** and select the dci-cli-main folder.

<figure><img src="https://1498879445-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0xUM1AtBZof4xC0ubVWO%2Fuploads%2FRyPBOURLVC093EfLLfX6%2Fimage.png?alt=media&#x26;token=78c4d75b-9766-4e6e-a2ac-9979fc770c04" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Rename Your Files <a href="#step-3-rename-your-files" id="step-3-rename-your-files"></a>

* In the dci-cli-main folder, locate the files `config.example.json` and `create-vaults.example.csv`.
* Create copies of these files and rename them:
  * `config.example.json` → `config.json`
  * `create-vaults.example.csv` → `create-vaults.csv`
* To rename:
  * Alternatively, in Finder (Mac) or File Explorer (Windows), right-click, select **Duplicate** or **Copy/Paste**, and rename.

<figure><img src="https://1498879445-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0xUM1AtBZof4xC0ubVWO%2Fuploads%2FjPY7NlidnuzNcgppbjGt%2Fimage.png?alt=media&#x26;token=255a5feb-3669-455d-aab8-2f2c9ca75abc" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Configure The RPC Node URL <a href="#step-4-configure-the-rpc-node-url" id="step-4-configure-the-rpc-node-url"></a>

* Open config.json in your code editor.
* Fill in the `rpcNode` parameter with the RPC node URL for your chosen blockchain network. This connects the CLI tool to the network. You can find the list of RPC nodes available [here](https://chainlist.org/).
* Copy any one of the link shown on the website

<figure><img src="https://1498879445-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0xUM1AtBZof4xC0ubVWO%2Fuploads%2F6Azcw820oqORhM5KImdi%2Fimage.png?alt=media&#x26;token=fa48ba51-e99a-4369-965b-7bcba7daafa1" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Fill In The `rpcNode` Section

* Paste the copied link into the rpcNode section

{% hint style="info" %}
*Note: Fill the config file under the network that you are running your CLI tool on. For example, if you trying to run the CLI tool on Base testnet, fill up the file under "Base Testnet" as shown in the example below.*
{% endhint %}

<figure><img src="https://1498879445-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0xUM1AtBZof4xC0ubVWO%2Fuploads%2F7JtIKX2fYqNYznEaxebl%2Fimage.png?alt=media&#x26;token=7c880435-1160-4699-9319-f03891076522" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

## Configure Wallet <a href="#step-5-configure-wallet" id="step-5-configure-wallet"></a>

* Add the `account` parameter with your wallet address.
* Replace the placeholder, `lp_account` , with your wallet address.

<figure><img src="https://1498879445-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0xUM1AtBZof4xC0ubVWO%2Fuploads%2F572Y2xUWcYdKwoKElEqI%2Fimage.png?alt=media&#x26;token=eb0b6804-b236-46a3-a23d-9c97fe89479a" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Obtain Json Wallet & Passphrase <a href="#step-6-obtain-json-wallet-and-passphrase" id="step-6-obtain-json-wallet-and-passphrase"></a>

To obtain the `JSON wallet` and `passphrase`, follow these steps:

* Open your folders, and go to the file you downloaded in Step 1.
* Right-click on the folder (the unzipped version), and click Copy (**Cmd + C** or **Ctrl + C**).

<figure><img src="https://1498879445-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0xUM1AtBZof4xC0ubVWO%2Fuploads%2FuJv1MJw4xcAl25pnsTpa%2Fimage.png?alt=media&#x26;token=47a1d044-3e35-4312-bcd0-3705393b1753" alt=""><figcaption></figcaption></figure>

* Open your terminal (Mac) or command prompt (Windows), type `cd`, press the spacebar, and paste the folder path (**Cmd + V** or **Ctrl + V**).
* It should look something like: `cd /Users/username/Downloads/dci-cli-main`.
  * “username” is your Mac username (type whoami in terminal to check).
  * “Downloads” is where your file is stored.
  * “dci-cli-main” is the name of your folder.

{% hint style="info" %}
**Note**: If you stored or renamed your folder, the folder path may look different
{% endhint %}

* **Run this command:**&#x20;
  * **`npm i`**
* If it shows an error, follow the instructions and run the fix comman&#x64;**:**
  * **`npm audit fix --force`**
* Once all the issues are fixed, run this command:&#x20;
  * **`npx ts-node src/encrypt_wallet.ts`**
* Enter the private key of the wallet you are trying to create your vaults with.
* Set your `passphrase`
* After you have done so, a new keystore should be generated. It should look something like this: keystore/0xXXXXXXXXX.json. This will be your `JSON wallet.`
* Copy the `Json wallet` and `passphrase` into the config.json file.

<figure><img src="https://1498879445-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0xUM1AtBZof4xC0ubVWO%2Fuploads%2F8xlc7sfv9s6AjMaucI6N%2Fimage.png?alt=media&#x26;token=b91a5ecb-9ec8-457b-95d9-674ec140543c" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Configure Vault Parameters <a href="#step-7-configure-vault-parameters" id="step-7-configure-vault-parameters"></a>

* Open the `create-vaults.csv` file using a code editor (eg; Visual Studio Code). Fill in the vault parameters:

<figure><img src="https://1498879445-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0xUM1AtBZof4xC0ubVWO%2Fuploads%2FqUV2ygR2z4ZoRBCBrzXQ%2Fimage.png?alt=media&#x26;token=8db3a599-1d3b-4bc4-afa9-c51794a16e47" alt=""><figcaption></figcaption></figure>

* **CreationDate**: The date when the vault will be created in this format; YYYY-MM-DD (eg; 2025-07-29).
* **Network**: The blockchain network where the vault will be created (eg; Base Mainnet).
* **TradingPair**: The token asset pair (eg; WETH-USDC).
* **LinkedPrice**: The target price at which you want to buy or sell your crypto token (eg; 2000.00).
* **YieldPercentage**: The reward offered to vault subscribers (eg; 5.0 for 5%).
* **ExpireDate**: The expiration date of the vault in this format: YYYY-MM-DD.
* **Direction**: The vault strategy, either “Buy Low” or “Sell High”.
* **Quantity**: The amount of digital asset to be bought or sold (eg; 1.5 for 1.5 WETH).

Here is an example:

<figure><img src="https://1498879445-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0xUM1AtBZof4xC0ubVWO%2Fuploads%2FLsDYXphHaC7ZcNWPcWr1%2Fimage.png?alt=media&#x26;token=0d83edad-245f-40d7-b4e7-f7cd6352783f" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Save Both Files

* Once you fill-up the parameter, save both the `config.json` & `create-vaults.csv` file (**Cmd + S** or **Ctrl + S**).
* Make sure to verify in your code editor that the files are in the dci-cli-main folder and contain the correct saved settings.
  {% endstep %}

{% step %}

### Install Dependencies

* In the terminal, run this command `npm i`
* If there are any issues, run the fix command again: `npm audit fix --force`
  {% endstep %}

{% step %}

### Run The CLI Script

* You are now ready to run the script!
* Run this command in the terminal: `npx ts-node ./src/batch_runner.ts`
* Once the vault is created, you will see the message “Vault created successfully”.

<figure><img src="https://1498879445-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0xUM1AtBZof4xC0ubVWO%2Fuploads%2F8ZB58o75fqsLw2w8F8R3%2Fimage.png?alt=media&#x26;token=d22d86bf-1b87-4ab6-ae2b-611f3e8abbb9" alt=""><figcaption></figcaption></figure>
{% endstep %}
{% endstepper %}
