Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
alsk1992 avatar

Drift Sdk

  • 14 installs
  • 610 repo stars
  • Updated June 26, 2026
  • alsk1992/cloddsbot

Drift SDK is a Claude Code skill for direct SDK-based perpetual-futures trading on Drift Protocol, Solana's perp DEX, without a gateway server.

About

Drift SDK is a trading skill that connects an agent directly to Drift Protocol on Solana via the native SDK, bypassing the gateway server the base Drift skill needs. A developer uses /drift commands to open long/short positions, manage limit and market orders, set leverage, and track unrealized PnL and risk metrics. It requires a DRIFT_PRIVATE_KEY and optionally a Solana RPC URL, with a DRY_RUN test mode.

  • Direct SDK-based perpetual-futures trading on Drift without a gateway server
  • Supports market, limit, post-only, IOC and FOK order types with per-market leverage up to 20x
  • Reports risk metrics: health factor, margin usage, and liquidation prices

Drift Sdk by the numbers

  • 14 all-time installs (skills.sh)
  • Ranked #752 of 1,106 Finance & Trading skills by installs in the Skillselion catalog
  • Data as of Aug 5, 2026 (Skillselion catalog sync)
At a glance

drift-sdk capabilities & compatibility

Requires DRIFT_PRIVATE_KEY and trading capital; optional custom Solana RPC; DRY_RUN test mode available. No service fee stated.

Capabilities
perp trading · spot trading · order management · leverage control · risk metrics
Use cases
trading
Runs
Runs locally
Pricing
Bring your own API key
From the docs

What drift-sdk says it does

Direct SDK-based trading on Drift Protocol, Solana's leading perpetual futures DEX. Bypass the gateway requirement with native SDK integration.
SKILL.md
**Risk Metrics** - Health factor, margin usage, liquidation prices
SKILL.md
npx skills add https://github.com/alsk1992/cloddsbot --skill drift-sdk

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs14
repo stars610
Last updatedJune 26, 2026
Repositoryalsk1992/cloddsbot

What it does

Trade Drift perpetual futures on Solana directly through the native SDK with full order types and risk metrics.

Who is it for?

Agents that need direct Drift perp/spot trading with limit, post-only, IOC, and FOK orders.

Skip if: Users without a Solana private key or who prefer the gateway-based Drift skill.

When should I use this skill?

You want native SDK trading on Drift Protocol without running a gateway server.

What you get

Direct native-SDK trading on Drift with full order types, leverage control, and live risk metrics.

By the numbers

  • Order types: market, limit, post-only, IOC, FOK
  • Per-market leverage 1-20x

Files

SKILL.mdMarkdownGitHub ↗

Drift Protocol SDK

Direct SDK-based trading on Drift Protocol, Solana's leading perpetual futures DEX. Bypass the gateway requirement with native SDK integration.

Quick Start

# Set credentials
export DRIFT_PRIVATE_KEY="your-solana-private-key"
export SOLANA_RPC_URL="https://api.mainnet-beta.solana.com"

# Check balance
/drift balance

# Open a position
/drift long BTC 0.1
/drift short ETH 1 2500

# Close position
/drift close BTC

Commands

Trading

CommandDescription
/drift long <coin> <size> [price]Open long position
/drift short <coin> <size> [price]Open short position
/drift close <coin>Close position at market
/drift closeallClose all positions
/drift leverage <coin> <1-20>Set leverage

Examples:

/drift long BTC 0.1           # Market buy 0.1 BTC
/drift short ETH 1 2500       # Limit sell 1 ETH at $2500
/drift leverage SOL 5         # Set SOL leverage to 5x

Orders

CommandDescription
/drift ordersList open orders
/drift cancel <orderId>Cancel order by ID
/drift cancel <coin>Cancel all orders for coin
/drift cancelallCancel all orders
/drift modify <orderId> [price] [size]Modify order

Account

CommandDescription
/drift balanceCollateral, margin, health factor
/drift positionsOpen positions with PnL

Configuration

# Required
export DRIFT_PRIVATE_KEY="base58_or_json_array"

# Optional
export SOLANA_RPC_URL="https://api.mainnet-beta.solana.com"
export DRY_RUN=true  # Test mode

Features

  • Direct SDK - No gateway server required
  • Perp & Spot - Trade both market types
  • Order Types - Market, limit, post-only, IOC, FOK
  • Position Management - Track unrealized PnL, entry prices
  • Risk Metrics - Health factor, margin usage, liquidation prices
  • Leverage Control - Set per-market leverage (1-20x)

Markets

MarketIndexMax Leverage
BTC-PERP020x
ETH-PERP120x
SOL-PERP220x
.........

Resources

Related skills

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.