Escrow stateless smart contract

Can anyone please help to understand how to add conditions for Escrow account in stateless smart contracts.

Hey isha,

Could you be more specific?

Smart Contracts are written in TEAL (Transaction Execution Approval Language).

There are several examples of stateless smart contracts available to help you learn more here.

Some good ones for getting started in Python are:

  1. Hash Time Lock Contract
  2. Periodic Payment
1 Like

Okay so for example,
If I want to transfer ASA in exchange of algos using an escrow account.
So here my condition is once the receiver receives ASA only then algos from escrow account should be transferred(released) to the ASA sender.

This is exactly what the limit order contract does.

To see how it does it, see - Algorand Developer Portal

To see how to use it: LimitOrder Contract with JavaScript | Algorand Developer Portal

(you can search for similar tutorials in Python, Java, Go)

I would strongly recommend to read the introduction to smart contracts first:

The smart contract above is “stateless”.

1 Like

If you have any example of stateless smart contract related to escrow account please send me.

Okay great I’ll try working on this.
Thanks a lot!