A deflected Trevor Sinclair free-kick on 73 minutes was enough to hand victory to the visitors in this pre-season friendly at Richmond Park yesterday.
It was the home side who created the opening the chance with Jamie Harris latching onto a cross from Paul Byrne with quarter of an hour gone but Steven Bywater proved alert to the danger.
The game continued to present chances to both sides and St Patrick's were unlucky not to have taken the lead midway through the second-half when Barry Prenderville struck the crossbar from outside the box.
St Patrick's Athletic: Kelly; Burke, S McGuinness, Foley, Doyle; Byrne, Russell, Prenderville, Drew; Quinn, Harris. Subs: Hallowes for Quinn (46 mins), Croly for Burke and Garret for Drew (53 mins), McCarthy for Harris (78 mins), McNevin for Doyle (84 mins), R McGuinness for Byrne (61 mins), Harte for Russell and Kelly for Hallowes (84 mins), Morgan for Prendervile and Purcell for McGuinness (89 mins).
West Ham United: Bywater; Jorge, Fox, Ferdinand, Charles, Cole, Carrick, Lampard, Keller; Kanoute, Sinclair. Subs: Bernado for Jorge; Ruddock for Ferdinand and Winterburn for Keller (half-time), Invincible for Kanoute and Newton for Charles (65 mins), O Reilly for Bywater (70 mins).
Refereee: H Byrne (Dublin).
Other results: Galway United 0, Bristol Rovers 1; Glentoran 3, Shelbourne 3; Derry City 0, Partick Thistle 0; Bohemians 1, Tranmere Rovers 3.