Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Order Direction (short or long) to Alpaca Order Interface #242

Open
ooples opened this issue Dec 20, 2022 · 0 comments
Open

Add Order Direction (short or long) to Alpaca Order Interface #242

ooples opened this issue Dec 20, 2022 · 0 comments

Comments

@ooples
Copy link

ooples commented Dec 20, 2022

Right now this change isn't available at the client only level so I want to request that on the server side, order info will include the order direction. I know this information is available for the stock positions but this change is very important for the order side for someone like me who runs 20 different portfolios and does thousands of stock transactions. Please keep me updated!

*EDIT: This change would be for the Alpaca Trading API and this would mostly likely affect the API only.

Recommended Order JSON structure:

  "id": "61e69015-8549-4bfd-b9c3-01e75843f47d",
  "client_order_id": "eb9e2aaa-f71a-4f51-b5b4-52a6c565dad4",
  "created_at": "2021-03-16T18:38:01.942282Z",
  "updated_at": "2021-03-16T18:38:01.942282Z",
  "submitted_at": "2021-03-16T18:38:01.937734Z",
  "filled_at": null,
  "expired_at": null,
  "canceled_at": null,
  "failed_at": null,
  "replaced_at": null,
  "replaced_by": null,
  "replaces": null,
  "asset_id": "b0b6dd9d-8b9b-48a9-ba46-b9d54906e415",
  "symbol": "AAPL",
  "asset_class": "us_equity",
  "notional": "500",
  "qty": null,
  "filled_qty": "0",
  "filled_avg_price": null,
  "order_class": "",
  "order_type": "market",
  "type": "market",
  "side": "buy",
  **"direction": "long" or "short",**
  "time_in_force": "day",
  "limit_price": null,
  "stop_price": null,
  "status": "accepted",
  "extended_hours": false,
  "legs": null,
  "trail_percent": null,
  "trail_price": null,
  "hwm": null
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant