Unit ID
IxLt0wKmA7FJvtdtE+QE8mWaD6VM/v7pmoUZ4fKV1Rs=
Received
01.08.2019 20:25:19
Confirmation delay (full node)
3 minutes 19 seconds
Confirmation delay (light node)
5 minutes 50 seconds
Messages
Definition
Definition: [ "autonomous agent", { "messages": [ { "app": "state", "state": "{ $checkaddress = trigger.data.address; if ( !$checkaddress ) // not sure how to check if data.address is an invalid address??? It especially cannot be a logicaladdress bounce( 'input: { address : address , [ newaddress : newaddress ] , [ checkonly : false ] }'); $logicaladdress = var[ $checkaddress ]; if ( $logicaladdress ){ // EXISTS $currentaddress = var[ $logicaladdress ]; // TRANSFER $newaddress = trigger.data.newaddress; if( $newaddress ){ // again need to check is an valid address??? again cannot be a logicaladdress if( !trigger.data.notauthorized ){ // for now just allow anyone who paid OR maybe set this to some admin address //if( var[ $currentaddress ][ 'author' ] == trigger.address ){ // how to get author of an external address??? // transfer to new address only if author of current address ONLY var[ $logicaladdress ] = $newaddress; var[ $newaddress ] = $logicaladdress; if( trigger.data.checkonly ){ response[ "message" ] = "Address transferred from " || $currentaddress || " to " || $newaddress; } } }else{ if( trigger.data.checkonly ) bounce( "You need to be author of " || $currentaddress || " in order to transfer to newaddress" ); } // CHECK IF LATEST ADDRESS if( trigger.data.checkonly ){ if( $checkaddress != $currentaddress ) bounce( "Please use latest address at " || $currentaddress ); else bounce( "This address is current" ); // let's bounce even thou computation is Success since we are checking only } $route = var[ $logicaladdress ]; }else{ // NEW var[ "L" || $checkaddress ] = $checkaddress; // create logical address var[ $checkaddress ] = "L" || $checkaddress; // set checkaddress to logical address $route = var[ "L" || $checkaddress ]; } response[ "message" ] = "Routing to " || $route; }" } ] } ]
Technical information
Fees:
2,579 bytes
(353 headers, 2226 payload)
Level:979889
Witnessed level:979882
Main chain index:978709
Latest included mc index:978708
Status:stable/confirmed/final