RIN Wallet RPC Scripts
This directory contains scripts for interacting with the RIN cryptocurrency wallet via RPC.
Prerequisites
curlandjqmust be installed on your system- RIN wallet/node must be running with RPC enabled
- RPC credentials must be configured
Scripts
send_rin.sh
Send RIN to another wallet address.
./send_rin.sh <recipient_address> <amount> [rpc_user] [rpc_password] [rpc_host] [rpc_port]
Example:
./send_rin.sh rin1qvj0yyt9phvled9kxflju3p687a4s7kareglpk5 100.0
check_balance.sh
Check wallet balance.
./check_balance.sh [account] [rpc_user] [rpc_password] [rpc_host] [rpc_port]
Example:
./check_balance.sh # Check all accounts
./check_balance.sh myaccount # Check specific account
get_transaction.sh
Get details of a specific transaction.
./get_transaction.sh <transaction_id> [rpc_user] [rpc_password] [rpc_host] [rpc_port]
Example:
./get_transaction.sh a1b2c3d4e5f6...
rpc_call.sh
General-purpose RPC call script for any RIN RPC method.
./rpc_call.sh <method> [param1] [param2] ... [rpc_user] [rpc_password] [rpc_host] [rpc_port]
Examples:
./rpc_call.sh getinfo
./rpc_call.sh getnewaddress myaccount
./rpc_call.sh listtransactions "*" 10
./rpc_call.sh validateaddress rin1qvj0yyt9phvled9kxflju3p687a4s7kareglpk5
./rpc_call.sh loadwallet
Default RPC Configuration
- Host: localhost
- Port: 8332
- User: rinrpc
- Password: password
You can override these defaults by providing them as the last arguments to any script.
Common RPC Methods
getbalance [account]- Get account balancegetinfo- Get wallet infogetnewaddress [account]- Generate new addresssendtoaddress <address> <amount>- Send coinslisttransactions [account] [count]- List transactionsgettransaction <txid>- Get transaction detailsvalidateaddress <address>- Validate addressgetaddressesbyaccount [account]- Get addresses for account
Security Notes
- These scripts send credentials in plain text (HTTP Basic Auth)
- Consider using HTTPS or local connections only
- Update default RPC credentials for production use
- Store scripts securely and avoid hardcoding sensitive information