Skip to content

Latest commit

 

History

History
45 lines (31 loc) · 1.85 KB

README.md

File metadata and controls

45 lines (31 loc) · 1.85 KB

CTF Challenge

Documentation

For TEALScript documentation, go to https://tealscript.algo.xyz

Usage

Algokit Bootstrap

  1. Create a new TestNet account using a 3-character prefix to help you identify your account on the leaderboard: algokit task vanity-address <PREFIX> where is your 3-character identifier The response will contain your mnemonic
  2. Fund your accoount using the TestNet Dispenser: algokit dispenser login --ci
  3. Within the response, press Command + Click the URL link to open the Dispenser validation website
  4. Follow the prompts, enter your email, check your spam folder for the verification code, complete the verification
  5. You may close the Dispenser website after verification, which will return you to the CLI
  6. The response will contain the ALGOKIT_DISPENSER_ACCESS_TOKEN
  7. Bootstrap the project algokit bootstrap all
  8. When prompted in the CLI, include the fields from #1 & #6
  9. Register your account on the Google Form

Run Level 0 Challenge

  1. npx tsx src/level0.ts
  2. Confirm your account is now on the Leaderboard

Build Contract

Without LocalNet

ALGOD_SERVER="https://testnet-api.algonode.cloud" ALGOD_PORT=443 ALGOD_TOKEN="" npm run build will compile the contract without using LocalNet but producing the same artifacts as the commands in the next section

With LocalNet

npm run build will compile the contract to TEAL and generate an ABI and appspec JSON in ./contracts/artifacts and a algokit TypeScript client in ./contracts/clients.

npm run compile-contract or npm run generate-client can be used to compile the contract or generate the contract seperately.

Run Tests

npm run test will execute the tests defined in ./__test__

Lint

npm run lint will lint the contracts and tests with ESLint.