From b3f2824268c38614f52490f95e214a54a553cd12 Mon Sep 17 00:00:00 2001 From: Jas Date: Wed, 24 Aug 2022 20:19:33 -0400 Subject: [PATCH] v0.4.5 (#34) * removed unwrap expect on TDAClient * updated readme * fixed cargo clippy issues * run cargo fmt * updated Readme * cargo docs and cargo update. bumped attohttpc 0.22 * deleted extra directory in docs * updated readme --- Cargo.toml | 6 +- Readme.md | 15 +- .../implementors/core/clone/trait.Clone.js | 2 +- .../implementors/core/cmp/trait.PartialEq.js | 2 +- .../implementors/core/convert/trait.From.js | 3 + .../core/default/trait.Default.js | 2 +- docs/doc/implementors/core/fmt/trait.Debug.js | 2 +- .../implementors/core/fmt/trait.Display.js | 3 + .../implementors/core/marker/trait.Freeze.js | 2 +- .../implementors/core/marker/trait.Send.js | 2 +- .../core/marker/trait.StructuralPartialEq.js | 2 +- .../implementors/core/marker/trait.Sync.js | 2 +- .../implementors/core/marker/trait.Unpin.js | 2 +- .../panic/unwind_safe/trait.RefUnwindSafe.js | 2 +- .../panic/unwind_safe/trait.UnwindSafe.js | 2 +- .../serde/de/trait.Deserialize.js | 2 +- .../implementors/serde/ser/trait.Serialize.js | 2 +- .../doc/implementors/std/error/trait.Error.js | 3 + docs/doc/search-index.js | 2 +- docs/doc/source-files.js | 2 +- docs/doc/src/tdameritradeclient/auth.rs.html | 24 +-- .../authmanagedclient.rs.html | 10 +- docs/doc/src/tdameritradeclient/error.rs.html | 73 ++++++++ docs/doc/src/tdameritradeclient/lib.rs.html | 10 +- .../tdameritradeclient/model/account.rs.html | 18 +- .../src/tdameritradeclient/model/mod.rs.html | 38 ++++- .../model/optionchain.rs.html | 36 +++- .../model/pricehistory.rs.html | 3 +- .../tdameritradeclient/model/quote.rs.html | 20 +-- .../model/userprincipals.rs.html | 16 +- .../src/tdameritradeclient/tdaclient.rs.html | 54 +++--- docs/doc/tdameritradeclient/all.html | 2 +- docs/doc/tdameritradeclient/auth/index.html | 2 +- .../auth/struct.TDauth.html | 22 +-- .../error/enum.TDAClientError.html | 34 ++++ docs/doc/tdameritradeclient/error/index.html | 11 ++ .../tdameritradeclient/error/sidebar-items.js | 1 + docs/doc/tdameritradeclient/index.html | 7 +- .../model/account/struct.AccountRoot.html | 13 +- .../model/account/struct.CurrentBalances.html | 13 +- .../model/account/struct.InitialBalances.html | 13 +- .../model/account/struct.Instrument.html | 13 +- .../account/struct.OrderLegCollection.html | 13 +- .../model/account/struct.OrderStrategy.html | 13 +- .../model/account/struct.Position.html | 13 +- .../account/struct.ProjectedBalances.html | 13 +- .../account/struct.SecuritiesAccount.html | 13 +- docs/doc/tdameritradeclient/model/index.html | 2 +- .../model/optionchain/index.html | 2 +- .../model/optionchain/struct.OptionChain.html | 12 +- .../model/optionchain/struct.OptionQuote.html | 18 +- .../model/pricehistory/struct.Candle.html | 6 +- .../model/pricehistory/struct.History.html | 6 +- .../model/quote/enum.Quote.html | 8 +- .../tdameritradeclient/model/quote/index.html | 2 +- .../model/quote/struct.QEquity.html | 6 +- .../model/quote/struct.QFund.html | 6 +- .../model/quote/struct.QGeneral.html | 6 +- .../model/quote/struct.QIndex.html | 6 +- .../model/quote/struct.QOption.html | 6 +- .../model/token/struct.ErrorResponse.html | 4 +- .../model/token/struct.TokenResponse.html | 4 +- .../model/userprincipals/struct.Account.html | 13 +- .../userprincipals/struct.Authorizations.html | 13 +- .../model/userprincipals/struct.Key.html | 13 +- .../userprincipals/struct.Preferences.html | 13 +- .../model/userprincipals/struct.Quotes.html | 13 +- .../userprincipals/struct.StreamerInfo.html | 13 +- .../struct.StreamerSubscriptionKeys.html | 13 +- .../userprincipals/struct.UserPrincipals.html | 13 +- docs/doc/tdameritradeclient/sidebar-items.js | 2 +- .../tdameritradeclient/struct.TDAClient.html | 35 ++-- examples/accountinfo.rs | 12 +- examples/accountmodel.rs | 9 +- examples/createorder.rs | 12 +- examples/deleteorder.rs | 12 +- examples/history.rs | 8 +- examples/optionchain.rs | 8 +- examples/optionchainmodel.rs | 28 +-- examples/quotes.rs | 8 +- src/auth.rs | 23 +-- src/authmanagedclient.rs | 8 +- src/error.rs | 32 ++++ src/lib.rs | 6 +- src/model/account.rs | 18 +- src/model/mod.rs | 24 ++- src/model/optionchain.rs | 27 ++- src/model/pricehistory.rs | 2 +- src/model/quote.rs | 19 +-- src/model/userprincipals.rs | 16 +- src/tdaclient.rs | 52 +++--- tests/clienttests.rs | 159 ++++++++++++------ 92 files changed, 779 insertions(+), 497 deletions(-) create mode 100644 docs/doc/implementors/core/convert/trait.From.js create mode 100644 docs/doc/implementors/core/fmt/trait.Display.js create mode 100644 docs/doc/implementors/std/error/trait.Error.js create mode 100644 docs/doc/src/tdameritradeclient/error.rs.html create mode 100644 docs/doc/tdameritradeclient/error/enum.TDAClientError.html create mode 100644 docs/doc/tdameritradeclient/error/index.html create mode 100644 docs/doc/tdameritradeclient/error/sidebar-items.js create mode 100644 src/error.rs diff --git a/Cargo.toml b/Cargo.toml index d352d8f..1c690ea 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,17 +1,17 @@ [package] name = "tdameritradeclient" -version = "0.4.4" +version = "0.4.5" authors = ["Jas Bertovic "] edition = "2018" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -attohttpc = { version = "0.19.1", features = ["form"] } +attohttpc = { version = "0.22.0", features = ["form"] } serde_json = "1.0" serde = {version = "1.0", features = ["derive"]} url = "2.1.1" log = "0.4" [dev-dependencies] -env_logger = "0.9" +env_logger = "0.9" \ No newline at end of file diff --git a/Readme.md b/Readme.md index c439375..a538797 100644 --- a/Readme.md +++ b/Readme.md @@ -1,5 +1,12 @@ **Disclaimer:** I'm not endorsing and am not affiliated with TD Ameritrade. Be careful using the API and understand that actual orders can be created through this library. Read and understand the TD Ameritrade's api terms of service and documentation before using. +## Note Version 0.4.5 Changes +- (BREAKING CHANGE) all reqests (get, post, put, patch and delete) will now return `Result` instead of just `T` +- Added library errors `crate::error` +- Removed all expect and unwrap on requests from `TDAClient` +- updated option chain model +- cleaned up code with `cargo clippy` and `cargo fmt` + ## Note Version 0.4.4 Changes - Added error checking on TDauth module. Used when retrieving tokens. - Gave TDAClientAuth acces to TDauth struct @@ -33,11 +40,11 @@ For the examples and tests to work you will need to set environmental variables ``` use std::env; -use tdameritradeclient::{TDAClient, Endpoint, param}; +use tdameritradeclient::{TDAClient, Endpoint, param, error::TDAClient}; // Will need to set TDAUTHTOKEN as environmental variable containing a valid token -fn main() { +fn main() -> Result<(), TDAClientError> { //set token from environment variables let token = env::var("TDAUTHTOKEN").unwrap(); @@ -46,10 +53,12 @@ fn main() { let c = TDAClient::new(token); // get quotes for 3 symbols and execute - let resptxt: String = c.get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,SPY,INTC,IWM")]); + let resptxt: String = c.get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,SPY,INTC,IWM")])?; // output will be text string in json format println!("{:?}", resptxt); + + Ok(()) } ``` diff --git a/docs/doc/implementors/core/clone/trait.Clone.js b/docs/doc/implementors/core/clone/trait.Clone.js index da13831..4cad504 100644 --- a/docs/doc/implementors/core/clone/trait.Clone.js +++ b/docs/doc/implementors/core/clone/trait.Clone.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl Clone for TDauth","synthetic":false,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Clone for TDAClient","synthetic":false,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Clone for TDAClientAuth","synthetic":false,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Clone for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Clone for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Clone for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Clone for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Clone for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Clone for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Clone for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Clone for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Clone for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Clone for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Clone for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Clone for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Clone for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Clone for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Clone for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Clone for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Clone for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Clone for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Clone for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Clone for Quote","synthetic":false,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Clone for QEquity","synthetic":false,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Clone for QIndex","synthetic":false,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Clone for QOption","synthetic":false,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Clone for QFund","synthetic":false,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Clone for QGeneral","synthetic":false,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Clone for OptionChain","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Clone for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl Clone for TDauth","synthetic":false,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Clone for TDAClient","synthetic":false,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Clone for TDAClientAuth","synthetic":false,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Clone for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Clone for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Clone for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Clone for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Clone for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Clone for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Clone for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Clone for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Clone for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Clone for OptionChain","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Clone for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl Clone for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Clone for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Clone for Quote","synthetic":false,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Clone for QEquity","synthetic":false,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Clone for QIndex","synthetic":false,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Clone for QOption","synthetic":false,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Clone for QFund","synthetic":false,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Clone for QGeneral","synthetic":false,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Clone for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Clone for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Clone for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Clone for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Clone for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Clone for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Clone for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Clone for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/cmp/trait.PartialEq.js b/docs/doc/implementors/core/cmp/trait.PartialEq.js index 0453188..a415f89 100644 --- a/docs/doc/implementors/core/cmp/trait.PartialEq.js +++ b/docs/doc/implementors/core/cmp/trait.PartialEq.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl PartialEq<AccountRoot> for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl PartialEq<SecuritiesAccount> for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl PartialEq<Position> for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl PartialEq<Instrument> for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl PartialEq<InitialBalances> for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl PartialEq<CurrentBalances> for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl PartialEq<ProjectedBalances> for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl PartialEq<OrderStrategy> for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl PartialEq<OrderLegCollection> for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl PartialEq<UserPrincipals> for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl PartialEq<StreamerInfo> for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl PartialEq<Quotes> for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl PartialEq<StreamerSubscriptionKeys> for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl PartialEq<Key> for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl PartialEq<Account> for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl PartialEq<Preferences> for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl PartialEq<Authorizations> for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl PartialEq<History> for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl PartialEq<Candle> for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl PartialEq<OptionQuote> for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl PartialEq<OptionQuote> for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl PartialEq<History> for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl PartialEq<Candle> for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/convert/trait.From.js b/docs/doc/implementors/core/convert/trait.From.js new file mode 100644 index 0000000..01631b2 --- /dev/null +++ b/docs/doc/implementors/core/convert/trait.From.js @@ -0,0 +1,3 @@ +(function() {var implementors = {}; +implementors["tdameritradeclient"] = [{"text":"impl From<Error> for TDAClientError","synthetic":false,"types":["tdameritradeclient::error::TDAClientError"]},{"text":"impl From<Error> for TDAClientError","synthetic":false,"types":["tdameritradeclient::error::TDAClientError"]}]; +if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/default/trait.Default.js b/docs/doc/implementors/core/default/trait.Default.js index 1f71b19..25ed632 100644 --- a/docs/doc/implementors/core/default/trait.Default.js +++ b/docs/doc/implementors/core/default/trait.Default.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl Default for TDauth","synthetic":false,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Default for TDAClient","synthetic":false,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Default for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Default for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Default for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Default for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Default for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Default for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Default for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Default for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Default for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Default for TokenResponse","synthetic":false,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Default for ErrorResponse","synthetic":false,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Default for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Default for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Default for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Default for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Default for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Default for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Default for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Default for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Default for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Default for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Default for OptionChain","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Default for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl Default for TDauth","synthetic":false,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Default for TDAClient","synthetic":false,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Default for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Default for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Default for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Default for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Default for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Default for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Default for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Default for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Default for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Default for OptionChain","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Default for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl Default for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Default for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Default for TokenResponse","synthetic":false,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Default for ErrorResponse","synthetic":false,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Default for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Default for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Default for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Default for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Default for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Default for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Default for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Default for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/fmt/trait.Debug.js b/docs/doc/implementors/core/fmt/trait.Debug.js index 340fcf8..910f5cf 100644 --- a/docs/doc/implementors/core/fmt/trait.Debug.js +++ b/docs/doc/implementors/core/fmt/trait.Debug.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl Debug for TDauth","synthetic":false,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Debug for Empty","synthetic":false,"types":["tdameritradeclient::param::Empty"]},{"text":"impl Debug for Account","synthetic":false,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> Debug for Order<'a>","synthetic":false,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> Debug for History<'a>","synthetic":false,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> Debug for OptionChain<'a>","synthetic":false,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> Debug for Transactions<'a>","synthetic":false,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> Debug for Instruments<'a>","synthetic":false,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl Debug for Movers","synthetic":false,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> Debug for Endpoint<'a>","synthetic":false,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl Debug for TDAClient","synthetic":false,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Debug for TDAClientAuth","synthetic":false,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Debug for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Debug for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Debug for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Debug for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Debug for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Debug for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Debug for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Debug for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Debug for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Debug for TokenResponse","synthetic":false,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Debug for ErrorResponse","synthetic":false,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Debug for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Debug for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Debug for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Debug for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Debug for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Debug for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Debug for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Debug for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Debug for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Debug for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Debug for Quote","synthetic":false,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Debug for QEquity","synthetic":false,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Debug for QIndex","synthetic":false,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Debug for QOption","synthetic":false,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Debug for QFund","synthetic":false,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Debug for QGeneral","synthetic":false,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Debug for OptionChain","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Debug for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl Debug for TDauth","synthetic":false,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Debug for Empty","synthetic":false,"types":["tdameritradeclient::param::Empty"]},{"text":"impl Debug for Account","synthetic":false,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> Debug for Order<'a>","synthetic":false,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> Debug for History<'a>","synthetic":false,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> Debug for OptionChain<'a>","synthetic":false,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> Debug for Transactions<'a>","synthetic":false,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> Debug for Instruments<'a>","synthetic":false,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl Debug for Movers","synthetic":false,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> Debug for Endpoint<'a>","synthetic":false,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl Debug for TDAClient","synthetic":false,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Debug for TDAClientAuth","synthetic":false,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Debug for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Debug for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Debug for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Debug for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Debug for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Debug for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Debug for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Debug for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Debug for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Debug for OptionChain","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Debug for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl Debug for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Debug for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Debug for Quote","synthetic":false,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Debug for QEquity","synthetic":false,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Debug for QIndex","synthetic":false,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Debug for QOption","synthetic":false,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Debug for QFund","synthetic":false,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Debug for QGeneral","synthetic":false,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Debug for TokenResponse","synthetic":false,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Debug for ErrorResponse","synthetic":false,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Debug for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Debug for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Debug for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Debug for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Debug for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Debug for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Debug for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Debug for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Debug for TDAClientError","synthetic":false,"types":["tdameritradeclient::error::TDAClientError"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/fmt/trait.Display.js b/docs/doc/implementors/core/fmt/trait.Display.js new file mode 100644 index 0000000..155a89c --- /dev/null +++ b/docs/doc/implementors/core/fmt/trait.Display.js @@ -0,0 +1,3 @@ +(function() {var implementors = {}; +implementors["tdameritradeclient"] = [{"text":"impl Display for TDAClientError","synthetic":false,"types":["tdameritradeclient::error::TDAClientError"]}]; +if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/marker/trait.Freeze.js b/docs/doc/implementors/core/marker/trait.Freeze.js index 03c7415..cac83dc 100644 --- a/docs/doc/implementors/core/marker/trait.Freeze.js +++ b/docs/doc/implementors/core/marker/trait.Freeze.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl Freeze for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Freeze for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl Freeze for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> Freeze for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> Freeze for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> Freeze for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> Freeze for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> Freeze for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> Freeze for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> Freeze for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl Freeze for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> Freeze for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl Freeze for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Freeze for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Freeze for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Freeze for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Freeze for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Freeze for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Freeze for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Freeze for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Freeze for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Freeze for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Freeze for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Freeze for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Freeze for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Freeze for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Freeze for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Freeze for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Freeze for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Freeze for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Freeze for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Freeze for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Freeze for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Freeze for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Freeze for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Freeze for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Freeze for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Freeze for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Freeze for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Freeze for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Freeze for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Freeze for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Freeze for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl Freeze for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Freeze for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl Freeze for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> Freeze for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> Freeze for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> Freeze for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> Freeze for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> Freeze for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> Freeze for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> Freeze for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl Freeze for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> Freeze for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl Freeze for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Freeze for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Freeze for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Freeze for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Freeze for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Freeze for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Freeze for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Freeze for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Freeze for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Freeze for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Freeze for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Freeze for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Freeze for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl Freeze for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Freeze for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Freeze for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Freeze for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Freeze for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Freeze for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Freeze for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Freeze for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Freeze for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Freeze for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Freeze for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Freeze for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Freeze for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Freeze for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Freeze for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Freeze for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Freeze for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Freeze for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Freeze for TDAClientError","synthetic":true,"types":["tdameritradeclient::error::TDAClientError"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/marker/trait.Send.js b/docs/doc/implementors/core/marker/trait.Send.js index 61f00fe..0287e2e 100644 --- a/docs/doc/implementors/core/marker/trait.Send.js +++ b/docs/doc/implementors/core/marker/trait.Send.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl Send for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Send for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl Send for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> Send for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> Send for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> Send for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> Send for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> Send for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> Send for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> Send for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl Send for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> Send for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl Send for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Send for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Send for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Send for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Send for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Send for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Send for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Send for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Send for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Send for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Send for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Send for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Send for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Send for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Send for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Send for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Send for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Send for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Send for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Send for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Send for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Send for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Send for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Send for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Send for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Send for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Send for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Send for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Send for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Send for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Send for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl Send for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Send for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl Send for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> Send for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> Send for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> Send for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> Send for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> Send for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> Send for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> Send for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl Send for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> Send for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl Send for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Send for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Send for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Send for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Send for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Send for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Send for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Send for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Send for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Send for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Send for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Send for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Send for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl Send for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Send for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Send for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Send for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Send for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Send for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Send for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Send for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Send for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Send for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Send for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Send for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Send for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Send for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Send for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Send for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Send for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Send for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Send for TDAClientError","synthetic":true,"types":["tdameritradeclient::error::TDAClientError"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/marker/trait.StructuralPartialEq.js b/docs/doc/implementors/core/marker/trait.StructuralPartialEq.js index 7b6cc7c..47f821a 100644 --- a/docs/doc/implementors/core/marker/trait.StructuralPartialEq.js +++ b/docs/doc/implementors/core/marker/trait.StructuralPartialEq.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl StructuralPartialEq for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl StructuralPartialEq for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl StructuralPartialEq for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl StructuralPartialEq for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl StructuralPartialEq for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl StructuralPartialEq for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl StructuralPartialEq for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl StructuralPartialEq for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl StructuralPartialEq for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl StructuralPartialEq for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl StructuralPartialEq for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl StructuralPartialEq for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl StructuralPartialEq for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl StructuralPartialEq for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl StructuralPartialEq for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl StructuralPartialEq for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl StructuralPartialEq for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl StructuralPartialEq for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl StructuralPartialEq for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl StructuralPartialEq for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl StructuralPartialEq for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl StructuralPartialEq for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl StructuralPartialEq for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/marker/trait.Sync.js b/docs/doc/implementors/core/marker/trait.Sync.js index cf95ef1..2488574 100644 --- a/docs/doc/implementors/core/marker/trait.Sync.js +++ b/docs/doc/implementors/core/marker/trait.Sync.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl Sync for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Sync for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl Sync for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> Sync for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> Sync for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> Sync for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> Sync for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> Sync for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> Sync for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> Sync for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl Sync for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> Sync for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl Sync for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Sync for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Sync for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Sync for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Sync for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Sync for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Sync for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Sync for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Sync for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Sync for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Sync for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Sync for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Sync for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Sync for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Sync for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Sync for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Sync for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Sync for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Sync for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Sync for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Sync for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Sync for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Sync for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Sync for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Sync for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Sync for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Sync for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Sync for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Sync for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Sync for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Sync for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl Sync for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Sync for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl Sync for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> Sync for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> Sync for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> Sync for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> Sync for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> Sync for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> Sync for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> Sync for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl Sync for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> Sync for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl Sync for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Sync for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Sync for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Sync for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Sync for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Sync for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Sync for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Sync for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Sync for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Sync for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Sync for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Sync for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Sync for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl Sync for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Sync for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Sync for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Sync for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Sync for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Sync for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Sync for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Sync for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Sync for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Sync for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Sync for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Sync for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Sync for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Sync for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Sync for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Sync for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Sync for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Sync for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Sync for TDAClientError","synthetic":true,"types":["tdameritradeclient::error::TDAClientError"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/marker/trait.Unpin.js b/docs/doc/implementors/core/marker/trait.Unpin.js index ae12a34..09dc65d 100644 --- a/docs/doc/implementors/core/marker/trait.Unpin.js +++ b/docs/doc/implementors/core/marker/trait.Unpin.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl Unpin for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Unpin for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl Unpin for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> Unpin for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> Unpin for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> Unpin for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> Unpin for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> Unpin for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> Unpin for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> Unpin for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl Unpin for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> Unpin for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl Unpin for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Unpin for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Unpin for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Unpin for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Unpin for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Unpin for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Unpin for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Unpin for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Unpin for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Unpin for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Unpin for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Unpin for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Unpin for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Unpin for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Unpin for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Unpin for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Unpin for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Unpin for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Unpin for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Unpin for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Unpin for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Unpin for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Unpin for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Unpin for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Unpin for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Unpin for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Unpin for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Unpin for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Unpin for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Unpin for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Unpin for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl Unpin for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Unpin for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl Unpin for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> Unpin for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> Unpin for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> Unpin for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> Unpin for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> Unpin for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> Unpin for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> Unpin for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl Unpin for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> Unpin for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl Unpin for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl Unpin for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl Unpin for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Unpin for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Unpin for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Unpin for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Unpin for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Unpin for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Unpin for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Unpin for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Unpin for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Unpin for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl Unpin for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl Unpin for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Unpin for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Unpin for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Unpin for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Unpin for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Unpin for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Unpin for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Unpin for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Unpin for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl Unpin for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl Unpin for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Unpin for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Unpin for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Unpin for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Unpin for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Unpin for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Unpin for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Unpin for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Unpin for TDAClientError","synthetic":true,"types":["tdameritradeclient::error::TDAClientError"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/panic/unwind_safe/trait.RefUnwindSafe.js b/docs/doc/implementors/core/panic/unwind_safe/trait.RefUnwindSafe.js index 72403d9..d9af313 100644 --- a/docs/doc/implementors/core/panic/unwind_safe/trait.RefUnwindSafe.js +++ b/docs/doc/implementors/core/panic/unwind_safe/trait.RefUnwindSafe.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl RefUnwindSafe for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl RefUnwindSafe for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl RefUnwindSafe for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> RefUnwindSafe for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> RefUnwindSafe for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> RefUnwindSafe for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> RefUnwindSafe for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> RefUnwindSafe for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> RefUnwindSafe for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> RefUnwindSafe for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl RefUnwindSafe for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> RefUnwindSafe for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl RefUnwindSafe for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl RefUnwindSafe for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl RefUnwindSafe for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl RefUnwindSafe for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl RefUnwindSafe for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl RefUnwindSafe for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl RefUnwindSafe for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl RefUnwindSafe for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl RefUnwindSafe for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl RefUnwindSafe for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl RefUnwindSafe for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl RefUnwindSafe for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl RefUnwindSafe for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl RefUnwindSafe for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl RefUnwindSafe for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl RefUnwindSafe for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl RefUnwindSafe for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl RefUnwindSafe for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl RefUnwindSafe for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl RefUnwindSafe for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl RefUnwindSafe for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl RefUnwindSafe for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl RefUnwindSafe for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl RefUnwindSafe for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl RefUnwindSafe for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl RefUnwindSafe for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl RefUnwindSafe for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl RefUnwindSafe for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl RefUnwindSafe for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl RefUnwindSafe for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl RefUnwindSafe for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl RefUnwindSafe for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl RefUnwindSafe for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl RefUnwindSafe for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> RefUnwindSafe for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> RefUnwindSafe for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> RefUnwindSafe for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> RefUnwindSafe for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> RefUnwindSafe for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> RefUnwindSafe for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> RefUnwindSafe for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl RefUnwindSafe for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> RefUnwindSafe for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl RefUnwindSafe for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl RefUnwindSafe for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl RefUnwindSafe for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl RefUnwindSafe for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl RefUnwindSafe for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl RefUnwindSafe for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl RefUnwindSafe for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl RefUnwindSafe for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl RefUnwindSafe for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl RefUnwindSafe for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl RefUnwindSafe for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl RefUnwindSafe for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl RefUnwindSafe for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl RefUnwindSafe for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl RefUnwindSafe for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl RefUnwindSafe for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl RefUnwindSafe for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl RefUnwindSafe for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl RefUnwindSafe for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl RefUnwindSafe for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl RefUnwindSafe for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl RefUnwindSafe for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl RefUnwindSafe for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl RefUnwindSafe for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl RefUnwindSafe for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl RefUnwindSafe for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl RefUnwindSafe for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl RefUnwindSafe for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl RefUnwindSafe for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl RefUnwindSafe for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl RefUnwindSafe for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl !RefUnwindSafe for TDAClientError","synthetic":true,"types":["tdameritradeclient::error::TDAClientError"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/core/panic/unwind_safe/trait.UnwindSafe.js b/docs/doc/implementors/core/panic/unwind_safe/trait.UnwindSafe.js index b308220..47f5cd1 100644 --- a/docs/doc/implementors/core/panic/unwind_safe/trait.UnwindSafe.js +++ b/docs/doc/implementors/core/panic/unwind_safe/trait.UnwindSafe.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl UnwindSafe for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl UnwindSafe for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl UnwindSafe for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> UnwindSafe for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> UnwindSafe for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> UnwindSafe for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> UnwindSafe for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> UnwindSafe for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> UnwindSafe for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> UnwindSafe for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl UnwindSafe for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> UnwindSafe for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl UnwindSafe for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl UnwindSafe for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl UnwindSafe for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl UnwindSafe for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl UnwindSafe for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl UnwindSafe for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl UnwindSafe for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl UnwindSafe for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl UnwindSafe for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl UnwindSafe for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl UnwindSafe for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl UnwindSafe for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl UnwindSafe for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl UnwindSafe for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl UnwindSafe for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl UnwindSafe for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl UnwindSafe for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl UnwindSafe for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl UnwindSafe for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl UnwindSafe for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl UnwindSafe for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl UnwindSafe for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl UnwindSafe for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl UnwindSafe for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl UnwindSafe for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl UnwindSafe for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl UnwindSafe for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl UnwindSafe for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl UnwindSafe for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl UnwindSafe for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl UnwindSafe for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl UnwindSafe for TDauth","synthetic":true,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl UnwindSafe for Empty","synthetic":true,"types":["tdameritradeclient::param::Empty"]},{"text":"impl UnwindSafe for Account","synthetic":true,"types":["tdameritradeclient::param::Account"]},{"text":"impl<'a> UnwindSafe for Quotes<'a>","synthetic":true,"types":["tdameritradeclient::param::Quotes"]},{"text":"impl<'a> UnwindSafe for Order<'a>","synthetic":true,"types":["tdameritradeclient::param::Order"]},{"text":"impl<'a> UnwindSafe for History<'a>","synthetic":true,"types":["tdameritradeclient::param::History"]},{"text":"impl<'a> UnwindSafe for OptionChain<'a>","synthetic":true,"types":["tdameritradeclient::param::OptionChain"]},{"text":"impl<'a> UnwindSafe for Transactions<'a>","synthetic":true,"types":["tdameritradeclient::param::Transactions"]},{"text":"impl<'a> UnwindSafe for Instruments<'a>","synthetic":true,"types":["tdameritradeclient::param::Instruments"]},{"text":"impl<'a> UnwindSafe for MarketHours<'a>","synthetic":true,"types":["tdameritradeclient::param::MarketHours"]},{"text":"impl UnwindSafe for Movers","synthetic":true,"types":["tdameritradeclient::param::Movers"]},{"text":"impl<'a> UnwindSafe for Endpoint<'a>","synthetic":true,"types":["tdameritradeclient::request::Endpoint"]},{"text":"impl UnwindSafe for TDAClient","synthetic":true,"types":["tdameritradeclient::tdaclient::TDAClient"]},{"text":"impl UnwindSafe for TDAClientAuth","synthetic":true,"types":["tdameritradeclient::authmanagedclient::TDAClientAuth"]},{"text":"impl UnwindSafe for AccountRoot","synthetic":true,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl UnwindSafe for SecuritiesAccount","synthetic":true,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl UnwindSafe for Position","synthetic":true,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl UnwindSafe for Instrument","synthetic":true,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl UnwindSafe for InitialBalances","synthetic":true,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl UnwindSafe for CurrentBalances","synthetic":true,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl UnwindSafe for ProjectedBalances","synthetic":true,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl UnwindSafe for OrderStrategy","synthetic":true,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl UnwindSafe for OrderLegCollection","synthetic":true,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl UnwindSafe for OptionChain","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl UnwindSafe for OptionQuote","synthetic":true,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl UnwindSafe for History","synthetic":true,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl UnwindSafe for Candle","synthetic":true,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl UnwindSafe for Quote","synthetic":true,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl UnwindSafe for QEquity","synthetic":true,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl UnwindSafe for QIndex","synthetic":true,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl UnwindSafe for QOption","synthetic":true,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl UnwindSafe for QFund","synthetic":true,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl UnwindSafe for QGeneral","synthetic":true,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl UnwindSafe for TokenResponse","synthetic":true,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl UnwindSafe for ErrorResponse","synthetic":true,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl UnwindSafe for UserPrincipals","synthetic":true,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl UnwindSafe for StreamerInfo","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl UnwindSafe for Quotes","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl UnwindSafe for StreamerSubscriptionKeys","synthetic":true,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl UnwindSafe for Key","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl UnwindSafe for Account","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl UnwindSafe for Preferences","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl UnwindSafe for Authorizations","synthetic":true,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl !UnwindSafe for TDAClientError","synthetic":true,"types":["tdameritradeclient::error::TDAClientError"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/serde/de/trait.Deserialize.js b/docs/doc/implementors/serde/de/trait.Deserialize.js index 11d0f2a..d7dc28b 100644 --- a/docs/doc/implementors/serde/de/trait.Deserialize.js +++ b/docs/doc/implementors/serde/de/trait.Deserialize.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl<'de> Deserialize<'de> for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl<'de> Deserialize<'de> for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl<'de> Deserialize<'de> for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl<'de> Deserialize<'de> for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl<'de> Deserialize<'de> for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl<'de> Deserialize<'de> for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl<'de> Deserialize<'de> for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl<'de> Deserialize<'de> for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl<'de> Deserialize<'de> for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl<'de> Deserialize<'de> for TokenResponse","synthetic":false,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl<'de> Deserialize<'de> for ErrorResponse","synthetic":false,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl<'de> Deserialize<'de> for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl<'de> Deserialize<'de> for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl<'de> Deserialize<'de> for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl<'de> Deserialize<'de> for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl<'de> Deserialize<'de> for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl<'de> Deserialize<'de> for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl<'de> Deserialize<'de> for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl<'de> Deserialize<'de> for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl<'de> Deserialize<'de> for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl<'de> Deserialize<'de> for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl<'de> Deserialize<'de> for Quote","synthetic":false,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl<'de> Deserialize<'de> for QEquity","synthetic":false,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl<'de> Deserialize<'de> for QIndex","synthetic":false,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl<'de> Deserialize<'de> for QOption","synthetic":false,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl<'de> Deserialize<'de> for QFund","synthetic":false,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl<'de> Deserialize<'de> for QGeneral","synthetic":false,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl<'de> Deserialize<'de> for OptionChain","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl<'de> Deserialize<'de> for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]}]; +implementors["tdameritradeclient"] = [{"text":"impl<'de> Deserialize<'de> for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl<'de> Deserialize<'de> for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl<'de> Deserialize<'de> for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl<'de> Deserialize<'de> for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl<'de> Deserialize<'de> for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl<'de> Deserialize<'de> for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl<'de> Deserialize<'de> for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl<'de> Deserialize<'de> for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl<'de> Deserialize<'de> for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl<'de> Deserialize<'de> for OptionChain","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionChain"]},{"text":"impl<'de> Deserialize<'de> for OptionQuote","synthetic":false,"types":["tdameritradeclient::model::optionchain::OptionQuote"]},{"text":"impl<'de> Deserialize<'de> for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl<'de> Deserialize<'de> for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl<'de> Deserialize<'de> for Quote","synthetic":false,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl<'de> Deserialize<'de> for QEquity","synthetic":false,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl<'de> Deserialize<'de> for QIndex","synthetic":false,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl<'de> Deserialize<'de> for QOption","synthetic":false,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl<'de> Deserialize<'de> for QFund","synthetic":false,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl<'de> Deserialize<'de> for QGeneral","synthetic":false,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl<'de> Deserialize<'de> for TokenResponse","synthetic":false,"types":["tdameritradeclient::model::token::TokenResponse"]},{"text":"impl<'de> Deserialize<'de> for ErrorResponse","synthetic":false,"types":["tdameritradeclient::model::token::ErrorResponse"]},{"text":"impl<'de> Deserialize<'de> for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl<'de> Deserialize<'de> for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl<'de> Deserialize<'de> for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl<'de> Deserialize<'de> for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl<'de> Deserialize<'de> for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl<'de> Deserialize<'de> for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl<'de> Deserialize<'de> for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl<'de> Deserialize<'de> for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/serde/ser/trait.Serialize.js b/docs/doc/implementors/serde/ser/trait.Serialize.js index fcf041f..96a0d87 100644 --- a/docs/doc/implementors/serde/ser/trait.Serialize.js +++ b/docs/doc/implementors/serde/ser/trait.Serialize.js @@ -1,3 +1,3 @@ (function() {var implementors = {}; -implementors["tdameritradeclient"] = [{"text":"impl Serialize for TDauth","synthetic":false,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Serialize for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Serialize for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Serialize for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Serialize for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Serialize for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Serialize for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Serialize for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Serialize for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Serialize for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Serialize for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Serialize for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Serialize for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Serialize for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Serialize for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Serialize for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Serialize for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Serialize for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]},{"text":"impl Serialize for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Serialize for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Serialize for Quote","synthetic":false,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Serialize for QEquity","synthetic":false,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Serialize for QIndex","synthetic":false,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Serialize for QOption","synthetic":false,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Serialize for QFund","synthetic":false,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Serialize for QGeneral","synthetic":false,"types":["tdameritradeclient::model::quote::QGeneral"]}]; +implementors["tdameritradeclient"] = [{"text":"impl Serialize for TDauth","synthetic":false,"types":["tdameritradeclient::auth::TDauth"]},{"text":"impl Serialize for AccountRoot","synthetic":false,"types":["tdameritradeclient::model::account::AccountRoot"]},{"text":"impl Serialize for SecuritiesAccount","synthetic":false,"types":["tdameritradeclient::model::account::SecuritiesAccount"]},{"text":"impl Serialize for Position","synthetic":false,"types":["tdameritradeclient::model::account::Position"]},{"text":"impl Serialize for Instrument","synthetic":false,"types":["tdameritradeclient::model::account::Instrument"]},{"text":"impl Serialize for InitialBalances","synthetic":false,"types":["tdameritradeclient::model::account::InitialBalances"]},{"text":"impl Serialize for CurrentBalances","synthetic":false,"types":["tdameritradeclient::model::account::CurrentBalances"]},{"text":"impl Serialize for ProjectedBalances","synthetic":false,"types":["tdameritradeclient::model::account::ProjectedBalances"]},{"text":"impl Serialize for OrderStrategy","synthetic":false,"types":["tdameritradeclient::model::account::OrderStrategy"]},{"text":"impl Serialize for OrderLegCollection","synthetic":false,"types":["tdameritradeclient::model::account::OrderLegCollection"]},{"text":"impl Serialize for History","synthetic":false,"types":["tdameritradeclient::model::pricehistory::History"]},{"text":"impl Serialize for Candle","synthetic":false,"types":["tdameritradeclient::model::pricehistory::Candle"]},{"text":"impl Serialize for Quote","synthetic":false,"types":["tdameritradeclient::model::quote::Quote"]},{"text":"impl Serialize for QEquity","synthetic":false,"types":["tdameritradeclient::model::quote::QEquity"]},{"text":"impl Serialize for QIndex","synthetic":false,"types":["tdameritradeclient::model::quote::QIndex"]},{"text":"impl Serialize for QOption","synthetic":false,"types":["tdameritradeclient::model::quote::QOption"]},{"text":"impl Serialize for QFund","synthetic":false,"types":["tdameritradeclient::model::quote::QFund"]},{"text":"impl Serialize for QGeneral","synthetic":false,"types":["tdameritradeclient::model::quote::QGeneral"]},{"text":"impl Serialize for UserPrincipals","synthetic":false,"types":["tdameritradeclient::model::userprincipals::UserPrincipals"]},{"text":"impl Serialize for StreamerInfo","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerInfo"]},{"text":"impl Serialize for Quotes","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Quotes"]},{"text":"impl Serialize for StreamerSubscriptionKeys","synthetic":false,"types":["tdameritradeclient::model::userprincipals::StreamerSubscriptionKeys"]},{"text":"impl Serialize for Key","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Key"]},{"text":"impl Serialize for Account","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Account"]},{"text":"impl Serialize for Preferences","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Preferences"]},{"text":"impl Serialize for Authorizations","synthetic":false,"types":["tdameritradeclient::model::userprincipals::Authorizations"]}]; if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/implementors/std/error/trait.Error.js b/docs/doc/implementors/std/error/trait.Error.js new file mode 100644 index 0000000..c40c931 --- /dev/null +++ b/docs/doc/implementors/std/error/trait.Error.js @@ -0,0 +1,3 @@ +(function() {var implementors = {}; +implementors["tdameritradeclient"] = [{"text":"impl Error for TDAClientError","synthetic":false,"types":["tdameritradeclient::error::TDAClientError"]}]; +if (window.register_implementors) {window.register_implementors(implementors);} else {window.pending_implementors = implementors;}})() \ No newline at end of file diff --git a/docs/doc/search-index.js b/docs/doc/search-index.js index fa5cb6d..4d57cac 100644 --- a/docs/doc/search-index.js +++ b/docs/doc/search-index.js @@ -1,5 +1,5 @@ var searchIndex = JSON.parse('{\ -"tdameritradeclient":{"doc":"tdameritradeclient","t":[2,3,3,11,0,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,0,11,11,0,11,11,11,11,0,11,11,11,11,11,11,11,11,11,3,11,11,11,11,11,11,11,11,5,5,5,5,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,0,0,0,0,0,0,3,3,3,3,3,3,3,3,3,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,12,12,12,12,11,11,11,11,11,11,11,11,11,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,11,11,12,3,3,12,12,12,12,12,11,11,11,11,12,11,11,11,11,12,12,11,11,12,12,12,11,11,11,12,12,12,11,11,11,11,12,12,12,12,12,11,11,12,12,12,12,12,12,12,12,12,12,12,12,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,12,12,11,11,11,11,11,11,12,12,12,12,3,3,11,11,11,11,12,11,11,11,11,12,12,11,11,11,11,12,11,11,11,11,11,11,11,12,11,11,12,11,11,12,11,11,12,11,11,11,11,11,11,11,11,12,13,13,13,13,13,3,3,3,3,3,4,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,12,12,12,11,12,12,12,12,12,12,12,12,11,11,11,11,11,11,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,3,3,12,11,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,12,12,12,12,11,11,11,11,11,11,3,3,3,3,3,3,3,3,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,12,12,12,11,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,4,13,13,13,13,13,13,13,3,13,13,13,13,13,13,13,4,13,4,13,13,4,13,4,13,4,13,4,13,8,13,13,13,13,4,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,4,13,13,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,5,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,10,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,13,13,4,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12],"n":["Endpoint","TDAClient","TDAClientAuth","active_token","auth","borrow","borrow","borrow_mut","borrow_mut","client","clone","clone","clone_into","clone_into","default","delete","fmt","fmt","from","from","from_tdauth","get","get_auth","into","into","model","new","new","param","patch","post","put","refresh_auth_active","request","session_timeout","to_owned","to_owned","try_from","try_from","try_into","try_into","type_id","type_id","TDauth","borrow","borrow_mut","clone","clone_into","default","fmt","from","get_auth_token","get_code_weblink","get_refresh_from_code","get_refresh_from_refresh","get_token_from_refresh","get_tokens","into","is_refresh_valid","is_token_valid","log_change","new","new_from_code","new_from_refresh","reset_expire","resolve_token_from_refresh","resolve_token_fromcode","serialize","to_owned","try_from","try_into","type_id","web_link_authorization","account","optionchain","pricehistory","quote","token","userprincipals","AccountRoot","CurrentBalances","InitialBalances","Instrument","OrderLegCollection","OrderStrategy","Position","ProjectedBalances","SecuritiesAccount","account_id","account_id","account_value","accrued_interest","accrued_interest","asset_type","available_funds","available_funds","available_funds_non_marginable_trade","available_funds_non_marginable_trade","available_funds_non_marginable_trade","average_price","bond_value","bond_value","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","buying_power","buying_power","buying_power","buying_power_non_marginable_trade","cancelable","cash_available_for_trading","cash_balance","cash_balance","cash_receipts","cash_receipts","clone","clone","clone","clone","clone","clone","clone","clone","clone","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","close_time","complex_order_strategy_type","current_balances","current_day_cost","current_day_profit_loss","current_day_profit_loss_percentage","cusip","day_trading_buying_power","day_trading_buying_power","day_trading_buying_power","day_trading_buying_power_call","day_trading_buying_power_call","day_trading_equity_call","default","default","default","default","default","default","default","default","default","description","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","destination_link_name","duration","editable","entered_time","eq","eq","eq","eq","eq","eq","eq","eq","eq","equity","equity","equity_percentage","equity_percentage","filled_quantity","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from","from","from","from","initial_balances","instruction","instrument","instrument","into","into","into","into","into","into","into","into","into","is_closing_only_restricted","is_day_trader","is_in_call","is_in_call","leg_id","liquidation_value","liquidation_value","long_margin_value","long_margin_value","long_market_value","long_option_market_value","long_option_market_value","long_quantity","long_stock_value","maintenance_call","maintenance_call","maintenance_call","maintenance_requirement","maintenance_requirement","maintenance_requirement","margin","margin_balance","margin_balance","margin_equity","market_value","money_market_fund","money_market_fund","mutual_fund_value","mutual_fund_value","ne","ne","ne","ne","ne","ne","ne","ne","ne","order_id","order_leg_collection","order_leg_type","order_strategies","order_strategy_type","order_type","pending_deposits","pending_deposits","position_effect","positions","previous_session_long_quantity","previous_session_short_quantity","price","projected_balances","put_call","quantity","quantity","reg_tcall","reg_tcall","reg_tcall","remaining_quantity","requested_destination","round_trips","savings","securities_account","serialize","serialize","serialize","serialize","serialize","serialize","serialize","serialize","serialize","session","settled_long_quantity","settled_short_quantity","short_balance","short_balance","short_margin_value","short_margin_value","short_market_value","short_option_market_value","short_option_market_value","short_quantity","short_stock_value","sma","status","stock_buying_power","symbol","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","total_cash","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","type_field","type_field","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","underlying_symbol","OptionChain","OptionQuote","ask","ask_size","bid","bid_ask_size","bid_size","borrow","borrow","borrow_mut","borrow_mut","call_exp_date_map","clone","clone","clone_into","clone_into","close_price","days_to_expiration","default","default","deliverable_note","delta","description","deserialize","deserialize","eq","exchange_name","expiration_date","expiration_type","fmt","fmt","from","from","gamma","high_price","in_the_money","interest_rate","interval","into","into","intrinsic_value","is_delayed","is_index","last","last_size","last_trading_day","low_price","mark","mark_change","mark_percent_change","mini","multiplier","ne","net_change","non_standard","number_of_contracts","open_interest","open_price","penny_pilot","percent_change","put_call","put_exp_date_map","quote_time_in_long","rho","settlement_type","status","strategy","strike_price","symbol","symbol","theoretical_option_value","theoretical_volatility","theta","time_value","to_owned","to_owned","total_volume","trade_time_in_long","try_from","try_from","try_into","try_into","type_id","type_id","underlying_price","vega","volatility","volatility","Candle","History","borrow","borrow","borrow_mut","borrow_mut","candles","clone","clone","clone_into","clone_into","close","datetime","default","default","deserialize","deserialize","empty","eq","eq","fmt","fmt","from","from","get_close_series","high","into","into","low","ne","ne","open","serialize","serialize","symbol","to_owned","to_owned","try_from","try_from","try_into","try_into","type_id","type_id","volume","Equity","Fund","General","Index","Option","QEquity","QFund","QGeneral","QIndex","QOption","Quote","ask_id","ask_price","ask_price","ask_size","ask_size","asset_type","asset_type","asset_type","asset_type","asset_type","bid_id","bid_price","bid_price","bid_size","bid_size","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","clone","clone","clone","clone","clone","clone","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","close_price","close_price","close_price","close_price","close_price","contract_type","cusip","cusip","cusip","days_to_expiration","deliverables","delta","description","description","description","description","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","digits","digits","digits","div_amount","div_amount","div_date","div_date","div_yield","div_yield","exchange","exchange","exchange","exchange","exchange_name","exchange_name","exchange_name","exchange_name","expiration_day","expiration_month","expiration_year","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from","gamma","high_price","high_price","high_price","implied_yield","into","into","into","into","into","into","last_id","last_price","last_price","last_price","last_size","last_size","last_trading_day","low_price","low_price","low_price","marginable","mark","mark","mark_change_in_double","mark_change_in_double","mark_price","money_intrinsic_value","multiplier","n52wk_high","n52wk_high","n52wk_high","n52wk_low","n52wk_low","n52wk_low","nav","net_change","net_change","net_change","net_change","net_percent_change_in_double","net_percent_change_in_double","net_percent_change_in_double","net_percent_change_in_double","open_interest","open_price","open_price","open_price","pe_ratio","pe_ratio","quote_time_in_long","quote_time_in_long","regular_market_last_price","regular_market_last_size","regular_market_net_change","regular_market_trade_time_in_long","rho","security_status","security_status","security_status","security_status","serialize","serialize","serialize","serialize","serialize","serialize","settlement_type","shortable","strike_price","symbol","symbol","symbol","symbol","symbol","symbol","theoretical_option_value","theta","time_value","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","total_volume","total_volume","total_volume","total_volume","trade_time_in_long","trade_time_in_long","trade_time_in_long","trade_time_in_long","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","type_id","underlying","underlying_price","uv_expiration_type","vega","volatility","volatility","0","0","0","0","0","ErrorResponse","TokenResponse","access_token","borrow","borrow","borrow_mut","borrow_mut","default","default","deserialize","deserialize","error","expires_in","fmt","fmt","from","from","into","into","refresh_token","refresh_token_expires_in","scope","token_type","try_from","try_from","try_into","try_into","type_id","type_id","Account","Authorizations","Key","Preferences","Quotes","StreamerInfo","StreamerSubscriptionKeys","UserPrincipals","access_level","access_level","account_cd_domain_id","account_id","accounts","acl","acl","advanced_margin","apex","app_id","auth_token","auth_token_timeout","authorizations","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","clone","clone","clone","clone","clone","clone","clone","clone","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","company","default","default","default","default","default","default","default","default","default_advanced_tool_launch","default_equity_order_duration","default_equity_order_leg_instruction","default_equity_order_market_session","default_equity_order_price_link_type","default_equity_order_type","default_equity_quantity","description","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","direct_equity_routing","direct_options_routing","display_name","eq","eq","eq","eq","eq","eq","eq","eq","equity_tax_lot_method","express_trading","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from","from","from","into","into","into","into","into","into","into","into","is_amex_delayed","is_cme_delayed","is_forex_delayed","is_ice_delayed","is_nasdaq_delayed","is_nyse_delayed","is_opra_delayed","key","keys","last_login_time","level_two_quotes","login_time","margin_trading","mutual_fund_tax_lot_method","ne","ne","ne","ne","ne","ne","ne","ne","option_tax_lot_method","option_trading_level","preferences","primary_account_id","professional_status","quotes","scottrade_account","segment","serialize","serialize","serialize","serialize","serialize","serialize","serialize","serialize","stale_password","stock_trading","streamer_access","streamer_binary_url","streamer_info","streamer_socket_url","streamer_subscription_keys","streaming_news","surrogate_ids","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","token","token_expiration_time","token_timestamp","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","user_cd_domain_id","user_group","user_id","Account","ChangePercent","ChangeValue","ContractType","Date","DaysToExpiration","DirectionDown","DirectionUp","Empty","EndDate","EndDate","ExpireMonth","Frequency","FrequencyType","FromDate","FromEnteredTime","History","IncludeQuotes","Instruments","InterestRate","Interval","MarketHours","MaxResults","Movers","NeedExendedHoursData","OptionChain","OptionType","Order","Orders","Pair","Period","PeriodType","Positions","PositionsAndOrders","Quotes","Range","SearchType","StartDate","StartDate","Status","Strategy","Strike","StrikeCount","Symbol","Symbol","Symbol","Symbol","ToDate","ToEnteredTime","TransactionType","Transactions","UnderlyingPrice","Volatility","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","convert_to_pairs","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from","from","from","from","from","into","into","into","into","into","into","into","into","into","into","pair","pair","pair","pair","pair","pair","pair","pair","pair","pair","pair","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","Account","Accounts","Endpoint","History","Instrument","Instruments","MarketHours","Movers","OptionChain","Order","Orders","Quotes","SavedOrder","SavedOrders","Transaction","Transactions","UserPrincipals","Watchlist","Watchlists","borrow","borrow_mut","fmt","from","into","try_from","try_into","type_id","url_endpoint","0","0","0","0","0","0","0","0","0","0","0","0","0"],"q":["tdameritradeclient","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::auth","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::model","","","","","","tdameritradeclient::model::account","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::model::optionchain","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::model::pricehistory","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::model::quote","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::model::quote::Quote","","","","","tdameritradeclient::model::token","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::model::userprincipals","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::param","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::param::History","","","","","","","tdameritradeclient::param::Instruments","","tdameritradeclient::param::MarketHours","tdameritradeclient::param::OptionChain","","","","","","","","","","","","","","","","tdameritradeclient::param::Order","","","","tdameritradeclient::param::Quotes","tdameritradeclient::param::Transactions","","","","tdameritradeclient::request","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::request::Endpoint","","","","","","","","","","","",""],"d":["Move to front of crate","Main client to access TD Ameritrade endpoints","Wrapper around TDAClient that handles managing the …","get current authorization token for TD API","utility module to help with authorization token, refresh …","","","","","retrieve client with updated token to use return None if …","","","","","","delete endpoint","","","Returns the argument unchanged.","Returns the argument unchanged.","create a new managed client from a TDauth configured …","get endpoint with query parameters","get authorization tokens for TD API","Calls U::from(self).","Calls U::from(self).","models that define types to parse json response or value …","Create new base client that maintains Authorization Header","create a new managed client with refresh token and client …","holds all the available query parameters used with the …","patch endpoint with json body","post endpoint with json body","put endpoint with json body","check that an active refresh token exists so client tokens …","holds all the relevant API endpoints","change timeout configuration of Session","","","","","","","","","These are tools to help manage authorization tokens with …","","","","","","","Returns the argument unchanged.","","used to get code manually from tdameritrade website with …","used to get a valid token and refresh_token from code, …","Convenience function","Convenience function","","Calls U::from(self).","","","","create new TDauth with configuration only","create new TDauth with code, redirecturi and clientid if …","create new TDauth with refresh_token and clientid if …","","get /oauth2/token token endpoint returns an access token …","get /oauth2/token token endpoint returns an access token …","","","","","","","type to respresent responses from /accounts/ endpoint","type to represent optionchains from /marketdata/chains","type to represent price history from …","type to represent quotes from …","type to represent token authorization response from …","type to respresent responses from /userprincipals/ endpoint","Holds account information that contains account …","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","","","","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","OptionChain Model","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","","","","","","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","","","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","Quote","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","","","","","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Holds Type Authorization response","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","Holds Type for UserPrincipals response","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Query Parameters for /accounts/","Specify change as a percent","Specify change as a value","Type of contracts to return in the chain. Can be CALL, …","Specify date for which market hours information is needed …","Days to expiration to use in calculations. Applies only to …","Specify direction movers Down","Specify direction movers UP","No Parameters","End date as milliseconds since epoch. If startDate and …","End Date in “yyyy-mm-dd” Maximum data range is one year","’Return only options expiring in the specified month. …","the number of the frequencyType to be included in each …","the type of frequency with which a new candle is formed. …","Only return expirations after this date. For strategies, …","Specifies that no orders entered before this time should …","Query Parameters for /marketdata/{symbol}/pricehistory","Include quotes for options in the option chain. Can be …","Query Parameters for /instruments","Interest rate to use in calculations. Applies only to …","Strike interval for spread strategy chains (see strategy …","Query Parameters for /marketdata/{market}/hours","Max number of orders to retrieve","Query Parameters for /marketdata/{index}/movers","true to return extended hours data, false for regular …","Query Parameters for /marketdata/chains","Type of contracts to return. Possible values are: S: …","Query Parameters for /orders/","","Query parameters must implement Pair trait to allow us to …","Number of periods to show. Valid by PeriodType (* is …","The type of period to show. Valid values are day, month, …","","","Query Parameters for /marketdata/quotes","Returns options for the given range. Possible values are: …","Type of Request symbol-search: Retrieve instrument data of …","Start date as milliseconds since epoch. If startDate and …","Start Date in “yyyy-mm-dd” Maximum date range is one …","specifies type of orders to be returned: WORKING, FILLED, …","Passing a value returns a Strategy Chain. Possible values …","Provide a strike price to return options only at that …","The number of strikes to return above and below the …","Indicate one symbol or multiple symbols with , as delimiter","Underlying symbol ","Specify symbol, otherwise all symbols","Specify symbol or search parameter","Only return expirations before this date. For strategies, …","Specifies that no orders entered after this time should be …","type = ALL, TRADE, BUY_ONLY, SELL_ONLY, …","Query Parameters for /account/transactions","Underlying price to use in calculations. Applies only to …","Volatility to use in calculations. Applies only to …","","","","","","","","","","","","","","","","","","","","","function to convert a collection of query parameters in to …","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","/accounts/{ACCOUNTID}","/accounts","specifies Endpoints for TD Ameritrade’s API","/marketdata/{SYMBOL}/pricehistory","Get Instrument by CUSIP","Search Instruments","/marketdata/{MARKET}/hours","Has not been tested","/marketdata/chains","/accounts/{ACCOUNTID}/orders/{ORDERID}","/accounts/{ACCOUNTID}/orders","/marketdata/quotes","/accounts/{ACCOUNTID}/savedorders/{SAVEDORDERID}","/accounts/{ACCOUNTID}/savedorders","/accounts/{ACCOUNTID}/transactions/{TRANSACTIONID}","/accounts/{ACCOUNTID}/transactions","/userprincipals","/accounts/{ACCOUNTID}/watchlists/{WATCHLISTID}","/accounts/{ACCOUNTID}/watchlists","","","","Returns the argument unchanged.","Calls U::from(self).","","","","defines the URL for the specified Endpoint","","","","","","","","","","","","",""],"i":[0,0,0,1,0,2,1,2,1,1,2,1,2,1,2,2,2,1,2,1,1,2,1,2,1,0,2,1,0,2,2,2,1,0,2,2,1,2,1,2,1,2,1,0,3,3,3,3,3,3,3,3,0,0,0,0,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,5,6,6,7,8,7,9,6,7,9,10,6,7,11,4,10,8,6,7,9,5,12,11,4,10,8,6,7,9,5,12,6,7,9,7,5,6,6,7,6,7,11,4,10,8,6,7,9,5,12,11,4,10,8,6,7,9,5,12,5,5,4,10,10,10,8,6,7,9,6,9,6,11,4,10,8,6,7,9,5,12,8,11,4,10,8,6,7,9,5,12,5,5,5,5,11,4,10,8,6,7,9,5,12,6,7,6,7,5,11,4,10,8,6,7,9,5,12,11,4,10,8,6,7,9,5,12,4,12,10,12,11,4,10,8,6,7,9,5,12,4,4,6,9,12,6,7,6,7,7,6,7,10,6,6,7,9,10,6,7,6,6,7,6,10,6,7,6,7,11,4,10,8,6,7,9,5,12,5,5,12,4,5,5,6,7,12,4,10,10,5,4,8,5,12,6,7,9,5,5,4,7,11,11,4,10,8,6,7,9,5,12,5,10,10,6,7,6,7,7,6,7,10,6,7,5,9,8,11,4,10,8,6,7,9,5,12,6,11,4,10,8,6,7,9,5,12,11,4,10,8,6,7,9,5,12,4,8,11,4,10,8,6,7,9,5,12,8,0,0,13,13,13,13,13,14,13,14,13,14,14,13,14,13,13,13,14,13,13,13,13,14,13,13,13,13,13,14,13,14,13,13,13,13,14,14,14,13,13,14,14,13,13,13,13,13,13,13,13,13,13,13,13,14,13,13,13,13,13,14,13,13,13,14,14,13,14,13,13,13,13,13,14,13,13,13,14,13,14,13,14,13,14,13,14,13,0,0,15,16,15,16,15,15,16,15,16,16,16,15,16,15,16,15,15,16,15,16,15,16,15,16,15,16,16,15,16,16,15,16,15,15,16,15,16,15,16,15,16,16,17,17,17,17,17,0,0,0,0,0,0,18,18,19,18,19,18,20,19,21,22,18,18,19,18,19,17,18,20,19,21,22,17,18,20,19,21,22,17,18,20,19,21,22,17,18,20,19,21,22,17,18,20,19,21,19,18,19,21,19,19,19,18,20,19,21,17,18,20,19,21,22,18,20,21,18,21,18,21,18,21,18,20,19,21,18,20,19,21,19,19,19,17,18,20,19,21,22,17,18,20,19,21,22,19,18,20,19,19,17,18,20,19,21,22,18,18,20,19,18,19,19,18,20,19,18,18,19,18,19,17,19,19,18,20,21,18,20,21,21,18,20,19,21,18,20,19,21,19,18,20,19,18,21,18,19,18,18,18,18,19,18,20,19,21,17,18,20,19,21,22,19,18,19,17,18,20,19,21,22,19,19,19,17,18,20,19,21,22,18,20,19,21,18,20,19,21,17,18,20,19,21,22,17,18,20,19,21,22,17,18,20,19,21,22,19,19,19,19,18,19,23,24,25,26,27,0,0,28,28,29,28,29,28,29,28,29,29,28,28,29,28,29,28,29,28,28,28,28,28,29,28,29,28,29,0,0,0,0,0,0,0,0,30,31,32,32,30,31,32,33,33,31,30,34,32,30,31,35,36,37,32,34,33,30,31,35,36,37,32,34,33,30,31,35,36,37,32,34,33,30,31,35,36,37,32,34,33,32,30,31,35,36,37,32,34,33,34,34,34,34,34,34,34,32,30,31,35,36,37,32,34,33,34,34,32,30,31,35,36,37,32,34,33,34,34,30,31,35,36,37,32,34,33,30,31,35,36,37,32,34,33,30,31,35,36,37,32,34,33,35,35,35,35,35,35,35,37,36,30,33,30,33,34,30,31,35,36,37,32,34,33,34,33,32,30,30,30,33,32,30,31,35,36,37,32,34,33,30,33,33,31,30,31,30,33,32,30,31,35,36,37,32,34,33,31,30,31,30,31,35,36,37,32,34,33,30,31,35,36,37,32,34,33,30,31,35,36,37,32,34,33,30,31,30,0,38,38,39,40,39,38,38,0,41,42,39,41,41,39,43,0,39,0,39,39,0,43,0,41,0,39,0,44,0,41,41,44,44,0,39,45,41,42,43,39,39,39,46,39,42,45,39,43,42,0,39,39,46,40,47,44,43,41,39,42,45,38,46,40,47,44,43,41,39,42,45,38,0,47,44,43,41,39,42,45,38,46,40,47,44,43,41,39,42,45,38,46,40,47,44,43,41,39,42,45,38,48,46,40,47,44,43,41,39,42,45,38,46,40,47,44,43,41,39,42,45,38,46,40,47,44,43,41,39,42,45,38,46,40,47,44,43,41,39,42,45,38,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,84,0,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,85,86,87,88,89,90,91,92,93,94,95,96,97],"f":[null,null,null,[[["tdaclientauth",3]],["option",4,[["str",0]]]],null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["tdaclientauth",3]],["option",4,[["tdaclient",3]]]],[[["tdaclient",3]],["tdaclient",3]],[[["tdaclientauth",3]],["tdaclientauth",3]],[[["",0],["",0]]],[[["",0],["",0]]],[[],["tdaclient",3]],[[["tdaclient",3],["endpoint",4]]],[[["tdaclient",3],["formatter",3]],["result",6]],[[["tdaclientauth",3],["formatter",3]],["result",6]],[[]],[[]],[[["tdauth",3]],["tdaclientauth",3]],[[["tdaclient",3],["endpoint",4]]],[[["tdaclientauth",3]],["tdauth",3]],[[]],[[]],null,[[["string",3]],["tdaclient",3]],[[["string",3],["string",3]],["tdaclientauth",3]],null,[[["tdaclient",3],["endpoint",4],["str",0]]],[[["tdaclient",3],["endpoint",4],["str",0]]],[[["tdaclient",3],["endpoint",4],["str",0]]],[[["tdaclientauth",3]],["bool",0]],null,[[["tdaclient",3],["duration",3]]],[[["",0]]],[[["",0]]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,[[["",0]],["",0]],[[["",0]],["",0]],[[["tdauth",3]],["tdauth",3]],[[["",0],["",0]]],[[],["tdauth",3]],[[["tdauth",3],["formatter",3]],["result",6]],[[]],[[["tdauth",3]],["str",0]],[[["str",0],["str",0]],["string",3]],[[["str",0],["str",0],["str",0],["bool",0]],["string",3]],[[["str",0],["str",0]],["string",3]],[[["str",0],["str",0]],["string",3]],[[["tdauth",3]]],[[]],[[["tdauth",3],["u64",0]],["bool",0]],[[["tdauth",3],["u64",0]],["bool",0]],[[["tdauth",3],["str",0]]],[[["string",3],["string",3],["string",3]],["tdauth",3]],[[["str",0],["str",0],["str",0],["bool",0]],["tdauth",3]],[[["str",0],["str",0],["bool",0]],["tdauth",3]],[[["tdauth",3]]],[[["tdauth",3],["bool",0]]],[[["tdauth",3],["str",0],["bool",0]]],[[["tdauth",3]],["result",4]],[[["",0]]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["tdauth",3]],["string",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],null,null,null,null,null,null,null,null,null,null,[[["accountroot",3]],["accountroot",3]],[[["securitiesaccount",3]],["securitiesaccount",3]],[[["position",3]],["position",3]],[[["instrument",3]],["instrument",3]],[[["initialbalances",3]],["initialbalances",3]],[[["currentbalances",3]],["currentbalances",3]],[[["projectedbalances",3]],["projectedbalances",3]],[[["orderstrategy",3]],["orderstrategy",3]],[[["orderlegcollection",3]],["orderlegcollection",3]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],null,null,null,null,null,null,null,null,null,null,null,null,null,[[],["accountroot",3]],[[],["securitiesaccount",3]],[[],["position",3]],[[],["instrument",3]],[[],["initialbalances",3]],[[],["currentbalances",3]],[[],["projectedbalances",3]],[[],["orderstrategy",3]],[[],["orderlegcollection",3]],null,[[],["result",4,[["accountroot",3]]]],[[],["result",4,[["securitiesaccount",3]]]],[[],["result",4,[["position",3]]]],[[],["result",4,[["instrument",3]]]],[[],["result",4,[["initialbalances",3]]]],[[],["result",4,[["currentbalances",3]]]],[[],["result",4,[["projectedbalances",3]]]],[[],["result",4,[["orderstrategy",3]]]],[[],["result",4,[["orderlegcollection",3]]]],null,null,null,null,[[["accountroot",3],["accountroot",3]],["bool",0]],[[["securitiesaccount",3],["securitiesaccount",3]],["bool",0]],[[["position",3],["position",3]],["bool",0]],[[["instrument",3],["instrument",3]],["bool",0]],[[["initialbalances",3],["initialbalances",3]],["bool",0]],[[["currentbalances",3],["currentbalances",3]],["bool",0]],[[["projectedbalances",3],["projectedbalances",3]],["bool",0]],[[["orderstrategy",3],["orderstrategy",3]],["bool",0]],[[["orderlegcollection",3],["orderlegcollection",3]],["bool",0]],null,null,null,null,null,[[["accountroot",3],["formatter",3]],["result",6]],[[["securitiesaccount",3],["formatter",3]],["result",6]],[[["position",3],["formatter",3]],["result",6]],[[["instrument",3],["formatter",3]],["result",6]],[[["initialbalances",3],["formatter",3]],["result",6]],[[["currentbalances",3],["formatter",3]],["result",6]],[[["projectedbalances",3],["formatter",3]],["result",6]],[[["orderstrategy",3],["formatter",3]],["result",6]],[[["orderlegcollection",3],["formatter",3]],["result",6]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],null,null,null,null,[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["accountroot",3],["accountroot",3]],["bool",0]],[[["securitiesaccount",3],["securitiesaccount",3]],["bool",0]],[[["position",3],["position",3]],["bool",0]],[[["instrument",3],["instrument",3]],["bool",0]],[[["initialbalances",3],["initialbalances",3]],["bool",0]],[[["currentbalances",3],["currentbalances",3]],["bool",0]],[[["projectedbalances",3],["projectedbalances",3]],["bool",0]],[[["orderstrategy",3],["orderstrategy",3]],["bool",0]],[[["orderlegcollection",3],["orderlegcollection",3]],["bool",0]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["accountroot",3]],["result",4]],[[["securitiesaccount",3]],["result",4]],[[["position",3]],["result",4]],[[["instrument",3]],["result",4]],[[["initialbalances",3]],["result",4]],[[["currentbalances",3]],["result",4]],[[["projectedbalances",3]],["result",4]],[[["orderstrategy",3]],["result",4]],[[["orderlegcollection",3]],["result",4]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],null,[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],null,null,[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],null,[[["optionchain",3]],["optionchain",3]],[[["optionquote",3]],["optionquote",3]],[[["",0],["",0]]],[[["",0],["",0]]],null,null,[[],["optionchain",3]],[[],["optionquote",3]],null,null,null,[[],["result",4,[["optionchain",3]]]],[[],["result",4,[["optionquote",3]]]],[[["optionquote",3],["optionquote",3]],["bool",0]],null,null,null,[[["optionchain",3],["formatter",3]],["result",6]],[[["optionquote",3],["formatter",3]],["result",6]],[[]],[[]],null,null,null,null,null,[[]],[[]],null,null,null,null,null,null,null,null,null,null,null,null,[[["optionquote",3],["optionquote",3]],["bool",0]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]]],[[["",0]]],null,null,[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],null,[[["history",3]],["history",3]],[[["candle",3]],["candle",3]],[[["",0],["",0]]],[[["",0],["",0]]],null,null,[[],["history",3]],[[],["candle",3]],[[],["result",4,[["history",3]]]],[[],["result",4,[["candle",3]]]],null,[[["history",3],["history",3]],["bool",0]],[[["candle",3],["candle",3]],["bool",0]],[[["history",3],["formatter",3]],["result",6]],[[["candle",3],["formatter",3]],["result",6]],[[]],[[]],[[["history",3]],["vec",3,[["f64",0]]]],null,[[]],[[]],null,[[["history",3],["history",3]],["bool",0]],[[["candle",3],["candle",3]],["bool",0]],null,[[["history",3]],["result",4]],[[["candle",3]],["result",4]],null,[[["",0]]],[[["",0]]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["quote",4]],["quote",4]],[[["qequity",3]],["qequity",3]],[[["qindex",3]],["qindex",3]],[[["qoption",3]],["qoption",3]],[[["qfund",3]],["qfund",3]],[[["qgeneral",3]],["qgeneral",3]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["quote",4]],["f64",0]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[],["result",4,[["quote",4]]]],[[],["result",4,[["qequity",3]]]],[[],["result",4,[["qindex",3]]]],[[],["result",4,[["qoption",3]]]],[[],["result",4,[["qfund",3]]]],[[],["result",4,[["qgeneral",3]]]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["quote",4],["formatter",3]],["result",6]],[[["qequity",3],["formatter",3]],["result",6]],[[["qindex",3],["formatter",3]],["result",6]],[[["qoption",3],["formatter",3]],["result",6]],[[["qfund",3],["formatter",3]],["result",6]],[[["qgeneral",3],["formatter",3]],["result",6]],[[]],[[]],[[]],[[]],[[]],[[]],null,null,null,null,null,[[]],[[]],[[]],[[]],[[]],[[]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["quote",4]],["f64",0]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["quote",4]],["result",4]],[[["qequity",3]],["result",4]],[[["qindex",3]],["result",4]],[[["qoption",3]],["result",4]],[[["qfund",3]],["result",4]],[[["qgeneral",3]],["result",4]],null,null,null,[[["quote",4]],["str",0]],null,null,null,null,null,null,null,null,[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],null,null,null,null,null,null,null,null,[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[],["tokenresponse",3]],[[],["errorresponse",3]],[[],["result",4,[["tokenresponse",3]]]],[[],["result",4,[["errorresponse",3]]]],null,null,[[["tokenresponse",3],["formatter",3]],["result",6]],[[["errorresponse",3],["formatter",3]],["result",6]],[[]],[[]],[[]],[[]],null,null,null,null,[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["userprincipals",3]],["userprincipals",3]],[[["streamerinfo",3]],["streamerinfo",3]],[[["quotes",3]],["quotes",3]],[[["streamersubscriptionkeys",3]],["streamersubscriptionkeys",3]],[[["key",3]],["key",3]],[[["account",3]],["account",3]],[[["preferences",3]],["preferences",3]],[[["authorizations",3]],["authorizations",3]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],null,[[],["userprincipals",3]],[[],["streamerinfo",3]],[[],["quotes",3]],[[],["streamersubscriptionkeys",3]],[[],["key",3]],[[],["account",3]],[[],["preferences",3]],[[],["authorizations",3]],null,null,null,null,null,null,null,null,[[],["result",4,[["userprincipals",3]]]],[[],["result",4,[["streamerinfo",3]]]],[[],["result",4,[["quotes",3]]]],[[],["result",4,[["streamersubscriptionkeys",3]]]],[[],["result",4,[["key",3]]]],[[],["result",4,[["account",3]]]],[[],["result",4,[["preferences",3]]]],[[],["result",4,[["authorizations",3]]]],null,null,null,[[["userprincipals",3],["userprincipals",3]],["bool",0]],[[["streamerinfo",3],["streamerinfo",3]],["bool",0]],[[["quotes",3],["quotes",3]],["bool",0]],[[["streamersubscriptionkeys",3],["streamersubscriptionkeys",3]],["bool",0]],[[["key",3],["key",3]],["bool",0]],[[["account",3],["account",3]],["bool",0]],[[["preferences",3],["preferences",3]],["bool",0]],[[["authorizations",3],["authorizations",3]],["bool",0]],null,null,[[["userprincipals",3],["formatter",3]],["result",6]],[[["streamerinfo",3],["formatter",3]],["result",6]],[[["quotes",3],["formatter",3]],["result",6]],[[["streamersubscriptionkeys",3],["formatter",3]],["result",6]],[[["key",3],["formatter",3]],["result",6]],[[["account",3],["formatter",3]],["result",6]],[[["preferences",3],["formatter",3]],["result",6]],[[["authorizations",3],["formatter",3]],["result",6]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["userprincipals",3],["userprincipals",3]],["bool",0]],[[["streamerinfo",3],["streamerinfo",3]],["bool",0]],[[["quotes",3],["quotes",3]],["bool",0]],[[["streamersubscriptionkeys",3],["streamersubscriptionkeys",3]],["bool",0]],[[["key",3],["key",3]],["bool",0]],[[["account",3],["account",3]],["bool",0]],[[["preferences",3],["preferences",3]],["bool",0]],[[["authorizations",3],["authorizations",3]],["bool",0]],null,null,null,null,null,null,null,null,[[["userprincipals",3]],["result",4]],[[["streamerinfo",3]],["result",4]],[[["quotes",3]],["result",4]],[[["streamersubscriptionkeys",3]],["result",4]],[[["key",3]],["result",4]],[[["account",3]],["result",4]],[[["preferences",3]],["result",4]],[[["authorizations",3]],["result",4]],null,null,null,null,null,null,null,null,null,[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],null,null,null,[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[],["vec",3]],[[["empty",3],["formatter",3]],["result",6]],[[["account",4],["formatter",3]],["result",6]],[[["order",4],["formatter",3]],["result",6]],[[["history",4],["formatter",3]],["result",6]],[[["optionchain",4],["formatter",3]],["result",6]],[[["transactions",4],["formatter",3]],["result",6]],[[["instruments",4],["formatter",3]],["result",6]],[[["movers",4],["formatter",3]],["result",6]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[["quotes",4]]],[[["markethours",4]]],[[["empty",3]]],[[["account",4]]],[[["order",4]]],[[["history",4]]],[[["optionchain",4]]],[[["transactions",4]]],[[["instruments",4]]],[[["movers",4]]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["endpoint",4],["formatter",3]],["result",6]],[[]],[[]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["endpoint",4]],["string",3]],null,null,null,null,null,null,null,null,null,null,null,null,null],"p":[[3,"TDAClientAuth"],[3,"TDAClient"],[3,"TDauth"],[3,"SecuritiesAccount"],[3,"OrderStrategy"],[3,"InitialBalances"],[3,"CurrentBalances"],[3,"Instrument"],[3,"ProjectedBalances"],[3,"Position"],[3,"AccountRoot"],[3,"OrderLegCollection"],[3,"OptionQuote"],[3,"OptionChain"],[3,"History"],[3,"Candle"],[4,"Quote"],[3,"QEquity"],[3,"QOption"],[3,"QIndex"],[3,"QFund"],[3,"QGeneral"],[13,"Equity"],[13,"Index"],[13,"Option"],[13,"Fund"],[13,"General"],[3,"TokenResponse"],[3,"ErrorResponse"],[3,"UserPrincipals"],[3,"StreamerInfo"],[3,"Account"],[3,"Authorizations"],[3,"Preferences"],[3,"Quotes"],[3,"StreamerSubscriptionKeys"],[3,"Key"],[4,"Movers"],[4,"OptionChain"],[4,"MarketHours"],[4,"History"],[4,"Transactions"],[4,"Order"],[4,"Account"],[4,"Instruments"],[4,"Quotes"],[3,"Empty"],[8,"Pair"],[13,"PeriodType"],[13,"Period"],[13,"FrequencyType"],[13,"Frequency"],[13,"StartDate"],[13,"EndDate"],[13,"NeedExendedHoursData"],[13,"Symbol"],[13,"SearchType"],[13,"Date"],[13,"Symbol"],[13,"ContractType"],[13,"StrikeCount"],[13,"Strategy"],[13,"Interval"],[13,"Strike"],[13,"IncludeQuotes"],[13,"Range"],[13,"FromDate"],[13,"ToDate"],[13,"Volatility"],[13,"UnderlyingPrice"],[13,"InterestRate"],[13,"DaysToExpiration"],[13,"ExpireMonth"],[13,"OptionType"],[13,"MaxResults"],[13,"FromEnteredTime"],[13,"ToEnteredTime"],[13,"Status"],[13,"Symbol"],[13,"TransactionType"],[13,"Symbol"],[13,"StartDate"],[13,"EndDate"],[4,"Endpoint"],[13,"Account"],[13,"Order"],[13,"Orders"],[13,"SavedOrder"],[13,"SavedOrders"],[13,"MarketHours"],[13,"Instrument"],[13,"History"],[13,"Transactions"],[13,"Transaction"],[13,"Watchlists"],[13,"Watchlist"],[13,"Movers"]]}\ +"tdameritradeclient":{"doc":"tdameritradeclient","t":[2,3,3,11,0,11,11,11,11,11,11,11,11,11,11,11,0,11,11,11,11,11,11,11,11,11,0,11,11,0,11,11,11,11,0,11,11,11,11,11,11,11,11,11,3,11,11,11,11,11,11,11,11,5,5,5,5,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,13,4,13,11,11,11,11,11,11,11,11,11,11,11,11,12,12,0,0,0,0,0,0,3,3,3,3,3,3,3,3,3,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,11,11,11,12,3,3,12,12,12,12,12,11,11,11,11,12,11,11,11,11,12,12,11,11,12,12,12,11,11,11,12,12,12,11,11,11,11,12,12,12,12,12,11,11,12,12,12,12,12,12,12,12,12,12,12,12,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,12,12,11,11,11,11,11,11,12,12,12,12,3,3,11,11,11,11,12,11,11,11,11,12,12,11,11,11,11,12,11,11,11,11,11,11,11,12,11,11,12,11,11,12,11,11,12,11,11,11,11,11,11,11,11,12,13,13,13,13,13,3,3,3,3,3,4,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,12,12,12,11,12,12,12,12,12,12,12,12,11,11,11,11,11,11,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,3,3,12,11,11,11,11,11,11,11,11,12,12,11,11,11,11,11,11,12,12,12,12,11,11,11,11,11,11,3,3,3,3,3,3,3,3,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,12,12,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,11,11,11,11,11,11,11,11,12,12,12,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,4,13,13,13,13,13,13,13,3,13,13,13,13,13,13,13,4,13,4,13,13,4,13,4,13,4,13,4,13,8,13,13,13,13,4,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,4,13,13,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,5,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,10,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,13,13,4,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,13,11,11,11,11,11,11,11,11,11,12,12,12,12,12,12,12,12,12,12,12,12,12],"n":["Endpoint","TDAClient","TDAClientAuth","active_token","auth","borrow","borrow","borrow_mut","borrow_mut","client","clone","clone","clone_into","clone_into","default","delete","error","fmt","fmt","from","from","from_tdauth","get","get_auth","into","into","model","new","new","param","patch","post","put","refresh_auth_active","request","session_timeout","to_owned","to_owned","try_from","try_from","try_into","try_into","type_id","type_id","TDauth","borrow","borrow_mut","clone","clone_into","default","fmt","from","get_auth_token","get_code_weblink","get_refresh_from_code","get_refresh_from_refresh","get_token_from_refresh","get_tokens","into","is_refresh_valid","is_token_valid","log_change","new","new_from_code","new_from_refresh","reset_expire","resolve_token_from_refresh","resolve_token_fromcode","serialize","to_owned","try_from","try_into","type_id","web_link_authorization","ParseError","TDAClientError","WebConnectIssue","borrow","borrow_mut","fmt","fmt","from","from","from","into","to_string","try_from","try_into","type_id","0","0","account","optionchain","pricehistory","quote","token","userprincipals","AccountRoot","CurrentBalances","InitialBalances","Instrument","OrderLegCollection","OrderStrategy","Position","ProjectedBalances","SecuritiesAccount","account_id","account_id","account_value","accrued_interest","accrued_interest","asset_type","available_funds","available_funds","available_funds_non_marginable_trade","available_funds_non_marginable_trade","available_funds_non_marginable_trade","average_price","bond_value","bond_value","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","buying_power","buying_power","buying_power","buying_power_non_marginable_trade","cancelable","cash_available_for_trading","cash_balance","cash_balance","cash_receipts","cash_receipts","clone","clone","clone","clone","clone","clone","clone","clone","clone","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","close_time","complex_order_strategy_type","current_balances","current_day_cost","current_day_profit_loss","current_day_profit_loss_percentage","cusip","day_trading_buying_power","day_trading_buying_power","day_trading_buying_power","day_trading_buying_power_call","day_trading_buying_power_call","day_trading_equity_call","default","default","default","default","default","default","default","default","default","description","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","destination_link_name","duration","editable","entered_time","equity","equity","equity_percentage","equity_percentage","filled_quantity","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from","from","from","from","initial_balances","instruction","instrument","instrument","into","into","into","into","into","into","into","into","into","is_closing_only_restricted","is_day_trader","is_in_call","is_in_call","leg_id","liquidation_value","liquidation_value","long_margin_value","long_margin_value","long_market_value","long_option_market_value","long_option_market_value","long_quantity","long_stock_value","maintenance_call","maintenance_call","maintenance_call","maintenance_requirement","maintenance_requirement","maintenance_requirement","margin","margin_balance","margin_balance","margin_equity","market_value","money_market_fund","money_market_fund","mutual_fund_value","mutual_fund_value","order_id","order_leg_collection","order_leg_type","order_strategies","order_strategy_type","order_type","pending_deposits","pending_deposits","position_effect","positions","previous_session_long_quantity","previous_session_short_quantity","price","projected_balances","put_call","quantity","quantity","reg_tcall","reg_tcall","reg_tcall","remaining_quantity","requested_destination","round_trips","savings","securities_account","serialize","serialize","serialize","serialize","serialize","serialize","serialize","serialize","serialize","session","settled_long_quantity","settled_short_quantity","short_balance","short_balance","short_margin_value","short_margin_value","short_market_value","short_option_market_value","short_option_market_value","short_quantity","short_stock_value","sma","status","stock_buying_power","symbol","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","total_cash","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","type_field","type_field","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","underlying_symbol","OptionChain","OptionQuote","ask","ask_size","bid","bid_ask_size","bid_size","borrow","borrow","borrow_mut","borrow_mut","call_exp_date_map","clone","clone","clone_into","clone_into","close_price","days_to_expiration","default","default","deliverable_note","delta","description","deserialize","deserialize","eq","exchange_name","expiration_date","expiration_type","fmt","fmt","from","from","gamma","high_price","in_the_money","interest_rate","interval","into","into","intrinsic_value","is_delayed","is_index","last","last_size","last_trading_day","low_price","mark","mark_change","mark_percent_change","mini","multiplier","ne","net_change","non_standard","number_of_contracts","open_interest","open_price","penny_pilot","percent_change","put_call","put_exp_date_map","quote_time_in_long","rho","settlement_type","status","strategy","strike_price","symbol","symbol","theoretical_option_value","theoretical_volatility","theta","time_value","to_owned","to_owned","total_volume","trade_time_in_long","try_from","try_from","try_into","try_into","type_id","type_id","underlying_price","vega","volatility","volatility","Candle","History","borrow","borrow","borrow_mut","borrow_mut","candles","clone","clone","clone_into","clone_into","close","datetime","default","default","deserialize","deserialize","empty","eq","eq","fmt","fmt","from","from","get_close_series","high","into","into","low","ne","ne","open","serialize","serialize","symbol","to_owned","to_owned","try_from","try_from","try_into","try_into","type_id","type_id","volume","Equity","Fund","General","Index","Option","QEquity","QFund","QGeneral","QIndex","QOption","Quote","ask_id","ask_price","ask_price","ask_size","ask_size","asset_type","asset_type","asset_type","asset_type","asset_type","bid_id","bid_price","bid_price","bid_size","bid_size","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","clone","clone","clone","clone","clone","clone","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","close_price","close_price","close_price","close_price","close_price","contract_type","cusip","cusip","cusip","days_to_expiration","deliverables","delta","description","description","description","description","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","digits","digits","digits","div_amount","div_amount","div_date","div_date","div_yield","div_yield","exchange","exchange","exchange","exchange","exchange_name","exchange_name","exchange_name","exchange_name","expiration_day","expiration_month","expiration_year","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from","gamma","high_price","high_price","high_price","implied_yield","into","into","into","into","into","into","last_id","last_price","last_price","last_price","last_size","last_size","last_trading_day","low_price","low_price","low_price","marginable","mark","mark","mark_change_in_double","mark_change_in_double","mark_price","money_intrinsic_value","multiplier","n52wk_high","n52wk_high","n52wk_high","n52wk_low","n52wk_low","n52wk_low","nav","net_change","net_change","net_change","net_change","net_percent_change_in_double","net_percent_change_in_double","net_percent_change_in_double","net_percent_change_in_double","open_interest","open_price","open_price","open_price","pe_ratio","pe_ratio","quote_time_in_long","quote_time_in_long","regular_market_last_price","regular_market_last_size","regular_market_net_change","regular_market_trade_time_in_long","rho","security_status","security_status","security_status","security_status","serialize","serialize","serialize","serialize","serialize","serialize","settlement_type","shortable","strike_price","symbol","symbol","symbol","symbol","symbol","symbol","theoretical_option_value","theta","time_value","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","total_volume","total_volume","total_volume","total_volume","trade_time_in_long","trade_time_in_long","trade_time_in_long","trade_time_in_long","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","type_id","underlying","underlying_price","uv_expiration_type","vega","volatility","volatility","0","0","0","0","0","ErrorResponse","TokenResponse","access_token","borrow","borrow","borrow_mut","borrow_mut","default","default","deserialize","deserialize","error","expires_in","fmt","fmt","from","from","into","into","refresh_token","refresh_token_expires_in","scope","token_type","try_from","try_from","try_into","try_into","type_id","type_id","Account","Authorizations","Key","Preferences","Quotes","StreamerInfo","StreamerSubscriptionKeys","UserPrincipals","access_level","access_level","account_cd_domain_id","account_id","accounts","acl","acl","advanced_margin","apex","app_id","auth_token","auth_token_timeout","authorizations","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","clone","clone","clone","clone","clone","clone","clone","clone","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","clone_into","company","default","default","default","default","default","default","default","default","default_advanced_tool_launch","default_equity_order_duration","default_equity_order_leg_instruction","default_equity_order_market_session","default_equity_order_price_link_type","default_equity_order_type","default_equity_quantity","description","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","deserialize","direct_equity_routing","direct_options_routing","display_name","equity_tax_lot_method","express_trading","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from","from","from","into","into","into","into","into","into","into","into","is_amex_delayed","is_cme_delayed","is_forex_delayed","is_ice_delayed","is_nasdaq_delayed","is_nyse_delayed","is_opra_delayed","key","keys","last_login_time","level_two_quotes","login_time","margin_trading","mutual_fund_tax_lot_method","option_tax_lot_method","option_trading_level","preferences","primary_account_id","professional_status","quotes","scottrade_account","segment","serialize","serialize","serialize","serialize","serialize","serialize","serialize","serialize","stale_password","stock_trading","streamer_access","streamer_binary_url","streamer_info","streamer_socket_url","streamer_subscription_keys","streaming_news","surrogate_ids","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","to_owned","token","token_expiration_time","token_timestamp","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","user_cd_domain_id","user_group","user_id","Account","ChangePercent","ChangeValue","ContractType","Date","DaysToExpiration","DirectionDown","DirectionUp","Empty","EndDate","EndDate","ExpireMonth","Frequency","FrequencyType","FromDate","FromEnteredTime","History","IncludeQuotes","Instruments","InterestRate","Interval","MarketHours","MaxResults","Movers","NeedExendedHoursData","OptionChain","OptionType","Order","Orders","Pair","Period","PeriodType","Positions","PositionsAndOrders","Quotes","Range","SearchType","StartDate","StartDate","Status","Strategy","Strike","StrikeCount","Symbol","Symbol","Symbol","Symbol","ToDate","ToEnteredTime","TransactionType","Transactions","UnderlyingPrice","Volatility","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","borrow_mut","convert_to_pairs","fmt","fmt","fmt","fmt","fmt","fmt","fmt","fmt","from","from","from","from","from","from","from","from","from","from","into","into","into","into","into","into","into","into","into","into","pair","pair","pair","pair","pair","pair","pair","pair","pair","pair","pair","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_from","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","try_into","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","type_id","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","Account","Accounts","Endpoint","History","Instrument","Instruments","MarketHours","Movers","OptionChain","Order","Orders","Quotes","SavedOrder","SavedOrders","Transaction","Transactions","UserPrincipals","Watchlist","Watchlists","borrow","borrow_mut","fmt","from","into","try_from","try_into","type_id","url_endpoint","0","0","0","0","0","0","0","0","0","0","0","0","0"],"q":["tdameritradeclient","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::auth","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::error","","","","","","","","","","","","","","","tdameritradeclient::error::TDAClientError","","tdameritradeclient::model","","","","","","tdameritradeclient::model::account","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::model::optionchain","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::model::pricehistory","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::model::quote","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::model::quote::Quote","","","","","tdameritradeclient::model::token","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::model::userprincipals","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::param","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::param::History","","","","","","","tdameritradeclient::param::Instruments","","tdameritradeclient::param::MarketHours","tdameritradeclient::param::OptionChain","","","","","","","","","","","","","","","","tdameritradeclient::param::Order","","","","tdameritradeclient::param::Quotes","tdameritradeclient::param::Transactions","","","","tdameritradeclient::request","","","","","","","","","","","","","","","","","","","","","","","","","","","","tdameritradeclient::request::Endpoint","","","","","","","","","","","",""],"d":["Move to front of crate","Main client to access TD Ameritrade endpoints","Wrapper around TDAClient that handles managing the …","get current authorization token for TD API","utility module to help with authorization token, refresh …","","","","","retrieve client with updated token to use return None if …","","","","","","delete endpoint","Rolled up Errors for TDAClient","","","Returns the argument unchanged.","Returns the argument unchanged.","create a new managed client from a TDauth configured …","get endpoint with query parameters","get authorization tokens for TD API","Calls U::from(self).","Calls U::from(self).","models that define types to parse json response or value …","Create new base client that maintains Authorization Header","create a new managed client with refresh token and client …","holds all the available query parameters used with the …","patch endpoint with json body","post endpoint with json body","put endpoint with json body","check that an active refresh token exists so client tokens …","holds all the relevant API endpoints","change timeout configuration of Session","","","","","","","","","These are tools to help manage authorization tokens with …","","","","","","","Returns the argument unchanged.","","used to get code manually from tdameritrade website with …","used to get a valid token and refresh_token from code, …","Convenience function","Convenience function","","Calls U::from(self).","","","","create new TDauth with configuration only","create new TDauth with code, redirecturi and clientid if …","create new TDauth with refresh_token and clientid if …","","get /oauth2/token token endpoint returns an access token …","get /oauth2/token token endpoint returns an access token …","","","","","","","Any issues in parsing the response","","Deals with connection io issues to the web API","","","","","","","Returns the argument unchanged.","Calls U::from(self).","","","","","","","type to respresent responses from /accounts/ endpoint","type to represent optionchains from /marketdata/chains","type to represent price history from …","type to represent quotes from …","type to represent token authorization response from …","type to respresent responses from /userprincipals/ endpoint","Holds account information that contains account …","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","","","","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","OptionChain Model","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","","","","","","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","","","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","Quote","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","","","","","","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Holds Type Authorization response","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","Holds Type for UserPrincipals response","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","Query Parameters for /accounts/","Specify change as a percent","Specify change as a value","Type of contracts to return in the chain. Can be CALL, …","Specify date for which market hours information is needed …","Days to expiration to use in calculations. Applies only to …","Specify direction movers Down","Specify direction movers UP","No Parameters","End date as milliseconds since epoch. If startDate and …","End Date in “yyyy-mm-dd” Maximum data range is one year","’Return only options expiring in the specified month. …","the number of the frequencyType to be included in each …","the type of frequency with which a new candle is formed. …","Only return expirations after this date. For strategies, …","Specifies that no orders entered before this time should …","Query Parameters for /marketdata/{symbol}/pricehistory","Include quotes for options in the option chain. Can be …","Query Parameters for /instruments","Interest rate to use in calculations. Applies only to …","Strike interval for spread strategy chains (see strategy …","Query Parameters for /marketdata/{market}/hours","Max number of orders to retrieve","Query Parameters for /marketdata/{index}/movers","true to return extended hours data, false for regular …","Query Parameters for /marketdata/chains","Type of contracts to return. Possible values are: S: …","Query Parameters for /orders/","","Query parameters must implement Pair trait to allow us to …","Number of periods to show. Valid by PeriodType (* is …","The type of period to show. Valid values are day, month, …","","","Query Parameters for /marketdata/quotes","Returns options for the given range. Possible values are: …","Type of Request symbol-search: Retrieve instrument data of …","Start date as milliseconds since epoch. If startDate and …","Start Date in “yyyy-mm-dd” Maximum date range is one …","specifies type of orders to be returned: WORKING, FILLED, …","Passing a value returns a Strategy Chain. Possible values …","Provide a strike price to return options only at that …","The number of strikes to return above and below the …","Indicate one symbol or multiple symbols with , as delimiter","Underlying symbol ","Specify symbol, otherwise all symbols","Specify symbol or search parameter","Only return expirations before this date. For strategies, …","Specifies that no orders entered after this time should be …","type = ALL, TRADE, BUY_ONLY, SELL_ONLY, …","Query Parameters for /account/transactions","Underlying price to use in calculations. Applies only to …","Volatility to use in calculations. Applies only to …","","","","","","","","","","","","","","","","","","","","","function to convert a collection of query parameters in to …","","","","","","","","","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Returns the argument unchanged.","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","Calls U::from(self).","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","/accounts/{ACCOUNTID}","/accounts","specifies Endpoints for TD Ameritrade’s API","/marketdata/{SYMBOL}/pricehistory","Get Instrument by CUSIP","Search Instruments","/marketdata/{MARKET}/hours","Has not been tested","/marketdata/chains","/accounts/{ACCOUNTID}/orders/{ORDERID}","/accounts/{ACCOUNTID}/orders","/marketdata/quotes","/accounts/{ACCOUNTID}/savedorders/{SAVEDORDERID}","/accounts/{ACCOUNTID}/savedorders","/accounts/{ACCOUNTID}/transactions/{TRANSACTIONID}","/accounts/{ACCOUNTID}/transactions","/userprincipals","/accounts/{ACCOUNTID}/watchlists/{WATCHLISTID}","/accounts/{ACCOUNTID}/watchlists","","","","Returns the argument unchanged.","Calls U::from(self).","","","","defines the URL for the specified Endpoint","","","","","","","","","","","","",""],"i":[0,0,0,1,0,2,1,2,1,1,2,1,2,1,2,2,0,2,1,2,1,1,2,1,2,1,0,2,1,0,2,2,2,1,0,2,2,1,2,1,2,1,2,1,0,3,3,3,3,3,3,3,3,0,0,0,0,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,4,0,4,4,4,4,4,4,4,4,4,4,4,4,4,5,6,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,7,8,9,9,10,11,10,12,9,10,12,13,9,10,14,7,13,11,9,10,12,8,15,14,7,13,11,9,10,12,8,15,9,10,12,10,8,9,9,10,9,10,14,7,13,11,9,10,12,8,15,14,7,13,11,9,10,12,8,15,8,8,7,13,13,13,11,9,10,12,9,12,9,14,7,13,11,9,10,12,8,15,11,14,7,13,11,9,10,12,8,15,8,8,8,8,9,10,9,10,8,14,7,13,11,9,10,12,8,15,14,7,13,11,9,10,12,8,15,7,15,13,15,14,7,13,11,9,10,12,8,15,7,7,9,12,15,9,10,9,10,10,9,10,13,9,9,10,12,13,9,10,9,9,10,9,13,9,10,9,10,8,8,15,7,8,8,9,10,15,7,13,13,8,7,11,8,15,9,10,12,8,8,7,10,14,14,7,13,11,9,10,12,8,15,8,13,13,9,10,9,10,10,9,10,13,9,10,8,12,11,14,7,13,11,9,10,12,8,15,9,14,7,13,11,9,10,12,8,15,14,7,13,11,9,10,12,8,15,7,11,14,7,13,11,9,10,12,8,15,11,0,0,16,16,16,16,16,17,16,17,16,17,17,16,17,16,16,16,17,16,16,16,16,17,16,16,16,16,16,17,16,17,16,16,16,16,17,17,17,16,16,17,17,16,16,16,16,16,16,16,16,16,16,16,16,17,16,16,16,16,16,17,16,16,16,17,17,16,17,16,16,16,16,16,17,16,16,16,17,16,17,16,17,16,17,16,17,16,0,0,18,19,18,19,18,18,19,18,19,19,19,18,19,18,19,18,18,19,18,19,18,19,18,19,18,19,19,18,19,19,18,19,18,18,19,18,19,18,19,18,19,19,20,20,20,20,20,0,0,0,0,0,0,21,21,22,21,22,21,23,22,24,25,21,21,22,21,22,20,21,23,22,24,25,20,21,23,22,24,25,20,21,23,22,24,25,20,21,23,22,24,25,20,21,23,22,24,22,21,22,24,22,22,22,21,23,22,24,20,21,23,22,24,25,21,23,24,21,24,21,24,21,24,21,23,22,24,21,23,22,24,22,22,22,20,21,23,22,24,25,20,21,23,22,24,25,22,21,23,22,22,20,21,23,22,24,25,21,21,23,22,21,22,22,21,23,22,21,21,22,21,22,20,22,22,21,23,24,21,23,24,24,21,23,22,24,21,23,22,24,22,21,23,22,21,24,21,22,21,21,21,21,22,21,23,22,24,20,21,23,22,24,25,22,21,22,20,21,23,22,24,25,22,22,22,20,21,23,22,24,25,21,23,22,24,21,23,22,24,20,21,23,22,24,25,20,21,23,22,24,25,20,21,23,22,24,25,22,22,22,22,21,22,26,27,28,29,30,0,0,31,31,32,31,32,31,32,31,32,32,31,31,32,31,32,31,32,31,31,31,31,31,32,31,32,31,32,0,0,0,0,0,0,0,0,33,34,35,35,33,34,35,36,36,34,33,37,35,33,34,38,39,40,35,37,36,33,34,38,39,40,35,37,36,33,34,38,39,40,35,37,36,33,34,38,39,40,35,37,36,35,33,34,38,39,40,35,37,36,37,37,37,37,37,37,37,35,33,34,38,39,40,35,37,36,37,37,35,37,37,33,34,38,39,40,35,37,36,33,34,38,39,40,35,37,36,33,34,38,39,40,35,37,36,38,38,38,38,38,38,38,40,39,33,36,33,36,37,37,36,35,33,33,33,36,35,33,34,38,39,40,35,37,36,33,36,36,34,33,34,33,36,35,33,34,38,39,40,35,37,36,34,33,34,33,34,38,39,40,35,37,36,33,34,38,39,40,35,37,36,33,34,38,39,40,35,37,36,33,34,33,0,41,41,42,43,42,41,41,0,44,45,42,44,44,42,46,0,42,0,42,42,0,46,0,44,0,42,0,47,0,44,44,47,47,0,42,48,44,45,46,42,42,42,49,42,45,48,42,46,45,0,42,42,49,43,50,47,46,44,42,45,48,41,49,43,50,47,46,44,42,45,48,41,0,50,47,46,44,42,45,48,41,49,43,50,47,46,44,42,45,48,41,49,43,50,47,46,44,42,45,48,41,51,49,43,50,47,46,44,42,45,48,41,49,43,50,47,46,44,42,45,48,41,49,43,50,47,46,44,42,45,48,41,49,43,50,47,46,44,42,45,48,41,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,87,0,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,88,89,90,91,92,93,94,95,96,97,98,99,100],"f":[null,null,null,[[["tdaclientauth",3]],["option",4,[["str",0]]]],null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["tdaclientauth",3]],["option",4,[["tdaclient",3]]]],[[["tdaclient",3]],["tdaclient",3]],[[["tdaclientauth",3]],["tdaclientauth",3]],[[["",0],["",0]]],[[["",0],["",0]]],[[],["tdaclient",3]],[[["tdaclient",3],["endpoint",4]],["result",4,[["tdaclienterror",4]]]],null,[[["tdaclient",3],["formatter",3]],["result",6]],[[["tdaclientauth",3],["formatter",3]],["result",6]],[[]],[[]],[[["tdauth",3]],["tdaclientauth",3]],[[["tdaclient",3],["endpoint",4]],["result",4,[["tdaclienterror",4]]]],[[["tdaclientauth",3]],["tdauth",3]],[[]],[[]],null,[[["string",3]],["tdaclient",3]],[[["string",3],["string",3]],["tdaclientauth",3]],null,[[["tdaclient",3],["endpoint",4],["str",0]],["result",4,[["tdaclienterror",4]]]],[[["tdaclient",3],["endpoint",4],["str",0]],["result",4,[["tdaclienterror",4]]]],[[["tdaclient",3],["endpoint",4],["str",0]],["result",4,[["tdaclienterror",4]]]],[[["tdaclientauth",3]],["bool",0]],null,[[["tdaclient",3],["duration",3]]],[[["",0]]],[[["",0]]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,[[["",0]],["",0]],[[["",0]],["",0]],[[["tdauth",3]],["tdauth",3]],[[["",0],["",0]]],[[],["tdauth",3]],[[["tdauth",3],["formatter",3]],["result",6]],[[]],[[["tdauth",3]],["str",0]],[[["str",0],["str",0]],["string",3]],[[["str",0],["str",0],["str",0],["bool",0]],["string",3]],[[["str",0],["str",0]],["string",3]],[[["str",0],["str",0]],["string",3]],[[["tdauth",3]]],[[]],[[["tdauth",3],["u64",0]],["bool",0]],[[["tdauth",3],["u64",0]],["bool",0]],[[["tdauth",3],["str",0]]],[[["string",3],["string",3],["string",3]],["tdauth",3]],[[["str",0],["str",0],["str",0],["bool",0]],["tdauth",3]],[[["str",0],["str",0],["bool",0]],["tdauth",3]],[[["tdauth",3]]],[[["tdauth",3],["bool",0]]],[[["tdauth",3],["str",0],["bool",0]]],[[["tdauth",3]],["result",4]],[[["",0]]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["tdauth",3]],["string",3]],null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["tdaclienterror",4],["formatter",3]],["result",6]],[[["tdaclienterror",4],["formatter",3]],["result",6]],[[["error",3]],["tdaclienterror",4]],[[["error",3]],["tdaclienterror",4]],[[]],[[]],[[["",0]],["string",3]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],null,null,null,null,null,null,null,null,null,null,[[["accountroot",3]],["accountroot",3]],[[["securitiesaccount",3]],["securitiesaccount",3]],[[["position",3]],["position",3]],[[["instrument",3]],["instrument",3]],[[["initialbalances",3]],["initialbalances",3]],[[["currentbalances",3]],["currentbalances",3]],[[["projectedbalances",3]],["projectedbalances",3]],[[["orderstrategy",3]],["orderstrategy",3]],[[["orderlegcollection",3]],["orderlegcollection",3]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],null,null,null,null,null,null,null,null,null,null,null,null,null,[[],["accountroot",3]],[[],["securitiesaccount",3]],[[],["position",3]],[[],["instrument",3]],[[],["initialbalances",3]],[[],["currentbalances",3]],[[],["projectedbalances",3]],[[],["orderstrategy",3]],[[],["orderlegcollection",3]],null,[[],["result",4,[["accountroot",3]]]],[[],["result",4,[["securitiesaccount",3]]]],[[],["result",4,[["position",3]]]],[[],["result",4,[["instrument",3]]]],[[],["result",4,[["initialbalances",3]]]],[[],["result",4,[["currentbalances",3]]]],[[],["result",4,[["projectedbalances",3]]]],[[],["result",4,[["orderstrategy",3]]]],[[],["result",4,[["orderlegcollection",3]]]],null,null,null,null,null,null,null,null,null,[[["accountroot",3],["formatter",3]],["result",6]],[[["securitiesaccount",3],["formatter",3]],["result",6]],[[["position",3],["formatter",3]],["result",6]],[[["instrument",3],["formatter",3]],["result",6]],[[["initialbalances",3],["formatter",3]],["result",6]],[[["currentbalances",3],["formatter",3]],["result",6]],[[["projectedbalances",3],["formatter",3]],["result",6]],[[["orderstrategy",3],["formatter",3]],["result",6]],[[["orderlegcollection",3],["formatter",3]],["result",6]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],null,null,null,null,[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["accountroot",3]],["result",4]],[[["securitiesaccount",3]],["result",4]],[[["position",3]],["result",4]],[[["instrument",3]],["result",4]],[[["initialbalances",3]],["result",4]],[[["currentbalances",3]],["result",4]],[[["projectedbalances",3]],["result",4]],[[["orderstrategy",3]],["result",4]],[[["orderlegcollection",3]],["result",4]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],null,[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],null,null,[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],null,[[["optionchain",3]],["optionchain",3]],[[["optionquote",3]],["optionquote",3]],[[["",0],["",0]]],[[["",0],["",0]]],null,null,[[],["optionchain",3]],[[],["optionquote",3]],null,null,null,[[],["result",4,[["optionchain",3]]]],[[],["result",4,[["optionquote",3]]]],[[["optionquote",3],["optionquote",3]],["bool",0]],null,null,null,[[["optionchain",3],["formatter",3]],["result",6]],[[["optionquote",3],["formatter",3]],["result",6]],[[]],[[]],null,null,null,null,null,[[]],[[]],null,null,null,null,null,null,null,null,null,null,null,null,[[["optionquote",3],["optionquote",3]],["bool",0]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]]],[[["",0]]],null,null,[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],null,[[["history",3]],["history",3]],[[["candle",3]],["candle",3]],[[["",0],["",0]]],[[["",0],["",0]]],null,null,[[],["history",3]],[[],["candle",3]],[[],["result",4,[["history",3]]]],[[],["result",4,[["candle",3]]]],null,[[["history",3],["history",3]],["bool",0]],[[["candle",3],["candle",3]],["bool",0]],[[["history",3],["formatter",3]],["result",6]],[[["candle",3],["formatter",3]],["result",6]],[[]],[[]],[[["history",3]],["vec",3,[["f64",0]]]],null,[[]],[[]],null,[[["history",3],["history",3]],["bool",0]],[[["candle",3],["candle",3]],["bool",0]],null,[[["history",3]],["result",4]],[[["candle",3]],["result",4]],null,[[["",0]]],[[["",0]]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["quote",4]],["quote",4]],[[["qequity",3]],["qequity",3]],[[["qindex",3]],["qindex",3]],[[["qoption",3]],["qoption",3]],[[["qfund",3]],["qfund",3]],[[["qgeneral",3]],["qgeneral",3]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["quote",4]],["f64",0]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[],["result",4,[["quote",4]]]],[[],["result",4,[["qequity",3]]]],[[],["result",4,[["qindex",3]]]],[[],["result",4,[["qoption",3]]]],[[],["result",4,[["qfund",3]]]],[[],["result",4,[["qgeneral",3]]]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["quote",4],["formatter",3]],["result",6]],[[["qequity",3],["formatter",3]],["result",6]],[[["qindex",3],["formatter",3]],["result",6]],[[["qoption",3],["formatter",3]],["result",6]],[[["qfund",3],["formatter",3]],["result",6]],[[["qgeneral",3],["formatter",3]],["result",6]],[[]],[[]],[[]],[[]],[[]],[[]],null,null,null,null,null,[[]],[[]],[[]],[[]],[[]],[[]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["quote",4]],["f64",0]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["quote",4]],["result",4]],[[["qequity",3]],["result",4]],[[["qindex",3]],["result",4]],[[["qoption",3]],["result",4]],[[["qfund",3]],["result",4]],[[["qgeneral",3]],["result",4]],null,null,null,[[["quote",4]],["str",0]],null,null,null,null,null,null,null,null,[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],null,null,null,null,null,null,null,null,[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[],["tokenresponse",3]],[[],["errorresponse",3]],[[],["result",4,[["tokenresponse",3]]]],[[],["result",4,[["errorresponse",3]]]],null,null,[[["tokenresponse",3],["formatter",3]],["result",6]],[[["errorresponse",3],["formatter",3]],["result",6]],[[]],[[]],[[]],[[]],null,null,null,null,[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["userprincipals",3]],["userprincipals",3]],[[["streamerinfo",3]],["streamerinfo",3]],[[["quotes",3]],["quotes",3]],[[["streamersubscriptionkeys",3]],["streamersubscriptionkeys",3]],[[["key",3]],["key",3]],[[["account",3]],["account",3]],[[["preferences",3]],["preferences",3]],[[["authorizations",3]],["authorizations",3]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],[[["",0],["",0]]],null,[[],["userprincipals",3]],[[],["streamerinfo",3]],[[],["quotes",3]],[[],["streamersubscriptionkeys",3]],[[],["key",3]],[[],["account",3]],[[],["preferences",3]],[[],["authorizations",3]],null,null,null,null,null,null,null,null,[[],["result",4,[["userprincipals",3]]]],[[],["result",4,[["streamerinfo",3]]]],[[],["result",4,[["quotes",3]]]],[[],["result",4,[["streamersubscriptionkeys",3]]]],[[],["result",4,[["key",3]]]],[[],["result",4,[["account",3]]]],[[],["result",4,[["preferences",3]]]],[[],["result",4,[["authorizations",3]]]],null,null,null,null,null,[[["userprincipals",3],["formatter",3]],["result",6]],[[["streamerinfo",3],["formatter",3]],["result",6]],[[["quotes",3],["formatter",3]],["result",6]],[[["streamersubscriptionkeys",3],["formatter",3]],["result",6]],[[["key",3],["formatter",3]],["result",6]],[[["account",3],["formatter",3]],["result",6]],[[["preferences",3],["formatter",3]],["result",6]],[[["authorizations",3],["formatter",3]],["result",6]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["userprincipals",3]],["result",4]],[[["streamerinfo",3]],["result",4]],[[["quotes",3]],["result",4]],[[["streamersubscriptionkeys",3]],["result",4]],[[["key",3]],["result",4]],[[["account",3]],["result",4]],[[["preferences",3]],["result",4]],[[["authorizations",3]],["result",4]],null,null,null,null,null,null,null,null,null,[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],[[["",0]]],null,null,null,[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[["",0]],["",0]],[[],["vec",3]],[[["empty",3],["formatter",3]],["result",6]],[[["account",4],["formatter",3]],["result",6]],[[["order",4],["formatter",3]],["result",6]],[[["history",4],["formatter",3]],["result",6]],[[["optionchain",4],["formatter",3]],["result",6]],[[["transactions",4],["formatter",3]],["result",6]],[[["instruments",4],["formatter",3]],["result",6]],[[["movers",4],["formatter",3]],["result",6]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[]],[[["quotes",4]]],[[["markethours",4]]],[[["empty",3]]],[[["account",4]]],[[["order",4]]],[[["history",4]]],[[["optionchain",4]]],[[["transactions",4]]],[[["instruments",4]]],[[["movers",4]]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],[[["",0]],["typeid",3]],null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[["",0]],["",0]],[[["",0]],["",0]],[[["endpoint",4],["formatter",3]],["result",6]],[[]],[[]],[[],["result",4]],[[],["result",4]],[[["",0]],["typeid",3]],[[["endpoint",4]],["string",3]],null,null,null,null,null,null,null,null,null,null,null,null,null],"p":[[3,"TDAClientAuth"],[3,"TDAClient"],[3,"TDauth"],[4,"TDAClientError"],[13,"WebConnectIssue"],[13,"ParseError"],[3,"SecuritiesAccount"],[3,"OrderStrategy"],[3,"InitialBalances"],[3,"CurrentBalances"],[3,"Instrument"],[3,"ProjectedBalances"],[3,"Position"],[3,"AccountRoot"],[3,"OrderLegCollection"],[3,"OptionQuote"],[3,"OptionChain"],[3,"History"],[3,"Candle"],[4,"Quote"],[3,"QEquity"],[3,"QOption"],[3,"QIndex"],[3,"QFund"],[3,"QGeneral"],[13,"Equity"],[13,"Index"],[13,"Option"],[13,"Fund"],[13,"General"],[3,"TokenResponse"],[3,"ErrorResponse"],[3,"UserPrincipals"],[3,"StreamerInfo"],[3,"Account"],[3,"Authorizations"],[3,"Preferences"],[3,"Quotes"],[3,"StreamerSubscriptionKeys"],[3,"Key"],[4,"Movers"],[4,"OptionChain"],[4,"MarketHours"],[4,"History"],[4,"Transactions"],[4,"Order"],[4,"Account"],[4,"Instruments"],[4,"Quotes"],[3,"Empty"],[8,"Pair"],[13,"PeriodType"],[13,"Period"],[13,"FrequencyType"],[13,"Frequency"],[13,"StartDate"],[13,"EndDate"],[13,"NeedExendedHoursData"],[13,"Symbol"],[13,"SearchType"],[13,"Date"],[13,"Symbol"],[13,"ContractType"],[13,"StrikeCount"],[13,"Strategy"],[13,"Interval"],[13,"Strike"],[13,"IncludeQuotes"],[13,"Range"],[13,"FromDate"],[13,"ToDate"],[13,"Volatility"],[13,"UnderlyingPrice"],[13,"InterestRate"],[13,"DaysToExpiration"],[13,"ExpireMonth"],[13,"OptionType"],[13,"MaxResults"],[13,"FromEnteredTime"],[13,"ToEnteredTime"],[13,"Status"],[13,"Symbol"],[13,"TransactionType"],[13,"Symbol"],[13,"StartDate"],[13,"EndDate"],[4,"Endpoint"],[13,"Account"],[13,"Order"],[13,"Orders"],[13,"SavedOrder"],[13,"SavedOrders"],[13,"MarketHours"],[13,"Instrument"],[13,"History"],[13,"Transactions"],[13,"Transaction"],[13,"Watchlists"],[13,"Watchlist"],[13,"Movers"]]}\ }'); if (typeof window !== 'undefined' && window.initSearch) {window.initSearch(searchIndex)}; if (typeof exports !== 'undefined') {exports.searchIndex = searchIndex}; diff --git a/docs/doc/source-files.js b/docs/doc/source-files.js index 81daec2..2a0e9d9 100644 --- a/docs/doc/source-files.js +++ b/docs/doc/source-files.js @@ -1,3 +1,3 @@ var sourcesIndex = {}; -sourcesIndex["tdameritradeclient"] = {"name":"","dirs":[{"name":"model","files":["account.rs","mod.rs","optionchain.rs","pricehistory.rs","quote.rs","token.rs","userprincipals.rs"]}],"files":["auth.rs","authmanagedclient.rs","lib.rs","param.rs","request.rs","tdaclient.rs"]}; +sourcesIndex["tdameritradeclient"] = {"name":"","dirs":[{"name":"model","files":["account.rs","mod.rs","optionchain.rs","pricehistory.rs","quote.rs","token.rs","userprincipals.rs"]}],"files":["auth.rs","authmanagedclient.rs","error.rs","lib.rs","param.rs","request.rs","tdaclient.rs"]}; createSourceSidebar(); diff --git a/docs/doc/src/tdameritradeclient/auth.rs.html b/docs/doc/src/tdameritradeclient/auth.rs.html index 87e6214..b052016 100644 --- a/docs/doc/src/tdameritradeclient/auth.rs.html +++ b/docs/doc/src/tdameritradeclient/auth.rs.html @@ -349,6 +349,7 @@ 343 344 345 +346
use crate::model::token::{ErrorResponse, TokenResponse};
 use log::info;
 use serde::Serialize;
@@ -417,6 +418,8 @@
 /// 2) `new_fromcode` will allow you to update tokens from the code retrieved in 1)
 /// 3) `new_fromrefresh` will allow you to update tokens from the `refresh_token`.  The `refresh_token` will stay active for 90 days so you can save for reuse.
 ///
+/// # Errors
+/// Any Web issues will reset token and send default TDAUTH struct which will be empty
 #[derive(Debug, Clone, Default, Serialize)]
 pub struct TDauth {
     token: String,
@@ -429,9 +432,8 @@
 }
 
 impl TDauth {
-
     /// create new `TDauth` with configuration only
-    /// 
+    ///
     pub fn new(refresh: String, client_id: String, redirect_uri: String) -> Self {
         let mut newauth = TDauth::default();
         newauth.set_refresh(refresh);
@@ -530,6 +532,7 @@
         self.auth_request(body, true);
     }
 
+    // if error in request just reset tokens
     fn auth_request(&mut self, body: Vec<(&str, &str)>, refresh_update: bool) {
         // any web issues
         let response = match request_auth(body) {
@@ -615,7 +618,7 @@
     }
 
     fn set_refresh(&mut self, refresh: String) {
-        self.refresh = refresh.to_owned();
+        self.refresh = refresh;
     }
 
     fn set_client_id(&mut self, client_id: String) {
@@ -623,7 +626,7 @@
     }
 
     fn set_redirect_uri(&mut self, redirect_uri: String) {
-        self.redirect_uri = Some(redirect_uri.to_owned());
+        self.redirect_uri = Some(redirect_uri);
     }
 
     pub fn log_change(&self, desc: &str) {
@@ -635,15 +638,15 @@
     }
 
     pub fn web_link_authorization(&self) -> String {
-        get_code_weblink(&self.client_id, self.redirect_uri.as_ref().unwrap())    
+        get_code_weblink(&self.client_id, self.redirect_uri.as_ref().unwrap())
     }
 }
 
 fn request_auth(body: Vec<(&str, &str)>) -> Result<String, attohttpc::Error> {
-    Ok(attohttpc::post(format!("{}oauth2/token", crate::APIWWW))
+    attohttpc::post(format!("{}oauth2/token", crate::APIWWW))
         .form(&body)?
         .send()?
-        .text()?)
+        .text()
 }
 
 #[cfg(test)]
@@ -671,7 +674,7 @@
     }
 
     #[test]
-   #[ignore]
+    #[ignore]
     fn check_new_fromrefresh_constructs_tdauth() {
         let refresh = env::var("TDREFRESHTOKEN").unwrap();
         let clientid = env::var("TDCLIENTKEY").unwrap();
@@ -683,7 +686,7 @@
 
     #[test]
     #[ignore]
-     fn check_existing_tdauth_fromrefresh_constructs_tdauth() {
+    fn check_existing_tdauth_fromrefresh_constructs_tdauth() {
         let mut auth = TDauth::default();
         auth.set_client_id(env::var("TDCLIENTKEY").unwrap());
         auth.set_refresh(env::var("TDREFRESHTOKEN").unwrap());
@@ -691,8 +694,7 @@
         let (t, r) = auth.get_tokens();
         println!("token: {} \nrefresh: {} \n", t, r);
         println!("{:?}", auth);
-     }
- 
+    }
 }
 
diff --git a/docs/doc/src/tdameritradeclient/authmanagedclient.rs.html b/docs/doc/src/tdameritradeclient/authmanagedclient.rs.html index 09a5114..41be75c 100644 --- a/docs/doc/src/tdameritradeclient/authmanagedclient.rs.html +++ b/docs/doc/src/tdameritradeclient/authmanagedclient.rs.html @@ -143,6 +143,8 @@ 137 138 139 +140 +141
use crate::auth::TDauth;
 use crate::TDAClient;
 use crate::REFRESHTIMEBUFFER;
@@ -221,7 +223,7 @@
     }
 
     /// check that an active refresh token exists so client tokens can be updated as needed
