AVM opcodes
The complete opcode inventory generated from the interpreter source, with the upstream test annotation preserved per opcode.
Experimental or beta Verified 2026-08-31
Behavior exists in beta or unreleased code. Do not build production dependencies on it.
- Page ID
-
protocol/avm/opcodes - Normative authority
- Atomicals reference implementation
- Networks
- none
- Documentation version
- 2026.08
- Audience
- developer
- Owner
- bitcoin-universe-docs
- Sources
-
- Atomicals Virtual Machine interpreter
at
c185e6216a3esrc/script/script.h opcode enumeration
- Atomicals Virtual Machine interpreter
at
- Known limitations
-
- The status column reflects the upstream source comment only. It is not a Universe verification result.
- Opcodes with no upstream annotation are shown as such rather than assumed working.
本頁內容尚未翻譯。
This inventory is generated from the interpreter’s opcode enumeration. It is not hand maintained, so it cannot drift from the source.
Authorisation
Section titled “Authorisation”Signature checking is replaced. The ordinary Bitcoin signature opcodes are removed and a custom authorisation opcode is used instead.
| Opcode | Value | Group | Upstream status | Purpose |
|---|---|---|---|---|
OP_CHECKAUTHSIG | 0xc0 | authorisation | tested upstream | No upstream description in the source comment. |
OP_CHECKAUTHSIGVERIFY | 0xc1 | authorisation | tested upstream | No upstream description in the source comment. |
Introspection
Section titled “Introspection”Opcodes that read the transaction being evaluated.
| Opcode | Value | Group | Upstream status | Purpose |
|---|---|---|---|---|
OP_TXVERSION | 0xc2 | introspection | no upstream status | No upstream description in the source comment. |
OP_TXINPUTCOUNT | 0xc3 | introspection | no upstream status | No upstream description in the source comment. |
OP_TXOUTPUTCOUNT | 0xc4 | introspection | no upstream status | No upstream description in the source comment. |
OP_TXLOCKTIME | 0xc5 | introspection | no upstream status | No upstream description in the source comment. |
OP_OUTPOINTTXHASH | 0xc8 | introspection | no upstream status | No upstream description in the source comment. |
OP_OUTPOINTINDEX | 0xc9 | introspection | no upstream status | No upstream description in the source comment. |
OP_INPUTBYTECODE | 0xca | introspection | tested upstream | No upstream description in the source comment. |
OP_INPUTSEQUENCENUMBER | 0xcb | introspection | tested upstream | No upstream description in the source comment. |
OP_INPUTWITNESSBYTECODE | 0xcc | introspection | not working | No upstream description in the source comment. |
OP_OUTPUTVALUE | 0xcd | introspection | no upstream status | No upstream description in the source comment. |
OP_OUTPUTBYTECODE | 0xce | introspection | no upstream status | No upstream description in the source comment. |
State storage
Section titled “State storage”Key and value storage private to a contract.
| Opcode | Value | Group | Upstream status | Purpose |
|---|---|---|---|---|
OP_KV_EXISTS | 0xed | state-storage | tested upstream | Check if KV exists. |
OP_KV_GET | 0xef | state-storage | tested upstream | Get KV. |
OP_KV_PUT | 0xf0 | state-storage | tested upstream | Put KV. |
OP_KV_DELETE | 0xf1 | state-storage | tested upstream | Delete KV. |
Fungible tokens
Section titled “Fungible tokens”Deposit, withdrawal, and inspection of ARC-20 balances held by a contract.
| Opcode | Value | Group | Upstream status | Purpose |
|---|---|---|---|---|
OP_FT_BALANCE_ADD | 0xd3 | fungible-tokens | tested upstream | Add to FT balance internal token table storage |
OP_FT_WITHDRAW | 0xf2 | fungible-tokens | tested upstream | Mark an output for withdraw FT |
OP_FT_BALANCE | 0xf4 | fungible-tokens | tested upstream | Get balance of FT held in contract |
OP_FT_COUNT | 0xf6 | fungible-tokens | tested upstream | Get count of different unique FTs |
OP_FT_ITEM | 0xf7 | fungible-tokens | tested upstream | Get a specific FT atomical id in sorted order |
Non-fungible tokens
Section titled “Non-fungible tokens”Deposit, withdrawal, and inspection of non-fungible objects held by a contract.
| Opcode | Value | Group | Upstream status | Purpose |
|---|---|---|---|---|
OP_NFT_PUT | 0xd1 | non-fungible-tokens | tested upstream | Add NFT to internal token table storage |
OP_NFT_WITHDRAW | 0xf3 | non-fungible-tokens | tested upstream | Mark an output for withdraw NFT |
OP_NFT_EXISTS | 0xf8 | non-fungible-tokens | tested upstream | Get specific NFT that exists |
OP_NFT_COUNT | 0xf9 | non-fungible-tokens | tested upstream | Get count of different unique NFTs |
OP_NFT_ITEM | 0xfa | non-fungible-tokens | tested upstream | Get a specfic NFT atomical id in sorted order |
Block information
Section titled “Block information”| Opcode | Value | Group | Upstream status | Purpose |
|---|---|---|---|---|
OP_GETBLOCKINFO | 0xfb | block-info | tested upstream | Get block info for height. |
OP_DECODEBLOCKINFO | 0xfc | block-info | tested upstream | Decode a block header into the parts |
Hashing
Section titled “Hashing”| Opcode | Value | Group | Upstream status | Purpose |
|---|---|---|---|---|
OP_HASH_FN | 0xfd | hashing | tested upstream | Various hash functions |
Large numbers
Section titled “Large numbers”The interpreter adds support for arbitrarily large numbers, so arithmetic is not bounded the way Bitcoin script bounds it. Any integration must treat numeric results as arbitrary precision rather than assuming a fixed width.