PHP Steem Tools - An Open Source Library For The Steem Blockchain (Updated Method for this tool)
Repository
https://github.com/dragosroua/php-steem-tools
What is the project about?
I was thinking of developing a PHP library for steem to use for a personal project of mine but then decided to check if something of such already exist. Fortunately, i found PHP-Steem Tool. This tool is an open source PHP library built by and is currently used as a tool for building steem.supply
Checkout his post for more info
According to the project owner, PHP Steem Tools wants to be a wrapper on top of a few APIs, including, but not limited to the Steem blockchain API.
Currently, it is packaged as a composer module and it has the following features:
- alternative transport: cURL / websocket
- get user JSON data
- get current prices for Steem / SBD from coinmarketcap.com
- converts vests to Steem Power
- access the following endpoints:
-- get_discussions_by_author_before_date,
-- get_replies_by_last_update,
-- get_current_median_history_price
-- get_content
-- get_content_replies
-- get_discussions_by_comments
-- get_account_votes
-- get_account_history
-- get_followers
-- lookup_accounts
-- get_accounts
-- get_api_by_name
-- get_dynamic_global_properties
Update
While making use of this tool, i noticed over 80% of steemjs api methods are not included and this is quiet understandable because according to the project owner
I decided to open source parts of the code I used when I created steem.supply, namely the formalizable parts, in an Open Source library called PHP Steem Tools.
Methods available in this tool were methods only used by the project owner in creating steem.supply. So i decided to update this tool and making it a more complete library by adding all available API Methods on api.steemjs.com
How i implement this?
All API methods were from api.steemjs.com
// Contributions by @profchydon
+ // Getting this tool up to date with all available methods on api.steemjs documentation
+
+ public function setSubscribeCallback ($params)
+ {
+ $result = $this->SteemLayer->call('set_subscribe_callback', $params);
+ return $result;
+ }
+
+ public function setPendingTransactionCallback ($params)
+ {
+ $result = $this->SteemLayer->call('set_pending_transaction_callback', $params);
+ return $result;
+ }
+
+ public function setBlockAppliedCallback ($params)
+ {
+ $result = $this->SteemLayer->call('set_block_applied_callback', $params);
+ return $result;
+ }
+
+ public function cancelAllSubscriptions ($params)
+ {
+ $result = $this->SteemLayer->call('cancel_all_subscriptions', $params);
+ return $result;
+ }
+