-    /// 
+    ///
     /// if this is false then `TDauth` will have to be resolved by getting a refresh token
     /// probably using `tdauth_code_grant`
     pub fn refresh_auth_active(&self) -> bool {
@@ -251,7 +253,8 @@
         let resptxt: String = managed_client
             .client()
             .unwrap()
-            .get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,SPY")]);
+            .get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,SPY")])
+            .unwrap();
         assert_eq!(resptxt.contains("\"assetType\""), true);
 
         let (t1, r1, t2, r2): (String, String, String, String);
@@ -267,7 +270,8 @@
         let resptxt: String = managed_client
             .client()
             .unwrap()
-            .get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,SPY")]);
+            .get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,SPY")])
+            .unwrap();
         assert_eq!(resptxt.contains("\"assetType\""), true);
 
         {
diff --git a/docs/doc/src/tdameritradeclient/error.rs.html b/docs/doc/src/tdameritradeclient/error.rs.html
new file mode 100644
index 0000000..52bfb14
--- /dev/null
+++ b/docs/doc/src/tdameritradeclient/error.rs.html
@@ -0,0 +1,73 @@
+error.rs - source
+    
1
+2
+3
+4
+5
+6
+7
+8
+9
+10
+11
+12
+13
+14
+15
+16
+17
+18
+19
+20
+21
+22
+23
+24
+25
+26
+27
+28
+29
+30
+31
+32
+
use std::fmt;
+
+#[derive(Debug)]
+pub enum TDAClientError {
+    /// Deals with connection io issues to the web API
+    WebConnectIssue(attohttpc::Error),
+    /// Any issues in parsing the response
+    ParseError(serde_json::Error),
+}
+
+impl std::error::Error for TDAClientError {}
+
+impl fmt::Display for TDAClientError {
+    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
+        match self {
+            TDAClientError::WebConnectIssue(e) => write!(f, "Web Connection Error: {}", e),
+            TDAClientError::ParseError(e) => write!(f, "Response Parsing Error: {}", e),
+        }
+    }
+}
+
+impl From<serde_json::Error> for TDAClientError {
+    fn from(e: serde_json::Error) -> Self {
+        TDAClientError::ParseError(e)
+    }
+}
+
+impl From<attohttpc::Error> for TDAClientError {
+    fn from(e: attohttpc::Error) -> Self {
+        TDAClientError::WebConnectIssue(e)
+    }
+}
+
+
+ \ No newline at end of file diff --git a/docs/doc/src/tdameritradeclient/lib.rs.html b/docs/doc/src/tdameritradeclient/lib.rs.html index ed0ef1b..f8b892f 100644 --- a/docs/doc/src/tdameritradeclient/lib.rs.html +++ b/docs/doc/src/tdameritradeclient/lib.rs.html @@ -100,6 +100,10 @@ 94 95 96 +97 +98 +99 +100
//! # tdameritradeclient
 //!
 //! TDAClient is the main struct that lets you build requests to TDAmeritrade's API
@@ -157,7 +161,7 @@
 //! let c = TDAClient::new(token);
 //!
 //! // get quotes for 3 symbols and execute
-//! let resptxt: String = c.get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,TRP")]);
+//! let resptxt: String = c.get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,TRP")]).unwrap();
 //!
 //! // output will be text string in json format
 //! println!("{:?}", resptxt);
@@ -168,6 +172,7 @@
 static APIKEY: &str = "@AMER.OAUTHAP";
 const TOKENTIMEBUFFER: u64 = 25 * 60; // 25 Minutes instead of 30 min
 const REFRESHTIMEBUFFER: u64 = 60 * 24 * 60; // 60 days instead of 90 days
+type Result<T> = std::result::Result<T, error::TDAClientError>;
 
 ///
 /// utility module to help with authorization token, refresh token and grant code
@@ -196,6 +201,9 @@
 /// Used: `https://transform.tools/json-to-rust-serde` to help with struct generation
 ///
 pub mod model;
+
+/// Rolled up Errors for TDAClient
+pub mod error;
 
\ No newline at end of file diff --git a/docs/doc/src/tdameritradeclient/model/account.rs.html b/docs/doc/src/tdameritradeclient/model/account.rs.html index 872f03d..998d8a2 100644 --- a/docs/doc/src/tdameritradeclient/model/account.rs.html +++ b/docs/doc/src/tdameritradeclient/model/account.rs.html @@ -210,7 +210,7 @@ /// Holds account information that contains account information, balances, positions and orders /// as retrieved from get Accounts /// -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct AccountRoot { pub securities_account: SecuritiesAccount, @@ -219,7 +219,7 @@ // TODO: Add the opportunity for either cash_account or margin_account. Currently only uses margin_account // Need to test cash account to see if it works -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct SecuritiesAccount { #[serde(rename = "type")] @@ -235,7 +235,7 @@ pub projected_balances: ProjectedBalances, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct Position { pub short_quantity: f64, @@ -253,7 +253,7 @@ pub previous_session_short_quantity: Option<f64>, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct Instrument { pub asset_type: String, @@ -266,7 +266,7 @@ pub type_field: Option<String>, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct InitialBalances { pub accrued_interest: f64, @@ -315,7 +315,7 @@ pub account_value: f64, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct CurrentBalances { pub accrued_interest: f64, @@ -356,7 +356,7 @@ pub bond_value: f64, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct ProjectedBalances { pub available_funds: f64, @@ -372,7 +372,7 @@ pub stock_buying_power: f64, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct OrderStrategy { pub session: String, @@ -396,7 +396,7 @@ pub account_id: i64, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct OrderLegCollection { pub order_leg_type: String, diff --git a/docs/doc/src/tdameritradeclient/model/mod.rs.html b/docs/doc/src/tdameritradeclient/model/mod.rs.html index 8b126dd..2e956c6 100644 --- a/docs/doc/src/tdameritradeclient/model/mod.rs.html +++ b/docs/doc/src/tdameritradeclient/model/mod.rs.html @@ -16,18 +16,42 @@ 10 11 12 -
/// type to respresent responses from /accounts/ endpoint
+13
+14
+15
+16
+17
+18
+19
+20
+21
+22
+23
+24
+
use serde::{Deserialize, Deserializer};
+use serde_json::Value;
+
+/// type to respresent responses from /accounts/ endpoint
 pub mod account;
-/// type to represent token authorization response from /oauth2/token endpoint
-pub mod token;
-/// type to respresent responses from /userprincipals/ endpoint
-pub mod userprincipals;
+/// type to represent optionchains from /marketdata/chains
+pub mod optionchain;
 /// type to represent price history from /marketdata/SYM/pricehistory
 pub mod pricehistory;
 /// type to represent quotes from /marketdata/quotes?SYM1,SYM2,etc
 pub mod quote;
-/// type to represent optionchains from /marketdata/chains
-pub mod optionchain;
+/// type to represent token authorization response from /oauth2/token endpoint
+pub mod token;
+/// type to respresent responses from /userprincipals/ endpoint
+pub mod userprincipals;
+
+fn ok_or_default<'a, T, D>(deserializer: D) -> Result<T, D::Error>
+where
+    T: Deserialize<'a> + Default,
+    D: Deserializer<'a>,
+{
+    let v: Value = Deserialize::deserialize(deserializer)?;
+    Ok(T::deserialize(v).unwrap_or_default())
+}
 
\ No newline at end of file diff --git a/docs/doc/src/tdameritradeclient/model/optionchain.rs.html b/docs/doc/src/tdameritradeclient/model/optionchain.rs.html index 8e71ad6..ae45854 100644 --- a/docs/doc/src/tdameritradeclient/model/optionchain.rs.html +++ b/docs/doc/src/tdameritradeclient/model/optionchain.rs.html @@ -84,8 +84,18 @@ 78 79 80 -
use std::collections::HashMap;
+81
+82
+83
+84
+85
+86
+87
+88
+89
+
use super::ok_or_default;
 use serde::Deserialize;
+use std::collections::HashMap;
 
 /// OptionChain Model
 #[derive(Default, Debug, Clone, Deserialize)]
@@ -93,21 +103,21 @@
 pub struct OptionChain {
     pub symbol: String,
     pub status: String,
-//    pub underlying: String - ignore for now
+    //    pub underlying: String - ignore for now
     pub strategy: String,
     pub interval: f64,
     pub is_delayed: bool,
     pub is_index: bool,
     pub interest_rate: f64,
-    #[serde(default)]
+    #[serde(deserialize_with = "ok_or_default")]
     pub underlying_price: f64,
     pub volatility: f64,
-//    pub days_to_expiration: i64 - not sure what this is at top level
+    //    pub days_to_expiration: i64 - not sure what this is at top level
     pub number_of_contracts: i64,
     // format is HashMap< expiredate, HashMap< strike, [optionquote] > >
-    #[serde(default)]
+    #[serde(deserialize_with = "ok_or_default")]
     pub put_exp_date_map: HashMap<String, HashMap<String, Vec<OptionQuote>>>,
-    #[serde(default)]
+    #[serde(deserialize_with = "ok_or_default")]
     pub call_exp_date_map: HashMap<String, HashMap<String, Vec<OptionQuote>>>,
 }
 
@@ -131,21 +141,29 @@
     pub open_price: f64,
     pub close_price: f64,
     pub total_volume: i64,
-//    pub trade_date: Value,
+    //    pub trade_date: Value,
     pub trade_time_in_long: i64,
     pub quote_time_in_long: i64,
     pub net_change: f64,
+    #[serde(deserialize_with = "ok_or_default")]
     pub volatility: f64,
+    #[serde(deserialize_with = "ok_or_default")]
     pub delta: f64,
+    #[serde(deserialize_with = "ok_or_default")]
     pub gamma: f64,
+    #[serde(deserialize_with = "ok_or_default")]
     pub theta: f64,
+    #[serde(deserialize_with = "ok_or_default")]
     pub vega: f64,
+    #[serde(deserialize_with = "ok_or_default")]
     pub rho: f64,
     pub open_interest: i64,
     pub time_value: f64,
+    #[serde(deserialize_with = "ok_or_default")]
     pub theoretical_option_value: f64,
+    #[serde(deserialize_with = "ok_or_default")]
     pub theoretical_volatility: f64,
-//    pub option_deliverables_list: Value,
+    //    pub option_deliverables_list: Value,
     pub strike_price: f64,
     pub expiration_date: i64,
     pub days_to_expiration: i64,
@@ -154,7 +172,7 @@
     pub multiplier: f64,
     pub settlement_type: String,
     pub deliverable_note: String,
-//    pub is_index_option: Value,
+    //    pub is_index_option: Value,
     pub percent_change: f64,
     pub mark_change: f64,
     pub mark_percent_change: f64,
diff --git a/docs/doc/src/tdameritradeclient/model/pricehistory.rs.html b/docs/doc/src/tdameritradeclient/model/pricehistory.rs.html
index 6388210..aae6db6 100644
--- a/docs/doc/src/tdameritradeclient/model/pricehistory.rs.html
+++ b/docs/doc/src/tdameritradeclient/model/pricehistory.rs.html
@@ -55,6 +55,7 @@
     pub fn get_close_series(&self) -> Vec<f64> {
         self.candles.iter().map(|candle| candle.close).collect()
     }
-}
+} +
\ No newline at end of file diff --git a/docs/doc/src/tdameritradeclient/model/quote.rs.html b/docs/doc/src/tdameritradeclient/model/quote.rs.html index 87e0c2b..a8caa94 100644 --- a/docs/doc/src/tdameritradeclient/model/quote.rs.html +++ b/docs/doc/src/tdameritradeclient/model/quote.rs.html @@ -222,15 +222,14 @@ 216 217 218 -219 -
use std::collections::HashMap;
+
use serde::{Deserialize, Serialize};
 use serde_json::Value;
