Home
Solutions
Pricing
Developers
Blog
Company
+91 91610 19161 WhatsApp
Create account Login
  1. Home
  2. Blog
  3. Guides

Why you should detect the operator on every recharge

GuidesPublished Updated 5 min read
Cards showing a number that was Airtel and is now Jio, with Operator Fetch always current

The first digits of a mobile number no longer tell you the operator. Mobile number portability (MNP) lets customers keep their number and move to another operator, and millions have. A table that maps number series to operators was a fair shortcut years ago. Today it quietly sends recharges to the wrong place.

What goes wrong with prefix tables

  • The customer ported from Airtel to Jio last month. Your table says Airtel.
  • You show Airtel plans. The customer recharges with an Airtel amount that the real operator does not recognise.
  • The recharge fails or, worse, lands as unused talk time. Support gets a call, and you may owe a refund.

Prefix tables also say nothing about the circle, and plan prices differ between circles.

Ask the source instead

Operator & Circle Fetch takes the 10-digit number and returns where it is now:

GET /planapi/operatorCircleFetch?username=YOUR_ID&pwd=YOUR_PWD&mobileno=9876543210

{ "ERROR": "0", "Operator": "AIRTEL", "OpCode": "A", "Circle": "Andhra Pradesh", "CircleCode": "49" }

Use OpCode and CircleCode for everything that follows, from Plan Fetch to R-Offer Check. The operator and circle codes guide explains the values.

Let the customer correct you

No lookup is perfect forever. Show the detected operator with a small "Not right? Change" link. If the customer changes it, trust them, and still use the operator they chose for the recharge itself.

Caching without regret

ScenarioSuggested behaviour
Same customer, same sessionReuse the result
Returning customer next dayLook it up again, or reuse only if it is recent
A recharge just failedDrop the cached operator and look it up again
Saved numbers listStore the number, not the operator

That last row catches many teams: store the customer's saved numbers, but resolve the operator at the moment of use.

The cost is small

One lookup is one hit against your daily limit. Compared with a failed recharge and a support ticket, that is cheap. If you want to trim hits, cache for the session as above rather than for months. More on that in caching and daily limits.

See the endpoint in the documentation or follow the quickstart to run it yourself.

Frequently asked questions

Can I guess the operator from the first digits?

Not reliably. Because customers can port their number to another operator, the starting digits only show where the number was first issued.

How long can I cache the detected operator?

Keep it short, for example for the length of a session or up to a day, and drop it immediately after a failed recharge.

Which A1 Plan API endpoint detects the operator?

Operator & Circle Fetch. Send the 10-digit number and read OpCode and CircleCode from the response.

Ready to build?

Create an account, pick a plan and make your first call today. Every plan includes every endpoint.

Create account Read the docs

Keep reading