Skip to main content
A position represents your directional bet on the future EUR/USD exchange rate at a specific maturity date. Positions flow through a well-defined lifecycle: open, manage, and close.
The protocol is deployed on Ethereum Sepolia testnet. All amounts are in test USDC with no monetary value.

Opening a Trade

To open a position, you choose four parameters:
ParameterDescriptionExample
SideLONG (EUR strengthens) or SHORT (EUR weakens)LONG
TenorMaturity period: 1 Day, 1 Week, or 1 Month1 Week
NotionalFace value of the contract in USDC10,000 USDC
MarginCollateral to lock (min 2% of notional, max 100%)500 USDC (5%, 20x leverage)
When you open a position, the protocol:
1

Validates your parameters

Checks that the pair and tenor are enabled, notional meets the minimum (100 USDC), and your margin is within the allowed range.
2

Calculates your maturity date

Adds the tenor duration to the current time and adjusts to the next business day at 4 PM UTC. Weekend dates roll to Monday.
3

Locks your entry price

Fetches the current forward price for your maturity date from the oracle. This becomes your entry strike — the reference price for all PnL calculations. It never changes.
4

Runs risk checks

Verifies that the position does not exceed per-position, per-account, or pool exposure caps.
5

Locks margin and charges fee

Your margin is locked from your collateral balance. A trading fee (0.05% of notional) is charged upfront.
All parameters that affect a position’s economics — margin rates, fee rates, liquidation penalty — are captured at open time. Admin changes to these parameters only affect future positions, never existing ones.

Managing Your Position

While your position is open, you have several options:

Add Margin

Increase your locked margin to reduce leverage and move further from liquidation. This is a rescue operation — it works even when your position is liquidatable.

Remove Margin

Decrease your locked margin to free up collateral. Only allowed when your position is healthy and the remaining margin stays above the minimum initial margin.

Reduce Position

Partially close your position by reducing the notional amount. PnL on the reduced portion is settled immediately. The remaining position stays open at the original entry price.

Increase Position

Add to your position’s notional. The entry price blends your original strike with the current forward price using a weighted average. Only available in Normal mode.
Adding margin is always more permissive than removing it. If your position is approaching liquidation, you can inject additional collateral to rescue it — but you cannot extract value from a distressed position.

How Your Trade Closes

Every position eventually closes through one of four paths:
The standard close path. When your position reaches its maturity date, it settles at the fixing price — the EUR/USD spot price recorded from Pyth at 4 PM UTC on the maturity business day. Settlement happens automatically (the keeper service processes it), but any address can trigger it.
  • Fee: Standard trading fee (0.05% of notional)
  • No action required from you

Position Status

A position follows a strict one-way transition:
OPEN → CLOSED
Once closed, a position cannot be reopened or modified. Every closed position records why it was closed: maturity settlement, early termination, or liquidation.

Fixing Timestamp Calculation

The maturity date is computed deterministically when you open a position:
Position OpenedTenorFixing Timestamp
Monday 10 AM UTC1 DayTuesday 4 PM UTC
Friday 10 AM UTC1 DayMonday 4 PM UTC (weekend roll)
Thursday 10 AM UTC1 WeekThursday 4 PM UTC (next week)
Saturday 10 AM UTC1 DayMonday 4 PM UTC (weekend roll)
The 4 PM UTC fixing time aligns with the WM/Reuters London Fix used in institutional FX markets. Weekend maturities always roll to Monday.

Next Steps

PnL Calculation

How profit and loss is calculated on your positions.

Margin

Deep dive into margin mechanics, leverage, and liquidation thresholds.

Smart Contract API

Full Position struct, function signatures, and error codes for developers.