Inspiration

The freelance economy is booming, but it’s still plagued by age-old problems: delayed payments, lack of trust, and the constant need to chase invoices. We wanted to build a solution where freelancers could work with the certainty that their funds are already secured and will be released automatically as they work.

What it does

Massa Freelance is a decentralized application (dApp) that redefines the relationship between clients and freelancers.

  • Verified Proof of Funds: Clients lock funds into a smart contract before work begins.
  • Autonomous Payments: Leveraging Massa's unique Autonomous Smart Contracts, the system wakes itself up and executes payments automatically at set intervals (e.g., every hour or minute).
  • Total Flexibility: A clean, modern Next.js interface allows users to easily hire talent or start working without needing deep crypto knowledge.

How we built it

We built Massa Freelance using a robust modern stack:

  • Frontend: Next.js 15 with React 19 for a responsive and dynamic user experience.
  • Blockchain: We used @massalabs/massa-web3 to interact with the Massa blockchain and wrote our smart contracts in AssemblyScript.
  • Smart Contracts: The core is autonomous.ts, an active contract that self-schedules its execution using deferredCallRegister to create an infinite loop of on-chain payments.
  • Styling: Tailwind CSS with a custom design system focused on a fresh green palette (no standard crypto-purple!).
  • AI Assistance: We utilized a custom AI coding assistant steered by our .kiro configuration to maintain code quality and consistency.

Challenges we ran into

  • Autonomous Logic: Designing the self-scheduling mechanism for the smart contract was tricky. We had to ensure the contract always had enough gas and storage fees to schedule its next wake-up call, or the loop would break.
  • State Management: synchronizing the on-chain state (RUNNING vs STOPPED) with the frontend UI required careful handling of async operations and event listening.

Accomplishments that we're proud of

  • Successfully deploying a truly autonomous smart contract that runs without any off-chain keepers.
  • Creating a seamless "Web2-like" user experience where the complexity of the blockchain is abstracted away behind a beautiful UI.
  • Implementing a robust "Developer Guide" directly in our documentation to help others learn from our approach.

What we learned

We gained a deep appreciation for Massa's unique architecture. The ability for smart contracts to be active participants—waking themselves up and performing actions—opens up a whole new paradigm for dApps that isn't possible on other chains.

What's next for Massa Freelance

  • Dispute Resolution: Adding a mechanism for arbitration if work isn't delivered as expected.
  • Multi-token Support: Allowing payments in stablecoins and other tokens.
  • Reputation System: Building an on-chain reputation score for freelancers and clients based on successful contract completions.

Built With

  • massa
Share this project:

Updates