Configuration
To configure Africell, please open the file custom/config/config_3rdparty.json
and copy the following code
"CONFIG_AFRICELL": {
"enabled": true,
"debug": false,
"check_ssl_certificate": false,
"processing_bank_prefix": "AFRICELL-",
"base_uri": "XXX",
"credentials": {
"auth_token": "XXX",
"bearerCode": "XX",
"currency": "101",
"languageId": "1",
"languageCode": "en",
"transactor": {
"idType": "mobileNumber",
"msisdn": "",
"productId": "12",
"mPin":"XXX"
}
},
"allowed_destination_countries": [
"SL"
],
"cron_frequency": "*/5 * * * *",
"max_export_attempts": 3
}
The values of the fields will be given by the client, but few fields will have values that should be standard (see the code above).
State Machine
The second step is to modify the file custom/config/config_state_machine.json
, or create it if it does not exist.
In this file search for the section modify_state_machine and comment out AFRICELL in the section BANKS_TO_HQOK.
"modify_state_machine": {
"BANKS_TO_HQOK": [
"AFRICELL-"
]
}
Entities and Cron Jobs
The next step is to create the entities that will be used by the integraion; to do it, just run the following command in the terminal:
php bin/integration africell:setup-entities
The last step is to configure the cron jobs that will export the transactions and check their status regularly; to do it, configure the cron frequency (see above), and run the following command in the terminal:
php libs/vendor/bin/crunz schedule:run
At this point the integration should be working correctly.