7GJDP6QNNR2LNKMPOC6T6OP574RWW733
[
"autonomous agent",
{
"doc_url": "https://oswap-frontend.herokuapp.com/oscript/factory.json",
"init": "{
$exchange_template = 'GYPPZYMY72Y2SJB5TZKFEYSI24X6HBEI';
}",
"messages": {
"cases": [
{
"if": "{trigger.data.createExchange AND trigger.data.asset}",
"init": "{
$asset = trigger.data.asset;
if (
!asset[$asset].exists
OR asset[$asset].is_private
OR !asset[$asset].is_transferrable
OR asset[$asset].fixed_denominations
)
bounce("INVALID_ASSET");
if (var['asset_to_exchange.' || $asset])
bounce("DUPLICATE_EXCHANGE");
}",
"messages": [
{
"app": "definition",
"payload": {
"definition": [
"autonomous agent",
{
"base_aa": "{$exchange_template}",
"params": {
"asset": "{$asset}"
}
}
]
}
},
{
"app": "state",
"state": "{
$exchange = unit[response_unit].messages[[.app='definition']].payload.address;
$asset_id = var['asset_count'] + 1;
var['asset_to_exchange.' || $asset] = $exchange;
var['exchange_to_asset.' || $exchange] = $asset;
var['asset_count'] = $asset_id;
var['id_to_asset.' || $asset_id] = $asset;
response['asset'] = $asset;
response['exchange'] = $exchange;
}"
}
]
}
]
}
}
]
- MCI: 1246502
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"asset": "UccpQo12uLmufihkzdK7Kcrb5BlHp8GcMrSEA7NVdNw=",
"exchange": "WAX5SQ77QXWS6BAFUWN45A45K4O3ZIE2"
}
}
- MCI: 1246432
- Not bounced
- Response unit:
- Response: {
"responseVars": {
"asset": "WhsD5Y/1NeKROgQojGwfe9EBC7NH4KnAk4CorCrVRhs=",
"exchange": "XMRHEHP4NUXEFQYUV3MNVVSTARGFXZJK"
}
}
Show transactions in assets:
No transactions found, it may be worth changing the filter
Unit ID
Date
From
Direction
To
Amount
23.02.2020 23:19:23
7GJDP6QNNR2LNKMPOC6T6OP574RWW733
out
7GJDP6QNNR2LNKMPOC6T6OP574RWW733
23.02.2020 23:19:23
in
7GJDP6QNNR2LNKMPOC6T6OP574RWW733
23.02.2020 22:47:49
7GJDP6QNNR2LNKMPOC6T6OP574RWW733
out
7GJDP6QNNR2LNKMPOC6T6OP574RWW733
23.02.2020 22:47:49
in
7GJDP6QNNR2LNKMPOC6T6OP574RWW733