This is used to programmatically add a specific amount of funds to your 3Commas paper trading account. Paper trading requires a 3Commas subscription.
-
Log into 3Commas and open your paper account
-
Click My Exchanges then the view icon on your paper trading account
-
Right click on the screen and inspect the page
-
Click the network tab
-
Click the
+$
next to your paper account name, this will add $1000 to your paper account -
Within your network tab you should see a
POST
with the filepapertrading_deposit
. Copy those headers.The network call with be at the top by default, but you can use the filter and filter for
paper
and find it easier.Firefox
- Right click the network call
- Copy > copy request headers
- Paste this into a notepad
- Copy everything to the right of
Cookie:
- Paste into the
cookie.txt
file. Make sure to not includeCookie:
into your string.
Chrome
- Right click the network call
- Copy > Copy as cURL. Note do note use
Copy all as cRURL
. - Paste this into a notepad
- The contents next to
-H 'cookie:
in this file are what you need to copy. Remove the trailing' \
from the end of the string. - Paste into the cookie.txt file. Make sure to not include the
-H 'cookie:
or' \
-
Run the function
Replace the
account_id
with your paper trading account id andtotal_funds
with the total amount of funds you want to add to paperExample:
python3 addfunds.py account_id total_funds
You will see
b'{"message":"Deposit successful"}'
printed for each $1000 that is added to your account.