UPDATE 1-Demand for Fed's year-end repo offering falls short of supply for first time

(Adds market details and analyst view)

Dec 19 (Reuters) - Wall Street firms might be close to building up all of the cash they will need to get them through the end of the year, based on the weaker demand for cash injections from the Federal Reserve.

The New York Fed on Thursday accepted all $31.269 billion in bids from primary dealers at a 14-day repurchase agreement (repo) operation - which fell short of the $35 billion offered to dealers.

It was the first time that demand for longer-term repo offerings from the Fed, which are meant to provide funding through the end of the year, were short of supply. All other repo offerings that mature in January have been oversubscribed since the Fed began offering them in late November - including some where demand was nearly twice as much as supply.

Some analysts say it is a potential sign that firms have tapped all the liquidity they will need to get through the next couple of weeks. But it is too soon to know if banks left money on the table because they do not need the cash or because they are approaching key limits on their balance sheet.

There could still be more stress in the repo market in the final days of the year, when large banks are expected to cut back on repo lending to shrink their balance sheets and avoid higher capital surcharges.

For more details on the Fed's offering, see: here

Reporting by Karen Brettell in New York Additional reporting by Jonnelle Marte Editing by John Stonestreet and Matthew Lewis