{"id":15027716,"url":"https://github.com/021-projects/crypto-wallets","last_synced_at":"2025-04-09T20:22:34.618Z","repository":{"id":56894057,"uuid":"452239832","full_name":"021-projects/crypto-wallets","owner":"021-projects","description":"Library for convenient work with cryptocurrency wallets","archived":false,"fork":false,"pushed_at":"2023-03-30T14:30:27.000Z","size":165,"stargazers_count":8,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-23T22:14:20.316Z","etag":null,"topics":["address","bitcoin","blockchain","btc","comfort","crypto","cryptocurrency","cryptowallet","eth","ethereum","ethereum-wallet","ltc","php","php81","provider","wallet","wallets","web3"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/021-projects.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-01-26T10:55:01.000Z","updated_at":"2024-04-30T13:31:49.000Z","dependencies_parsed_at":"2025-02-15T20:33:40.182Z","dependency_job_id":"d11b2540-d4f1-4d18-8515-78a29723f683","html_url":"https://github.com/021-projects/crypto-wallets","commit_stats":null,"previous_names":[],"tags_count":45,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/021-projects%2Fcrypto-wallets","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/021-projects%2Fcrypto-wallets/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/021-projects%2Fcrypto-wallets/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/021-projects%2Fcrypto-wallets/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/021-projects","download_url":"https://codeload.github.com/021-projects/crypto-wallets/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248104784,"owners_count":21048403,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["address","bitcoin","blockchain","btc","comfort","crypto","cryptocurrency","cryptowallet","eth","ethereum","ethereum-wallet","ltc","php","php81","provider","wallet","wallets","web3"],"created_at":"2024-09-24T20:06:56.436Z","updated_at":"2025-04-09T20:22:34.594Z","avatar_url":"https://github.com/021-projects.png","language":"PHP","readme":"# Installation \n\nRun ```composer require 021/crypto-wallets```\n\nAdd repositories to composer.json\n```\n\"repositories\": [\n    {\n        \"type\": \"vcs\",\n        \"url\": \"git@github.com:021-projects/php-bitcoinrpc.git\"\n    }\n]\n```\n\n# Requirements\n\n- PHP 8.1+\n\n# Wallet interface\n\n### \\O21\\CryptoWallets\\Interfaces\\WalletInterface\n  `__construct(\\O21\\CryptoWallets\\Interfaces\\ConnectConfigInterface $config)`\n\n  `isAvailable(): bool` - check is RPC client available\n\n  `getBalance(): string` - get wallet balance\n\n  `getNewAddress($config = null): string` - get new address\n\n  `isValidAddress(string $address): bool` - check is an address is valid\n\n  `isOwningAddress(string $address): bool` - checks if an address belongs to a wallet\n  \n  `getExploreAddressLink(string $address): string` - returns a link to blockchain explorer for the address\n\n  ```\n  getRate(\n        string $currency = 'USD', \n        ?\\O21\\CryptoWallets\\Interfaces\\RateProviderInterface $provider = null\n  ): float\n  // Returns the cryptocurrency exchange rate for the selected currency\n  ```  \n  ```\n  getBestRate(\n      string $currency = 'USD',\n      int $limit = 60,\n      \\O21\\CryptoWallets\\Units\\RateInterval $interval = RateInterval::Minutes,\n      ?\\O21\\CryptoWallets\\Interfaces\\RateProviderInterface $provider = null\n  ): float\n  // Returns the best cryptocurrency rate for the selected currency for a given period of time\n  ```\n  ```\n  estimateSendingFee(\n      string $to,\n      string $value,\n      \\O21\\CryptoWallets\\Interfaces\\FeeInterface|string $fee\n  ): string\n  // Estimates the fee amount required to send a transaction\n  ```\n  ```\n  send(\n      string $to,\n      string $value,\n      \\O21\\CryptoWallets\\Interfaces\\FeeInterface|string $fee\n  ): string\n  // Send funds from a wallet\n  ```\n  `getTransaction(string $hash): ?\\O21\\CryptoWallets\\Interfaces\\TransactionInterface` - returns transaction from a wallet\n  \n  `getTransactions(int $count = 50, int $skip = 0): \\Illuminate\\Support\\Collection;` - returns transactions from a wallet\n\n  `getTransactionsSinceBlock(string $block = ''): \\Illuminate\\Support\\Collection;` - returns transactions from a wallet\n  \n  `getTransactionsCount(): int` - returns transactions count on a wallet\n  \n  `getExploreTransactionLink(string $hash): string` - returns a link to blockchain explorer for the address\n\n  ```\n  /**\n   * @return \\Illuminate\\Support\\Collection\u003c\\O21\\CryptoWallets\\Interfaces\\FeeInterface\u003e\n   */\n  public function getNetworkFees(): Collection;\n  // Returns the recommended fees for the transaction\n  ```\n\n  `getDefaultBestRateLimit(): int` - returns the default value for the period in the `getBestRate` function\n\n  `getTypicalTransactionSize(): int` - returns typical transaction size for a wallet\n\n  `getSymbol(): string` - returns symbol of a wallet \n\nAlso, some wallets have their own unique methods. Explore the interfaces `\\O21\\CryptoWallets\\Interfaces\\BitcoindWalletInterface` and `\\O21\\CryptoWallets\\Interfaces\\EthereumWalletInterface`\n\n## Currently available wallets\n\n`\\O21\\CryptoWallets\\BitcoinWallet` for bitcoin\n\n`\\O21\\CryptoWallets\\LitecoinWallet` for litecoin\n\n`\\O21\\CryptoWallets\\EthereumWallet` for ethereum","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F021-projects%2Fcrypto-wallets","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F021-projects%2Fcrypto-wallets","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F021-projects%2Fcrypto-wallets/lists"}