Getting the tick size via API (TD Ameritrade)

Discussion in 'Automated Trading' started by earth_imperator, Jan 19, 2023.

  1. Anybody know which TD Ameritrade API function to call to get the tick size for an options or equity symbol?
    Ie. the smallest price increment in which the prices are quoted.

    And related: what is the practical definition of the "pennyPilot" data field (having a boolean value of true or false),
    as returned when calling the "Get Option Chain" API function ( https://apiforums.tdameritrade.com/option-chains/apis/get/marketdata/chains )?
    Does "pennyPilot":true mean "tick size $0.01" ?
     
  2. The API Support of TDA has just replied by saying that "Currently there is not a return for tick size." :-(
    I wonder how one can effectively automate w/o knowing the tick size, especially with options...
     
  3. spy

    spy

    I would imagine it does. Last time I looked at the TD Api I wasn't particularly impressed and so I'm not surprised when you say:

    For practical purposes though, I suppose you could assume the options you trade are priced in pennies and then, if your order is rejected, change the tick size in your system to a nickle.

    Not pretty, but it might get the job done. That's what I do and my broker actually provides the info... but it's a well known fact that I'm a slacker.
     
  4. Which API do you use?

    Yeah, makes sense.
    I'm now using the following for setting the ticksize for a symbol/ticker:
    Code:
      tick_size = !fOption    ?        (Last < 1.0 ? 0.0001 : 0.01) :    // stocks
                  fPennyPilot ? 0.01 : (Last < 3.0 ? 0.05   : 0.10);     // options
    
    then use "round_to_ticksize(LastPrice, fUp)" where fUp is true or false.
     
  5. spy

    spy

    IB