adaptic-backend 1.0.159 → 1.0.161

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.
Files changed (65) hide show
  1. package/Account.cjs +285 -8
  2. package/Action.cjs +615 -4
  3. package/Alert.cjs +338 -4
  4. package/AlpacaAccount.cjs +771 -4
  5. package/Asset.cjs +642 -0
  6. package/Authenticator.cjs +288 -4
  7. package/Customer.cjs +273 -10
  8. package/NewsArticle.cjs +165 -0
  9. package/NewsArticleAssetSentiment.cjs +256 -8
  10. package/Order.cjs +510 -10
  11. package/Position.cjs +546 -8
  12. package/Session.cjs +288 -4
  13. package/StopLoss.cjs +348 -1
  14. package/TakeProfit.cjs +348 -1
  15. package/Trade.cjs +607 -8
  16. package/User.cjs +261 -0
  17. package/package.json +1 -1
  18. package/server/Account.d.ts.map +1 -1
  19. package/server/Account.js.map +1 -1
  20. package/server/Account.mjs +285 -8
  21. package/server/Action.d.ts.map +1 -1
  22. package/server/Action.js.map +1 -1
  23. package/server/Action.mjs +615 -4
  24. package/server/Alert.d.ts.map +1 -1
  25. package/server/Alert.js.map +1 -1
  26. package/server/Alert.mjs +338 -4
  27. package/server/AlpacaAccount.d.ts.map +1 -1
  28. package/server/AlpacaAccount.js.map +1 -1
  29. package/server/AlpacaAccount.mjs +771 -4
  30. package/server/Asset.d.ts.map +1 -1
  31. package/server/Asset.js.map +1 -1
  32. package/server/Asset.mjs +642 -0
  33. package/server/Authenticator.d.ts.map +1 -1
  34. package/server/Authenticator.js.map +1 -1
  35. package/server/Authenticator.mjs +288 -4
  36. package/server/Customer.d.ts.map +1 -1
  37. package/server/Customer.js.map +1 -1
  38. package/server/Customer.mjs +273 -10
  39. package/server/NewsArticle.d.ts.map +1 -1
  40. package/server/NewsArticle.js.map +1 -1
  41. package/server/NewsArticle.mjs +165 -0
  42. package/server/NewsArticleAssetSentiment.d.ts.map +1 -1
  43. package/server/NewsArticleAssetSentiment.js.map +1 -1
  44. package/server/NewsArticleAssetSentiment.mjs +256 -8
  45. package/server/Order.d.ts.map +1 -1
  46. package/server/Order.js.map +1 -1
  47. package/server/Order.mjs +510 -10
  48. package/server/Position.d.ts.map +1 -1
  49. package/server/Position.js.map +1 -1
  50. package/server/Position.mjs +546 -8
  51. package/server/Session.d.ts.map +1 -1
  52. package/server/Session.js.map +1 -1
  53. package/server/Session.mjs +288 -4
  54. package/server/StopLoss.d.ts.map +1 -1
  55. package/server/StopLoss.js.map +1 -1
  56. package/server/StopLoss.mjs +348 -1
  57. package/server/TakeProfit.d.ts.map +1 -1
  58. package/server/TakeProfit.js.map +1 -1
  59. package/server/TakeProfit.mjs +348 -1
  60. package/server/Trade.d.ts.map +1 -1
  61. package/server/Trade.js.map +1 -1
  62. package/server/Trade.mjs +607 -8
  63. package/server/User.d.ts.map +1 -1
  64. package/server/User.js.map +1 -1
  65. package/server/User.mjs +261 -0
