SteemTools Update: Account Profile Lookup + Steem Blockchain Information


SteemTools is a Chrome Extension that aims to provide useful tools and data for SteemIt Users.

Features of SteemTools

  • Steem BlockChain Information
  • Steem Users Account Information
  • Steem Nodes Information
  • Steem Delegators
  • Steem Delegatees
  • Steem Downvoters
  • Steem Js Console
  • Steem Witness Lookup
  • Reveal Steem Deleted Comments
  • Steem Powerdown Lookup
  • Send SBD/Steem to Multiple Receipents
  • Reputation Calculator
  • API/Steem Server Ping Tests

SteemTools Open Source

Github: https://github.com/DoctorLai/SteemTools/

Previous Versions

Technology Stack

Javascript that runs in the Chrome Browser (Chrome Extension)

New Features of SteemTools v0.0.11

This commit adds the following changes:

  • Account Profile Lookup
  • Steem Blockchain Information
  • Bug fixes

SteemTools Screenshots

steemtools-account-profile-lookup SteemTools Update: Account Profile Lookup + Steem Blockchain Information chrome extension javascript SteemIt

steemtools-account-profile-lookup

steemtools-blockchain-information SteemTools Update: Account Profile Lookup + Steem Blockchain Information chrome extension javascript SteemIt

steemtools-blockchain-information

SteemTools API

The API used can be found here.

Roadmap of Steem Tools

Javascript: SteemIt Account Profile Lookup

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
// profile API
const handleProfile = (dom, input, btn) => {
    textPressEnterButtonClick(input, btn);
    let server = getServer();        
    server = server || default_server;
    let id = prepareId($(input).val());
    dom.html('<img src="images/loading.gif"/>');
    btn.attr("disabled", true);
    $.ajax({ 
        dataType: "json",
        url: "https://" + server + "/api/steemit/account/profile/?cached&id=" + id,
        cache: false,
        error: function(request, status, error) {
            dom.html('<font color=red>API/SteemSQL Server (' + server + error + ') is currently offline. Please try again later!' + request.responseText + '</font>');
        },          
        complete: function(data) {
            // re-enable the button
            btn.attr("disabled", false);
        },
        success: function (response) {
            let result = response;
            if (result) {
                let s = '';
                s += '<table>';
                s += '<thead><tr><th style="width:30%">Key</th><th>Value</th></tr></thead><tbody>';
 
                const addKeyValue = (result, x) => {
                    return "<tr><td>" + x + "</td><td>" + result[x] + "</td></tr>";
                }
 
                s += addKeyValue(result, "id");
                s += addKeyValue(result, "created");
                s += addKeyValue(result, "last_vote_time");
                s += addKeyValue(result, "steem");
                s += addKeyValue(result, "rep");
                s += addKeyValue(result, "online");
                s += addKeyValue(result, "vests");
                s += addKeyValue(result, "sbd");
                s += addKeyValue(result, "value");
                s += addKeyValue(result, "vp");
                s += "<tr><td>received_sp</td><td>" + result['esp']['received_sp'] + "</td></tr>";
                s += "<tr><td>delegated_vesting_shares</td><td>" + result['esp']['delegated_vesting_shares'] + "</td></tr>";
                s += "<tr><td>effective_vesting_shares</td><td>" + result['esp']['effective_vesting_shares'] + "</td></tr>";
                s += "<tr><td>vesting_shares</td><td>" + result['esp']['vesting_shares'] + "</td></tr>";
                s += "<tr><td>received_vesting_shares</td><td>" + result['esp']['received_vesting_shares'] + "</td></tr>";
                s += "<tr><td>vesting_sp</td><td>" + result['esp']['vesting_sp'] + "</td></tr>";
                s += "<tr><td>esp</td><td>" + result['esp']['esp'] + "</td></tr>";
                s += "<tr><td>delegated_sp</td><td>" + result['esp']['delegated_sp'] + "</td></tr>";
                s += '</tbody>';
                s += '</table>';
                dom.html(s);                          
            } else {
                dom.html('');
            }      
        }           
    });
}
// profile API
const handleProfile = (dom, input, btn) => {
    textPressEnterButtonClick(input, btn);
    let server = getServer();        
    server = server || default_server;
    let id = prepareId($(input).val());
    dom.html('<img src="images/loading.gif"/>');
    btn.attr("disabled", true);
    $.ajax({ 
        dataType: "json",
        url: "https://" + server + "/api/steemit/account/profile/?cached&id=" + id,
        cache: false,
        error: function(request, status, error) {
            dom.html('<font color=red>API/SteemSQL Server (' + server + error + ') is currently offline. Please try again later!' + request.responseText + '</font>');
        },          
        complete: function(data) {
            // re-enable the button
            btn.attr("disabled", false);
        },
        success: function (response) {
            let result = response;
            if (result) {
                let s = '';
                s += '<table>';
                s += '<thead><tr><th style="width:30%">Key</th><th>Value</th></tr></thead><tbody>';

                const addKeyValue = (result, x) => {
                    return "<tr><td>" + x + "</td><td>" + result[x] + "</td></tr>";
                }

                s += addKeyValue(result, "id");
                s += addKeyValue(result, "created");
                s += addKeyValue(result, "last_vote_time");
                s += addKeyValue(result, "steem");
                s += addKeyValue(result, "rep");
                s += addKeyValue(result, "online");
                s += addKeyValue(result, "vests");
                s += addKeyValue(result, "sbd");
                s += addKeyValue(result, "value");
                s += addKeyValue(result, "vp");
                s += "<tr><td>received_sp</td><td>" + result['esp']['received_sp'] + "</td></tr>";
                s += "<tr><td>delegated_vesting_shares</td><td>" + result['esp']['delegated_vesting_shares'] + "</td></tr>";
                s += "<tr><td>effective_vesting_shares</td><td>" + result['esp']['effective_vesting_shares'] + "</td></tr>";
                s += "<tr><td>vesting_shares</td><td>" + result['esp']['vesting_shares'] + "</td></tr>";
                s += "<tr><td>received_vesting_shares</td><td>" + result['esp']['received_vesting_shares'] + "</td></tr>";
                s += "<tr><td>vesting_sp</td><td>" + result['esp']['vesting_sp'] + "</td></tr>";
                s += "<tr><td>esp</td><td>" + result['esp']['esp'] + "</td></tr>";
                s += "<tr><td>delegated_sp</td><td>" + result['esp']['delegated_sp'] + "</td></tr>";
                s += '</tbody>';
                s += '</table>';
                dom.html(s);                          
            } else {
                dom.html('');
            }      
        }           
    });
}

