adaptic-backend 1.0.152 → 1.0.153
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/generated/typeStrings/Account.cjs +0 -370
- package/generated/typeStrings/Account.d.ts +1 -1
- package/generated/typeStrings/Account.d.ts.map +1 -1
- package/generated/typeStrings/Account.js.map +1 -1
- package/generated/typeStrings/Action.cjs +7 -822
- package/generated/typeStrings/Action.d.ts +1 -1
- package/generated/typeStrings/Action.d.ts.map +1 -1
- package/generated/typeStrings/Action.js.map +1 -1
- package/generated/typeStrings/Alert.cjs +0 -804
- package/generated/typeStrings/Alert.d.ts +1 -1
- package/generated/typeStrings/Alert.d.ts.map +1 -1
- package/generated/typeStrings/Alert.js.map +1 -1
- package/generated/typeStrings/AlpacaAccount.cjs +2 -1051
- package/generated/typeStrings/AlpacaAccount.d.ts +1 -1
- package/generated/typeStrings/AlpacaAccount.d.ts.map +1 -1
- package/generated/typeStrings/AlpacaAccount.js.map +1 -1
- package/generated/typeStrings/Asset.cjs +0 -975
- package/generated/typeStrings/Asset.d.ts +1 -1
- package/generated/typeStrings/Asset.d.ts.map +1 -1
- package/generated/typeStrings/Asset.js.map +1 -1
- package/generated/typeStrings/Authenticator.cjs +1 -382
- package/generated/typeStrings/Authenticator.d.ts +1 -1
- package/generated/typeStrings/Authenticator.d.ts.map +1 -1
- package/generated/typeStrings/Authenticator.js.map +1 -1
- package/generated/typeStrings/Customer.cjs +32 -290
- package/generated/typeStrings/Customer.d.ts +1 -1
- package/generated/typeStrings/Customer.d.ts.map +1 -1
- package/generated/typeStrings/Customer.js.map +1 -1
- package/generated/typeStrings/NewsArticle.cjs +0 -405
- package/generated/typeStrings/NewsArticle.d.ts +1 -1
- package/generated/typeStrings/NewsArticle.d.ts.map +1 -1
- package/generated/typeStrings/NewsArticle.js.map +1 -1
- package/generated/typeStrings/NewsArticleAssetSentiment.cjs +1 -543
- package/generated/typeStrings/NewsArticleAssetSentiment.d.ts +1 -1
- package/generated/typeStrings/NewsArticleAssetSentiment.d.ts.map +1 -1
- package/generated/typeStrings/NewsArticleAssetSentiment.js.map +1 -1
- package/generated/typeStrings/Order.cjs +4 -1006
- package/generated/typeStrings/Order.d.ts +1 -1
- package/generated/typeStrings/Order.d.ts.map +1 -1
- package/generated/typeStrings/Order.js.map +1 -1
- package/generated/typeStrings/Position.cjs +1 -961
- package/generated/typeStrings/Position.d.ts +1 -1
- package/generated/typeStrings/Position.d.ts.map +1 -1
- package/generated/typeStrings/Position.js.map +1 -1
- package/generated/typeStrings/Session.cjs +33 -286
- package/generated/typeStrings/Session.d.ts +1 -1
- package/generated/typeStrings/Session.d.ts.map +1 -1
- package/generated/typeStrings/Session.js.map +1 -1
- package/generated/typeStrings/StopLoss.cjs +7 -496
- package/generated/typeStrings/StopLoss.d.ts +1 -1
- package/generated/typeStrings/StopLoss.d.ts.map +1 -1
- package/generated/typeStrings/StopLoss.js.map +1 -1
- package/generated/typeStrings/TakeProfit.cjs +7 -496
- package/generated/typeStrings/TakeProfit.d.ts +1 -1
- package/generated/typeStrings/TakeProfit.d.ts.map +1 -1
- package/generated/typeStrings/TakeProfit.js.map +1 -1
- package/generated/typeStrings/Trade.cjs +38 -967
- package/generated/typeStrings/Trade.d.ts +1 -1
- package/generated/typeStrings/Trade.d.ts.map +1 -1
- package/generated/typeStrings/Trade.js.map +1 -1
- package/generated/typeStrings/User.cjs +4 -697
- package/generated/typeStrings/User.d.ts +1 -1
- package/generated/typeStrings/User.d.ts.map +1 -1
- package/generated/typeStrings/User.js.map +1 -1
- package/generated/typeStrings/VerificationToken.cjs +1 -6
- package/generated/typeStrings/VerificationToken.d.ts +1 -1
- package/generated/typeStrings/VerificationToken.d.ts.map +1 -1
- package/generated/typeStrings/VerificationToken.js.map +1 -1
- package/generated/typeStrings/index.d.ts +17 -17
- package/generated/typegraphql-prisma/models/Trade.d.ts +1 -1
- package/generated/typegraphql-prisma/resolvers/relations/Trade/TradeRelationsResolver.cjs +1 -1
- package/generated/typegraphql-prisma/resolvers/relations/Trade/TradeRelationsResolver.js.map +1 -1
- package/package.json +1 -1
- package/server/generated/typeStrings/Account.d.ts +1 -1
- package/server/generated/typeStrings/Account.d.ts.map +1 -1
- package/server/generated/typeStrings/Account.js.map +1 -1
- package/server/generated/typeStrings/Account.mjs +0 -370
- package/server/generated/typeStrings/Action.d.ts +1 -1
- package/server/generated/typeStrings/Action.d.ts.map +1 -1
- package/server/generated/typeStrings/Action.js.map +1 -1
- package/server/generated/typeStrings/Action.mjs +7 -822
- package/server/generated/typeStrings/Alert.d.ts +1 -1
- package/server/generated/typeStrings/Alert.d.ts.map +1 -1
- package/server/generated/typeStrings/Alert.js.map +1 -1
- package/server/generated/typeStrings/Alert.mjs +0 -804
- package/server/generated/typeStrings/AlpacaAccount.d.ts +1 -1
- package/server/generated/typeStrings/AlpacaAccount.d.ts.map +1 -1
- package/server/generated/typeStrings/AlpacaAccount.js.map +1 -1
- package/server/generated/typeStrings/AlpacaAccount.mjs +2 -1051
- package/server/generated/typeStrings/Asset.d.ts +1 -1
- package/server/generated/typeStrings/Asset.d.ts.map +1 -1
- package/server/generated/typeStrings/Asset.js.map +1 -1
- package/server/generated/typeStrings/Asset.mjs +0 -975
- package/server/generated/typeStrings/Authenticator.d.ts +1 -1
- package/server/generated/typeStrings/Authenticator.d.ts.map +1 -1
- package/server/generated/typeStrings/Authenticator.js.map +1 -1
- package/server/generated/typeStrings/Authenticator.mjs +1 -382
- package/server/generated/typeStrings/Customer.d.ts +1 -1
- package/server/generated/typeStrings/Customer.d.ts.map +1 -1
- package/server/generated/typeStrings/Customer.js.map +1 -1
- package/server/generated/typeStrings/Customer.mjs +32 -290
- package/server/generated/typeStrings/NewsArticle.d.ts +1 -1
- package/server/generated/typeStrings/NewsArticle.d.ts.map +1 -1
- package/server/generated/typeStrings/NewsArticle.js.map +1 -1
- package/server/generated/typeStrings/NewsArticle.mjs +0 -405
- package/server/generated/typeStrings/NewsArticleAssetSentiment.d.ts +1 -1
- package/server/generated/typeStrings/NewsArticleAssetSentiment.d.ts.map +1 -1
- package/server/generated/typeStrings/NewsArticleAssetSentiment.js.map +1 -1
- package/server/generated/typeStrings/NewsArticleAssetSentiment.mjs +1 -543
- package/server/generated/typeStrings/Order.d.ts +1 -1
- package/server/generated/typeStrings/Order.d.ts.map +1 -1
- package/server/generated/typeStrings/Order.js.map +1 -1
- package/server/generated/typeStrings/Order.mjs +4 -1006
- package/server/generated/typeStrings/Position.d.ts +1 -1
- package/server/generated/typeStrings/Position.d.ts.map +1 -1
- package/server/generated/typeStrings/Position.js.map +1 -1
- package/server/generated/typeStrings/Position.mjs +1 -961
- package/server/generated/typeStrings/Session.d.ts +1 -1
- package/server/generated/typeStrings/Session.d.ts.map +1 -1
- package/server/generated/typeStrings/Session.js.map +1 -1
- package/server/generated/typeStrings/Session.mjs +33 -286
- package/server/generated/typeStrings/StopLoss.d.ts +1 -1
- package/server/generated/typeStrings/StopLoss.d.ts.map +1 -1
- package/server/generated/typeStrings/StopLoss.js.map +1 -1
- package/server/generated/typeStrings/StopLoss.mjs +7 -496
- package/server/generated/typeStrings/TakeProfit.d.ts +1 -1
- package/server/generated/typeStrings/TakeProfit.d.ts.map +1 -1
- package/server/generated/typeStrings/TakeProfit.js.map +1 -1
- package/server/generated/typeStrings/TakeProfit.mjs +7 -496
- package/server/generated/typeStrings/Trade.d.ts +1 -1
- package/server/generated/typeStrings/Trade.d.ts.map +1 -1
- package/server/generated/typeStrings/Trade.js.map +1 -1
- package/server/generated/typeStrings/Trade.mjs +38 -967
- package/server/generated/typeStrings/User.d.ts +1 -1
- package/server/generated/typeStrings/User.d.ts.map +1 -1
- package/server/generated/typeStrings/User.js.map +1 -1
- package/server/generated/typeStrings/User.mjs +4 -697
- package/server/generated/typeStrings/VerificationToken.d.ts +1 -1
- package/server/generated/typeStrings/VerificationToken.d.ts.map +1 -1
- package/server/generated/typeStrings/VerificationToken.js.map +1 -1
- package/server/generated/typeStrings/VerificationToken.mjs +1 -6
- package/server/generated/typeStrings/index.d.ts +17 -17
- package/server/generated/typegraphql-prisma/models/Trade.d.ts +1 -1
- package/server/generated/typegraphql-prisma/models/Trade.mjs +1 -1
- package/server/generated/typegraphql-prisma/resolvers/relations/Trade/TradeRelationsResolver.js.map +1 -1
- package/server/generated/typegraphql-prisma/resolvers/relations/Trade/TradeRelationsResolver.mjs +1 -1
@@ -19,457 +19,13 @@ export type Trade = {
|
|
19
19
|
signal: TradeSignal;
|
20
20
|
// Strategy used to execute the trade.
|
21
21
|
strategy: TradeStrategy;
|
22
|
-
// Analysis supporting the trade decision as markdown text. TYPESTRING.
|
23
|
-
analysis: string;
|
24
22
|
// summary of the trade decision (this should be a short description of the trade).
|
25
23
|
summary: string;
|
26
24
|
// Confidence level in the trade decision.
|
27
25
|
confidence: number;
|
28
|
-
// Timestamp when the trade was executed. TYPESTRING.
|
29
|
-
timestamp: Date;
|
30
26
|
// Current status of the trade.
|
31
27
|
status: TradeStatus;
|
32
|
-
// Relation to the
|
33
|
-
alpacaAccount: {
|
34
|
-
// The type of Alpaca account (PAPER or LIVE).
|
35
|
-
type: AlpacaAccountType;
|
36
|
-
// API key for authenticating requests to Alpaca. TYPESTRING.
|
37
|
-
APIKey: string;
|
38
|
-
// API secret for authenticating requests to Alpaca. TYPESTRING.
|
39
|
-
APISecret: string;
|
40
|
-
// JSON configuration settings for the Alpaca account.
|
41
|
-
configuration?: any;
|
42
|
-
// Indicates whether the market is currently open for trading.
|
43
|
-
marketOpen: boolean;
|
44
|
-
// Minimum order size for the account. TYPESTRING.
|
45
|
-
minOrderSize: number;
|
46
|
-
// Maximum order size for the account. TYPESTRING.
|
47
|
-
maxOrderSize: number;
|
48
|
-
// Minimum percentage change (from intraday high/low) to consider for a trade signal. TYPESTRING.
|
49
|
-
minPercentageChange: number;
|
50
|
-
// Volume threshold for a trade signal (minimum volume qualifier to consider an asset for trading). TYPESTRING.
|
51
|
-
volumeThreshold: number;
|
52
|
-
// Relation to the User model who owns this Alpaca account. TYPESTRING.
|
53
|
-
user: {
|
54
|
-
// The user's full name.
|
55
|
-
name?: string;
|
56
|
-
// The user's email address, must be unique.
|
57
|
-
email?: string;
|
58
|
-
// Timestamp when the user's email was verified. TYPESTRING.
|
59
|
-
emailVerified?: Date;
|
60
|
-
// URL to the user's profile image.
|
61
|
-
image?: string;
|
62
|
-
// The role assigned to the user, determining permissions.
|
63
|
-
role: UserRole;
|
64
|
-
// A short biography or description of the user.
|
65
|
-
bio?: string;
|
66
|
-
// The user's job title or position.
|
67
|
-
jobTitle?: string;
|
68
|
-
// The type of Alpaca account the user currently holds.
|
69
|
-
currentAccount: AlpacaAccountType;
|
70
|
-
// Relation to the Customer model. TYPESTRING. GQL.
|
71
|
-
customer?: {
|
72
|
-
// Name of the customer.
|
73
|
-
name?: string;
|
74
|
-
// Subscription plan the customer is enrolled in.
|
75
|
-
plan?: SubscriptionPlan;
|
76
|
-
// End date of the current billing period in Stripe.
|
77
|
-
stripeCurrentPeriodEnd?: Date;
|
78
|
-
};
|
79
|
-
// List of accounts associated with the user. TYPESTRING. GQL.
|
80
|
-
accounts: {
|
81
|
-
// Type of the account (e.g., OAuth provider).
|
82
|
-
type: string;
|
83
|
-
// Provider of the account (e.g., Google, GitHub).
|
84
|
-
provider: string;
|
85
|
-
// Refresh token for the external account, if applicable. TYPESTRING.
|
86
|
-
refresh_token?: string;
|
87
|
-
// Access token for the external account, if applicable. TYPESTRING.
|
88
|
-
access_token?: string;
|
89
|
-
// Expiration time of the access token.
|
90
|
-
expires_at?: number;
|
91
|
-
// Type of the token (e.g., Bearer).
|
92
|
-
token_type?: string;
|
93
|
-
// Scope of access granted by the token.
|
94
|
-
scope?: string;
|
95
|
-
// ID token for authentication, if applicable. TYPESTRING.
|
96
|
-
id_token?: string;
|
97
|
-
// State of the session associated with the account.
|
98
|
-
session_state?: string;
|
99
|
-
}[];
|
100
|
-
// List of sessions associated with the user. TYPESTRING. GQL.
|
101
|
-
sessions: {
|
102
|
-
// Token associated with the session for authentication. TYPESTRING.
|
103
|
-
sessionToken: string;
|
104
|
-
// Expiration date and time of the session.
|
105
|
-
expires: Date;
|
106
|
-
}[];
|
107
|
-
// List of authenticators for the user. TYPESTRING. GQL.
|
108
|
-
authenticators: {
|
109
|
-
// Unique credential ID for the authenticator. TYPESTRING.
|
110
|
-
credentialID: string;
|
111
|
-
// Public key associated with the authenticator. TYPESTRING.
|
112
|
-
publicKey: string;
|
113
|
-
// Counter for the number of authentication attempts. TYPESTRING.
|
114
|
-
counter: number;
|
115
|
-
}[];
|
116
|
-
// The subscription plan the user is enrolled in.
|
117
|
-
plan?: SubscriptionPlan;
|
118
|
-
// OpenAI API key for the user.
|
119
|
-
openaiAPIKey?: string;
|
120
|
-
// OpenAI API Language model selected by the user
|
121
|
-
openaiModel?: OpenaiModel;
|
122
|
-
};
|
123
|
-
// List of orders placed through this Alpaca account. TYPESTRING.
|
124
|
-
orders: {
|
125
|
-
// Quantity of the asset to be ordered.
|
126
|
-
qty?: number;
|
127
|
-
// Notional value of the order. Optional, used if qty is not provided. But importantly, either qty or notional must be provided.
|
128
|
-
notional?: number;
|
129
|
-
// Side of the order (BUY or SELL).
|
130
|
-
side: OrderSide;
|
131
|
-
// Type of order (market, limit, stop, stop_limit, trailing_stop).
|
132
|
-
type: OrderType;
|
133
|
-
// Order class for advanced order types (simple, bracket, oco, oso).
|
134
|
-
orderClass: OrderClass;
|
135
|
-
// Time in force for the order (day, gtc, opg, cls, ioc, fok).
|
136
|
-
timeInForce: TimeInForce;
|
137
|
-
// Must be a positive number and required for LIMIT or STOP_LIMIT orders. For take_profit, must be ≥ base_price + 0.01.
|
138
|
-
limitPrice?: number;
|
139
|
-
// Must be a positive number and required for STOP or STOP_LIMIT orders.
|
140
|
-
stopPrice?: number;
|
141
|
-
// Stop loss object required for bracket orders.
|
142
|
-
stopLoss?: {
|
143
|
-
// Must be a positive number. For SELL orders: stopPrice ≤ current market price. For BUY orders: stopPrice ≥ current market price.
|
144
|
-
stopPrice?: number;
|
145
|
-
// Must be a positive number and required if parent Order's type is STOP_LIMIT.
|
146
|
-
limitPrice?: number;
|
147
|
-
};
|
148
|
-
// Take profit object required for bracket orders.
|
149
|
-
takeProfit?: {
|
150
|
-
// Must be a positive number and ≥ base_price + 0.01.
|
151
|
-
limitPrice?: number;
|
152
|
-
// Typically not used in standard take profit orders. If used, must comply with Alpaca's specific requirements.
|
153
|
-
stopPrice?: number;
|
154
|
-
};
|
155
|
-
// Must be a positive number and required for TRAILING_STOP orders.
|
156
|
-
trailPrice?: number;
|
157
|
-
// Must be a positive number representing the percentage and required for TRAILING_STOP orders.
|
158
|
-
trailPercent?: number;
|
159
|
-
// Whether the order is eligible for extended hours.
|
160
|
-
extendedHours?: boolean;
|
161
|
-
// Current status of the order.
|
162
|
-
status: OrderStatus;
|
163
|
-
// Timestamp when the order was submitted.
|
164
|
-
submittedAt?: Date;
|
165
|
-
// Timestamp when the order was filled.
|
166
|
-
filledAt?: Date;
|
167
|
-
// Average price at which the order was filled.
|
168
|
-
filledAvgPrice?: number;
|
169
|
-
// The action this order is associated with. TYPESTRING. GQL.
|
170
|
-
action: {
|
171
|
-
// Sequence number of the action within the trade.
|
172
|
-
sequence: number;
|
173
|
-
// Type of trade action, defined by ActionType enum.
|
174
|
-
type: ActionType;
|
175
|
-
// Additional notes or comments about the action.
|
176
|
-
note: string;
|
177
|
-
// Current status of the trade action.
|
178
|
-
status: ActionStatus;
|
179
|
-
// Fees associated with the action.
|
180
|
-
fee?: number;
|
181
|
-
};
|
182
|
-
// The asset this order is for. TYPESTRING. GQL.
|
183
|
-
asset: {
|
184
|
-
// Ticker symbol of the asset, must be unique.
|
185
|
-
symbol: string;
|
186
|
-
// Full name of the asset, must be unique.
|
187
|
-
name: string;
|
188
|
-
// Type of the asset, defined by AssetType enum.
|
189
|
-
type: AssetType;
|
190
|
-
// URL to the asset's logo image. TYPESTRING.
|
191
|
-
logoUrl?: string;
|
192
|
-
// Description of the asset. TYPESTRING.
|
193
|
-
description?: string;
|
194
|
-
// Central Index Key for the asset. TYPESTRING.
|
195
|
-
cik?: string;
|
196
|
-
// Stock exchange where the asset is listed. TYPESTRING.
|
197
|
-
exchange?: string;
|
198
|
-
// Currency in which the asset is traded. TYPESTRING.
|
199
|
-
currency?: string;
|
200
|
-
// Country where the asset is based. TYPESTRING.
|
201
|
-
country?: string;
|
202
|
-
// Sector classification of the asset. TYPESTRING.
|
203
|
-
sector?: string;
|
204
|
-
// Industry classification of the asset. TYPESTRING.
|
205
|
-
industry?: string;
|
206
|
-
// Physical address associated with the asset. TYPESTRING.
|
207
|
-
address?: string;
|
208
|
-
// Official website of the asset. TYPESTRING.
|
209
|
-
officialSite?: string;
|
210
|
-
// Fiscal year-end date of the asset. TYPESTRING.
|
211
|
-
fiscalYearEnd?: string;
|
212
|
-
// Date of the latest financial quarter. TYPESTRING.
|
213
|
-
latestQuarter?: string;
|
214
|
-
// Market capitalization of the asset. TYPESTRING.
|
215
|
-
marketCapitalization?: string;
|
216
|
-
// Earnings Before Interest, Taxes, Depreciation, and Amortization. TYPESTRING.
|
217
|
-
ebitda?: string;
|
218
|
-
// Price-to-Earnings ratio. TYPESTRING.
|
219
|
-
peRatio?: string;
|
220
|
-
// Price/Earnings to Growth ratio. TYPESTRING.
|
221
|
-
pegRatio?: string;
|
222
|
-
// Book value per share. TYPESTRING.
|
223
|
-
bookValue?: string;
|
224
|
-
// Dividend per share. TYPESTRING.
|
225
|
-
dividendPerShare?: string;
|
226
|
-
// Dividend yield percentage. TYPESTRING.
|
227
|
-
dividendYield?: string;
|
228
|
-
// Earnings per share. TYPESTRING.
|
229
|
-
eps?: string;
|
230
|
-
// Revenue per share over the trailing twelve months. TYPESTRING.
|
231
|
-
revenuePerShareTTM?: string;
|
232
|
-
// Profit margin percentage. TYPESTRING.
|
233
|
-
profitMargin?: string;
|
234
|
-
// Operating margin over the trailing twelve months. TYPESTRING.
|
235
|
-
operatingMarginTTM?: string;
|
236
|
-
// Return on assets over the trailing twelve months. TYPESTRING.
|
237
|
-
returnOnAssetsTTM?: string;
|
238
|
-
// Return on equity over the trailing twelve months. TYPESTRING.
|
239
|
-
returnOnEquityTTM?: string;
|
240
|
-
// Total revenue over the trailing twelve months. TYPESTRING.
|
241
|
-
revenueTTM?: string;
|
242
|
-
// Gross profit over the trailing twelve months. TYPESTRING.
|
243
|
-
grossProfitTTM?: string;
|
244
|
-
// Diluted earnings per share over the trailing twelve months. TYPESTRING.
|
245
|
-
dilutedEPSTTM?: string;
|
246
|
-
// Year-over-year growth in quarterly earnings. TYPESTRING.
|
247
|
-
quarterlyEarningsGrowthYOY?: string;
|
248
|
-
// Year-over-year growth in quarterly revenue. TYPESTRING.
|
249
|
-
quarterlyRevenueGrowthYOY?: string;
|
250
|
-
// Analyst target price for the asset. TYPESTRING.
|
251
|
-
analystTargetPrice?: string;
|
252
|
-
// Percentage of analysts rating the asset as Strong Buy. TYPESTRING.
|
253
|
-
analystRatingStrongBuy?: string;
|
254
|
-
// Percentage of analysts rating the asset as Buy. TYPESTRING.
|
255
|
-
analystRatingBuy?: string;
|
256
|
-
// Percentage of analysts rating the asset as Hold. TYPESTRING.
|
257
|
-
analystRatingHold?: string;
|
258
|
-
// Percentage of analysts rating the asset as Sell. TYPESTRING.
|
259
|
-
analystRatingSell?: string;
|
260
|
-
// Percentage of analysts rating the asset as Strong Sell. TYPESTRING.
|
261
|
-
analystRatingStrongSell?: string;
|
262
|
-
// Trailing Price-to-Earnings ratio. TYPESTRING.
|
263
|
-
trailingPE?: string;
|
264
|
-
// Forward Price-to-Earnings ratio. TYPESTRING.
|
265
|
-
forwardPE?: string;
|
266
|
-
// Price-to-Sales ratio over the trailing twelve months. TYPESTRING.
|
267
|
-
priceToSalesRatioTTM?: string;
|
268
|
-
// Price-to-Book ratio. TYPESTRING.
|
269
|
-
priceToBookRatio?: string;
|
270
|
-
// Enterprise Value to Revenue ratio. TYPESTRING.
|
271
|
-
evToRevenue?: string;
|
272
|
-
// Enterprise Value to EBITDA ratio. TYPESTRING.
|
273
|
-
evToEbitda?: string;
|
274
|
-
// Beta coefficient measuring volatility. TYPESTRING.
|
275
|
-
beta?: string;
|
276
|
-
// 52-week high price of the asset. TYPESTRING.
|
277
|
-
week52High?: string;
|
278
|
-
// 52-week low price of the asset. TYPESTRING.
|
279
|
-
week52Low?: string;
|
280
|
-
// 50-day moving average price. TYPESTRING.
|
281
|
-
day50MovingAverage?: string;
|
282
|
-
// 200-day moving average price. TYPESTRING.
|
283
|
-
day200MovingAverage?: string;
|
284
|
-
// Total number of shares outstanding. TYPESTRING.
|
285
|
-
sharesOutstanding?: string;
|
286
|
-
// Date when the next dividend is paid. TYPESTRING.
|
287
|
-
dividendDate?: string;
|
288
|
-
// Date when the asset goes ex-dividend. TYPESTRING.
|
289
|
-
exDividendDate?: string;
|
290
|
-
// Last ask price of the asset. TYPESTRING.
|
291
|
-
askPrice?: string;
|
292
|
-
// Last bid price of the asset. TYPESTRING.
|
293
|
-
bidPrice?: string;
|
294
|
-
// List of positions involving this asset. TYPESTRING. GQL.
|
295
|
-
positions: {
|
296
|
-
any
|
297
|
-
}[];
|
298
|
-
// List of news article sentiments related to this asset. TYPESTRING. GQL.
|
299
|
-
newsMentions: {
|
300
|
-
any
|
301
|
-
}[];
|
302
|
-
};
|
303
|
-
// Fee associated with the order.
|
304
|
-
fee?: number;
|
305
|
-
// Strike price for option orders.
|
306
|
-
strikePrice?: number;
|
307
|
-
// Expiration date for option orders.
|
308
|
-
expirationDate?: Date;
|
309
|
-
// If the asset.type is OPTION, then provide type of contract (CALL or PUT).
|
310
|
-
optionType?: OptionType;
|
311
|
-
}[];
|
312
|
-
// List of positions held in this Alpaca account. TYPESTRING. GQL.
|
313
|
-
positions: {
|
314
|
-
// Relation to the Asset model. TYPESTRING. GQL.
|
315
|
-
asset: {
|
316
|
-
// Ticker symbol of the asset, must be unique.
|
317
|
-
symbol: string;
|
318
|
-
// Full name of the asset, must be unique.
|
319
|
-
name: string;
|
320
|
-
// Type of the asset, defined by AssetType enum.
|
321
|
-
type: AssetType;
|
322
|
-
// URL to the asset's logo image. TYPESTRING.
|
323
|
-
logoUrl?: string;
|
324
|
-
// Description of the asset. TYPESTRING.
|
325
|
-
description?: string;
|
326
|
-
// Central Index Key for the asset. TYPESTRING.
|
327
|
-
cik?: string;
|
328
|
-
// Stock exchange where the asset is listed. TYPESTRING.
|
329
|
-
exchange?: string;
|
330
|
-
// Currency in which the asset is traded. TYPESTRING.
|
331
|
-
currency?: string;
|
332
|
-
// Country where the asset is based. TYPESTRING.
|
333
|
-
country?: string;
|
334
|
-
// Sector classification of the asset. TYPESTRING.
|
335
|
-
sector?: string;
|
336
|
-
// Industry classification of the asset. TYPESTRING.
|
337
|
-
industry?: string;
|
338
|
-
// Physical address associated with the asset. TYPESTRING.
|
339
|
-
address?: string;
|
340
|
-
// Official website of the asset. TYPESTRING.
|
341
|
-
officialSite?: string;
|
342
|
-
// Fiscal year-end date of the asset. TYPESTRING.
|
343
|
-
fiscalYearEnd?: string;
|
344
|
-
// Date of the latest financial quarter. TYPESTRING.
|
345
|
-
latestQuarter?: string;
|
346
|
-
// Market capitalization of the asset. TYPESTRING.
|
347
|
-
marketCapitalization?: string;
|
348
|
-
// Earnings Before Interest, Taxes, Depreciation, and Amortization. TYPESTRING.
|
349
|
-
ebitda?: string;
|
350
|
-
// Price-to-Earnings ratio. TYPESTRING.
|
351
|
-
peRatio?: string;
|
352
|
-
// Price/Earnings to Growth ratio. TYPESTRING.
|
353
|
-
pegRatio?: string;
|
354
|
-
// Book value per share. TYPESTRING.
|
355
|
-
bookValue?: string;
|
356
|
-
// Dividend per share. TYPESTRING.
|
357
|
-
dividendPerShare?: string;
|
358
|
-
// Dividend yield percentage. TYPESTRING.
|
359
|
-
dividendYield?: string;
|
360
|
-
// Earnings per share. TYPESTRING.
|
361
|
-
eps?: string;
|
362
|
-
// Revenue per share over the trailing twelve months. TYPESTRING.
|
363
|
-
revenuePerShareTTM?: string;
|
364
|
-
// Profit margin percentage. TYPESTRING.
|
365
|
-
profitMargin?: string;
|
366
|
-
// Operating margin over the trailing twelve months. TYPESTRING.
|
367
|
-
operatingMarginTTM?: string;
|
368
|
-
// Return on assets over the trailing twelve months. TYPESTRING.
|
369
|
-
returnOnAssetsTTM?: string;
|
370
|
-
// Return on equity over the trailing twelve months. TYPESTRING.
|
371
|
-
returnOnEquityTTM?: string;
|
372
|
-
// Total revenue over the trailing twelve months. TYPESTRING.
|
373
|
-
revenueTTM?: string;
|
374
|
-
// Gross profit over the trailing twelve months. TYPESTRING.
|
375
|
-
grossProfitTTM?: string;
|
376
|
-
// Diluted earnings per share over the trailing twelve months. TYPESTRING.
|
377
|
-
dilutedEPSTTM?: string;
|
378
|
-
// Year-over-year growth in quarterly earnings. TYPESTRING.
|
379
|
-
quarterlyEarningsGrowthYOY?: string;
|
380
|
-
// Year-over-year growth in quarterly revenue. TYPESTRING.
|
381
|
-
quarterlyRevenueGrowthYOY?: string;
|
382
|
-
// Analyst target price for the asset. TYPESTRING.
|
383
|
-
analystTargetPrice?: string;
|
384
|
-
// Percentage of analysts rating the asset as Strong Buy. TYPESTRING.
|
385
|
-
analystRatingStrongBuy?: string;
|
386
|
-
// Percentage of analysts rating the asset as Buy. TYPESTRING.
|
387
|
-
analystRatingBuy?: string;
|
388
|
-
// Percentage of analysts rating the asset as Hold. TYPESTRING.
|
389
|
-
analystRatingHold?: string;
|
390
|
-
// Percentage of analysts rating the asset as Sell. TYPESTRING.
|
391
|
-
analystRatingSell?: string;
|
392
|
-
// Percentage of analysts rating the asset as Strong Sell. TYPESTRING.
|
393
|
-
analystRatingStrongSell?: string;
|
394
|
-
// Trailing Price-to-Earnings ratio. TYPESTRING.
|
395
|
-
trailingPE?: string;
|
396
|
-
// Forward Price-to-Earnings ratio. TYPESTRING.
|
397
|
-
forwardPE?: string;
|
398
|
-
// Price-to-Sales ratio over the trailing twelve months. TYPESTRING.
|
399
|
-
priceToSalesRatioTTM?: string;
|
400
|
-
// Price-to-Book ratio. TYPESTRING.
|
401
|
-
priceToBookRatio?: string;
|
402
|
-
// Enterprise Value to Revenue ratio. TYPESTRING.
|
403
|
-
evToRevenue?: string;
|
404
|
-
// Enterprise Value to EBITDA ratio. TYPESTRING.
|
405
|
-
evToEbitda?: string;
|
406
|
-
// Beta coefficient measuring volatility. TYPESTRING.
|
407
|
-
beta?: string;
|
408
|
-
// 52-week high price of the asset. TYPESTRING.
|
409
|
-
week52High?: string;
|
410
|
-
// 52-week low price of the asset. TYPESTRING.
|
411
|
-
week52Low?: string;
|
412
|
-
// 50-day moving average price. TYPESTRING.
|
413
|
-
day50MovingAverage?: string;
|
414
|
-
// 200-day moving average price. TYPESTRING.
|
415
|
-
day200MovingAverage?: string;
|
416
|
-
// Total number of shares outstanding. TYPESTRING.
|
417
|
-
sharesOutstanding?: string;
|
418
|
-
// Date when the next dividend is paid. TYPESTRING.
|
419
|
-
dividendDate?: string;
|
420
|
-
// Date when the asset goes ex-dividend. TYPESTRING.
|
421
|
-
exDividendDate?: string;
|
422
|
-
// Last ask price of the asset. TYPESTRING.
|
423
|
-
askPrice?: string;
|
424
|
-
// Last bid price of the asset. TYPESTRING.
|
425
|
-
bidPrice?: string;
|
426
|
-
// List of orders involving this asset. TYPESTRING. GQL.
|
427
|
-
orders: {
|
428
|
-
any
|
429
|
-
}[];
|
430
|
-
// List of news article sentiments related to this asset. TYPESTRING. GQL.
|
431
|
-
newsMentions: {
|
432
|
-
any
|
433
|
-
}[];
|
434
|
-
};
|
435
|
-
// The average price at which the asset was acquired.
|
436
|
-
averageEntryPrice: number;
|
437
|
-
// Total quantity of the asset held.
|
438
|
-
qty: number;
|
439
|
-
// Quantity of the asset available for trading.
|
440
|
-
qtyAvailable: number;
|
441
|
-
// Current market value of the position.
|
442
|
-
marketValue: number;
|
443
|
-
// Total cost basis of the position.
|
444
|
-
costBasis: number;
|
445
|
-
// Unrealized profit or loss of the position.
|
446
|
-
unrealizedPL: number;
|
447
|
-
// Unrealized profit or loss as a percentage.
|
448
|
-
unrealizedPLPC: number;
|
449
|
-
// Unrealized intraday profit or loss.
|
450
|
-
unrealisedIntradayPL: number;
|
451
|
-
// Unrealized intraday profit or loss as a percentage.
|
452
|
-
unrealisedIntradayPLPC: number;
|
453
|
-
// Current price of the asset.
|
454
|
-
currentPrice: number;
|
455
|
-
// Last traded price of the asset.
|
456
|
-
lastTradePrice: number;
|
457
|
-
// Price change of the asset for the day.
|
458
|
-
changeToday: number;
|
459
|
-
// Indicates if the asset is marginable.
|
460
|
-
assetMarginable: boolean;
|
461
|
-
}[];
|
462
|
-
// List of alerts generated for this Alpaca account. TYPESTRING.
|
463
|
-
alerts: {
|
464
|
-
// Message content of the alert.
|
465
|
-
message: string;
|
466
|
-
// Type of the alert, defined by AlertType enum.
|
467
|
-
type: AlertType;
|
468
|
-
// Indicates whether the alert has been read by the user.
|
469
|
-
isRead: boolean;
|
470
|
-
}[];
|
471
|
-
};
|
472
|
-
// Relation to the Asset model. TYPESTRING. GQL.
|
28
|
+
// Relation to the Asset model.
|
473
29
|
asset: {
|
474
30
|
// Ticker symbol of the asset, must be unique.
|
475
31
|
symbol: string;
|
@@ -477,317 +33,8 @@ export type Trade = {
|
|
477
33
|
name: string;
|
478
34
|
// Type of the asset, defined by AssetType enum.
|
479
35
|
type: AssetType;
|
480
|
-
// URL to the asset's logo image. TYPESTRING.
|
481
|
-
logoUrl?: string;
|
482
|
-
// Description of the asset. TYPESTRING.
|
483
|
-
description?: string;
|
484
|
-
// Central Index Key for the asset. TYPESTRING.
|
485
|
-
cik?: string;
|
486
|
-
// Stock exchange where the asset is listed. TYPESTRING.
|
487
|
-
exchange?: string;
|
488
|
-
// Currency in which the asset is traded. TYPESTRING.
|
489
|
-
currency?: string;
|
490
|
-
// Country where the asset is based. TYPESTRING.
|
491
|
-
country?: string;
|
492
|
-
// Sector classification of the asset. TYPESTRING.
|
493
|
-
sector?: string;
|
494
|
-
// Industry classification of the asset. TYPESTRING.
|
495
|
-
industry?: string;
|
496
|
-
// Physical address associated with the asset. TYPESTRING.
|
497
|
-
address?: string;
|
498
|
-
// Official website of the asset. TYPESTRING.
|
499
|
-
officialSite?: string;
|
500
|
-
// Fiscal year-end date of the asset. TYPESTRING.
|
501
|
-
fiscalYearEnd?: string;
|
502
|
-
// Date of the latest financial quarter. TYPESTRING.
|
503
|
-
latestQuarter?: string;
|
504
|
-
// Market capitalization of the asset. TYPESTRING.
|
505
|
-
marketCapitalization?: string;
|
506
|
-
// Earnings Before Interest, Taxes, Depreciation, and Amortization. TYPESTRING.
|
507
|
-
ebitda?: string;
|
508
|
-
// Price-to-Earnings ratio. TYPESTRING.
|
509
|
-
peRatio?: string;
|
510
|
-
// Price/Earnings to Growth ratio. TYPESTRING.
|
511
|
-
pegRatio?: string;
|
512
|
-
// Book value per share. TYPESTRING.
|
513
|
-
bookValue?: string;
|
514
|
-
// Dividend per share. TYPESTRING.
|
515
|
-
dividendPerShare?: string;
|
516
|
-
// Dividend yield percentage. TYPESTRING.
|
517
|
-
dividendYield?: string;
|
518
|
-
// Earnings per share. TYPESTRING.
|
519
|
-
eps?: string;
|
520
|
-
// Revenue per share over the trailing twelve months. TYPESTRING.
|
521
|
-
revenuePerShareTTM?: string;
|
522
|
-
// Profit margin percentage. TYPESTRING.
|
523
|
-
profitMargin?: string;
|
524
|
-
// Operating margin over the trailing twelve months. TYPESTRING.
|
525
|
-
operatingMarginTTM?: string;
|
526
|
-
// Return on assets over the trailing twelve months. TYPESTRING.
|
527
|
-
returnOnAssetsTTM?: string;
|
528
|
-
// Return on equity over the trailing twelve months. TYPESTRING.
|
529
|
-
returnOnEquityTTM?: string;
|
530
|
-
// Total revenue over the trailing twelve months. TYPESTRING.
|
531
|
-
revenueTTM?: string;
|
532
|
-
// Gross profit over the trailing twelve months. TYPESTRING.
|
533
|
-
grossProfitTTM?: string;
|
534
|
-
// Diluted earnings per share over the trailing twelve months. TYPESTRING.
|
535
|
-
dilutedEPSTTM?: string;
|
536
|
-
// Year-over-year growth in quarterly earnings. TYPESTRING.
|
537
|
-
quarterlyEarningsGrowthYOY?: string;
|
538
|
-
// Year-over-year growth in quarterly revenue. TYPESTRING.
|
539
|
-
quarterlyRevenueGrowthYOY?: string;
|
540
|
-
// Analyst target price for the asset. TYPESTRING.
|
541
|
-
analystTargetPrice?: string;
|
542
|
-
// Percentage of analysts rating the asset as Strong Buy. TYPESTRING.
|
543
|
-
analystRatingStrongBuy?: string;
|
544
|
-
// Percentage of analysts rating the asset as Buy. TYPESTRING.
|
545
|
-
analystRatingBuy?: string;
|
546
|
-
// Percentage of analysts rating the asset as Hold. TYPESTRING.
|
547
|
-
analystRatingHold?: string;
|
548
|
-
// Percentage of analysts rating the asset as Sell. TYPESTRING.
|
549
|
-
analystRatingSell?: string;
|
550
|
-
// Percentage of analysts rating the asset as Strong Sell. TYPESTRING.
|
551
|
-
analystRatingStrongSell?: string;
|
552
|
-
// Trailing Price-to-Earnings ratio. TYPESTRING.
|
553
|
-
trailingPE?: string;
|
554
|
-
// Forward Price-to-Earnings ratio. TYPESTRING.
|
555
|
-
forwardPE?: string;
|
556
|
-
// Price-to-Sales ratio over the trailing twelve months. TYPESTRING.
|
557
|
-
priceToSalesRatioTTM?: string;
|
558
|
-
// Price-to-Book ratio. TYPESTRING.
|
559
|
-
priceToBookRatio?: string;
|
560
|
-
// Enterprise Value to Revenue ratio. TYPESTRING.
|
561
|
-
evToRevenue?: string;
|
562
|
-
// Enterprise Value to EBITDA ratio. TYPESTRING.
|
563
|
-
evToEbitda?: string;
|
564
|
-
// Beta coefficient measuring volatility. TYPESTRING.
|
565
|
-
beta?: string;
|
566
|
-
// 52-week high price of the asset. TYPESTRING.
|
567
|
-
week52High?: string;
|
568
|
-
// 52-week low price of the asset. TYPESTRING.
|
569
|
-
week52Low?: string;
|
570
|
-
// 50-day moving average price. TYPESTRING.
|
571
|
-
day50MovingAverage?: string;
|
572
|
-
// 200-day moving average price. TYPESTRING.
|
573
|
-
day200MovingAverage?: string;
|
574
|
-
// Total number of shares outstanding. TYPESTRING.
|
575
|
-
sharesOutstanding?: string;
|
576
|
-
// Date when the next dividend is paid. TYPESTRING.
|
577
|
-
dividendDate?: string;
|
578
|
-
// Date when the asset goes ex-dividend. TYPESTRING.
|
579
|
-
exDividendDate?: string;
|
580
|
-
// Last ask price of the asset. TYPESTRING.
|
581
|
-
askPrice?: string;
|
582
|
-
// Last bid price of the asset. TYPESTRING.
|
583
|
-
bidPrice?: string;
|
584
|
-
// List of orders involving this asset. TYPESTRING. GQL.
|
585
|
-
orders: {
|
586
|
-
// Quantity of the asset to be ordered.
|
587
|
-
qty?: number;
|
588
|
-
// Notional value of the order. Optional, used if qty is not provided. But importantly, either qty or notional must be provided.
|
589
|
-
notional?: number;
|
590
|
-
// Side of the order (BUY or SELL).
|
591
|
-
side: OrderSide;
|
592
|
-
// Type of order (market, limit, stop, stop_limit, trailing_stop).
|
593
|
-
type: OrderType;
|
594
|
-
// Order class for advanced order types (simple, bracket, oco, oso).
|
595
|
-
orderClass: OrderClass;
|
596
|
-
// Time in force for the order (day, gtc, opg, cls, ioc, fok).
|
597
|
-
timeInForce: TimeInForce;
|
598
|
-
// Must be a positive number and required for LIMIT or STOP_LIMIT orders. For take_profit, must be ≥ base_price + 0.01.
|
599
|
-
limitPrice?: number;
|
600
|
-
// Must be a positive number and required for STOP or STOP_LIMIT orders.
|
601
|
-
stopPrice?: number;
|
602
|
-
// Stop loss object required for bracket orders.
|
603
|
-
stopLoss?: {
|
604
|
-
// Must be a positive number. For SELL orders: stopPrice ≤ current market price. For BUY orders: stopPrice ≥ current market price.
|
605
|
-
stopPrice?: number;
|
606
|
-
// Must be a positive number and required if parent Order's type is STOP_LIMIT.
|
607
|
-
limitPrice?: number;
|
608
|
-
};
|
609
|
-
// Take profit object required for bracket orders.
|
610
|
-
takeProfit?: {
|
611
|
-
// Must be a positive number and ≥ base_price + 0.01.
|
612
|
-
limitPrice?: number;
|
613
|
-
// Typically not used in standard take profit orders. If used, must comply with Alpaca's specific requirements.
|
614
|
-
stopPrice?: number;
|
615
|
-
};
|
616
|
-
// Must be a positive number and required for TRAILING_STOP orders.
|
617
|
-
trailPrice?: number;
|
618
|
-
// Must be a positive number representing the percentage and required for TRAILING_STOP orders.
|
619
|
-
trailPercent?: number;
|
620
|
-
// Whether the order is eligible for extended hours.
|
621
|
-
extendedHours?: boolean;
|
622
|
-
// Current status of the order.
|
623
|
-
status: OrderStatus;
|
624
|
-
// Timestamp when the order was submitted.
|
625
|
-
submittedAt?: Date;
|
626
|
-
// Timestamp when the order was filled.
|
627
|
-
filledAt?: Date;
|
628
|
-
// Average price at which the order was filled.
|
629
|
-
filledAvgPrice?: number;
|
630
|
-
// The Alpaca account this order is associated with. TYPESTRING. GQL.
|
631
|
-
alpacaAccount: {
|
632
|
-
// The type of Alpaca account (PAPER or LIVE).
|
633
|
-
type: AlpacaAccountType;
|
634
|
-
// API key for authenticating requests to Alpaca. TYPESTRING.
|
635
|
-
APIKey: string;
|
636
|
-
// API secret for authenticating requests to Alpaca. TYPESTRING.
|
637
|
-
APISecret: string;
|
638
|
-
// JSON configuration settings for the Alpaca account.
|
639
|
-
configuration?: any;
|
640
|
-
// Indicates whether the market is currently open for trading.
|
641
|
-
marketOpen: boolean;
|
642
|
-
// Minimum order size for the account. TYPESTRING.
|
643
|
-
minOrderSize: number;
|
644
|
-
// Maximum order size for the account. TYPESTRING.
|
645
|
-
maxOrderSize: number;
|
646
|
-
// Minimum percentage change (from intraday high/low) to consider for a trade signal. TYPESTRING.
|
647
|
-
minPercentageChange: number;
|
648
|
-
// Volume threshold for a trade signal (minimum volume qualifier to consider an asset for trading). TYPESTRING.
|
649
|
-
volumeThreshold: number;
|
650
|
-
// Relation to the User model who owns this Alpaca account. TYPESTRING.
|
651
|
-
user: {
|
652
|
-
any
|
653
|
-
};
|
654
|
-
// List of positions held in this Alpaca account. TYPESTRING. GQL.
|
655
|
-
positions: {
|
656
|
-
any
|
657
|
-
}[];
|
658
|
-
// List of alerts generated for this Alpaca account. TYPESTRING.
|
659
|
-
alerts: {
|
660
|
-
any
|
661
|
-
}[];
|
662
|
-
};
|
663
|
-
// The action this order is associated with. TYPESTRING. GQL.
|
664
|
-
action: {
|
665
|
-
// Sequence number of the action within the trade.
|
666
|
-
sequence: number;
|
667
|
-
// Type of trade action, defined by ActionType enum.
|
668
|
-
type: ActionType;
|
669
|
-
// Additional notes or comments about the action.
|
670
|
-
note: string;
|
671
|
-
// Current status of the trade action.
|
672
|
-
status: ActionStatus;
|
673
|
-
// Fees associated with the action.
|
674
|
-
fee?: number;
|
675
|
-
};
|
676
|
-
// Fee associated with the order.
|
677
|
-
fee?: number;
|
678
|
-
// Strike price for option orders.
|
679
|
-
strikePrice?: number;
|
680
|
-
// Expiration date for option orders.
|
681
|
-
expirationDate?: Date;
|
682
|
-
// If the asset.type is OPTION, then provide type of contract (CALL or PUT).
|
683
|
-
optionType?: OptionType;
|
684
|
-
}[];
|
685
|
-
// List of positions involving this asset. TYPESTRING. GQL.
|
686
|
-
positions: {
|
687
|
-
// The average price at which the asset was acquired.
|
688
|
-
averageEntryPrice: number;
|
689
|
-
// Total quantity of the asset held.
|
690
|
-
qty: number;
|
691
|
-
// Quantity of the asset available for trading.
|
692
|
-
qtyAvailable: number;
|
693
|
-
// Current market value of the position.
|
694
|
-
marketValue: number;
|
695
|
-
// Total cost basis of the position.
|
696
|
-
costBasis: number;
|
697
|
-
// Unrealized profit or loss of the position.
|
698
|
-
unrealizedPL: number;
|
699
|
-
// Unrealized profit or loss as a percentage.
|
700
|
-
unrealizedPLPC: number;
|
701
|
-
// Unrealized intraday profit or loss.
|
702
|
-
unrealisedIntradayPL: number;
|
703
|
-
// Unrealized intraday profit or loss as a percentage.
|
704
|
-
unrealisedIntradayPLPC: number;
|
705
|
-
// Current price of the asset.
|
706
|
-
currentPrice: number;
|
707
|
-
// Last traded price of the asset.
|
708
|
-
lastTradePrice: number;
|
709
|
-
// Price change of the asset for the day.
|
710
|
-
changeToday: number;
|
711
|
-
// Indicates if the asset is marginable.
|
712
|
-
assetMarginable: boolean;
|
713
|
-
// Relation to the AlpacaAccount model, if applicable. TYPESTRING. GQL.
|
714
|
-
alpacaAccount?: {
|
715
|
-
// The type of Alpaca account (PAPER or LIVE).
|
716
|
-
type: AlpacaAccountType;
|
717
|
-
// API key for authenticating requests to Alpaca. TYPESTRING.
|
718
|
-
APIKey: string;
|
719
|
-
// API secret for authenticating requests to Alpaca. TYPESTRING.
|
720
|
-
APISecret: string;
|
721
|
-
// JSON configuration settings for the Alpaca account.
|
722
|
-
configuration?: any;
|
723
|
-
// Indicates whether the market is currently open for trading.
|
724
|
-
marketOpen: boolean;
|
725
|
-
// Minimum order size for the account. TYPESTRING.
|
726
|
-
minOrderSize: number;
|
727
|
-
// Maximum order size for the account. TYPESTRING.
|
728
|
-
maxOrderSize: number;
|
729
|
-
// Minimum percentage change (from intraday high/low) to consider for a trade signal. TYPESTRING.
|
730
|
-
minPercentageChange: number;
|
731
|
-
// Volume threshold for a trade signal (minimum volume qualifier to consider an asset for trading). TYPESTRING.
|
732
|
-
volumeThreshold: number;
|
733
|
-
// Relation to the User model who owns this Alpaca account. TYPESTRING.
|
734
|
-
user: {
|
735
|
-
any
|
736
|
-
};
|
737
|
-
// List of orders placed through this Alpaca account. TYPESTRING.
|
738
|
-
orders: {
|
739
|
-
any
|
740
|
-
}[];
|
741
|
-
// List of alerts generated for this Alpaca account. TYPESTRING.
|
742
|
-
alerts: {
|
743
|
-
any
|
744
|
-
}[];
|
745
|
-
};
|
746
|
-
}[];
|
747
|
-
// List of news article sentiments related to this asset. TYPESTRING. GQL.
|
748
|
-
newsMentions: {
|
749
|
-
// URL of the news article, must be unique.
|
750
|
-
url: string;
|
751
|
-
// Relation to the NewsArticle model. TYPESTRING. GQL.
|
752
|
-
news: {
|
753
|
-
// Title of the news article.
|
754
|
-
title: string;
|
755
|
-
// Full content of the news article.
|
756
|
-
content?: string;
|
757
|
-
// Source of the news article (e.g., Bloomberg, Reuters).
|
758
|
-
source: string;
|
759
|
-
// Domain of the source website.
|
760
|
-
sourceDomain?: string;
|
761
|
-
// URL to the original news article, must be unique.
|
762
|
-
url: string;
|
763
|
-
// Sentiment analysis result of the article.
|
764
|
-
sentiment: string;
|
765
|
-
// List of authors who wrote the article.
|
766
|
-
authors: string[];
|
767
|
-
// Summary or abstract of the news article.
|
768
|
-
summary?: string;
|
769
|
-
// URL to the banner image of the article.
|
770
|
-
bannerImage?: string;
|
771
|
-
// Publication time of the article.
|
772
|
-
timePublished: string;
|
773
|
-
// Category or genre of the news article.
|
774
|
-
category?: string;
|
775
|
-
// Topics covered in the news article.
|
776
|
-
topics: string[];
|
777
|
-
// URL to the logo image of the news source.
|
778
|
-
logo?: string;
|
779
|
-
// List of asset sentiments related to this news article. TYPESTRING. GQL.
|
780
|
-
assets: NewsArticleAssetSentiment[];
|
781
|
-
};
|
782
|
-
// Relevancy score indicating how relevant the news is to the asset.
|
783
|
-
relevancyScore?: string;
|
784
|
-
// Sentiment score derived from the news content.
|
785
|
-
sentimentScore?: string;
|
786
|
-
// Label indicating the overall sentiment (e.g., Positive, Negative, Neutral).
|
787
|
-
sentimentLabel?: string;
|
788
|
-
}[];
|
789
36
|
};
|
790
|
-
// List of actions associated with this trade.
|
37
|
+
// List of actions associated with this trade.
|
791
38
|
actions: {
|
792
39
|
// Sequence number of the action within the trade.
|
793
40
|
sequence: number;
|
@@ -799,7 +46,7 @@ export type Trade = {
|
|
799
46
|
status: ActionStatus;
|
800
47
|
// Fees associated with the action.
|
801
48
|
fee?: number;
|
802
|
-
// The order associated with this action.
|
49
|
+
// The order associated with this action.
|
803
50
|
order?: {
|
804
51
|
// Quantity of the asset to be ordered.
|
805
52
|
qty?: number;
|
@@ -845,40 +92,7 @@ export type Trade = {
|
|
845
92
|
filledAt?: Date;
|
846
93
|
// Average price at which the order was filled.
|
847
94
|
filledAvgPrice?: number;
|
848
|
-
// The
|
849
|
-
alpacaAccount: {
|
850
|
-
// The type of Alpaca account (PAPER or LIVE).
|
851
|
-
type: AlpacaAccountType;
|
852
|
-
// API key for authenticating requests to Alpaca. TYPESTRING.
|
853
|
-
APIKey: string;
|
854
|
-
// API secret for authenticating requests to Alpaca. TYPESTRING.
|
855
|
-
APISecret: string;
|
856
|
-
// JSON configuration settings for the Alpaca account.
|
857
|
-
configuration?: any;
|
858
|
-
// Indicates whether the market is currently open for trading.
|
859
|
-
marketOpen: boolean;
|
860
|
-
// Minimum order size for the account. TYPESTRING.
|
861
|
-
minOrderSize: number;
|
862
|
-
// Maximum order size for the account. TYPESTRING.
|
863
|
-
maxOrderSize: number;
|
864
|
-
// Minimum percentage change (from intraday high/low) to consider for a trade signal. TYPESTRING.
|
865
|
-
minPercentageChange: number;
|
866
|
-
// Volume threshold for a trade signal (minimum volume qualifier to consider an asset for trading). TYPESTRING.
|
867
|
-
volumeThreshold: number;
|
868
|
-
// Relation to the User model who owns this Alpaca account. TYPESTRING.
|
869
|
-
user: {
|
870
|
-
any
|
871
|
-
};
|
872
|
-
// List of positions held in this Alpaca account. TYPESTRING. GQL.
|
873
|
-
positions: {
|
874
|
-
any
|
875
|
-
}[];
|
876
|
-
// List of alerts generated for this Alpaca account. TYPESTRING.
|
877
|
-
alerts: {
|
878
|
-
any
|
879
|
-
}[];
|
880
|
-
};
|
881
|
-
// The asset this order is for. TYPESTRING. GQL.
|
95
|
+
// The asset this order is for.
|
882
96
|
asset: {
|
883
97
|
// Ticker symbol of the asset, must be unique.
|
884
98
|
symbol: string;
|
@@ -886,118 +100,6 @@ export type Trade = {
|
|
886
100
|
name: string;
|
887
101
|
// Type of the asset, defined by AssetType enum.
|
888
102
|
type: AssetType;
|
889
|
-
// URL to the asset's logo image. TYPESTRING.
|
890
|
-
logoUrl?: string;
|
891
|
-
// Description of the asset. TYPESTRING.
|
892
|
-
description?: string;
|
893
|
-
// Central Index Key for the asset. TYPESTRING.
|
894
|
-
cik?: string;
|
895
|
-
// Stock exchange where the asset is listed. TYPESTRING.
|
896
|
-
exchange?: string;
|
897
|
-
// Currency in which the asset is traded. TYPESTRING.
|
898
|
-
currency?: string;
|
899
|
-
// Country where the asset is based. TYPESTRING.
|
900
|
-
country?: string;
|
901
|
-
// Sector classification of the asset. TYPESTRING.
|
902
|
-
sector?: string;
|
903
|
-
// Industry classification of the asset. TYPESTRING.
|
904
|
-
industry?: string;
|
905
|
-
// Physical address associated with the asset. TYPESTRING.
|
906
|
-
address?: string;
|
907
|
-
// Official website of the asset. TYPESTRING.
|
908
|
-
officialSite?: string;
|
909
|
-
// Fiscal year-end date of the asset. TYPESTRING.
|
910
|
-
fiscalYearEnd?: string;
|
911
|
-
// Date of the latest financial quarter. TYPESTRING.
|
912
|
-
latestQuarter?: string;
|
913
|
-
// Market capitalization of the asset. TYPESTRING.
|
914
|
-
marketCapitalization?: string;
|
915
|
-
// Earnings Before Interest, Taxes, Depreciation, and Amortization. TYPESTRING.
|
916
|
-
ebitda?: string;
|
917
|
-
// Price-to-Earnings ratio. TYPESTRING.
|
918
|
-
peRatio?: string;
|
919
|
-
// Price/Earnings to Growth ratio. TYPESTRING.
|
920
|
-
pegRatio?: string;
|
921
|
-
// Book value per share. TYPESTRING.
|
922
|
-
bookValue?: string;
|
923
|
-
// Dividend per share. TYPESTRING.
|
924
|
-
dividendPerShare?: string;
|
925
|
-
// Dividend yield percentage. TYPESTRING.
|
926
|
-
dividendYield?: string;
|
927
|
-
// Earnings per share. TYPESTRING.
|
928
|
-
eps?: string;
|
929
|
-
// Revenue per share over the trailing twelve months. TYPESTRING.
|
930
|
-
revenuePerShareTTM?: string;
|
931
|
-
// Profit margin percentage. TYPESTRING.
|
932
|
-
profitMargin?: string;
|
933
|
-
// Operating margin over the trailing twelve months. TYPESTRING.
|
934
|
-
operatingMarginTTM?: string;
|
935
|
-
// Return on assets over the trailing twelve months. TYPESTRING.
|
936
|
-
returnOnAssetsTTM?: string;
|
937
|
-
// Return on equity over the trailing twelve months. TYPESTRING.
|
938
|
-
returnOnEquityTTM?: string;
|
939
|
-
// Total revenue over the trailing twelve months. TYPESTRING.
|
940
|
-
revenueTTM?: string;
|
941
|
-
// Gross profit over the trailing twelve months. TYPESTRING.
|
942
|
-
grossProfitTTM?: string;
|
943
|
-
// Diluted earnings per share over the trailing twelve months. TYPESTRING.
|
944
|
-
dilutedEPSTTM?: string;
|
945
|
-
// Year-over-year growth in quarterly earnings. TYPESTRING.
|
946
|
-
quarterlyEarningsGrowthYOY?: string;
|
947
|
-
// Year-over-year growth in quarterly revenue. TYPESTRING.
|
948
|
-
quarterlyRevenueGrowthYOY?: string;
|
949
|
-
// Analyst target price for the asset. TYPESTRING.
|
950
|
-
analystTargetPrice?: string;
|
951
|
-
// Percentage of analysts rating the asset as Strong Buy. TYPESTRING.
|
952
|
-
analystRatingStrongBuy?: string;
|
953
|
-
// Percentage of analysts rating the asset as Buy. TYPESTRING.
|
954
|
-
analystRatingBuy?: string;
|
955
|
-
// Percentage of analysts rating the asset as Hold. TYPESTRING.
|
956
|
-
analystRatingHold?: string;
|
957
|
-
// Percentage of analysts rating the asset as Sell. TYPESTRING.
|
958
|
-
analystRatingSell?: string;
|
959
|
-
// Percentage of analysts rating the asset as Strong Sell. TYPESTRING.
|
960
|
-
analystRatingStrongSell?: string;
|
961
|
-
// Trailing Price-to-Earnings ratio. TYPESTRING.
|
962
|
-
trailingPE?: string;
|
963
|
-
// Forward Price-to-Earnings ratio. TYPESTRING.
|
964
|
-
forwardPE?: string;
|
965
|
-
// Price-to-Sales ratio over the trailing twelve months. TYPESTRING.
|
966
|
-
priceToSalesRatioTTM?: string;
|
967
|
-
// Price-to-Book ratio. TYPESTRING.
|
968
|
-
priceToBookRatio?: string;
|
969
|
-
// Enterprise Value to Revenue ratio. TYPESTRING.
|
970
|
-
evToRevenue?: string;
|
971
|
-
// Enterprise Value to EBITDA ratio. TYPESTRING.
|
972
|
-
evToEbitda?: string;
|
973
|
-
// Beta coefficient measuring volatility. TYPESTRING.
|
974
|
-
beta?: string;
|
975
|
-
// 52-week high price of the asset. TYPESTRING.
|
976
|
-
week52High?: string;
|
977
|
-
// 52-week low price of the asset. TYPESTRING.
|
978
|
-
week52Low?: string;
|
979
|
-
// 50-day moving average price. TYPESTRING.
|
980
|
-
day50MovingAverage?: string;
|
981
|
-
// 200-day moving average price. TYPESTRING.
|
982
|
-
day200MovingAverage?: string;
|
983
|
-
// Total number of shares outstanding. TYPESTRING.
|
984
|
-
sharesOutstanding?: string;
|
985
|
-
// Date when the next dividend is paid. TYPESTRING.
|
986
|
-
dividendDate?: string;
|
987
|
-
// Date when the asset goes ex-dividend. TYPESTRING.
|
988
|
-
exDividendDate?: string;
|
989
|
-
// Last ask price of the asset. TYPESTRING.
|
990
|
-
askPrice?: string;
|
991
|
-
// Last bid price of the asset. TYPESTRING.
|
992
|
-
bidPrice?: string;
|
993
|
-
// List of positions involving this asset. TYPESTRING. GQL.
|
994
|
-
positions: {
|
995
|
-
any
|
996
|
-
}[];
|
997
|
-
// List of news article sentiments related to this asset. TYPESTRING. GQL.
|
998
|
-
newsMentions: {
|
999
|
-
any
|
1000
|
-
}[];
|
1001
103
|
};
|
1002
104
|
// Fee associated with the order.
|
1003
105
|
fee?: number;
|
@@ -1089,28 +191,44 @@ export enum TradeStatus {
|
|
1089
191
|
COMPLETED = "COMPLETED"
|
1090
192
|
}
|
1091
193
|
|
1092
|
-
export enum
|
1093
|
-
|
1094
|
-
|
1095
|
-
|
1096
|
-
|
1097
|
-
|
1098
|
-
|
1099
|
-
|
1100
|
-
|
194
|
+
export enum AssetType {
|
195
|
+
STOCK = "STOCK",
|
196
|
+
ETF = "ETF",
|
197
|
+
MUTUAL_FUND = "MUTUAL_FUND",
|
198
|
+
CRYPTOCURRENCY = "CRYPTOCURRENCY",
|
199
|
+
INDEX = "INDEX",
|
200
|
+
COMMODITY = "COMMODITY",
|
201
|
+
CURRENCY = "CURRENCY",
|
202
|
+
OPTION = "OPTION",
|
203
|
+
FUTURE = "FUTURE",
|
204
|
+
BOND = "BOND",
|
205
|
+
WARRANT = "WARRANT",
|
206
|
+
ADR = "ADR",
|
207
|
+
GDR = "GDR",
|
208
|
+
UNIT = "UNIT",
|
209
|
+
RIGHT = "RIGHT",
|
210
|
+
REIT = "REIT",
|
211
|
+
STRUCTURED_PRODUCT = "STRUCTURED_PRODUCT",
|
212
|
+
SWAP = "SWAP",
|
213
|
+
SPOT = "SPOT",
|
214
|
+
FORWARD = "FORWARD",
|
215
|
+
OTHER = "OTHER"
|
1101
216
|
}
|
1102
217
|
|
1103
|
-
export enum
|
1104
|
-
|
1105
|
-
|
1106
|
-
|
218
|
+
export enum ActionType {
|
219
|
+
BUY = "BUY",
|
220
|
+
BUY_OPTION = "BUY_OPTION",
|
221
|
+
EXERCISE_OPTION = "EXERCISE_OPTION",
|
222
|
+
SELL = "SELL",
|
223
|
+
CANCEL = "CANCEL",
|
224
|
+
ADJUST = "ADJUST",
|
225
|
+
HEDGE = "HEDGE"
|
1107
226
|
}
|
1108
227
|
|
1109
|
-
export enum
|
1110
|
-
|
1111
|
-
|
1112
|
-
|
1113
|
-
O1_MINI = "O1_MINI"
|
228
|
+
export enum ActionStatus {
|
229
|
+
STAGED = "STAGED",
|
230
|
+
EXECUTED = "EXECUTED",
|
231
|
+
COMPLETED = "COMPLETED"
|
1114
232
|
}
|
1115
233
|
|
1116
234
|
export enum OrderSide {
|
@@ -1164,52 +282,5 @@ export enum OrderStatus {
|
|
1164
282
|
CALCULATED = "CALCULATED"
|
1165
283
|
}
|
1166
284
|
|
1167
|
-
export enum ActionType {
|
1168
|
-
BUY = "BUY",
|
1169
|
-
BUY_OPTION = "BUY_OPTION",
|
1170
|
-
EXERCISE_OPTION = "EXERCISE_OPTION",
|
1171
|
-
SELL = "SELL",
|
1172
|
-
CANCEL = "CANCEL",
|
1173
|
-
ADJUST = "ADJUST",
|
1174
|
-
HEDGE = "HEDGE"
|
1175
|
-
}
|
1176
|
-
|
1177
|
-
export enum ActionStatus {
|
1178
|
-
STAGED = "STAGED",
|
1179
|
-
EXECUTED = "EXECUTED",
|
1180
|
-
COMPLETED = "COMPLETED"
|
1181
|
-
}
|
1182
|
-
|
1183
|
-
export enum AssetType {
|
1184
|
-
STOCK = "STOCK",
|
1185
|
-
ETF = "ETF",
|
1186
|
-
MUTUAL_FUND = "MUTUAL_FUND",
|
1187
|
-
CRYPTOCURRENCY = "CRYPTOCURRENCY",
|
1188
|
-
INDEX = "INDEX",
|
1189
|
-
COMMODITY = "COMMODITY",
|
1190
|
-
CURRENCY = "CURRENCY",
|
1191
|
-
OPTION = "OPTION",
|
1192
|
-
FUTURE = "FUTURE",
|
1193
|
-
BOND = "BOND",
|
1194
|
-
WARRANT = "WARRANT",
|
1195
|
-
ADR = "ADR",
|
1196
|
-
GDR = "GDR",
|
1197
|
-
UNIT = "UNIT",
|
1198
|
-
RIGHT = "RIGHT",
|
1199
|
-
REIT = "REIT",
|
1200
|
-
STRUCTURED_PRODUCT = "STRUCTURED_PRODUCT",
|
1201
|
-
SWAP = "SWAP",
|
1202
|
-
SPOT = "SPOT",
|
1203
|
-
FORWARD = "FORWARD",
|
1204
|
-
OTHER = "OTHER"
|
1205
|
-
}
|
1206
|
-
|
1207
|
-
export enum AlertType {
|
1208
|
-
SUCCESS = "SUCCESS",
|
1209
|
-
WARNING = "WARNING",
|
1210
|
-
ERROR = "ERROR",
|
1211
|
-
INFO = "INFO"
|
1212
|
-
}
|
1213
|
-
|
1214
285
|
`;
|
1215
286
|
//# sourceMappingURL=Trade.js.map
|