pyteal
Algorand Smart Contracts in Python
File Explorer
Download Latest Version (.zip)- bug_report.md
- feature_request.md
- build.yml
- nightly.yml
- abi.rst
- accessing_transaction_field.rst
- api.rst
- arithmetic_expression.rst
- assets.rst
- byte_expression.rst
- compiler_optimization.rst
- conf.py
- control_structures.rst
- crypto.rst
- data_type.rst
- examples.rst
- index.rst
- installation.rst
- loading_group_transaction.rst
- make.bat
- Makefile
- opup.rst
- overview.rst
- pyteal.png
- pyteal.svg
- README.md
- requirements.txt
- scratch.rst
- sourcemap.rst
- state.rst
- versions.rst
- __init__.py
- algobank.json
- algobank.py
- algobank_approval.teal
- algobank_clear_state.teal
- sourcemap.teal
- sourcemap_annotated.teal
- __init__.py
- asset.py
- opup.py
- security_token.py
- sourcemap.py
- vote.py
- vote_deploy.py
- __init__.py
- atomic_swap.py
- atomic_swap.teal
- basic.py
- basic.teal
- dutch_auction.py
- dutch_auction.teal
- dutch_auction_annotated.teal
- factorizer_game.py
- periodic_payment.py
- periodic_payment.teal
- periodic_payment_deploy.py
- recurring_swap.py
- recurring_swap.teal
- recurring_swap_deploy.py
- split.py
- split.teal
- __init__.py
- __init__.py
- __init__.py
- address.py
- address_test.py
- array_base.py
- array_base_test.py
- array_dynamic.py
- array_dynamic_test.py
- array_static.py
- array_static_test.py
- bool.py
- bool_test.py
- method_return.py
- method_return_test.py
- reference_type.py
- reference_type_test.py
- string.py
- string_test.py
- transaction.py
- transaction_test.py
- tuple.py
- tuple_test.py
- type.py
- type_test.py
- uint.py
- uint_test.py
- util.py
- util_test.py
- __init__.py
- abstractvar.py
- acct.py
- acct_test.py
- addr.py
- addr_test.py
- app.py
- app_test.py
- arg.py
- arg_test.py
- array.py
- assert_.py
- assert_test.py
- asset.py
- asset_test.py
- base64decode.py
- base64decode_test.py
- binaryexpr.py
- binaryexpr_test.py
- block.py
- block_test.py
- box.py
- box_test.py
- break_.py
- break_test.py
- bytes.py
- bytes_test.py
- comment.py
- comment_test.py
- cond.py
- cond_test.py
- continue_.py
- continue_test.py
- ec.py
- ec_test.py
- ecdsa.py
- ecdsa_test.py
- err.py
- err_test.py
- expr.py
- for_.py
- for_test.py
- frame.py
- frame_test.py
- gaid.py
- gaid_test.py
- gitxn.py
- gitxn_test.py
- gload.py
- gload_test.py
- global_.py
- global_test.py
- gtxn.py
- gtxn_test.py
- if_.py
- if_test.py
- int.py
- int_test.py
- itxn.py
- itxn_test.py
- jsonref.py
- jsonref_test.py
- leafexpr.py
- maybe.py
- maybe_test.py
- methodsig.py
- methodsig_test.py
- mimc.py
- mimc_test.py
- multi.py
- multi_test.py
- naryexpr.py
- naryexpr_test.py
- nonce.py
- nonce_test.py
- opup.py
- opup_test.py
- pragma.py
- pragma_test.py
- replace.py
- replace_test.py
- return_.py
- return_test.py
- router.py
- router_test.py
- scratch.py
- scratch_test.py
- scratchvar.py
- scratchvar_test.py
- seq.py
- seq_test.py
- stake.py
- stake_test.py
- subroutine.py
- subroutine_test.py
- substring.py
- substring_test.py
- ternaryexpr.py
- ternaryexpr_test.py
- tmpl.py
- tmpl_test.py
- txn.py
- txn_test.py
- unaryexpr.py
- unaryexpr_test.py
- voter.py
- voter_test.py
- vrfverify.py
- vrfverify_test.py
- while_.py
- while_test.py
- widemath.py
- __init__.py
- optimizer.py
- optimizer_test.py
- __init__.py
- compiler.py
- compiler_test.py
- constants.py
- constants_test.py
- flatten.py
- flatten_test.py
- scratchslots.py
- scratchslots_test.py
- sort.py
- sort_test.py
- sourcemap.py
- subroutines.py
- subroutines_test.py
- __init__.py
- labelref.py
- ops.py
- tealblock.py
- tealblock_test.py
- tealcomponent.py
- tealcomponent_test.py
- tealconditionalblock.py
- tealconditionalblock_test.py
- teallabel.py
- tealop.py
- tealpragma.py
- tealpragma_test.py
- tealsimpleblock.py
- tealsimpleblock_test.py
- __init__.py
- pragma.py
- pragma_test.py
- __init__.py
- __init__.pyi
- config.py
- errors.py
- py.typed
- stack_frame.py
- stack_frame_test.py
- types.py
- types_test.py
- util.py
- generate_init.py
- AlgoBank_h0_c0.tealf
- AlgoBank_h0_c1.tealf
- AlgoBank_h1_c0.tealf
- AlgoBank_h1_c1.tealf
- app_roundtrip_((uint64,byte[],uint64[1]))_v6.teal
- app_roundtrip_((uint64,byte[],uint64[1]))_v8.teal
- app_roundtrip_()_v6.teal
- app_roundtrip_()_v8.teal
- app_roundtrip_(bool)[10]_v6.teal
- app_roundtrip_(bool)[10]_v8.teal
- app_roundtrip_(bool)_v6.teal
- app_roundtrip_(bool)_v8.teal
- app_roundtrip_(bool,address,(uint64,bool),byte[10],bool[4],uint64)_v6.teal
- app_roundtrip_(bool,address,(uint64,bool),byte[10],bool[4],uint64)_v8.teal
- app_roundtrip_(bool,byte)_v6.teal
- app_roundtrip_(bool,byte)_v8.teal
- app_roundtrip_(bool,byte,address,string)_v6.teal
- app_roundtrip_(bool,byte,address,string)_v8.teal
- app_roundtrip_(bool,byte,address,string,(address,(uint32,string[],bool[2],(byte),uint8)[2],string,bool[]))[]_2_v6.teal
- app_roundtrip_(bool,byte,address,string,(address,(uint32,string[],bool[2],(byte),uint8)[2],string,bool[]))[]_2_v8.teal
- app_roundtrip_(bool,byte,address,string,uint64)_v6.teal
- app_roundtrip_(bool,byte,address,string,uint64)_v8.teal
- app_roundtrip_(bool,uint64,uint32)_v6.teal
- app_roundtrip_(bool,uint64,uint32)_v8.teal
- app_roundtrip_(byte)_v6.teal
- app_roundtrip_(byte)_v8.teal
- app_roundtrip_(byte,bool,uint64)_v6.teal
- app_roundtrip_(byte,bool,uint64)_v8.teal
- app_roundtrip_(byte[4],(bool,bool),uint64,address)[]_7_v6.teal
- app_roundtrip_(byte[4],(bool,bool),uint64,address)[]_7_v8.teal
- app_roundtrip_(byte[],byte[3])_v6.teal
- app_roundtrip_(byte[],byte[3])_v8.teal
- app_roundtrip_(uint16)_v6.teal
- app_roundtrip_(uint16)_v8.teal
- app_roundtrip_(uint16,uint8,byte)_v6.teal
- app_roundtrip_(uint16,uint8,byte)_v8.teal
- app_roundtrip_(uint32)_v6.teal
- app_roundtrip_(uint32)_v8.teal
- app_roundtrip_(uint32,uint16,uint8)_v6.teal
- app_roundtrip_(uint32,uint16,uint8)_v8.teal
- app_roundtrip_(uint64)_v6.teal
- app_roundtrip_(uint64)_v8.teal
- app_roundtrip_(uint64,uint32,uint16)_v6.teal
- app_roundtrip_(uint64,uint32,uint16)_v8.teal
- app_roundtrip_(uint8)_v6.teal
- app_roundtrip_(uint8)_v8.teal
- app_roundtrip_(uint8,byte,bool)_v6.teal
- app_roundtrip_(uint8,byte,bool)_v8.teal
- app_roundtrip_address[]_10_v6.teal
- app_roundtrip_address[]_10_v8.teal
- app_roundtrip_address_v6.teal
- app_roundtrip_address_v8.teal
- app_roundtrip_bool[1]_v6.teal
- app_roundtrip_bool[1]_v8.teal
- app_roundtrip_bool[3][]_11_v6.teal
- app_roundtrip_bool[3][]_11_v8.teal
- app_roundtrip_bool[42]_v6.teal
- app_roundtrip_bool[42]_v8.teal
- app_roundtrip_bool[]_0_v6.teal
- app_roundtrip_bool[]_0_v8.teal
- app_roundtrip_bool[]_1_v6.teal
- app_roundtrip_bool[]_1_v8.teal
- app_roundtrip_bool[]_42_v6.teal
- app_roundtrip_bool[]_42_v8.teal
- app_roundtrip_bool_v6.teal
- app_roundtrip_bool_v8.teal
- app_roundtrip_byte[16]_v6.teal
- app_roundtrip_byte[16]_v8.teal
- app_roundtrip_byte[]_36_v6.teal
- app_roundtrip_byte[]_36_v8.teal
- app_roundtrip_byte_v6.teal
- app_roundtrip_byte_v8.teal
- app_roundtrip_string_0_v6.teal
- app_roundtrip_string_0_v8.teal
- app_roundtrip_string_13_v6.teal
- app_roundtrip_string_13_v8.teal
- app_roundtrip_string_1_v6.teal
- app_roundtrip_string_1_v8.teal
- app_roundtrip_uint16_v6.teal
- app_roundtrip_uint16_v8.teal
- app_roundtrip_uint32_v6.teal
- app_roundtrip_uint32_v8.teal
- app_roundtrip_uint64[1]_v6.teal
- app_roundtrip_uint64[1]_v8.teal
- app_roundtrip_uint64[42]_v6.teal
- app_roundtrip_uint64[42]_v8.teal
- app_roundtrip_uint64[]_0_v6.teal
- app_roundtrip_uint64[]_0_v8.teal
- app_roundtrip_uint64[]_1_v6.teal
- app_roundtrip_uint64[]_1_v8.teal
- app_roundtrip_uint64[]_42_v6.teal
- app_roundtrip_uint64[]_42_v8.teal
- app_roundtrip_uint64_v6.teal
- app_roundtrip_uint64_v8.teal
- app_roundtrip_uint8_v6.teal
- app_roundtrip_uint8_v8.teal
- app_exp.teal
- app_oldfac.teal
- app_slow_fibonacci.teal
- app_square.teal
- app_square_byref.teal
- app_string_mult.teal
- app_swap.teal
- lsig_exp.teal
- lsig_oldfac.teal
- lsig_slow_fibonacci.teal
- lsig_square.teal
- lsig_square_byref.teal
- lsig_string_mult.teal
- lsig_swap.teal
- __init__.py
- abi_roundtrip_test.py
- abi_router_test.py
- algod_test.py
- ecdsa_test.py
- graviton_abi_test.py
- graviton_test.py
- opup_test.py
- pure_logicsig_test.py
- sourcemap_monkey_integ_test.py
- nontriv_clear_approval_v6.teal
- nontriv_clear_approval_v8.teal
- nontriv_clear_clear_v6.teal
- nontriv_clear_clear_v8.teal
- questionable_approval_v6.teal
- questionable_clear_v6.teal
- questionableFP_approval_v8.teal
- questionableFP_clear_v8.teal
- yacc_approval_v6.teal
- yacc_clear_v6.teal
- yaccFP_approval_v8.teal
- yaccFP_clear_v8.teal
- __init__.py
- rps.py
- rps.teal
- rps_annotated.teal
- user_guide_snippet_dynamic_scratch_var.teal
- user_guide_snippet_recursiveIsEven.teal
- app_fn_0arg_0ret.teal
- app_fn_0arg_uint64_ret.teal
- app_fn_1arg_0ret.teal
- app_fn_1arg_1ret.teal
- app_fn_1tt_arg_uint64_ret.teal
- app_fn_2arg_0ret.teal
- app_fn_2mixed_arg_1ret.teal
- app_fn_3mixed_args_0ret.teal
- lsig_fn_0arg_0ret.teal
- lsig_fn_0arg_uint64_ret.teal
- lsig_fn_1arg_0ret.teal
- lsig_fn_1arg_1ret.teal
- lsig_fn_1tt_arg_uint64_ret.teal
- lsig_fn_2arg_0ret.teal
- lsig_fn_2mixed_arg_1ret.teal
- lsig_fn_3mixed_args_0ret.teal
- app_utest_any.teal
- app_utest_any_args.teal
- app_utest_bytes.teal
- app_utest_bytes_args.teal
- app_utest_int.teal
- app_utest_int_args.teal
- app_utest_noop.teal
- app_utest_noop_args.teal
- lsig_utest_any.teal
- lsig_utest_any_args.teal
- lsig_utest_bytes.teal
- lsig_utest_bytes_args.teal
- lsig_utest_int.teal
- lsig_utest_int_args.teal
- lsig_utest_noop.teal
- lsig_utest_noop_args.teal
- sub_even.teal
- sub_fastfib.teal
- sub_logcat.teal
- sub_slowfib.teal
- empty_scratches.teal
- lots_o_vars.teal
- sub_logcat_dynamic.teal
- sub_mixed.teal
- swapper.teal
- wilt_the_stilt.teal
- user_guide_snippet_ABIReturnSubroutine.teal
- user_guide_snippet_dynamic_scratch_var.teal
- user_guide_snippet_recursiveIsEven.teal
- __init__.py
- blackbox_test.py
- compile_test.py
- feature_gates_test.py
- module_test.py
- pass_by_ref_test.py
- pre_v6_test.py
- sourcemap_constructs311_test.py
- sourcemap_constructs_allpy_test.py
- sourcemap_monkey_raises_test.py
- sourcemap_monkey_unit_test.py
- sourcemap_rps_test.py
- sourcemap_test.py
- user_guide_test.py
- __init__.py
- abi_roundtrip.py
- blackbox.py
- compile_asserts.py
- mock_version.py
- .flake8
- .gitignore
- .readthedocs.yaml
- CHANGELOG.md
- CODE_OF_CONDUCT.md
- CONTRIBUTING.md
- docker-compose.yml
- LICENSE
- Makefile
- mypy.ini
- pytest.ini
- README.md
- release-process.md
- requirements.txt
- setup.py
# Installation Guide
1. Get the code
git clone https://github.com/algorand/pyteal
Downloads the entire project code from GitHub to your computer.
cd pyteal
Moves into the project folder you just downloaded.
2. Docker
Easy RecommendedPrerequisites
- Git Needed to download the project code from GitHub.
- Docker Desktop Needed to build and run containers. Install it and keep it running in the background.
docker compose up -d --build
Builds and starts all defined containers (server, database, etc.) at once, in the background.
Run docker compose ps to check the containers are Up. If the README mentions a port, open http://localhost:PORT in your browser.
3. Python
EasyPrerequisites
pip install -r requirements.txt
Installs the Python libraries listed in requirements.txt (or similar).
python <μ€νν νμΌλͺ
>.py # READMEμμ μ νν μ€ν νμΌλͺ
μ νμΈνμΈμ
Runs the Python script (or module).
If it runs without errors and prints output in the terminal, it worked.
4. Make
MediumPrerequisites
- Git Needed to download the project code from GitHub.
- Make Usually pre-installed on Linux/macOS. On Windows, install separately (e.g. via MSYS2 or WSL).
make
Compiles the code based on the generated build configuration to produce an executable.
If it finishes without errors, it worked. Try running the generated executable directly.
// repository documentation
Was this content helpful?
(0 ratings)
