Originally posted by @quackquack to Uzless
It is 100% discretionary. A country has the absolute right to deny admission to non-citizens.
Not everyone who seeks entry into a foreign country is an 'immigrant', some are classified as 'refugees'.
Under international law and conventions, refugees have some rights, including asylum.
"Article 14(1) of the Universal Declaration of Human Rights (UDHR), which was
adopted in 1948, guarantees the right to seek and enjoy asylum in other countries.
Subsequent regional human rights instruments have elaborated on this right,
guaranteeing the “right to seek and be granted asylum in a foreign territory, in
accordance with the legislation of the state and international conventions.'"
Universal Declaration of Human Rights
(1) Everyone has the right to seek and to enjoy in other countries asylum from persecution.
(2) This right may not be invoked in the case of prosecutions genuinely arising from
non-political crimes or from acts contrary to the purposes and principles of the United Nations."