position.open

Open a position in a prediction market with declarative parameters and automatic risk management.


Overview

The position.open tool executes trades on prediction markets with built-in risk checks, slippage protection, and approval workflows. Agents describe trade intent using natural language; MoltMarket handles order placement, transaction signing, and position tracking.

Key features:

  • Automatic risk limit validation

  • Conditional execution (e.g., "if probability < 45%")

  • Stop-loss and take-profit configuration

  • Hardware wallet approval for large trades

  • Transaction confirmation tracking


Parameters

Parameter
Type
Required
Description

market_id

string

Yes

Platform-specific market identifier

platform

string

Yes

"polymarket" or "kalshi"

side

string

Yes

"YES" or "NO"

amount

number

Yes

Position size in USD/USDC

order_type

string

No

"market" or "limit" (default: market)

limit_price

number

No

Limit price 0-1 (required if order_type=limit)

slippage_tolerance

number

No

Max acceptable slippage in % (default: 1.0)

stop_loss

number

No

Auto-close if price reaches this level (0-1)

take_profit

number

No

Auto-close if price reaches this level (0-1)

conditions

object

No

Conditional execution rules


Request Examples

Market Order

Limit Order

With Risk Management

Conditional Execution

MCP Tool Call (JSON)


Response Format

Successful Execution

Risk Limit Exceeded

Requires Approval


Risk Validation

Before executing trades, MoltMarket validates:

1. Position Size Limits

Validation:

2. Total Exposure Limits

Validation:

3. Daily Loss Limits

Validation:

4. Concentration Limits

Validation:

5. Open Position Limits

Validation:


Approval Workflows

Small Trades (Auto-Approve)

Medium Trades (Notification + Auto-Execute)

Large Trades (Hardware Wallet Required)


Order Types

Market Order

Executes immediately at best available price.

Pros:

  • Guaranteed execution (if sufficient liquidity)

  • Fast (< 2 seconds)

Cons:

  • Price uncertainty

  • Potential slippage

Limit Order

Executes only at specified price or better.

Pros:

  • Price certainty

  • Better execution prices

Cons:

  • May not fill

  • Requires monitoring


Platform-Specific Behavior

Polymarket

Settlement: On-chain USDC on Polygon Gas Fees: ~$0.50-2.50 per trade Collateral: USDC (1:1) Order Book: Continuous (always available)

Example transaction flow:

  1. Approve USDC spending (one-time)

  2. Submit trade to CLOB API

  3. Order matched on-chain

  4. Shares minted via CTF contract

  5. Position recorded in wallet

Kalshi

Settlement: USD (centralized) Fees: ~2% per trade Collateral: USD (fiat) Order Book: Continuous (market hours)

Example transaction flow:

  1. Check USD balance

  2. Submit order via REST API

  3. Order matched by Kalshi

  4. Position recorded in account

  5. Confirmation email sent


Error Handling

Insufficient Balance

Solution: Deposit more USDC/USD

Slippage Exceeded

Solution: Increase slippage tolerance or use limit order

Market Closed

Solution: Find alternative market


Performance

Metric
Polymarket
Kalshi

Avg Execution Time

2.1s

1.8s

p95 Execution Time

3.5s

2.9s

Success Rate

98.2%

99.1%

Typical Gas Fee

$1.20

$0 (included in spread)


Best Practices

  1. Always Set Stop-Losses

  2. Use Limit Orders for Large Trades

  3. Check Liquidity First

  4. Monitor Slippage



Examples

See Event-Driven Tradingarrow-up-right for advanced position management.

Last updated