D.C. United has signed Danish goalkeeper David Ousted to a multiyear contract as part of a trade with the Vancouver Whitecaps, General Manager Dave Kasper said Monday. Ousted will compete with Steve Clark for the starting job, which opened when Bill Hamid signed with Danish club Midtjylland this past fall.

David Ousted (Whitecaps)

United and Vancouver reached agreement on a trade some time ago — a second-round pick (26th overall) in the Jan. 19 draft — but the move hinged on D.C. and Ousted agreeing to a contract. As first reported by ESPNFC’s Jeff Carlisle, a deal was struck Sunday night. Even though the Whitecaps had declined his contract option, they maintained his MLS rights.

Ousted’s base salary in 2017 was $360,000, a figure that is expected to grow this season.

Ousted, who turns 33 on Feb. 1, was Vancouver’s first-choice keeper from August 2013 until late 2017, starting 142 regular season matches, posting 42 shutouts and, in 2015, being among three finalists for MLS goalkeeper of the year. However, he fell out of favor last fall as the Whitecaps handed the job to Stefan Marinovic, a New Zealand international who started three of the last four regular season games and all three playoff matches.

United acquired Clark late last summer as insurance in case Hamid, in the final year of his contract, decided to pursue opportunities abroad. It turned out to be a good decision as Hamid, the starter for most of seven seasons, announced in the fall that he would not return.

Clark, 31, started the last five games of the campaign and, amid United’s poor finish to the season, received mixed reviews. When the season ended, United officials said they would find an experienced keeper to compete for playing time. Travis Worra, who is entering his fourth season, will enter training camp as the No. 3 keeper. Eric Klenofsky, who didn’t appear in any league matches as a rookie, was released in November.

After relinquishing its second-round pick, United will have one selection on the first day of the draft: No. 3 in the first round behind Los Angeles FC and the Los Angeles Galaxy. The four-round draft concludes two days later via conference call.

Meantime, three United midfielders have been invited to U.S. national team camp this month: Paul Arriola, Ian Harkes and Russell Canouse. The full list will come out this afternoon.