Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 7 from a total of 7 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Stream Withdraw | 19812539 | 295 days ago | IN | 0 ETH | 0.0003247 | ||||
Stream Withdraw | 19517906 | 336 days ago | IN | 0 ETH | 0.00103299 | ||||
Stream Withdraw | 19241577 | 375 days ago | IN | 0 ETH | 0.00168349 | ||||
Stream Withdraw | 18699471 | 451 days ago | IN | 0 ETH | 0.00153947 | ||||
Stream Withdraw | 18157507 | 526 days ago | IN | 0 ETH | 0.00040841 | ||||
Stream Withdraw | 17821799 | 573 days ago | IN | 0 ETH | 0.00117892 | ||||
Stream Withdraw | 17493878 | 620 days ago | IN | 0 ETH | 0.00167786 |
Latest 14 internal transactions
Advanced mode:
Parent Transaction Hash | Block |
From
|
To
|
|||
---|---|---|---|---|---|---|
19812539 | 295 days ago | 1 ETH | ||||
19526224 | 335 days ago | 1 ETH | ||||
19517906 | 336 days ago | 1 ETH | ||||
19270205 | 371 days ago | 1 ETH | ||||
19241577 | 375 days ago | 1 ETH | ||||
18773076 | 440 days ago | 1 ETH | ||||
18699471 | 451 days ago | 1 ETH | ||||
18192364 | 522 days ago | 1 ETH | ||||
18157507 | 526 days ago | 1 ETH | ||||
17865175 | 567 days ago | 1 ETH | ||||
17821799 | 573 days ago | 1 ETH | ||||
17515811 | 616 days ago | 1 ETH | ||||
17493878 | 620 days ago | 1 ETH | ||||
17493839 | 620 days ago | 1 ETH |
Loading...
Loading
Similar Match Source Code This contract matches the deployed Bytecode of the Source Code for Contract 0x518Af5F2...74AB4F9c4 The constructor portion of the code might be different and could alter the actual behaviour of the contract
Contract Name:
SimpleStream
Compiler Version
v0.8.4+commit.c7e474f2
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2021-05-20 */ // Sources flattened with hardhat v2.1.1 https://hardhat.org // File contracts/SimpleStream.sol // https://github.com/austintgriffith/scaffold-eth/tree/simple-stream // // 🏰 BuidlGuidl.com // pragma solidity >=0.8.0; //SPDX-License-Identifier: MIT //import "hardhat/console.sol"; contract SimpleStream { event Withdraw( address indexed to, uint256 amount, string reason ); event Deposit( address indexed from, uint256 amount, string reason ); address payable public toAddress;// = payable(0xD75b0609ed51307E13bae0F9394b5f63A7f8b6A1); uint256 public cap;// = 0.5 ether; uint256 public frequency;// 1296000 seconds == 2 weeks; uint256 public last;//stream starts empty (last = block.timestamp) or full (block.timestamp - frequency) constructor(address payable _toAddress, uint256 _cap, uint256 _frequency, bool _startsFull) { toAddress = _toAddress; cap = _cap; frequency = _frequency; if(_startsFull){ last = block.timestamp - frequency; }else{ last = block.timestamp; } } function streamBalance() public view returns (uint256){ if(block.timestamp-last > frequency){ return cap; } return (cap * (block.timestamp-last)) / frequency; } function streamWithdraw(uint256 amount, string memory reason) public { require(msg.sender==toAddress,"this stream is not for you"); uint256 totalAmountCanWithdraw = streamBalance(); require(totalAmountCanWithdraw>=amount,"not enough in the stream"); uint256 cappedLast = block.timestamp-frequency; if(last<cappedLast){ last = cappedLast; } last = last + ((block.timestamp - last) * amount / totalAmountCanWithdraw); emit Withdraw( msg.sender, amount, reason ); toAddress.transfer(amount); } function streamDeposit(string memory reason) public payable { emit Deposit( msg.sender, msg.value, reason ); } receive() external payable { streamDeposit(""); } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address payable","name":"_toAddress","type":"address"},{"internalType":"uint256","name":"_cap","type":"uint256"},{"internalType":"uint256","name":"_frequency","type":"uint256"},{"internalType":"bool","name":"_startsFull","type":"bool"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"string","name":"reason","type":"string"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"string","name":"reason","type":"string"}],"name":"Withdraw","type":"event"},{"inputs":[],"name":"cap","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"frequency","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"last","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"streamBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"reason","type":"string"}],"name":"streamDeposit","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"string","name":"reason","type":"string"}],"name":"streamWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"toAddress","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]
Deployed Bytecode
0x6080604052600436106100745760003560e01c8063a8397ddc1161004e578063a8397ddc1461010f578063c3ae1e591461012f578063c5a15ec814610144578063ead50da31461015757600080fd5b806319c87f1f14610098578063355274ea146100d557806347799da8146100f957600080fd5b36610093576100916040518060200160405280600081525061016d565b005b600080fd5b3480156100a457600080fd5b506000546100b8906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b3480156100e157600080fd5b506100eb60015481565b6040519081526020016100cc565b34801561010557600080fd5b506100eb60035481565b34801561011b57600080fd5b5061009161012a36600461044e565b6101b3565b34801561013b57600080fd5b506100eb610340565b610091610152366004610413565b61016d565b34801561016357600080fd5b506100eb60025481565b336001600160a01b03167f643e927b32d5bfd08eccd2fcbd97057ad413850f857a2359639114e8e8dd3d7b34836040516101a8929190610493565b60405180910390a250565b6000546001600160a01b031633146102125760405162461bcd60e51b815260206004820152601a60248201527f746869732073747265616d206973206e6f7420666f7220796f7500000000000060448201526064015b60405180910390fd5b600061021c610340565b90508281101561026e5760405162461bcd60e51b815260206004820152601860248201527f6e6f7420656e6f75676820696e207468652073747265616d00000000000000006044820152606401610209565b60006002544261027e9190610545565b90508060035410156102905760038190555b8184600354426102a09190610545565b6102aa9190610526565b6102b49190610506565b6003546102c191906104ee565b60035560405133907f485f1bb6524c663555797e00171a10f341656e59b02d6b557a0a38ba7d5d9751906102f89087908790610493565b60405180910390a2600080546040516001600160a01b039091169186156108fc02918791818181858888f19350505050158015610339573d6000803e3d6000fd5b5050505050565b6000600254600354426103539190610545565b1115610360575060015490565b6002546003546103709042610545565b60015461037d9190610526565b6103879190610506565b905090565b600082601f83011261039c578081fd5b813567ffffffffffffffff808211156103b7576103b7610572565b604051601f8301601f19908116603f011681019082821181831017156103df576103df610572565b816040528381528660208588010111156103f7578485fd5b8360208701602083013792830160200193909352509392505050565b600060208284031215610424578081fd5b813567ffffffffffffffff81111561043a578182fd5b6104468482850161038c565b949350505050565b60008060408385031215610460578081fd5b82359150602083013567ffffffffffffffff81111561047d578182fd5b6104898582860161038c565b9150509250929050565b828152600060206040818401528351806040850152825b818110156104c6578581018301518582016060015282016104aa565b818111156104d75783606083870101525b50601f01601f191692909201606001949350505050565b600082198211156105015761050161055c565b500190565b60008261052157634e487b7160e01b81526012600452602481fd5b500490565b60008160001904831182151516156105405761054061055c565b500290565b6000828210156105575761055761055c565b500390565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052604160045260246000fdfea2646970667358221220998fd3296a17e6fc1e79b14215371f2ae91a0a88a0ca053c18e4bbb8872216b664736f6c63430008040033
Deployed Bytecode Sourcemap
304:1705:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1986:17;;;;;;;;;;;;;:13;:17::i;:::-;304:1705;;;;;480:32;;;;;;;;;;-1:-1:-1;480:32:0;;;;-1:-1:-1;;;;;480:32:0;;;;;;-1:-1:-1;;;;;1700:32:1;;;1682:51;;1670:2;1655:18;480:32:0;;;;;;;;574:18;;;;;;;;;;;;;;;;;;;2598:25:1;;;2586:2;2571:18;574::0;2553:76:1;671:19:0;;;;;;;;;;;;;;;;1266:556;;;;;;;;;;-1:-1:-1;1266:556:0;;;;;:::i;:::-;;:::i;1075:185::-;;;;;;;;;;;;;:::i;1829:121::-;;;;;;:::i;:::-;;:::i;612:24::-;;;;;;;;;;;;;;;;1829:121;1912:10;-1:-1:-1;;;;;1903:40:0;;1924:9;1935:6;1903:40;;;;;;;:::i;:::-;;;;;;;;1829:121;:::o;1266:556::-;1363:9;;-1:-1:-1;;;;;1363:9:0;1351:10;:21;1343:59;;;;-1:-1:-1;;;1343:59:0;;1946:2:1;1343:59:0;;;1928:21:1;1985:2;1965:18;;;1958:30;2024:28;2004:18;;;1997:56;2070:18;;1343:59:0;;;;;;;;;1410:30;1443:15;:13;:15::i;:::-;1410:48;;1498:6;1474:22;:30;;1466:66;;;;-1:-1:-1;;;1466:66:0;;2301:2:1;1466:66:0;;;2283:21:1;2340:2;2320:18;;;2313:30;2379:26;2359:18;;;2352:54;2423:18;;1466:66:0;2273:174:1;1466:66:0;1540:18;1577:9;;1561:15;:25;;;;:::i;:::-;1540:46;;1602:10;1597:4;;:15;1594:55;;;1623:4;:17;;;1594:55;1707:22;1698:6;1690:4;;1672:15;:22;;;;:::i;:::-;1671:33;;;;:::i;:::-;:58;;;;:::i;:::-;1663:4;;:67;;;;:::i;:::-;1656:4;:74;1743:38;;1753:10;;1743:38;;;;1765:6;;1773;;1743:38;:::i;:::-;;;;;;;;1789:9;;;:26;;-1:-1:-1;;;;;1789:9:0;;;;:26;;;;;1808:6;;1789:26;:9;:26;1808:6;1789:9;:26;;;;;;;;;;;;;;;;;;;;;1266:556;;;;:::o;1075:185::-;1121:7;1162:9;;1155:4;;1139:15;:20;;;;:::i;:::-;:32;1136:63;;;-1:-1:-1;1188:3:0;;;1075:185::o;1136:63::-;1245:9;;1236:4;;1220:20;;:15;:20;:::i;:::-;1213:3;;:28;;;;:::i;:::-;1212:42;;;;:::i;:::-;1205:49;;1075:185;:::o;14:739:1:-;57:5;110:3;103:4;95:6;91:17;87:27;77:2;;132:5;125;118:20;77:2;172:6;159:20;198:18;235:2;231;228:10;225:2;;;241:18;;:::i;:::-;316:2;310:9;284:2;370:13;;-1:-1:-1;;366:22:1;;;390:2;362:31;358:40;346:53;;;414:18;;;434:22;;;411:46;408:2;;;460:18;;:::i;:::-;500:10;496:2;489:22;535:2;527:6;520:18;581:3;574:4;569:2;561:6;557:15;553:26;550:35;547:2;;;602:5;595;588:20;547:2;670;663:4;655:6;651:17;644:4;636:6;632:17;619:54;693:15;;;710:4;689:26;682:41;;;;-1:-1:-1;697:6:1;67:686;-1:-1:-1;;;67:686:1:o;758:342::-;827:6;880:2;868:9;859:7;855:23;851:32;848:2;;;901:6;893;886:22;848:2;946:9;933:23;979:18;971:6;968:30;965:2;;;1016:6;1008;1001:22;965:2;1044:50;1086:7;1077:6;1066:9;1062:22;1044:50;:::i;:::-;1034:60;838:262;-1:-1:-1;;;;838:262:1:o;1105:410::-;1183:6;1191;1244:2;1232:9;1223:7;1219:23;1215:32;1212:2;;;1265:6;1257;1250:22;1212:2;1306:9;1293:23;1283:33;;1367:2;1356:9;1352:18;1339:32;1394:18;1386:6;1383:30;1380:2;;;1431:6;1423;1416:22;1380:2;1459:50;1501:7;1492:6;1481:9;1477:22;1459:50;:::i;:::-;1449:60;;;1202:313;;;;;:::o;2634:674::-;2811:6;2800:9;2793:25;2774:4;2837:2;2875;2870;2859:9;2855:18;2848:30;2907:6;2901:13;2950:6;2945:2;2934:9;2930:18;2923:34;2975:4;2988:140;3002:6;2999:1;2996:13;2988:140;;;3097:14;;;3093:23;;3087:30;3063:17;;;3082:2;3059:26;3052:66;3017:10;;2988:140;;;3146:6;3143:1;3140:13;3137:2;;;3216:4;3211:2;3202:6;3191:9;3187:22;3183:31;3176:45;3137:2;-1:-1:-1;3292:2:1;3271:15;-1:-1:-1;;3267:29:1;3252:45;;;;3299:2;3248:54;;2783:525;-1:-1:-1;;;;2783:525:1:o;3313:128::-;3353:3;3384:1;3380:6;3377:1;3374:13;3371:2;;;3390:18;;:::i;:::-;-1:-1:-1;3426:9:1;;3361:80::o;3446:217::-;3486:1;3512;3502:2;;-1:-1:-1;;;3537:31:1;;3591:4;3588:1;3581:15;3619:4;3544:1;3609:15;3502:2;-1:-1:-1;3648:9:1;;3492:171::o;3668:168::-;3708:7;3774:1;3770;3766:6;3762:14;3759:1;3756:21;3751:1;3744:9;3737:17;3733:45;3730:2;;;3781:18;;:::i;:::-;-1:-1:-1;3821:9:1;;3720:116::o;3841:125::-;3881:4;3909:1;3906;3903:8;3900:2;;;3914:18;;:::i;:::-;-1:-1:-1;3951:9:1;;3890:76::o;3971:127::-;4032:10;4027:3;4023:20;4020:1;4013:31;4063:4;4060:1;4053:15;4087:4;4084:1;4077:15;4103:127;4164:10;4159:3;4155:20;4152:1;4145:31;4195:4;4192:1;4185:15;4219:4;4216:1;4209:15
Swarm Source
ipfs://998fd3296a17e6fc1e79b14215371f2ae91a0a88a0ca053c18e4bbb8872216b6
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 31 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.