Developer Reference · East Africa

The Nairobi
Stack

The coordination infrastructure stack for East Africa. Reference for building on Kenya's financial, civic, health, and agricultural systems — 130+ open-source tools, 23 MCP servers, 4 Swahili NLP datasets. MCP servers, APIs, open-source tools, NLP datasets — everything you need to ship.

M-PESA · Daraja API USSD · Africa's Talking MCP · A2A · ADK KRA eTims NHIF / SHA Swahili NLP KHIS / DHIS2 eCitizen API Kenya Legal Corpus
130+
Open Source Tools
12
MCP Servers
4
HF Datasets
3
AI Protocols
47M
Swahili Speakers
Model Context Protocol

MCP Servers — 30 Live

Plug East Africa's digital infrastructure directly into Claude, GPT-4, Gemini, or Kimi Agent Swarm. No custom API code. All on PyPI. All MIT licensed. 30 servers covering the full coordination stack — the tool layer for AI agent swarms operating in East Africa.

M-PESA Daraja API as MCP tools — STK push, B2C payments, balance queries, transaction status, C2B registration. First African mobile money MCP. 7 tools.
pip install mpesa-mcp MIT 1,200+ downloads
Alternative credit scoring — 300–850 score from M-PESA behavioral signals, no formal credit history required. Loan eligibility and improvement paths. 5 tools.
pip install mkopo-mcp MIT
Insurance intelligence — NHIF coverage, parametric crop risk scoring (NDMA/ACRE methodology), microinsurance comparison, community risk pool sizing. 6 tools.
pip install bima-mcp MIT
Commodity price intelligence — regional price comparison across East Africa, trend analysis, sell/hold decision support for farmers. Closes information asymmetry. 5 tools.
pip install soko-mcp MIT
Reputation and trust scoring for informal economy participants — chamas, boda riders, kiosk owners. Portable trust layer without formal credit bureaus. 5 tools.
pip install sifa-mcp MIT
Remittance guidance and comparison — corridor rates, KYC requirements, recipient options, and diaspora investment pathways from abroad. 5 tools.
pip install remit-mcp MIT
Kenya Revenue Authority tax compliance — PAYE calculator, VAT guide, PIN registration, withholding tax rates, investment incentives. 1st world: TurboTax/HMRC. 6 tools.
pip install kra-mcp MIT
Kenya capital markets — Treasury bond calculator, NSE equities guide, unit trust comparison, diaspora investment, IPO participation. 1st world: Fidelity/Schwab. 6 tools.
pip install faida-mcp MIT
Kenya drought and water access — NDMA drought phase monitoring, borehole registry, water point distances, county water coverage. 6 tools.
pip install wapimaji-mcp MIT
Kenya energy access — KPLC connection guidance, electricity tariff calculator, off-grid solar options, rural electrification programs, consumer rights. 5 tools.
pip install nishati-mcp MIT
Kenya transport and logistics — matatu route finder, NTSA services guide, boda licensing, freight logistics options, passenger rights. 5 tools.
pip install usafiri-mcp MIT
Kenya land administration — title search guidance, land rates, subdivision process, dispute resolution pathways (NLC/ELC), land rights. 5 tools.
pip install ardhi-mcp MIT
Kenya health system navigation — NHIF/SHA coverage queries, facility finder, CHW services, maternal health milestones, essential medicines. 6 tools.
pip install afya-mcp MIT
Kenya mental health resources — therapist finder, crisis lines (Befrienders Kenya 0800 723 253), teletherapy, workplace wellness, rights under Mental Health Act 2022. 5 tools.
pip install afya-ya-akili-mcp MIT
Kenya education system — school registry, KCSE/KCPE results guidance, HELB student loans, TVET programs, adult literacy resources. 5 tools.
pip install elimu-mcp MIT
Kenya labor market — employment rights, informal sector guidance, gig economy protection, job search resources, NSSF/NHIF worker rights. 5 tools.
pip install kazi-mcp MIT
Kenya labour rights — minimum wages, unfair dismissal guidance, maternity/paternity rights, trade union directory, Labour Relations Court. 1st world: ACAS/NLRB. 5 tools.
pip install haki-ya-kazi-mcp MIT
Kenya precision agriculture — crop calendar, fertilizer recommendations, pest/disease alerts, market timing, KALRO varieties, input cost calculator. 1st world: Climate Corp. 6 tools.
pip install kilimo-mcp MIT
Kenya community finance — SACCO finder, chama formation guide, cooperative benefits, SACCO loan types and rates, cooperative member rights. 5 tools.
pip install jumuia-mcp MIT
Kenya housing — rental market guide, tenant rights, building permit process, affordable housing programs (Boma Yangu), housing finance and mortgages. 5 tools.
pip install nyumba-mcp MIT
Kenya civic information — Kenya Gazette search, government tender finder, open data sources, parliament tracker, official citizen feedback channels. 5 tools.
pip install habari-mcp MIT
Kenya environment — NEMA permit guidance, climate data sources, conservation areas, environmental rights under Constitution Art. 42, climate adaptation. 5 tools.
pip install mazingira-mcp MIT
Unified Kenya civic AI SDK — agent builder, compliance tools, NHIF/KRA/NTSA integrations, Swahili locale support. Underlying SDK for the full stack. 8 tools.
pip install civic-agent-kit MIT
Public APIs & Data