Javascript: Steem Blockchain Information

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
// steem blockchain information
const getInfor = (dom) => {
    let server = getServer();        
    server = server || default_server;
    dom.html('<img src="images/loading.gif"/>');
    $.ajax({ 
        dataType: "json",
        url: "https://" + server + "/api/steemit/info/",
        cache: false,
        success: function (response) {
            let result = response;
            if (result) {
                let s = '';
                s += '<table>';
                s += '<thead><tr><th style="width:30%">Key</th><th>Value</th></tr></thead><tbody>';
 
                const addKeyValue = (result, x) => {
                    return "<tr><td>" + x + "</td><td>" + result[x] + "</td></tr>";
                }
 
                s += addKeyValue(result, "account_num");
                s += addKeyValue(result, "time");
                s += addKeyValue(result, "last_irreversible_block_num");
                s += addKeyValue(result, "head_block_number");
                s += addKeyValue(result, "hardfork_version");
                s += addKeyValue(result, "market_price");
                s += addKeyValue(result, "feed_price");
                s += "<tr><td>blockchain_version</td><td>" + result['version']['blockchain_version'] + "</td></tr>";
                s += "<tr><td>steem_revision</td><td>" + result['version']['steem_revision'] + "</td></tr>";
                s += "<tr><td>fc_revision</td><td>" + result['version']['fc_revision'] + "</td></tr>";
                s += '</tbody>';
                s += '</table>';
                dom.html(s);                          
            } else {
                dom.html('');
            }      
        }           
    });
}
// steem blockchain information
const getInfor = (dom) => {
    let server = getServer();        
    server = server || default_server;
    dom.html('<img src="images/loading.gif"/>');
    $.ajax({ 
        dataType: "json",
        url: "https://" + server + "/api/steemit/info/",
        cache: false,
        success: function (response) {
            let result = response;
            if (result) {
                let s = '';
                s += '<table>';
                s += '<thead><tr><th style="width:30%">Key</th><th>Value</th></tr></thead><tbody>';

                const addKeyValue = (result, x) => {
                    return "<tr><td>" + x + "</td><td>" + result[x] + "</td></tr>";
                }

                s += addKeyValue(result, "account_num");
                s += addKeyValue(result, "time");
                s += addKeyValue(result, "last_irreversible_block_num");
                s += addKeyValue(result, "head_block_number");
                s += addKeyValue(result, "hardfork_version");
                s += addKeyValue(result, "market_price");
                s += addKeyValue(result, "feed_price");
                s += "<tr><td>blockchain_version</td><td>" + result['version']['blockchain_version'] + "</td></tr>";
                s += "<tr><td>steem_revision</td><td>" + result['version']['steem_revision'] + "</td></tr>";
                s += "<tr><td>fc_revision</td><td>" + result['version']['fc_revision'] + "</td></tr>";
                s += '</tbody>';
                s += '</table>';
                dom.html(s);                          
            } else {
                dom.html('');
            }      
        }           
    });
}

License

MIT

Chrome Webstore

Install the SteemTools Chrome Extension Now!

Contribution Welcome

Github: https://github.com/DoctorLai/SteemTools

  • Fork it!
  • Create your feature branch: git checkout -b my-new-feature
  • Commit your changes: git commit -am ‘Add some feature’
  • Push to the branch: git push origin my-new-feature
  • Submit a pull request.

–EOF (The Ultimate Computing & Technology Blog) —

GD Star Rating
loading...
1585 words
Last Post: Steem Blockchain Information: API, Discord and Wechat!
Next Post: Data Structures and Algorithms Series - Majority Number (Boyer–Moore majority vote algorithm)

The Permanent URL is: SteemTools Update: Account Profile Lookup + Steem Blockchain Information

Leave a Reply