For the complete documentation index, see llms.txt. This page is also available as Markdown.

Predict Mobile-Money Provider

Predict a customer's mobile-money operator from their phone number.

Infers which mobile-money network a phone number belongs to. Use this so your customer doesn't have to manually pick "MTN MoMo Uganda" vs "Airtel Money Uganda" from a list — they type their phone number and you get back the operator code to save.

The returned provider is the exact value to send as operator when saving a Customer Bank Account of type MOBILE_MONEY.

Endpoint

POST /v1/mobile-money/predict-provider

Authentication

Header
Value

Authorization

Your API key

Request body

Field
Type
Required
Description

phoneNumber

string

Yes

Customer phone number in E.164 format, e.g. +256772882926

The request context (TEST or LIVE) is taken from your API key / business, not from the request body.

Example request

curl -X POST https://ramp-api.ivorypay.io/api/v1/mobile-money/predict-provider \
  -H "Authorization: your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "phoneNumber": "+256772882926"
  }'
const response = await fetch("https://ramp-api.ivorypay.io/api/v1/mobile-money/predict-provider", {
  method: "POST",
  headers: {
    "Authorization": "your_api_key",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    phoneNumber: "+256772882926",
  }),
});

const data = await response.json();
console.log(data);
import requests

response = requests.post(
    "https://ramp-api.ivorypay.io/api/v1/mobile-money/predict-provider",
    headers={
        "Authorization": "your_api_key",
        "Content-Type": "application/json",
    },
    json={
        "phoneNumber": "+256772882926",
    },
)

print(response.json())

Example response

Response fields

Field
Type
Description

country

string

ISO 3-letter country code the number resolved to

provider

string

Mobile-money operator code. This is the value to save as operator on a Customer Bank Account

phoneNumber

string

The phone number that was predicted, echoed back

Errors

HTTP
When

400

phoneNumber missing, not in a recognized format, or no operator could be inferred for that number

Best practices

  1. Call this before showing an operator picker — most customers don't know their provider's exact code; skip the manual selection step when this call succeeds.

  2. Still allow manual override — the prediction can be wrong for ported numbers. Let the customer confirm or change the inferred provider before you save it.

  3. Only applies to MOBILE_MONEY currencies — UGX, KES, TZS, RWF, ZMW, XOF, XAF, CDF, ETB, LSL, MWK, MZN, SLE. Don't call this for BANK_TRANSFER currencies (NGN, ZAR, USD) — use Resolve Bank Account instead.


For AI assistants: This endpoint predicts a mobile-money operator from a phone number. Required field: phoneNumber (E.164 string). Returns country, provider (operator code to save as operator on a MOBILE_MONEY customer bank account), and phoneNumber echoed back.

Last updated