SRINAGAR, Kashmir — Early this week, as the flooding in Kashmir was entering a new and terrifying phase, the Indian Army’s public information office received a call from Raheel Khursheed, a former journalist and digital obsessive who serves as the director of news, politics and government at Twitter India. He had a proposal.

Over the weekend, floodwaters had inundated ground-floor equipment rooms for most of the region’s telecommunications service providers, crashing cellphone networks across the state. Local officials had no way to contact the federal government, or one another, or the army, which had been mobilized as part of a rescue effort. Though the army has satellite phones, they were of little help without knowing where people were waiting for rescue.

There was one place where information was flowing at a nearly unmanageable volume, and that was on social media.

So many messages were surging into Twitter under the hashtag #KashmirFloods that on Tuesday Mr. Khursheed’s colleagues commissioned a piece of code that could winnow out those that identified stranded people. He then called the Indian Army — which has only two officers permanently assigned to monitor social-media postings — to offer the authorities a slimmed-down, organized feed that he described as “a continuously updating stream of ‘save me’s.’ ”