Update Of PHP Graphene Node Client [v5.1.2 - v5.2.0]

Words
443
Reading
2 min
Listen
Play
8y

php-graphene-node-client

It is PHP API client for VIZ/STEEM/GOLOS/WHALESHARES blockchain

Github or packagist with MIT license. Author t3ran13@t3ran13 and active contributor semasping@semasping

In Release v5.1.2

  • upd VIZ public nodes list
  • fix InitConnector bug for VIZ

In Release v5.1.3

  • VIZ content operation was deleted
  • VIZ custom operation was added

In Release v5.1.3

  • Steem HTTPS nodes was updated in connector
  • Own Classes with operations IDs and fields types was added for each chain
  • New GetTransactionHex command was added (debug your serialized transactions)
  • New BOOL and INT8 types were added for operation fields
  • Beneficiaries serialization was fixeds

upd VIZ public nodes list

Actual list of VIZ nodes are:

fix InitConnector bug for VIZ

It was not working correct before and was fixed. Now you can use InitConnector for convenient simultaneous work with few chains.

$connector = InitConnector::getConnector(ConnectorInterface::PLATFORM_VIZ);

VIZ content operation was deleted

It was deprecated and does not wark in VIZ anymore.

VIZ custom operation was added

It is the same as custom_json in STEEM/GOLOS/WHALESHARES, but in VIZ it has other name

Example of using

$connector = InitConnector::getConnector(ConnectorInterface::PLATFORM_VIZ);
$chainName = $connector->getPlatform();
/** @var CommandQueryData $tx */
$tx = Transaction::init($connector);
$tx->setParamByKey(
    '0:operations:0',
    [
        'custom',
        [
            'required_auths'         => [],
            'required_posting_auths' => ['guest123'],
            'id'                     => 'YOUR_ID',
            'json'                   => json_encode(YOUR_JSON)
        ]
    ]
);
Transaction::sign(
    $chainName,
    $tx,
    [
        'posting' => '5POSTING_KEY', 
    ]
);

$command = new BroadcastTransactionSynchronousCommand($connector);
$answer = $command->execute(
    $tx
);

Steem HTTPS nodes was updated in connector

Actual list of STEEM HTTPS nodes are:

Own Classes with operations IDs and fields types was added for each chain

Each chain has own class with operations IDs and fields types:

  • ChainOperationsGolos.php
  • ChainOperationsSteem.php
  • ChainOperationsViz.php
  • ChainOperationsWhaleshares.php

Thanks of this each chain can has difference in operations from other and it is easy to add this changes.

New GetTransactionHex command was added (debug your serialized transactions)

It is best way for dubag serialiaer with GetTransactionHex api method.
You have to prepare Tx without signature and send it to node and witch back serialized hex string.

$chainName = $connector->getPlatform();
/** @var CommandQueryData $tx */
$tx = Transaction::init($connector);

$tx->setParamByKey(// some data
);

$command = new GetTransactionHexCommand($connector);
$answer = $command->execute(
    $tx
);
echo PHP_EOL . '
'
. print_r($answer, true) . '
'
;

New BOOL and INT8 types were added for operation fields

This types use for serialization Tx. Now it is easy to add some operation with this types.

Beneficiaries serialization was fixeds

It was bug with serialization Tx with 2 and more beneficiaries. It works correct now.


It is better with each commit

Commits were done by me in master branch

  • fix InitConnector bug for VIZ
  • upd VIZ public nodes list
  • upd VIZ new operation
  • upd VIZ operation content is deleted
  • fix VIZ custom operation order
  • ups own operations list for each chain (last 14 days)
  • fix viz and whaleshares operations and new operation for steem, whale and golos (last 14 days)
  • add GetTransactionHex command (last 14 days)
  • add own serializer operations types for each chain (last 14 days)
  • add type BOOL for operation field and fix type beneficiaries (last 14 days)
  • upd https nodes of steem (last 14 days)
  • upd README (last 14 days)

Compare v5.1.1 - v5.2.0

Update Of PHP Graphene Node Client [v5.1.2 - v5.2.0] | Ecency