Let $P(X,Y)\in \mathbf Z[X,Y]$ be an irreducible polynomial and let $A$ denote the quotient ring $\mathbf Z[X,Y]/(P)$.
What is known about the group of units of $A$? It's not even clear to me that why it is a finitely generated group. If so, can we say something about its rank?
This question is motivated by Dedekind's theorem, stating that with one variable less, the group of units of $\mathbf Z[X]/(P(X))$ is finitely generated and expressing its rank in terms of the number of real and complex embeddings.