Inspiration
Emerging markets have a shortage of agro processing capacity. While developed economies can make dried mangos or tomato sauce when there is a bumper crop, emerging markets often don’t have the capacity to process locally and thus produce rots. This is because Agro processing requires factories and factories require capital. And capital typically runs at 15-30% interest in emerging markets.
Affordable loans can unlock the potential of more than 1 billion people.
Meanwhile, cryptocurrency holders are looking for yield, especially yield that is uncorrelated with the rest of the crypto market. Right now, in the bear market, yield is down.
Investing in emerging markets is a great way to get 10-30% yield on assets uncorrelated with the crypto-economy.
Prior Art inspiration: Goldfinch does something similar for Consumer Finance companies in emerging markets. Using the Eth network, Goldfinch provides USDC loans to consumer finance companies like JoyPay in Mexico to provide financing for phones, TVs, etc. Goldfinch has raised over $120m. FarmDAO is analogous to Goldfinch but for SME finance on the ICP blockchain.
One of our team members (Kyle Schutter) has raised millions of dollars for agri processors in Africa over the last 10 years as owner of the the company thegrant.co. He knows the challenges of raising capital for this market intimately.
What it does
With FarmDAO, Agro processors like tomato sauce canneries or sunflower oil producers can now access capital faster and at affordable rates. The loan can be collateralized by machinery, land, invoices, purchase orders or personal guarantee. In addition to collateral, borrowers have other incentives to repay: reputational risk, reporting to local credit bureaus and no longer being able to borrow on our FarmDAO platform. Lenders are split into two tranches: Senior Debt at ~8% interest which is repaid first and Junior Debt at ~18% interest which is repaid last. This blended financing enables higher yield for those willing to take more risk. The Junior Debt backers have to do their due diligence and vet the opportunity because their money is on the line. If the Junior Debt backers approve the loan, they will fund 20% of the loan as the first-loss money or junior debt. They are taking more risk so backers receive a higher interest rate–let’s say 18% Backer-approved loans are then available for Senior Debt to fund the remaining 80% of the loan. The Senior Debt will have a lower interest rate because they are taking less risk. The combined interest rate will be 10% which is a good deal in emerging markets.
Once installed, the factory produces shelf-stable agricultural products which are exported or consumed locally. With this new revenue stream, the factory can repay the loan and then Senior Debt and finally backers are repaid automatically through the smart contract. This is vastly better than the current situation where liquidity providers often have their repayment disbursements delayed by processing issues.
How we built it
The frontend was built with ReactJS. The smart contracts were programmed in Motoko. The backend API and database was built using NestJS and PostgreSQL, respectively. We used class-validator for API request validation and the application is hosted on Heroku.
Challenges we ran into
- no stablecoin on IC…yet! XTC is not quite a stablecoin as it is hard to go back and forth between ICP and XTC. So at this point loans can only be denominated in ICP.
- Connecting the front-end (react) with Motoko. Most documentation for Motoko/Javascript integrations is for Svelte, not React. However, the IC community was very helpful and helped us resolve the issues
- Differences in concept for ids and keys between internet computer and traditional blockchains
Accomplishments that we're proud of
- Building a simple yet fully running loan application on a blockchain we had not used before.
- Sticking together as a team even when the going got tough.
What we learned
- How to create canisters and have them communicate with each other (frontend canister and contract canister)
- How to make calls from the frontend canister using an Actor.
- We learned that ICP has a strong community of people willing to help and who want to see the protocol grow.
What's next for Decentralized SME lending
- Integration of frontend and backend
- User authentication Wallet Implementation Go deeper with the display of the loans (Junior/Senior Debt) Connect React and Motoko
- User/Borrower verification via certain required documents and collateral before a loan is created.
- Give junior debts the option to see list of loan requests and a link to each borrower's documents for verification before contributing to junior pool
- Set up our react frontend which is more detailed and has a better UI/UX than what we have now in Svelte.
- Only show certain buttons based on user's role (eg. borrowers would only be able to see the withdraw pool funds and check loan status buttons) and pool status (withdraw pool funds won't be clickable until pool status has been set to approved and senior pool has enough funds for the requested loan).
- Enable contributions to Junior pool to be withdrawable.
- Implement business logic based on points mentioned above in the api and database.
- A token to enable direct investment in our protocol.
Team
- Godswill (Nigeria) Backend development
- Kiko (Egypt) Smart contracts
- Elias (Canada) Frontend
- Chifunda (Zambia) Finance
- Kyle (Kenya/US) Product
Built With
- dfx
- heroku
- icp
- javascript
- motoko
- nestjs
- postgresql
- react


Log in or sign up for Devpost to join the conversation.