Install
openclaw skills install @mtrab/openclaw-coinbaseAccess Coinbase API to fetch balances, get EUR trading pairs, create market or limit crypto orders, and view order history and fills.
openclaw skills install @mtrab/openclaw-coinbaseThis skill provides access to Coinbase trading API for crypto trading agents.
from scripts.coinbase import get_euro_balance, get_btc_balance, get_all_balances
eur = get_euro_balance()
btc = get_btc_balance()
all_balances = get_all_balances()
from scripts.coinbase import get_eur_products, get_product
# All EUR trading pairs
products = get_eur_products()
# Specific product
btc_eur = get_product('BTC-EUR')
from scripts.coinbase import create_order
# Market buy order
result = create_order(
product_id='BTC-EUR',
side='BUY',
size='0.001' # Amount in base currency
)
# Limit order
result = create_order(
product_id='BTC-EUR',
side='BUY',
size='0.001',
price='45000', # Limit price
order_type='LIMIT'
)
from scripts.coinbase import get_fills, get_orders
# Recent trades
fills = get_fills()
# Specific product
fills_btc = get_fills(product_id='BTC-EUR')
# Order history
orders = get_orders()
Create these files in the same directory as the script:
.coinbase-api-key # Your API key
.coinbase-api-secret # Your private key (PEM format)
side='BUY' or side='SELL'size is in base currency (e.g., BTC, not EUR)