  Gamma rays are produced by cosmic ray (CR) protons interacting with the
particles at solar
  photosphere and by cosmic ray electrons and positrons (CRes) via inverse
Compton scattering of
  solar photons. The former come from the solar disk while the latter extend
beyond the disk.
  Evaluation of these emissions requires the flux and spectrum of CRs in the
vicinity of the Sun,
  while most observations provide flux and spectra near the Earth, at around 1
AU from the Sun. Past
  estimates of the quiet Sun gamma-ray emission use phenomenological modulation
procedures to estimate
  spectra near the Sun (see review by Orlando and Strong 2021 and references
therein). We show that CRe transport in the inner heliosphere requires a
kinetic approach and use a novel approximation to determine the variation of
CRe flux and spectrum from 1 AU to the Sun including effects of (1) the
structure of
  large scale magnetic field, (2) small scale turbulence in the solar wind from
several in situ measurements, in particular, those by Parker Solar Probe that
extend this information to 0.1 AU, and (3) most importantly, energy losses due
to synchrotron and inverse Compton processes. We present results on the flux
and spectrum variation of CRes from 1 AU to the Sun for several transport
models. In forthcoming
  papers we will use these results for a more accurate estimate of quiet Sun
inverse Compton gamma-ray spectra,
  and, for the first time, the spectrum of extreme ultraviolet to hard X-ray
photons produced by
  synchrotron emission. These can be compared with the quiet Sun gamma-ray
observation by Fermi (see, e.g.~Fermi-LAT Collaboration, 2011) and X-ray upper
limits set by RHESSI (Hannah et al., 2010).
