AI-Powered Payment Integration for Senegalese Mobile Money Services
Deggo MCP is a Model Context Protocol server that enables AI applications to interact with Senegalese mobile money services through natural language. It provides secure integration with Orange Money, supporting real-time payments, balance queries, and transaction management with enterprise-grade security including RSA PIN encryption and OAuth 2.0 authentication.
git clone https://github.com/jmndao/deggo-mcp.git
cd deggo-mcp
npm install
npm run buildcp .env.example .envConfigure your Orange Money credentials:
ORANGE_API_KEY=221771234567
ORANGE_CLIENT_ID=your_client_id
ORANGE_CLIENT_SECRET=your_client_secret
ORANGE_PIN_CODE=your_4_digit_pin
ORANGE_ENVIRONMENT=sandboximport { Deggo } from "./dist/index.js";
const deggo = new Deggo();
// Send payment
await deggo.sendMoney({
provider: "orange",
amount: { value: 25000, currency: "XOF" },
recipient: { phoneNumber: "771234567" },
description: "Payment"
});
// Check balance
const balance = await deggo.checkBalance("orange");npx deggo-mcpAdd to claude_desktop_config.json:
{
"mcpServers": {
"deggo": {
"command": "node",
"args": ["/absolute/path/to/deggo-mcp/dist/server.js"],
"env": {
"ORANGE_API_KEY": "221771234567",
"ORANGE_CLIENT_ID": "your_client_id",
"ORANGE_CLIENT_SECRET": "your_client_secret",
"ORANGE_PIN_CODE": "your_pin",
"ORANGE_ENVIRONMENT": "sandbox"
}
}
}
}sendMoney(request)- Execute mobile money transferscheckBalance(provider)- Query account balancegetTransactionHistory(filter)- Retrieve transaction recordstestConnections()- Verify provider connectivity
send-payment- Process payment transactionscheck-balance- Get account informationtest-connections- Validate system status
- Orange Money - Full integration with Orange Sonatel API
- Wave - Planned implementation
Automatically handles Senegalese number formats:
- Local:
77 123 45 67 - International:
+221 77 123 45 67 - Full:
221771234567
Valid prefixes: 70, 75, 76, 77, 78
npm install
npm run build
npm test
npm run dev- Register at https://developer.orange-sonatel.com
- Complete KYC verification
- Obtain API credentials
- Configure sandbox environment
try {
await deggo.sendMoney(request);
} catch (error) {
console.error(`Transaction failed: ${error.message}`);
}Common error codes:
INSUFFICIENT_FUNDSINVALID_RECIPIENTTRANSACTION_LIMIT_EXCEEDED
MIT
See docs/new-provider-guide.md for provider implementation guidelines.