@@ -76,6 +76,15 @@ exception.
76
76
.. automethod :: schwab.streaming.StreamClient.login
77
77
78
78
79
+ -----------
80
+ Logging Out
81
+ -----------
82
+
83
+ For a clean exit, it's recommended to log out of the stream when you're done.
84
+
85
+ .. automethod :: schwab.streaming.StreamClient.logout
86
+
87
+
79
88
----------------------
80
89
Subscribing to Streams
81
90
----------------------
@@ -96,14 +105,24 @@ subscription methods again seems to clear the old subscription and create a new
96
105
one. Note this behavior is not officially documented, so this interpretation may
97
106
be incorrect.
98
107
108
+
109
+ ----------------------
110
+ Add symbols to Streams
111
+ ----------------------
112
+
113
+ These functions have names that follow the pattern ``SERVICE_NAME_add ``.
114
+ These functions send a request to add to the list of subscribed symbols for a
115
+ particular data stream.
116
+
117
+
99
118
-------------------------
100
119
Un-Subscribing to Streams
101
120
-------------------------
102
121
103
- These functions have names that follow the pattern ``SERVICE_NAME_unsubs ``.
104
- These functions send a request to disable the symbols of a streaming data for a
105
- particular data stream. They are *not * thread safe, so they should only be
106
- called in series. When unsubscribing to services with symbols, symbols which
122
+ These functions have names that follow the pattern ``SERVICE_NAME_unsubs ``.
123
+ These functions send a request to disable the symbols of a streaming data for a
124
+ particular data stream. They are *not * thread safe, so they should only be
125
+ called in series. When unsubscribing to services with symbols, symbols which
107
126
were not explicitly unsubscribed remain subscribed.
108
127
109
128
@@ -224,12 +243,15 @@ to our `Discord server <https://discord.gg/BEr6y6Xqyv>`__. We'll be updating
224
243
this page as we discover new things.
225
244
226
245
The following streams are confirmed working:
227
- * :ref: `equity_charts `
228
- * :ref: `level_one_quotes_stream `
229
- * :ref: `level_one_option_stream `
246
+ * :ref: `charts `
247
+ * :ref: `level_one `
230
248
* :ref: `level_two `
249
+ * :ref: `screener `
250
+ * :ref: `account_activity `
231
251
232
252
253
+ .. _charts :
254
+
233
255
++++++++++++
234
256
OHLCV Charts
235
257
++++++++++++
@@ -293,6 +315,7 @@ Level one quotes for equities traded on NYSE, AMEX, and PACIFIC.
293
315
294
316
.. automethod :: schwab.streaming::StreamClient.level_one_equity_subs
295
317
.. automethod :: schwab.streaming::StreamClient.level_one_equity_unsubs
318
+ .. automethod :: schwab.streaming::StreamClient.level_one_equity_add
296
319
.. automethod :: schwab.streaming::StreamClient.add_level_one_equity_handler
297
320
.. autoclass :: schwab.streaming::StreamClient.LevelOneEquityFields
298
321
:members:
@@ -311,12 +334,15 @@ available option symbols.
311
334
312
335
.. automethod :: schwab.streaming::StreamClient.level_one_option_subs
313
336
.. automethod :: schwab.streaming::StreamClient.level_one_option_unsubs
337
+ .. automethod :: schwab.streaming::StreamClient.level_one_option_add
314
338
.. automethod :: schwab.streaming::StreamClient.add_level_one_option_handler
315
339
.. autoclass :: schwab.streaming::StreamClient.LevelOneOptionFields
316
340
:members:
317
341
:undoc-members:
318
342
319
343
344
+ .. _level_one_futures_stream :
345
+
320
346
--------------
321
347
Futures Quotes
322
348
--------------
@@ -325,25 +351,14 @@ Level one quotes for futures.
325
351
326
352
.. automethod :: schwab.streaming::StreamClient.level_one_futures_subs
327
353
.. automethod :: schwab.streaming::StreamClient.level_one_futures_unsubs
354
+ .. automethod :: schwab.streaming::StreamClient.level_one_futures_add
328
355
.. automethod :: schwab.streaming::StreamClient.add_level_one_futures_handler
329
356
.. autoclass :: schwab.streaming::StreamClient.LevelOneFuturesFields
330
357
:members:
331
358
:undoc-members:
332
359
333
360
334
- ------------
335
- Forex Quotes
336
- ------------
337
-
338
- Level one quotes for foreign exchange pairs.
339
-
340
- .. automethod :: schwab.streaming::StreamClient.level_one_forex_subs
341
- .. automethod :: schwab.streaming::StreamClient.level_one_forex_unsubs
342
- .. automethod :: schwab.streaming::StreamClient.add_level_one_forex_handler
343
- .. autoclass :: schwab.streaming::StreamClient.LevelOneForexFields
344
- :members:
345
- :undoc-members:
346
-
361
+ .. _level_one_futures_options_stream :
347
362
348
363
----------------------
349
364
Futures Options Quotes
@@ -353,12 +368,30 @@ Level one quotes for futures options.
353
368
354
369
.. automethod :: schwab.streaming::StreamClient.level_one_futures_options_subs
355
370
.. automethod :: schwab.streaming::StreamClient.level_one_futures_options_unsubs
371
+ .. automethod :: schwab.streaming::StreamClient.level_one_futures_options_add
356
372
.. automethod :: schwab.streaming::StreamClient.add_level_one_futures_options_handler
357
373
.. autoclass :: schwab.streaming::StreamClient.LevelOneFuturesOptionsFields
358
374
:members:
359
375
:undoc-members:
360
376
361
377
378
+ .. _level_one_forex_stream :
379
+
380
+ ------------
381
+ Forex Quotes
382
+ ------------
383
+
384
+ Level one quotes for foreign exchange pairs.
385
+
386
+ .. automethod :: schwab.streaming::StreamClient.level_one_forex_subs
387
+ .. automethod :: schwab.streaming::StreamClient.level_one_forex_unsubs
388
+ .. automethod :: schwab.streaming::StreamClient.level_one_forex_add
389
+ .. automethod :: schwab.streaming::StreamClient.add_level_one_forex_handler
390
+ .. autoclass :: schwab.streaming::StreamClient.LevelOneForexFields
391
+ :members:
392
+ :undoc-members:
393
+
394
+
362
395
.. _level_two :
363
396
364
397
++++++++++++++++++++
@@ -419,12 +452,14 @@ book is called "listed." Testing indicates this stream corresponds to the NYSE
419
452
book, but if you find any behavior that suggests otherwise please
420
453
`let us know <https://github.com/alexgolec/schwab-api/issues >`__.
421
454
422
- .. automethod :: schwab.streaming::StreamClient.listed_book_subs
423
- .. automethod :: schwab.streaming::StreamClient.listed_book_unsubs
424
- .. automethod :: schwab.streaming::StreamClient.add_listed_book_handler
455
+ .. automethod :: schwab.streaming::StreamClient.nyse_book_subs
456
+ .. automethod :: schwab.streaming::StreamClient.nyse_book_unsubs
457
+ .. automethod :: schwab.streaming::StreamClient.nyse_book_add
458
+ .. automethod :: schwab.streaming::StreamClient.add_nyse_book_handler
425
459
426
460
.. automethod :: schwab.streaming::StreamClient.nasdaq_book_subs
427
461
.. automethod :: schwab.streaming::StreamClient.nasdaq_book_unsubs
462
+ .. automethod :: schwab.streaming::StreamClient.nasdaq_book_add
428
463
.. automethod :: schwab.streaming::StreamClient.add_nasdaq_book_handler
429
464
430
465
@@ -440,64 +475,60 @@ exchanges, although this is an admittedly an uneducated guess.
440
475
441
476
.. automethod :: schwab.streaming::StreamClient.options_book_subs
442
477
.. automethod :: schwab.streaming::StreamClient.options_book_unsubs
478
+ .. automethod :: schwab.streaming::StreamClient.options_book_add
443
479
.. automethod :: schwab.streaming::StreamClient.add_options_book_handler
444
480
445
481
446
- ++++++++++++
447
- Time of Sale
448
- ++++++++++++
482
+ .. _screener :
449
483
450
- The data in :ref: `level_two ` describes the bids and asks for various
451
- instruments, but by itself is insufficient to determine when trades actually
452
- take place. The time of sale streams notify on trades as they happen. Together
453
- with the level two data, they provide a fairly complete picture of what is
454
- happening on an exchange.
484
+ ++++++++
485
+ Screener
486
+ ++++++++
455
487
456
- All time of sale streams uss a common set of fields:
488
+ Top 10 advances and decliners by volume, trades, percent change and average percent
489
+ volume.
457
490
458
- .. autoclass :: schwab.streaming::StreamClient.TimesaleFields
459
- :members:
460
- :undoc-members:
491
+ Symbols in upper case and separated by commas.
461
492
493
+ (PREFIX)_(SORTFIELD)_(FREQUENCY) where PREFIX is:
494
+ * Indices: $COMPX $DJI, $SPX.X, INDEX_ALL
495
+ * Exchanges: NYSE, NASDAQ, OTCBB, EQUITY_ALL
496
+ * Option: OPTION_PUT, OPTION_CALL, OPTION_ALL
462
497
463
- -------------
464
- Equity Trades
465
- -------------
498
+ and sortField is:
499
+ * VOLUME, TRADES, PERCENT_CHANGE_UP, PERCENT_CHANGE_DOWN, AVERAGE_PERCENT_VOLUME
466
500
467
- .. automethod :: schwab.streaming::StreamClient.timesale_equity_subs
468
- .. automethod :: schwab.streaming::StreamClient.timesale_equity_unsubs
469
- .. automethod :: schwab.streaming::StreamClient.add_timesale_equity_handler
501
+ and frequency is:
502
+ * 0, 1, 5, 10, 30 60 minutes (0 is for all day)
470
503
504
+ Both the equity and option screener streams use a common set of fields:
471
505
472
- --------------
473
- Futures Trades
474
- --------------
506
+ .. autoclass :: schwab.streaming::StreamClient.ScreenerFields
507
+ :members:
508
+ :undoc-members:
475
509
476
- .. automethod :: schwab.streaming::StreamClient.timesale_futures_subs
477
- .. automethod :: schwab.streaming::StreamClient.timesale_futures_unsubs
478
- .. automethod :: schwab.streaming::StreamClient.add_timesale_futures_handler
479
510
511
+ ---------------
512
+ Screener Equity
513
+ ---------------
480
514
481
- --------------
482
- Options Trades
483
- --------------
515
+ .. automethod :: schwab.streaming::StreamClient.screener_equity_subs
516
+ .. automethod :: schwab.streaming::StreamClient.screener_equity_unsubs
517
+ .. automethod :: schwab.streaming::StreamClient.screener_equity_add
518
+ .. automethod :: schwab.streaming::StreamClient.add_screener_equity_handler
484
519
485
- .. automethod :: schwab.streaming::StreamClient.timesale_options_subs
486
- .. automethod :: schwab.streaming::StreamClient.timesale_options_unsubs
487
- .. automethod :: schwab.streaming::StreamClient.add_timesale_options_handler
488
520
521
+ ---------------
522
+ Screener Option
523
+ ---------------
489
524
490
- ++++++++++++++
491
- News Headlines
492
- ++++++++++++++
525
+ .. automethod :: schwab.streaming::StreamClient.screener_option_subs
526
+ .. automethod :: schwab.streaming::StreamClient.screener_option_unsubs
527
+ .. automethod :: schwab.streaming::StreamClient.screener_option_add
528
+ .. automethod :: schwab.streaming::StreamClient.add_screener_option_handler
493
529
494
- .. automethod :: schwab.streaming::StreamClient.news_headline_subs
495
- .. automethod :: schwab.streaming::StreamClient.news_headline_unsubs
496
- .. automethod :: schwab.streaming::StreamClient.add_news_headline_handler
497
- .. autoclass :: schwab.streaming::StreamClient.NewsHeadlineFields
498
- :members:
499
- :undoc-members:
500
530
531
+ .. _account_activity :
501
532
502
533
++++++++++++++++
503
534
Account Activity
0 commit comments