2 For [gar] if [ei] Abraham [Abraam] were
justified [dikaioo] by [ek] works [ergon], he hath [echo] whereof to glory [kauchema];
but [alla] not [ou] before [pros] God [theos].KJV-Interlinear
2 For if
Abraham was justified by works, he has something to boast about, but not before
Paul quickly points out that Abraham was not justified by works, and the scriptures do not say anywhere, that works were any part of his justification. Quite the contrary, works are rejected and dismissed as the basis for anything except boasting before people.
When someone works and accomplishes something, then they have a sound basis for bragging or boasting or announcing their accomplishment.
This is normal and typical.
When we graduate from school, we announce it. When we begin a career, we announce it. When we get married, we announce it. When we have a child, we announce it. When we accomplish something, we announce it.
These things are normal and proper because we have actually done something.
But when God does something and we do nothing, then we have no right to claim credit for that which God has done. And in the spiritual life, God has and does, everything. We do nothing.
We receive the benefit of Gods effort as a gift. A gift that is neither earned nor deserved.
When we work we receive a paycheck. When we achieve something we receive an award.
But these things are not gifts, but compensation of recognition for effort.
Grace is a gift which can never be earned.
So rather than earning salvation through work, Abraham recognized the salvation that he has already received, through a work, namely circumcision, which was a ritual reminder of faith, not the source of faith.