tatumio / tatum-php Goto Github PK
View Code? Open in Web Editor NEWTatum SDK written in PHP
Home Page: https://tatumio.github.io/tatum-php/
License: MIT License
Tatum SDK written in PHP
Home Page: https://tatumio.github.io/tatum-php/
License: MIT License
Fatal error: Uncaught TatumException: You need to set your Network from your .env file! in C:\laragon\www\tatum\vendor\tatumio\tatum-php\src\Tatum.php:57 Stack trace: #0 C:\laragon\www\tatum\vendor\tatumio\tatum-php\src\Tatum.php(42): Tatum\Tatum->InitTatum() #1 C:\laragon\www\tatum\index.php(104): Tatum\Tatum->__construct() #2 [internal function]: {closure}()
$sdk = new \Tatum\Sdk();
$result = $sdk
->mainnet()
->local()->wallet()
->bsc()
->generatePrivateKey('elite tonight holiday hat boil culture second romance parrot pair swamp impose sign valley apart lunar lake tonight song kind divert mango naive chef', 0);
// 4223009e6dffe7accaff161ac1d3df304775b65474eae0da4140dde011e6801c
In fact, the private key recovered by the program is not this, and it is completely inconsistent with the wallet.
Hello dear developers, I have the following problem, I created a subscription to notifications for an address, subscription type "ADDRESS_TRANSACTION", the documentation says that the data is contained in the body of the POST request, but when testing I get an empty webhook. Here is the code of my handler:
<?php
var_dump($_POST);
I'm doing a test webhook through the tatum panel.
As shown in the screenshot, the $_POST variable is empty, please advise how to solve this problem
Describe the bug
Type for return type
\Tatum\Model\EthTx::getBlockNumber()
To Reproduce
Steps to reproduce the behavior:
\Tatum\Api\EthereumApi::ethGetTransactionByAddress()
Environment (please complete the following information):
Describe the bug
chainTransferSolanaSpl currently expects strings with a length of 43 characters when all solana wallets are 44.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
I expect the transaction to go through as intended. The same query works via curl with the 44 character long Solana wallet address.
Environment (please complete the following information):
Additional context
Add any other context about the problem here.
Hey folks, With the amount of watchers/downloads/stars, I believe this project is not a prioity, so, when are you planning to update this lib to support PHP 8?
Thanks!
Describe the bug
Undefined constant "Tatum\Sdk\Psr7\Http\CURL_HTTP_VERSION_2_0"
To Reproduce
mainnet()->config()->setDebug(true); // Account address you want to get balance of $arg_address = "0x3223AEB8404C7525FcAA6C512f91e287AE9FfE7B"; // Type of Ethereum testnet. Defaults to ethereum-sepolia. $arg_x_testnet_type = 'ethereum-sepolia'; try { /** * GET /v3/ethereum/account/balance/{address} * * @var \Tatum\Model\EthBalance $response */ $response = $sdk->mainnet() ->api() ->ethereum() ->ethGetBalance($arg_address, $arg_x_testnet_type); var_dump($response); } catch (\Tatum\Sdk\ApiException $apiExc) { echo sprintf( "API Exception when calling api()->ethereum()->ethGetBalance(): %s\n", var_export($apiExc->getResponseObject(), true) ); } catch (\Exception $exc) { echo sprintf( "Exception when calling api()->ethereum()->ethGetBalance(): %s\n", $exc->getMessage() ); } Environment - OS: Ubuntu 22 - CPU: x64 - PHP Version: 8.2 - Server: Apache **Additional context** Add any other context about the problem here.array:1 [▼
"Exception" => yii\base\ErrorException {#206 ▼
#message: "settype(): Invalid type"
#code: 2
#file: "vendor/tatumio/tatum-php/lib/Sdk/Serializer.php"
#line: 464
#severity: E_WARNING
trace: {▼
vendor/tatumio/tatum-php/lib/Sdk/Serializer.php:464 {▼
yii\base\ErrorHandler->handleError($code, $message, $file, $line) …
› if (in_array($type, ['\DateTime', '\SplFileObject', 'array', 'bool', 'boolean', 'byte', 'float', 'int', 'integer', 'mixed', 'number', 'object', 'string', 'void'], true)) {
› settype($data, $type);
› return $data;
}
yii\base\ErrorHandler->handleError() {}
vendor/tatumio/tatum-php/lib/Sdk/Serializer.php:464 {▼
Tatum\Sdk\Serializer::doDeserialize($data, string $type) …
› if (in_array($type, ['\DateTime', '\SplFileObject', 'array', 'bool', 'boolean', 'byte', 'float', 'int', 'integer', 'mixed', 'number', 'object', 'string', 'void'], true)) {
› settype($data, $type);
› return $data;
arguments: {▼
&$var: 10300651
$type: "mixed"
}
}
vendor/tatumio/tatum-php/lib/Sdk/Serializer.php:502 {▼
Tatum\Sdk\Serializer::doDeserialize($data, string $type) …
› $propertyValue = $data->{$instance::attributeMap()[$property]};
› $instance->$propertySetter(self::doDeserialize($propertyValue, $model_types));
› }
arguments: {▶}
}
vendor/tatumio/tatum-php/lib/Sdk/Serializer.php:419 {▶}
vendor/tatumio/tatum-php/lib/Sdk/Serializer.php:393 {▶}
vendor/tatumio/tatum-php/lib/Api/AbstractApi.php:112 {▶}
vendor/tatumio/tatum-php/lib/Api/EthereumApi.php:487 {▶}
addons/VymToken/backend/controllers/basic/TransactionController.php:48 {▶}
addons\VymToken\backend\controllers\basic\TransactionController->actionRun() {}
vendor/yiisoft/yii2/base/InlineAction.php:57 {▶}
vendor/yiisoft/yii2/base/Controller.php:178 {▶}
vendor/yiisoft/yii2/base/Module.php:552 {▶}
vendor/yiisoft/yii2/web/Application.php:103 {▶}
vendor/yiisoft/yii2/base/Application.php:384 {▶}
web/backend/index.php:35 {▶}
}
}
]
After cloning the repo into a folder I opened the read me to finish the install, upon running the command
"apt-get install php php-gmp php-mbstring php-mcrypt"
I was returned this error .
"Package php-mcrypt is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'php-mcrypt' has no installation candidate"
So is there another program that can accomplish this same thing or perhaps another source?
Describe the bug
\Tatum\Model\TransferEthBlockchain and \Tatum\Model\TransferEthBlockchainKMS require \Tatum\Model\Erc20Currency. But \Tatum\Model\Erc20Currency doesn't have _constructor, getters and setters.
To Reproduce
Steps to reproduce the behavior:
Environment:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.