In pre-1947 'British India' there were a number of autonomous Princely States. Their rulers were protected by the British & in return they had to accept a British Resident at their Court.
The Resident & his staff were menbers of the Indian Political Service (IPS)
The IPS wre high up in the order of precedence - known as 'The Blue Book'
Your GG.Grandfather was a civilian in the top echelons of British Rule