Kenya API Reference

Every public API and data source you need, with endpoint references and usage notes.

M-PESA Daraja API
Safaricom · OAuth 2.0
Core Kenya payment infrastructure. STK push, C2B, B2C, account balance, transaction status. 35M+ registered users. Sandbox available at no cost.
https://sandbox.safaricom.co.ke/oauth/v1/generate
Africa's Talking SMS/USSD
Africa's Talking · API Key
SMS delivery to 300+ carriers, USSD session management, voice calls, airtime topup. Essential for reaching feature-phone users. Kenya, Uganda, Tanzania, Nigeria.
https://api.africastalking.com/version1/messaging
KRA eTims API
Kenya Revenue Authority · PIN Auth
Electronic Tax Invoice Management System. Invoice submission, VSCU integration, trader details lookup. Required for VAT-registered businesses as of 2024.
https://etims.kra.go.ke/etims-api
Kenya KHIS / DHIS2
Ministry of Health · Public
Kenya Health Information System — 8,700+ health facilities, disease surveillance, maternal health indicators, immunization coverage. Full DHIS2 analytics API.
https://hiskenya.org/api/analytics
Kenya Open Data
Government of Kenya · Open
Datasets across agriculture, health, education, census, budget allocations. County-level data via devolution. Updated quarterly.
https://opendata.go.ke/api/views
Kenya Meteorological Dept
KMD · Request Access
Weather forecasts, rainfall data, climate normals. Essential for agricultural AI, flood monitoring, and energy applications. County-level granularity.
https://api.meteo.go.ke/v1/forecast
Complete Tool Directory

130+ Deployed Tools

Every tool is open-source, tested, and deployable today. All Streamlit apps run on the free tier.

M-PESA transaction intelligence, fraud signals, paybill lookup
StreamlitGemini
Kenya business formalization: KRA, permits, NHIF, NSSF step-by-step
StreamlitSwahili
NSE, SACCOs, Treasury bonds — wealth building education in Swahili
StreamlitNSE
Medicine info, drug interactions, generic alternatives in Swahili
KMPDBSafety
Crop disease diagnosis, market prices, weather — for 8M+ farmers
KALROWFP
Constitution, Employment Act, Land Act RAG in English/Swahili
RAGMCP
Upload any Kenya gov document → plain Swahili explanation
VisionPDF
County budget tracker — allocation vs spending with AI analysis
Transparency
KCSE curriculum tutoring in Swahili for 4M+ secondary students
KNECEducation
Swahili ↔ English, Kikuyu, Dholuo, Kamba — domain-aware translation
NLP6 langs
Mental health support, counseling resources, crisis line integration
Crisis: 0800 723 253
Youth employment: CV builder, interview prep, gig economy guide
FuzuBM
Informal sector AI — KIE registration, NITA certification, cooperatives
KIE3M workers
Import/export: KRA customs duty, EAC trade, KEBS standards
KRACOMESA
UNHCR registration, refugee rights, humanitarian services Kenya
UNHCR560k refugees
Emergency response, disaster preparedness, first aid — NDMA data
NDMARedCross
CLI registry for all Kenya MCP servers — pip install & connect in one command
CLIRegistry
Building blocks for civic AI agents — data connectors, prompt templates, evaluation
AgentsLlamaIndex

