Registry / data / pinets-cli

pinets-cli

JSON →
library0.1.14jsnpmunverified

pinets-cli is a CLI wrapper for PineTS (v0.1.14), an open-source transpiler that runs Pine Script indicators outside of TradingView. It allows executing .pine files directly from the command line with live market data (Binance) or custom JSON datasets. The release cadence is irregular as it is early-stage. Key differentiators: no code setup, JSON output, stdin support, and multiple timeframe options. It is ideal for quick backtesting and indicator prototyping without an IDE.

npm install pinets-cli
INSTALL
IMPORT
SIG · PINETS-CLI
P
pinets-cli
datajavascriptv0.1.14
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Install pinets-cli globally, create a sample Pine Script file with SMA cross, and run it on BTCUSDT hourly data to get JSON output.

npm install -g pinets-cli cat << 'EOF' > sma_cross.pine //@version=5 indicator("SMA Cross", overlay=true) fast = ta.sma(close, 9) slow = ta.sma(close, 21) plot(fast, "Fast SMA", color=color.blue) plot(slow, "Slow SMA", color=color.red) EOF pinets run sma_cross.pine --symbol BTCUSDT --timeframe 60
pinets-cli --version
Debug
Known issues
gotchaSymbol must be a Binance-valid ticker (e.g., BTCUSDT).
fix
Use correct symbol format like BTCUSDT, ETHUSDT, etc.
affects: >=0.1.0
deprecatedThe --data option accepts JSON but format must match internal candle structure (open, high, low, close, volume).
fix
Ensure JSON file has array of objects with keys: open, high, low, close, volume as numbers.
affects: >=0.1.0
breakingVersion 0.1.0 changed from npx pinets to npx pinets-cli run.
fix
Use 'pinets run' instead of 'pinets' directly.
affects: >=0.1.0
gotchaPiped stdin may not work on Windows without cat or equivalent.
fix
Use file argument or PowerShell's Get-Content pipe.
affects: >=0.1.0
gotchaOutput format 'full' (--format full) includes pinescript lines as keys which can be large.
fix
Use --format default for cleaner output.
affects: >=0.1.0
Errors
Common errors & fixes
Error: Unsupported symbol. Please use a valid Binance symbol.
Symbol ticker is not recognized by Binance exchange.
fix
Use correct symbol like 'BTCUSDT', 'ETHUSDT', or 'BNBUSDT'.
Error: Timeframe must be one of: 1, 5, 15, 60, 240, 1D, 1W, 1M
Invalid timeframe value provided via --timeframe option.
fix
Use one of the supported values: '1', '5', '15', '60', '240', '1D', '1W', '1M'.
Error: File not found: ./nonexistent.pine
Pine script file path is incorrect or file does not exist.
fix
Ensure the file path is correct and file exists.
Upgrade
Version history
0.1.14latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
2 hits · last 30 days
node
2
Resources
pinets-cli — npm install pinets-cli · libregistry