  In a combined theoretical and experimental work, we investigate X-ray
Absorption Near-Edge Structure (XANES) spectroscopy of the I $L_3$ and the Pb
$M_5$ edges of the methylammonium lead iodide ($\textrm{MAPbI}_3$) hybrid
inorganic-organic perovskite and its binary phase $\textrm{PbI}_2$. The
absorption onsets are dominated by bound excitons with sizable binding energies
of a few hundred meV and pronounced anisotropy. The spectra of both materials
exhibit remarkable similarities, suggesting that the fingerprints of core
excitations in $\textrm{MAPbI}_3$ are essentially given by its inorganic
component, with negligible influence from the organic groups. The theoretical
analysis complementing experimental observations provides the conceptual
insights required for a full characterization of this complex material.
