QRPI33656RFSEDEZHB5T2DNJ7R2WQQDS
[
"autonomous agent",
{
"init": "{
$non_bytes_asset = trigger.output[[asset!=base]].asset;
if ($non_bytes_asset == 'ambiguous')
bounce('ambiguous asset');
$asset = $non_bytes_asset == 'none' ? 'base' : $non_bytes_asset;
$claim_num = trigger.data.claim_num;
$step1 = !!$claim_num; // from the bridge
if ($step1){
$data = trigger.data.data;
$address = $data.address1;
$data_to_forward = $data.data1;
}
else if (var['initial_unit'] AND var['initial_unit'] == trigger.initial_unit AND var['address2']){ // response from the AA called in step 1
$step2 = true;
$address = var['address2'];
$data_to_forward = var['data2'];
}
}",
"messages": [
{
"if": "{$step1 OR $step2}",
"app": "payment",
"payload": {
"asset": "{$asset}",
"outputs": [
{
"address": "{$address}",
"amount": "{trigger.output[[asset=$asset]]}"
}
]
}
},
{
"if": "{($step1 OR $step2) AND $asset != 'base'}",
"app": "payment",
"payload": {
"asset": "base",
"outputs": [
{
"address": "{$address}",
"amount": 1000
}
]
}
},
{
"if": "{$data_to_forward}",
"app": "data",
"payload": "{
$data_to_forward
}"
},
{
"app": "state",
"state": "{
if ($step1 AND $data.address2){ // save step2 data for future forwarding
var['initial_unit'] = trigger.initial_unit;
var['address2'] = $data.address2;
var['data2'] = $data.data2;
}
else if ($step2){
var['initial_unit'] = false;
var['address2'] = false;
var['data2'] = false;
}
response['message'] = $step1 ? 'forwarded 1' : ($step2 ? 'forwarded 2' : 'deposited');
}"
}
]
}
]
- MCI: 2959611
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"message": "forwarded 1"
}
}
- MCI: 2950084
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"message": "forwarded 1"
}
}
- MCI: 2950083
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"message": "forwarded 1"
}
}
- MCI: 2947954
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"message": "forwarded 1"
}
}
- MCI: 2947260
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"message": "forwarded 1"
}
}
- MCI: 2946359
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"message": "forwarded 1"
}
}
- MCI: 2943107
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"message": "forwarded 1"
}
}
- MCI: 2940573
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"message": "forwarded 1"
}
}
- MCI: 2940504
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"message": "forwarded 1"
}
}
- MCI: 2756718
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"message": "forwarded 1"
}
}
Show transactions in assets:
No transactions found, it may be worth changing the filter
Unit ID
Date
From
Direction
To
Amount
09.02.2023 09:22:51
QRPI33656RFSEDEZHB5T2DNJ7R2WQQDS
out
09.02.2023 09:22:51
in
QRPI33656RFSEDEZHB5T2DNJ7R2WQQDS
06.02.2023 16:29:54
QRPI33656RFSEDEZHB5T2DNJ7R2WQQDS
out
06.02.2023 16:29:54
in
QRPI33656RFSEDEZHB5T2DNJ7R2WQQDS
06.02.2023 16:29:53
QRPI33656RFSEDEZHB5T2DNJ7R2WQQDS
out