Hi KQ and welcome to this forum.
Yes this is definitely an Accepted Action situation, so please review TDA Rule 46.
Generally speaking Player A is obligated to wager the full 40k AND A can win the full 40k.
If the TD considers the situation too egregious (i.e. too wide a spread between the declared and actual amount), per Rule 46 the TD can make an adjustment to the amount of A's obligation using Rule 1.