Join our
Discord!
LogoLogo
SupraScan ExplorerStarKey WalletDiscord
  • Network
  • Oracles
  • Automation
  • SupraNova
  • AI Agents
  • Overview
  • Getting Started
  • API Reference
  • Smart Contract Integration
  • Your First Automation Task
    • Prerequisites & Epoch Timing
    • Create the Move Smart Contract
    • Calculate task-expiry-time & task-automation-fee
    • Register your Automation Task
    • Canceling Your Automation Task
  • Use Cases of AutoFi
  • Glossary
  • FAQs
Powered by GitBook

Links

  • Whitepapers
  • Bug Bounty
  • Security Audits

‎

  • Supra Dev Hub
  • Supra Labs Github
  • Entropy Foundation Github
On this page
Edit on GitHub
  1. Your First Automation Task

Register your Automation Task

Make sure the contract is published before registering automation — otherwise, the system won’t be able to find your function.

PreviousCalculate task-expiry-time & task-automation-feeNextCanceling Your Automation Task

Last updated 14 days ago

Before registering for real, test the task using --simulate:

supra move automation register --simulate \
  --task-max-gas-amount 5000 \
  --task-gas-price-cap 200 \
  --task-expiry-time-secs 1748035485 \
  --task-automation-fee-cap 1440000000\
  --function-id "0x123::auto_incr::auto_increment" \
  --rpc-url https://rpc-testnet.supra.com

If you see:

"vm_status": "Executed successfully"

You’re good to go, remove --simulate and run it for to get Automation Task Registered.

Post-Deployment: Sanity Check

Once you've registered your automation task, you’ll want to confirm it’s actually working.

  • Use SupraScan

    • Visit

    • Search your deployer address

    • Check Tasks Tab.

    • Confirm your task is executing at the expected intervals

Task will not become active until the next epoch. Users may not be able to confirm the task is executing right away.

  • Run the View Function

To check your counter value, run this CLI command:

supra move tool view \
  --function-id '0x123::auto_incr::get_counter_value' \
  --args address:0x123 \
  --rpc-url https://rpc-testnet.supra.com

Before the automation task starts:

{
"result": [
"0"
]
}

After the automation task starts:

{
  "result": [
    "1"
  ]
}

Check again after automation runs — if the value increases, your automation task is working perfectly.

SupraScan