“The first duty prescribed by God for His servants is the recognition of Him Who is the Dayspring of His Revelation and the Fountain of His laws, Who representeth the Godhead in both the Kingdom of His Cause and the world of creation. Whoso achieveth this duty hath attained unto all good; and whoso is deprived thereof hath gone astray, though he be the author of every righteous deed. It behoveth every one who reacheth this most sublime station, this summit of transcendent glory, to observe every ordinance of Him Who is the Desire of the world. These twin duties are inseparable. Neither is acceptable without the other. Thus hath it been decreed by Him Who is the Source of Divine inspiration.”
Bahá’u’lláh, The Kitáb-i-Aqdas, p. 19
The way I interpret that quote is that the first duty is the most important.
After the first duty comes the second duty, to observe every ordinance of Baha'u'llah. That it is unacceptable to do the first duty and not the second duty means we must follow His laws.
The person who follows His laws but is not a believer than Baha'u'llah has not done his first and most important duty.
I suppose it is better to follow His laws than to not do so, but it is not acceptable to only do that.
The quote below only refers to Baha'is, (the people of Baha, who are the inmates of the Ark of God). These are the people who have done the first duty. It is not about people who follow His laws but are not believers in Baha'u'llah.
"The people of Baha, who are the inmates of the Ark of God, are, one and all, well aware of one another's state and condition, and are united in the bonds of intimacy and fellowship. Such a state, however, must depend upon their
faith and their
conduct. They that are of the same grade and station are fully aware of one another's capacity, character, accomplishments and merits. They that are of a lower grade, however, are incapable of comprehending adequately the station, or of estimating the merits, of those that rank above them. Each shall receive his share from thy Lord."
(Baha'u'llah, Gleanings from the Writings of Baha'u'llah, p. 169)