# Setting DAI as the receivable token in a crowdsale contract

**URL:** <https://forum.openzeppelin.com/t/setting-dai-as-the-receivable-token-in-a-crowdsale-contract/2066>\
**Category:** Contracts\
**Tags:** erc777, crowdsale\
**Created:** [January 10, 2020, 2:54pm UTC](https://forum.openzeppelin.com/t/setting-dai-as-the-receivable-token-in-a-crowdsale-contract/2066 "2020-01-10T14:54:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Yorkemartin](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/yorkemartin/32/17622_2.png) [@Yorkemartin](https://forum.openzeppelin.com/u/Yorkemartin)\
**Post date:** [January 10, 2020, 2:54pm UTC](https://forum.openzeppelin.com/t/setting-dai-as-the-receivable-token-in-a-crowdsale-contract/2066/1 "2020-01-10T14:54:49Z")

</div>

Hi all -

I’m trying to build a crowdsale contract that will hopefully function similar to kickstarter / indiegogo / etc, but more like a micro-loan that can be paid back by the recipient. The goal is to use it for fundraising for creative projects like publishing a book or recording an album.

My initial thought is to make a crowdsale contract that can be paid in DAI, then the contributor can be rewarded with an erc777, which they could trade back at the end of the project for the return of their investment (dai).

Is this way of thinking viable? Can I set the rate for a crowdsale in DAI, or would I have to integrate Airswap or something other thing to quickly change from eth to dai after its contributed?

---

<div class="post-metadata">

**Author:** ![abcoathup](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/abcoathup/32/415_2.png) [@abcoathup](https://forum.openzeppelin.com/u/abcoathup)\
**Post date:** [January 12, 2020, 11:38pm UTC](https://forum.openzeppelin.com/t/setting-dai-as-the-receivable-token-in-a-crowdsale-contract/2066/2 "2020-01-12T23:38:08Z")

</div>

Hi @Yorkemartin,

Welcome to the community 👋.

I suggest you have appropriate advice on any regulatory requirements for such a scheme.

The OpenZeppelin Contracts [Crowdsales](https://docs.openzeppelin.com/contracts/2.x/crowdsales) accept Ether and issue ERC20 tokens. Though you may be able to adapt the crowdsale to use a stable token as payment instead of Ether. Issuing an ERC777 token should be fine as it can be ERC20 compatible. If adapting [Crowdsale](https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/crowdsale/Crowdsale.sol) isn’t suitable, then you would likely be creating something similar.

Any such solution should be appropriately tested and audited ([OpenZeppelin performs security audits](https://openzeppelin.com/security-audits/))

---

<div class="post-metadata">

**Author:** ![abcoathup](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/abcoathup/32/415_2.png) [@abcoathup](https://forum.openzeppelin.com/u/abcoathup)\
**Post date:** [January 20, 2020, 3:45am UTC](https://forum.openzeppelin.com/t/setting-dai-as-the-receivable-token-in-a-crowdsale-contract/2066/3 "2020-01-20T03:45:26Z")

</div>

Hi @Yorkemartin,

How did you get on with this? Let me know if you have any more questions.