-use serde::{Deserialize, Serialize};
+use std::collections::HashMap;
 ///
 /// Quote
 ///
 /// Deserialized through a HashMap<String, Quote>
-/// 
+///
 #[derive(Debug, Serialize, Deserialize, Clone)]
 #[serde(rename_all = "camelCase", untagged)]
 pub enum Quote {
@@ -244,7 +243,7 @@
 #[derive(Debug, Serialize, Deserialize, Clone)]
 #[serde(rename_all = "camelCase")]
 pub struct QEquity {
-    pub asset_type: String,    
+    pub asset_type: String,
     pub symbol: String,
     pub description: String,
     pub bid_price: f64,
@@ -294,7 +293,7 @@
 #[derive(Debug, Serialize, Deserialize, Clone)]
 #[serde(rename_all = "camelCase")]
 pub struct QIndex {
-    pub asset_type: String,    
+    pub asset_type: String,
     pub symbol: String,
     pub description: String,
     pub last_price: f64,
@@ -316,12 +315,12 @@
     pub net_percent_change_in_double: f64,
     #[serde(flatten)]
     extra: HashMap<String, Value>,
-}   
+}
 
 #[derive(Debug, Serialize, Deserialize, Clone)]
 #[serde(rename_all = "camelCase")]
 pub struct QOption {
-    pub asset_type: String,    
+    pub asset_type: String,
     pub symbol: String,
     pub description: String,
     pub bid_price: f64,
@@ -376,7 +375,7 @@
 #[derive(Debug, Serialize, Deserialize, Clone)]
 #[serde(rename_all = "camelCase")]
 pub struct QFund {
-    pub asset_type: String,    
+    pub asset_type: String,
     pub symbol: String,
     pub description: String,
     pub close_price: f64,
@@ -406,13 +405,12 @@
 #[derive(Debug, Serialize, Deserialize, Clone)]
 #[serde(rename_all = "camelCase")]
 pub struct QGeneral {
-    pub asset_type: String,    
+    pub asset_type: String,
     pub symbol: String,
     #[serde(flatten)]
     extra: HashMap<String, Value>,
 }
 
-
 impl Quote {
     pub fn symbol(&self) -> &str {
         match self {
diff --git a/docs/doc/src/tdameritradeclient/model/userprincipals.rs.html b/docs/doc/src/tdameritradeclient/model/userprincipals.rs.html
index 8585ace..e3f93a4 100644
--- a/docs/doc/src/tdameritradeclient/model/userprincipals.rs.html
+++ b/docs/doc/src/tdameritradeclient/model/userprincipals.rs.html
@@ -121,7 +121,7 @@
 ///
 /// Holds Type for UserPrincipals response
 ///
-#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)]
+#[derive(Default, Debug, Clone, Serialize, Deserialize)]
 #[serde(rename_all = "camelCase")]
 pub struct UserPrincipals {
     #[serde(skip)]
@@ -143,7 +143,7 @@
     pub accounts: Vec<Account>,
 }
 
-#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)]
+#[derive(Default, Debug, Clone, Serialize, Deserialize)]
 #[serde(rename_all = "camelCase")]
 pub struct StreamerInfo {
     pub streamer_binary_url: String,
@@ -156,7 +156,7 @@
     pub app_id: String,
 }
 
-#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)]
+#[derive(Default, Debug, Clone, Serialize, Deserialize)]
 #[serde(rename_all = "camelCase")]
 pub struct Quotes {
     pub is_nyse_delayed: bool,
@@ -168,19 +168,19 @@
     pub is_forex_delayed: bool,
 }
 
-#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)]
+#[derive(Default, Debug, Clone, Serialize, Deserialize)]
 #[serde(rename_all = "camelCase")]
 pub struct StreamerSubscriptionKeys {
     pub keys: Vec<Key>,
 }
 
-#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)]
+#[derive(Default, Debug, Clone, Serialize, Deserialize)]
 #[serde(rename_all = "camelCase")]
 pub struct Key {
     pub key: String,
 }
 
-#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)]
+#[derive(Default, Debug, Clone, Serialize, Deserialize)]
 #[serde(rename_all = "camelCase")]
 pub struct Account {
     pub account_id: String,
@@ -198,7 +198,7 @@
     pub authorizations: Authorizations,
 }
 
-#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)]
+#[derive(Default, Debug, Clone, Serialize, Deserialize)]
 #[serde(rename_all = "camelCase")]
 pub struct Preferences {
     pub express_trading: bool,
@@ -217,7 +217,7 @@
     pub auth_token_timeout: String,
 }
 
-#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)]
+#[derive(Default, Debug, Clone, Serialize, Deserialize)]
 #[serde(rename_all = "camelCase")]
 pub struct Authorizations {
     pub apex: bool,
diff --git a/docs/doc/src/tdameritradeclient/tdaclient.rs.html b/docs/doc/src/tdameritradeclient/tdaclient.rs.html
index 734c6d6..ce0b40e 100644
--- a/docs/doc/src/tdameritradeclient/tdaclient.rs.html
+++ b/docs/doc/src/tdameritradeclient/tdaclient.rs.html
@@ -198,13 +198,17 @@
 192
 193
 194
+195
+196
 
#![warn(clippy::all, clippy::pedantic)]
 #![allow(clippy::must_use_candidate)]
 use crate::param::{convert_to_pairs, Pair};
 use crate::request::Endpoint;
+use crate::Result;
 use attohttpc::{RequestBuilder, Response, Session};
 use log::info;
 use std::time::Duration;
+
 ///
 /// Main client to access TD Ameritrade endpoints
 ///
@@ -215,6 +219,11 @@
 /// 2) convert to `serde_json::Value`
 /// 3) use `serde_json::Value` output to parse into a response `model` type
 ///
+/// # Error
+///
+/// Any errors with request to API will be returned as `tdameritradeclient::Error::TDAClientError`
+/// These errors will be issue with the connection or trouble parsing the output if using `serde_json`
+///
 #[derive(Debug, Default)]
 pub struct TDAClient {
     auth_token: String,
@@ -255,7 +264,9 @@
     ///
     /// See param for matching parameters
     ///
-    pub fn get<'a, P, T>(&self, ep: &Endpoint, params: P) -> T
+    /// # Errors
+    /// Will return either a web connection issue or a parse error
+    pub fn get<'a, P, T>(&self, ep: &Endpoint, params: P) -> Result<T>
     where
         RequestBuilder: Execute<T>,
         P: IntoIterator,
@@ -271,9 +282,9 @@
     /// post endpoint with json body
     ///
     /// # Errors
-    /// if nothing was returned than request was good, otherwise a json string will be returned indicating error
+    /// Will return either a web connection issue or a parse error
     ///
-    pub fn post<'a, T>(&self, ep: &Endpoint, body: &'a str) -> T
+    pub fn post<'a, T>(&self, ep: &Endpoint, body: &'a str) -> Result<T>
     where
         // RequestBuilder: Execute<T>,
         RequestBuilder<attohttpc::body::Text<&'a str>>: Execute<T>,
@@ -288,9 +299,9 @@
     /// put endpoint with json body
     ///
     /// # Errors
-    /// if nothing was returned than request was good, otherwise a json string will be returned indicating error
+    /// Will return either a web connection issue or a parse error
     ///
-    pub fn put<'a, T>(&self, ep: &Endpoint, body: &'a str) -> T
+    pub fn put<'a, T>(&self, ep: &Endpoint, body: &'a str) -> Result<T>
     where
         // RequestBuilder: Execute<T>,
         RequestBuilder<attohttpc::body::Text<&'a str>>: Execute<T>,
@@ -305,9 +316,9 @@
     /// patch endpoint with json body
     ///
     /// # Errors
-    /// if nothing was returned than request was good, otherwise a json string will be returned indicating error
+    /// Will return either a web connection issue or a parse error
     ///
-    pub fn patch<'a, T>(&self, ep: &Endpoint, body: &'a str) -> T
+    pub fn patch<'a, T>(&self, ep: &Endpoint, body: &'a str) -> Result<T>
     where
         // RequestBuilder: Execute<T>,
         RequestBuilder<attohttpc::body::Text<&'a str>>: Execute<T>,
@@ -322,7 +333,10 @@
     ///
     /// delete endpoint
     ///
-    pub fn delete<T>(&self, ep: &Endpoint) -> T
+    /// # Errors
+    /// Will return either a web connection issue or a parse error
+    ///
+    pub fn delete<T>(&self, ep: &Endpoint) -> Result<T>
     where
         RequestBuilder: Execute<T>,
     {
@@ -337,37 +351,27 @@
 /// 2) `serde_json::Value` - as a JSON object format
 ///
 pub trait Execute<T> {
-    fn execute(self) -> T;
+    fn execute(self) -> Result<T>;
 }
 
 impl Execute<String> for RequestBuilder {
-    fn execute(self) -> String {
+    fn execute(self) -> Result<String> {
         let response = preexecute(self);
-        response
-            .text()
-            .expect("Response did not return BODY: ERROR")
+        Ok(response.text()?)
     }
 }
 
 impl Execute<String> for RequestBuilder<attohttpc::body::Text<&str>> {
-    fn execute(self) -> String {
+    fn execute(self) -> Result<String> {
         let response = preexecute_wbody(self);
-        response
-            .text()
-            .expect("Response did not return BODY: ERROR")
+        Ok(response.text()?)
     }
 }
 
 impl Execute<serde_json::Value> for RequestBuilder {
-    fn execute(self) -> serde_json::Value {
+    fn execute(self) -> Result<serde_json::Value> {
         let response = preexecute(self);
-        serde_json::from_str(
-            response
-                .text()
-                .expect("Response did not return JSON: ERROR")
-                .as_str(),
-        )
-        .expect("SERDE: Trouble parsing json text: ERROR")
+        Ok(serde_json::from_str(response.text()?.as_str())?)
     }
 }
 
diff --git a/docs/doc/tdameritradeclient/all.html b/docs/doc/tdameritradeclient/all.html
index 4f227e0..9f800ef 100644
--- a/docs/doc/tdameritradeclient/all.html
+++ b/docs/doc/tdameritradeclient/all.html
@@ -4,5 +4,5 @@
     
+

List of all items

Structs

Enums

Traits

Functions

\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/auth/index.html b/docs/doc/tdameritradeclient/auth/index.html index ae2dd92..501e61e 100644 --- a/docs/doc/tdameritradeclient/auth/index.html +++ b/docs/doc/tdameritradeclient/auth/index.html @@ -5,7 +5,7 @@

Module auth

Expand description

utility module to help with authorization token, refresh token and grant code

+

Module tdameritradeclient::auth

source · []
Expand description

utility module to help with authorization token, refresh token and grant code

You can use the public functions or the TDauth struct. TDauth allows you to store the information for reuse.

Structs

diff --git a/docs/doc/tdameritradeclient/auth/struct.TDauth.html b/docs/doc/tdameritradeclient/auth/struct.TDauth.html index 5d327df..78b3b1c 100644 --- a/docs/doc/tdameritradeclient/auth/struct.TDauth.html +++ b/docs/doc/tdameritradeclient/auth/struct.TDauth.html @@ -5,7 +5,7 @@

TDauth

pub struct TDauth { /* private fields */ }
Expand description

These are tools to help manage authorization tokens with TD Ameritrade API

+

Struct tdameritradeclient::auth::TDauth

source · []
pub struct TDauth { /* private fields */ }
Expand description

These are tools to help manage authorization tokens with TD Ameritrade API

  1. getcodeweblink is a link created from parameters registered with deverloper.tdameritrade.com.
    The link can be used to return a code to use to request a valid token and refresh token. You will need to log in with your TDAmeritrade Credentials. @@ -13,29 +13,31 @@

    Struct tdameritrad
  2. new_fromcode will allow you to update tokens from the code retrieved in 1)
  3. new_fromrefresh will allow you to update tokens from the refresh_token. The refresh_token will stay active for 90 days so you can save for reuse.
-

Implementations

create new TDauth with configuration only

-

create new TDauth with refresh_token and clientid +

Errors

+

Any Web issues will reset token and send default TDAUTH struct which will be empty

+

Implementations

create new TDauth with configuration only

+

create new TDauth with refresh_token and clientid if successful TDauth will carry new valid token if refreshupdate is true than refresh_token will also be updated

-

create new TDauth with code, redirecturi and clientid +

create new TDauth with code, redirecturi and clientid if successful TDauth will carry both new refresh_token and new valid token

you can use decode=true if you did NOT decode it only useful if you are using the browser to get code from query string

-

get /oauth2/token +

get /oauth2/token token endpoint returns an access token along with an refresh token using refresh_token grant type and retrieves new refresh_token (optional)

returns full response and updates TDauth struct

-

get /oauth2/token +

get /oauth2/token token endpoint returns an access token along with an optional refresh token using authorization_code grant type and retrieves new refresh_token (response returned) while storing valid token inside client

returns full json response as text and updates TDAuth

if grabbing code from browser as per the instructions on developer.tdameritrade.com then you will need to decode it. As the code is encoded when put in post body.

you can use decode=true if you did NOT decode it only useful if you are using the browser to get code from query string

-

Trait Implementations

Returns a copy of the value. Read more

+

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

-

Formats the value using the given formatter. Read more

-

Returns the “default value” for a type. Read more

-

Serialize this value into the given Serde serializer. Read more

+

Formats the value using the given formatter. Read more

+

Returns the “default value” for a type. Read more

+

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

diff --git a/docs/doc/tdameritradeclient/error/enum.TDAClientError.html b/docs/doc/tdameritradeclient/error/enum.TDAClientError.html new file mode 100644 index 0000000..5e9ee5e --- /dev/null +++ b/docs/doc/tdameritradeclient/error/enum.TDAClientError.html @@ -0,0 +1,34 @@ +TDAClientError in tdameritradeclient::error - Rust +
pub enum TDAClientError {
+    WebConnectIssue(Error),
+    ParseError(Error),
+}

Variants

WebConnectIssue(Error)

Deals with connection io issues to the web API

+

ParseError(Error)

Any issues in parsing the response

+

Trait Implementations

Formats the value using the given formatter. Read more

+

Formats the value using the given formatter. Read more

+

The lower-level source of this error, if any. Read more

+
🔬 This is a nightly-only experimental API. (backtrace)

Returns a stack backtrace, if available, of where this error occurred. Read more

+
👎 Deprecated since 1.42.0:

use the Display impl or to_string()

+
👎 Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

+

Converts to this type from the input type.

+

Converts to this type from the input type.

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Immutably borrows from an owned value. Read more

+

Mutably borrows from an owned value. Read more

+

Returns the argument unchanged.

+

Calls U::from(self).

+

That is, this conversion is whatever the implementation of +From<T> for U chooses to do.

+

Converts the given value to a String. Read more

+

The type returned in the event of a conversion error.

+

Performs the conversion.

+

The type returned in the event of a conversion error.

+

Performs the conversion.

+
+ \ No newline at end of file diff --git a/docs/doc/tdameritradeclient/error/index.html b/docs/doc/tdameritradeclient/error/index.html new file mode 100644 index 0000000..eb38b87 --- /dev/null +++ b/docs/doc/tdameritradeclient/error/index.html @@ -0,0 +1,11 @@ +tdameritradeclient::error - Rust +
Expand description

Rolled up Errors for TDAClient

+

Enums

+
+ \ No newline at end of file diff --git a/docs/doc/tdameritradeclient/error/sidebar-items.js b/docs/doc/tdameritradeclient/error/sidebar-items.js new file mode 100644 index 0000000..28ece70 --- /dev/null +++ b/docs/doc/tdameritradeclient/error/sidebar-items.js @@ -0,0 +1 @@ +window.SIDEBAR_ITEMS = {"enum":[["TDAClientError",""]]}; \ No newline at end of file diff --git a/docs/doc/tdameritradeclient/index.html b/docs/doc/tdameritradeclient/index.html index 9f95b7d..528c2a1 100644 --- a/docs/doc/tdameritradeclient/index.html +++ b/docs/doc/tdameritradeclient/index.html @@ -2,10 +2,10 @@

Expand description
Expand description

tdameritradeclient

TDAClient is the main struct that lets you build requests to TDAmeritrade’s API

See TD Ameritrade API for API documentation

Create TDAClient with a valid Access Token - see TD Ameritrade API for info on creating token

@@ -43,13 +43,14 @@

Example

let c = TDAClient::new(token); // get quotes for 3 symbols and execute -let resptxt: String = c.get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,TRP")]); +let resptxt: String = c.get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,TRP")]).unwrap(); // output will be text string in json format println!("{:?}", resptxt);

Re-exports

pub use request::Endpoint;

Modules

utility module to help with authorization token, refresh token and grant code

+

Rolled up Errors for TDAClient

models that define types to parse json response or value responses from API

holds all the available query parameters used with the endpoints

holds all the relevant API endpoints

diff --git a/docs/doc/tdameritradeclient/model/account/struct.AccountRoot.html b/docs/doc/tdameritradeclient/model/account/struct.AccountRoot.html index 17ea1d6..eb15dc2 100644 --- a/docs/doc/tdameritradeclient/model/account/struct.AccountRoot.html +++ b/docs/doc/tdameritradeclient/model/account/struct.AccountRoot.html @@ -2,7 +2,7 @@

pub struct AccountRoot {
@@ -13,12 +13,9 @@ 

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -32,5 +29,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/account/struct.CurrentBalances.html b/docs/doc/tdameritradeclient/model/account/struct.CurrentBalances.html index df9c1c3..ddda24e 100644 --- a/docs/doc/tdameritradeclient/model/account/struct.CurrentBalances.html +++ b/docs/doc/tdameritradeclient/model/account/struct.CurrentBalances.html @@ -2,7 +2,7 @@

pub struct CurrentBalances {
Show 28 fields @@ -38,12 +38,9 @@

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -57,5 +54,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/account/struct.InitialBalances.html b/docs/doc/tdameritradeclient/model/account/struct.InitialBalances.html index 6d6d090..39cbf16 100644 --- a/docs/doc/tdameritradeclient/model/account/struct.InitialBalances.html +++ b/docs/doc/tdameritradeclient/model/account/struct.InitialBalances.html @@ -2,7 +2,7 @@

pub struct InitialBalances {
Show 32 fields @@ -42,12 +42,9 @@

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -61,5 +58,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/account/struct.Instrument.html b/docs/doc/tdameritradeclient/model/account/struct.Instrument.html index f04319f..65af2fc 100644 --- a/docs/doc/tdameritradeclient/model/account/struct.Instrument.html +++ b/docs/doc/tdameritradeclient/model/account/struct.Instrument.html @@ -2,7 +2,7 @@

pub struct Instrument {
@@ -17,12 +17,9 @@ 

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -36,5 +33,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/account/struct.OrderLegCollection.html b/docs/doc/tdameritradeclient/model/account/struct.OrderLegCollection.html index ac75fc8..5ac718f 100644 --- a/docs/doc/tdameritradeclient/model/account/struct.OrderLegCollection.html +++ b/docs/doc/tdameritradeclient/model/account/struct.OrderLegCollection.html @@ -2,7 +2,7 @@

pub struct OrderLegCollection {
@@ -16,12 +16,9 @@ 

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -35,5 +32,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/account/struct.OrderStrategy.html b/docs/doc/tdameritradeclient/model/account/struct.OrderStrategy.html index c98995a..5d060fa 100644 --- a/docs/doc/tdameritradeclient/model/account/struct.OrderStrategy.html +++ b/docs/doc/tdameritradeclient/model/account/struct.OrderStrategy.html @@ -2,7 +2,7 @@

pub struct OrderStrategy {
Show 19 fields @@ -29,12 +29,9 @@

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -48,5 +45,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/account/struct.Position.html b/docs/doc/tdameritradeclient/model/account/struct.Position.html index af90b6a..133046d 100644 --- a/docs/doc/tdameritradeclient/model/account/struct.Position.html +++ b/docs/doc/tdameritradeclient/model/account/struct.Position.html @@ -2,7 +2,7 @@

pub struct Position {
Show 13 fields @@ -23,12 +23,9 @@

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -42,5 +39,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/account/struct.ProjectedBalances.html b/docs/doc/tdameritradeclient/model/account/struct.ProjectedBalances.html index 4d66649..5d3a0bf 100644 --- a/docs/doc/tdameritradeclient/model/account/struct.ProjectedBalances.html +++ b/docs/doc/tdameritradeclient/model/account/struct.ProjectedBalances.html @@ -2,7 +2,7 @@

pub struct ProjectedBalances {
@@ -19,12 +19,9 @@ 

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -38,5 +35,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/account/struct.SecuritiesAccount.html b/docs/doc/tdameritradeclient/model/account/struct.SecuritiesAccount.html index 4abadc1..f0066d6 100644 --- a/docs/doc/tdameritradeclient/model/account/struct.SecuritiesAccount.html +++ b/docs/doc/tdameritradeclient/model/account/struct.SecuritiesAccount.html @@ -2,7 +2,7 @@

pub struct SecuritiesAccount {
@@ -20,12 +20,9 @@ 

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -39,5 +36,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/index.html b/docs/doc/tdameritradeclient/model/index.html index 304e9c3..3409630 100644 --- a/docs/doc/tdameritradeclient/model/index.html +++ b/docs/doc/tdameritradeclient/model/index.html @@ -5,7 +5,7 @@

Module model

Expand description

models that define types to parse json response or value responses from API

+

Module tdameritradeclient::model

source · []
Expand description

models that define types to parse json response or value responses from API

Used: https://transform.tools/json-to-rust-serde to help with struct generation

Modules

type to respresent responses from /accounts/ endpoint

diff --git a/docs/doc/tdameritradeclient/model/optionchain/index.html b/docs/doc/tdameritradeclient/model/optionchain/index.html index 5d86ce3..be9f6b3 100644 --- a/docs/doc/tdameritradeclient/model/optionchain/index.html +++ b/docs/doc/tdameritradeclient/model/optionchain/index.html @@ -5,7 +5,7 @@

Module optionchain

Expand description

type to represent optionchains from /marketdata/chains

+

Module tdameritradeclient::model::optionchain

source · []
Expand description

type to represent optionchains from /marketdata/chains

Structs

OptionChain Model

diff --git a/docs/doc/tdameritradeclient/model/optionchain/struct.OptionChain.html b/docs/doc/tdameritradeclient/model/optionchain/struct.OptionChain.html index 2e7ee02..5001858 100644 --- a/docs/doc/tdameritradeclient/model/optionchain/struct.OptionChain.html +++ b/docs/doc/tdameritradeclient/model/optionchain/struct.OptionChain.html @@ -5,7 +5,7 @@

OptionChain

pub struct OptionChain {
+    

Struct tdameritradeclient::model::optionchain::OptionChain

source · []
pub struct OptionChain {
     pub symbol: String,
     pub status: String,
     pub strategy: String,
@@ -19,11 +19,11 @@ 

Struct tdamerit pub put_exp_date_map: HashMap<String, HashMap<String, Vec<OptionQuote>>>, pub call_exp_date_map: HashMap<String, HashMap<String, Vec<OptionQuote>>>, }

Expand description

OptionChain Model

-

Fields

symbol: Stringstatus: Stringstrategy: Stringinterval: f64is_delayed: boolis_index: boolinterest_rate: f64underlying_price: f64volatility: f64number_of_contracts: i64put_exp_date_map: HashMap<String, HashMap<String, Vec<OptionQuote>>>call_exp_date_map: HashMap<String, HashMap<String, Vec<OptionQuote>>>

Trait Implementations

Returns a copy of the value. Read more

+

Fields

symbol: Stringstatus: Stringstrategy: Stringinterval: f64is_delayed: boolis_index: boolinterest_rate: f64underlying_price: f64volatility: f64number_of_contracts: i64put_exp_date_map: HashMap<String, HashMap<String, Vec<OptionQuote>>>call_exp_date_map: HashMap<String, HashMap<String, Vec<OptionQuote>>>

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

-

Formats the value using the given formatter. Read more

-

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

+

Formats the value using the given formatter. Read more

+

Returns the “default value” for a type. Read more

+

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

@@ -38,5 +38,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/optionchain/struct.OptionQuote.html b/docs/doc/tdameritradeclient/model/optionchain/struct.OptionQuote.html index 19d7671..6a9a93c 100644 --- a/docs/doc/tdameritradeclient/model/optionchain/struct.OptionQuote.html +++ b/docs/doc/tdameritradeclient/model/optionchain/struct.OptionQuote.html @@ -5,7 +5,7 @@

OptionQuote

pub struct OptionQuote {
Show 46 fields +

Struct tdameritradeclient::model::optionchain::OptionQuote

source · []
pub struct OptionQuote {
Show 46 fields pub put_call: String, pub symbol: String, pub description: String, @@ -52,15 +52,15 @@

Struct tdamerit pub penny_pilot: bool, pub in_the_money: bool, pub mini: bool, -

}

Fields

put_call: Stringsymbol: Stringdescription: Stringexchange_name: Stringbid: f64ask: f64last: f64mark: f64bid_size: i64ask_size: i64bid_ask_size: Stringlast_size: i64high_price: f64low_price: f64open_price: f64close_price: f64total_volume: i64trade_time_in_long: i64quote_time_in_long: i64net_change: f64volatility: f64delta: f64gamma: f64theta: f64vega: f64rho: f64open_interest: i64time_value: f64theoretical_option_value: f64theoretical_volatility: f64strike_price: f64expiration_date: i64days_to_expiration: i64expiration_type: Stringlast_trading_day: i64multiplier: f64settlement_type: Stringdeliverable_note: Stringpercent_change: f64mark_change: f64mark_percent_change: f64intrinsic_value: f64non_standard: boolpenny_pilot: boolin_the_money: boolmini: bool

Trait Implementations

Returns a copy of the value. Read more

+
}

Fields

put_call: Stringsymbol: Stringdescription: Stringexchange_name: Stringbid: f64ask: f64last: f64mark: f64bid_size: i64ask_size: i64bid_ask_size: Stringlast_size: i64high_price: f64low_price: f64open_price: f64close_price: f64total_volume: i64trade_time_in_long: i64quote_time_in_long: i64net_change: f64volatility: f64delta: f64gamma: f64theta: f64vega: f64rho: f64open_interest: i64time_value: f64theoretical_option_value: f64theoretical_volatility: f64strike_price: f64expiration_date: i64days_to_expiration: i64expiration_type: Stringlast_trading_day: i64multiplier: f64settlement_type: Stringdeliverable_note: Stringpercent_change: f64mark_change: f64mark_percent_change: f64intrinsic_value: f64non_standard: boolpenny_pilot: boolin_the_money: boolmini: bool

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

-

Formats the value using the given formatter. Read more

-

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used +

Formats the value using the given formatter. Read more

+

Returns the “default value” for a type. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

This method tests for self and other values to be equal, and is used by ==. Read more

-

This method tests for !=.

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

This method tests for !=.

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -74,5 +74,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/pricehistory/struct.Candle.html b/docs/doc/tdameritradeclient/model/pricehistory/struct.Candle.html index b72ce46..3e6ddc2 100644 --- a/docs/doc/tdameritradeclient/model/pricehistory/struct.Candle.html +++ b/docs/doc/tdameritradeclient/model/pricehistory/struct.Candle.html @@ -16,11 +16,11 @@

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

+

Deserialize this value from the given Serde deserializer. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

+

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

@@ -35,5 +35,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/pricehistory/struct.History.html b/docs/doc/tdameritradeclient/model/pricehistory/struct.History.html index 1c792c7..70a2664 100644 --- a/docs/doc/tdameritradeclient/model/pricehistory/struct.History.html +++ b/docs/doc/tdameritradeclient/model/pricehistory/struct.History.html @@ -13,11 +13,11 @@

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

+

Deserialize this value from the given Serde deserializer. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

+

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

@@ -32,5 +32,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/quote/enum.Quote.html b/docs/doc/tdameritradeclient/model/quote/enum.Quote.html index 7629d67..45b5a63 100644 --- a/docs/doc/tdameritradeclient/model/quote/enum.Quote.html +++ b/docs/doc/tdameritradeclient/model/quote/enum.Quote.html @@ -13,11 +13,11 @@

Enum tdameritra General(QGeneral), }
Expand description

Quote

Deserialized through a HashMap<String, Quote>

-

Variants

Equity(QEquity)

Index(QIndex)

Option(QOption)

Fund(QFund)

General(QGeneral)

Implementations

Trait Implementations

Returns a copy of the value. Read more

+

Variants

Equity(QEquity)

Index(QIndex)

Option(QOption)

Fund(QFund)

General(QGeneral)

Implementations

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

Serialize this value into the given Serde serializer. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

@@ -32,5 +32,5 @@

Enum tdameritra

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/quote/index.html b/docs/doc/tdameritradeclient/model/quote/index.html index 2a6a881..f9e6588 100644 --- a/docs/doc/tdameritradeclient/model/quote/index.html +++ b/docs/doc/tdameritradeclient/model/quote/index.html @@ -5,7 +5,7 @@

Module quote

Expand description

type to represent quotes from /marketdata/quotes?SYM1,SYM2,etc

+

Module tdameritradeclient::model::quote

source · []
Expand description

type to represent quotes from /marketdata/quotes?SYM1,SYM2,etc

Structs

Enums

Quote

diff --git a/docs/doc/tdameritradeclient/model/quote/struct.QEquity.html b/docs/doc/tdameritradeclient/model/quote/struct.QEquity.html index cea3efd..bdf3ab4 100644 --- a/docs/doc/tdameritradeclient/model/quote/struct.QEquity.html +++ b/docs/doc/tdameritradeclient/model/quote/struct.QEquity.html @@ -51,8 +51,8 @@

Struct tdamerit

}

Fields

asset_type: Stringsymbol: Stringdescription: Stringbid_price: f64bid_size: f64bid_id: Stringask_price: f64ask_size: f64ask_id: Stringlast_price: f64last_size: f64last_id: Stringopen_price: f64high_price: f64low_price: f64close_price: f64net_change: f64total_volume: i64quote_time_in_long: i64trade_time_in_long: i64mark: f64cusip: Stringexchange: Stringexchange_name: Stringmarginable: boolshortable: boolvolatility: f64digits: i64n52wk_high: f64n52wk_low: f64pe_ratio: f64div_amount: f64div_yield: f64div_date: Stringsecurity_status: Stringregular_market_last_price: f64regular_market_last_size: f64regular_market_net_change: f64regular_market_trade_time_in_long: f64net_percent_change_in_double: f64mark_change_in_double: f64

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

Serialize this value into the given Serde serializer. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

@@ -67,5 +67,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/quote/struct.QFund.html b/docs/doc/tdameritradeclient/model/quote/struct.QFund.html index d415e05..ac68f24 100644 --- a/docs/doc/tdameritradeclient/model/quote/struct.QFund.html +++ b/docs/doc/tdameritradeclient/model/quote/struct.QFund.html @@ -30,8 +30,8 @@

Struct tdamerit }

Fields

asset_type: Stringsymbol: Stringdescription: Stringclose_price: f64net_change: f64total_volume: i64trade_time_in_long: i64cusip: Stringexchange: Stringexchange_name: Stringdigits: i64n52wk_high: f64n52wk_low: f64nav: f64pe_ratio: f64div_amount: f64div_yield: f64div_date: Stringsecurity_status: Stringnet_percent_change_in_double: f64

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

Serialize this value into the given Serde serializer. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

@@ -46,5 +46,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/quote/struct.QGeneral.html b/docs/doc/tdameritradeclient/model/quote/struct.QGeneral.html index 95b594e..6de6535 100644 --- a/docs/doc/tdameritradeclient/model/quote/struct.QGeneral.html +++ b/docs/doc/tdameritradeclient/model/quote/struct.QGeneral.html @@ -12,8 +12,8 @@

Struct tdamerit }

Fields

asset_type: Stringsymbol: String

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

Serialize this value into the given Serde serializer. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

@@ -28,5 +28,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/quote/struct.QIndex.html b/docs/doc/tdameritradeclient/model/quote/struct.QIndex.html index a586a2d..77cbc7a 100644 --- a/docs/doc/tdameritradeclient/model/quote/struct.QIndex.html +++ b/docs/doc/tdameritradeclient/model/quote/struct.QIndex.html @@ -28,8 +28,8 @@

Struct tdamerit }

Fields

asset_type: Stringsymbol: Stringdescription: Stringlast_price: f64open_price: f64high_price: f64low_price: f64close_price: f64net_change: f64total_volume: i64trade_time_in_long: i64exchange: Stringexchange_name: Stringdigits: i64n52wk_high: f64n52wk_low: f64security_status: Stringnet_percent_change_in_double: f64

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

Serialize this value into the given Serde serializer. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

@@ -44,5 +44,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/quote/struct.QOption.html b/docs/doc/tdameritradeclient/model/quote/struct.QOption.html index 69cf43a..e63a5f3 100644 --- a/docs/doc/tdameritradeclient/model/quote/struct.QOption.html +++ b/docs/doc/tdameritradeclient/model/quote/struct.QOption.html @@ -58,8 +58,8 @@

Struct tdamerit }

Fields

asset_type: Stringsymbol: Stringdescription: Stringbid_price: f64bid_size: f64ask_price: f64ask_size: f64last_price: f64last_size: f64open_price: f64high_price: f64low_price: f64close_price: f64net_change: f64total_volume: i64quote_time_in_long: i64trade_time_in_long: i64mark: f64cusip: Stringopen_interest: f64volatility: f64money_intrinsic_value: f64multiplier: f64strike_price: f64contract_type: Stringunderlying: Stringtime_value: f64deliverables: Stringdelta: f64gamma: f64theta: f64vega: f64rho: f64security_status: Stringtheoretical_option_value: f64underlying_price: f64uv_expiration_type: Stringexchange: Stringexchange_name: Stringsettlement_type: Stringnet_percent_change_in_double: f64mark_change_in_double: f64last_trading_day: i64expiration_day: i64expiration_month: i64expiration_year: i64days_to_expiration: i64implied_yield: f64

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

Serialize this value into the given Serde serializer. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

@@ -74,5 +74,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/token/struct.ErrorResponse.html b/docs/doc/tdameritradeclient/model/token/struct.ErrorResponse.html index fc191c9..82ba74f 100644 --- a/docs/doc/tdameritradeclient/model/token/struct.ErrorResponse.html +++ b/docs/doc/tdameritradeclient/model/token/struct.ErrorResponse.html @@ -9,7 +9,7 @@

Struct tdamerit pub error: String, }

Fields

error: String

Trait Implementations

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

+

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

@@ -21,5 +21,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/token/struct.TokenResponse.html b/docs/doc/tdameritradeclient/model/token/struct.TokenResponse.html index 827dedd..5f93e82 100644 --- a/docs/doc/tdameritradeclient/model/token/struct.TokenResponse.html +++ b/docs/doc/tdameritradeclient/model/token/struct.TokenResponse.html @@ -15,7 +15,7 @@

Struct tdamerit }
Expand description

Holds Type Authorization response

Fields

access_token: Stringrefresh_token: Stringtoken_type: Stringexpires_in: u64scope: Stringrefresh_token_expires_in: u64

Trait Implementations

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

+

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

@@ -27,5 +27,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/userprincipals/struct.Account.html b/docs/doc/tdameritradeclient/model/userprincipals/struct.Account.html index 1f37478..128ad26 100644 --- a/docs/doc/tdameritradeclient/model/userprincipals/struct.Account.html +++ b/docs/doc/tdameritradeclient/model/userprincipals/struct.Account.html @@ -2,7 +2,7 @@

pub struct Account {
@@ -20,12 +20,9 @@ 

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -39,5 +36,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/userprincipals/struct.Authorizations.html b/docs/doc/tdameritradeclient/model/userprincipals/struct.Authorizations.html index 0a0eee6..595fefe 100644 --- a/docs/doc/tdameritradeclient/model/userprincipals/struct.Authorizations.html +++ b/docs/doc/tdameritradeclient/model/userprincipals/struct.Authorizations.html @@ -2,7 +2,7 @@

pub struct Authorizations {
@@ -19,12 +19,9 @@ 

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -38,5 +35,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/userprincipals/struct.Key.html b/docs/doc/tdameritradeclient/model/userprincipals/struct.Key.html index d51a1e9..b864da8 100644 --- a/docs/doc/tdameritradeclient/model/userprincipals/struct.Key.html +++ b/docs/doc/tdameritradeclient/model/userprincipals/struct.Key.html @@ -2,7 +2,7 @@

pub struct Key {
@@ -11,12 +11,9 @@ 

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -30,5 +27,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/userprincipals/struct.Preferences.html b/docs/doc/tdameritradeclient/model/userprincipals/struct.Preferences.html index 2b6dcc9..b56917c 100644 --- a/docs/doc/tdameritradeclient/model/userprincipals/struct.Preferences.html +++ b/docs/doc/tdameritradeclient/model/userprincipals/struct.Preferences.html @@ -2,7 +2,7 @@

pub struct Preferences {
Show 14 fields @@ -24,12 +24,9 @@

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -43,5 +40,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/userprincipals/struct.Quotes.html b/docs/doc/tdameritradeclient/model/userprincipals/struct.Quotes.html index 369ed42..91cfb56 100644 --- a/docs/doc/tdameritradeclient/model/userprincipals/struct.Quotes.html +++ b/docs/doc/tdameritradeclient/model/userprincipals/struct.Quotes.html @@ -2,7 +2,7 @@

pub struct Quotes {
@@ -17,12 +17,9 @@ 

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -36,5 +33,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/userprincipals/struct.StreamerInfo.html b/docs/doc/tdameritradeclient/model/userprincipals/struct.StreamerInfo.html index c4138ba..790c283 100644 --- a/docs/doc/tdameritradeclient/model/userprincipals/struct.StreamerInfo.html +++ b/docs/doc/tdameritradeclient/model/userprincipals/struct.StreamerInfo.html @@ -2,7 +2,7 @@

pub struct StreamerInfo {
@@ -18,12 +18,9 @@ 

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -37,5 +34,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/userprincipals/struct.StreamerSubscriptionKeys.html b/docs/doc/tdameritradeclient/model/userprincipals/struct.StreamerSubscriptionKeys.html index 2b2929c..81a5f3c 100644 --- a/docs/doc/tdameritradeclient/model/userprincipals/struct.StreamerSubscriptionKeys.html +++ b/docs/doc/tdameritradeclient/model/userprincipals/struct.StreamerSubscriptionKeys.html @@ -2,7 +2,7 @@

pub struct StreamerSubscriptionKeys {
@@ -11,12 +11,9 @@ 

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -30,5 +27,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/model/userprincipals/struct.UserPrincipals.html b/docs/doc/tdameritradeclient/model/userprincipals/struct.UserPrincipals.html index 6652c7f..5561956 100644 --- a/docs/doc/tdameritradeclient/model/userprincipals/struct.UserPrincipals.html +++ b/docs/doc/tdameritradeclient/model/userprincipals/struct.UserPrincipals.html @@ -2,7 +2,7 @@

pub struct UserPrincipals {
Show 14 fields @@ -25,12 +25,9 @@

Struct tdamerit

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

-

Deserialize this value from the given Serde deserializer. Read more

-

This method tests for self and other values to be equal, and is used -by ==. Read more

-

This method tests for !=.

-

Serialize this value into the given Serde serializer. Read more

-

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

+

Deserialize this value from the given Serde deserializer. Read more

+

Serialize this value into the given Serde serializer. Read more

+

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

@@ -44,5 +41,5 @@

Struct tdamerit

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

-
+
\ No newline at end of file diff --git a/docs/doc/tdameritradeclient/sidebar-items.js b/docs/doc/tdameritradeclient/sidebar-items.js index 9506cd4..7bd7730 100644 --- a/docs/doc/tdameritradeclient/sidebar-items.js +++ b/docs/doc/tdameritradeclient/sidebar-items.js @@ -1 +1 @@ -window.SIDEBAR_ITEMS = {"mod":[["auth","utility module to help with authorization token, refresh token and grant code"],["model","models that define types to parse json response or value responses from API"],["param","holds all the available query parameters used with the endpoints"],["request","holds all the relevant API endpoints"]],"struct":[["TDAClient","Main client to access TD Ameritrade endpoints"],["TDAClientAuth","Wrapper around `TDAClient` that handles managing the authorization token"]]}; \ No newline at end of file +window.SIDEBAR_ITEMS = {"mod":[["auth","utility module to help with authorization token, refresh token and grant code"],["error","Rolled up Errors for TDAClient"],["model","models that define types to parse json response or value responses from API"],["param","holds all the available query parameters used with the endpoints"],["request","holds all the relevant API endpoints"]],"struct":[["TDAClient","Main client to access TD Ameritrade endpoints"],["TDAClientAuth","Wrapper around `TDAClient` that handles managing the authorization token"]]}; \ No newline at end of file diff --git a/docs/doc/tdameritradeclient/struct.TDAClient.html b/docs/doc/tdameritradeclient/struct.TDAClient.html index 4864c2f..c65c21d 100644 --- a/docs/doc/tdameritradeclient/struct.TDAClient.html +++ b/docs/doc/tdameritradeclient/struct.TDAClient.html @@ -5,7 +5,7 @@

TDAClient

pub struct TDAClient { /* private fields */ }
Expand description

Main client to access TD Ameritrade endpoints

+

Struct tdameritradeclient::TDAClient

source · []
pub struct TDAClient { /* private fields */ }
Expand description

Main client to access TD Ameritrade endpoints

Uses attohttpc::RequestBuilder to build requests and attohttpc::Session to maintain the same client configuration

Two options for output:

    @@ -13,26 +13,33 @@

    Struct tdameritradecl
  1. convert to serde_json::Value
  2. use serde_json::Value output to parse into a response model type
-

Implementations

Create new base client that maintains Authorization Header

+

Error

+

Any errors with request to API will be returned as tdameritradeclient::Error::TDAClientError +These errors will be issue with the connection or trouble parsing the output if using serde_json

+

Implementations

Create new base client that maintains Authorization Header

Requires valid token from tdameritrade

-

change timeout configuration of Session

-

get endpoint with query parameters

+

change timeout configuration of Session

+

get endpoint with query parameters

See Endpoint for available Endpoints

See param for matching parameters

-

post endpoint with json body

Errors
-

if nothing was returned than request was good, otherwise a json string will be returned indicating error

-

put endpoint with json body

+

Will return either a web connection issue or a parse error

+

post endpoint with json body

Errors
-

if nothing was returned than request was good, otherwise a json string will be returned indicating error

-

patch endpoint with json body

+

Will return either a web connection issue or a parse error

+

put endpoint with json body

Errors
-

if nothing was returned than request was good, otherwise a json string will be returned indicating error

-

delete endpoint

-

Trait Implementations

Returns a copy of the value. Read more

+

Will return either a web connection issue or a parse error

+

patch endpoint with json body

+
Errors
+

Will return either a web connection issue or a parse error

+

delete endpoint

+
Errors
+

Will return either a web connection issue or a parse error

+

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

-

Formats the value using the given formatter. Read more

-

Returns the “default value” for a type. Read more

+

Formats the value using the given formatter. Read more

+

Returns the “default value” for a type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

diff --git a/examples/accountinfo.rs b/examples/accountinfo.rs index a68c876..3032182 100644 --- a/examples/accountinfo.rs +++ b/examples/accountinfo.rs @@ -1,7 +1,7 @@ use std::env; -use tdameritradeclient::{param, Endpoint, TDAClient}; +use tdameritradeclient::{error::TDAClientError, param, Endpoint, TDAClient}; -fn main() { +fn main() -> Result<(), TDAClientError> { env_logger::init(); // grab authorization token from an environmental variable @@ -9,7 +9,7 @@ fn main() { // get userprincipals endpoint title_print("user/account info:"); - let resptxt: serde_json::Value = c.get(&Endpoint::UserPrincipals, &[param::Empty]); + let resptxt: serde_json::Value = c.get(&Endpoint::UserPrincipals, &[param::Empty])?; pretty_print(&resptxt); // pull out primary account id @@ -17,11 +17,13 @@ fn main() { // get account details on positions title_print("position info:"); - pretty_print(&c.get(&Endpoint::Account(accountid), &[param::Account::Positions])); + pretty_print(&c.get(&Endpoint::Account(accountid), &[param::Account::Positions])?); // get account details on any orders title_print("orders:"); - pretty_print(&c.get(&Endpoint::Orders(accountid), &[param::Empty])); + pretty_print(&c.get(&Endpoint::Orders(accountid), &[param::Empty])?); + + Ok(()) } fn pretty_print(toprint: &serde_json::Value) { diff --git a/examples/accountmodel.rs b/examples/accountmodel.rs index 7ac82fe..0ba632b 100644 --- a/examples/accountmodel.rs +++ b/examples/accountmodel.rs @@ -1,9 +1,10 @@ use std::env; +use tdameritradeclient::error::TDAClientError; use tdameritradeclient::model::account::AccountRoot; use tdameritradeclient::model::userprincipals::UserPrincipals; use tdameritradeclient::{param, Endpoint, TDAClient}; -fn main() { +fn main() -> Result<(), TDAClientError> { env_logger::init(); // grab authorization token from an environmental variable @@ -13,7 +14,7 @@ fn main() { title_print("UserPrincipals Model:"); let userprincipals: UserPrincipals = - serde_json::from_value(c.get(&Endpoint::UserPrincipals, &[param::Empty])).unwrap(); + serde_json::from_value(c.get(&Endpoint::UserPrincipals, &[param::Empty])?).unwrap(); println!("{:?}\n", &userprincipals); // pull out primary account id @@ -22,7 +23,7 @@ fn main() { // get account details on positions title_print("Account Position:"); let account_root: AccountRoot = - serde_json::from_value(c.get(&Endpoint::Account(accountid), &[param::Account::Positions])) + serde_json::from_value(c.get(&Endpoint::Account(accountid), &[param::Account::Positions])?) .unwrap(); // pull out positions @@ -37,6 +38,8 @@ fn main() { p.market_value ); } + + Ok(()) } fn title_print(heading: &str) { diff --git a/examples/createorder.rs b/examples/createorder.rs index 14e4a19..4b85b2c 100644 --- a/examples/createorder.rs +++ b/examples/createorder.rs @@ -1,12 +1,12 @@ use std::env; -use tdameritradeclient::{param, Endpoint, TDAClient}; +use tdameritradeclient::{error::TDAClientError, param, Endpoint, TDAClient}; -fn main() { +fn main() -> Result<(), TDAClientError> { env_logger::init(); let c = TDAClient::new(env::var("TDAUTHTOKEN").unwrap()); - let resptxt: serde_json::Value = c.get(&Endpoint::UserPrincipals, &[param::Empty]); + let resptxt: serde_json::Value = c.get(&Endpoint::UserPrincipals, &[param::Empty])?; let accountid = resptxt["primaryAccountId"].as_str().unwrap(); let order_def = r#" @@ -30,14 +30,16 @@ fn main() { "#; // use post method to pass body of order definition/instructions - let resptxt = c.post(&Endpoint::Orders(accountid), &order_def); + let resptxt = c.post(&Endpoint::Orders(accountid), &order_def)?; // outcome of order submit println!("Order Created: '{}'", resptxt); // get working orders and find the order above - let resptxt: serde_json::Value = c.get(&Endpoint::Orders(accountid), &[param::Empty]); + let resptxt: serde_json::Value = c.get(&Endpoint::Orders(accountid), &[param::Empty])?; pretty_print(&resptxt); + + Ok(()) } fn pretty_print(toprint: &serde_json::Value) { diff --git a/examples/deleteorder.rs b/examples/deleteorder.rs index 74af63e..5a6500e 100644 --- a/examples/deleteorder.rs +++ b/examples/deleteorder.rs @@ -1,7 +1,7 @@ use std::env; -use tdameritradeclient::{param, Endpoint, TDAClient}; +use tdameritradeclient::{error::TDAClientError, param, Endpoint, TDAClient}; -fn main() { +fn main() -> Result<(), TDAClientError> { // Delete order by ORDERID env_logger::init(); @@ -11,14 +11,16 @@ fn main() { println!("orderid to delete: {}", orderid); - let resptxt: serde_json::Value = c.get(&Endpoint::UserPrincipals, &[param::Empty]); + let resptxt: serde_json::Value = c.get(&Endpoint::UserPrincipals, &[param::Empty])?; let accountid = resptxt["primaryAccountId"].as_str().unwrap(); - let _: String = c.delete(&Endpoint::Order((&accountid, &orderid))); + let _: String = c.delete(&Endpoint::Order((&accountid, &orderid)))?; - let resptxt: serde_json::Value = c.get(&Endpoint::Orders(accountid), &[param::Empty]); // get working orders + let resptxt: serde_json::Value = c.get(&Endpoint::Orders(accountid), &[param::Empty])?; // get working orders println!("orders remaining: "); prettyprint(&resptxt); + + Ok(()) } fn prettyprint(toprint: &serde_json::Value) { diff --git a/examples/history.rs b/examples/history.rs index 366db85..661cc54 100644 --- a/examples/history.rs +++ b/examples/history.rs @@ -1,7 +1,7 @@ use std::env; -use tdameritradeclient::{param, Endpoint, TDAClient}; +use tdameritradeclient::{error::TDAClientError, param, Endpoint, TDAClient}; -fn main() { +fn main() -> Result<(), TDAClientError> { env_logger::init(); let c = TDAClient::new(env::var("TDAUTHTOKEN").unwrap()); title_print("History:"); @@ -13,7 +13,9 @@ fn main() { param::History::Frequency(1), param::History::FrequencyType("daily"), ], - )); + )?); + + Ok(()) } fn pretty_print(toprint: &serde_json::Value) { diff --git a/examples/optionchain.rs b/examples/optionchain.rs index 26eedb0..159b0f8 100644 --- a/examples/optionchain.rs +++ b/examples/optionchain.rs @@ -1,7 +1,7 @@ use std::env; -use tdameritradeclient::{param, Endpoint, TDAClient}; +use tdameritradeclient::{error::TDAClientError, param, Endpoint, TDAClient}; -fn main() { +fn main() -> Result<(), TDAClientError> { env_logger::init(); let c = TDAClient::new(env::var("TDAUTHTOKEN").unwrap()); @@ -14,7 +14,9 @@ fn main() { param::OptionChain::StrikeCount(3), param::OptionChain::ContractType("CALL"), ], - )); + )?); + + Ok(()) } fn pretty_print(toprint: &serde_json::Value) { diff --git a/examples/optionchainmodel.rs b/examples/optionchainmodel.rs index 93b6322..d333e44 100644 --- a/examples/optionchainmodel.rs +++ b/examples/optionchainmodel.rs @@ -1,9 +1,10 @@ use std::collections::HashMap; use std::env; +use tdameritradeclient::error::TDAClientError; use tdameritradeclient::model::optionchain::{OptionChain, OptionQuote}; use tdameritradeclient::{param, Endpoint, TDAClient}; -fn main() { +fn main() -> Result<(), TDAClientError> { env_logger::init(); // grab authorization token from an environmental variable @@ -12,19 +13,19 @@ fn main() { // get userprincipals endpoint and parse into userprincipals type title_print("Option Chain Quote for SPY:"); - let optionchain: OptionChain = - serde_json::from_value( - c.get( - &Endpoint::OptionChain, - &[ - param::OptionChain::Symbol("SPY"), - param::OptionChain::StrikeCount(1), - ], - ) - ).unwrap(); + let optionchain: OptionChain = serde_json::from_value(c.get( + &Endpoint::OptionChain, + &[ + param::OptionChain::Symbol("SPY"), + param::OptionChain::StrikeCount(1), + ], + )?)?; println!("Status: {}", &optionchain.status); - println!("Number of Contracts: {}\n", &optionchain.number_of_contracts); + println!( + "Number of Contracts: {}\n", + &optionchain.number_of_contracts + ); title_print("PUTS"); print_exp_date_map(&optionchain.put_exp_date_map); @@ -32,6 +33,7 @@ fn main() { title_print("CALLS"); print_exp_date_map(&optionchain.call_exp_date_map); + Ok(()) } fn title_print(heading: &str) { @@ -45,4 +47,4 @@ fn print_exp_date_map(exp_date_map: &HashMap Result<(), TDAClientError> { env_logger::init(); // grab authorization token from environmental variable @@ -12,7 +12,9 @@ fn main() { pretty_print(&c.get( &Endpoint::Quotes, &[param::Quotes::Symbol("F,SPY,INTC,IWM")], - )); + )?); + + Ok(()) } fn pretty_print(toprint: &serde_json::Value) { diff --git a/src/auth.rs b/src/auth.rs index dd1015f..efd7456 100644 --- a/src/auth.rs +++ b/src/auth.rs @@ -66,6 +66,8 @@ pub fn get_code_weblink(clientid: &str, redirecturi: &str) -> String { /// 2) `new_fromcode` will allow you to update tokens from the code retrieved in 1) /// 3) `new_fromrefresh` will allow you to update tokens from the `refresh_token`. The `refresh_token` will stay active for 90 days so you can save for reuse. /// +/// # Errors +/// Any Web issues will reset token and send default TDAUTH struct which will be empty #[derive(Debug, Clone, Default, Serialize)] pub struct TDauth { token: String, @@ -78,9 +80,8 @@ pub struct TDauth { } impl TDauth { - /// create new `TDauth` with configuration only - /// + /// pub fn new(refresh: String, client_id: String, redirect_uri: String) -> Self { let mut newauth = TDauth::default(); newauth.set_refresh(refresh); @@ -179,6 +180,7 @@ impl TDauth { self.auth_request(body, true); } + // if error in request just reset tokens fn auth_request(&mut self, body: Vec<(&str, &str)>, refresh_update: bool) { // any web issues let response = match request_auth(body) { @@ -264,7 +266,7 @@ impl TDauth { } fn set_refresh(&mut self, refresh: String) { - self.refresh = refresh.to_owned(); + self.refresh = refresh; } fn set_client_id(&mut self, client_id: String) { @@ -272,7 +274,7 @@ impl TDauth { } fn set_redirect_uri(&mut self, redirect_uri: String) { - self.redirect_uri = Some(redirect_uri.to_owned()); + self.redirect_uri = Some(redirect_uri); } pub fn log_change(&self, desc: &str) { @@ -284,15 +286,15 @@ impl TDauth { } pub fn web_link_authorization(&self) -> String { - get_code_weblink(&self.client_id, self.redirect_uri.as_ref().unwrap()) + get_code_weblink(&self.client_id, self.redirect_uri.as_ref().unwrap()) } } fn request_auth(body: Vec<(&str, &str)>) -> Result { - Ok(attohttpc::post(format!("{}oauth2/token", crate::APIWWW)) + attohttpc::post(format!("{}oauth2/token", crate::APIWWW)) .form(&body)? .send()? - .text()?) + .text() } #[cfg(test)] @@ -320,7 +322,7 @@ mod auth_tests { } #[test] - #[ignore] + #[ignore] fn check_new_fromrefresh_constructs_tdauth() { let refresh = env::var("TDREFRESHTOKEN").unwrap(); let clientid = env::var("TDCLIENTKEY").unwrap(); @@ -332,7 +334,7 @@ mod auth_tests { #[test] #[ignore] - fn check_existing_tdauth_fromrefresh_constructs_tdauth() { + fn check_existing_tdauth_fromrefresh_constructs_tdauth() { let mut auth = TDauth::default(); auth.set_client_id(env::var("TDCLIENTKEY").unwrap()); auth.set_refresh(env::var("TDREFRESHTOKEN").unwrap()); @@ -340,6 +342,5 @@ mod auth_tests { let (t, r) = auth.get_tokens(); println!("token: {} \nrefresh: {} \n", t, r); println!("{:?}", auth); - } - + } } diff --git a/src/authmanagedclient.rs b/src/authmanagedclient.rs index f1ca75e..fd031aa 100644 --- a/src/authmanagedclient.rs +++ b/src/authmanagedclient.rs @@ -76,7 +76,7 @@ impl TDAClientAuth { } /// check that an active refresh token exists so client tokens can be updated as needed - /// + /// /// if this is false then `TDauth` will have to be resolved by getting a refresh token /// probably using `tdauth_code_grant` pub fn refresh_auth_active(&self) -> bool { @@ -106,7 +106,8 @@ mod managed_client_tests { let resptxt: String = managed_client .client() .unwrap() - .get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,SPY")]); + .get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,SPY")]) + .unwrap(); assert_eq!(resptxt.contains("\"assetType\""), true); let (t1, r1, t2, r2): (String, String, String, String); @@ -122,7 +123,8 @@ mod managed_client_tests { let resptxt: String = managed_client .client() .unwrap() - .get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,SPY")]); + .get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,SPY")]) + .unwrap(); assert_eq!(resptxt.contains("\"assetType\""), true); { diff --git a/src/error.rs b/src/error.rs new file mode 100644 index 0000000..8535297 --- /dev/null +++ b/src/error.rs @@ -0,0 +1,32 @@ +use std::fmt; + +#[derive(Debug)] +pub enum TDAClientError { + /// Deals with connection io issues to the web API + WebConnectIssue(attohttpc::Error), + /// Any issues in parsing the response + ParseError(serde_json::Error), +} + +impl std::error::Error for TDAClientError {} + +impl fmt::Display for TDAClientError { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + match self { + TDAClientError::WebConnectIssue(e) => write!(f, "Web Connection Error: {}", e), + TDAClientError::ParseError(e) => write!(f, "Response Parsing Error: {}", e), + } + } +} + +impl From for TDAClientError { + fn from(e: serde_json::Error) -> Self { + TDAClientError::ParseError(e) + } +} + +impl From for TDAClientError { + fn from(e: attohttpc::Error) -> Self { + TDAClientError::WebConnectIssue(e) + } +} diff --git a/src/lib.rs b/src/lib.rs index 3caf584..5d7c5aa 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -55,7 +55,7 @@ //! let c = TDAClient::new(token); //! //! // get quotes for 3 symbols and execute -//! let resptxt: String = c.get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,TRP")]); +//! let resptxt: String = c.get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,INTC,TRP")]).unwrap(); //! //! // output will be text string in json format //! println!("{:?}", resptxt); @@ -66,6 +66,7 @@ static APIWWW: &str = "https://api.tdameritrade.com/v1/"; static APIKEY: &str = "@AMER.OAUTHAP"; const TOKENTIMEBUFFER: u64 = 25 * 60; // 25 Minutes instead of 30 min const REFRESHTIMEBUFFER: u64 = 60 * 24 * 60; // 60 days instead of 90 days +type Result = std::result::Result; /// /// utility module to help with authorization token, refresh token and grant code @@ -94,3 +95,6 @@ pub use authmanagedclient::TDAClientAuth; /// Used: `https://transform.tools/json-to-rust-serde` to help with struct generation /// pub mod model; + +/// Rolled up Errors for TDAClient +pub mod error; diff --git a/src/model/account.rs b/src/model/account.rs index 95bc496..1dcc5e2 100644 --- a/src/model/account.rs +++ b/src/model/account.rs @@ -3,7 +3,7 @@ use serde::{Deserialize, Serialize}; /// Holds account information that contains account information, balances, positions and orders /// as retrieved from get Accounts /// -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct AccountRoot { pub securities_account: SecuritiesAccount, @@ -12,7 +12,7 @@ pub struct AccountRoot { // TODO: Add the opportunity for either cash_account or margin_account. Currently only uses margin_account // Need to test cash account to see if it works -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct SecuritiesAccount { #[serde(rename = "type")] @@ -28,7 +28,7 @@ pub struct SecuritiesAccount { pub projected_balances: ProjectedBalances, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct Position { pub short_quantity: f64, @@ -46,7 +46,7 @@ pub struct Position { pub previous_session_short_quantity: Option, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct Instrument { pub asset_type: String, @@ -59,7 +59,7 @@ pub struct Instrument { pub type_field: Option, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct InitialBalances { pub accrued_interest: f64, @@ -108,7 +108,7 @@ pub struct InitialBalances { pub account_value: f64, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct CurrentBalances { pub accrued_interest: f64, @@ -149,7 +149,7 @@ pub struct CurrentBalances { pub bond_value: f64, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct ProjectedBalances { pub available_funds: f64, @@ -165,7 +165,7 @@ pub struct ProjectedBalances { pub stock_buying_power: f64, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct OrderStrategy { pub session: String, @@ -189,7 +189,7 @@ pub struct OrderStrategy { pub account_id: i64, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct OrderLegCollection { pub order_leg_type: String, diff --git a/src/model/mod.rs b/src/model/mod.rs index 437773e..e84e524 100644 --- a/src/model/mod.rs +++ b/src/model/mod.rs @@ -1,12 +1,24 @@ +use serde::{Deserialize, Deserializer}; +use serde_json::Value; + /// type to respresent responses from /accounts/ endpoint pub mod account; -/// type to represent token authorization response from /oauth2/token endpoint -pub mod token; -/// type to respresent responses from /userprincipals/ endpoint -pub mod userprincipals; +/// type to represent optionchains from /marketdata/chains +pub mod optionchain; /// type to represent price history from /marketdata/SYM/pricehistory pub mod pricehistory; /// type to represent quotes from /marketdata/quotes?SYM1,SYM2,etc pub mod quote; -/// type to represent optionchains from /marketdata/chains -pub mod optionchain; +/// type to represent token authorization response from /oauth2/token endpoint +pub mod token; +/// type to respresent responses from /userprincipals/ endpoint +pub mod userprincipals; + +fn ok_or_default<'a, T, D>(deserializer: D) -> Result +where + T: Deserialize<'a> + Default, + D: Deserializer<'a>, +{ + let v: Value = Deserialize::deserialize(deserializer)?; + Ok(T::deserialize(v).unwrap_or_default()) +} diff --git a/src/model/optionchain.rs b/src/model/optionchain.rs index 1c21b2a..034aeab 100644 --- a/src/model/optionchain.rs +++ b/src/model/optionchain.rs @@ -1,5 +1,6 @@ -use std::collections::HashMap; +use super::ok_or_default; use serde::Deserialize; +use std::collections::HashMap; /// OptionChain Model #[derive(Default, Debug, Clone, Deserialize)] @@ -7,21 +8,21 @@ use serde::Deserialize; pub struct OptionChain { pub symbol: String, pub status: String, -// pub underlying: String - ignore for now + // pub underlying: String - ignore for now pub strategy: String, pub interval: f64, pub is_delayed: bool, pub is_index: bool, pub interest_rate: f64, - #[serde(default)] + #[serde(deserialize_with = "ok_or_default")] pub underlying_price: f64, pub volatility: f64, -// pub days_to_expiration: i64 - not sure what this is at top level + // pub days_to_expiration: i64 - not sure what this is at top level pub number_of_contracts: i64, // format is HashMap< expiredate, HashMap< strike, [optionquote] > > - #[serde(default)] + #[serde(deserialize_with = "ok_or_default")] pub put_exp_date_map: HashMap>>, - #[serde(default)] + #[serde(deserialize_with = "ok_or_default")] pub call_exp_date_map: HashMap>>, } @@ -45,21 +46,29 @@ pub struct OptionQuote { pub open_price: f64, pub close_price: f64, pub total_volume: i64, -// pub trade_date: Value, + // pub trade_date: Value, pub trade_time_in_long: i64, pub quote_time_in_long: i64, pub net_change: f64, + #[serde(deserialize_with = "ok_or_default")] pub volatility: f64, + #[serde(deserialize_with = "ok_or_default")] pub delta: f64, + #[serde(deserialize_with = "ok_or_default")] pub gamma: f64, + #[serde(deserialize_with = "ok_or_default")] pub theta: f64, + #[serde(deserialize_with = "ok_or_default")] pub vega: f64, + #[serde(deserialize_with = "ok_or_default")] pub rho: f64, pub open_interest: i64, pub time_value: f64, + #[serde(deserialize_with = "ok_or_default")] pub theoretical_option_value: f64, + #[serde(deserialize_with = "ok_or_default")] pub theoretical_volatility: f64, -// pub option_deliverables_list: Value, + // pub option_deliverables_list: Value, pub strike_price: f64, pub expiration_date: i64, pub days_to_expiration: i64, @@ -68,7 +77,7 @@ pub struct OptionQuote { pub multiplier: f64, pub settlement_type: String, pub deliverable_note: String, -// pub is_index_option: Value, + // pub is_index_option: Value, pub percent_change: f64, pub mark_change: f64, pub mark_percent_change: f64, diff --git a/src/model/pricehistory.rs b/src/model/pricehistory.rs index 76e48ac..345aca8 100644 --- a/src/model/pricehistory.rs +++ b/src/model/pricehistory.rs @@ -23,4 +23,4 @@ impl History { pub fn get_close_series(&self) -> Vec { self.candles.iter().map(|candle| candle.close).collect() } -} \ No newline at end of file +} diff --git a/src/model/quote.rs b/src/model/quote.rs index 22ed61c..b8e612f 100644 --- a/src/model/quote.rs +++ b/src/model/quote.rs @@ -1,11 +1,11 @@ -use std::collections::HashMap; -use serde_json::Value; use serde::{Deserialize, Serialize}; +use serde_json::Value; +use std::collections::HashMap; /// /// Quote /// /// Deserialized through a HashMap -/// +/// #[derive(Debug, Serialize, Deserialize, Clone)] #[serde(rename_all = "camelCase", untagged)] pub enum Quote { @@ -19,7 +19,7 @@ pub enum Quote { #[derive(Debug, Serialize, Deserialize, Clone)] #[serde(rename_all = "camelCase")] pub struct QEquity { - pub asset_type: String, + pub asset_type: String, pub symbol: String, pub description: String, pub bid_price: f64, @@ -69,7 +69,7 @@ pub struct QEquity { #[derive(Debug, Serialize, Deserialize, Clone)] #[serde(rename_all = "camelCase")] pub struct QIndex { - pub asset_type: String, + pub asset_type: String, pub symbol: String, pub description: String, pub last_price: f64, @@ -91,12 +91,12 @@ pub struct QIndex { pub net_percent_change_in_double: f64, #[serde(flatten)] extra: HashMap, -} +} #[derive(Debug, Serialize, Deserialize, Clone)] #[serde(rename_all = "camelCase")] pub struct QOption { - pub asset_type: String, + pub asset_type: String, pub symbol: String, pub description: String, pub bid_price: f64, @@ -151,7 +151,7 @@ pub struct QOption { #[derive(Debug, Serialize, Deserialize, Clone)] #[serde(rename_all = "camelCase")] pub struct QFund { - pub asset_type: String, + pub asset_type: String, pub symbol: String, pub description: String, pub close_price: f64, @@ -181,13 +181,12 @@ pub struct QFund { #[derive(Debug, Serialize, Deserialize, Clone)] #[serde(rename_all = "camelCase")] pub struct QGeneral { - pub asset_type: String, + pub asset_type: String, pub symbol: String, #[serde(flatten)] extra: HashMap, } - impl Quote { pub fn symbol(&self) -> &str { match self { diff --git a/src/model/userprincipals.rs b/src/model/userprincipals.rs index 77e6f18..a8889b6 100644 --- a/src/model/userprincipals.rs +++ b/src/model/userprincipals.rs @@ -2,7 +2,7 @@ use serde::{Deserialize, Serialize}; /// /// Holds Type for UserPrincipals response /// -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct UserPrincipals { #[serde(skip)] @@ -24,7 +24,7 @@ pub struct UserPrincipals { pub accounts: Vec, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct StreamerInfo { pub streamer_binary_url: String, @@ -37,7 +37,7 @@ pub struct StreamerInfo { pub app_id: String, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct Quotes { pub is_nyse_delayed: bool, @@ -49,19 +49,19 @@ pub struct Quotes { pub is_forex_delayed: bool, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct StreamerSubscriptionKeys { pub keys: Vec, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct Key { pub key: String, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct Account { pub account_id: String, @@ -79,7 +79,7 @@ pub struct Account { pub authorizations: Authorizations, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct Preferences { pub express_trading: bool, @@ -98,7 +98,7 @@ pub struct Preferences { pub auth_token_timeout: String, } -#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize)] +#[derive(Default, Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct Authorizations { pub apex: bool, diff --git a/src/tdaclient.rs b/src/tdaclient.rs index e726fee..f068c0b 100644 --- a/src/tdaclient.rs +++ b/src/tdaclient.rs @@ -2,9 +2,11 @@ #![allow(clippy::must_use_candidate)] use crate::param::{convert_to_pairs, Pair}; use crate::request::Endpoint; +use crate::Result; use attohttpc::{RequestBuilder, Response, Session}; use log::info; use std::time::Duration; + /// /// Main client to access TD Ameritrade endpoints /// @@ -15,6 +17,11 @@ use std::time::Duration; /// 2) convert to `serde_json::Value` /// 3) use `serde_json::Value` output to parse into a response `model` type /// +/// # Error +/// +/// Any errors with request to API will be returned as `tdameritradeclient::Error::TDAClientError` +/// These errors will be issue with the connection or trouble parsing the output if using `serde_json` +/// #[derive(Debug, Default)] pub struct TDAClient { auth_token: String, @@ -55,7 +62,9 @@ impl TDAClient { /// /// See param for matching parameters /// - pub fn get<'a, P, T>(&self, ep: &Endpoint, params: P) -> T + /// # Errors + /// Will return either a web connection issue or a parse error + pub fn get<'a, P, T>(&self, ep: &Endpoint, params: P) -> Result where RequestBuilder: Execute, P: IntoIterator, @@ -71,9 +80,9 @@ impl TDAClient { /// post endpoint with json body /// /// # Errors - /// if nothing was returned than request was good, otherwise a json string will be returned indicating error + /// Will return either a web connection issue or a parse error /// - pub fn post<'a, T>(&self, ep: &Endpoint, body: &'a str) -> T + pub fn post<'a, T>(&self, ep: &Endpoint, body: &'a str) -> Result where // RequestBuilder: Execute, RequestBuilder>: Execute, @@ -88,9 +97,9 @@ impl TDAClient { /// put endpoint with json body /// /// # Errors - /// if nothing was returned than request was good, otherwise a json string will be returned indicating error + /// Will return either a web connection issue or a parse error /// - pub fn put<'a, T>(&self, ep: &Endpoint, body: &'a str) -> T + pub fn put<'a, T>(&self, ep: &Endpoint, body: &'a str) -> Result where // RequestBuilder: Execute, RequestBuilder>: Execute, @@ -105,9 +114,9 @@ impl TDAClient { /// patch endpoint with json body /// /// # Errors - /// if nothing was returned than request was good, otherwise a json string will be returned indicating error + /// Will return either a web connection issue or a parse error /// - pub fn patch<'a, T>(&self, ep: &Endpoint, body: &'a str) -> T + pub fn patch<'a, T>(&self, ep: &Endpoint, body: &'a str) -> Result where // RequestBuilder: Execute, RequestBuilder>: Execute, @@ -122,7 +131,10 @@ impl TDAClient { /// /// delete endpoint /// - pub fn delete(&self, ep: &Endpoint) -> T + /// # Errors + /// Will return either a web connection issue or a parse error + /// + pub fn delete(&self, ep: &Endpoint) -> Result where RequestBuilder: Execute, { @@ -137,37 +149,27 @@ impl TDAClient { /// 2) `serde_json::Value` - as a JSON object format /// pub trait Execute { - fn execute(self) -> T; + fn execute(self) -> Result; } impl Execute for RequestBuilder { - fn execute(self) -> String { + fn execute(self) -> Result { let response = preexecute(self); - response - .text() - .expect("Response did not return BODY: ERROR") + Ok(response.text()?) } } impl Execute for RequestBuilder> { - fn execute(self) -> String { + fn execute(self) -> Result { let response = preexecute_wbody(self); - response - .text() - .expect("Response did not return BODY: ERROR") + Ok(response.text()?) } } impl Execute for RequestBuilder { - fn execute(self) -> serde_json::Value { + fn execute(self) -> Result { let response = preexecute(self); - serde_json::from_str( - response - .text() - .expect("Response did not return JSON: ERROR") - .as_str(), - ) - .expect("SERDE: Trouble parsing json text: ERROR") + Ok(serde_json::from_str(response.text()?.as_str())?) } } diff --git a/tests/clienttests.rs b/tests/clienttests.rs index 0b2c4e2..9cd703c 100644 --- a/tests/clienttests.rs +++ b/tests/clienttests.rs @@ -4,11 +4,11 @@ // TODO: tests to add: watchlist endpoints -use std::env; use std::collections::HashMap; -use tdameritradeclient::model::quote::Quote; -use tdameritradeclient::model::pricehistory::History; +use std::env; use tdameritradeclient::model::account::AccountRoot; +use tdameritradeclient::model::pricehistory::History; +use tdameritradeclient::model::quote::Quote; use tdameritradeclient::model::userprincipals::UserPrincipals; use tdameritradeclient::{param, Endpoint, TDAClient}; @@ -18,7 +18,7 @@ fn initialize_client() -> TDAClient { fn initialize_client_accountid() -> (TDAClient, String) { let c = initialize_client(); - let user: serde_json::Value = c.get(&Endpoint::UserPrincipals, &[param::Empty]); + let user: serde_json::Value = c.get(&Endpoint::UserPrincipals, &[param::Empty]).unwrap(); let accountid = user["primaryAccountId"] .as_str() .expect("Trouble Parsing Primary AccountId") @@ -28,84 +28,112 @@ fn initialize_client_accountid() -> (TDAClient, String) { #[test] fn able_to_retrieve_userprincipals() { - let resptxt: String = initialize_client().get(&Endpoint::UserPrincipals, &[param::Empty]); + let resptxt: String = initialize_client() + .get(&Endpoint::UserPrincipals, &[param::Empty]) + .unwrap(); println!("{:?}", resptxt); assert_eq!(resptxt.contains("\"userId\""), true); } #[test] fn able_to_retrieve_userprincipals_into_model() { - assert!(serde_json::from_value::(initialize_client().get(&Endpoint::UserPrincipals, &[param::Empty])).is_ok()); + assert!(serde_json::from_value::( + initialize_client() + .get(&Endpoint::UserPrincipals, &[param::Empty]) + .unwrap() + ) + .is_ok()); } #[test] fn able_to_retrieve_quotes() { - let resptxt: String = - initialize_client().get(&Endpoint::Quotes, &[param::Quotes::Symbol("F,VFIAX,SPY,$SPX.X")]); - + let resptxt: String = initialize_client() + .get( + &Endpoint::Quotes, + &[param::Quotes::Symbol("F,VFIAX,SPY,$SPX.X")], + ) + .unwrap(); + println!("{:?}", resptxt); assert_eq!(resptxt.contains("\"assetType\""), true); } #[test] fn able_to_retrieve_quotes_into_model() { - let quote_symbols="F,VFIAX,SPY,$SPX.X"; - assert!(serde_json::from_value::>(initialize_client().get(&Endpoint::Quotes, &[param::Quotes::Symbol(quote_symbols)])).is_ok()); + let quote_symbols = "F,VFIAX,SPY,$SPX.X"; + assert!(serde_json::from_value::>( + initialize_client() + .get(&Endpoint::Quotes, &[param::Quotes::Symbol(quote_symbols)]) + .unwrap() + ) + .is_ok()); } #[test] fn able_to_retrieve_tojson() { - let resptxt: serde_json::Value = - initialize_client().get(&Endpoint::UserPrincipals, &[param::Empty]); + let resptxt: serde_json::Value = initialize_client() + .get(&Endpoint::UserPrincipals, &[param::Empty]) + .unwrap(); println!("{:?}", resptxt); assert!(resptxt["userId"].is_string()); } #[test] fn able_to_retrieve_history() { - let resptxt: String = initialize_client().get( - &Endpoint::History("SPY"), - &[ - param::History::Period(1), - param::History::PeriodType("month"), - param::History::Frequency(1), - param::History::FrequencyType("daily"), - ], - ); - println!("RESULT{:?}", resptxt); - assert_eq!(resptxt.contains("\"candles\""), true); -} - -#[test] -fn able_to_retrieve_pricehistory_into_model() { - assert!(serde_json::from_value::(initialize_client() - .get(&Endpoint::History("SPY"), + let resptxt: String = initialize_client() + .get( + &Endpoint::History("SPY"), &[ param::History::Period(1), param::History::PeriodType("month"), param::History::Frequency(1), param::History::FrequencyType("daily"), ], - )).is_ok()); + ) + .unwrap(); + println!("RESULT{:?}", resptxt); + assert_eq!(resptxt.contains("\"candles\""), true); +} + +#[test] +fn able_to_retrieve_pricehistory_into_model() { + assert!(serde_json::from_value::( + initialize_client() + .get( + &Endpoint::History("SPY"), + &[ + param::History::Period(1), + param::History::PeriodType("month"), + param::History::Frequency(1), + param::History::FrequencyType("daily"), + ], + ) + .unwrap() + ) + .is_ok()); } #[test] fn able_to_retrieve_optionchain() { - let resptxt: String = initialize_client().get( - &Endpoint::OptionChain, - &[ - param::OptionChain::Symbol("SPY"), - param::OptionChain::StrikeCount(3), - param::OptionChain::ContractType("CALL"), - ], - ); + let resptxt: String = initialize_client() + .get( + &Endpoint::OptionChain, + &[ + param::OptionChain::Symbol("SPY"), + param::OptionChain::StrikeCount(3), + param::OptionChain::ContractType("CALL"), + ], + ) + .unwrap(); println!("{:?}", resptxt); assert_eq!(resptxt.contains("\"SUCCESS\""), true); } #[test] fn able_to_retrieve_all_accounts() { - let resptxt: String = initialize_client().get(&Endpoint::Accounts, &[param::Empty]); + let resptxt: String = initialize_client() + .get(&Endpoint::Accounts, &[param::Empty]) + .unwrap(); println!("{:?}", resptxt); assert_eq!(resptxt.contains("\"securitiesAccount\""), true); } @@ -113,7 +141,9 @@ fn able_to_retrieve_all_accounts() { #[test] fn able_to_retrieve_one_account() { let (c, accountid) = initialize_client_accountid(); - let resptxt: String = c.get(&Endpoint::Account(&accountid), &[param::Empty]); + let resptxt: String = c + .get(&Endpoint::Account(&accountid), &[param::Empty]) + .unwrap(); println!("{:?}", resptxt); assert_eq!(resptxt.contains("\"securitiesAccount\""), true); } @@ -121,16 +151,29 @@ fn able_to_retrieve_one_account() { #[test] fn able_to_retrieve_account_into_model() { let (c, accountid) = initialize_client_accountid(); - assert!(serde_json::from_value::(c.get(&Endpoint::Account(&accountid), &[param::Empty])).is_ok()); - assert!(serde_json::from_value::(c.get(&Endpoint::Account(&accountid), &[param::Account::Positions])).is_ok()); - assert!(serde_json::from_value::(c.get(&Endpoint::Account(&accountid), &[param::Account::Orders])).is_ok()); + assert!(serde_json::from_value::( + c.get(&Endpoint::Account(&accountid), &[param::Empty]) + .unwrap() + ) + .is_ok()); + assert!(serde_json::from_value::( + c.get(&Endpoint::Account(&accountid), &[param::Account::Positions]) + .unwrap() + ) + .is_ok()); + assert!(serde_json::from_value::( + c.get(&Endpoint::Account(&accountid), &[param::Account::Orders]) + .unwrap() + ) + .is_ok()); } - #[test] fn able_to_retrieve_account_positions() { let (c, accountid) = initialize_client_accountid(); - let resptxt: String = c.get(&Endpoint::Account(&accountid), &[param::Account::Positions]); + let resptxt: String = c + .get(&Endpoint::Account(&accountid), &[param::Account::Positions]) + .unwrap(); println!("{:?}", resptxt); assert_eq!(resptxt.contains("\"positions\""), true); } @@ -138,7 +181,9 @@ fn able_to_retrieve_account_positions() { #[test] fn able_to_retrieve_transactions() { let (c, accountid) = initialize_client_accountid(); - let resptxt: String = c.get(&Endpoint::Transactions(&accountid), &[param::Empty]); + let resptxt: String = c + .get(&Endpoint::Transactions(&accountid), &[param::Empty]) + .unwrap(); println!("{:?}", resptxt); assert_eq!(resptxt.contains("\"transactionItem\""), true); } @@ -146,7 +191,9 @@ fn able_to_retrieve_transactions() { #[test] fn able_to_retrieve_instrument_cusip() { let c = initialize_client(); - let resptxt: String = c.get(&Endpoint::Instrument("458140100"), &[param::Empty]); + let resptxt: String = c + .get(&Endpoint::Instrument("458140100"), &[param::Empty]) + .unwrap(); println!("{:?}", resptxt); assert_eq!(resptxt.contains("\"cusip\""), true); } @@ -154,13 +201,15 @@ fn able_to_retrieve_instrument_cusip() { #[test] fn able_to_retrieve_instrument_search() { let c = initialize_client(); - let resptxt: String = c.get( - &Endpoint::Instruments, - &[ - param::Instruments::Symbol("INTC"), - param::Instruments::SearchType("fundamental"), - ], - ); + let resptxt: String = c + .get( + &Endpoint::Instruments, + &[ + param::Instruments::Symbol("INTC"), + param::Instruments::SearchType("fundamental"), + ], + ) + .unwrap(); println!("{:?}", resptxt); assert_eq!(resptxt.contains("\"cusip\""), true); }