  Let $\mathbf{F}$ be a number field and $\mathfrak{q},\mathfrak{l}$ two
coprime integral ideals with $\mathfrak{q}$ squarefree and $\pi_1,\pi_2$ two
fixed unitary automorphic representations of
$\mathrm{PGL}_2(\mathbb{A}_{\mathbf{F}})$ unramified at all finite places. In
this paper, we use regularized integrals to obtain a formula that links the
first moment of $L(\pi\otimes\pi_1\otimes\pi_2,\tfrac{1}{2})$ twisted by the
Hecke eigenvalues $\lambda_\pi (\mathfrak{l})$, where $\pi$ runs through
unitary automorphic representations of
$\mathrm{PGL}_2(\mathbb{A}_{\mathbf{F}})$ with conductor dividing
$\mathfrak{q}$, with some spectral expansion of periods over representations of
conductor dividing $\mathfrak{l}$. In the special case where
$\pi_1=\pi_2=\sigma$, this formula becomes a reciprocity relation between
moments of $L$-functions. As applications, we obtain a subconvex estimate in
the level aspect for the central value of the triple product
$L(\pi\otimes\pi_1\otimes\pi_2,\tfrac{1}{2})$ and a simultaneous non-vanishing
result for $L(\mathrm{Sym}^2(\sigma)\otimes \pi,\tfrac{1}{2})$ and
$L(\pi,\tfrac{1}{2})$.
