According to the APA manual it is best to "cite secondary sources sparingly--for instance, when the original work is out of print, unavailable, or available only in a language that you do not understand. If possible, as a matter of good scholarly practice, find the primary source, read it, and cite it directly rather than citing a secondary source” (American Psychological Association [APA], 2020, p. 258).
In your in-text citation identify the primary source, and include in parentheses "(as cited in Author, Date)". The reference list will only list the secondary source. In the examples below, Smith's study is the primary source and Queenan et al. is the secondary ("as cited in") source.