Skip to content

Providers (International)

Get available countries, operators, and denominations for international top-up.

Endpoint: POST /providers

Get Countries

Request without parameters returns all available countries.

bash
curl -X POST https://api.paynet.one/providers \
  -H "Content-Type: application/json" \
  -d '{
    "auth": {
      "id": 123,
      "key": 1706360400000,
      "hash": "a1b2c3d4e5f6..."
    }
  }'
php
<?php
$response = apiRequest('/providers', []);
print_r($response);
javascript
const response = await api.post('/providers', { auth });
console.log(response.countries);
python
response = api.post('/providers', {'auth': auth_data})
print(response['countries'])

Response

json
{
  "countries": [
    {
      "id": "74",
      "name": "Pakistan",
      "phone_code": "+92"
    },
    {
      "id": "110",
      "name": "Uganda",
      "phone_code": "+256"
    },
    {
      "id": "17",
      "name": "Burundi",
      "phone_code": "+257"
    }
  ]
}

Get Operators by Country

Pass country_id to get operators in that country.

bash
curl -X POST https://api.paynet.one/providers \
  -H "Content-Type: application/json" \
  -d '{
    "auth": {
      "id": 123,
      "key": 1706360400001,
      "hash": "b2c3d4e5f6a1..."
    },
    "country_id": 74
  }'
javascript
const response = await api.post('/providers', {
  auth,
  country_id: 74
});
console.log(response.providers);

Response

json
{
  "country": {
    "id": "74",
    "name": "Pakistan"
  },
  "providers": [
    {
      "id": "46",
      "parent_id": 0,
      "name": "Ufone Pakistan",
      "logo": "https://bo.paynet.one/uploads/operator-logo/46.png",
      "is_pin_based": false
    },
    {
      "id": "47",
      "parent_id": 0,
      "name": "Jazz Pakistan",
      "logo": "https://bo.paynet.one/uploads/operator-logo/47.png",
      "is_pin_based": false
    }
  ]
}
FieldDescription
idOperator ID (use in next request)
parent_idParent operator (0 = root)
nameOperator name
logoOperator logo URL
is_pin_basedWhether this returns a PIN

Get Denominations by Operator

Pass provider_id to get available denominations.

bash
curl -X POST https://api.paynet.one/providers \
  -H "Content-Type: application/json" \
  -d '{
    "auth": {
      "id": 123,
      "key": 1706360400002,
      "hash": "c3d4e5f6a1b2..."
    },
    "provider_id": 46
  }'
javascript
const response = await api.post('/providers', {
  auth,
  provider_id: 46
});
console.log(response.amounts);

Response

json
{
  "country": {
    "id": "74",
    "name": "Pakistan"
  },
  "providers": [
    {
      "id": "46",
      "parent_id": 0,
      "name": "Ufone Pakistan"
    }
  ],
  "amounts": [
    {
      "type_id": 1,
      "amount": 100.00,
      "currency": "PKR",
      "sale_price": 5.00,
      "sale_currency": "AED",
      "price": 4.95,
      "price_currency": "AED"
    },
    {
      "type_id": 1,
      "amount": 500.00,
      "currency": "PKR",
      "sale_price": 25.00,
      "sale_currency": "AED",
      "price": 24.75,
      "price_currency": "AED"
    },
    {
      "type_id": 2,
      "amount": 1000.00,
      "currency": "PKR",
      "sale_price": 45.00,
      "sale_currency": "AED",
      "price": 44.55,
      "price_currency": "AED"
    }
  ]
}

Amount Fields

FieldDescription
type_idDenomination type (1=Mobile, 2=Data, etc.)
amountValue customer receives
currencyCustomer's currency
sale_priceSuggested retail price
sale_currencyYour currency
priceYour cost (with discount)
price_currencyYour currency

Denomination Types

type_idType
1Mobile
2Data / Bundle / Package

Next Step

After discovering available denominations, proceed to Check with the phone number.

Paynet API Documentation