Skip to content

TypeScript SDK UserTrade type is missing the fee field #1983

Description

@realfishsam

Gap

Core's UserTrade type includes an optional fee field, and the Python SDK's UserTrade model already has it — but the TypeScript SDK's UserTrade interface omits it entirely.

Core

core/src/types.ts:215UserTrade.fee?: number; (within the UserTrade interface at core/src/types.ts:209-222).

TypeScript SDK

sdks/typescript/pmxt/models.ts:214-247 — the UserTrade interface has id, price, amount, side, timestamp, orderId?, outcomeId?, marketId?, txHash?, chain?, blockNumber? but no fee field at all.

Python SDK

sdks/python/pmxt/models.py:404-405 — already has fee: Optional[float] = None on UserTrade.

Evidence

Field-by-field read of core/src/types.ts:209-222 vs sdks/typescript/pmxt/models.ts:214-247 vs sdks/python/pmxt/models.py:404-405. The TypeScript SDK's own API_REFERENCE.md (around line 1804) documents fee: number as part of UserTrade, confirming the shipped models.ts is out of sync with its own docs, not just with core.

Impact

TypeScript SDK users have no typed way to read the fee value on a UserTrade object, even though core returns it, the Python SDK exposes it, and the TypeScript SDK's own reference docs claim it exists.


Found by automated Core-to-SDK surface coverage audit

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions