ranger-finance

Build Solana perpetual futures trading applications using the Ranger Finance SOR SDK.

1|1|Updated May 21, 2026
One-click install
npx skills add https://github.com/naruto11eth/cryptoskills --skill ranger-finance-naruto11eth
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ranger-finance
Source: https://github.com/naruto11eth/cryptoskills/tree/main/skills/ranger-finance
Command: npx skills add https://github.com/naruto11eth/cryptoskills --skill ranger-finance-naruto11eth

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @solana/web3.js, bs58, dotenv, mcp-agent, numpy.

What problem does it solve? Trading perpetual futures on Solana requires integrating separately with multiple protocols like Drift, Flash, Adrena, and Jupiter, each with different APIs and pricing. This Skill provides a unified guide for the Ranger Finance Smart Order Router, which aggregates liquidity across these venues for best execution. ## Core Features & Use Cases - Smart Order Routing: Get quotes and route trades across Drift, Flash, Adrena, and Jupiter perp venues through a single API. - Position Management: Fetch, filter, decrease, and close positions across all supported platforms with unified TypeScript interfaces. - AI Agent Integration: Expose trading tools via an MCP server for building automated trading agents and portfolio monitors. - Use Case: Build an AI trading agent that monitors liquidation signals, gets cross-venue quotes for SOL perpetuals, and executes trades at the venue with the best pricing. ## Quick Start Use the ranger-finance skill to get a quote and open a 1 SOL long position with 10 USDC collateral through the Smart Order Router.

Frequently Asked Questions about ranger-finance

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I open a perpetual futures position on Solana with Ranger Finance?

Initialize the SorApi client with your API key, then call increasePosition with the symbol, side (Long or Short), size, collateral, and adjustment_type 'Increase'. The API returns a base64-encoded transaction that you sign with your Solana keypair and submit to the network.

What is a smart order router for Solana perpetuals trading?

A smart order router aggregates liquidity across multiple perp protocols to find the best execution price. Ranger Finance routes orders across Drift, Flash, Adrena, and Jupiter, returning venue allocations with per-venue quotes and fee breakdowns.

Which perp protocols does Ranger Finance aggregate on Solana?

Ranger Finance aggregates perpetual futures across four Solana protocols: Drift, Flash Trade, Adrena, and Jupiter Perps. Drift offers 20+ markets while Flash, Adrena, and Jupiter support SOL, BTC, and ETH.

Can I build an AI trading agent with the Ranger MCP server?

Yes, Ranger provides an MCP server exposing tools like sor_get_trade_quote, sor_increase_position, data_get_positions, and data_get_liquidations. Install the ranger-agent-kit with Python, configure your API key, and connect agents using the mcp-agent framework.

Why does my Ranger Finance transaction fail with insufficient liquidity?

Error 1004 occurs when venues lack enough liquidity for your order size. Call getOrderMetadata first to check order_available_liquidity per venue, then reduce your order size or split it into smaller orders across venues.

What are the Ranger Finance API rate limits?

The standard rate limit is 100 requests per minute, position queries are limited to 30 per minute, and trade execution to 10 per minute. Responses include X-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset headers for tracking usage.