Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Table of Contents
maxLevel2
Receiving Webhooks

...

MifosX will send along a few HTTP headers to differentiate between event types.

NameDescription
X-Mifos-EntityThe entity type that was triggered.
X-Mifos-ActionThe action triggered on the entity type.
X-Mifos-Platform-TenantId

The tenant which experienced the event.

...

See /hooks/template response (groupings array inside the json) or the m_permission table (other than special, read and checker permissions) to find a list of all available combinations of Entity and Action.

SMS Bridge Template

You need to clone https://github.com/mgeiss/mifos-twilio-bridge and do a gradlew bootRun to start the application which will act as a bridge between MifosX and Twilio.

So for the Sms Bridge template in the Create Hook form, you need to give http://localhost:9191/modules/sms as the payload url, type "twilio" as the sms provider (without the quotes) and fill the remaining 3 fields (Phone Number, SMS Provider Account Id, SMS Provider token) with the details you received when registering an account in Twilio.

WARNING : Do not create a SMS Bridge hook with your own mobile number if you have not registered for Twilio. This will cause a wrong api key to be generated by the bridge which will be stored in MifosX. To circumvent that, you will need to delete the hook in MifosX and manually generate a DELETE request to mifos-twilio-bridge to delete the api key since it won't allow multiple api keys per tenant.

WARNING : The only 2 events in Mifos X currently supported by the bridge application are CREATE CLIENT and REPAYMENT LOAN. The bridge application won't react to other events registered for the SMS Bridge Hook. As of now, it is only meant for demo purposes as specialists can implement their own preferred SMS service provider using the WEB template for hook.

List hooks

 https://demo.openmf.org/api-docs/apiLive.htm#configs_hooks_retrieve

...