British India has a consulate in Kashgar and so did the Russians!
As Russia further advanced into Central Asia within the immediate proximity of Pamirs, the limits of Xinjiang on both sides of Kashmir and Russian frontier became increasingly important to British India. With the intention of counterbalancing Russian influence and to persuade the Chinese to push their outposts in the Pamir further west, the British Government sent a number of missions to the area to make contact with the local government. In 1874, an Anglo-Kashgarian commercial treaty was signed; it granted the British the freedom to trade with low duties in the region. In 1885, a second mission headed by Ney Elias, an official of the Foreign Department of the Government of India, went to Kashgar to negotiate a trade agreement with the Chinese Government. From 1890, the Government of India appointed an official resident to be stationed at Kashgar. Col Francis Younghusband was the first British Resident in Kashgar, and from 1891 George Macartney (no relation to the first Ambassador to China in 1793) replaced Younghusband and stayed there until his retirement at the end of the First World War.
British Residents at Kashgar: Younghusband (centre right) and Macartney (first left), 1891. [Mss Eur F197/674(1)] © The British Library Board
One of the most important duties of the British Political Resident at Kashgar was to send periodic news reports or fortnightly diaries, channelled through the Government of India, to London. The contents of these reports and diaries range from the Resident's daily dealings with the locals to political uprisings in the region. In the countries surrounding India's frontiers, there was little secret intelligence of a direct military kind to be acquired. What the British Government needed to know was mainly political - Russian movement in the region, local events, which tribes might be plotting to overthrow some ruler and what might be the effect on the border tribes.
The Political Resident at Kashgar, George Macartney, who was fully bilingual, managed to establish an amicable rapport with Chinese Taotai (a provincial administrator) as well as with the Russian Consul at Kashgar. Through his local contacts, he was well informed of political shifts and likely repercussions within or beyond the borders. In general, it could be said that, like every British Political Agent of that period, Macartney ran a local information or intelligence service, which Russians might have called a spy network, but it tended to be a very informal and parochial affair.
After Macartney's retirement, every two or three years a colleague of the Political Agent at Kashmir would arrive at Kashgar from Srinagar in Gilgit, to assume the post of Consul General, or return to Srinagar from Kashgar after leaving this post. Their job was to ensure that the Chinese kept a sufficiently clear sovereignty, to preclude Russian infiltration in this region. This was the main British objective.
Following the outbreak of the Chinese Revolution of 1911, Xinjiang experienced a period of chaos as the change of government took place. It was again affected by the Bolshevik Revolution in 1917, when it looked as though many of the Russian Asiatic possessions would pass out of the control of Moscow. During this period, many parts of Central Asia were rife with Pan-Islamic movements coinciding with nationalistic sentiments. The Government of British India observed with keen interest the internal turmoil of the Central Asian republics. However, Xinjiang remains on the Chinese map to the present day.
http://www.bl.uk/reshelp/findhelpregion/asia/china/guidesources/britishactivities/index.html