{
    "version": 5,
    "timestamp": 1707358652551,
    "reference": "54XD6XC73Rd8iPxwheUhkgUVVsPJcYePw8B11hFeu3dq",
    "nxt-consensus": {
        "base-target": 70,
        "generation-signature": "FiknKfXUdmm4Nd4aKLip63BCHrL5KWicEJA5HAF5FFHFMcpdmB5jPCyTdZq37MyMNwUyLnfBCVpSgwysUqwot9GiLC9oCJTgf4Fstb3jSq74mB2fzfAyUon5MMEXvqB2ccX"
    },
    "transactionsRoot": "Ed5X2ioZR3eQiACbaHsbZ2SeQkMNdePkHBbGYTuBB6uX",
    "id": "734kP4BDnuYHrC9LGzeDneP3p8nqDSpdC1xFj6cpsVD1",
    "features": [],
    "desiredReward": -1,
    "generator": "3MvbutkV3xapQVUcGBGWCongwfdH8LKTm8w",
    "generatorPublicKey": "9bNzvarUWDCnAv4YrNKtSh6FQXQ94jFZNkciJNcH4dgj",
    "stateHash": "7jhhsTPASps7M1qxBFahbn4d5QX5MAfg8FC85zDczgPF",
    "signature": "5hHGE2pABg3qUTkRkFYA7zToQRXuw7Qd74irP3sw2PH3hsjV6oK7BsP7FSoWS9afQN5coXciqon8orW7i1GhrUFB",
    "blocksize": 6700,
    "transactionCount": 19,
    "totalFee": 9500000,
    "reward": 600000000,
    "rewardShares": {
        "3MvbutkV3xapQVUcGBGWCongwfdH8LKTm8w": 200000000,
        "3Myb6G8DkdBb8YcZzhrky65HrmiNuac3kvS": 200000000,
        "3N13KQpdY3UU7JkWUBD9kN7t7xuUgeyYMTT": 200000000
    },
    "VRF": "KMNhfyAswGPtQXjnBMfG5AHZDmxgaaQ5VyuanHWiSwf",
    "fee": 9500000,
    "previous": "2966663",
    "height": "2966664",
    "next": "2966665",
    "transactions": [
        {
            "type": 16,
            "id": "66s2xokWJUZRVozyQXnC5haPPrcmZYjA2Ssi9kPhyjr8",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358652453,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "TdvuVCvZVd4ZLdcXAqXutcQ7ajSKjKL2MNEWL45gYhrDBEqUamybWspPeLWX6oQ9Etk1J5k9TJcqCorovX7mg6m"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "9SbgzYDTGMGaTHdNdLv4WAjFaCRf42R4CtfSCk2SK9iK",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358652600,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "59QXoZDjTcwtrkfvpaiYLX8J3A7TsR2KtUo14yGXVbjBHuuhMd6JfyKPxRCr1q4w7FuVTfqKC2kfx3txbF8aRsZF"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "5u63ptCF8ZC5h1oPtTTCGkYCHVCmySuC4SZUP163ukFX",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358662620,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "4bdDtXfdJuZ4CPpbAFwtVUHKvLcn4vxeSgGNQUgGdp1qkqS7rLmp8wV9xwmU6TJarSa1M5vT3yrtjqawo3JfpjB3"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "AaQYpuci3VZTMKSxqJuiyESbSpyeovdk5KoZPi8AK3Ps",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358662638,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "4wiPkfhNLerJcWnSxzbkAkfoPBxuDHPVfSjHbkHm6tiQqqzuH1f3WfeLEtkk4Y9KLiSVcbEX3N5tt7gadYDANoLc"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "CbbT7oWMTkaEtYTAU4C8BE37Ec9hGFr2rKXLPpXNEJbF",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358672658,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "32piZoJvedBjncG9Z13Q5uqFDZcHYhQuKFVy9d7KRQ6i6EJ29NNftQyNdfAoygWskbbLH1KVkRb1SFoGQqB1H7T6"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "EXAY7gnEJooXysM56LzFsbC4uE63d1aQ7yWbWZbNDZHG",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358672673,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "2YYMHt4T9Qjq7LEjrQL3pN1ZdMnThyPrJfZsj6tu44GUH93MFgq8LoUzQNim1Cdsc5pJtGhexxBJx9B8VrwqwH71"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "B6rfoSrSM7HdpT3xjqwHuQdhokUz7mywSn6J22WXftZW",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358674001,
            "version": 2,
            "chainId": 84,
            "sender": "3N1zCcy5aEojvD5xNCjuxphHtwycQXr42TP",
            "senderPublicKey": "8Zv7itBufxgv2KeiMV5hoSn63XJraBp48dK3R8tuB5nE",
            "proofs": [
                "35vYjSCEHGXhikyzJdKQKZqNhm3HwCEYRtccSAQVDwjctx1fxPQhgQUZgGVkpxDhniUGbDLToWABCGEaM884RNZ"
            ],
            "dApp": "3N9tKixzqTYWnEXQxrDQ5pBTGvQd6sFsvmV",
            "payment": [
                {
                    "amount": 10000000,
                    "assetId": "AxGKQRxKo4F2EbhrRq6N2tdLsxtMnpzQsS4QemV6V1W1"
                }
            ],
            "call": {
                "function": "registerTask",
                "args": [
                    {
                        "type": "string",
                        "value": "Design a smart contract in the WAVES Ride language that allows token holders to stake a minimum of 10 tokens in a Liquidity Pool. The staked tokens should earn a 10% weekly reward from the total amount staked. The smart contract should include functions for staking tokens, checking rewards, and withdrawing funds. Ensure that the contract enforces the minimum stake requirement and calculates the rewards accurately based on the total amount staked. Generate the smart contract code that implements this staking mechanism."
                    },
                    {
                        "type": "string",
                        "value": "chatgpt"
                    }
                ]
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "AsBGPWCin1Q3uJSTVMct4ShFvNm4tHxSxhzdJ2C8Kp71",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358682689,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "4jfsRgxNVuo8aTKKirnUFosF5LzgvRSzkN5daHzxToA9e9QKDspvNbEx1oFhzxNFY7km9kQxwpoAUwSiv7d9Z8Th"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "HDXnLePpo8fCdHo29g9qgYVcCGrTCg5DB7FHckzh75JA",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358682705,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "4K1zVabo6qo9G4N5BqpW7wLkiCCmoWxzTRxE68D7C8mbKGYPG11UKNjTGrwQYdpyLrKvVsRJFdwBVXumTFfM3wf6"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "Bdbtucy3pnmiw2k8Vkwd2NkC2bGMsun57kByzvjH5PPo",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358684460,
            "version": 2,
            "chainId": 84,
            "sender": "3N9ttyLcRwDo7L4EmJkbS3ZFuQJygivupsL",
            "senderPublicKey": "92ovWCy1Zf8CSsTLLLssC74m8yn5yPMqVp9fmVacou97",
            "proofs": [
                "dPYptSWUr6AzWSG6Lg4EgHazLbTFSf2wAqfCYSbVFUHTje51DVttq4FmYFQDnhPjLSKMTkoehWHyS1LsYteuguw"
            ],
            "dApp": "3N9tKixzqTYWnEXQxrDQ5pBTGvQd6sFsvmV",
            "payment": [],
            "call": {
                "function": "checkoutTask",
                "args": [
                    {
                        "type": "string",
                        "value": "B6rfoSrSM7HdpT3xjqwHuQdhokUz7mywSn6J22WXftZW_8Zv7itBufxgv2KeiMV5hoSn63XJraBp48dK3R8tuB5nE"
                    },
                    {
                        "type": "string",
                        "value": "chatgpt"
                    }
                ]
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "CQ5nxz4GcxYP9RXWsp2C8SyFummJFwxKS32hNqrEPyLK",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358692727,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "5yG9FbHCixRE1BYr5j2c1Xjq8oTqRMErgwsaCQzuEAq5u2oqpw1SRnXBQ6uCPAvhWTviDQ5fFbsSQ4CyVvCdyefR"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "4aByi7frWqh2UyuRU4WxAxMPkwssSsCJV5u6CrNq62aR",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358692740,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "2YiLjyktyuujVr6hAeGDsUFG4FmbpZSnt9LaUERM3zkJdGGr59K4rf9ooeT21P6NizPhWpnVW3BuozaoRDBuWJoh"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "6QwsKtSVh4yxNgHg38C1N94iTusxHveUfnjwL8MpT9n3",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358699253,
            "version": 2,
            "chainId": 84,
            "sender": "3N9ttyLcRwDo7L4EmJkbS3ZFuQJygivupsL",
            "senderPublicKey": "92ovWCy1Zf8CSsTLLLssC74m8yn5yPMqVp9fmVacou97",
            "proofs": [
                "3pT2UDnCWAGovBFzMcX8KdkXC7qMKqBr1FnxFtgHkhyViEzFwRp48Ugm34mu2qNM9QGK5acXkYQaXB7uoXcixr5m"
            ],
            "dApp": "3N9tKixzqTYWnEXQxrDQ5pBTGvQd6sFsvmV",
            "payment": [],
            "call": {
                "function": "commitTask",
                "args": [
                    {
                        "type": "string",
                        "value": "B6rfoSrSM7HdpT3xjqwHuQdhokUz7mywSn6J22WXftZW_8Zv7itBufxgv2KeiMV5hoSn63XJraBp48dK3R8tuB5nE"
                    },
                    {
                        "type": "string",
                        "value": "Certainly! Here's an example of a smart contract in the WAVES Ride language that implements the staking mechanism you described:\n\n```ride\n{-# STDLIB_VERSION 4 #-}\n{-# CONTENT_TYPE DAPP #-}\n{-# SCRIPT_TYPE ACCOUNT #-}\n\n@Callable(i)\nfunc stakeTokens() = {\n    let tokenAmount = extract(tx.bodyBytes, 0, 8)\n    let sender = toBase58String(i.caller.bytes)\n\n    if (isDefined(getInteger(sender))) then\n        let currentStake = getInteger(sender)\n        let newStake = currentStake + tokenAmount\n        putInteger(sender, newStake)\n    else\n        putInteger(sender, tokenAmount)\n\n    nil\n}\n\n@Callable(i)\nfunc checkRewards() = {\n    let sender = toBase58String(i.caller.bytes)\n    let currentStake = getInteger(sender)\n\n    if (currentStake >= 10) then\n        let rewards = currentStake / 10\n        let totalRewards = rewards * 10\n        [IntegerEntry(sender, currentStake - totalRewards), IntegerEntry(sender, rewards)]\n    else\n        throw("Insufficient stake to claim rewards.")\n\n    nil\n}\n\n@Callable(i)\nfunc withdrawFunds() = {\n    let sender = toBase58String(i.caller.bytes)\n    let rewards = getInteger(sender)\n\n    if (rewards > 0) then\n        transferFromContract(i.caller, tokens(rewards))\n        let newRewards = rewards - rewards\n        IntegerEntry(sender, newRewards)\n    else\n        throw("No rewards to withdraw.")\n\n    nil\n}\n```\n\nThis smart contract includes three callables:\n\n1. `stakeTokens` allows token holders to stake their tokens in the Liquidity Pool. It checks if the token holder has already staked tokens, and if so, increases the stake. If not, it creates a new stake entry.\n\n2. `checkRewards` allows token holders to check their available rewards. If the token holder's stake is equal to or greater than 10 tokens, it calculates the rewards as 10% of the stake and returns it. Additionally, it updates the stake to deduct the total rewards claimed.\n\n3. `withdrawFunds` allows token holders to withdraw their rewards from the contract. If they have rewards available, the function transfers the corresponding tokens to the token holder's address and updates the rewards to zero.\n\nEnsure to deploy this smart contract to the WAVES blockchain and interact with it using the appropriate methods and UI design."
                    }
                ]
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "6N4NgkzLGDRdfatzpjwNGgG7QsdRjgJu7EDLCYsfsXZB",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358702758,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "3SLoUDUyjf9KgExQcfAqSMVNQTyc7dfNqcUxbBbVTp6TQwdCG82LtpAySpobw4gDi5VSe3xuo1bQGiUT6XkzPiLU"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "CsspxupgeBHdYqK6NCNv5v4K9LqBZs71xZGnn7yS59xt",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358702774,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "5wFH5ZCGQ8gTPZy5KbvLzsNqDjSZN56XAvasZKyQQY7im6YHcsYHFCRNtdc29pgtu4CwUv7R1KQEg77zQAPk3Jzw"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "73MQtSqcCURtDT78QP2vTotynXnbA4ntKPndtyd5y4WH",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358712791,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "63LxwS3BS9yvskHLGcqbMaUD6GFL63eLJNSaX2jCku4DkmTejBQnmYKvk5dLaWmMvmv8YdTWV9gCC7Mi5zKwK2UQ"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "6V9nMh1aN6wqMMXHKbyMKiwXKUXkbT9ST9vY1JZBu58h",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358712805,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "3jQHFw8fb9puBDC2ipk2GxrxN7rVtEgKSj6TRBcNy1rqECY7FCKUc7Kab5trMPZs4mWmpDiDe8GRn1mT38SVXyng"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "ikcnbYrHsu9Wr2Efj73WAFnF4zBptwd8DZUHLBtW3zk",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358722824,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "4zNtSJDiV6iaKEK6uo7qsdFQC5kyi3SV8qvLdZjPa3MoU6x7NEZYCbXisCvSU4thyTPZ47ycKRm59Yvzi6CyND58"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        },
        {
            "type": 16,
            "id": "FtBGU6LqYfB2Q1Mt4i1jJ8txtby71Qf2WKHvxMAv9t61",
            "fee": 500000,
            "feeAssetId": null,
            "timestamp": 1707358722849,
            "version": 2,
            "chainId": 84,
            "sender": "3MrD3wC4Yds6JgyGthbzArnJDxcSgUCLCvB",
            "senderPublicKey": "J5m6H7xXXwMv5HCXAPBPr71SoChHv7cbrqp7bdnKC9P3",
            "proofs": [
                "2LDJSRejJcM3MKeqeG6dRJJEbJYbzrJ3hmiCr1EkPijwWrtbooxp4wHYJuQJDhxFNR1P9x7mcxEm49GgqDe13yfT"
            ],
            "dApp": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg",
            "payment": [],
            "call": {
                "function": "finalizeVoting",
                "args": []
            },
            "applicationStatus": "succeeded"
        }
    ]
}

github/deemru/w8io/169f3d6 
9.32 ms