{"_id":"@bagsfm/react-native-helius-sdk","_rev":"6-525ebd075f34a594ad62330abddf8a58","name":"@bagsfm/react-native-helius-sdk","dist-tags":{"latest":"1.0.4"},"versions":{"1.0.0":{"name":"@bagsfm/react-native-helius-sdk","version":"1.0.0","keywords":["helius","solana","web3","crypto","api","sdk","react-native","mobile"],"author":{"name":"ramyodev"},"license":"ISC","_id":"@bagsfm/react-native-helius-sdk@1.0.0","maintainers":[{"name":"ramyobags","email":"ramyo@bags.fm"}],"homepage":"https://github.com/ramyodev/react-native-helius-sdk#readme","bugs":{"url":"https://github.com/ramyodev/react-native-helius-sdk/issues"},"dist":{"shasum":"e9512c6ba66671d4b4a31d0959ddb0061c411069","tarball":"https://registry.npmjs.org/@bagsfm/react-native-helius-sdk/-/react-native-helius-sdk-1.0.0.tgz","fileCount":32,"integrity":"sha512-xs/8Aqc1DjeMfgHHqwScLnt20CkdLv0bjc2lvwHPo6b2DyD+hEuCIjbhtstT3ZM96pHhKerq6c80pC/hxiYHEA==","signatures":[{"sig":"MEUCIC5kajx4bndetL5wDR4nizLquX+4wSc6pHF50wL1PfnrAiEAmukcs/YzxyRa+CxqAGyup0vXt/UxR4uwxCPQuQpb/xo=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":207271},"main":"dist/src/index.js","types":"dist/src/index.d.ts","gitHead":"d2af46a6ce7a0bddd76fc838b3493ba88a44d1b5","scripts":{"lint":"eslint \"{src,tests}/**/*.{js,ts}\"","test":"jest","build":"tsc","format":"prettier --write 'src/**/*.{js,ts,json,md}'","prepare":"npm run build","test:watch":"jest --watch","test:coverage":"jest --coverage"},"_npmUser":{"name":"ramyobags","email":"ramyo@bags.fm"},"repository":{"url":"git+https://github.com/ramyodev/react-native-helius-sdk.git","type":"git"},"_npmVersion":"10.8.3","description":"React Native SDK for the Helius API (https://helius.xyz)","directories":{},"_nodeVersion":"20.13.1","dependencies":{"bs58":"^6.0.0","axios":"^1.2.3","@metaplex-foundation/mpl-token-metadata":"^2.5.2"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.7.0","jsdoc":"^4.0.0","eslint":"^8.0.0","ts-jest":"^29.1.2","ts-node":"^10.9.2","prettier":"^3.3.2","typescript":"^4.9.4","@types/bs58":"^4.0.4","@types/jest":"^29.5.12","@types/axios":"^0.14.0","@solana/web3.js":"^1.73.2","eslint-plugin-import":"^2.29.1","eslint-config-prettier":"^9.1.0","eslint-plugin-prettier":"^5.1.3","@typescript-eslint/parser":"^3.9.0","eslint-config-airbnb-base":"^14.2.0","@typescript-eslint/eslint-plugin":"^3.9.0"},"peerDependencies":{"react-native":">=0.60.0"},"_npmOperationalInternal":{"tmp":"tmp/react-native-helius-sdk_1.0.0_1729789566890_0.5951255553714923","host":"s3://npm-registry-packages"}},"1.0.1":{"name":"@bagsfm/react-native-helius-sdk","version":"1.0.1","keywords":["helius","solana","web3","crypto","api","sdk","react-native","mobile"],"author":{"name":"ramyodev"},"license":"ISC","_id":"@bagsfm/react-native-helius-sdk@1.0.1","maintainers":[{"name":"ramyobags","email":"ramyo@bags.fm"}],"homepage":"https://github.com/ramyodev/react-native-helius-sdk#readme","bugs":{"url":"https://github.com/ramyodev/react-native-helius-sdk/issues"},"dist":{"shasum":"7efa53e3473b3e878b24e258da133ac3a72fa2bb","tarball":"https://registry.npmjs.org/@bagsfm/react-native-helius-sdk/-/react-native-helius-sdk-1.0.1.tgz","fileCount":32,"integrity":"sha512-T2DlNk2c5GFelhConxzZiiyPpeGX/A9ZHBQ3VPXrJXH2pXe5phRlefhLNGL4iV6pjQVJbUkzUK0ypXSbKXGW7A==","signatures":[{"sig":"MEQCIAKiDFjHaggCEhCGrg71BZpAL4EDPXZXX9GtgyHuNQ1WAiB8Xmhf7xULBcwqmNHenJLzhsTYASsDKyuPVcRfH86Qyg==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":207661},"main":"dist/src/index.js","types":"dist/src/index.d.ts","gitHead":"901004ca07053305941894810063d3a0b26f90d3","scripts":{"lint":"eslint \"{src,tests}/**/*.{js,ts}\"","test":"jest","build":"tsc","format":"prettier --write 'src/**/*.{js,ts,json,md}'","prepare":"npm run build","test:watch":"jest --watch","test:coverage":"jest --coverage"},"_npmUser":{"name":"ramyobags","email":"ramyo@bags.fm"},"repository":{"url":"git+https://github.com/ramyodev/react-native-helius-sdk.git","type":"git"},"_npmVersion":"10.8.3","description":"React Native SDK for the Helius API (https://helius.xyz)","directories":{},"_nodeVersion":"20.13.1","dependencies":{"bs58":"^6.0.0","axios":"^1.2.3","@metaplex-foundation/mpl-token-metadata":"^2.5.2"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.7.0","jsdoc":"^4.0.0","eslint":"^8.0.0","ts-jest":"^29.1.2","ts-node":"^10.9.2","prettier":"^3.3.2","typescript":"^4.9.4","@types/bs58":"^4.0.4","@types/jest":"^29.5.12","@types/axios":"^0.14.0","@solana/web3.js":"^1.73.2","eslint-plugin-import":"^2.29.1","eslint-config-prettier":"^9.1.0","eslint-plugin-prettier":"^5.1.3","@typescript-eslint/parser":"^3.9.0","eslint-config-airbnb-base":"^14.2.0","@typescript-eslint/eslint-plugin":"^3.9.0"},"peerDependencies":{"react-native":">=0.60.0"},"_npmOperationalInternal":{"tmp":"tmp/react-native-helius-sdk_1.0.1_1729834780115_0.0024620663827736866","host":"s3://npm-registry-packages"}},"1.0.2":{"name":"@bagsfm/react-native-helius-sdk","version":"1.0.2","keywords":["helius","solana","web3","crypto","api","sdk","react-native","mobile"],"author":{"name":"ramyodev"},"license":"ISC","_id":"@bagsfm/react-native-helius-sdk@1.0.2","maintainers":[{"name":"ramyobags","email":"ramyo@bags.fm"}],"homepage":"https://github.com/ramyodev/react-native-helius-sdk#readme","bugs":{"url":"https://github.com/ramyodev/react-native-helius-sdk/issues"},"dist":{"shasum":"4ff1f51b3ae0ff218fcfeb517f39eab2d14c8637","tarball":"https://registry.npmjs.org/@bagsfm/react-native-helius-sdk/-/react-native-helius-sdk-1.0.2.tgz","fileCount":32,"integrity":"sha512-2i1w+3liHFP1drpCjIGacT7pTyQDcXlTudJNGKzRjWnJou/r6bxzeG2LoBQaQqLJMPkbnYuJe2o0nrU7z+13kg==","signatures":[{"sig":"MEYCIQD7F85UD5T2i9gDd7+BnaKyUOuj6sht4DT61t7jkfhdhgIhAJY9qYgT+fYrOGtyaX7jt0LfhRMfUUGyxMHLDJG4Vn6H","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":207720},"main":"dist/src/index.js","types":"dist/src/index.d.ts","gitHead":"2dbd1fb894fb0e42ba0c23f84b4399db2188fbab","scripts":{"lint":"eslint \"{src,tests}/**/*.{js,ts}\"","test":"jest","build":"tsc","format":"prettier --write 'src/**/*.{js,ts,json,md}'","prepare":"npm run build","test:watch":"jest --watch","test:coverage":"jest --coverage"},"_npmUser":{"name":"ramyobags","email":"ramyo@bags.fm"},"repository":{"url":"git+https://github.com/ramyodev/react-native-helius-sdk.git","type":"git"},"_npmVersion":"10.8.3","description":"React Native SDK for the Helius API (https://helius.xyz)","directories":{},"_nodeVersion":"20.13.1","dependencies":{"bs58":"^6.0.0","axios":"^1.2.3","@metaplex-foundation/mpl-token-metadata":"^2.5.2"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.7.0","jsdoc":"^4.0.0","eslint":"^8.0.0","ts-jest":"^29.1.2","ts-node":"^10.9.2","prettier":"^3.3.2","typescript":"^4.9.4","@types/bs58":"^4.0.4","@types/jest":"^29.5.12","@types/axios":"^0.14.0","@solana/web3.js":"^1.73.2","eslint-plugin-import":"^2.29.1","eslint-config-prettier":"^9.1.0","eslint-plugin-prettier":"^5.1.3","@typescript-eslint/parser":"^3.9.0","eslint-config-airbnb-base":"^14.2.0","@typescript-eslint/eslint-plugin":"^3.9.0"},"peerDependencies":{"react-native":">=0.60.0"},"_npmOperationalInternal":{"tmp":"tmp/react-native-helius-sdk_1.0.2_1729835482196_0.4264245478686237","host":"s3://npm-registry-packages"}},"1.0.3":{"name":"@bagsfm/react-native-helius-sdk","version":"1.0.3","keywords":["helius","solana","web3","crypto","api","sdk","react-native","mobile"],"author":{"name":"ramyodev"},"license":"ISC","_id":"@bagsfm/react-native-helius-sdk@1.0.3","maintainers":[{"name":"ramyobags","email":"ramyo@bags.fm"}],"homepage":"https://github.com/ramyodev/react-native-helius-sdk#readme","bugs":{"url":"https://github.com/ramyodev/react-native-helius-sdk/issues"},"dist":{"shasum":"40497f72e24b2ccad9a596006637e7463501eecc","tarball":"https://registry.npmjs.org/@bagsfm/react-native-helius-sdk/-/react-native-helius-sdk-1.0.3.tgz","fileCount":32,"integrity":"sha512-pUcbf6avp1gEs7T6PJwlTBM2+ARTlIhl4biIjKKLDP5oVnKlq4hOpOvmqDsDDDpGchsC7kuIXj1y+rDdZ/8rTw==","signatures":[{"sig":"MEQCIHp2wO8V7WfGR8poNJ7w7CIHTj4BeyHAuSbAysZlMCesAiBMYNcO34kzT0VnnwKPAazwuwfWyuljS/GXK3sHbIkLjg==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":207794},"main":"dist/src/index.js","types":"dist/src/index.d.ts","gitHead":"7f42d8914fa13c21df9096ef96090c4da524c1dc","scripts":{"lint":"eslint \"{src,tests}/**/*.{js,ts}\"","test":"jest","build":"tsc","format":"prettier --write 'src/**/*.{js,ts,json,md}'","prepare":"npm run build","test:watch":"jest --watch","test:coverage":"jest --coverage"},"_npmUser":{"name":"ramyobags","email":"ramyo@bags.fm"},"repository":{"url":"git+https://github.com/ramyodev/react-native-helius-sdk.git","type":"git"},"_npmVersion":"10.8.3","description":"React Native SDK for the Helius API (https://helius.xyz)","directories":{},"_nodeVersion":"20.13.1","dependencies":{"bs58":"^6.0.0","axios":"^1.2.3","@metaplex-foundation/mpl-token-metadata":"^2.5.2"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.7.0","jsdoc":"^4.0.0","eslint":"^8.0.0","ts-jest":"^29.1.2","ts-node":"^10.9.2","prettier":"^3.3.2","typescript":"^4.9.4","@types/bs58":"^4.0.4","@types/jest":"^29.5.12","@types/axios":"^0.14.0","@solana/web3.js":"^1.73.2","eslint-plugin-import":"^2.29.1","eslint-config-prettier":"^9.1.0","eslint-plugin-prettier":"^5.1.3","@typescript-eslint/parser":"^3.9.0","eslint-config-airbnb-base":"^14.2.0","@typescript-eslint/eslint-plugin":"^3.9.0"},"peerDependencies":{"react-native":">=0.60.0"},"_npmOperationalInternal":{"tmp":"tmp/react-native-helius-sdk_1.0.3_1729836607744_0.08090454588604512","host":"s3://npm-registry-packages"}},"1.0.4":{"name":"@bagsfm/react-native-helius-sdk","version":"1.0.4","keywords":["helius","solana","web3","crypto","api","sdk","react-native","mobile"],"author":{"name":"ramyodev"},"license":"ISC","_id":"@bagsfm/react-native-helius-sdk@1.0.4","maintainers":[{"name":"ramyobags","email":"ramyo@bags.fm"}],"homepage":"https://github.com/ramyodev/react-native-helius-sdk#readme","bugs":{"url":"https://github.com/ramyodev/react-native-helius-sdk/issues"},"dist":{"shasum":"f2f608d2bb5a5d8c836d8e39b5f355516cf315a4","tarball":"https://registry.npmjs.org/@bagsfm/react-native-helius-sdk/-/react-native-helius-sdk-1.0.4.tgz","fileCount":32,"integrity":"sha512-NicNSgbCA01cfSM+WPp7F/unr1lEr9ercEBWH4u6DYQ7DgRO03vO2f4ZGuF8BDFSslX+mVR3U+SQ39FaHCq92w==","signatures":[{"sig":"MEYCIQDCn+8bi5VLxic5U7ElHaqUozl/qbSTx6b7ONQBySaaEAIhAOWkFFw+U9PwSCmag+F58iTiEzm+TI3Mqm8wV6kFgm/7","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":208219},"main":"dist/src/index.js","types":"dist/src/index.d.ts","gitHead":"6bfc8f4512d3b5b08cddfb9eedaf5b75ed217628","scripts":{"lint":"eslint \"{src,tests}/**/*.{js,ts}\"","test":"jest","build":"tsc","format":"prettier --write 'src/**/*.{js,ts,json,md}'","prepare":"npm run build","test:watch":"jest --watch","test:coverage":"jest --coverage"},"_npmUser":{"name":"ramyobags","email":"ramyo@bags.fm"},"repository":{"url":"git+https://github.com/ramyodev/react-native-helius-sdk.git","type":"git"},"_npmVersion":"10.8.3","description":"React Native SDK for the Helius API (https://helius.xyz)","directories":{},"_nodeVersion":"20.13.1","dependencies":{"bs58":"^6.0.0","axios":"^1.2.3","@metaplex-foundation/mpl-token-metadata":"^2.5.2"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^29.7.0","jsdoc":"^4.0.0","eslint":"^8.0.0","ts-jest":"^29.1.2","ts-node":"^10.9.2","prettier":"^3.3.2","typescript":"^4.9.4","@types/bs58":"^4.0.4","@types/jest":"^29.5.12","@types/axios":"^0.14.0","@solana/web3.js":"^1.73.2","eslint-plugin-import":"^2.29.1","eslint-config-prettier":"^9.1.0","eslint-plugin-prettier":"^5.1.3","@typescript-eslint/parser":"^3.9.0","eslint-config-airbnb-base":"^14.2.0","@typescript-eslint/eslint-plugin":"^3.9.0"},"peerDependencies":{"react-native":">=0.60.0"},"_npmOperationalInternal":{"tmp":"tmp/react-native-helius-sdk_1.0.4_1729837245093_0.9698463019054142","host":"s3://npm-registry-packages"}}},"time":{"created":"2024-10-24T17:06:06.767Z","modified":"2025-08-02T18:33:59.400Z","1.0.0":"2024-10-24T17:06:07.145Z","1.0.1":"2024-10-25T05:39:40.321Z","1.0.2":"2024-10-25T05:51:22.378Z","1.0.3":"2024-10-25T06:10:07.959Z","1.0.4":"2024-10-25T06:20:45.364Z"},"bugs":{"url":"https://github.com/ramyodev/react-native-helius-sdk/issues"},"author":{"name":"ramyodev"},"license":"ISC","homepage":"https://github.com/ramyodev/react-native-helius-sdk#readme","keywords":["helius","solana","web3","crypto","api","sdk","react-native","mobile"],"repository":{"url":"git+https://github.com/ramyodev/react-native-helius-sdk.git","type":"git"},"description":"React Native SDK for the Helius API (https://helius.xyz)","maintainers":[{"email":"ramyo@bags.fm","name":"ramyobags"},{"email":"alaa@bags.fm","name":"alaabags"}],"readme":"# Helius Node.js SDK\n\n[![Version](https://img.shields.io/npm/v/helius-sdk)](https://www.npmjs.org/package/helius-sdk)\n![Downloads](https://img.shields.io/npm/dm/react-native-helius-sdk)\n\nThe Helius Node.js library provides access to the Helius API from JavaScript/TypeScript.\n\n## Documentation\n\nAPI reference documentation is available at [docs.helius.dev](https://docs.helius.dev).\n\n## Installation\n\nUsing npm:\n\n```shell\nnpm install helius-sdk\n```\n\nUsing yarn:\n\n```shell\nyarn add helius-sdk\n```\n\n## Usage\n\nThe package needs to be configured with your account's API key, which is available in the [Helius Dashboard](https://dev.helius.xyz/dashboard/app). \n```js \nimport { Helius } from \"helius-sdk\";\n\n// Replace YOUR_API_KEY with the API key from your Helius dashboard\nconst helius = new Helius(\"YOUR_API_KEY\"); \n\nconst getAssetsByOwner = async () => {\n  const response = await helius.rpc.getAssetsByOwner({\n    ownerAddress: \"86xCnPeV69n6t3DnyGvkKobf9FdN2H9oiVDdaMpo2MMY\",\n    page: 1,\n  });\n  console.log(response.items);\n}\n\ngetAssetsByOwner();\n```\n\n[![Try it out](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/edit/helius-node-js-sdk-xbw7t6?file=index.js)\n\n## Handling errors\n\nWhen the API returns a non-success status code (4xx or 5xx response), an error message will be thrown:\n\n```ts\ntry {\n  const response = await helius.rpc.getAssetsByOwner({\n    ownerAddress: \"86xCnPeV69n6t3DnyGvkKobf9FdN2H9oiVDdaMpo2MMY\",\n    page: 1,\n  });\n  console.log(response.items);\n} catch (error) {\n  console.log(error);\n}\n```\n\n### Common Error Codes\n\nWhen working with the Helius SDK, you may encounter several error codes. Below is a table detailing some of the common error codes along with additional information to help you troubleshoot:\n\n| Error Code | Error Message         | More Information                                                                                       |\n| ---------- | --------------------- | ------------------------------------------------------------------------------------------------------ |\n| 401        | Unauthorized          | This occurs when an invalid API key is provided or access is restricted due to RPC rules.              |\n| 429        | Too Many Requests     | This indicates that the user has exceeded the request limit in a given timeframe or is out of credits. |\n| 5XX        | Internal Server Error | This is a generic error message for server-side issues. Please contact Helius support for assistance.  |\n\nIf you encounter any of these errors, refer to the Helius documentation for further guidance, or reach out to the Helius support team for more detailed assistance.\n\n## Using the Helius SDK\n\nOur SDK is designed to give you a seamless experience when building on Solana. We've separated the core functionality into various segments.\n\n[**DAS API**](#das-api-digital-asset-standard)\n\nComprehensive and performant API for tokens, NFTs, and compressed NFTs on Solana.\n\n  - [`getAsset()`](#getAsset): Get an asset by its ID.\n  - [`getAssetBatch()`](#getAssetBatch): Get multiple assets by ID (up to 1k).\n  - [`getSignaturesForAsset()`](#getSignaturesForAsset): Get a list of transaction signatures related to a compressed asset.\n  - [`searchAssets()`](#searchAssets): Search for assets by a variety of parameters. Very useful for token-gating!\n  - [`getAssetProof()`](#getAssetProof): Get a Merkle proof for a compressed asset by its ID.\n  - [`getAssetsByOwner()`](#getAssetsByOwner): Get a list of assets owned by an address. This is the fastest way to get all the NFTs and fungible tokens that are owned by a wallet on Solana.\n  - [`getAssetsByGroup()`](#getAssetsByGroup): Get a list of assets by a group key and value. This endpoint is very useful for getting the mint list for NFT Collections.\n  - [`getAssetsByCreator()`](#getAssetsByCreator): Get a list of assets created by an address.\n  - [`getAssetsByAuthority()`](#getAssetsByAuthority): Get a list of assets with a specific authority.\n  - [`getTokenAccounts()`](#getTokenAccounts): Get information about all token accounts for a specific mint or a specific owner.\n  - [`getNftEditions()`](#getNftEditions): Get information about all the edition NFTs for a specific master NFT\n\n[**Mint API**](#mint-api)\n\nThe easiest way to mint compressed NFTs at scale.\n\n- [`mintCompressedNft()`](#mintCompressedNft): Mint a new compressed NFT. \n- [`delegateCollectionAuthority()`](#delegatecollectionauthority-and-revokecollectionauthority): Delegates collection authority to a new address.\n- [`revokeCollectionAuthority()`](#delegatecollectionauthority-and-revokecollectionauthority): Revokes collection authority from an address.\n- [`getMintlist()`](#getMintlist) Get all the tokens for an NFT collection.\n\n[**Webhooks**](#webhooks)\n\nProvides methods for setting up, editing, and managing webhooks, crucial for listening to on-chain Solana events (e.g., sales, listings, swaps) and triggering actions when these events happen.\n\n- [`createWebhook()`](#createWebhook): Creates a new webhook with the provided request.\n- [`editWebhook()`](#editWebhook): Edits an existing webhook by its ID with the provided request.\n- [`appendAddressesToWebhook()`](#appendAddressesToWebhook): Append new addresses to an existing webhook.\n- [`removeAddressesFromWebhook()`](#removeAddressesFromWebhook): Remove addresses from an existing webhook.\n- [`deleteWebhook()`](#deleteWebhook): Deletes a webhook by its ID.\n- [`getWebhookByID()`](#getWebhookByID): Retrieves a single webhook by its ID.\n- [`getAllWebhooks()`](#getAllWebhooks): Retrieves a list of all webhooks.\n- [`createCollectionWebhook()`](#createCollectionWebhook) Create a new collection webhook with the provided request.\n\n[**Smart Transactions**](https://docs.helius.dev/solana-rpc-nodes/sending-transactions-on-solana#sending-smart-transactions)\n- [`createSmartTransaction()`](#createSmartTransaction): Creates a smart transaction with the provided configuration\n- [`getComputeUnits()`](#getComputeUnits): Simulates a transaction to get the total compute units consumed\n- [`pollTransactionConfirmation()`](#pollTransactionConfirmation): Polls a transaction to check whether it has been confirmed\n- [`sendSmartTransaction()`](#sendSmartTransaction): Builds and sends an optimized transaction\n\n[**Jito Smart Transactions and Helper Methods**]()\n- [`addTipInstruction()`](#addTipInstruction): Adds a tip instruction as the last instruction given the provided instructions\n- [`createSmartTransactionWithTip()`](#createSmartTransactionWithTip): Creates a smart transaction with a Jito tip\n- [`getBundleStatuses()`](#getBundleStatuses): Gets the status of the provided bundles\n- [`sendJitoBundle()`](#sendJitoBundle): Sends a bundle of transactions to the Jito Block Engine\n- [`sendSmartTransactionWithTip()`](#sendSmartTransactionWithTip): Sends a smart transaction as a Jito bundle with a tip\n\n[**Helper methods**](#helper-methods)\n\nOffers additional tools for various Solana-related tasks like analyzing blockchain throughput and tracking stake accounts and SPL token holders.\n\n- [`getCurrentTPS()`](#getCurrentTPS): Returns the current transactions per second (TPS) rate — including voting transactions.\n- [`airdrop()`](#airdrop): Request an allocation of lamports to the specified address\n- [`getStakeAccounts()`](#getStakeAccounts): Returns all the stake accounts for a given public key.\n- [`getTokenHolders()`](#getTokenHolders): Returns all the token accounts for a given mint address (ONLY FOR SPL TOKENS).\n- [`getPriorityFeeEstimate()`](#getPriorityFeeEstimate): Returns an estimated priority fee based on a set of predefined priority levels (percentiles).\n- [`sendTransaction()`](#sendTransaction): Wrapper for `sendTransaction` RPC call that includes support for `validatorAcls` parameter.\n\n\n## DAS API (Digital Asset Standard)\n\nRead more about the DAS API from our docs, [here](https://docs.helius.dev/solana-compression/digital-asset-standard-das-api).\n\nNamespace: `helius.rpc`\n\n### getAsset()\n\nGet an asset by its ID.\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\nconst response = await helius.rpc.getAsset({\n  id: \"F9Lw3ki3hJ7PF9HQXsBzoY8GyE6sPoEZZdXJBsTTD2rk\",\n  displayOptions: {\n    showCollectionMetadata: true,\n  },\n});\nconsole.log(response.grouping?.map((g) => g.collection_metadata?.name));\n```\n\n### getAssetBatch()\n\nGet multiple assets by ID (up to 1k).\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst ids = [\n  \"F9Lw3ki3hJ7PF9HQXsBzoY8GyE6sPoEZZdXJBsTTD2rk\",\n  \"F9Lw3ki3hJ7PF9HQXsBzoY8GyE6sPoEZZdXJBsTTD2rk\",\n];\nconst helius = new Helius(\"your-api-key\");\nconst response = await helius.rpc.getAssetBatch({\n  ids: ids,\n});\nconsole.log(response.map((x) => x.id));\n```\n\n### getSignaturesForAsset()\n\nGet a list of transaction signatures related to a compressed asset.\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\nconst response = await helius.rpc.getSignaturesForAsset({\n  id: \"Bu1DEKeawy7txbnCEJE4BU3BKLXaNAKCYcHR4XhndGss\",\n  page: 1,\n});\nconsole.log(response.items);\n```\n\n### searchAssets()\n\nSearch for assets by a variety of parameters. Very useful for token-gating!\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\nconst response = await helius.rpc.searchAssets({\n  ownerAddress: \"2k5AXX4guW9XwRQ1AKCpAuUqgWDpQpwFfpVFh3hnm2Ha\",\n  compressed: true,\n  page: 1,\n});\nconsole.log(response.items);\n```\n\n### getAssetProof()\n\nGet a merkle proof for a compressed asset by its ID.\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\nconst response = await helius.rpc.getAssetProof({\n  id: \"Bu1DEKeawy7txbnCEJE4BU3BKLXaNAKCYcHR4XhndGss\",\n});\nconsole.log(response);\n```\n\n### getAssetsByOwner()\n\nGet a list of assets owned by an address. This is the fastest way to get all the NFTs owned by a wallet on Solana.\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\nconst response = await helius.rpc.getAssetsByOwner({\n  ownerAddress: \"86xCnPeV69n6t3DnyGvkKobf9FdN2H9oiVDdaMpo2MMY\",\n  page: 1,\n});\nconsole.log(response.items);\n```\n\n### getAssetsByGroup()\n\nGet a list of assets by a group key and value. This endpoint is very useful for getting the mint list for NFT Collections.\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\nconst response = await helius.rpc.getAssetsByGroup({\n  groupKey: \"collection\",\n  groupValue: \"J1S9H3QjnRtBbbuD4HjPV6RpRhwuk4zKbxsnCHuTgh9w\",\n  page: 1,\n});\nconsole.log(response.items);\n```\n\n### getAssetsByCreator()\n\nGet a list of assets created by an address.\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\nconst response = await helius.rpc.getAssetsByCreator({\n  creatorAddress: \"D3XrkNZz6wx6cofot7Zohsf2KSsu2ArngNk8VqU9cTY3\",\n  onlyVerified: true,\n  page: 1,\n});\nconsole.log(response.items);\n```\n\n### getAssetsByAuthority()\n\nGet a list of assets with a specific authority.\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\nconst response = await helius.rpc.getAssetsByAuthority({\n  authorityAddress: \"2RtGg6fsFiiF1EQzHqbd66AhW7R5bWeQGpTbv2UMkCdW\",\n  page: 1,\n});\nconsole.log(response.items);\n```\n\n### getTokenAccounts()\n\nGet information about all token accounts for a specific mint or a specific owner.\n\n```ts\nconst response = await helius.rpc.getTokenAccounts({\n  page: 1,\n  limit: 100,\n  options: {\n    showZeroBalance: false,\n  },\n  owner: \"CckxW6C1CjsxYcXSiDbk7NYfPLhfqAm3kSB5LEZunnSE\"\n});\n\nconsole.log(response);\n```\n\n### getNftEditions()\n\nGet information about all the edition NFTs for a specific master NFT.\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\nconst response = await helius.rpc.getNftEditions({\n  mint: \"Ey2Qb8kLctbchQsMnhZs5DjY32To2QtPuXNwWvk4NosL\",\n  page: 1,\n  limit: 2,\n});\n\nconsole.log(response);\n```\n\n## Mint\n\nTo read more about the easiest way to mint cNFTs on Solana, see [our docs](https://docs.helius.dev/compression-and-das-api/mint-api).\n\n### mintCompressedNft()\n\nTo mint a compressed NFT, simply call the `mintCompressedNft` method and pass in your NFT data. [This](https://xray.helius.xyz/token/UJA7Dguu6VeG3W73AyaDYQiPR9Jw9vx3XXi6CYrN224?network=mainnet) is what the mint will look like in the explorer.\n\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\nconst response = await helius.mintCompressedNft({\n  name: \"Exodia the Forbidden One\",\n  symbol: \"ETFO\",\n  owner: \"OWNER_WALLET_ADDRESS\",\n  description:\n    \"Exodia the Forbidden One is a powerful, legendary creature composed of five parts: the Right Leg, Left Leg, Right Arm, Left Arm, and the Head. When all five parts are assembled, Exodia becomes an unstoppable force.\",\n  attributes: [\n    {\n      trait_type: \"Type\",\n      value: \"Legendary\",\n    },\n    {\n      trait_type: \"Power\",\n      value: \"Infinite\",\n    },\n    {\n      trait_type: \"Element\",\n      value: \"Dark\",\n    },\n    {\n      trait_type: \"Rarity\",\n      value: \"Mythical\",\n    },\n  ],\n  imageUrl:\n    \"https://cdna.artstation.com/p/assets/images/images/052/118/830/large/julie-almoneda-03.jpg?1658992401\",\n  externalUrl: \"https://www.yugioh-card.com/en/\",\n  sellerFeeBasisPoints: 6900,\n});\nconsole.log(response.result);\n```\n\nIf you want the SDK to handle the image upload, you can do so by passing in the `imagePath` and `walletPrivatekey` fields. `imagePath` is the relative path to the image, and `walletPrivatekey` is the private key of the wallet that'll pay for the image upload to Arweave.\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\nconst response = await helius.mintCompressedNft({\n  name: \"Aggron\",\n  symbol: \"AGNFT\",\n  owner: \"OWNER_WALLET_ADDRESS\",\n  description:\n    \"Aggron is a powerful Steel/Rock-type Pokémon known for its iron defense.\",\n  attributes: [\n    {\n      trait_type: \"Type\",\n      value: \"Steel/Rock\",\n    },\n    {\n      trait_type: \"Power\",\n      value: \"High\",\n    },\n  ],\n  externalUrl: \"https://www.pokemon.com/us/pokedex/aggron\",\n  imagePath: \"../images/aagron.png\",\n  walletPrivatekey: \"YOUR_WALLET_PRIVATE_KEY\",\n});\n```\n\n### delegateCollectionAuthority() and revokeCollectionAuthority()\n\nIf you want to mint your cNFT to a collection:\n\n- Delegate Helius as a collection authority (using `DelegateCollectionAuthority` method), so that Helius can mint to that collection on your behalf.\n- Pass in the collection mint address in the `collection` field.\n- (Optional) Revoke collection authority (using `RevokeCollectionAuthority` method).\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\n// 1. Delegate Helius as a collection authority\nawait helius.delegateCollectionAuthority({\n  collectionMint: \"COLLECTION_MINT_ADDRESS\",\n  updateAuthorityKeypair: updateAuthorityKeypair,\n});\n\n// 2. Mint your cNFT to the collection\nconst response = await helius.mintCompressedNft({\n  name: \"Feitan Portor\",\n  symbol: \"FEITAN\",\n  owner: \"OWNER_WALLET_ADDRESS\",\n  collection: \"COLLECTION_MINT_ADDRESS\",\n  description: \"Feitan Portor is a member of the notorious Phantom Troupe.\",\n  attributes: [\n    {\n      trait_type: \"Affiliation\",\n      value: \"Phantom Troupe\",\n    },\n    {\n      trait_type: \"Nen Ability\",\n      value: \"Pain Packer\",\n    },\n  ],\n  externalUrl: \"https://hunterxhunter.fandom.com/wiki/Feitan_Portor\",\n  imagePath: \"../images/feitan.png\",\n  walletPrivatekey: \"YOUR_WALLET_PRIVATE_KEY\",\n});\n\n// 3. Revoke collection authority (optional)\nawait helius.revokeCollectionAuthority({\n  collectionMint: \"COLLECTION_MINT_ADDRESS\",\n  revokeAuthorityKeypair: revokeAuthorityKeypair,\n});\n```\n### getMintlist()\n\nTo get all the tokens for an NFT collection:\n\n```ts\nimport {\n  Helius\n  Collections,\n} from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nconst mints = helius.getMintlist({\n  query: Collections.ABC,\n});\n```\n\n## **Webhooks**\n\nHelius webhooks are the perfect way of building event-driven systems on Solana.\n\nSimply select the transaction type(s) to detect, the accounts to watch, and the webhook handler.\n\nWe've parsed over 100 transaction types (including NFT Sales, NFT Listings, and more) from over 50 different sources so you can get building ASAP.\n\n> If you don't want Helius' unique abstractions and would rather work with Solana's native data types, set `webhookType` to \"raw\".\n\nFor a quick demo video, please see the [Webhook docs.](https://docs.helius.dev/webhooks/webhooks-summary)\n\n### createWebhook()\n\n> **Note**: You can use enum `WebhookType` to specify between raw, discord, or enhanced webhooks! The default type is \"enhanced\".\n\n```ts\nimport {\n  // enums\n  Address,\n  TransactionType,\n\n  // lib\n  Helius,\n} from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nhelius.createWebhook({\n  accountAddresses: [Address.MAGIC_EDEN_V2],\n  transactionTypes: [TransactionType.NFT_LISTING],\n  webhookURL: \"my-webhook-handler.com/handle\",\n});\n```\n\nIf you'd like to work with the native Solana transaction format instead of Helius' abstraction, use the \"raw\" type instead (this will also have lower latency). Note we also add an auth-header for security purposes.\n\n```ts\nimport {\n  // enums\n  TransactionType,\n  WebhookType,\n  Address,\n  Helius,\n} from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nhelius.createWebhook({\n  accountAddresses: [Address.MAGIC_EDEN_V2],\n  authHeader: \"some auth header\",\n  webhookURL: \"my-webhook-handler.com/handle\",\n  webhookType: WebhookType.RAW,\n  transactionTypes: [TransactionType.ANY],\n});\n```\n\nFor Discord webhooks, simply use enum `WebhookType.DISCORD`.\n\n### editWebhook()\n\nYou can also edit your webhooks. A common use case is dynamically adding/removing accounts to watch in a webhook:\n\n```ts\nimport { Helius, Address } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nhelius.editWebhook(\n  \"your-webhook-id-here\",\n  { accountAddresses: [Address.SQUADS] } // This will ONLY update accountAddresses, not the other fields on the webhook object\n);\n```\n\n> **Very important**: The `editWebhook` method will completely overwrite the existing values for the field(s) that you inputted. Make sure to fetch the existing webhook and merge the values to avoid this.\n\n### appendAddressesToWebhook()\n\nFor convenience, we've added a method to let you simply append new addresses to an existing webhook:\n\n```ts\nimport { Helius, Address } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nhelius.appendAddressesToWebhook(\"your-webhook-id-here\", [\n  Address.SQUADS,\n  Address.JUPITER_V3,\n]);\n```\n\n### removeAddressesFromWebhook()\n\nFor convenience, we've added a method to let you simply remove addresses from an existing webhook:\n\n```ts\nimport { Helius, Address } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nhelius.removeAddressesFromWebhook(\"your-webhook-id-here\", [\n  Address.SQUADS,\n  Address.JUPITER_V3,\n]);\n```\n\n### getAllWebhooks()\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nhelius.getAllWebhooks();\n```\n\n### getWebhookByID()\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nhelius.getWebhookByID(\"<webhook-id-here>\");\n```\n\n### deleteWebhook()\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nhelius.deleteWebhook(\"<webhook-id-here>\"); // returns a boolean\n```\n\n### createCollectionWebhook()\n\n```ts\nimport {\n  // collections dict\n  Collections,\n  Helius,\n} from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nhelius.createCollectionWebhook({\n  collectionQuery: Collections.ABC,\n  transactionTypes: [Types.TransactionType.ANY],\n  webhookType: Types.WebhookType.DISCORD,\n  webhookURL: \"https://discord.com/api/webhooks/your-discord-token-here\",\n});\n```\n\nNote that the Collections.ABC enum references the collection query for this collection. It is just a convenience enum so that developers don't have to figure out whether to use firstVerifiedCreator or the Metaplex Certified Collection address. If you already know it for your collection, please make a PR.\n\n## Helper methods\n\nWe provide a variety of helper methods to help make Solana RPCs easier to work with.\n\n### getCurrentTPS()\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nconst tps = await helius.rpc.getCurrentTPS();\n```\n\n### airdrop()\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nconst response = await helius.rpc.airdrop(\n  new PublicKey(\"<wallet address>\"),\n  1000000000\n); // 1 sol\n```\n\n### getStakeAccounts()\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nconst response = await helius.rpc.getStakeAccounts(\"<wallet address>\");\n```\n\n### getTokenHolders()\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nconst response = await helius.rpc.getTokenHolders(\"<token mint address>\");\n```\n\n### getPriorityFeeEstimate()\nThis method considers both global and local fee markets in the estimation. Users can also specify to receive all the priority levels and adjust the window with which these levels are calculated via `lookbackSlots`\n\n```ts\nimport { Helius } from \"helius-sdk\";\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nconst response = await helius.rpc.getPriorityFeeEstimate({\n  accountKeys: [\"JUP6LkbZbjS1jKKwapdHNy74zcZ3tLUZoi5QNyVTaV4\"],\n  options: {\n    includeAllPriorityFeeLevels: true,\n  }\n});\n\nconsole.log(response);\n```\n\n### sendSmartTransaction()\nThis method builds and sends an optimized transaction, while handling its confirmation status. Whether the transaction skips preflight checks and how many times it is retried is configurable by the user. The following code snippet is an example of sending 0.5 SOL to a given public key, with an optimize transaction that skips preflight checks:\n\n```ts\nimport { Helius } from \"helius-sdk\";\nimport {\n  Keypair,\n  SystemProgram,\n  LAMPORTS_PER_SOL,\n  TransactionInstruction,\n} from \"@solana/web3.js\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nconst fromKeypair = /* Your keypair goes here */;\nconst fromPubkey = fromKeypair.publicKey;\nconst toPubkey = /* The person we're sending 0.5 SOL to */;\n\nconst instructions: TransactionInstruction[] = [\n  SystemProgram.transfer({\n    fromPubkey: fromPubkey,\n    toPubkey: toPubkey,\n    lamports: 0.5 * LAMPORTS_PER_SOL, \n  }),\n];\n\nconst transactionSignature = await helius.rpc.sendSmartTransaction(instructions, [fromKeypair], [], { skipPreflight: true });\nconsole.log(`Successful transfer: ${transactionSignature}`);\n```\n\n### createSmartTransaction()\nThe smart transaction creation functionality has been abstracted out of `sendSmartTransaction` and is available with the `createSmartTransaction()` method. It takes in an array of instructions, signers, lookup tables, and an optional fee payer. It returns an object containing the smart transaction (i.e., `Transaction | VersionedTransaction`) as well as the `lastValidBlockHeight`:\n\n```ts\nconst { smartTransaction: transaction, lastValidBlockHeight } = await helius.rpc.createSmartTransaction(instructions, signers, lookupTables, feePayer);\n```\n\n### getComputeUnits()\nThis method simulates a transaction to get the total compute units consumed. It takes in an array of instructions, a fee payer, an array of lookup tables, and an array of signers. It returns the compute units consumed, or null if unsuccessful:\n\n```ts\nconst units = helius.rpc.getComputeUnits(instructions, payerKey, [], []);\n```\n\n### pollTransactionConfirmation()\nThis method polls a transaction to check whether it has been confirmed. It takes in a `TransactionSignature` and checks whether it has been confirmed within the timeout period. Currently, this method defaults to a 15 second timeout and a 5 second retry interval, so it polls 3 times over 15 seconds. However, with `PollTransactionOptions`, these values can be changed in addition to the confirmation status. It returns the confirmed transaction signature or an error if the confirmation times out:\n\n```ts\nlet txSig = await helius.connection().sendRawTransaction(transaction.serialize(), {\n  skipPreflight: true,\n  ...sendOptions\n});\n\nreturn await helius.rpc.pollTransactionConfirmation(txSig);\n```\n\n### sendSmartTransactionWithTip()\nThis method has the same functionality as `sendSmartTransaction`. However, it sends the optimized transaction as a bundle and includes a tip so it is processed by Jito's Block Engine. The following code snippet sends 0.05 SOL to a given public key with a Jito tip of 100k lamports using Jito's New York API URL:\n\n```ts\nimport { Helius } from \"helius-sdk\";\nimport {\n  Keypair,\n  SystemProgram,\n  LAMPORTS_PER_SOL,\n  TransactionInstruction,\n} from \"@solana/web3.js\";\n\nconst helius = new Helius(\"YOUR_API_KEY\");\n\nconst fromKeypair = /* Your keypair goes here */;\nconst fromPubkey = fromKeypair.publicKey;\nconst toPubkey = /* The person we're sending 0.05 SOL to */;\n\nconst instructions: TransactionInstruction[] = [\n  SystemProgram.transfer({\n    fromPubkey: fromPubkey,\n    toPubkey: toPubkey,\n    lamports: 0.05 * LAMPORTS_PER_SOL, \n  }),\n];\n\n// Call the sendSmartTransactionWithTip function\nconst bundleId = await helius.rpc.sendSmartTransactionWithTip(instructions, [keypair], address_lut, 100000, \"NY\");\nconsole.log(`Bundle sent successfully with ID: ${bundleId}`);\n```\n\n### createSmartTransactionWithTip()\nSimilarly to `createSmartTransaction`, the smart transaction creation functionality for smart transactions with tips has been abstracted out of `sendSmartTransactionWithTip` and is available with the `createSmartTransactionWithTip` method. It takes in an array of instructions, signers, lookup tables, as well as a tip amount and an optional fee payer. The tip amount defaults to 1000 lamports — the minimum specified in [Jito's documentation](https://jito-labs.gitbook.io/mev/searcher-resources/bundles#tip-guidelines). It returns the serialized transaction as a string, and the `lastValidBlockHeight`. The reason we return the transaction as a string is because the `sendJitoBundle` method requires a serialzied transaction:\n\n```ts\nconst { serializedTransaction, lastValidBlockHeight } = await this.createSmartTransactionWithTip(instructions, signers, lookupTables, tipAmount, feePayer);\n```\n\n### addTipInstruction()\nThis method adds a tip instruction to the last instruction in the set of provided instructions. It is a transfer instruction that sends the specified amount of lamports from the fee payer to the designated tip account.\n\n```ts\nconst randomTipAccount = JITO_TIP_ACCOUNTS[Math.floor(Math.random() * JITO_TIP_ACCOUNTS.length)];\nconst tipAmount = 10000;\n\nhelius.rpc.addTipInstruction(instructions, feePayer, randomTipAccount, tipAmount);\n```\n\n### sendJitoBundle()\nThis method sends a bundle of transactions to the Jito Block Engine. It takes in an array of serialized transactions and a Jito Block Engine API URL. It returns the bundle ID as a string.\n\n```ts\nconst jitoApiUrl = 'https://mainnet.block-engine.jito.wtf/api/v1/bundles';\nconst bundleId = helius.rpc.sendJitoBundle([serializedTransactions], jitoApiUrl);\n```\n\n### getBundleStatuses()\nThis method gets the status of Jito bundles. It takes in an array of bundle IDs and a Jito Block Engine API URL. It returns the status of the bundles.\n\n```ts\nconst bundleIds = [ /* Bundle IDs */];\nconst jitoApiUrl = 'https://mainnet.block-engine.jito.wtf/api/v1/bundles';\nconst statuses = helius.rpc.getBundleStatuses(bundleIds, jitoApiUrl);\n```\n\n### sendTransaction()\nThis method behaves the same way as the standard `sendTransaction`, but adds support for `validatorAcls` JSON-based allow/denylists.\n\n```ts\ntry {\n    const response = await helius.rpc.sendTransaction(\n        transaction,\n        {\n            validatorAcls: [SFDP_REJECTS_URL],\n            skipPreflight: true,\n        },\n    );\n} catch (error) {\n    console.error(error);\n}\n```\n\n## helius.connection\n\n> [!WARNING]   \n> This uses Solana-Web3.js version 1.73.2\n\nIncorporates all commonly-used methods from Solana-Web3.js Provider using your Helius RPC. Ideal for managing connections and performing standard Solana blockchain operations. For a list of all the Methods see: https://docs.solana.com/api/http\n\n```ts\nimport { Helius } from \"helius-sdk\";\n\n// Replace YOUR_API_KEY with the API key from your Helius dashboard\nconst helius = new Helius(\"YOUR_API_KEY\"); \n\nconst getBlockHeight = async () => {\n  const response = await helius.connection.getBlockHeight();\n  console.log(response);\n}\n\ngetBlockHeight();\n```\n\n## FAQ\n\nQ: I get an error stating `Cannot use import statement outside a module`  \nA: In the `package.json` file add `\"type\": \"module\"`. Adding this enables ES6 modules.\n","readmeFilename":"README.md"}