package/Order.cjs CHANGED
@@ -229,6 +229,7 @@ exports.Order = {
229
229
  : { connectOrCreate: {
230
230
  where: {
231
231
  id: props.stopLoss.id !== undefined ? props.stopLoss.id : undefined,
232
+ orderId: props.stopLoss.orderId !== undefined ? props.stopLoss.orderId : undefined,
232
233
  },
233
234
  create: {
234
235
  stopPrice: props.stopLoss.stopPrice !== undefined ? props.stopLoss.stopPrice : undefined,
@@ -245,6 +246,7 @@ exports.Order = {
245
246
  : { connectOrCreate: {
246
247
  where: {
247
248
  id: props.takeProfit.id !== undefined ? props.takeProfit.id : undefined,
249
+ orderId: props.takeProfit.orderId !== undefined ? props.takeProfit.orderId : undefined,
248
250
  },
249
251
  create: {
250
252
  limitPrice: props.takeProfit.limitPrice !== undefined ? props.takeProfit.limitPrice : undefined,
@@ -261,6 +263,9 @@ exports.Order = {
261
263
  : { connectOrCreate: {
262
264
  where: {
263
265
  id: props.alpacaAccount.id !== undefined ? props.alpacaAccount.id : undefined,
266
+ userId: props.alpacaAccount.userId !== undefined ? {
267
+ equals: props.alpacaAccount.userId
268
+ } : undefined,
264
269
  },
265
270
  create: {
266
271
  type: props.alpacaAccount.type !== undefined ? props.alpacaAccount.type : undefined,
@@ -307,9 +312,17 @@ exports.Order = {
307
312
  : { connectOrCreate: {
308
313
  where: {
309
314
  id: props.alpacaAccount.user.customer.id !== undefined ? props.alpacaAccount.user.customer.id : undefined,
315
+ stripeCustomerId: props.alpacaAccount.user.customer.stripeCustomerId !== undefined ? props.alpacaAccount.user.customer.stripeCustomerId : undefined,
316
+ stripeSubscriptionId: props.alpacaAccount.user.customer.stripeSubscriptionId !== undefined ? props.alpacaAccount.user.customer.stripeSubscriptionId : undefined,
317
+ authUserId: props.alpacaAccount.user.customer.authUserId !== undefined ? {
318
+ equals: props.alpacaAccount.user.customer.authUserId
319
+ } : undefined,
310
320
  name: props.alpacaAccount.user.customer.name !== undefined ? {
311
321
  equals: props.alpacaAccount.user.customer.name
312
322
  } : undefined,
323
+ stripePriceId: props.alpacaAccount.user.customer.stripePriceId !== undefined ? {
324
+ equals: props.alpacaAccount.user.customer.stripePriceId
325
+ } : undefined,
313
326
  },
314
327
  create: {
315
328
  authUserId: props.alpacaAccount.user.customer.authUserId !== undefined ? props.alpacaAccount.user.customer.authUserId : undefined,
@@ -331,6 +344,12 @@ exports.Order = {
331
344
  : { connectOrCreate: props.alpacaAccount.user.accounts.map((item) => ({
332
345
  where: {
333
346
  id: item.id !== undefined ? item.id : undefined,
347
+ userId: item.userId !== undefined ? {
348
+ equals: item.userId
349
+ } : undefined,
350
+ providerAccountId: item.providerAccountId !== undefined ? {
351
+ equals: item.providerAccountId
352
+ } : undefined,
334
353
  },
335
354
  create: {
336
355
  type: item.type !== undefined ? item.type : undefined,
@@ -355,6 +374,9 @@ exports.Order = {
355
374
  : { connectOrCreate: props.alpacaAccount.user.sessions.map((item) => ({
356
375
  where: {
357
376
  id: item.id !== undefined ? item.id : undefined,
377
+ userId: item.userId !== undefined ? {
378
+ equals: item.userId
379
+ } : undefined,
358
380
  },
359
381
  create: {
360
382
  sessionToken: item.sessionToken !== undefined ? item.sessionToken : undefined,
@@ -371,6 +393,9 @@ exports.Order = {
371
393
  : { connectOrCreate: props.alpacaAccount.user.authenticators.map((item) => ({
372
394
  where: {
373
395
  id: item.id !== undefined ? item.id : undefined,
396
+ userId: item.userId !== undefined ? {
397
+ equals: item.userId
398
+ } : undefined,
374
399
  },
375
400
  create: {
376
401
  credentialID: item.credentialID !== undefined ? item.credentialID : undefined,
@@ -391,6 +416,12 @@ exports.Order = {
391
416
  : { connectOrCreate: props.alpacaAccount.trades.map((item) => ({
392
417
  where: {
393
418
  id: item.id !== undefined ? item.id : undefined,
419
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
420
+ equals: item.alpacaAccountId
421
+ } : undefined,
422
+ assetId: item.assetId !== undefined ? {
423
+ equals: item.assetId
424
+ } : undefined,
394
425
  },
395
426
  create: {
396
427
  qty: item.qty !== undefined ? item.qty : undefined,
@@ -484,6 +515,9 @@ exports.Order = {
484
515
  : { connectOrCreate: item.actions.map((item) => ({
485
516
  where: {
486
517
  id: item.id !== undefined ? item.id : undefined,
518
+ tradeId: item.tradeId !== undefined ? {
519
+ equals: item.tradeId
520
+ } : undefined,
487
521
  },
488
522
  create: {
489
523
  sequence: item.sequence !== undefined ? item.sequence : undefined,
@@ -506,6 +540,12 @@ exports.Order = {
506
540
  : { connectOrCreate: props.alpacaAccount.positions.map((item) => ({
507
541
  where: {
508
542
  id: item.id !== undefined ? item.id : undefined,
543
+ assetId: item.assetId !== undefined ? {
544
+ equals: item.assetId
545
+ } : undefined,
546
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
547
+ equals: item.alpacaAccountId
548
+ } : undefined,
509
549
  },
510
550
  create: {
511
551
  averageEntryPrice: item.averageEntryPrice !== undefined ? item.averageEntryPrice : undefined,
@@ -604,6 +644,9 @@ exports.Order = {
604
644
  : { connectOrCreate: props.alpacaAccount.alerts.map((item) => ({
605
645
  where: {
606
646
  id: item.id !== undefined ? item.id : undefined,
647
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
648
+ equals: item.alpacaAccountId
649
+ } : undefined,
607
650
  },
608
651
  create: {
609
652
  message: item.message !== undefined ? item.message : undefined,
@@ -624,6 +667,9 @@ exports.Order = {
624
667
  : { connectOrCreate: {
625
668
  where: {
626
669
  id: props.action.id !== undefined ? props.action.id : undefined,
670
+ tradeId: props.action.tradeId !== undefined ? {
671
+ equals: props.action.tradeId
672
+ } : undefined,
627
673
  },
628
674
  create: {
629
675
  sequence: props.action.sequence !== undefined ? props.action.sequence : undefined,
@@ -640,6 +686,12 @@ exports.Order = {
640
686
  : { connectOrCreate: {
641
687
  where: {
642
688
  id: props.action.trade.id !== undefined ? props.action.trade.id : undefined,
689
+ alpacaAccountId: props.action.trade.alpacaAccountId !== undefined ? {
690
+ equals: props.action.trade.alpacaAccountId
691
+ } : undefined,
692
+ assetId: props.action.trade.assetId !== undefined ? {
693
+ equals: props.action.trade.assetId
694
+ } : undefined,
643
695
  },
644
696
  create: {
645
697
  qty: props.action.trade.qty !== undefined ? props.action.trade.qty : undefined,
@@ -662,6 +714,9 @@ exports.Order = {
662
714
  : { connectOrCreate: {
663
715
  where: {
664
716
  id: props.action.trade.alpacaAccount.id !== undefined ? props.action.trade.alpacaAccount.id : undefined,
717
+ userId: props.action.trade.alpacaAccount.userId !== undefined ? {
718
+ equals: props.action.trade.alpacaAccount.userId
719
+ } : undefined,
665
720
  },
666
721
  create: {
667
722
  type: props.action.trade.alpacaAccount.type !== undefined ? props.action.trade.alpacaAccount.type : undefined,
@@ -830,6 +885,12 @@ exports.Order = {
830
885
  : { connectOrCreate: props.asset.trades.map((item) => ({
831
886
  where: {
832
887
  id: item.id !== undefined ? item.id : undefined,
888
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
889
+ equals: item.alpacaAccountId
890
+ } : undefined,
891
+ assetId: item.assetId !== undefined ? {
892
+ equals: item.assetId
893
+ } : undefined,
833
894
  },
834
895
  create: {
835
896
  qty: item.qty !== undefined ? item.qty : undefined,
@@ -852,6 +913,9 @@ exports.Order = {
852
913
  : { connectOrCreate: {
853
914
  where: {
854
915
  id: item.alpacaAccount.id !== undefined ? item.alpacaAccount.id : undefined,
916
+ userId: item.alpacaAccount.userId !== undefined ? {
917
+ equals: item.alpacaAccount.userId
918
+ } : undefined,
855
919
  },
856
920
  create: {
857
921
  type: item.alpacaAccount.type !== undefined ? item.alpacaAccount.type : undefined,
@@ -875,6 +939,9 @@ exports.Order = {
875
939
  : { connectOrCreate: item.actions.map((item) => ({
876
940
  where: {
877
941
  id: item.id !== undefined ? item.id : undefined,
942
+ tradeId: item.tradeId !== undefined ? {
943
+ equals: item.tradeId
944
+ } : undefined,
878
945
  },
879
946
  create: {
880
947
  sequence: item.sequence !== undefined ? item.sequence : undefined,
@@ -897,6 +964,12 @@ exports.Order = {
897
964
  : { connectOrCreate: props.asset.positions.map((item) => ({
898
965
  where: {
899
966
  id: item.id !== undefined ? item.id : undefined,
967
+ assetId: item.assetId !== undefined ? {
968
+ equals: item.assetId
969
+ } : undefined,
970
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
971
+ equals: item.alpacaAccountId
972
+ } : undefined,
900
973
  },
901
974
  create: {
902
975
  averageEntryPrice: item.averageEntryPrice !== undefined ? item.averageEntryPrice : undefined,
@@ -921,6 +994,9 @@ exports.Order = {
921
994
  : { connectOrCreate: {
922
995
  where: {
923
996
  id: item.alpacaAccount.id !== undefined ? item.alpacaAccount.id : undefined,
997
+ userId: item.alpacaAccount.userId !== undefined ? {
998
+ equals: item.alpacaAccount.userId
999
+ } : undefined,
924
1000
  },
925
1001
  create: {
926
1002
  type: item.alpacaAccount.type !== undefined ? item.alpacaAccount.type : undefined,
@@ -948,6 +1024,12 @@ exports.Order = {
948
1024
  where: {
949
1025
  id: item.id !== undefined ? item.id : undefined,
950
1026
  url: item.url !== undefined ? item.url : undefined,
1027
+ assetId: item.assetId !== undefined ? {
1028
+ equals: item.assetId
1029
+ } : undefined,
1030
+ newsArticleId: item.newsArticleId !== undefined ? {
1031
+ equals: item.newsArticleId
1032
+ } : undefined,
951
1033
  },
952
1034
  create: {
953
1035
  url: item.url !== undefined ? item.url : undefined,
@@ -1088,8 +1170,12 @@ exports.Order = {
1088
1170
  clientOrderId: props.clientOrderId !== undefined ? props.clientOrderId : undefined,
1089
1171
  actionId: props.actionId !== undefined ? props.actionId : undefined,
1090
1172
  stopLossId: props.stopLossId !== undefined ? props.stopLossId : undefined,
1091
- alpacaAccountId: props.alpacaAccountId !== undefined ? props.alpacaAccountId : undefined,
1092
- assetId: props.assetId !== undefined ? props.assetId : undefined,
1173
+ alpacaAccountId: props.alpacaAccountId !== undefined ? {
1174
+ equals: props.alpacaAccountId
1175
+ } : undefined,
1176
+ assetId: props.assetId !== undefined ? {
1177
+ equals: props.assetId
1178
+ } : undefined,
1093
1179
  side: props.side !== undefined ? props.side : undefined,
1094
1180
  type: props.type !== undefined ? props.type : undefined,
1095
1181
  orderClass: props.orderClass !== undefined ? props.orderClass : undefined,
@@ -1184,6 +1270,9 @@ exports.Order = {
1184
1270
  id: props.stopLoss.id !== undefined ? {
1185
1271
  equals: props.stopLoss.id
1186
1272
  } : undefined,
1273
+ orderId: props.stopLoss.orderId !== undefined ? {
1274
+ equals: props.stopLoss.orderId
1275
+ } : undefined,
1187
1276
  },
1188
1277
  update: {
1189
1278
  id: props.stopLoss.id !== undefined ? {
@@ -1208,6 +1297,9 @@ exports.Order = {
1208
1297
  id: props.takeProfit.id !== undefined ? {
1209
1298
  equals: props.takeProfit.id
1210
1299
  } : undefined,
1300
+ orderId: props.takeProfit.orderId !== undefined ? {
1301
+ equals: props.takeProfit.orderId
1302
+ } : undefined,
1211
1303
  },
1212
1304
  update: {
1213
1305
  id: props.takeProfit.id !== undefined ? {
@@ -1232,6 +1324,9 @@ exports.Order = {
1232
1324
  id: props.alpacaAccount.id !== undefined ? {
1233
1325
  equals: props.alpacaAccount.id
1234
1326
  } : undefined,
1327
+ userId: props.alpacaAccount.userId !== undefined ? {
1328
+ equals: props.alpacaAccount.userId
1329
+ } : undefined,
1235
1330
  },
1236
1331
  update: {
1237
1332
  id: props.alpacaAccount.id !== undefined ? {
@@ -1320,9 +1415,21 @@ exports.Order = {
1320
1415
  id: props.alpacaAccount.user.customer.id !== undefined ? {
1321
1416
  equals: props.alpacaAccount.user.customer.id
1322
1417
  } : undefined,
1418
+ authUserId: props.alpacaAccount.user.customer.authUserId !== undefined ? {
1419
+ equals: props.alpacaAccount.user.customer.authUserId
1420
+ } : undefined,
1323
1421
  name: props.alpacaAccount.user.customer.name !== undefined ? {
1324
1422
  equals: props.alpacaAccount.user.customer.name
1325
1423
  } : undefined,
1424
+ stripeCustomerId: props.alpacaAccount.user.customer.stripeCustomerId !== undefined ? {
1425
+ equals: props.alpacaAccount.user.customer.stripeCustomerId
1426
+ } : undefined,
1427
+ stripeSubscriptionId: props.alpacaAccount.user.customer.stripeSubscriptionId !== undefined ? {
1428
+ equals: props.alpacaAccount.user.customer.stripeSubscriptionId
1429
+ } : undefined,
1430
+ stripePriceId: props.alpacaAccount.user.customer.stripePriceId !== undefined ? {
1431
+ equals: props.alpacaAccount.user.customer.stripePriceId
1432
+ } : undefined,
1326
1433
  },
1327
1434
  update: {
1328
1435
  authUserId: props.alpacaAccount.user.customer.authUserId !== undefined ? {
@@ -1362,6 +1469,12 @@ exports.Order = {
1362
1469
  upsert: props.alpacaAccount.user.accounts.map((item) => ({
1363
1470
  where: {
1364
1471
  id: item.id !== undefined ? item.id : undefined,
1472
+ userId: item.userId !== undefined ? {
1473
+ equals: item.userId
1474
+ } : undefined,
1475
+ providerAccountId: item.providerAccountId !== undefined ? {
1476
+ equals: item.providerAccountId
1477
+ } : undefined,
1365
1478
  },
1366
1479
  update: {
1367
1480
  id: item.id !== undefined ? {
@@ -1416,6 +1529,9 @@ exports.Order = {
1416
1529
  upsert: props.alpacaAccount.user.sessions.map((item) => ({
1417
1530
  where: {
1418
1531
  id: item.id !== undefined ? item.id : undefined,
1532
+ userId: item.userId !== undefined ? {
1533
+ equals: item.userId
1534
+ } : undefined,
1419
1535
  },
1420
1536
  update: {
1421
1537
  id: item.id !== undefined ? {
@@ -1438,6 +1554,9 @@ exports.Order = {
1438
1554
  upsert: props.alpacaAccount.user.authenticators.map((item) => ({
1439
1555
  where: {
1440
1556
  id: item.id !== undefined ? item.id : undefined,
1557
+ userId: item.userId !== undefined ? {
1558
+ equals: item.userId
1559
+ } : undefined,
1441
1560
  },
1442
1561
  update: {
1443
1562
  id: item.id !== undefined ? {
@@ -1482,9 +1601,17 @@ exports.Order = {
1482
1601
  : { connectOrCreate: {
1483
1602
  where: {
1484
1603
  id: props.alpacaAccount.user.customer.id !== undefined ? props.alpacaAccount.user.customer.id : undefined,
1604
+ stripeCustomerId: props.alpacaAccount.user.customer.stripeCustomerId !== undefined ? props.alpacaAccount.user.customer.stripeCustomerId : undefined,
1605
+ stripeSubscriptionId: props.alpacaAccount.user.customer.stripeSubscriptionId !== undefined ? props.alpacaAccount.user.customer.stripeSubscriptionId : undefined,
1606
+ authUserId: props.alpacaAccount.user.customer.authUserId !== undefined ? {
1607
+ equals: props.alpacaAccount.user.customer.authUserId
1608
+ } : undefined,
1485
1609
  name: props.alpacaAccount.user.customer.name !== undefined ? {
1486
1610
  equals: props.alpacaAccount.user.customer.name
1487
1611
  } : undefined,
1612
+ stripePriceId: props.alpacaAccount.user.customer.stripePriceId !== undefined ? {
1613
+ equals: props.alpacaAccount.user.customer.stripePriceId
1614
+ } : undefined,
1488
1615
  },
1489
1616
  create: {
1490
1617
  authUserId: props.alpacaAccount.user.customer.authUserId !== undefined ? props.alpacaAccount.user.customer.authUserId : undefined,
@@ -1506,6 +1633,12 @@ exports.Order = {
1506
1633
  : { connectOrCreate: props.alpacaAccount.user.accounts.map((item) => ({
1507
1634
  where: {
1508
1635
  id: item.id !== undefined ? item.id : undefined,
1636
+ userId: item.userId !== undefined ? {
1637
+ equals: item.userId
1638
+ } : undefined,
1639
+ providerAccountId: item.providerAccountId !== undefined ? {
1640
+ equals: item.providerAccountId
1641
+ } : undefined,
1509
1642
  },
1510
1643
  create: {
1511
1644
  type: item.type !== undefined ? item.type : undefined,
@@ -1530,6 +1663,9 @@ exports.Order = {
1530
1663
  : { connectOrCreate: props.alpacaAccount.user.sessions.map((item) => ({
1531
1664
  where: {
1532
1665
  id: item.id !== undefined ? item.id : undefined,
1666
+ userId: item.userId !== undefined ? {
1667
+ equals: item.userId
1668
+ } : undefined,
1533
1669
  },
1534
1670
  create: {
1535
1671
  sessionToken: item.sessionToken !== undefined ? item.sessionToken : undefined,
@@ -1546,6 +1682,9 @@ exports.Order = {
1546
1682
  : { connectOrCreate: props.alpacaAccount.user.authenticators.map((item) => ({
1547
1683
  where: {
1548
1684
  id: item.id !== undefined ? item.id : undefined,
1685
+ userId: item.userId !== undefined ? {
1686
+ equals: item.userId
1687
+ } : undefined,
1549
1688
  },
1550
1689
  create: {
1551
1690
  credentialID: item.credentialID !== undefined ? item.credentialID : undefined,
@@ -1561,6 +1700,12 @@ exports.Order = {
1561
1700
  upsert: props.alpacaAccount.trades.map((item) => ({
1562
1701
  where: {
1563
1702
  id: item.id !== undefined ? item.id : undefined,
1703
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
1704
+ equals: item.alpacaAccountId
1705
+ } : undefined,
1706
+ assetId: item.assetId !== undefined ? {
1707
+ equals: item.assetId
1708
+ } : undefined,
1564
1709
  },
1565
1710
  update: {
1566
1711
  id: item.id !== undefined ? {
@@ -1845,6 +1990,9 @@ exports.Order = {
1845
1990
  upsert: item.actions.map((item) => ({
1846
1991
  where: {
1847
1992
  id: item.id !== undefined ? item.id : undefined,
1993
+ tradeId: item.tradeId !== undefined ? {
1994
+ equals: item.tradeId
1995
+ } : undefined,
1848
1996
  },
1849
1997
  update: {
1850
1998
  id: item.id !== undefined ? {
@@ -1968,6 +2116,9 @@ exports.Order = {
1968
2116
  : { connectOrCreate: item.actions.map((item) => ({
1969
2117
  where: {
1970
2118
  id: item.id !== undefined ? item.id : undefined,
2119
+ tradeId: item.tradeId !== undefined ? {
2120
+ equals: item.tradeId
2121
+ } : undefined,
1971
2122
  },
1972
2123
  create: {
1973
2124
  sequence: item.sequence !== undefined ? item.sequence : undefined,
@@ -1985,6 +2136,12 @@ exports.Order = {
1985
2136
  upsert: props.alpacaAccount.positions.map((item) => ({
1986
2137
  where: {
1987
2138
  id: item.id !== undefined ? item.id : undefined,
2139
+ assetId: item.assetId !== undefined ? {
2140
+ equals: item.assetId
2141
+ } : undefined,
2142
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
2143
+ equals: item.alpacaAccountId
2144
+ } : undefined,
1988
2145
  },
1989
2146
  update: {
1990
2147
  id: item.id !== undefined ? {
@@ -2364,6 +2521,9 @@ exports.Order = {
2364
2521
  upsert: props.alpacaAccount.alerts.map((item) => ({
2365
2522
  where: {
2366
2523
  id: item.id !== undefined ? item.id : undefined,
2524
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
2525
+ equals: item.alpacaAccountId
2526
+ } : undefined,
2367
2527
  },
2368
2528
  update: {
2369
2529
  id: item.id !== undefined ? {
@@ -2432,9 +2592,17 @@ exports.Order = {
2432
2592
  : { connectOrCreate: {
2433
2593
  where: {
2434
2594
  id: props.alpacaAccount.user.customer.id !== undefined ? props.alpacaAccount.user.customer.id : undefined,
2595
+ stripeCustomerId: props.alpacaAccount.user.customer.stripeCustomerId !== undefined ? props.alpacaAccount.user.customer.stripeCustomerId : undefined,
2596
+ stripeSubscriptionId: props.alpacaAccount.user.customer.stripeSubscriptionId !== undefined ? props.alpacaAccount.user.customer.stripeSubscriptionId : undefined,
2597
+ authUserId: props.alpacaAccount.user.customer.authUserId !== undefined ? {
2598
+ equals: props.alpacaAccount.user.customer.authUserId
2599
+ } : undefined,
2435
2600
  name: props.alpacaAccount.user.customer.name !== undefined ? {
2436
2601
  equals: props.alpacaAccount.user.customer.name
2437
2602
  } : undefined,
2603
+ stripePriceId: props.alpacaAccount.user.customer.stripePriceId !== undefined ? {
2604
+ equals: props.alpacaAccount.user.customer.stripePriceId
2605
+ } : undefined,
2438
2606
  },
2439
2607
  create: {
2440
2608
  authUserId: props.alpacaAccount.user.customer.authUserId !== undefined ? props.alpacaAccount.user.customer.authUserId : undefined,
@@ -2456,6 +2624,12 @@ exports.Order = {
2456
2624
  : { connectOrCreate: props.alpacaAccount.user.accounts.map((item) => ({
2457
2625
  where: {
2458
2626
  id: item.id !== undefined ? item.id : undefined,
2627
+ userId: item.userId !== undefined ? {
2628
+ equals: item.userId
2629
+ } : undefined,
2630
+ providerAccountId: item.providerAccountId !== undefined ? {
2631
+ equals: item.providerAccountId
2632
+ } : undefined,
2459
2633
  },
2460
2634
  create: {
2461
2635
  type: item.type !== undefined ? item.type : undefined,
@@ -2480,6 +2654,9 @@ exports.Order = {
2480
2654
  : { connectOrCreate: props.alpacaAccount.user.sessions.map((item) => ({
2481
2655
  where: {
2482
2656
  id: item.id !== undefined ? item.id : undefined,
2657
+ userId: item.userId !== undefined ? {
2658
+ equals: item.userId
2659
+ } : undefined,
2483
2660
  },
2484
2661
  create: {
2485
2662
  sessionToken: item.sessionToken !== undefined ? item.sessionToken : undefined,
@@ -2496,6 +2673,9 @@ exports.Order = {
2496
2673
  : { connectOrCreate: props.alpacaAccount.user.authenticators.map((item) => ({
2497
2674
  where: {
2498
2675
  id: item.id !== undefined ? item.id : undefined,
2676
+ userId: item.userId !== undefined ? {
2677
+ equals: item.userId
2678
+ } : undefined,
2499
2679
  },
2500
2680
  create: {
2501
2681
  credentialID: item.credentialID !== undefined ? item.credentialID : undefined,
@@ -2516,6 +2696,12 @@ exports.Order = {
2516
2696
  : { connectOrCreate: props.alpacaAccount.trades.map((item) => ({
2517
2697
  where: {
2518
2698
  id: item.id !== undefined ? item.id : undefined,
2699
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
2700
+ equals: item.alpacaAccountId
2701
+ } : undefined,
2702
+ assetId: item.assetId !== undefined ? {
2703
+ equals: item.assetId
2704
+ } : undefined,
2519
2705
  },
2520
2706
  create: {
2521
2707
  qty: item.qty !== undefined ? item.qty : undefined,
@@ -2609,6 +2795,9 @@ exports.Order = {
2609
2795
  : { connectOrCreate: item.actions.map((item) => ({
2610
2796
  where: {
2611
2797
  id: item.id !== undefined ? item.id : undefined,
2798
+ tradeId: item.tradeId !== undefined ? {
2799
+ equals: item.tradeId
2800
+ } : undefined,
2612
2801
  },
2613
2802
  create: {
2614
2803
  sequence: item.sequence !== undefined ? item.sequence : undefined,
@@ -2631,6 +2820,12 @@ exports.Order = {
2631
2820
  : { connectOrCreate: props.alpacaAccount.positions.map((item) => ({
2632
2821
  where: {
2633
2822
  id: item.id !== undefined ? item.id : undefined,
2823
+ assetId: item.assetId !== undefined ? {
2824
+ equals: item.assetId
2825
+ } : undefined,
2826
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
2827
+ equals: item.alpacaAccountId
2828
+ } : undefined,
2634
2829
  },
2635
2830
  create: {
2636
2831
  averageEntryPrice: item.averageEntryPrice !== undefined ? item.averageEntryPrice : undefined,
@@ -2729,6 +2924,9 @@ exports.Order = {
2729
2924
  : { connectOrCreate: props.alpacaAccount.alerts.map((item) => ({
2730
2925
  where: {
2731
2926
  id: item.id !== undefined ? item.id : undefined,
2927
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
2928
+ equals: item.alpacaAccountId
2929
+ } : undefined,
2732
2930
  },
2733
2931
  create: {
2734
2932
  message: item.message !== undefined ? item.message : undefined,
@@ -2746,6 +2944,9 @@ exports.Order = {
2746
2944
  id: props.action.id !== undefined ? {
2747
2945
  equals: props.action.id
2748
2946
  } : undefined,
2947
+ tradeId: props.action.tradeId !== undefined ? {
2948
+ equals: props.action.tradeId
2949
+ } : undefined,
2749
2950
  },
2750
2951
  update: {
2751
2952
  id: props.action.id !== undefined ? {
@@ -2772,6 +2973,12 @@ exports.Order = {
2772
2973
  id: props.action.trade.id !== undefined ? {
2773
2974
  equals: props.action.trade.id
2774
2975
  } : undefined,
2976
+ alpacaAccountId: props.action.trade.alpacaAccountId !== undefined ? {
2977
+ equals: props.action.trade.alpacaAccountId
2978
+ } : undefined,
2979
+ assetId: props.action.trade.assetId !== undefined ? {
2980
+ equals: props.action.trade.assetId
2981
+ } : undefined,
2775
2982
  },
2776
2983
  update: {
2777
2984
  id: props.action.trade.id !== undefined ? {
@@ -2816,6 +3023,9 @@ exports.Order = {
2816
3023
  id: props.action.trade.alpacaAccount.id !== undefined ? {
2817
3024
  equals: props.action.trade.alpacaAccount.id
2818
3025
  } : undefined,
3026
+ userId: props.action.trade.alpacaAccount.userId !== undefined ? {
3027
+ equals: props.action.trade.alpacaAccount.userId
3028
+ } : undefined,
2819
3029
  },
2820
3030
  update: {
2821
3031
  id: props.action.trade.alpacaAccount.id !== undefined ? {
@@ -3126,6 +3336,9 @@ exports.Order = {
3126
3336
  : { connectOrCreate: {
3127
3337
  where: {
3128
3338
  id: props.action.trade.alpacaAccount.id !== undefined ? props.action.trade.alpacaAccount.id : undefined,
3339
+ userId: props.action.trade.alpacaAccount.userId !== undefined ? {
3340
+ equals: props.action.trade.alpacaAccount.userId
3341
+ } : undefined,
3129
3342
  },
3130
3343
  create: {
3131
3344
  type: props.action.trade.alpacaAccount.type !== undefined ? props.action.trade.alpacaAccount.type : undefined,
@@ -3230,6 +3443,12 @@ exports.Order = {
3230
3443
  : { connectOrCreate: {
3231
3444
  where: {
3232
3445
  id: props.action.trade.id !== undefined ? props.action.trade.id : undefined,
3446
+ alpacaAccountId: props.action.trade.alpacaAccountId !== undefined ? {
3447
+ equals: props.action.trade.alpacaAccountId
3448
+ } : undefined,
3449
+ assetId: props.action.trade.assetId !== undefined ? {
3450
+ equals: props.action.trade.assetId
3451
+ } : undefined,
3233
3452
  },
3234
3453
  create: {
3235
3454
  qty: props.action.trade.qty !== undefined ? props.action.trade.qty : undefined,
@@ -3252,6 +3471,9 @@ exports.Order = {
3252
3471
  : { connectOrCreate: {
3253
3472
  where: {
3254
3473
  id: props.action.trade.alpacaAccount.id !== undefined ? props.action.trade.alpacaAccount.id : undefined,
3474
+ userId: props.action.trade.alpacaAccount.userId !== undefined ? {
3475
+ equals: props.action.trade.alpacaAccount.userId
3476
+ } : undefined,
3255
3477
  },
3256
3478
  create: {
3257
3479
  type: props.action.trade.alpacaAccount.type !== undefined ? props.action.trade.alpacaAccount.type : undefined,
@@ -3529,6 +3751,12 @@ exports.Order = {
3529
3751
  upsert: props.asset.trades.map((item) => ({
3530
3752
  where: {
3531
3753
  id: item.id !== undefined ? item.id : undefined,
3754
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
3755
+ equals: item.alpacaAccountId
3756
+ } : undefined,
3757
+ assetId: item.assetId !== undefined ? {
3758
+ equals: item.assetId
3759
+ } : undefined,
3532
3760
  },
3533
3761
  update: {
3534
3762
  id: item.id !== undefined ? {
@@ -3573,6 +3801,9 @@ exports.Order = {
3573
3801
  id: item.alpacaAccount.id !== undefined ? {
3574
3802
  equals: item.alpacaAccount.id
3575
3803
  } : undefined,
3804
+ userId: item.alpacaAccount.userId !== undefined ? {
3805
+ equals: item.alpacaAccount.userId
3806
+ } : undefined,
3576
3807
  },
3577
3808
  update: {
3578
3809
  id: item.alpacaAccount.id !== undefined ? {
@@ -3623,6 +3854,9 @@ exports.Order = {
3623
3854
  upsert: item.actions.map((item) => ({
3624
3855
  where: {
3625
3856
  id: item.id !== undefined ? item.id : undefined,
3857
+ tradeId: item.tradeId !== undefined ? {
3858
+ equals: item.tradeId
3859
+ } : undefined,
3626
3860
  },
3627
3861
  update: {
3628
3862
  id: item.id !== undefined ? {
@@ -3675,6 +3909,9 @@ exports.Order = {
3675
3909
  : { connectOrCreate: {
3676
3910
  where: {
3677
3911
  id: item.alpacaAccount.id !== undefined ? item.alpacaAccount.id : undefined,
3912
+ userId: item.alpacaAccount.userId !== undefined ? {
3913
+ equals: item.alpacaAccount.userId
3914
+ } : undefined,
3678
3915
  },
3679
3916
  create: {
3680
3917
  type: item.alpacaAccount.type !== undefined ? item.alpacaAccount.type : undefined,
@@ -3698,6 +3935,9 @@ exports.Order = {
3698
3935
  : { connectOrCreate: item.actions.map((item) => ({
3699
3936
  where: {
3700
3937
  id: item.id !== undefined ? item.id : undefined,
3938
+ tradeId: item.tradeId !== undefined ? {
3939
+ equals: item.tradeId
3940
+ } : undefined,
3701
3941
  },
3702
3942
  create: {
3703
3943
  sequence: item.sequence !== undefined ? item.sequence : undefined,
@@ -3715,6 +3955,12 @@ exports.Order = {
3715
3955
  upsert: props.asset.positions.map((item) => ({
3716
3956
  where: {
3717
3957
  id: item.id !== undefined ? item.id : undefined,
3958
+ assetId: item.assetId !== undefined ? {
3959
+ equals: item.assetId
3960
+ } : undefined,
3961
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
3962
+ equals: item.alpacaAccountId
3963
+ } : undefined,
3718
3964
  },
3719
3965
  update: {
3720
3966
  id: item.id !== undefined ? {
@@ -3765,6 +4011,9 @@ exports.Order = {
3765
4011
  id: item.alpacaAccount.id !== undefined ? {
3766
4012
  equals: item.alpacaAccount.id
3767
4013
  } : undefined,
4014
+ userId: item.alpacaAccount.userId !== undefined ? {
4015
+ equals: item.alpacaAccount.userId
4016
+ } : undefined,
3768
4017
  },
3769
4018
  update: {
3770
4019
  id: item.alpacaAccount.id !== undefined ? {
@@ -3835,6 +4084,9 @@ exports.Order = {
3835
4084
  : { connectOrCreate: {
3836
4085
  where: {
3837
4086
  id: item.alpacaAccount.id !== undefined ? item.alpacaAccount.id : undefined,
4087
+ userId: item.alpacaAccount.userId !== undefined ? {
4088
+ equals: item.alpacaAccount.userId
4089
+ } : undefined,
3838
4090
  },
3839
4091
  create: {
3840
4092
  type: item.alpacaAccount.type !== undefined ? item.alpacaAccount.type : undefined,
@@ -3857,6 +4109,12 @@ exports.Order = {
3857
4109
  where: {
3858
4110
  id: item.id !== undefined ? item.id : undefined,
3859
4111
  url: item.url !== undefined ? item.url : undefined,
4112
+ assetId: item.assetId !== undefined ? {
4113
+ equals: item.assetId
4114
+ } : undefined,
4115
+ newsArticleId: item.newsArticleId !== undefined ? {
4116
+ equals: item.newsArticleId
4117
+ } : undefined,
3860
4118
  },
3861
4119
  update: {
3862
4120
  id: item.id !== undefined ? {
@@ -4054,6 +4312,12 @@ exports.Order = {
4054
4312
  : { connectOrCreate: props.asset.trades.map((item) => ({
4055
4313
  where: {
4056
4314
  id: item.id !== undefined ? item.id : undefined,
4315
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
4316
+ equals: item.alpacaAccountId
4317
+ } : undefined,
4318
+ assetId: item.assetId !== undefined ? {
4319
+ equals: item.assetId
4320
+ } : undefined,
4057
4321
  },
4058
4322
  create: {
4059
4323
  qty: item.qty !== undefined ? item.qty : undefined,
@@ -4076,6 +4340,9 @@ exports.Order = {
4076
4340
  : { connectOrCreate: {
4077
4341
  where: {
4078
4342
  id: item.alpacaAccount.id !== undefined ? item.alpacaAccount.id : undefined,
4343
+ userId: item.alpacaAccount.userId !== undefined ? {
4344
+ equals: item.alpacaAccount.userId
4345
+ } : undefined,
4079
4346
  },
4080
4347
  create: {
4081
4348
  type: item.alpacaAccount.type !== undefined ? item.alpacaAccount.type : undefined,
@@ -4099,6 +4366,9 @@ exports.Order = {
4099
4366
  : { connectOrCreate: item.actions.map((item) => ({
4100
4367
  where: {
4101
4368
  id: item.id !== undefined ? item.id : undefined,
4369
+ tradeId: item.tradeId !== undefined ? {
4370
+ equals: item.tradeId
4371
+ } : undefined,
4102
4372
  },
4103
4373
  create: {
4104
4374
  sequence: item.sequence !== undefined ? item.sequence : undefined,
@@ -4121,6 +4391,12 @@ exports.Order = {
4121
4391
  : { connectOrCreate: props.asset.positions.map((item) => ({
4122
4392
  where: {
4123
4393
  id: item.id !== undefined ? item.id : undefined,
4394
+ assetId: item.assetId !== undefined ? {
4395
+ equals: item.assetId
4396
+ } : undefined,
4397
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
4398
+ equals: item.alpacaAccountId
4399
+ } : undefined,
4124
4400
  },
4125
4401
  create: {
4126
4402
  averageEntryPrice: item.averageEntryPrice !== undefined ? item.averageEntryPrice : undefined,
@@ -4145,6 +4421,9 @@ exports.Order = {
4145
4421
  : { connectOrCreate: {
4146
4422
  where: {
4147
4423
  id: item.alpacaAccount.id !== undefined ? item.alpacaAccount.id : undefined,
4424
+ userId: item.alpacaAccount.userId !== undefined ? {
4425
+ equals: item.alpacaAccount.userId
4426
+ } : undefined,
4148
4427
  },
4149
4428
  create: {
4150
4429
  type: item.alpacaAccount.type !== undefined ? item.alpacaAccount.type : undefined,
@@ -4172,6 +4451,12 @@ exports.Order = {
4172
4451
  where: {
4173
4452
  id: item.id !== undefined ? item.id : undefined,
4174
4453
  url: item.url !== undefined ? item.url : undefined,
4454
+ assetId: item.assetId !== undefined ? {
4455
+ equals: item.assetId
4456
+ } : undefined,
4457
+ newsArticleId: item.newsArticleId !== undefined ? {
4458
+ equals: item.newsArticleId
4459
+ } : undefined,
4175
4460
  },
4176
4461
  create: {
4177
4462
  url: item.url !== undefined ? item.url : undefined,
@@ -4253,8 +4538,12 @@ exports.Order = {
4253
4538
  clientOrderId: prop.clientOrderId !== undefined ? prop.clientOrderId : undefined,
4254
4539
  actionId: prop.actionId !== undefined ? prop.actionId : undefined,
4255
4540
  stopLossId: prop.stopLossId !== undefined ? prop.stopLossId : undefined,
4256
- alpacaAccountId: prop.alpacaAccountId !== undefined ? prop.alpacaAccountId : undefined,
4257
- assetId: prop.assetId !== undefined ? prop.assetId : undefined,
4541
+ alpacaAccountId: prop.alpacaAccountId !== undefined ? {
4542
+ equals: prop.alpacaAccountId
4543
+ } : undefined,
4544
+ assetId: prop.assetId !== undefined ? {
4545
+ equals: prop.assetId
4546
+ } : undefined,
4258
4547
  side: prop.side !== undefined ? prop.side : undefined,
4259
4548
  type: prop.type !== undefined ? prop.type : undefined,
4260
4549
  orderClass: prop.orderClass !== undefined ? prop.orderClass : undefined,
@@ -4349,6 +4638,9 @@ exports.Order = {
4349
4638
  id: prop.stopLoss.id !== undefined ? {
4350
4639
  equals: prop.stopLoss.id
4351
4640
  } : undefined,
4641
+ orderId: prop.stopLoss.orderId !== undefined ? {
4642
+ equals: prop.stopLoss.orderId
4643
+ } : undefined,
4352
4644
  },
4353
4645
  update: {
4354
4646
  id: prop.stopLoss.id !== undefined ? {
@@ -4373,6 +4665,9 @@ exports.Order = {
4373
4665
  id: prop.takeProfit.id !== undefined ? {
4374
4666
  equals: prop.takeProfit.id
4375
4667
  } : undefined,
4668
+ orderId: prop.takeProfit.orderId !== undefined ? {
4669
+ equals: prop.takeProfit.orderId
4670
+ } : undefined,
4376
4671
  },
4377
4672
  update: {
4378
4673
  id: prop.takeProfit.id !== undefined ? {
@@ -4397,6 +4692,9 @@ exports.Order = {
4397
4692
  id: prop.alpacaAccount.id !== undefined ? {
4398
4693
  equals: prop.alpacaAccount.id
4399
4694
  } : undefined,
4695
+ userId: prop.alpacaAccount.userId !== undefined ? {
4696
+ equals: prop.alpacaAccount.userId
4697
+ } : undefined,
4400
4698
  },
4401
4699
  update: {
4402
4700
  id: prop.alpacaAccount.id !== undefined ? {
@@ -4485,9 +4783,21 @@ exports.Order = {
4485
4783
  id: prop.alpacaAccount.user.customer.id !== undefined ? {
4486
4784
  equals: prop.alpacaAccount.user.customer.id
4487
4785
  } : undefined,
4786
+ authUserId: prop.alpacaAccount.user.customer.authUserId !== undefined ? {
4787
+ equals: prop.alpacaAccount.user.customer.authUserId
4788
+ } : undefined,
4488
4789
  name: prop.alpacaAccount.user.customer.name !== undefined ? {
4489
4790
  equals: prop.alpacaAccount.user.customer.name
4490
4791
  } : undefined,
4792
+ stripeCustomerId: prop.alpacaAccount.user.customer.stripeCustomerId !== undefined ? {
4793
+ equals: prop.alpacaAccount.user.customer.stripeCustomerId
4794
+ } : undefined,
4795
+ stripeSubscriptionId: prop.alpacaAccount.user.customer.stripeSubscriptionId !== undefined ? {
4796
+ equals: prop.alpacaAccount.user.customer.stripeSubscriptionId
4797
+ } : undefined,
4798
+ stripePriceId: prop.alpacaAccount.user.customer.stripePriceId !== undefined ? {
4799
+ equals: prop.alpacaAccount.user.customer.stripePriceId
4800
+ } : undefined,
4491
4801
  },
4492
4802
  update: {
4493
4803
  authUserId: prop.alpacaAccount.user.customer.authUserId !== undefined ? {
@@ -4527,6 +4837,12 @@ exports.Order = {
4527
4837
  upsert: prop.alpacaAccount.user.accounts.map((item) => ({
4528
4838
  where: {
4529
4839
  id: item.id !== undefined ? item.id : undefined,
4840
+ userId: item.userId !== undefined ? {
4841
+ equals: item.userId
4842
+ } : undefined,
4843
+ providerAccountId: item.providerAccountId !== undefined ? {
4844
+ equals: item.providerAccountId
4845
+ } : undefined,
4530
4846
  },
4531
4847
  update: {
4532
4848
  id: item.id !== undefined ? {
@@ -4581,6 +4897,9 @@ exports.Order = {
4581
4897
  upsert: prop.alpacaAccount.user.sessions.map((item) => ({
4582
4898
  where: {
4583
4899
  id: item.id !== undefined ? item.id : undefined,
4900
+ userId: item.userId !== undefined ? {
4901
+ equals: item.userId
4902
+ } : undefined,
4584
4903
  },
4585
4904
  update: {
4586
4905
  id: item.id !== undefined ? {
@@ -4603,6 +4922,9 @@ exports.Order = {
4603
4922
  upsert: prop.alpacaAccount.user.authenticators.map((item) => ({
4604
4923
  where: {
4605
4924
  id: item.id !== undefined ? item.id : undefined,
4925
+ userId: item.userId !== undefined ? {
4926
+ equals: item.userId
4927
+ } : undefined,
4606
4928
  },
4607
4929
  update: {
4608
4930
  id: item.id !== undefined ? {
@@ -4647,9 +4969,17 @@ exports.Order = {
4647
4969
  : { connectOrCreate: {
4648
4970
  where: {
4649
4971
  id: prop.alpacaAccount.user.customer.id !== undefined ? prop.alpacaAccount.user.customer.id : undefined,
4972
+ stripeCustomerId: prop.alpacaAccount.user.customer.stripeCustomerId !== undefined ? prop.alpacaAccount.user.customer.stripeCustomerId : undefined,
4973
+ stripeSubscriptionId: prop.alpacaAccount.user.customer.stripeSubscriptionId !== undefined ? prop.alpacaAccount.user.customer.stripeSubscriptionId : undefined,
4974
+ authUserId: prop.alpacaAccount.user.customer.authUserId !== undefined ? {
4975
+ equals: prop.alpacaAccount.user.customer.authUserId
4976
+ } : undefined,
4650
4977
  name: prop.alpacaAccount.user.customer.name !== undefined ? {
4651
4978
  equals: prop.alpacaAccount.user.customer.name
4652
4979
  } : undefined,
4980
+ stripePriceId: prop.alpacaAccount.user.customer.stripePriceId !== undefined ? {
4981
+ equals: prop.alpacaAccount.user.customer.stripePriceId
4982
+ } : undefined,
4653
4983
  },
4654
4984
  create: {
4655
4985
  authUserId: prop.alpacaAccount.user.customer.authUserId !== undefined ? prop.alpacaAccount.user.customer.authUserId : undefined,
@@ -4671,6 +5001,12 @@ exports.Order = {
4671
5001
  : { connectOrCreate: prop.alpacaAccount.user.accounts.map((item) => ({
4672
5002
  where: {
4673
5003
  id: item.id !== undefined ? item.id : undefined,
5004
+ userId: item.userId !== undefined ? {
5005
+ equals: item.userId
5006
+ } : undefined,
5007
+ providerAccountId: item.providerAccountId !== undefined ? {
5008
+ equals: item.providerAccountId
5009
+ } : undefined,
4674
5010
  },
4675
5011
  create: {
4676
5012
  type: item.type !== undefined ? item.type : undefined,
@@ -4695,6 +5031,9 @@ exports.Order = {
4695
5031
  : { connectOrCreate: prop.alpacaAccount.user.sessions.map((item) => ({
4696
5032
  where: {
4697
5033
  id: item.id !== undefined ? item.id : undefined,
5034
+ userId: item.userId !== undefined ? {
5035
+ equals: item.userId
5036
+ } : undefined,
4698
5037
  },
4699
5038
  create: {
4700
5039
  sessionToken: item.sessionToken !== undefined ? item.sessionToken : undefined,
@@ -4711,6 +5050,9 @@ exports.Order = {
4711
5050
  : { connectOrCreate: prop.alpacaAccount.user.authenticators.map((item) => ({
4712
5051
  where: {
4713
5052
  id: item.id !== undefined ? item.id : undefined,
5053
+ userId: item.userId !== undefined ? {
5054
+ equals: item.userId
5055
+ } : undefined,
4714
5056
  },
4715
5057
  create: {
4716
5058
  credentialID: item.credentialID !== undefined ? item.credentialID : undefined,
@@ -4726,6 +5068,12 @@ exports.Order = {
4726
5068
  upsert: prop.alpacaAccount.trades.map((item) => ({
4727
5069
  where: {
4728
5070
  id: item.id !== undefined ? item.id : undefined,
5071
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
5072
+ equals: item.alpacaAccountId
5073
+ } : undefined,
5074
+ assetId: item.assetId !== undefined ? {
5075
+ equals: item.assetId
5076
+ } : undefined,
4729
5077
  },
4730
5078
  update: {
4731
5079
  id: item.id !== undefined ? {
@@ -5010,6 +5358,9 @@ exports.Order = {
5010
5358
  upsert: item.actions.map((item) => ({
5011
5359
  where: {
5012
5360
  id: item.id !== undefined ? item.id : undefined,
5361
+ tradeId: item.tradeId !== undefined ? {
5362
+ equals: item.tradeId
5363
+ } : undefined,
5013
5364
  },
5014
5365
  update: {
5015
5366
  id: item.id !== undefined ? {
@@ -5133,6 +5484,9 @@ exports.Order = {
5133
5484
  : { connectOrCreate: item.actions.map((item) => ({
5134
5485
  where: {
5135
5486
  id: item.id !== undefined ? item.id : undefined,
5487
+ tradeId: item.tradeId !== undefined ? {
5488
+ equals: item.tradeId
5489
+ } : undefined,
5136
5490
  },
5137
5491
  create: {
5138
5492
  sequence: item.sequence !== undefined ? item.sequence : undefined,
@@ -5150,6 +5504,12 @@ exports.Order = {
5150
5504
  upsert: prop.alpacaAccount.positions.map((item) => ({
5151
5505
  where: {
5152
5506
  id: item.id !== undefined ? item.id : undefined,
5507
+ assetId: item.assetId !== undefined ? {
5508
+ equals: item.assetId
5509
+ } : undefined,
5510
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
5511
+ equals: item.alpacaAccountId
5512
+ } : undefined,
5153
5513
  },
5154
5514
  update: {
5155
5515
  id: item.id !== undefined ? {
@@ -5529,6 +5889,9 @@ exports.Order = {
5529
5889
  upsert: prop.alpacaAccount.alerts.map((item) => ({
5530
5890
  where: {
5531
5891
  id: item.id !== undefined ? item.id : undefined,
5892
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
5893
+ equals: item.alpacaAccountId
5894
+ } : undefined,
5532
5895
  },
5533
5896
  update: {
5534
5897
  id: item.id !== undefined ? {
@@ -5597,9 +5960,17 @@ exports.Order = {
5597
5960
  : { connectOrCreate: {
5598
5961
  where: {
5599
5962
  id: prop.alpacaAccount.user.customer.id !== undefined ? prop.alpacaAccount.user.customer.id : undefined,
5963
+ stripeCustomerId: prop.alpacaAccount.user.customer.stripeCustomerId !== undefined ? prop.alpacaAccount.user.customer.stripeCustomerId : undefined,
5964
+ stripeSubscriptionId: prop.alpacaAccount.user.customer.stripeSubscriptionId !== undefined ? prop.alpacaAccount.user.customer.stripeSubscriptionId : undefined,
5965
+ authUserId: prop.alpacaAccount.user.customer.authUserId !== undefined ? {
5966
+ equals: prop.alpacaAccount.user.customer.authUserId
5967
+ } : undefined,
5600
5968
  name: prop.alpacaAccount.user.customer.name !== undefined ? {
5601
5969
  equals: prop.alpacaAccount.user.customer.name
5602
5970
  } : undefined,
5971
+ stripePriceId: prop.alpacaAccount.user.customer.stripePriceId !== undefined ? {
5972
+ equals: prop.alpacaAccount.user.customer.stripePriceId
5973
+ } : undefined,
5603
5974
  },
5604
5975
  create: {
5605
5976
  authUserId: prop.alpacaAccount.user.customer.authUserId !== undefined ? prop.alpacaAccount.user.customer.authUserId : undefined,
@@ -5621,6 +5992,12 @@ exports.Order = {
5621
5992
  : { connectOrCreate: prop.alpacaAccount.user.accounts.map((item) => ({
5622
5993
  where: {
5623
5994
  id: item.id !== undefined ? item.id : undefined,
5995
+ userId: item.userId !== undefined ? {
5996
+ equals: item.userId
5997
+ } : undefined,
5998
+ providerAccountId: item.providerAccountId !== undefined ? {
5999
+ equals: item.providerAccountId
6000
+ } : undefined,
5624
6001
  },
5625
6002
  create: {
5626
6003
  type: item.type !== undefined ? item.type : undefined,
@@ -5645,6 +6022,9 @@ exports.Order = {
5645
6022
  : { connectOrCreate: prop.alpacaAccount.user.sessions.map((item) => ({
5646
6023
  where: {
5647
6024
  id: item.id !== undefined ? item.id : undefined,
6025
+ userId: item.userId !== undefined ? {
6026
+ equals: item.userId
6027
+ } : undefined,
5648
6028
  },
5649
6029
  create: {
5650
6030
  sessionToken: item.sessionToken !== undefined ? item.sessionToken : undefined,
@@ -5661,6 +6041,9 @@ exports.Order = {
5661
6041
  : { connectOrCreate: prop.alpacaAccount.user.authenticators.map((item) => ({
5662
6042
  where: {
5663
6043
  id: item.id !== undefined ? item.id : undefined,
6044
+ userId: item.userId !== undefined ? {
6045
+ equals: item.userId
6046
+ } : undefined,
5664
6047
  },
5665
6048
  create: {
5666
6049
  credentialID: item.credentialID !== undefined ? item.credentialID : undefined,
@@ -5681,6 +6064,12 @@ exports.Order = {
5681
6064
  : { connectOrCreate: prop.alpacaAccount.trades.map((item) => ({
5682
6065
  where: {
5683
6066
  id: item.id !== undefined ? item.id : undefined,
6067
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
6068
+ equals: item.alpacaAccountId
6069
+ } : undefined,
6070
+ assetId: item.assetId !== undefined ? {
6071
+ equals: item.assetId
6072
+ } : undefined,
5684
6073
  },
5685
6074
  create: {
5686
6075
  qty: item.qty !== undefined ? item.qty : undefined,
@@ -5774,6 +6163,9 @@ exports.Order = {
5774
6163
  : { connectOrCreate: item.actions.map((item) => ({
5775
6164
  where: {
5776
6165
  id: item.id !== undefined ? item.id : undefined,
6166
+ tradeId: item.tradeId !== undefined ? {
6167
+ equals: item.tradeId
6168
+ } : undefined,
5777
6169
  },
5778
6170
  create: {
5779
6171
  sequence: item.sequence !== undefined ? item.sequence : undefined,
@@ -5796,6 +6188,12 @@ exports.Order = {
5796
6188
  : { connectOrCreate: prop.alpacaAccount.positions.map((item) => ({
5797
6189
  where: {
5798
6190
  id: item.id !== undefined ? item.id : undefined,
6191
+ assetId: item.assetId !== undefined ? {
6192
+ equals: item.assetId
6193
+ } : undefined,
6194
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
6195
+ equals: item.alpacaAccountId
6196
+ } : undefined,
5799
6197
  },
5800
6198
  create: {
5801
6199
  averageEntryPrice: item.averageEntryPrice !== undefined ? item.averageEntryPrice : undefined,
@@ -5894,6 +6292,9 @@ exports.Order = {
5894
6292
  : { connectOrCreate: prop.alpacaAccount.alerts.map((item) => ({
5895
6293
  where: {
5896
6294
  id: item.id !== undefined ? item.id : undefined,
6295
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
6296
+ equals: item.alpacaAccountId
6297
+ } : undefined,
5897
6298
  },
5898
6299
  create: {
5899
6300
  message: item.message !== undefined ? item.message : undefined,
@@ -5911,6 +6312,9 @@ exports.Order = {
5911
6312
  id: prop.action.id !== undefined ? {
5912
6313
  equals: prop.action.id
5913
6314
  } : undefined,
6315
+ tradeId: prop.action.tradeId !== undefined ? {
6316
+ equals: prop.action.tradeId
6317
+ } : undefined,
5914
6318
  },
5915
6319
  update: {
5916
6320
  id: prop.action.id !== undefined ? {
@@ -5937,6 +6341,12 @@ exports.Order = {
5937
6341
  id: prop.action.trade.id !== undefined ? {
5938
6342
  equals: prop.action.trade.id
5939
6343
  } : undefined,
6344
+ alpacaAccountId: prop.action.trade.alpacaAccountId !== undefined ? {
6345
+ equals: prop.action.trade.alpacaAccountId
6346
+ } : undefined,
6347
+ assetId: prop.action.trade.assetId !== undefined ? {
6348
+ equals: prop.action.trade.assetId
6349
+ } : undefined,
5940
6350
  },
5941
6351
  update: {
5942
6352
  id: prop.action.trade.id !== undefined ? {
@@ -5981,6 +6391,9 @@ exports.Order = {
5981
6391
  id: prop.action.trade.alpacaAccount.id !== undefined ? {
5982
6392
  equals: prop.action.trade.alpacaAccount.id
5983
6393
  } : undefined,
6394
+ userId: prop.action.trade.alpacaAccount.userId !== undefined ? {
6395
+ equals: prop.action.trade.alpacaAccount.userId
6396
+ } : undefined,
5984
6397
  },
5985
6398
  update: {
5986
6399
  id: prop.action.trade.alpacaAccount.id !== undefined ? {
@@ -6291,6 +6704,9 @@ exports.Order = {
6291
6704
  : { connectOrCreate: {
6292
6705
  where: {
6293
6706
  id: prop.action.trade.alpacaAccount.id !== undefined ? prop.action.trade.alpacaAccount.id : undefined,
6707
+ userId: prop.action.trade.alpacaAccount.userId !== undefined ? {
6708
+ equals: prop.action.trade.alpacaAccount.userId
6709
+ } : undefined,
6294
6710
  },
6295
6711
  create: {
6296
6712
  type: prop.action.trade.alpacaAccount.type !== undefined ? prop.action.trade.alpacaAccount.type : undefined,
@@ -6395,6 +6811,12 @@ exports.Order = {
6395
6811
  : { connectOrCreate: {
6396
6812
  where: {
6397
6813
  id: prop.action.trade.id !== undefined ? prop.action.trade.id : undefined,
6814
+ alpacaAccountId: prop.action.trade.alpacaAccountId !== undefined ? {
6815
+ equals: prop.action.trade.alpacaAccountId
6816
+ } : undefined,
6817
+ assetId: prop.action.trade.assetId !== undefined ? {
6818
+ equals: prop.action.trade.assetId
6819
+ } : undefined,
6398
6820
  },
6399
6821
  create: {
6400
6822
  qty: prop.action.trade.qty !== undefined ? prop.action.trade.qty : undefined,
@@ -6417,6 +6839,9 @@ exports.Order = {
6417
6839
  : { connectOrCreate: {
6418
6840
  where: {
6419
6841
  id: prop.action.trade.alpacaAccount.id !== undefined ? prop.action.trade.alpacaAccount.id : undefined,
6842
+ userId: prop.action.trade.alpacaAccount.userId !== undefined ? {
6843
+ equals: prop.action.trade.alpacaAccount.userId
6844
+ } : undefined,
6420
6845
  },
6421
6846
  create: {
6422
6847
  type: prop.action.trade.alpacaAccount.type !== undefined ? prop.action.trade.alpacaAccount.type : undefined,
@@ -6694,6 +7119,12 @@ exports.Order = {
6694
7119
  upsert: prop.asset.trades.map((item) => ({
6695
7120
  where: {
6696
7121
  id: item.id !== undefined ? item.id : undefined,
7122
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
7123
+ equals: item.alpacaAccountId
7124
+ } : undefined,
7125
+ assetId: item.assetId !== undefined ? {
7126
+ equals: item.assetId
7127
+ } : undefined,
6697
7128
  },
6698
7129
  update: {
6699
7130
  id: item.id !== undefined ? {
@@ -6738,6 +7169,9 @@ exports.Order = {
6738
7169
  id: item.alpacaAccount.id !== undefined ? {
6739
7170
  equals: item.alpacaAccount.id
6740
7171
  } : undefined,
7172
+ userId: item.alpacaAccount.userId !== undefined ? {
7173
+ equals: item.alpacaAccount.userId
7174
+ } : undefined,
6741
7175
  },
6742
7176
  update: {
6743
7177
  id: item.alpacaAccount.id !== undefined ? {
@@ -6788,6 +7222,9 @@ exports.Order = {
6788
7222
  upsert: item.actions.map((item) => ({
6789
7223
  where: {
6790
7224
  id: item.id !== undefined ? item.id : undefined,
7225
+ tradeId: item.tradeId !== undefined ? {
7226
+ equals: item.tradeId
7227
+ } : undefined,
6791
7228
  },
6792
7229
  update: {
6793
7230
  id: item.id !== undefined ? {
@@ -6840,6 +7277,9 @@ exports.Order = {
6840
7277
  : { connectOrCreate: {
6841
7278
  where: {
6842
7279
  id: item.alpacaAccount.id !== undefined ? item.alpacaAccount.id : undefined,
7280
+ userId: item.alpacaAccount.userId !== undefined ? {
7281
+ equals: item.alpacaAccount.userId
7282
+ } : undefined,
6843
7283
  },
6844
7284
  create: {
6845
7285
  type: item.alpacaAccount.type !== undefined ? item.alpacaAccount.type : undefined,
@@ -6863,6 +7303,9 @@ exports.Order = {
6863
7303
  : { connectOrCreate: item.actions.map((item) => ({
6864
7304
  where: {
6865
7305
  id: item.id !== undefined ? item.id : undefined,
7306
+ tradeId: item.tradeId !== undefined ? {
7307
+ equals: item.tradeId
7308
+ } : undefined,
6866
7309
  },
6867
7310
  create: {
6868
7311
  sequence: item.sequence !== undefined ? item.sequence : undefined,
@@ -6880,6 +7323,12 @@ exports.Order = {
6880
7323
  upsert: prop.asset.positions.map((item) => ({
6881
7324
  where: {
6882
7325
  id: item.id !== undefined ? item.id : undefined,
7326
+ assetId: item.assetId !== undefined ? {
7327
+ equals: item.assetId
7328
+ } : undefined,
7329
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
7330
+ equals: item.alpacaAccountId
7331
+ } : undefined,
6883
7332
  },
6884
7333
  update: {
6885
7334
  id: item.id !== undefined ? {
@@ -6930,6 +7379,9 @@ exports.Order = {
6930
7379
  id: item.alpacaAccount.id !== undefined ? {
6931
7380
  equals: item.alpacaAccount.id
6932
7381
  } : undefined,
7382
+ userId: item.alpacaAccount.userId !== undefined ? {
7383
+ equals: item.alpacaAccount.userId
7384
+ } : undefined,
6933
7385
  },
6934
7386
  update: {
6935
7387
  id: item.alpacaAccount.id !== undefined ? {
@@ -7000,6 +7452,9 @@ exports.Order = {
7000
7452
  : { connectOrCreate: {
7001
7453
  where: {
7002
7454
  id: item.alpacaAccount.id !== undefined ? item.alpacaAccount.id : undefined,
7455
+ userId: item.alpacaAccount.userId !== undefined ? {
7456
+ equals: item.alpacaAccount.userId
7457
+ } : undefined,
7003
7458
  },
7004
7459
  create: {
7005
7460
  type: item.alpacaAccount.type !== undefined ? item.alpacaAccount.type : undefined,
@@ -7022,6 +7477,12 @@ exports.Order = {
7022
7477
  where: {
7023
7478
  id: item.id !== undefined ? item.id : undefined,
7024
7479
  url: item.url !== undefined ? item.url : undefined,
7480
+ assetId: item.assetId !== undefined ? {
7481
+ equals: item.assetId
7482
+ } : undefined,
7483
+ newsArticleId: item.newsArticleId !== undefined ? {
7484
+ equals: item.newsArticleId
7485
+ } : undefined,
7025
7486
  },
7026
7487
  update: {
7027
7488
  id: item.id !== undefined ? {
@@ -7219,6 +7680,12 @@ exports.Order = {
7219
7680
  : { connectOrCreate: prop.asset.trades.map((item) => ({
7220
7681
  where: {
7221
7682
  id: item.id !== undefined ? item.id : undefined,
7683
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
7684
+ equals: item.alpacaAccountId
7685
+ } : undefined,
7686
+ assetId: item.assetId !== undefined ? {
7687
+ equals: item.assetId
7688
+ } : undefined,
7222
7689
  },
7223
7690
  create: {
7224
7691
  qty: item.qty !== undefined ? item.qty : undefined,
@@ -7241,6 +7708,9 @@ exports.Order = {
7241
7708
  : { connectOrCreate: {
7242
7709
  where: {
7243
7710
  id: item.alpacaAccount.id !== undefined ? item.alpacaAccount.id : undefined,
7711
+ userId: item.alpacaAccount.userId !== undefined ? {
7712
+ equals: item.alpacaAccount.userId
7713
+ } : undefined,
7244
7714
  },
7245
7715
  create: {
7246
7716
  type: item.alpacaAccount.type !== undefined ? item.alpacaAccount.type : undefined,
@@ -7264,6 +7734,9 @@ exports.Order = {
7264
7734
  : { connectOrCreate: item.actions.map((item) => ({
7265
7735
  where: {
7266
7736
  id: item.id !== undefined ? item.id : undefined,
7737
+ tradeId: item.tradeId !== undefined ? {
7738
+ equals: item.tradeId
7739
+ } : undefined,
7267
7740
  },
7268
7741
  create: {
7269
7742
  sequence: item.sequence !== undefined ? item.sequence : undefined,
@@ -7286,6 +7759,12 @@ exports.Order = {
7286
7759
  : { connectOrCreate: prop.asset.positions.map((item) => ({
7287
7760
  where: {
7288
7761
  id: item.id !== undefined ? item.id : undefined,
7762
+ assetId: item.assetId !== undefined ? {
7763
+ equals: item.assetId
7764
+ } : undefined,
7765
+ alpacaAccountId: item.alpacaAccountId !== undefined ? {
7766
+ equals: item.alpacaAccountId
7767
+ } : undefined,
7289
7768
  },
7290
7769
  create: {
7291
7770
  averageEntryPrice: item.averageEntryPrice !== undefined ? item.averageEntryPrice : undefined,
@@ -7310,6 +7789,9 @@ exports.Order = {
7310
7789
  : { connectOrCreate: {
7311
7790
  where: {
7312
7791
  id: item.alpacaAccount.id !== undefined ? item.alpacaAccount.id : undefined,
7792
+ userId: item.alpacaAccount.userId !== undefined ? {
7793
+ equals: item.alpacaAccount.userId
7794
+ } : undefined,
7313
7795
  },
7314
7796
  create: {
7315
7797
  type: item.alpacaAccount.type !== undefined ? item.alpacaAccount.type : undefined,
@@ -7337,6 +7819,12 @@ exports.Order = {
7337
7819
  where: {
7338
7820
  id: item.id !== undefined ? item.id : undefined,
7339
7821
  url: item.url !== undefined ? item.url : undefined,
7822
+ assetId: item.assetId !== undefined ? {
7823
+ equals: item.assetId
7824
+ } : undefined,
7825
+ newsArticleId: item.newsArticleId !== undefined ? {
7826
+ equals: item.newsArticleId
7827
+ } : undefined,
7340
7828
  },
7341
7829
  create: {
7342
7830
  url: item.url !== undefined ? item.url : undefined,
@@ -7454,8 +7942,12 @@ exports.Order = {
7454
7942
  clientOrderId: props.clientOrderId !== undefined ? props.clientOrderId : undefined,
7455
7943
  actionId: props.actionId !== undefined ? props.actionId : undefined,
7456
7944
  stopLossId: props.stopLossId !== undefined ? props.stopLossId : undefined,
7457
- alpacaAccountId: props.alpacaAccountId !== undefined ? props.alpacaAccountId : undefined,
7458
- assetId: props.assetId !== undefined ? props.assetId : undefined,
7945
+ alpacaAccountId: props.alpacaAccountId !== undefined ? {
7946
+ equals: props.alpacaAccountId
7947
+ } : undefined,
7948
+ assetId: props.assetId !== undefined ? {
7949
+ equals: props.assetId
7950
+ } : undefined,
7459
7951
  side: props.side !== undefined ? props.side : undefined,
7460
7952
  type: props.type !== undefined ? props.type : undefined,
7461
7953
  orderClass: props.orderClass !== undefined ? props.orderClass : undefined,
@@ -7533,9 +8025,15 @@ exports.Order = {
7533
8025
  id: props.id !== undefined ? {
7534
8026
  equals: props.id
7535
8027
  } : undefined,
7536
- clientOrderId: props.clientOrderId !== undefined ? props.clientOrderId : undefined,
7537
- alpacaAccountId: props.alpacaAccountId !== undefined ? props.alpacaAccountId : undefined,
7538
- assetId: props.assetId !== undefined ? props.assetId : undefined,
8028
+ clientOrderId: props.clientOrderId !== undefined ? {
8029
+ equals: props.clientOrderId
8030
+ } : undefined,
8031
+ alpacaAccountId: props.alpacaAccountId !== undefined ? {
8032
+ equals: props.alpacaAccountId
8033
+ } : undefined,
8034
+ assetId: props.assetId !== undefined ? {
8035
+ equals: props.assetId
8036
+ } : undefined,
7539
8037
  side: props.side !== undefined ? props.side : undefined,
7540
8038
  type: props.type !== undefined ? props.type : undefined,
7541
8039
  orderClass: props.orderClass !== undefined ? props.orderClass : undefined,
@@ -7545,7 +8043,9 @@ exports.Order = {
7545
8043
  updatedAt: props.updatedAt !== undefined ? props.updatedAt : undefined,
7546
8044
  submittedAt: props.submittedAt !== undefined ? props.submittedAt : undefined,
7547
8045
  filledAt: props.filledAt !== undefined ? props.filledAt : undefined,
7548
- actionId: props.actionId !== undefined ? props.actionId : undefined,
8046
+ actionId: props.actionId !== undefined ? {
8047
+ equals: props.actionId
8048
+ } : undefined,
7549
8049
  expirationDate: props.expirationDate !== undefined ? props.expirationDate : undefined,
7550
8050
  optionType: props.optionType !== undefined ? props.optionType : undefined,
7551
8051
  },