Browse all 130+ repositories on GitHub

HuggingFace Datasets

Swahili NLP Datasets

Open training data for East African language AI. All datasets are CC BY 4.0.

gmahia · CC BY 4.0 · Swahili/English
Annotated Swahili civic sentences covering government services, constitutional rights, M-PESA financial terms, and county administration. The foundational dataset for Kenya civic AI.
gmahia · CC BY 4.0 · English/Swahili
Kenya county government data, budget allocations, public service metrics. Structured for NLP tasks: NER, relation extraction, and question answering on civic content.
gmahia · CC BY 4.0 · Swahili/English
Q&A pairs for Kenya agricultural advisory — crop diseases (MSV, FAW), market prices, planting calendars, livestock health. Grounded in KALRO/KEPHIS data.
gmahia · CC BY 4.0 · Swahili/English
Annotated Kenya legal documents (Constitution, Employment Act, Land Act) with NER labels (PERSON, ORG, LAW, DATE) and QA pairs for legal information retrieval tasks.
Get Building

Quickstart

From zero to a working East African AI application in under 10 minutes.

1
Install mpesa-mcp
The fastest way to start building on Kenya's financial infrastructure.
pip install mpesa-mcp
claude mcp add mpesa -- mpesa-mcp
2
Configure Daraja credentials
Get a free Safaricom Daraja sandbox account at developer.safaricom.co.ke. No real money required.
# Environment variables
export MPESA_CONSUMER_KEY="your_key"
export MPESA_CONSUMER_SECRET="your_secret"
export MPESA_SHORTCODE="174379" # sandbox
export MPESA_ENV="sandbox"
3
Or clone a complete app
Pick any domain and deploy a working app today. All apps work on Streamlit Cloud free tier.
# Example: Kenya farmer advisory
git clone https://github.com/gabrielmahia/shamba-ai
cd shamba-ai
pip install -r requirements.txt
# Add GOOGLE_API_KEY to .streamlit/secrets.toml
streamlit run app.py
4
Contribute or extend
Every tool is MIT (infrastructure) or CC BY-NC-ND (apps). Build on top, open issues, or reach out to collaborate on the LINGUA Africa grant work.
# Hub CLI to explore all MCP servers
pip install kenya-mcp-hub
kenya-mcp-hub list
Family infrastructure — inheritance, wills, trusts, diaspora property, caretaker records. 1st world: LegalZoom / Trust & Will. 6 tools.
pip install familia-mcpMIT
Full diaspora lifecycle — immigration, dual citizenship, cross-border taxes, homeland investment, community resources. 6 tools.
pip install diaspora-mcpMIT
Translation infrastructure — Swahili/English glossary, Kikuyu guide, Luo guide, official document terms. Thesis Layer 5. 6 tools.
pip install tafsiri-mcpMIT
Local AI inference — Ollama wrapper, open weights directory, degraded-mode guide. Runs on Raspberry Pi + 50W solar. Thesis Layer 4. 6 tools.
pip install offline-mcpMIT
Kenya historical archives — timeline 3000BCE→2022, independence leaders, heritage sites, ethnic groups, oral history. Thesis Layer 1. 6 tools.
pip install historia-mcpMIT
Kenya 47 counties — demographics, budgets, devolution services, CDF, ward information, contacts. Thesis Layer 9. 6 tools.
pip install county-mcpMIT
Community and religious infrastructure — Catholic dioceses, Protestant denominations, Muslim guide, welfare services, legal registration. 6 tools.
pip install church-mcpMIT