In April 1787, Wilkinson made a highly controversial trip to
New Orleans, which was the capital of
Spanish colonial Louisiana.: 80  At that time, Americans were allowed to trade on the
Mississippi River, but they had to pay a hefty
tariff. Wilkinson met with Spanish Governor
Esteban RodrĂguez MirĂł and managed to convince him to allow Kentucky to have a trading monopoly on the River; in return he promised to promote Spanish interests in the west. On August 22, 1787, Wilkinson signed an expatriation declaration and swore allegiance to the King of Spain to satisfy his own commercial needs.: 86  The "Spanish Conspiracy", as it is known, was initiated by Wilkinson's "First Memorial", a 7,500-word report written before he left New Orleans for
Charleston, to the Spanish concerning the "political future of western settlers" and to convince Spain to "admit us [Kentuckians] under protection as vassals".: 85  This was encoded with myriad symbols, numbers, and letters that was decoded via a complex English-Spanish cipher code-named "Number 13", which became the basis for his pseudonym, "Agent 13".: 88  Wilkinson's involvement with the Spanish (as Agent 13) was widely suspected in his own day, and it was proved in 1854, with Louisiana historian
Charles Gayarré's publication of the American general's correspondence with
Esteban RodrĂguez MirĂł,
Louisiana's colonial governor between 1785 and 1791.