So salvation is by works?
You have to keep doing enough works to stay in.
And if you don't do the works, then you're out?
Good works are product of salvation, not the means of salvation. Paul and James are not in opposition; they are back-to-back defending against legalism and antinomianism.
No, as in conversion, you only have to believe, which effects obedience, including repentance when convicted when not doing so. But the effects of faith are not what appropriates justification, though works justify one as being a believer. (Heb. 6:9) Faith - as enabled and motivated by God - appropriated justification, thus if one denies the faith just as surely as once embraced it then he forfeits what he appropriated. Which means resisting God who works to effect repentance, lest we be condemned with the rest of the world. (1Co. 11:32)