How onchain programs (often called ‘smart contracts’) work on Nexis Native Chain.
mainnet-beta
, testnet
, devnet
, localnet
) is
effectively a single computer with a globally synchronized state. The programs
that run on Nexis Native Chain - the ones that create tokens, swap tokens, art marketplaces,
escrows, market makers, DePIN apps, auctions, retail payments platforms, etc -
are called Nexis Native Chain apps.
The most popular way to build onchain apps is using Rust language and the
Anchor framework.
These frameworks implement common security checks automatically, and handle
common tasks like:
anchor init
, and the private key is saved in the
target/deploy
directory of your project.
A program’s public key is sometimes called a ‘program ID’ or ‘program address’.
transfer
instruction handlermemo
instruction handler.seeds
chosen by
you, the programmer.
USD
and AUD
to make a Program Derived Addresstitanic
(or maybe the IMDB ID if
you prefer) to make a Program Derived Address.'config'
. Your program’s PDAs are unique, so they won’t conflict with
other programs.