alpacahq / alpacahq/Alpaca-API

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

Open
#242 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
No language data
Stars
173
Forks
17
PR merge metrics
No merged PRs in 30d

Description

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
}

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.