Skip to content

MarketOrderParams requires SubaccountParams as sender but this is not documented #32

Description

@ghettof

Bug Description

When calling place_market_order(), passing a wallet address string as sender
in MarketOrderParams causes a validation error. The correct type is SubaccountParams
but this is not mentioned anywhere in the documentation or examples.

Steps to Reproduce

from nado_protocol.utils.execute import MarketOrderParams

# This fails silently or causes unexpected behavior:
order = MarketOrderParams(sender="0xYourWalletAddress", amount=1000000000000000)

# This is the correct usage but is NOT documented:
from nado_protocol.utils.subaccount import SubaccountParams
sender = SubaccountParams(subaccount_owner="0xYourWalletAddress", subaccount_name="default")
order = MarketOrderParams(sender=sender, amount=1000000000000000)

Expected Behavior

Documentation should clearly state that sender must be a SubaccountParams object,
not a plain wallet address string.

Environment

  • nado-protocol SDK version: latest
  • Python 3.11

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions