TransactionsSandbox

Transaction details

Contract creation
Success
Transaction ID
0xd85496c2949770b0a10396e3e143f5a0c541bc2a9c56fb6de413a6d391f24821
Contract name
ST2PZGXFZS6MGSDPT7YBHXPW2NHB8WFYX4RXHX7FA.hello_world
Sender address
ST2PZGXFZS6MGSDPT7YBHXPW2NHB8WFYX4RXHX7FA
Fees
0.003 STX
Block height
#397
6 days ago
Block hash
0xf073b7b10b9391006dfc5a6293f33ad150c59be2eb214602be5a9f614bbfd0e8
hello_world
Event Log
#
Asset
Event type
Value
01
novel-token-19
Mint
12 FT
01
{
02
"event_index"
:
0
,
03
"event_type"
:
"fungible_token_asset"
,
04
"asset"
:
{
05
"asset_event_type"
:
"mint"
,
06
"asset_id"
:
"ST2PZGXFZS6MGSDPT7YBHXPW2NHB8WFYX4RXHX7FA.hello_world::novel-token-19"
,
07
"sender"
:
""
,
08
"recipient"
:
"SZ2J6ZY48GV1EZ5V2V5RB9MP66SW86PYKKQ9H6DPR"
,
09
"amount"
:
"12"
10
}
11
}
02
hello-nft
Mint
2 NFT
01
{
02
"event_index"
:
1
,
03
"event_type"
:
"non_fungible_token_asset"
,
04
"asset"
:
{
05
"asset_event_type"
:
"mint"
,
06
"asset_id"
:
"ST2PZGXFZS6MGSDPT7YBHXPW2NHB8WFYX4RXHX7FA.hello_world::hello-nft"
,
07
"sender"
:
""
,
08
"recipient"
:
"SZ2J6ZY48GV1EZ5V2V5RB9MP66SW86PYKKQ9H6DPR"
,
09
"value"
:
{
10
"hex"
:
"0x0100000000000000000000000000000002"
,
11
"repr"
:
"2"
12
}
13
}
14
}
03
novel-token-19
Transfer
2 FT
01
{
02
"event_index"
:
2
,
03
"event_type"
:
"fungible_token_asset"
,
04
"asset"
:
{
05
"asset_event_type"
:
"transfer"
,
06
"asset_id"
:
"ST2PZGXFZS6MGSDPT7YBHXPW2NHB8WFYX4RXHX7FA.hello_world::novel-token-19"
,
07
"sender"
:
"SZ2J6ZY48GV1EZ5V2V5RB9MP66SW86PYKKQ9H6DPR"
,
08
"recipient"
:
"SM2J6ZY48GV1EZ5V2V5RB9MP66SW86PYKKQVX8X0G"
,
09
"amount"
:
"2"
10
}
11
}
04
Smart Contract
Log
"Event! Hello world"
01
{
02
"event_index"
:
3
,
03
"event_type"
:
"smart_contract_log"
,
04
"contract_log"
:
{
05
"contract_id"
:
"ST2PZGXFZS6MGSDPT7YBHXPW2NHB8WFYX4RXHX7FA.hello_world"
,
06
"topic"
:
"print"
,
07
"value"
:
{
08
"hex"
:
"0x02000000124576656e74212048656c6c6f20776f726c64"
,
09
"repr"
:
"\"Event! Hello world\""
10
}
11
}
12
}
05
hello-nft
Mint
1 NFT
01
{
02
"event_index"
:
4
,
03
"event_type"
:
"non_fungible_token_asset"
,
04
"asset"
:
{
05
"asset_event_type"
:
"mint"
,
06
"asset_id"
:
"ST2PZGXFZS6MGSDPT7YBHXPW2NHB8WFYX4RXHX7FA.hello_world::hello-nft"
,
07
"sender"
:
""
,
08
"recipient"
:
"SZ2J6ZY48GV1EZ5V2V5RB9MP66SW86PYKKQ9H6DPR"
,
09
"value"
:
{
10
"hex"
:
"0x0100000000000000000000000000000001"
,
11
"repr"
:
"1"
12
}
13
}
14
}
06
hello-nft
Transfer
1 NFT
01
{
02
"event_index"
:
5
,
03
"event_type"
:
"non_fungible_token_asset"
,
04
"asset"
:
{
05
"asset_event_type"
:
"transfer"
,
06
"asset_id"
:
"ST2PZGXFZS6MGSDPT7YBHXPW2NHB8WFYX4RXHX7FA.hello_world::hello-nft"
,
07
"sender"
:
"SZ2J6ZY48GV1EZ5V2V5RB9MP66SW86PYKKQ9H6DPR"
,
08
"recipient"
:
"SM2J6ZY48GV1EZ5V2V5RB9MP66SW86PYKKQVX8X0G"
,
09
"value"
:
{
10
"hex"
:
"0x0100000000000000000000000000000001"
,
11
"repr"
:
"1"
12
}
13
}
14
}
Contract source
01
(
define-constant
sender
'SZ2J6ZY48GV1EZ5V2V5RB9MP66SW86PYKKQ9H6DPR
)
02
(
define-constant
recipient
'SM2J6ZY48GV1EZ5V2V5RB9MP66SW86PYKKQVX8X0G
)
03
04
(
define-fungible-token
novel-token-19
)
05
(
begin
(
ft-mint?
novel-token-19
u12
sender
)
)
06
(
begin
(
ft-transfer?
novel-token-19
u2
sender recipient
)
)
07
08
(
define-non-fungible-token
hello-nft uint
)
09
(
begin
(
nft-mint?
hello-nft
u1
sender
)
)
10
(
begin
(
nft-mint?
hello-nft
u2
sender
)
)
11
(
begin
(
nft-transfer?
hello-nft
u1
sender recipient
)
)
12
13
(
define-public
(
test-emit-event
)
14
(
begin
15
(
print
"Event! Hello world"
)
16
(
ok
u1
)
)
)
17
(
begin
(
test-emit-event
)
)
18
19
(
define-public
(
test-event-types
)
20
(
begin
21
(
unwrap-panic
(
ft-mint?
novel-token-19
u3
recipient
)
)
22
(
unwrap-panic
(
nft-mint?
hello-nft
u2
recipient
)
)
23
(
unwrap-panic
(
stx-transfer?
u60
tx-sender
'SZ2J6ZY48GV1EZ5V2V5RB9MP66SW86PYKKQ9H6DPR
)
)
24
(
unwrap-panic
(
stx-burn?
u20
tx-sender
)
)
25
(
ok
u1
)
)
)
26
27
(
define-map
store
(
(
key
(
buff
32
)
)
)
(
(
value
(
buff
32
)
)
)
)
28
(
define-public
(
get-value
(
key
(
buff
32
)
)
)
29
(
begin
30
(
match
(
map-get?
store
(
(
key
key
)
)
)
31
entry
(
ok
(
get
value entry
)
)
32
(
err
0
)
)
)
)
33
(
define-public
(
set-value
(
key
(
buff
32
)
)
(
value
(
buff
32
)
)
)
34
(
begin
35
(
map-set
store
(
(
key
key
)
)
(
(
value
value
)
)
)
36
(
ok
u1
)
)
)
Post conditions
This transaction has no post-conditions.