Skip to content

A script to automate token swaps and liquidity operations on the Pharos Network using Node.js. Supports configurable private key, looped execution, and headless runtime via screen sessions.

Notifications You must be signed in to change notification settings

winsnip/pharos-network

 
 

Repository files navigation

Pharos Network Swap and Liquidity Bot

This project is a simple automated script to interact with the Pharos Network, performing token swaps and liquidity-related operations.

Features

  • Token Swapping on Pharos Network
  • Liquidity Management
  • Headless execution using screen
  • Configurable private key and loop count for batch operations

Getting Started

1. Clone the Repository

git clone https://github.com/takachan0012/pharos-network.git

2. Navigate to the Project Directory

cd pharos-network

3. Install Dependencies

npm install

4. Set Environment Variables

setup private key

echo PRIVATE_KEY=your_private_key_here >> main/.env

setup loop count ( how many time you will run script in main.ts )

echo LOOP_COUNT=your_loop_count_here >> main/.env

setup amount in percent, it set for each tx of your asset. for example use 1% from asset balance

echo AMOUNT_IN_PERCENT=1 >> main/.env

set timeout in milisecond, it set for waiting next tx. for example below, next tx will be done in ranges 1minute to 2minutes

echo TIMEOUT_MIN_MS=60000 >> main/.env
echo TIMEOUT_MAX_MS=120000 >> main/.env

setup Autostaking Access token open https://autostaking.pro/?env=pharos, connect wallet > open devmode > tab console, paste code below

localStorage.getItem("token")

copy that value token, then run in terminal

echo AUTOSTAKING_TOKEN="your_token_here" >> main/.env

Optional Set Rpc Url

echo RPC_URL=your_rpc_url_here >> main/.env

5. Create a New Screen Session

screen -S pharos

6. Start the Bot

Command lists

Rwafi Aquaflux
npm run rwafiAquaflux
Autostaking
faucet
npm run autostakingFaucet
deposit
npm run autostakingDeposit
withdraw
npm run autostakingWithdraw
CFD Trading / Brokex
npm run openCfdTrade
Faroswap
USDC Liquidity
npm run faroswapUsdcLiquidity
USDT Liquidty
npm run faroswapUsdtLiquidty
USDC Swap
npm run faroswapUsdcSwap
WPHRS Swap
npm run faroswapWphrsSwap
Pharos Name Service
npm run pns
Primus
npm run primus
Zenith
USDC Liquidity
npm run zenithUsdcLiquidity
WPHRS Liquidity
npm run zenithWphrsLiquidity
USDC Swap
npm run zenithUsdcSwap
USDT Swap
npm run zenithUsdtSwap
WPHRS Swap
npm run zenithWphrsSwap
RWAFI R2
Swap
npm run rwafiR2Swap
Earn
npm run rwafiR2Earn
Lend and Borrow OpenFi
Faucet
npm run openFiFaucet
Supply
npm run openFiSupply
Borrow
npm run openFiBorrow
Repay
npm run openFiRepay
Withdraw
npm run openFiWithdraw
Spout RWAFI
Buy
npm run spoutBuy
Bitverse Trading

⚠️ NOTES Make sure your account in website has USDT balance. and We had been setup min and max amount for open position between 2 to 5 USDT.

Open position
npm run bitverseOpenPosition

if you got error especially in order type Market as example below:

Opening position long BTCS-USD for 2.16 USDT, Order type: market...
Failed: Error: transaction execution reverted action="sendTransaction", data=null, reason=null, invocation=null, revert=null, ...

setup order type to 2 in main/bitverse/openPosition.ts as below:

await openPosition({
     baseDir,
     side,
     pair,
     provider,
     signer: wallet.signer,
     router,
     orderType: 2 // SETUP HERE
})

-Atlantic-

Send Token To Friends
Setup PHAROS_TOKEN

open https://testnet.pharosnetwork.xyz/experience, connect wallet > open devmode > tab console, paste code below

localStorage.getItem("PHAROS_AUTHORIZATION_TOKEN")

copy that value token, then run in terminal

echo PHAROS_TOKEN=your_token_here >> main/.env
coomand send token
npm run atlanticDirectSendToken
Asseto
Subscription
npm run atlanticSubscribeAsseto
Redemption
npm run atlanticRedemptionAsseto

7. Detach the Screen Session

Press: Ctrl + A, then D

8. Reattach the Screen Session

screen -R pharos

Done!

Your bot is running in the background on the Pharos Network.

⚠️ NOTES

Coffee: https://trakteer.id/Winsnipsupport/tip

Join Telegram Winsnip

Stay updated and connect with the Winsnip community:

Channel: https://t.me/winsnip

Group Chat: https://t.me/winsnip_hub

This ensures users can join the Telegram community easily and stay engaged with updates and discussions.

Have suggestions or improvements? Feel free to contribute!

About

A script to automate token swaps and liquidity operations on the Pharos Network using Node.js. Supports configurable private key, looped execution, and headless runtime via screen sessions.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 99.4%
  • Solidity 0.6%