From f88a7c59b899cac452c081c2cf6e7e9bfd38285b Mon Sep 17 00:00:00 2001 From: Will Ruddick Date: Mon, 18 May 2020 13:40:59 +0000 Subject: [PATCH] Add new file --- spec/sepc/007_eMoney_integration.md | 36 +++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 spec/sepc/007_eMoney_integration.md diff --git a/spec/sepc/007_eMoney_integration.md b/spec/sepc/007_eMoney_integration.md new file mode 100644 index 0000000..469eec1 --- /dev/null +++ b/spec/sepc/007_eMoney_integration.md @@ -0,0 +1,36 @@ +## Incoming Sarafu ## +When chama (group accounts) exchange Sarafu each month for National Currency we have to manually send them Mpesa. +We would like to automate this. + +## Outgoing Sarafu ## +When anyone sends us Mpesa on our paybill we have to manuall send them Sarafu + +## Solution ## +Configure - using our own system AfricasTalking API to automatically send Sarafu / Mpesa based on rules: + +### Incoming Sarafu Rules ### + - *white list* The chama (group accounts only) must only be able to cash out - using the exchange option to an Agent account + - *amount* The max cash out is the minimum of (30,000 Sarafu, half their balance, their total amount of outward trade volume to other users (standard transactions) + - *time* They can only cash out once per month + - *rate* The Sarafu to Mpesa rate should be a config variable set to 1.0 -> a 0% cash out fee. i.e. For 100 Sarafu you get 100 Mpesa. This rate will vary manual based on promotion periods and available Mpesa + + +### Outgoing Sarafu Rules ### + - *white list* Only users sending via paybill receive Sarafu. Non users receive a invitation to join Sarafu sms + - *amount* The max sarafu out is 20,000 Sarafu per user + - *time* No limit + - *rate* The Mpesa to Sarafu rate should be a config variable set to 1.2 -> a 20% cash in bonus. i.e. For 100 Mpesa you get 120 Sarafu. This rate will vary manual based on promotion periods and available Sarafu + + +### Security ### + - Balance alerts: The paybill from which Sarafu is sent needs to send a sms and email alert when low + - Failure alerts: If the API session fails an sms and email alert should be sent + - Reject on not enough Mpesa balance: If there is not enough Mpesa (on incoming Sarafu) the transaction should be rejected and an email sent to admin along with a SMS to admin and user (Sarafu should not be taken from user). (message should be visible also on mgmt platform txn view and user view and admin view). + - Reject on not enough Sarafu balance: If there is not enough Sarafu (on incoming Mpesa) the transaction should be rejected and an email sent to admin along with a SMS to admin and user (Mpesa should not be taken from user). (message should be visible also on mgmt platform txn view and user view and admin view). + +### Variables ### + - The account from which Sarafu is sent should be a Agent account + - The cash-out rules for a chama (minimum and time limit) + - Alert balance levels + - Rate: Mpesa to Sarafu + - Rate: Sarafu to Mpesa \ No newline at end of file