# Root criterion for polynomial over number fields

It's well known that if $\alpha$ is a rational root to an integer coefficient polynomial, then its denominator divides the leading coefficient and its numerator divides the constant term. I'm asking if there is an analog if the coefficients of the polynomial live in a number field and I'm looking for solutions in that number field, which doesn't necessarily have unique factorization. I'm asking if there is a criterion that reduces the problem to a finite amount of checking just like the integral case.

Let $f(x) = a_nx^n+\cdots+a_0$ be a polynomial with coefficients in the ring of integers $\mathcal{O}_K$ of a number field $K$. Then for every nonzero root $\alpha$ of $f$ in $K$ one has $a_n \alpha, \frac{a_0}{\alpha} \in \mathcal{O}_K$. This can be seen by the simple observation that $a_n \alpha$ and $\frac{a_0}{\alpha}$ are roots of the monic polynomials
$$x^n+a_{n-1}x^{n-1}+a_{n}a_{n-2}x^{n-2}+\cdots+a_{n}^{n-1}a_0,\\ x^n + a_1 x^{n-1}+ a_0 a_2 x^{n-2}+\cdots+a_0^{n-1}a_n,$$ and $\mathcal{O}_K$ is integrally closed. These conditions impose bounds on the valuations of $\alpha$ but in the cases that $K$ has infinitely many units, these conditions doesn't restrict to only finite number of candidates.
Write $\alpha=a/b$. The ideal $(a)/(a,b)$ divides the last term and $(b)/(a,b)$ divides the first. To prove this, plug in $a/b$ and clear denominators. Each term is in the ideal generated by the other terms. Divide both sides by $(a,b)^n$ and apply unique factorization of prime ideals.
There are finitely many possible ideals dividing the first and last coefficients. Given a pair in the same ideal class, that determines $a/b$ up to a unit. However there may be infinitely many units. To deal with thus, you can give an upper bound on the norm of $\alpha$ at each place, reducing it to a finite check.