Untitled

mail@pastecode.io avatar
unknown
javascript
a month ago
1.1 kB
4
Indexable
Never
var request = require('request');
var options = {
    'method': 'POST',
    'url': 'https://graphql.bitquery.io',
    'headers': {
        'Content-Type': 'application/json',
        'X-API-KEY': '*************'
    },
    body: JSON.stringify({
        "query": "{\n  ethereum(network: bsc_testnet) {\n    smartContractCalls(\n      smartContractAddress: {in: [\"0xdded23f61040c917bf14d50383f55d49d5fffaf5\"]}\n      options: {desc: \"block.timestamp.iso8601\", limit: 1000}\n      date: {after: \"2023-01-01T11:00:00Z\"}\n      smartContractMethod: {is: \"stake\"}\n    ) {\n      block {\n        height\n        timestamp {\n          iso8601\n        }\n      }\n      smartContract {\n        address {\n          address\n        }\n      }\n      smartContractMethod {\n        name\n      }\n      transaction {\n        hash\n        txFrom {\n          address\n        }\n      }\n      arguments {\n        value\n      }\n    }\n  }\n}\n",
        "variables": "{}"
    })

};
request(options, function (error, response) {
    if (error) throw new Error(error);
    console.log(response.body);
});
Leave a Comment