diff --git a/.github/actions/setup/action.yml b/.github/actions/setup/action.yml
index 28323e5..9c6c869 100644
--- a/.github/actions/setup/action.yml
+++ b/.github/actions/setup/action.yml
@@ -29,7 +29,7 @@ runs:
- name: Setup Node.js
uses: actions/setup-node@v4
with:
- node-version: 18
+ node-version: 20
cache: 'pnpm'
- name: Install Dependencies
diff --git a/clients/js/package.json b/clients/js/package.json
index ff8bbd8..1707a14 100644
--- a/clients/js/package.json
+++ b/clients/js/package.json
@@ -34,14 +34,13 @@
},
"license": "Apache-2.0",
"peerDependencies": {
- "@solana/web3.js": "2.0.0-rc.0"
+ "@solana/web3.js": "2.0.0-rc.1"
},
"devDependencies": {
"@ava/typescript": "^4.1.0",
"@solana-program/system": "^0.4.1",
"@solana/eslint-config-solana": "^3.0.3",
- "@solana/web3.js": "2.0.0-rc.0",
- "@solana/webcrypto-ed25519-polyfill": "2.0.0-rc.0",
+ "@solana/web3.js": "2.0.0-rc.1",
"@types/node": "^20",
"@typescript-eslint/eslint-plugin": "^7.16.1",
"@typescript-eslint/parser": "^7.16.1",
@@ -58,9 +57,6 @@
"nodeArguments": [
"--no-warnings"
],
- "require": [
- "@solana/webcrypto-ed25519-polyfill"
- ],
"typescript": {
"compile": false,
"rewritePaths": {
diff --git a/clients/js/pnpm-lock.yaml b/clients/js/pnpm-lock.yaml
index bb9d197..b3ae115 100644
--- a/clients/js/pnpm-lock.yaml
+++ b/clients/js/pnpm-lock.yaml
@@ -13,16 +13,13 @@ importers:
version: 4.1.0
'@solana-program/system':
specifier: ^0.4.1
- version: 0.4.1(@solana/web3.js@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0))
+ version: 0.4.1(@solana/web3.js@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0))
'@solana/eslint-config-solana':
specifier: ^3.0.3
version: 3.0.3(@typescript-eslint/eslint-plugin@7.16.1(@typescript-eslint/parser@7.16.1(eslint@8.57.0)(typescript@5.5.3))(eslint@8.57.0)(typescript@5.5.3))(@typescript-eslint/parser@7.16.1(eslint@8.57.0)(typescript@5.5.3))(eslint-plugin-jest@27.9.0(@typescript-eslint/eslint-plugin@7.16.1(@typescript-eslint/parser@7.16.1(eslint@8.57.0)(typescript@5.5.3))(eslint@8.57.0)(typescript@5.5.3))(eslint@8.57.0)(typescript@5.5.3))(eslint-plugin-react-hooks@4.6.2(eslint@8.57.0))(eslint-plugin-simple-import-sort@10.0.0(eslint@8.57.0))(eslint-plugin-sort-keys-fix@1.1.2)(eslint-plugin-typescript-sort-keys@3.2.0(@typescript-eslint/parser@7.16.1(eslint@8.57.0)(typescript@5.5.3))(eslint@8.57.0)(typescript@5.5.3))(eslint@8.57.0)(typescript@5.5.3)
'@solana/web3.js':
- specifier: 2.0.0-rc.0
- version: 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)
- '@solana/webcrypto-ed25519-polyfill':
- specifier: 2.0.0-rc.0
- version: 2.0.0-rc.0(typescript@5.5.3)
+ specifier: 2.0.0-rc.1
+ version: 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)
'@types/node':
specifier: ^20
version: 20.14.11
@@ -262,9 +259,6 @@ packages:
resolution: {integrity: sha512-Yhlar6v9WQgUp/He7BdgzOz8lqMQ8sU+jkCq7Wx8Myc5YFJLbEe7lgui/V7G1qB1DJykHSGwreceSaD60Y0PUQ==}
hasBin: true
- '@noble/ed25519@2.1.0':
- resolution: {integrity: sha512-KM4qTyXPinyCgMzeYJH/UudpdL+paJXtY3CHtHYZQtBkS8MZoPr4rOikZllIutJe0d06QDQKisyn02gxZ8TcQA==}
-
'@nodelib/fs.scandir@2.1.5':
resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==}
engines: {node: '>= 8'}
@@ -374,49 +368,49 @@ packages:
peerDependencies:
'@solana/web3.js': 2.0.0-preview.4
- '@solana/accounts@2.0.0-rc.0':
- resolution: {integrity: sha512-Xun9ASXuJd3njGgc8q32Ra2f2r5J4KNhVZn6g5G//uQVpc+8QpBrTqS0lV+q7f6i0+um8WD4Q7OYOtnRb6mBiA==}
+ '@solana/accounts@2.0.0-rc.1':
+ resolution: {integrity: sha512-au6grz6iIgepKIbN2HUHKatFhg7mvIvdjFMDYpuEx+AGwK7vHnN5PsJqSCGQydthC2nVQwSZC9IgA5MF5wUHdw==}
peerDependencies:
typescript: '>=5'
- '@solana/addresses@2.0.0-rc.0':
- resolution: {integrity: sha512-cx/Vdwqn7Ns3ud+tyvD5ua4q2UtTleaAWuqyv7opAZLJOZWq2sL9esG3MIEZR5P9wW6sai8Mk9ule1DoWC+pqQ==}
+ '@solana/addresses@2.0.0-rc.1':
+ resolution: {integrity: sha512-g31KrLZdECjAKceShlGoYxnWDmEVklpjPs8xOtnj/HWupEk+Mds4vtmTACTAeJkWZW/3x+z0aexMtO86MKA47g==}
peerDependencies:
typescript: '>=5'
- '@solana/assertions@2.0.0-rc.0':
- resolution: {integrity: sha512-O9g764n0CC3y8OTe7o02syj/S6ecqHvOcquf0z1qwQKZkwCJ8eyb6Xj9l82RKuMEvMtgaIiMrg8jMDo2ML5aCw==}
+ '@solana/assertions@2.0.0-rc.1':
+ resolution: {integrity: sha512-dvxYCUB7ftZa5lWcsyMYLsGm204H6yVN8Q3ngluMG0rhTtScMBRklVg7Vs39ISwJOkJWJPGToaZ7DjNJ83bm1Q==}
peerDependencies:
typescript: '>=5'
- '@solana/codecs-core@2.0.0-rc.0':
- resolution: {integrity: sha512-eIMMZiSfzZNlMK0uJRfpj9URrvuRo8SXncbCva+Wmpaob9dS+Mplo9VrH0T7+aTZJUAb5o9FbZgo4tUAOecVhg==}
+ '@solana/codecs-core@2.0.0-rc.1':
+ resolution: {integrity: sha512-bauxqMfSs8EHD0JKESaNmNuNvkvHSuN3bbWAF5RjOfDu2PugxHrvRebmYauvSumZ3cTfQ4HJJX6PG5rN852qyQ==}
peerDependencies:
typescript: '>=5'
- '@solana/codecs-data-structures@2.0.0-rc.0':
- resolution: {integrity: sha512-CTFOIV+I6LjGosKBkfYYFSRH+i2WG0F46Qf5zBsa52X/UGFFW7Nwaf6XJl84xYIFi4JMMZOA3x221vjK0JoYWg==}
+ '@solana/codecs-data-structures@2.0.0-rc.1':
+ resolution: {integrity: sha512-rinCv0RrAVJ9rE/rmaibWJQxMwC5lSaORSZuwjopSUE6T0nb/MVg6Z1siNCXhh/HFTOg0l8bNvZHgBcN/yvXog==}
peerDependencies:
typescript: '>=5'
- '@solana/codecs-numbers@2.0.0-rc.0':
- resolution: {integrity: sha512-KqIU/xuB+IHNex9uYsB9y2MoH6VX2zRBnDJpdu9L/dE9Uw5xVKJRGdeHB9mBC4PBZ90VPMz3mP+xfFIXMS0j8g==}
+ '@solana/codecs-numbers@2.0.0-rc.1':
+ resolution: {integrity: sha512-J5i5mOkvukXn8E3Z7sGIPxsThRCgSdgTWJDQeZvucQ9PT6Y3HiVXJ0pcWiOWAoQ3RX8e/f4I3IC+wE6pZiJzDQ==}
peerDependencies:
typescript: '>=5'
- '@solana/codecs-strings@2.0.0-rc.0':
- resolution: {integrity: sha512-9yYBvJpo1WTT8idzomrHF602Snylo1+pmEGNrYlUaxmzVU2Hdb28U0WKv0iz9TdCDvMDlIwjsBznt6DmVf4i6g==}
+ '@solana/codecs-strings@2.0.0-rc.1':
+ resolution: {integrity: sha512-9/wPhw8TbGRTt6mHC4Zz1RqOnuPTqq1Nb4EyuvpZ39GW6O2t2Q7Q0XxiB3+BdoEjwA2XgPw6e2iRfvYgqty44g==}
peerDependencies:
fastestsmallesttextencoderdecoder: ^1.0.22
typescript: '>=5'
- '@solana/codecs@2.0.0-rc.0':
- resolution: {integrity: sha512-C92OLr/4k2+o+hlZb5ukXn4/KlDZa/YMvgVYlKk87+RoSPLS6/WWHpU8+Anh2bAW8TD+BwFx4p1WtLWPd6Jwdg==}
+ '@solana/codecs@2.0.0-rc.1':
+ resolution: {integrity: sha512-qxoR7VybNJixV51L0G1RD2boZTcxmwUWnKCaJJExQ5qNKwbpSyDdWfFJfM5JhGyKe9DnPVOZB+JHWXnpbZBqrQ==}
peerDependencies:
typescript: '>=5'
- '@solana/errors@2.0.0-rc.0':
- resolution: {integrity: sha512-4zaFxuYWQJi+CBucncGPc+QsWZktdmC6rDne3JxZGDKqqY5AMwktRC9LyUKaey/dVThmFGo1wv1wNQy1ryvbWw==}
+ '@solana/errors@2.0.0-rc.1':
+ resolution: {integrity: sha512-ejNvQ2oJ7+bcFAYWj225lyRkHnixuAeb7RQCixm+5mH4n1IA4Qya/9Bmfy5RAAHQzxK43clu3kZmL5eF9VGtYQ==}
hasBin: true
peerDependencies:
typescript: '>=5'
@@ -434,129 +428,129 @@ packages:
eslint-plugin-typescript-sort-keys: ^3.2.0
typescript: ^5.1.6
- '@solana/fast-stable-stringify@2.0.0-rc.0':
- resolution: {integrity: sha512-qpHZNKzVP5PFEIK1TQvIM+A+DjSCV53KaxXzxPFiYd/JfjdxIhH6h1C0bbRMdsbBqwWlbacs2H5/xrKP3X42cw==}
+ '@solana/fast-stable-stringify@2.0.0-rc.1':
+ resolution: {integrity: sha512-TN8JY+Sbh5NNq4TqdWil8hXKx2d84bTHvY6jfBXNjM29S0fwpUpVRHUzOkuK1mjjWFNkMpfgJfozC0TjdUbkvA==}
peerDependencies:
typescript: '>=5'
- '@solana/functional@2.0.0-rc.0':
- resolution: {integrity: sha512-Z+nkjtWyjp3yktU8ip2MxbKb7+I2YUiY8kbpvxAWnWKGcUoKhgcW3EhxhSxFWKbaiEcBmyoPCEdM2MJgJPZJug==}
+ '@solana/functional@2.0.0-rc.1':
+ resolution: {integrity: sha512-BmedS5o8HTlU8/NA22I6urJqat9QYIw0oH6rKdMMBisDwX7MtgJhe38W8iLP7QCcxoJeS4526qaD8uD62+Pheg==}
peerDependencies:
typescript: '>=5'
- '@solana/instructions@2.0.0-rc.0':
- resolution: {integrity: sha512-0/MQ80BXZfELZuCc7GudopuCpQC4VnN9WJDHtR8Tur0j8shiSyHWOOZlWfx66eQuSiQsnbOLT1CRTdhEt/vZhA==}
+ '@solana/instructions@2.0.0-rc.1':
+ resolution: {integrity: sha512-zkfL4WBHPbkMrYsuGZc/sekPa/oALIVvVGUw/gwAervMeLZ34cWCUE6WC2uUUh+bq3OFq0/FSFhAg2YbHHDyUw==}
peerDependencies:
typescript: '>=5'
- '@solana/keys@2.0.0-rc.0':
- resolution: {integrity: sha512-k/2uvObJdQfsmKUI+vL+9zcRRdZpaScq0SKIQLe33dbv+3XIEhCRizPEIg8Q8fzIKB9rrbwHqJ5RPDxThZa++g==}
+ '@solana/keys@2.0.0-rc.1':
+ resolution: {integrity: sha512-ls3B0KOvfdiBH3/fnEjHhicfXsLLb4zApJlSX4X8NZ+2TmTJ2Jqa+MakgAzrsxL1FJkTJ1RDboR9xx2CHQtKzw==}
peerDependencies:
typescript: '>=5'
- '@solana/options@2.0.0-rc.0':
- resolution: {integrity: sha512-uPc/31v+FZj9mkq2mQ6uAJfvmxGnQsx2mJ90IlJdDLSlkcx6GymNyXp0meh8qfhvfEaz4F5lCOzSeApofIZPvw==}
+ '@solana/options@2.0.0-rc.1':
+ resolution: {integrity: sha512-mLUcR9mZ3qfHlmMnREdIFPf9dpMc/Bl66tLSOOWxw4ml5xMT2ohFn7WGqoKcu/UHkT9CrC6+amEdqCNvUqI7AA==}
peerDependencies:
typescript: '>=5'
- '@solana/programs@2.0.0-rc.0':
- resolution: {integrity: sha512-sihHN5HDXEXJnoeG/hnahFreF6d2AMGIELtF2kv5uHM9F5NcdYFmX1Q0tWBC6Y/DugIf3Qtk+jMFceM7qUoWXA==}
+ '@solana/programs@2.0.0-rc.1':
+ resolution: {integrity: sha512-wF49DychwSz3sVmTF51R6DTHBGMP7Uhe7EdmCNu+Ef9EgKBJZFfrViOD6M8Q0b3WH//TV63HNlX/2QmHtJjQHg==}
peerDependencies:
typescript: '>=5'
- '@solana/rpc-api@2.0.0-rc.0':
- resolution: {integrity: sha512-vP21oksg3lU8bbSyJfgfT9a/eeQ/q5sN76VSR05T7j3Tv8VmI9N77ZNrtrfG4DZfIiYWw3qlSrVI8XTwgMIW8A==}
+ '@solana/promises@2.0.0-rc.1':
+ resolution: {integrity: sha512-iIaC52Ka+omGabGn2LHOSgEm9N2gI7Iyik6LE3DDxZ4MuYmGcJ4E315XuE/UVXWnc9qOfOjgtSaaOYhde0vyrQ==}
peerDependencies:
typescript: '>=5'
- '@solana/rpc-parsed-types@2.0.0-rc.0':
- resolution: {integrity: sha512-EvyOGZ6vbKG5XWDoPmNpMbm4Z0HE+hEIBxhQFkB+ML+qKPghtrifyF0bvydna7AIBkpc0OccVmv22Vd+gBvHng==}
+ '@solana/rpc-api@2.0.0-rc.1':
+ resolution: {integrity: sha512-pg/w+0pgj3msBCC/hkZa9/qZHRdqh7MLsHMJInXnenO+Rzj6IyE47Ig6rt6GuI4OxYy+1d714jcPXVMA8p2YWw==}
peerDependencies:
typescript: '>=5'
- '@solana/rpc-spec-types@2.0.0-rc.0':
- resolution: {integrity: sha512-0h2uQfjHIoUpP5ha3lzLFep6WLnggrksjWiCd8+iIoktPeh09CPJI2iU/hFheP7e+tUKhmErGqsL+OPNECwD2g==}
+ '@solana/rpc-parsed-types@2.0.0-rc.1':
+ resolution: {integrity: sha512-5/AYNiZvR9do56VJgmTscRwnd9myt6x9uG7b0S3V+K5e0xzA9yJF68SzI4TQSNmLfWXCaVC90xGCWWkM19lLIQ==}
peerDependencies:
typescript: '>=5'
- '@solana/rpc-spec@2.0.0-rc.0':
- resolution: {integrity: sha512-Cdwj8ief8ek5VUWRfSZDqdFzRfC6HVzyoPMIOdWRtEd8KocUGo7BTbwN9ilVJL/vIi52vi6e2A6oPMFNRyuBFw==}
+ '@solana/rpc-spec-types@2.0.0-rc.1':
+ resolution: {integrity: sha512-Z0gOrzasTYU+kNNnDDG2snZxBoBPMN8oFc0EE9HiDKN9JEsc+asexzKeq+Nea7JVqVFcN5V3bjqrpD86V5EOiQ==}
peerDependencies:
typescript: '>=5'
- '@solana/rpc-subscriptions-api@2.0.0-rc.0':
- resolution: {integrity: sha512-Q4/rR4epPud7Z/3lrtGNMJd5oSrrxp/JgJTnkxEzGxs07RHmVfvO/9jrS+dgDtj3epyjD4BhmecO98Bg8bZ2yg==}
+ '@solana/rpc-spec@2.0.0-rc.1':
+ resolution: {integrity: sha512-E81IoNzLbp24T633klEqlRujd2i/rd8xVkJGt04DL/LGS4/cCWJEhkmOnfljxWafCPUundRXlPtNG3ZmHzEYqA==}
peerDependencies:
typescript: '>=5'
- '@solana/rpc-subscriptions-spec@2.0.0-rc.0':
- resolution: {integrity: sha512-ZUxFAGy1nAIpLZ3RgWsRlRvPOLlx/vk1isFo5YcA+GAFZDLIt+jOZJF/J6QUjOohMc5xSkTRmJuMURCDmu+1dg==}
+ '@solana/rpc-subscriptions-api@2.0.0-rc.1':
+ resolution: {integrity: sha512-HmuJmB+RnpYzpiwDWncYFey0lrdFt8KbFvH0JvxEB7NX6V9NgGQIwRY1bfoaeSwX6t93p4nBWr2ckJWLNjXzCw==}
peerDependencies:
typescript: '>=5'
- '@solana/rpc-subscriptions-transport-websocket@2.0.0-rc.0':
- resolution: {integrity: sha512-Qg3w/zMAVaXhm/WQYFV0qXUjUDKmSJrRG/CzdjMfiqYPSFX1286uwyq5wnua4NzrbPd+ZtbGKyvdSVRnmy1WkA==}
+ '@solana/rpc-subscriptions-spec@2.0.0-rc.1':
+ resolution: {integrity: sha512-eXRVlMr9zw4JlBoJgVhFRxFs3Iaowhtt35ZIMD+OoTqgKniL62iGiZ3hXsuMDToMvQCBd0UfI+ZVdF2gLQdg9A==}
peerDependencies:
typescript: '>=5'
- ws: ^8.14.0
- '@solana/rpc-subscriptions@2.0.0-rc.0':
- resolution: {integrity: sha512-ThLHuf6dxpq1RTWu7GAItjLubhcJsBdhGdGGtPjGEBW1zX5YnGLsG2sc16XLgbH5LZhUDQ37wub6iwMTOBqVhA==}
+ '@solana/rpc-subscriptions-transport-websocket@2.0.0-rc.1':
+ resolution: {integrity: sha512-NxheQmG6Ku9gjF3TyGbM8Nxx6fOU3m89LdfH9SQNu6yME6VXKWuT1LaY24T707yDOoKZJsOWabRrQtNfJ+3HZA==}
peerDependencies:
typescript: '>=5'
+ ws: ^8.14.0
- '@solana/rpc-transformers@2.0.0-rc.0':
- resolution: {integrity: sha512-F/aL/ivIh2rPIpAGId8ZC3WG88wv025yLSmAhFZUOSbvF1ZCp8h63TUS5qpRGbDVUNr7PLu2Cm8EMkF6MoDSDA==}
+ '@solana/rpc-subscriptions@2.0.0-rc.1':
+ resolution: {integrity: sha512-gHrVNWEbMi8uDO8BzpJkuDiHMcfD4SrfLRohROnHx0SfSlEGxvIkBjPnwOYIoS7IkWk95e19s7hJoBNn2TX4kw==}
peerDependencies:
typescript: '>=5'
- '@solana/rpc-transport-http@2.0.0-rc.0':
- resolution: {integrity: sha512-ZuT3nhlfTGcDXjEkVlwG+XeLUKLxZvh/Am1em2vO8zGSQJmtFKlEq+Wk3C55acs0CrH00s29w3TcEcTtltikbg==}
+ '@solana/rpc-transformers@2.0.0-rc.1':
+ resolution: {integrity: sha512-YM25X4Eeh39UR2AoSrCFn74W99bQk0/DLqyPgZpNBRbszzEifGHqu83NNFwBuPMVc9q7ilf5s6r6pqhWP+5JJw==}
peerDependencies:
typescript: '>=5'
- '@solana/rpc-types@2.0.0-rc.0':
- resolution: {integrity: sha512-KFuPmkVlZitZnncDGbwu5FSFXljHQsWb4u6fJbmq0yNGwjAlUspOnl7ufL0bS7e+hh0NKfyNOXWuC4vmYEMThw==}
+ '@solana/rpc-transport-http@2.0.0-rc.1':
+ resolution: {integrity: sha512-Byvn2LnaCgTnEyr78wcgh8SrVHo+L6/l1kXQW05cNAjjbS8d8z4meBUBrXDWHmCsWy7RdnrTcBixPPtE+pUebw==}
peerDependencies:
typescript: '>=5'
- '@solana/rpc@2.0.0-rc.0':
- resolution: {integrity: sha512-isWQk5Cfu3hmjdzMfYLPn65KTkJHARocwx8i1+hF53kqrgvFGgAWtqDJXJfjkEan8ksSRfI5FzZB02YFB4zKSw==}
+ '@solana/rpc-types@2.0.0-rc.1':
+ resolution: {integrity: sha512-EcGx9VXqA0+uYEdaa1lKTaGBVxLyNL8nkecE4GkqQ+ntRyYlNBPecd4b8siQGSleUQa+Tk/VSPUawSkHqNTLug==}
peerDependencies:
typescript: '>=5'
- '@solana/signers@2.0.0-rc.0':
- resolution: {integrity: sha512-woQAIFe/kVrDPIC45wAt539hXYBOgIcVFuNVn3/aeKBpxosAokX1/NI7lWrIJChPHYB48wdnx6FOdV++EErwdQ==}
+ '@solana/rpc@2.0.0-rc.1':
+ resolution: {integrity: sha512-upqR/Ae5syzQDZkffTdU/09k1Vx073Gt4xkkpcWaTBmW0obVhrlvJvH2k5jrOQ13BZd2NVg1MWMEOBcy3+nJjQ==}
peerDependencies:
typescript: '>=5'
- '@solana/sysvars@2.0.0-rc.0':
- resolution: {integrity: sha512-re+H9N4jFlFlpVxZt2y7QwWpo1HvqMgxLzJgnJicn6KPTeQX+UgH9+N1yNInLrBWDmgdvw+xjUinojqt3xPlEA==}
+ '@solana/signers@2.0.0-rc.1':
+ resolution: {integrity: sha512-dv3oKSF+AIaHKpnSkmzEf+jXVcA3nl015+Mp/WQZYzQJS01dlrmnd4N5DOSn2CaPRJ0TLujHkupxkOFXbe149A==}
peerDependencies:
typescript: '>=5'
- '@solana/transaction-confirmation@2.0.0-rc.0':
- resolution: {integrity: sha512-dGHxDaMd+a5BN52IZMiTv0oBcVwvNugGPJdE431ltSY47Q3rMUeGKQ9fj/EMY9WzVGEnbcD4Q67hERz1CRSJTA==}
+ '@solana/sysvars@2.0.0-rc.1':
+ resolution: {integrity: sha512-nLiuisgbRw7FkJrxPJOBzf0ro7ZCk0gWgMyLQexe9oPoTzdZnWbHI4ldYDmtfdy2dkPBsNTz6sZ6o75HwnGu0A==}
peerDependencies:
typescript: '>=5'
- '@solana/transaction-messages@2.0.0-rc.0':
- resolution: {integrity: sha512-WY3eQ6z1gsRffwSzRWy8MjJzLlNs47Wd99Up1vQggn9vJtwoGPF1uIYkjkTxsCEBXQOC1Z1RTy87dgcM7US/Jg==}
+ '@solana/transaction-confirmation@2.0.0-rc.1':
+ resolution: {integrity: sha512-ES671CZUDLaXV46Vv3Kxd22coSQE4DlE7y0s9ChzQ7t4bLGv6DeHlHXU9kQBtou9koLR25wiDUWtvwNUyzUbHw==}
peerDependencies:
typescript: '>=5'
- '@solana/transactions@2.0.0-rc.0':
- resolution: {integrity: sha512-0+d37gqvxAo172AtRkW2MDT19IYIcapeSZE4/RLa87JFBbouJovDZStDoYpcVCwjv4uxS3Squtc9PyAPhKLSnw==}
+ '@solana/transaction-messages@2.0.0-rc.1':
+ resolution: {integrity: sha512-pZTetOtRDwfuK/fyE8FKbtRsLQOTgEIQld3tskB85npUHaEgrnCYzp3nJtMhKOLel3w3f/27VtWLNSrRyyAiew==}
peerDependencies:
typescript: '>=5'
- '@solana/web3.js@2.0.0-rc.0':
- resolution: {integrity: sha512-yJFhDdWM/REW635Cx2pIwa+cXxAEYQwdQ17ZvFO/fUZtU+In/OWYE3fXyC2ShfpUYzeCuMIfxHVPUhmeuSpUyA==}
+ '@solana/transactions@2.0.0-rc.1':
+ resolution: {integrity: sha512-u9MH2Kk4P0E5rNxATdx/ljR2rp34S9VuC3Jzj9nCMKJ0XwvCD+ddTmIDop5Vs+96Ls9SGj0XaKAJtT+9S7SDpw==}
peerDependencies:
typescript: '>=5'
- '@solana/webcrypto-ed25519-polyfill@2.0.0-rc.0':
- resolution: {integrity: sha512-Ol5+EexErkKhIprhONGcgjXbUpdAo6zefoA058G7MA7TG98SWTszNg0obDHhHi5IW+r2x5zXc9uOuv55bP9mgw==}
+ '@solana/web3.js@2.0.0-rc.1':
+ resolution: {integrity: sha512-0fE40ZsJuqSOYOWbt8haHBIbhSfGckxJbwWEK+xRQaWr1sY1+MPUDnBawsLf818g9KRSNnS2Y3+/Sve7A3yfBA==}
peerDependencies:
typescript: '>=5'
@@ -2146,8 +2140,6 @@ snapshots:
- encoding
- supports-color
- '@noble/ed25519@2.1.0': {}
-
'@nodelib/fs.scandir@2.1.5':
dependencies:
'@nodelib/fs.stat': 2.0.5
@@ -2218,75 +2210,75 @@ snapshots:
'@sindresorhus/merge-streams@2.3.0': {}
- '@solana-program/system@0.4.1(@solana/web3.js@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0))':
+ '@solana-program/system@0.4.1(@solana/web3.js@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0))':
dependencies:
- '@solana/web3.js': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)
+ '@solana/web3.js': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)
- '@solana/accounts@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/accounts@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/addresses': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-strings': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-spec': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-types': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/addresses': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-strings': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-spec': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-types': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/addresses@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/addresses@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/assertions': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-strings': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/assertions': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-strings': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/assertions@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/assertions@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
- '@solana/codecs-core@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/codecs-core@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
- '@solana/codecs-data-structures@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/codecs-data-structures@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-numbers': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-numbers': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
- '@solana/codecs-numbers@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/codecs-numbers@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
- '@solana/codecs-strings@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/codecs-strings@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-numbers': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-numbers': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
fastestsmallesttextencoderdecoder: 1.0.22
typescript: 5.5.3
- '@solana/codecs@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/codecs@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-data-structures': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-numbers': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-strings': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/options': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-data-structures': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-numbers': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-strings': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/options': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/errors@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/errors@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
chalk: 5.3.0
commander: 12.1.0
@@ -2304,261 +2296,262 @@ snapshots:
eslint-plugin-typescript-sort-keys: 3.2.0(@typescript-eslint/parser@7.16.1(eslint@8.57.0)(typescript@5.5.3))(eslint@8.57.0)(typescript@5.5.3)
typescript: 5.5.3
- '@solana/fast-stable-stringify@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/fast-stable-stringify@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
typescript: 5.5.3
- '@solana/functional@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/functional@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
typescript: 5.5.3
- '@solana/instructions@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/instructions@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
- '@solana/keys@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/keys@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/assertions': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-strings': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/assertions': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-strings': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/options@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/options@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-data-structures': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-numbers': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-strings': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-data-structures': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-numbers': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-strings': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/programs@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/programs@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/addresses': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/addresses': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/rpc-api@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
- dependencies:
- '@solana/addresses': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-strings': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/keys': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc-parsed-types': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-spec': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-transformers': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc-types': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/transaction-messages': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/transactions': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/promises@2.0.0-rc.1(typescript@5.5.3)':
+ dependencies:
+ typescript: 5.5.3
+
+ '@solana/rpc-api@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ dependencies:
+ '@solana/addresses': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-strings': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/keys': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-parsed-types': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-spec': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-transformers': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-types': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transaction-messages': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transactions': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/rpc-parsed-types@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/rpc-parsed-types@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
typescript: 5.5.3
- '@solana/rpc-spec-types@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/rpc-spec-types@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
typescript: 5.5.3
- '@solana/rpc-spec@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/rpc-spec@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
- '@solana/rpc-spec-types': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/rpc-spec-types': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
- '@solana/rpc-subscriptions-api@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/rpc-subscriptions-api@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/addresses': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/keys': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc-subscriptions-spec': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-transformers': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc-types': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/transaction-messages': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/transactions': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/addresses': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/keys': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-subscriptions-spec': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-transformers': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-types': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transaction-messages': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transactions': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/rpc-subscriptions-spec@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/rpc-subscriptions-spec@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-spec-types': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-spec-types': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
- '@solana/rpc-subscriptions-transport-websocket@2.0.0-rc.0(typescript@5.5.3)(ws@8.17.0)':
+ '@solana/rpc-subscriptions-transport-websocket@2.0.0-rc.1(typescript@5.5.3)(ws@8.17.0)':
dependencies:
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-subscriptions-spec': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-subscriptions-spec': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
ws: 8.17.0
- '@solana/rpc-subscriptions@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)':
- dependencies:
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/fast-stable-stringify': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/functional': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-subscriptions-api': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc-subscriptions-spec': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-subscriptions-transport-websocket': 2.0.0-rc.0(typescript@5.5.3)(ws@8.17.0)
- '@solana/rpc-transformers': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc-types': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-subscriptions@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)':
+ dependencies:
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/fast-stable-stringify': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/functional': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/promises': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-subscriptions-api': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-subscriptions-spec': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-subscriptions-transport-websocket': 2.0.0-rc.1(typescript@5.5.3)(ws@8.17.0)
+ '@solana/rpc-transformers': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-types': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- ws
- '@solana/rpc-transformers@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/rpc-transformers@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/functional': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-spec': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-subscriptions-spec': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-types': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/functional': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-spec': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-subscriptions-spec': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-types': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/rpc-transport-http@2.0.0-rc.0(typescript@5.5.3)':
+ '@solana/rpc-transport-http@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-spec': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-spec': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
undici-types: 6.19.5
- '@solana/rpc-types@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/rpc-types@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/addresses': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-numbers': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-strings': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
+ '@solana/addresses': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-numbers': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-strings': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/rpc@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/rpc@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/fast-stable-stringify': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/functional': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-api': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc-spec': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-transformers': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc-transport-http': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-types': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/fast-stable-stringify': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/functional': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-api': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-spec': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-transformers': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-transport-http': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-types': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/signers@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/signers@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/addresses': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/instructions': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/keys': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/transaction-messages': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/transactions': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/addresses': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/instructions': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/keys': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transaction-messages': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transactions': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/sysvars@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/sysvars@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/accounts': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/codecs': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-types': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/accounts': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/codecs': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-types': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/transaction-confirmation@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)':
- dependencies:
- '@solana/addresses': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/codecs-strings': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/keys': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc-subscriptions': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)
- '@solana/rpc-types': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/transaction-messages': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/transactions': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transaction-confirmation@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)':
+ dependencies:
+ '@solana/addresses': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/codecs-strings': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/keys': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/promises': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-subscriptions': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)
+ '@solana/rpc-types': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transaction-messages': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transactions': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- ws
- '@solana/transaction-messages@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/transaction-messages@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/addresses': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-data-structures': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-numbers': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/functional': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/instructions': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-types': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/addresses': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-data-structures': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-numbers': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/functional': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/instructions': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-types': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/transactions@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
- dependencies:
- '@solana/addresses': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/codecs-core': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-data-structures': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-numbers': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/codecs-strings': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/functional': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/instructions': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/keys': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc-types': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/transaction-messages': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transactions@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ dependencies:
+ '@solana/addresses': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-data-structures': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-numbers': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-strings': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/functional': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/instructions': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/keys': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-types': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transaction-messages': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- '@solana/web3.js@2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)':
- dependencies:
- '@solana/accounts': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/addresses': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/codecs': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/errors': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/functional': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/instructions': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/keys': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/programs': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/rpc-parsed-types': 2.0.0-rc.0(typescript@5.5.3)
- '@solana/rpc-subscriptions': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)
- '@solana/rpc-types': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/signers': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/sysvars': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/transaction-confirmation': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)
- '@solana/transaction-messages': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
- '@solana/transactions': 2.0.0-rc.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/web3.js@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)':
+ dependencies:
+ '@solana/accounts': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/addresses': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/codecs': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/functional': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/instructions': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/keys': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/programs': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/rpc-parsed-types': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/rpc-subscriptions': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)
+ '@solana/rpc-types': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/signers': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/sysvars': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transaction-confirmation': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)(ws@8.17.0)
+ '@solana/transaction-messages': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@solana/transactions': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
typescript: 5.5.3
transitivePeerDependencies:
- fastestsmallesttextencoderdecoder
- ws
- '@solana/webcrypto-ed25519-polyfill@2.0.0-rc.0(typescript@5.5.3)':
- dependencies:
- '@noble/ed25519': 2.1.0
- typescript: 5.5.3
-
'@types/estree@1.0.5': {}
'@types/json-schema@7.0.15': {}
diff --git a/clients/js/src/generated/accounts/mint.ts b/clients/js/src/generated/accounts/mint.ts
index d1fead6..8001bd5 100644
--- a/clients/js/src/generated/accounts/mint.ts
+++ b/clients/js/src/generated/accounts/mint.ts
@@ -70,7 +70,7 @@ export type Mint = {
/** Optional authority to freeze token accounts. */
freezeAuthority: Option
;
/** The extensions activated on the mint account. */
- extensions: Array;
+ extensions: Option>;
};
export type MintArgs = {
@@ -89,7 +89,7 @@ export type MintArgs = {
/** Optional authority to freeze token accounts. */
freezeAuthority: OptionOrNullable;
/** The extensions activated on the mint account. */
- extensions: Array;
+ extensions: OptionOrNullable>;
};
export function getMintEncoder(): Encoder {
@@ -113,9 +113,12 @@ export function getMintEncoder(): Encoder {
],
[
'extensions',
- getHiddenPrefixEncoder(
- getArrayEncoder(getExtensionEncoder(), { size: 'remainder' }),
- [getConstantEncoder(padLeftEncoder(getU8Encoder(), 83).encode(1))]
+ getOptionEncoder(
+ getHiddenPrefixEncoder(
+ getArrayEncoder(getExtensionEncoder(), { size: 'remainder' }),
+ [getConstantEncoder(padLeftEncoder(getU8Encoder(), 83).encode(1))]
+ ),
+ { prefix: null }
),
],
]);
@@ -142,9 +145,12 @@ export function getMintDecoder(): Decoder {
],
[
'extensions',
- getHiddenPrefixDecoder(
- getArrayDecoder(getExtensionDecoder(), { size: 'remainder' }),
- [getConstantDecoder(padLeftEncoder(getU8Encoder(), 83).encode(1))]
+ getOptionDecoder(
+ getHiddenPrefixDecoder(
+ getArrayDecoder(getExtensionDecoder(), { size: 'remainder' }),
+ [getConstantDecoder(padLeftEncoder(getU8Encoder(), 83).encode(1))]
+ ),
+ { prefix: null }
),
],
]);
diff --git a/clients/js/src/generated/accounts/token.ts b/clients/js/src/generated/accounts/token.ts
index d3ca969..771a035 100644
--- a/clients/js/src/generated/accounts/token.ts
+++ b/clients/js/src/generated/accounts/token.ts
@@ -80,7 +80,7 @@ export type Token = {
/** Optional authority to close the account. */
closeAuthority: Option;
/** The extensions activated on the token account. */
- extensions: Array;
+ extensions: Option>;
};
export type TokenArgs = {
@@ -109,7 +109,7 @@ export type TokenArgs = {
/** Optional authority to close the account. */
closeAuthority: OptionOrNullable;
/** The extensions activated on the token account. */
- extensions: Array;
+ extensions: OptionOrNullable>;
};
export function getTokenEncoder(): Encoder {
@@ -142,9 +142,12 @@ export function getTokenEncoder(): Encoder {
],
[
'extensions',
- getHiddenPrefixEncoder(
- getArrayEncoder(getExtensionEncoder(), { size: 'remainder' }),
- [getConstantEncoder(getU8Encoder().encode(2))]
+ getOptionEncoder(
+ getHiddenPrefixEncoder(
+ getArrayEncoder(getExtensionEncoder(), { size: 'remainder' }),
+ [getConstantEncoder(getU8Encoder().encode(2))]
+ ),
+ { prefix: null }
),
],
]);
@@ -180,9 +183,12 @@ export function getTokenDecoder(): Decoder {
],
[
'extensions',
- getHiddenPrefixDecoder(
- getArrayDecoder(getExtensionDecoder(), { size: 'remainder' }),
- [getConstantDecoder(getU8Encoder().encode(2))]
+ getOptionDecoder(
+ getHiddenPrefixDecoder(
+ getArrayDecoder(getExtensionDecoder(), { size: 'remainder' }),
+ [getConstantDecoder(getU8Encoder().encode(2))]
+ ),
+ { prefix: null }
),
],
]);
diff --git a/clients/js/src/generated/instructions/amountToUiAmount.ts b/clients/js/src/generated/instructions/amountToUiAmount.ts
index f4d4529..62e3ddb 100644
--- a/clients/js/src/generated/instructions/amountToUiAmount.ts
+++ b/clients/js/src/generated/instructions/amountToUiAmount.ts
@@ -28,6 +28,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const AMOUNT_TO_UI_AMOUNT_DISCRIMINATOR = 23;
+
+export function getAmountToUiAmountDiscriminatorBytes() {
+ return getU8Encoder().encode(AMOUNT_TO_UI_AMOUNT_DISCRIMINATOR);
+}
+
export type AmountToUiAmountInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountMint extends string | IAccountMeta = string,
@@ -60,7 +66,7 @@ export function getAmountToUiAmountInstructionDataEncoder(): Encoder ({ ...value, discriminator: 23 })
+ (value) => ({ ...value, discriminator: AMOUNT_TO_UI_AMOUNT_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/approve.ts b/clients/js/src/generated/instructions/approve.ts
index 1dde7d6..9fd45c1 100644
--- a/clients/js/src/generated/instructions/approve.ts
+++ b/clients/js/src/generated/instructions/approve.ts
@@ -33,6 +33,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const APPROVE_DISCRIMINATOR = 4;
+
+export function getApproveDiscriminatorBytes() {
+ return getU8Encoder().encode(APPROVE_DISCRIMINATOR);
+}
+
export type ApproveInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountSource extends string | IAccountMeta = string,
@@ -73,7 +79,7 @@ export function getApproveInstructionDataEncoder(): Encoder ({ ...value, discriminator: 4 })
+ (value) => ({ ...value, discriminator: APPROVE_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/approveChecked.ts b/clients/js/src/generated/instructions/approveChecked.ts
index cac37b5..cda96db 100644
--- a/clients/js/src/generated/instructions/approveChecked.ts
+++ b/clients/js/src/generated/instructions/approveChecked.ts
@@ -33,6 +33,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const APPROVE_CHECKED_DISCRIMINATOR = 13;
+
+export function getApproveCheckedDiscriminatorBytes() {
+ return getU8Encoder().encode(APPROVE_CHECKED_DISCRIMINATOR);
+}
+
export type ApproveCheckedInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountSource extends string | IAccountMeta = string,
@@ -82,7 +88,7 @@ export function getApproveCheckedInstructionDataEncoder(): Encoder ({ ...value, discriminator: 13 })
+ (value) => ({ ...value, discriminator: APPROVE_CHECKED_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/burn.ts b/clients/js/src/generated/instructions/burn.ts
index 1b4b947..a200aac 100644
--- a/clients/js/src/generated/instructions/burn.ts
+++ b/clients/js/src/generated/instructions/burn.ts
@@ -33,6 +33,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const BURN_DISCRIMINATOR = 8;
+
+export function getBurnDiscriminatorBytes() {
+ return getU8Encoder().encode(BURN_DISCRIMINATOR);
+}
+
export type BurnInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountAccount extends string | IAccountMeta = string,
@@ -70,7 +76,7 @@ export function getBurnInstructionDataEncoder(): Encoder ({ ...value, discriminator: 8 })
+ (value) => ({ ...value, discriminator: BURN_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/burnChecked.ts b/clients/js/src/generated/instructions/burnChecked.ts
index 79bc0a5..7df1528 100644
--- a/clients/js/src/generated/instructions/burnChecked.ts
+++ b/clients/js/src/generated/instructions/burnChecked.ts
@@ -33,6 +33,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const BURN_CHECKED_DISCRIMINATOR = 15;
+
+export function getBurnCheckedDiscriminatorBytes() {
+ return getU8Encoder().encode(BURN_CHECKED_DISCRIMINATOR);
+}
+
export type BurnCheckedInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountAccount extends string | IAccountMeta = string,
@@ -78,7 +84,7 @@ export function getBurnCheckedInstructionDataEncoder(): Encoder ({ ...value, discriminator: 15 })
+ (value) => ({ ...value, discriminator: BURN_CHECKED_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/closeAccount.ts b/clients/js/src/generated/instructions/closeAccount.ts
index c8ff230..46ba9b8 100644
--- a/clients/js/src/generated/instructions/closeAccount.ts
+++ b/clients/js/src/generated/instructions/closeAccount.ts
@@ -31,6 +31,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const CLOSE_ACCOUNT_DISCRIMINATOR = 9;
+
+export function getCloseAccountDiscriminatorBytes() {
+ return getU8Encoder().encode(CLOSE_ACCOUNT_DISCRIMINATOR);
+}
+
export type CloseAccountInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountAccount extends string | IAccountMeta = string,
@@ -61,7 +67,7 @@ export type CloseAccountInstructionDataArgs = {};
export function getCloseAccountInstructionDataEncoder(): Encoder {
return transformEncoder(
getStructEncoder([['discriminator', getU8Encoder()]]),
- (value) => ({ ...value, discriminator: 9 })
+ (value) => ({ ...value, discriminator: CLOSE_ACCOUNT_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/createAssociatedToken.ts b/clients/js/src/generated/instructions/createAssociatedToken.ts
index a221c9a..bb14991 100644
--- a/clients/js/src/generated/instructions/createAssociatedToken.ts
+++ b/clients/js/src/generated/instructions/createAssociatedToken.ts
@@ -35,6 +35,12 @@ import {
type ResolvedAccount,
} from '../shared';
+export const CREATE_ASSOCIATED_TOKEN_DISCRIMINATOR = 0;
+
+export function getCreateAssociatedTokenDiscriminatorBytes() {
+ return getU8Encoder().encode(CREATE_ASSOCIATED_TOKEN_DISCRIMINATOR);
+}
+
export type CreateAssociatedTokenInstruction<
TProgram extends string = typeof ASSOCIATED_TOKEN_PROGRAM_ADDRESS,
TAccountPayer extends string | IAccountMeta = string,
@@ -46,7 +52,7 @@ export type CreateAssociatedTokenInstruction<
| IAccountMeta = '11111111111111111111111111111111',
TAccountTokenProgram extends
| string
- | IAccountMeta = 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA',
+ | IAccountMeta = 'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb',
TRemainingAccounts extends readonly IAccountMeta[] = [],
> = IInstruction &
IInstructionWithData &
@@ -80,7 +86,10 @@ export type CreateAssociatedTokenInstructionDataArgs = {};
export function getCreateAssociatedTokenInstructionDataEncoder(): Encoder {
return transformEncoder(
getStructEncoder([['discriminator', getU8Encoder()]]),
- (value) => ({ ...value, discriminator: 0 })
+ (value) => ({
+ ...value,
+ discriminator: CREATE_ASSOCIATED_TOKEN_DISCRIMINATOR,
+ })
);
}
@@ -167,7 +176,7 @@ export async function getCreateAssociatedTokenInstructionAsync<
// Resolve default values.
if (!accounts.tokenProgram.value) {
accounts.tokenProgram.value =
- 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA' as Address<'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA'>;
+ 'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb' as Address<'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb'>;
}
if (!accounts.ata.value) {
accounts.ata.value = await findAssociatedTokenPda({
@@ -273,7 +282,7 @@ export function getCreateAssociatedTokenInstruction<
// Resolve default values.
if (!accounts.tokenProgram.value) {
accounts.tokenProgram.value =
- 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA' as Address<'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA'>;
+ 'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb' as Address<'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb'>;
}
if (!accounts.systemProgram.value) {
accounts.systemProgram.value =
diff --git a/clients/js/src/generated/instructions/createAssociatedTokenIdempotent.ts b/clients/js/src/generated/instructions/createAssociatedTokenIdempotent.ts
index 749f74a..b102a74 100644
--- a/clients/js/src/generated/instructions/createAssociatedTokenIdempotent.ts
+++ b/clients/js/src/generated/instructions/createAssociatedTokenIdempotent.ts
@@ -35,6 +35,14 @@ import {
type ResolvedAccount,
} from '../shared';
+export const CREATE_ASSOCIATED_TOKEN_IDEMPOTENT_DISCRIMINATOR = 1;
+
+export function getCreateAssociatedTokenIdempotentDiscriminatorBytes() {
+ return getU8Encoder().encode(
+ CREATE_ASSOCIATED_TOKEN_IDEMPOTENT_DISCRIMINATOR
+ );
+}
+
export type CreateAssociatedTokenIdempotentInstruction<
TProgram extends string = typeof ASSOCIATED_TOKEN_PROGRAM_ADDRESS,
TAccountPayer extends string | IAccountMeta = string,
@@ -46,7 +54,7 @@ export type CreateAssociatedTokenIdempotentInstruction<
| IAccountMeta = '11111111111111111111111111111111',
TAccountTokenProgram extends
| string
- | IAccountMeta = 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA',
+ | IAccountMeta = 'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb',
TRemainingAccounts extends readonly IAccountMeta[] = [],
> = IInstruction &
IInstructionWithData &
@@ -82,7 +90,10 @@ export type CreateAssociatedTokenIdempotentInstructionDataArgs = {};
export function getCreateAssociatedTokenIdempotentInstructionDataEncoder(): Encoder {
return transformEncoder(
getStructEncoder([['discriminator', getU8Encoder()]]),
- (value) => ({ ...value, discriminator: 1 })
+ (value) => ({
+ ...value,
+ discriminator: CREATE_ASSOCIATED_TOKEN_IDEMPOTENT_DISCRIMINATOR,
+ })
);
}
@@ -169,7 +180,7 @@ export async function getCreateAssociatedTokenIdempotentInstructionAsync<
// Resolve default values.
if (!accounts.tokenProgram.value) {
accounts.tokenProgram.value =
- 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA' as Address<'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA'>;
+ 'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb' as Address<'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb'>;
}
if (!accounts.ata.value) {
accounts.ata.value = await findAssociatedTokenPda({
@@ -275,7 +286,7 @@ export function getCreateAssociatedTokenIdempotentInstruction<
// Resolve default values.
if (!accounts.tokenProgram.value) {
accounts.tokenProgram.value =
- 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA' as Address<'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA'>;
+ 'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb' as Address<'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb'>;
}
if (!accounts.systemProgram.value) {
accounts.systemProgram.value =
diff --git a/clients/js/src/generated/instructions/freezeAccount.ts b/clients/js/src/generated/instructions/freezeAccount.ts
index ca56dec..145dc77 100644
--- a/clients/js/src/generated/instructions/freezeAccount.ts
+++ b/clients/js/src/generated/instructions/freezeAccount.ts
@@ -31,6 +31,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const FREEZE_ACCOUNT_DISCRIMINATOR = 10;
+
+export function getFreezeAccountDiscriminatorBytes() {
+ return getU8Encoder().encode(FREEZE_ACCOUNT_DISCRIMINATOR);
+}
+
export type FreezeAccountInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountAccount extends string | IAccountMeta = string,
@@ -61,7 +67,7 @@ export type FreezeAccountInstructionDataArgs = {};
export function getFreezeAccountInstructionDataEncoder(): Encoder {
return transformEncoder(
getStructEncoder([['discriminator', getU8Encoder()]]),
- (value) => ({ ...value, discriminator: 10 })
+ (value) => ({ ...value, discriminator: FREEZE_ACCOUNT_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/getAccountDataSize.ts b/clients/js/src/generated/instructions/getAccountDataSize.ts
index 1850dce..5dd8b13 100644
--- a/clients/js/src/generated/instructions/getAccountDataSize.ts
+++ b/clients/js/src/generated/instructions/getAccountDataSize.ts
@@ -26,6 +26,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const GET_ACCOUNT_DATA_SIZE_DISCRIMINATOR = 21;
+
+export function getGetAccountDataSizeDiscriminatorBytes() {
+ return getU8Encoder().encode(GET_ACCOUNT_DATA_SIZE_DISCRIMINATOR);
+}
+
export type GetAccountDataSizeInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountMint extends string | IAccountMeta = string,
@@ -48,7 +54,10 @@ export type GetAccountDataSizeInstructionDataArgs = {};
export function getGetAccountDataSizeInstructionDataEncoder(): Encoder {
return transformEncoder(
getStructEncoder([['discriminator', getU8Encoder()]]),
- (value) => ({ ...value, discriminator: 21 })
+ (value) => ({
+ ...value,
+ discriminator: GET_ACCOUNT_DATA_SIZE_DISCRIMINATOR,
+ })
);
}
diff --git a/clients/js/src/generated/instructions/index.ts b/clients/js/src/generated/instructions/index.ts
index fbda370..38b9e85 100644
--- a/clients/js/src/generated/instructions/index.ts
+++ b/clients/js/src/generated/instructions/index.ts
@@ -22,8 +22,10 @@ export * from './initializeAccount3';
export * from './initializeImmutableOwner';
export * from './initializeMint';
export * from './initializeMint2';
+export * from './initializeMintCloseAuthority';
export * from './initializeMultisig';
export * from './initializeMultisig2';
+export * from './initializeTransferFeeConfig';
export * from './mintTo';
export * from './mintToChecked';
export * from './recoverNestedAssociatedToken';
diff --git a/clients/js/src/generated/instructions/initializeAccount.ts b/clients/js/src/generated/instructions/initializeAccount.ts
index 8f06325..9ec7e2d 100644
--- a/clients/js/src/generated/instructions/initializeAccount.ts
+++ b/clients/js/src/generated/instructions/initializeAccount.ts
@@ -27,6 +27,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const INITIALIZE_ACCOUNT_DISCRIMINATOR = 1;
+
+export function getInitializeAccountDiscriminatorBytes() {
+ return getU8Encoder().encode(INITIALIZE_ACCOUNT_DISCRIMINATOR);
+}
+
export type InitializeAccountInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountAccount extends string | IAccountMeta = string,
@@ -63,7 +69,7 @@ export type InitializeAccountInstructionDataArgs = {};
export function getInitializeAccountInstructionDataEncoder(): Encoder {
return transformEncoder(
getStructEncoder([['discriminator', getU8Encoder()]]),
- (value) => ({ ...value, discriminator: 1 })
+ (value) => ({ ...value, discriminator: INITIALIZE_ACCOUNT_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/initializeAccount2.ts b/clients/js/src/generated/instructions/initializeAccount2.ts
index af2eaf6..bcd0773 100644
--- a/clients/js/src/generated/instructions/initializeAccount2.ts
+++ b/clients/js/src/generated/instructions/initializeAccount2.ts
@@ -29,6 +29,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const INITIALIZE_ACCOUNT2_DISCRIMINATOR = 16;
+
+export function getInitializeAccount2DiscriminatorBytes() {
+ return getU8Encoder().encode(INITIALIZE_ACCOUNT2_DISCRIMINATOR);
+}
+
export type InitializeAccount2Instruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountAccount extends string | IAccountMeta = string,
@@ -71,7 +77,7 @@ export function getInitializeAccount2InstructionDataEncoder(): Encoder ({ ...value, discriminator: 16 })
+ (value) => ({ ...value, discriminator: INITIALIZE_ACCOUNT2_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/initializeAccount3.ts b/clients/js/src/generated/instructions/initializeAccount3.ts
index 0a8a689..f4c7cae 100644
--- a/clients/js/src/generated/instructions/initializeAccount3.ts
+++ b/clients/js/src/generated/instructions/initializeAccount3.ts
@@ -29,6 +29,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const INITIALIZE_ACCOUNT3_DISCRIMINATOR = 18;
+
+export function getInitializeAccount3DiscriminatorBytes() {
+ return getU8Encoder().encode(INITIALIZE_ACCOUNT3_DISCRIMINATOR);
+}
+
export type InitializeAccount3Instruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountAccount extends string | IAccountMeta = string,
@@ -65,7 +71,7 @@ export function getInitializeAccount3InstructionDataEncoder(): Encoder ({ ...value, discriminator: 18 })
+ (value) => ({ ...value, discriminator: INITIALIZE_ACCOUNT3_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/initializeImmutableOwner.ts b/clients/js/src/generated/instructions/initializeImmutableOwner.ts
index bce0f46..3e6991c 100644
--- a/clients/js/src/generated/instructions/initializeImmutableOwner.ts
+++ b/clients/js/src/generated/instructions/initializeImmutableOwner.ts
@@ -26,6 +26,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const INITIALIZE_IMMUTABLE_OWNER_DISCRIMINATOR = 22;
+
+export function getInitializeImmutableOwnerDiscriminatorBytes() {
+ return getU8Encoder().encode(INITIALIZE_IMMUTABLE_OWNER_DISCRIMINATOR);
+}
+
export type InitializeImmutableOwnerInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountAccount extends string | IAccountMeta = string,
@@ -48,7 +54,10 @@ export type InitializeImmutableOwnerInstructionDataArgs = {};
export function getInitializeImmutableOwnerInstructionDataEncoder(): Encoder {
return transformEncoder(
getStructEncoder([['discriminator', getU8Encoder()]]),
- (value) => ({ ...value, discriminator: 22 })
+ (value) => ({
+ ...value,
+ discriminator: INITIALIZE_IMMUTABLE_OWNER_DISCRIMINATOR,
+ })
);
}
diff --git a/clients/js/src/generated/instructions/initializeMint.ts b/clients/js/src/generated/instructions/initializeMint.ts
index 67fd2b0..1b27ec5 100644
--- a/clients/js/src/generated/instructions/initializeMint.ts
+++ b/clients/js/src/generated/instructions/initializeMint.ts
@@ -34,6 +34,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const INITIALIZE_MINT_DISCRIMINATOR = 0;
+
+export function getInitializeMintDiscriminatorBytes() {
+ return getU8Encoder().encode(INITIALIZE_MINT_DISCRIMINATOR);
+}
+
export type InitializeMintInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountMint extends string | IAccountMeta = string,
@@ -84,7 +90,7 @@ export function getInitializeMintInstructionDataEncoder(): Encoder ({
...value,
- discriminator: 0,
+ discriminator: INITIALIZE_MINT_DISCRIMINATOR,
freezeAuthority: value.freezeAuthority ?? none(),
})
);
diff --git a/clients/js/src/generated/instructions/initializeMint2.ts b/clients/js/src/generated/instructions/initializeMint2.ts
index ac40be4..d982a72 100644
--- a/clients/js/src/generated/instructions/initializeMint2.ts
+++ b/clients/js/src/generated/instructions/initializeMint2.ts
@@ -33,6 +33,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const INITIALIZE_MINT2_DISCRIMINATOR = 20;
+
+export function getInitializeMint2DiscriminatorBytes() {
+ return getU8Encoder().encode(INITIALIZE_MINT2_DISCRIMINATOR);
+}
+
export type InitializeMint2Instruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountMint extends string | IAccountMeta = string,
@@ -77,7 +83,7 @@ export function getInitializeMint2InstructionDataEncoder(): Encoder ({
...value,
- discriminator: 20,
+ discriminator: INITIALIZE_MINT2_DISCRIMINATOR,
freezeAuthority: value.freezeAuthority ?? none(),
})
);
diff --git a/clients/js/src/generated/instructions/initializeMintCloseAuthority.ts b/clients/js/src/generated/instructions/initializeMintCloseAuthority.ts
new file mode 100644
index 0000000..3cddb2c
--- /dev/null
+++ b/clients/js/src/generated/instructions/initializeMintCloseAuthority.ts
@@ -0,0 +1,182 @@
+/**
+ * This code was AUTOGENERATED using the kinobi library.
+ * Please DO NOT EDIT THIS FILE, instead use visitors
+ * to add features, then rerun kinobi to update it.
+ *
+ * @see https://github.com/kinobi-so/kinobi
+ */
+
+import {
+ combineCodec,
+ getAddressDecoder,
+ getAddressEncoder,
+ getOptionDecoder,
+ getOptionEncoder,
+ getStructDecoder,
+ getStructEncoder,
+ getU8Decoder,
+ getU8Encoder,
+ transformEncoder,
+ type Address,
+ type Codec,
+ type Decoder,
+ type Encoder,
+ type IAccountMeta,
+ type IInstruction,
+ type IInstructionWithAccounts,
+ type IInstructionWithData,
+ type Option,
+ type OptionOrNullable,
+ type WritableAccount,
+} from '@solana/web3.js';
+import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
+import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+
+export const INITIALIZE_MINT_CLOSE_AUTHORITY_DISCRIMINATOR = 25;
+
+export function getInitializeMintCloseAuthorityDiscriminatorBytes() {
+ return getU8Encoder().encode(INITIALIZE_MINT_CLOSE_AUTHORITY_DISCRIMINATOR);
+}
+
+export type InitializeMintCloseAuthorityInstruction<
+ TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
+ TAccountMint extends string | IAccountMeta = string,
+ TRemainingAccounts extends readonly IAccountMeta[] = [],
+> = IInstruction &
+ IInstructionWithData &
+ IInstructionWithAccounts<
+ [
+ TAccountMint extends string
+ ? WritableAccount
+ : TAccountMint,
+ ...TRemainingAccounts,
+ ]
+ >;
+
+export type InitializeMintCloseAuthorityInstructionData = {
+ discriminator: number;
+ /** Authority that must sign the `CloseAccount` instruction on a mint. */
+ closeAuthority: Option;
+};
+
+export type InitializeMintCloseAuthorityInstructionDataArgs = {
+ /** Authority that must sign the `CloseAccount` instruction on a mint. */
+ closeAuthority: OptionOrNullable;
+};
+
+export function getInitializeMintCloseAuthorityInstructionDataEncoder(): Encoder {
+ return transformEncoder(
+ getStructEncoder([
+ ['discriminator', getU8Encoder()],
+ ['closeAuthority', getOptionEncoder(getAddressEncoder())],
+ ]),
+ (value) => ({
+ ...value,
+ discriminator: INITIALIZE_MINT_CLOSE_AUTHORITY_DISCRIMINATOR,
+ })
+ );
+}
+
+export function getInitializeMintCloseAuthorityInstructionDataDecoder(): Decoder {
+ return getStructDecoder([
+ ['discriminator', getU8Decoder()],
+ ['closeAuthority', getOptionDecoder(getAddressDecoder())],
+ ]);
+}
+
+export function getInitializeMintCloseAuthorityInstructionDataCodec(): Codec<
+ InitializeMintCloseAuthorityInstructionDataArgs,
+ InitializeMintCloseAuthorityInstructionData
+> {
+ return combineCodec(
+ getInitializeMintCloseAuthorityInstructionDataEncoder(),
+ getInitializeMintCloseAuthorityInstructionDataDecoder()
+ );
+}
+
+export type InitializeMintCloseAuthorityInput<
+ TAccountMint extends string = string,
+> = {
+ /** The mint to initialize. */
+ mint: Address;
+ closeAuthority: InitializeMintCloseAuthorityInstructionDataArgs['closeAuthority'];
+};
+
+export function getInitializeMintCloseAuthorityInstruction<
+ TAccountMint extends string,
+>(
+ input: InitializeMintCloseAuthorityInput
+): InitializeMintCloseAuthorityInstruction<
+ typeof TOKEN_2022_PROGRAM_ADDRESS,
+ TAccountMint
+> {
+ // Program address.
+ const programAddress = TOKEN_2022_PROGRAM_ADDRESS;
+
+ // Original accounts.
+ const originalAccounts = {
+ mint: { value: input.mint ?? null, isWritable: true },
+ };
+ const accounts = originalAccounts as Record<
+ keyof typeof originalAccounts,
+ ResolvedAccount
+ >;
+
+ // Original args.
+ const args = { ...input };
+
+ const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');
+ const instruction = {
+ accounts: [getAccountMeta(accounts.mint)],
+ programAddress,
+ data: getInitializeMintCloseAuthorityInstructionDataEncoder().encode(
+ args as InitializeMintCloseAuthorityInstructionDataArgs
+ ),
+ } as InitializeMintCloseAuthorityInstruction<
+ typeof TOKEN_2022_PROGRAM_ADDRESS,
+ TAccountMint
+ >;
+
+ return instruction;
+}
+
+export type ParsedInitializeMintCloseAuthorityInstruction<
+ TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
+ TAccountMetas extends readonly IAccountMeta[] = readonly IAccountMeta[],
+> = {
+ programAddress: Address;
+ accounts: {
+ /** The mint to initialize. */
+ mint: TAccountMetas[0];
+ };
+ data: InitializeMintCloseAuthorityInstructionData;
+};
+
+export function parseInitializeMintCloseAuthorityInstruction<
+ TProgram extends string,
+ TAccountMetas extends readonly IAccountMeta[],
+>(
+ instruction: IInstruction &
+ IInstructionWithAccounts &
+ IInstructionWithData
+): ParsedInitializeMintCloseAuthorityInstruction {
+ if (instruction.accounts.length < 1) {
+ // TODO: Coded error.
+ throw new Error('Not enough accounts');
+ }
+ let accountIndex = 0;
+ const getNextAccount = () => {
+ const accountMeta = instruction.accounts![accountIndex]!;
+ accountIndex += 1;
+ return accountMeta;
+ };
+ return {
+ programAddress: instruction.programAddress,
+ accounts: {
+ mint: getNextAccount(),
+ },
+ data: getInitializeMintCloseAuthorityInstructionDataDecoder().decode(
+ instruction.data
+ ),
+ };
+}
diff --git a/clients/js/src/generated/instructions/initializeMultisig.ts b/clients/js/src/generated/instructions/initializeMultisig.ts
index 35f3ef5..6fac79a 100644
--- a/clients/js/src/generated/instructions/initializeMultisig.ts
+++ b/clients/js/src/generated/instructions/initializeMultisig.ts
@@ -28,6 +28,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const INITIALIZE_MULTISIG_DISCRIMINATOR = 2;
+
+export function getInitializeMultisigDiscriminatorBytes() {
+ return getU8Encoder().encode(INITIALIZE_MULTISIG_DISCRIMINATOR);
+}
+
export type InitializeMultisigInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountMultisig extends string | IAccountMeta = string,
@@ -66,7 +72,7 @@ export function getInitializeMultisigInstructionDataEncoder(): Encoder ({ ...value, discriminator: 2 })
+ (value) => ({ ...value, discriminator: INITIALIZE_MULTISIG_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/initializeMultisig2.ts b/clients/js/src/generated/instructions/initializeMultisig2.ts
index b281538..2acfe1a 100644
--- a/clients/js/src/generated/instructions/initializeMultisig2.ts
+++ b/clients/js/src/generated/instructions/initializeMultisig2.ts
@@ -27,6 +27,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const INITIALIZE_MULTISIG2_DISCRIMINATOR = 19;
+
+export function getInitializeMultisig2DiscriminatorBytes() {
+ return getU8Encoder().encode(INITIALIZE_MULTISIG2_DISCRIMINATOR);
+}
+
export type InitializeMultisig2Instruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountMultisig extends string | IAccountMeta = string,
@@ -59,7 +65,7 @@ export function getInitializeMultisig2InstructionDataEncoder(): Encoder ({ ...value, discriminator: 19 })
+ (value) => ({ ...value, discriminator: INITIALIZE_MULTISIG2_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/initializeTransferFeeConfig.ts b/clients/js/src/generated/instructions/initializeTransferFeeConfig.ts
new file mode 100644
index 0000000..fe9cafb
--- /dev/null
+++ b/clients/js/src/generated/instructions/initializeTransferFeeConfig.ts
@@ -0,0 +1,220 @@
+/**
+ * This code was AUTOGENERATED using the kinobi library.
+ * Please DO NOT EDIT THIS FILE, instead use visitors
+ * to add features, then rerun kinobi to update it.
+ *
+ * @see https://github.com/kinobi-so/kinobi
+ */
+
+import {
+ combineCodec,
+ getAddressDecoder,
+ getAddressEncoder,
+ getOptionDecoder,
+ getOptionEncoder,
+ getStructDecoder,
+ getStructEncoder,
+ getU16Decoder,
+ getU16Encoder,
+ getU64Decoder,
+ getU64Encoder,
+ getU8Decoder,
+ getU8Encoder,
+ transformEncoder,
+ type Address,
+ type Codec,
+ type Decoder,
+ type Encoder,
+ type IAccountMeta,
+ type IInstruction,
+ type IInstructionWithAccounts,
+ type IInstructionWithData,
+ type Option,
+ type OptionOrNullable,
+ type WritableAccount,
+} from '@solana/web3.js';
+import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
+import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+
+export const INITIALIZE_TRANSFER_FEE_CONFIG_DISCRIMINATOR = 26;
+
+export function getInitializeTransferFeeConfigDiscriminatorBytes() {
+ return getU8Encoder().encode(INITIALIZE_TRANSFER_FEE_CONFIG_DISCRIMINATOR);
+}
+
+export const INITIALIZE_TRANSFER_FEE_CONFIG_TRANSFER_FEE_DISCRIMINATOR = 0;
+
+export function getInitializeTransferFeeConfigTransferFeeDiscriminatorBytes() {
+ return getU8Encoder().encode(
+ INITIALIZE_TRANSFER_FEE_CONFIG_TRANSFER_FEE_DISCRIMINATOR
+ );
+}
+
+export type InitializeTransferFeeConfigInstruction<
+ TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
+ TAccountMint extends string | IAccountMeta = string,
+ TRemainingAccounts extends readonly IAccountMeta[] = [],
+> = IInstruction &
+ IInstructionWithData &
+ IInstructionWithAccounts<
+ [
+ TAccountMint extends string
+ ? WritableAccount
+ : TAccountMint,
+ ...TRemainingAccounts,
+ ]
+ >;
+
+export type InitializeTransferFeeConfigInstructionData = {
+ discriminator: number;
+ transferFeeDiscriminator: number;
+ /** Pubkey that may update the fees. */
+ transferFeeConfigAuthority: Option;
+ /** Withdraw instructions must be signed by this key. */
+ withdrawWithheldAuthority: Option;
+ /** Amount of transfer collected as fees, expressed as basis points of the transfer amount. */
+ transferFeeBasisPoints: number;
+ /** Maximum fee assessed on transfers. */
+ maximumFee: bigint;
+};
+
+export type InitializeTransferFeeConfigInstructionDataArgs = {
+ /** Pubkey that may update the fees. */
+ transferFeeConfigAuthority: OptionOrNullable;
+ /** Withdraw instructions must be signed by this key. */
+ withdrawWithheldAuthority: OptionOrNullable;
+ /** Amount of transfer collected as fees, expressed as basis points of the transfer amount. */
+ transferFeeBasisPoints: number;
+ /** Maximum fee assessed on transfers. */
+ maximumFee: number | bigint;
+};
+
+export function getInitializeTransferFeeConfigInstructionDataEncoder(): Encoder {
+ return transformEncoder(
+ getStructEncoder([
+ ['discriminator', getU8Encoder()],
+ ['transferFeeDiscriminator', getU8Encoder()],
+ ['transferFeeConfigAuthority', getOptionEncoder(getAddressEncoder())],
+ ['withdrawWithheldAuthority', getOptionEncoder(getAddressEncoder())],
+ ['transferFeeBasisPoints', getU16Encoder()],
+ ['maximumFee', getU64Encoder()],
+ ]),
+ (value) => ({
+ ...value,
+ discriminator: INITIALIZE_TRANSFER_FEE_CONFIG_DISCRIMINATOR,
+ transferFeeDiscriminator:
+ INITIALIZE_TRANSFER_FEE_CONFIG_TRANSFER_FEE_DISCRIMINATOR,
+ })
+ );
+}
+
+export function getInitializeTransferFeeConfigInstructionDataDecoder(): Decoder {
+ return getStructDecoder([
+ ['discriminator', getU8Decoder()],
+ ['transferFeeDiscriminator', getU8Decoder()],
+ ['transferFeeConfigAuthority', getOptionDecoder(getAddressDecoder())],
+ ['withdrawWithheldAuthority', getOptionDecoder(getAddressDecoder())],
+ ['transferFeeBasisPoints', getU16Decoder()],
+ ['maximumFee', getU64Decoder()],
+ ]);
+}
+
+export function getInitializeTransferFeeConfigInstructionDataCodec(): Codec<
+ InitializeTransferFeeConfigInstructionDataArgs,
+ InitializeTransferFeeConfigInstructionData
+> {
+ return combineCodec(
+ getInitializeTransferFeeConfigInstructionDataEncoder(),
+ getInitializeTransferFeeConfigInstructionDataDecoder()
+ );
+}
+
+export type InitializeTransferFeeConfigInput<
+ TAccountMint extends string = string,
+> = {
+ /** The mint to initialize. */
+ mint: Address;
+ transferFeeConfigAuthority: InitializeTransferFeeConfigInstructionDataArgs['transferFeeConfigAuthority'];
+ withdrawWithheldAuthority: InitializeTransferFeeConfigInstructionDataArgs['withdrawWithheldAuthority'];
+ transferFeeBasisPoints: InitializeTransferFeeConfigInstructionDataArgs['transferFeeBasisPoints'];
+ maximumFee: InitializeTransferFeeConfigInstructionDataArgs['maximumFee'];
+};
+
+export function getInitializeTransferFeeConfigInstruction<
+ TAccountMint extends string,
+>(
+ input: InitializeTransferFeeConfigInput
+): InitializeTransferFeeConfigInstruction<
+ typeof TOKEN_2022_PROGRAM_ADDRESS,
+ TAccountMint
+> {
+ // Program address.
+ const programAddress = TOKEN_2022_PROGRAM_ADDRESS;
+
+ // Original accounts.
+ const originalAccounts = {
+ mint: { value: input.mint ?? null, isWritable: true },
+ };
+ const accounts = originalAccounts as Record<
+ keyof typeof originalAccounts,
+ ResolvedAccount
+ >;
+
+ // Original args.
+ const args = { ...input };
+
+ const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');
+ const instruction = {
+ accounts: [getAccountMeta(accounts.mint)],
+ programAddress,
+ data: getInitializeTransferFeeConfigInstructionDataEncoder().encode(
+ args as InitializeTransferFeeConfigInstructionDataArgs
+ ),
+ } as InitializeTransferFeeConfigInstruction<
+ typeof TOKEN_2022_PROGRAM_ADDRESS,
+ TAccountMint
+ >;
+
+ return instruction;
+}
+
+export type ParsedInitializeTransferFeeConfigInstruction<
+ TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
+ TAccountMetas extends readonly IAccountMeta[] = readonly IAccountMeta[],
+> = {
+ programAddress: Address;
+ accounts: {
+ /** The mint to initialize. */
+ mint: TAccountMetas[0];
+ };
+ data: InitializeTransferFeeConfigInstructionData;
+};
+
+export function parseInitializeTransferFeeConfigInstruction<
+ TProgram extends string,
+ TAccountMetas extends readonly IAccountMeta[],
+>(
+ instruction: IInstruction &
+ IInstructionWithAccounts &
+ IInstructionWithData
+): ParsedInitializeTransferFeeConfigInstruction {
+ if (instruction.accounts.length < 1) {
+ // TODO: Coded error.
+ throw new Error('Not enough accounts');
+ }
+ let accountIndex = 0;
+ const getNextAccount = () => {
+ const accountMeta = instruction.accounts![accountIndex]!;
+ accountIndex += 1;
+ return accountMeta;
+ };
+ return {
+ programAddress: instruction.programAddress,
+ accounts: {
+ mint: getNextAccount(),
+ },
+ data: getInitializeTransferFeeConfigInstructionDataDecoder().decode(
+ instruction.data
+ ),
+ };
+}
diff --git a/clients/js/src/generated/instructions/mintTo.ts b/clients/js/src/generated/instructions/mintTo.ts
index 4b781ce..779b5b6 100644
--- a/clients/js/src/generated/instructions/mintTo.ts
+++ b/clients/js/src/generated/instructions/mintTo.ts
@@ -33,6 +33,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const MINT_TO_DISCRIMINATOR = 7;
+
+export function getMintToDiscriminatorBytes() {
+ return getU8Encoder().encode(MINT_TO_DISCRIMINATOR);
+}
+
export type MintToInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountMint extends string | IAccountMeta = string,
@@ -73,7 +79,7 @@ export function getMintToInstructionDataEncoder(): Encoder ({ ...value, discriminator: 7 })
+ (value) => ({ ...value, discriminator: MINT_TO_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/mintToChecked.ts b/clients/js/src/generated/instructions/mintToChecked.ts
index 00ffa87..10869da 100644
--- a/clients/js/src/generated/instructions/mintToChecked.ts
+++ b/clients/js/src/generated/instructions/mintToChecked.ts
@@ -33,6 +33,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const MINT_TO_CHECKED_DISCRIMINATOR = 14;
+
+export function getMintToCheckedDiscriminatorBytes() {
+ return getU8Encoder().encode(MINT_TO_CHECKED_DISCRIMINATOR);
+}
+
export type MintToCheckedInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountMint extends string | IAccountMeta = string,
@@ -78,7 +84,7 @@ export function getMintToCheckedInstructionDataEncoder(): Encoder ({ ...value, discriminator: 14 })
+ (value) => ({ ...value, discriminator: MINT_TO_CHECKED_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/recoverNestedAssociatedToken.ts b/clients/js/src/generated/instructions/recoverNestedAssociatedToken.ts
index 8dd54f2..33c601a 100644
--- a/clients/js/src/generated/instructions/recoverNestedAssociatedToken.ts
+++ b/clients/js/src/generated/instructions/recoverNestedAssociatedToken.ts
@@ -35,6 +35,12 @@ import {
type ResolvedAccount,
} from '../shared';
+export const RECOVER_NESTED_ASSOCIATED_TOKEN_DISCRIMINATOR = 2;
+
+export function getRecoverNestedAssociatedTokenDiscriminatorBytes() {
+ return getU8Encoder().encode(RECOVER_NESTED_ASSOCIATED_TOKEN_DISCRIMINATOR);
+}
+
export type RecoverNestedAssociatedTokenInstruction<
TProgram extends string = typeof ASSOCIATED_TOKEN_PROGRAM_ADDRESS,
TAccountNestedAssociatedAccountAddress extends
@@ -51,7 +57,7 @@ export type RecoverNestedAssociatedTokenInstruction<
TAccountWalletAddress extends string | IAccountMeta = string,
TAccountTokenProgram extends
| string
- | IAccountMeta = 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA',
+ | IAccountMeta = 'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb',
TRemainingAccounts extends readonly IAccountMeta[] = [],
> = IInstruction &
IInstructionWithData &
@@ -92,7 +98,10 @@ export type RecoverNestedAssociatedTokenInstructionDataArgs = {};
export function getRecoverNestedAssociatedTokenInstructionDataEncoder(): Encoder {
return transformEncoder(
getStructEncoder([['discriminator', getU8Encoder()]]),
- (value) => ({ ...value, discriminator: 2 })
+ (value) => ({
+ ...value,
+ discriminator: RECOVER_NESTED_ASSOCIATED_TOKEN_DISCRIMINATOR,
+ })
);
}
@@ -201,7 +210,7 @@ export async function getRecoverNestedAssociatedTokenInstructionAsync<
// Resolve default values.
if (!accounts.tokenProgram.value) {
accounts.tokenProgram.value =
- 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA' as Address<'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA'>;
+ 'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb' as Address<'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb'>;
}
if (!accounts.ownerAssociatedAccountAddress.value) {
accounts.ownerAssociatedAccountAddress.value = await findAssociatedTokenPda(
@@ -345,7 +354,7 @@ export function getRecoverNestedAssociatedTokenInstruction<
// Resolve default values.
if (!accounts.tokenProgram.value) {
accounts.tokenProgram.value =
- 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA' as Address<'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA'>;
+ 'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb' as Address<'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb'>;
}
const getAccountMeta = getAccountMetaFactory(programAddress, 'programId');
diff --git a/clients/js/src/generated/instructions/revoke.ts b/clients/js/src/generated/instructions/revoke.ts
index a2872fb..71524be 100644
--- a/clients/js/src/generated/instructions/revoke.ts
+++ b/clients/js/src/generated/instructions/revoke.ts
@@ -31,6 +31,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const REVOKE_DISCRIMINATOR = 5;
+
+export function getRevokeDiscriminatorBytes() {
+ return getU8Encoder().encode(REVOKE_DISCRIMINATOR);
+}
+
export type RevokeInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountSource extends string | IAccountMeta = string,
@@ -57,7 +63,7 @@ export type RevokeInstructionDataArgs = {};
export function getRevokeInstructionDataEncoder(): Encoder {
return transformEncoder(
getStructEncoder([['discriminator', getU8Encoder()]]),
- (value) => ({ ...value, discriminator: 5 })
+ (value) => ({ ...value, discriminator: REVOKE_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/setAuthority.ts b/clients/js/src/generated/instructions/setAuthority.ts
index c0e30a7..edb424f 100644
--- a/clients/js/src/generated/instructions/setAuthority.ts
+++ b/clients/js/src/generated/instructions/setAuthority.ts
@@ -43,6 +43,12 @@ import {
type AuthorityTypeArgs,
} from '../types';
+export const SET_AUTHORITY_DISCRIMINATOR = 6;
+
+export function getSetAuthorityDiscriminatorBytes() {
+ return getU8Encoder().encode(SET_AUTHORITY_DISCRIMINATOR);
+}
+
export type SetAuthorityInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountOwned extends string | IAccountMeta = string,
@@ -84,7 +90,7 @@ export function getSetAuthorityInstructionDataEncoder(): Encoder ({ ...value, discriminator: 6 })
+ (value) => ({ ...value, discriminator: SET_AUTHORITY_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/syncNative.ts b/clients/js/src/generated/instructions/syncNative.ts
index a18350f..85f2bb6 100644
--- a/clients/js/src/generated/instructions/syncNative.ts
+++ b/clients/js/src/generated/instructions/syncNative.ts
@@ -26,6 +26,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const SYNC_NATIVE_DISCRIMINATOR = 17;
+
+export function getSyncNativeDiscriminatorBytes() {
+ return getU8Encoder().encode(SYNC_NATIVE_DISCRIMINATOR);
+}
+
export type SyncNativeInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountAccount extends string | IAccountMeta = string,
@@ -48,7 +54,7 @@ export type SyncNativeInstructionDataArgs = {};
export function getSyncNativeInstructionDataEncoder(): Encoder {
return transformEncoder(
getStructEncoder([['discriminator', getU8Encoder()]]),
- (value) => ({ ...value, discriminator: 17 })
+ (value) => ({ ...value, discriminator: SYNC_NATIVE_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/thawAccount.ts b/clients/js/src/generated/instructions/thawAccount.ts
index a80ba4a..a692637 100644
--- a/clients/js/src/generated/instructions/thawAccount.ts
+++ b/clients/js/src/generated/instructions/thawAccount.ts
@@ -31,6 +31,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const THAW_ACCOUNT_DISCRIMINATOR = 11;
+
+export function getThawAccountDiscriminatorBytes() {
+ return getU8Encoder().encode(THAW_ACCOUNT_DISCRIMINATOR);
+}
+
export type ThawAccountInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountAccount extends string | IAccountMeta = string,
@@ -61,7 +67,7 @@ export type ThawAccountInstructionDataArgs = {};
export function getThawAccountInstructionDataEncoder(): Encoder {
return transformEncoder(
getStructEncoder([['discriminator', getU8Encoder()]]),
- (value) => ({ ...value, discriminator: 11 })
+ (value) => ({ ...value, discriminator: THAW_ACCOUNT_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/transfer.ts b/clients/js/src/generated/instructions/transfer.ts
index c919980..c1bc36c 100644
--- a/clients/js/src/generated/instructions/transfer.ts
+++ b/clients/js/src/generated/instructions/transfer.ts
@@ -33,6 +33,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const TRANSFER_DISCRIMINATOR = 3;
+
+export function getTransferDiscriminatorBytes() {
+ return getU8Encoder().encode(TRANSFER_DISCRIMINATOR);
+}
+
export type TransferInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountSource extends string | IAccountMeta = string,
@@ -73,7 +79,7 @@ export function getTransferInstructionDataEncoder(): Encoder ({ ...value, discriminator: 3 })
+ (value) => ({ ...value, discriminator: TRANSFER_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/transferChecked.ts b/clients/js/src/generated/instructions/transferChecked.ts
index bbe46f6..fb7b51b 100644
--- a/clients/js/src/generated/instructions/transferChecked.ts
+++ b/clients/js/src/generated/instructions/transferChecked.ts
@@ -33,6 +33,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const TRANSFER_CHECKED_DISCRIMINATOR = 12;
+
+export function getTransferCheckedDiscriminatorBytes() {
+ return getU8Encoder().encode(TRANSFER_CHECKED_DISCRIMINATOR);
+}
+
export type TransferCheckedInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountSource extends string | IAccountMeta = string,
@@ -82,7 +88,7 @@ export function getTransferCheckedInstructionDataEncoder(): Encoder ({ ...value, discriminator: 12 })
+ (value) => ({ ...value, discriminator: TRANSFER_CHECKED_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/instructions/uiAmountToAmount.ts b/clients/js/src/generated/instructions/uiAmountToAmount.ts
index 73da41e..035ddc0 100644
--- a/clients/js/src/generated/instructions/uiAmountToAmount.ts
+++ b/clients/js/src/generated/instructions/uiAmountToAmount.ts
@@ -28,6 +28,12 @@ import {
import { TOKEN_2022_PROGRAM_ADDRESS } from '../programs';
import { getAccountMetaFactory, type ResolvedAccount } from '../shared';
+export const UI_AMOUNT_TO_AMOUNT_DISCRIMINATOR = 24;
+
+export function getUiAmountToAmountDiscriminatorBytes() {
+ return getU8Encoder().encode(UI_AMOUNT_TO_AMOUNT_DISCRIMINATOR);
+}
+
export type UiAmountToAmountInstruction<
TProgram extends string = typeof TOKEN_2022_PROGRAM_ADDRESS,
TAccountMint extends string | IAccountMeta = string,
@@ -60,7 +66,7 @@ export function getUiAmountToAmountInstructionDataEncoder(): Encoder ({ ...value, discriminator: 24 })
+ (value) => ({ ...value, discriminator: UI_AMOUNT_TO_AMOUNT_DISCRIMINATOR })
);
}
diff --git a/clients/js/src/generated/programs/token2022.ts b/clients/js/src/generated/programs/token2022.ts
index 8c5ba43..47741da 100644
--- a/clients/js/src/generated/programs/token2022.ts
+++ b/clients/js/src/generated/programs/token2022.ts
@@ -26,9 +26,11 @@ import {
type ParsedInitializeAccountInstruction,
type ParsedInitializeImmutableOwnerInstruction,
type ParsedInitializeMint2Instruction,
+ type ParsedInitializeMintCloseAuthorityInstruction,
type ParsedInitializeMintInstruction,
type ParsedInitializeMultisig2Instruction,
type ParsedInitializeMultisigInstruction,
+ type ParsedInitializeTransferFeeConfigInstruction,
type ParsedMintToCheckedInstruction,
type ParsedMintToInstruction,
type ParsedRevokeInstruction,
@@ -93,6 +95,8 @@ export enum Token2022Instruction {
InitializeImmutableOwner,
AmountToUiAmount,
UiAmountToAmount,
+ InitializeMintCloseAuthority,
+ InitializeTransferFeeConfig,
}
export function identifyToken2022Instruction(
@@ -174,6 +178,15 @@ export function identifyToken2022Instruction(
if (containsBytes(data, getU8Encoder().encode(24), 0)) {
return Token2022Instruction.UiAmountToAmount;
}
+ if (containsBytes(data, getU8Encoder().encode(25), 0)) {
+ return Token2022Instruction.InitializeMintCloseAuthority;
+ }
+ if (
+ containsBytes(data, getU8Encoder().encode(26), 0) &&
+ containsBytes(data, getU8Encoder().encode(0), 1)
+ ) {
+ return Token2022Instruction.InitializeTransferFeeConfig;
+ }
throw new Error(
'The provided instruction could not be identified as a token-2022 instruction.'
);
@@ -256,4 +269,10 @@ export type ParsedToken2022Instruction<
} & ParsedAmountToUiAmountInstruction)
| ({
instructionType: Token2022Instruction.UiAmountToAmount;
- } & ParsedUiAmountToAmountInstruction);
+ } & ParsedUiAmountToAmountInstruction)
+ | ({
+ instructionType: Token2022Instruction.InitializeMintCloseAuthority;
+ } & ParsedInitializeMintCloseAuthorityInstruction)
+ | ({
+ instructionType: Token2022Instruction.InitializeTransferFeeConfig;
+ } & ParsedInitializeTransferFeeConfigInstruction);
diff --git a/clients/js/src/getMintSize.ts b/clients/js/src/getMintSize.ts
new file mode 100644
index 0000000..de2f9a1
--- /dev/null
+++ b/clients/js/src/getMintSize.ts
@@ -0,0 +1,19 @@
+import {
+ getArrayEncoder,
+ getConstantEncoder,
+ getHiddenPrefixEncoder,
+ getU8Encoder,
+ padLeftEncoder,
+} from '@solana/web3.js';
+import { ExtensionArgs, getExtensionEncoder } from './generated';
+
+const MINT_BASE_SIZE = 82;
+
+export function getMintSize(extensions?: ExtensionArgs[]): number {
+ if (extensions == null) return MINT_BASE_SIZE;
+ const tvlEncoder = getHiddenPrefixEncoder(
+ getArrayEncoder(getExtensionEncoder(), { size: 'remainder' }),
+ [getConstantEncoder(padLeftEncoder(getU8Encoder(), 83).encode(1))]
+ );
+ return MINT_BASE_SIZE + tvlEncoder.encode(extensions).length;
+}
diff --git a/clients/js/src/getTokenSize.ts b/clients/js/src/getTokenSize.ts
new file mode 100644
index 0000000..478d577
--- /dev/null
+++ b/clients/js/src/getTokenSize.ts
@@ -0,0 +1,18 @@
+import {
+ getArrayEncoder,
+ getConstantEncoder,
+ getHiddenPrefixEncoder,
+ getU8Encoder,
+} from '@solana/web3.js';
+import { ExtensionArgs, getExtensionEncoder } from './generated';
+
+const TOKEN_BASE_SIZE = 165;
+
+export function getTokenSize(extensions?: ExtensionArgs[]): number {
+ if (extensions == null) return TOKEN_BASE_SIZE;
+ const tvlEncoder = getHiddenPrefixEncoder(
+ getArrayEncoder(getExtensionEncoder(), { size: 'remainder' }),
+ [getConstantEncoder(getU8Encoder().encode(2))]
+ );
+ return TOKEN_BASE_SIZE + tvlEncoder.encode(extensions).length;
+}
diff --git a/clients/js/src/index.ts b/clients/js/src/index.ts
index 69e4e4e..d14487d 100644
--- a/clients/js/src/index.ts
+++ b/clients/js/src/index.ts
@@ -1 +1,4 @@
export * from './generated';
+
+export * from './getTokenSize';
+export * from './getMintSize';
diff --git a/clients/js/test/_setup.ts b/clients/js/test/_setup.ts
index e6dd1e7..947b86b 100644
--- a/clients/js/test/_setup.ts
+++ b/clients/js/test/_setup.ts
@@ -87,6 +87,24 @@ export const getBalance = async (client: Client, address: Address) =>
(await client.rpc.getBalance(address, { commitment: 'confirmed' }).send())
.value;
+export const getCreateToken22AccountInstruction = async (
+ client: Client,
+ payer: TransactionSigner,
+ newAccount: TransactionSigner,
+ space: number | bigint
+) => {
+ const rent = await client.rpc
+ .getMinimumBalanceForRentExemption(BigInt(space))
+ .send();
+ return getCreateAccountInstruction({
+ payer,
+ newAccount,
+ lamports: rent,
+ space,
+ programAddress: TOKEN_2022_PROGRAM_ADDRESS,
+ });
+};
+
export const createMint = async (
client: Client,
payer: TransactionSigner,
diff --git a/clients/js/test/accounts/mint.test.ts b/clients/js/test/accounts/mint.test.ts
index 484d868..d62ddcc 100644
--- a/clients/js/test/accounts/mint.test.ts
+++ b/clients/js/test/accounts/mint.test.ts
@@ -18,7 +18,7 @@ test('it decodes a mint account with extensions', (t) => {
decimals: 9,
isInitialized: true,
freezeAuthority: some('FdrdFuo1RQ9LrQ3FRfQUE7RigyANe5kFNLyMhCYk1xgJ'),
- extensions: [
+ extensions: some([
{
__kind: 'MintCloseAuthority',
closeAuthority: 'FdrdFuo1RQ9LrQ3FRfQUE7RigyANe5kFNLyMhCYk1xgJ',
@@ -104,6 +104,6 @@ test('it decodes a mint account with extensions', (t) => {
size: 0,
maxSize: 1000,
},
- ],
+ ]),
});
});
diff --git a/clients/js/test/accounts/token.test.ts b/clients/js/test/accounts/token.test.ts
index 47f4919..09a1f2a 100644
--- a/clients/js/test/accounts/token.test.ts
+++ b/clients/js/test/accounts/token.test.ts
@@ -1,4 +1,9 @@
-import { getBase16Encoder, getBase64Encoder, none } from '@solana/web3.js';
+import {
+ getBase16Encoder,
+ getBase64Encoder,
+ none,
+ some,
+} from '@solana/web3.js';
import test from 'ava';
import { AccountState, Token, getTokenDecoder } from '../../src';
@@ -21,7 +26,7 @@ test('it decodes a token account with extensions', (t) => {
isNative: none(),
delegatedAmount: 0n,
closeAuthority: none(),
- extensions: [
+ extensions: some([
{ __kind: 'ImmutableOwner' },
{ __kind: 'NonTransferableAccount' },
{ __kind: 'TransferFeeAmount', withheldAmount: 0n },
@@ -49,6 +54,6 @@ test('it decodes a token account with extensions', (t) => {
__kind: 'ConfidentialTransferFeeAmount',
withheldAmount: new Uint8Array(64).fill(0),
},
- ],
+ ]),
});
});
diff --git a/clients/js/test/extensions/mintCloseAuthority.test.ts b/clients/js/test/extensions/mintCloseAuthority.test.ts
new file mode 100644
index 0000000..5740ee5
--- /dev/null
+++ b/clients/js/test/extensions/mintCloseAuthority.test.ts
@@ -0,0 +1,78 @@
+import {
+ Account,
+ address,
+ appendTransactionMessageInstructions,
+ generateKeyPairSigner,
+ none,
+ pipe,
+ some,
+} from '@solana/web3.js';
+import test from 'ava';
+import {
+ Mint,
+ extension,
+ fetchMint,
+ getInitializeMintCloseAuthorityInstruction,
+ getInitializeMintInstruction,
+ getMintSize,
+} from '../../src';
+import {
+ createDefaultSolanaClient,
+ createDefaultTransaction,
+ generateKeyPairSignerWithSol,
+ getCreateToken22AccountInstruction,
+ signAndSendTransaction,
+} from '../_setup';
+
+test('it initializes a mint account with a close authority', async (t) => {
+ // Given an authority and a mint account.
+ const client = createDefaultSolanaClient();
+ const authority = await generateKeyPairSignerWithSol(client);
+ const mint = await generateKeyPairSigner();
+
+ // And a mint close authority extension.
+ const mintCloseAuthorityExtension = extension('MintCloseAuthority', {
+ closeAuthority: address('HHS1XymmkBpYAkg3XTbZLxgHa5n11PAWUCWdiVtRmzzS'),
+ });
+
+ // When we create and initialize a mint account with this extension.
+ const space = BigInt(getMintSize([mintCloseAuthorityExtension]));
+ const instructions = [
+ await getCreateToken22AccountInstruction(client, authority, mint, space),
+ getInitializeMintCloseAuthorityInstruction({
+ mint: mint.address,
+ closeAuthority: mintCloseAuthorityExtension.closeAuthority,
+ }),
+ getInitializeMintInstruction({
+ mint: mint.address,
+ decimals: 2,
+ mintAuthority: authority.address,
+ }),
+ ];
+ await pipe(
+ await createDefaultTransaction(client, authority),
+ (tx) => appendTransactionMessageInstructions(instructions, tx),
+ (tx) => signAndSendTransaction(client, tx)
+ );
+
+ // Then we expect the mint account to exist and have the following data.
+ const mintAccount = await fetchMint(client.rpc, mint.address);
+ t.like(mintAccount, >{
+ address: mint.address,
+ data: {
+ mintAuthority: some(authority.address),
+ supply: 0n,
+ decimals: 2,
+ isInitialized: true,
+ freezeAuthority: none(),
+ extensions: some([
+ {
+ __kind: 'MintCloseAuthority',
+ closeAuthority: address(
+ 'HHS1XymmkBpYAkg3XTbZLxgHa5n11PAWUCWdiVtRmzzS'
+ ),
+ },
+ ]),
+ },
+ });
+});
diff --git a/clients/js/test/extensions/transferFeeConfig.test.ts b/clients/js/test/extensions/transferFeeConfig.test.ts
new file mode 100644
index 0000000..38aefd4
--- /dev/null
+++ b/clients/js/test/extensions/transferFeeConfig.test.ts
@@ -0,0 +1,104 @@
+import {
+ Account,
+ address,
+ appendTransactionMessageInstructions,
+ generateKeyPairSigner,
+ none,
+ pipe,
+ some,
+} from '@solana/web3.js';
+import test from 'ava';
+import {
+ Mint,
+ extension,
+ fetchMint,
+ getInitializeMintInstruction,
+ getInitializeTransferFeeConfigInstruction,
+ getMintSize,
+} from '../../src';
+import {
+ createDefaultSolanaClient,
+ createDefaultTransaction,
+ generateKeyPairSignerWithSol,
+ getCreateToken22AccountInstruction,
+ signAndSendTransaction,
+} from '../_setup';
+
+test('it initializes a mint account with transfer fee configurations', async (t) => {
+ // Given an authority and a mint account.
+ const client = createDefaultSolanaClient();
+ const authority = await generateKeyPairSignerWithSol(client);
+ const mint = await generateKeyPairSigner();
+
+ // And a transfer fee config extension.
+ const transferFees = {
+ epoch: 0n,
+ maximumFee: 1_000_000_000n,
+ transferFeeBasisPoints: 150, // 1.5%
+ };
+ const transferFeeConfigExtension = extension('TransferFeeConfig', {
+ transferFeeConfigAuthority: address(
+ '6sPR6MzvjMMP5LSZzEtTe4ZBVX9rhBmtM1dmfFtkNTbW'
+ ),
+ withdrawWithheldAuthority: address(
+ 'BTNEPmmWuj7Sg4Fo5i1FC5eiV2Aj4jiv9boarvE5XeaX'
+ ),
+ withheldAmount: 0n,
+ newerTransferFee: transferFees,
+ // Used for transitioning configs. Starts by being the same as newerTransferFee.
+ olderTransferFee: transferFees,
+ });
+
+ // When we create and initialize a mint account with this extension.
+ const space = BigInt(getMintSize([transferFeeConfigExtension]));
+ const instructions = [
+ await getCreateToken22AccountInstruction(client, authority, mint, space),
+ getInitializeTransferFeeConfigInstruction({
+ mint: mint.address,
+ transferFeeConfigAuthority:
+ transferFeeConfigExtension.transferFeeConfigAuthority,
+ withdrawWithheldAuthority:
+ transferFeeConfigExtension.withdrawWithheldAuthority,
+ transferFeeBasisPoints:
+ transferFeeConfigExtension.newerTransferFee.transferFeeBasisPoints,
+ maximumFee: transferFeeConfigExtension.newerTransferFee.maximumFee,
+ }),
+ getInitializeMintInstruction({
+ mint: mint.address,
+ decimals: 2,
+ mintAuthority: authority.address,
+ }),
+ ];
+ await pipe(
+ await createDefaultTransaction(client, authority),
+ (tx) => appendTransactionMessageInstructions(instructions, tx),
+ (tx) => signAndSendTransaction(client, tx)
+ );
+
+ // Then we expect the mint account to exist and have the following data.
+ const mintAccount = await fetchMint(client.rpc, mint.address);
+ t.like(mintAccount, >{
+ address: mint.address,
+ data: {
+ mintAuthority: some(authority.address),
+ supply: 0n,
+ decimals: 2,
+ isInitialized: true,
+ freezeAuthority: none(),
+ extensions: some([
+ {
+ __kind: 'TransferFeeConfig',
+ transferFeeConfigAuthority: address(
+ '6sPR6MzvjMMP5LSZzEtTe4ZBVX9rhBmtM1dmfFtkNTbW'
+ ),
+ withdrawWithheldAuthority: address(
+ 'BTNEPmmWuj7Sg4Fo5i1FC5eiV2Aj4jiv9boarvE5XeaX'
+ ),
+ withheldAmount: 0n,
+ newerTransferFee: transferFees,
+ olderTransferFee: transferFees,
+ },
+ ]),
+ },
+ });
+});
diff --git a/clients/js/test/getMintSize.test.ts b/clients/js/test/getMintSize.test.ts
new file mode 100644
index 0000000..575eeba
--- /dev/null
+++ b/clients/js/test/getMintSize.test.ts
@@ -0,0 +1,34 @@
+import test from 'ava';
+
+import { extension, getMintSize } from '../src';
+import { address } from '@solana/web3.js';
+
+test('it returns the base size when no extensions are provided', (t) => {
+ t.is(getMintSize(), 82 /* base size */);
+});
+
+test('it returns the extended base size when an empty array of extensions is provided', (t) => {
+ t.is(
+ getMintSize([]),
+ 82 /* base size */ +
+ 83 /* offset to reach 165 */ +
+ 1 /* mint discriminator */
+ );
+});
+
+test('it returns the size including all provided extensions', (t) => {
+ t.is(
+ getMintSize([
+ extension('MintCloseAuthority', {
+ closeAuthority: address('HHS1XymmkBpYAkg3XTbZLxgHa5n11PAWUCWdiVtRmzzS'),
+ }),
+ extension('TransferHook', {
+ authority: address('6YG6ggAzLnqu1oV56HELbmvfyveD3JKmCmEWGU9W6RK2'),
+ programId: address('DAFy5fcNXoaxxrtenLrqH1DHUyD8rAqn77sDMEHit4Qx'),
+ }),
+ ]),
+ 166 /* extended mint base size */ +
+ 36 /* MintCloseAuthority extension size */ +
+ 68 /* TransferHook extension size */
+ );
+});
diff --git a/clients/js/test/getTokenSize.test.ts b/clients/js/test/getTokenSize.test.ts
new file mode 100644
index 0000000..ba7027f
--- /dev/null
+++ b/clients/js/test/getTokenSize.test.ts
@@ -0,0 +1,23 @@
+import test from 'ava';
+
+import { extension, getTokenSize } from '../src';
+
+test('it returns the base size when no extensions are provided', (t) => {
+ t.is(getTokenSize(), 165 /* base size */);
+});
+
+test('it returns the extended base size when an empty array of extensions is provided', (t) => {
+ t.is(getTokenSize([]), 165 /* base size */ + 1 /* token discriminator */);
+});
+
+test('it returns the size including all provided extensions', (t) => {
+ t.is(
+ getTokenSize([
+ extension('ImmutableOwner', {}),
+ extension('TransferFeeAmount', { withheldAmount: 100n }),
+ ]),
+ 166 /* extended mint base size */ +
+ 4 /* ImmutableOwner extension size */ +
+ 12 /* TransferFeeAmount extension size */
+ );
+});
diff --git a/clients/js/test/initializeMint.test.ts b/clients/js/test/initializeMint.test.ts
index 73d486e..9b0151a 100644
--- a/clients/js/test/initializeMint.test.ts
+++ b/clients/js/test/initializeMint.test.ts
@@ -1,4 +1,3 @@
-import { getCreateAccountInstruction } from '@solana-program/system';
import {
Account,
appendTransactionMessageInstructions,
@@ -10,14 +9,15 @@ import {
import test from 'ava';
import {
Mint,
- TOKEN_2022_PROGRAM_ADDRESS,
fetchMint,
getInitializeMintInstruction,
+ getMintSize,
} from '../src';
import {
createDefaultSolanaClient,
createDefaultTransaction,
generateKeyPairSignerWithSol,
+ getCreateToken22AccountInstruction,
signAndSendTransaction,
} from './_setup';
@@ -28,16 +28,9 @@ test('it creates and initializes a new mint account', async (t) => {
const mint = await generateKeyPairSigner();
// When we create and initialize a mint account at this address.
- const space = 82n;
- const rent = await client.rpc.getMinimumBalanceForRentExemption(space).send();
+ const space = BigInt(getMintSize());
const instructions = [
- getCreateAccountInstruction({
- payer: authority,
- newAccount: mint,
- lamports: rent,
- space,
- programAddress: TOKEN_2022_PROGRAM_ADDRESS,
- }),
+ await getCreateToken22AccountInstruction(client, authority, mint, space),
getInitializeMintInstruction({
mint: mint.address,
decimals: 2,
@@ -75,16 +68,9 @@ test('it creates a new mint account with a freeze authority', async (t) => {
]);
// When we create and initialize a mint account at this address.
- const space = 82n;
- const rent = await client.rpc.getMinimumBalanceForRentExemption(space).send();
+ const space = BigInt(getMintSize());
const instructions = [
- getCreateAccountInstruction({
- payer,
- newAccount: mint,
- lamports: rent,
- space,
- programAddress: TOKEN_2022_PROGRAM_ADDRESS,
- }),
+ await getCreateToken22AccountInstruction(client, payer, mint, space),
getInitializeMintInstruction({
mint: mint.address,
decimals: 0,
diff --git a/package.json b/package.json
index 73e174d..009ee60 100644
--- a/package.json
+++ b/package.json
@@ -20,9 +20,9 @@
},
"devDependencies": {
"@iarna/toml": "^2.2.5",
- "@kinobi-so/renderers-js": "^0.21.2",
- "@kinobi-so/renderers-rust": "^0.21.0",
- "kinobi": "^0.21.0",
+ "@kinobi-so/renderers-js": "^0.21.8",
+ "@kinobi-so/renderers-rust": "^0.21.6",
+ "kinobi": "^0.21.4",
"typescript": "^5.5.2",
"zx": "^7.2.3"
},
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index c833f9e..d4d1658 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -12,14 +12,14 @@ importers:
specifier: ^2.2.5
version: 2.2.5
'@kinobi-so/renderers-js':
- specifier: ^0.21.2
- version: 0.21.2(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ specifier: ^0.21.8
+ version: 0.21.8(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
'@kinobi-so/renderers-rust':
- specifier: ^0.21.0
- version: 0.21.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ specifier: ^0.21.6
+ version: 0.21.6(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
kinobi:
- specifier: ^0.21.0
- version: 0.21.0
+ specifier: ^0.21.4
+ version: 0.21.4
typescript:
specifier: ^5.5.2
version: 5.5.3
@@ -32,36 +32,36 @@ packages:
'@iarna/toml@2.2.5':
resolution: {integrity: sha512-trnsAYxU3xnS1gPHPyU961coFyLkh4gAD/0zQ5mymY4yOZ+CYvsPqUbOFSw0aDM4y0tV7tiFxL/1XfXPNC6IPg==}
- '@kinobi-so/errors@0.21.0':
- resolution: {integrity: sha512-7dPK35L/Y01qzekhVHdKAu+lENmHhuwX39rIx3qNJpNPHKi1VCcorLuOJlfT2F9MPPUjv5pZliL5qQ5IsvtNMw==}
+ '@kinobi-so/errors@0.21.4':
+ resolution: {integrity: sha512-Ffu/l5SGGLbSf451on+hHLWKGm8fpoWocCh6+RTftNSe/OHKnz9K0f2esX7ny83Vckpf77sVub1JXwOMW/hW/w==}
hasBin: true
- '@kinobi-so/node-types@0.21.0':
- resolution: {integrity: sha512-UmzjocmsLa1pZ/ExVklGRsWQZNoIvifKBuTEAcpdxlDhg6hmrMWoXwWvRrLI5o7v1WKvTucv7KuM+5GU9UhFDw==}
+ '@kinobi-so/node-types@0.21.4':
+ resolution: {integrity: sha512-/6En6kVU21/skBlKbN6EzD5saDFzFoezDYoonbWurtXJcelTIuqz3D1WwR3iNOXvWco64cqpHG6mM7zdF5WsHA==}
- '@kinobi-so/nodes-from-anchor@0.20.9':
- resolution: {integrity: sha512-xNlwvJek6Hbfi45Unocwq/lT3rFXhmpZcAZmQJMgdIH8E4iAya9ZQ89j4neRQ+C1KVrK9qFJh0SaJvt9xnJQXA==}
+ '@kinobi-so/nodes-from-anchor@0.21.2':
+ resolution: {integrity: sha512-c7lDg9MH4LKod5PwNC4Lvsugx3Dj6bqgw5kQFLUYDdIWVRdR2Z8JGK/LhPXceiDvw2bLnjy2Mmroz8zh2/0cuA==}
- '@kinobi-so/nodes@0.21.0':
- resolution: {integrity: sha512-Z8STFjB3/f9LzK494l6qydkBMsFtnm96YreJjlAg9/DeKNtphimslSvFTF/9qHiGMfOQpOVhQqbWFXpt+PCZiQ==}
+ '@kinobi-so/nodes@0.21.4':
+ resolution: {integrity: sha512-QQbmSsOcfL2GhCMkHP33XihzUDS12jAKMvhNyTzhdpI1QPS40wvMwYfA8UXFtc5B/4aKhneEGUok7QgF4IZXkg==}
- '@kinobi-so/renderers-core@0.20.7':
- resolution: {integrity: sha512-KJhU8+UMowO9dDkLhEodAkbRkgSxdfBWeY+DIgOCgXcakt0T140K7OREuaAo9fp12Owf+10SAEGx9AzTNySoHA==}
+ '@kinobi-so/renderers-core@0.21.2':
+ resolution: {integrity: sha512-czVR9dfKWwZ5YQB1N83+whsh9g1zCS8rMJZ0t/T3Vd7P0uuKOOGL9ej/WMQZ7qQhCLTDJDEn5Lqf2JInArzqLg==}
- '@kinobi-so/renderers-js@0.21.2':
- resolution: {integrity: sha512-G576GAQ10ugmA63EZRlEbv892th37q9ow+AMzZD1vtypRCEJ7znakzySSDG3aeqaZujk2igKXFQTD+FHuY/xPg==}
+ '@kinobi-so/renderers-js@0.21.8':
+ resolution: {integrity: sha512-YYyi5ADxwdC0nbIAH9xHtEFbHW6RJiA9w7i+gtSnX6olpp4g+e0ITOuuV3GmeUlRdflbf3hMMbCNWWl+y7uiOg==}
- '@kinobi-so/renderers-rust@0.21.0':
- resolution: {integrity: sha512-BLe1SW6XFBhjtZdCc7cuukMWrJTbhCafCCmXryLmjzF7jaiK9nyZZFinHxljSac4HCk2vDn22mHAwOjabaDQ2Q==}
+ '@kinobi-so/renderers-rust@0.21.6':
+ resolution: {integrity: sha512-AIJVE/3KsKNBbzuzpgV5npC7IyeEX9SjIf6LFuKXEfUcyLTVjAmosn+MBCDCtY7bTC2CD1U+Bfjt9/8a+uO4mA==}
- '@kinobi-so/validators@0.21.0':
- resolution: {integrity: sha512-mpBqgqlto/Wdj6rlf1mqWkyw00rPJw98bkNItXq+ofCEtBsjaMq9lsevCE+IPmfJJYEPFGHGJW4Gb6m/cLmOqw==}
+ '@kinobi-so/validators@0.21.4':
+ resolution: {integrity: sha512-1bCi035dtbL1x1L8b/faNbYQ5Qb9He9dYdCgThQoxJL/v9a7L8F/9D4DGlKxZxEP1xBAflzbVx21QR6ESVpdMA==}
- '@kinobi-so/visitors-core@0.21.0':
- resolution: {integrity: sha512-m6C/cAy7q7ZAWhByQGo2YnBsbt0qS3Un0lyT4mmPGQt0QFXUDExFipjTvY/NnzZ5lQJ2grvnL04pqLx8V7eiuw==}
+ '@kinobi-so/visitors-core@0.21.4':
+ resolution: {integrity: sha512-xRosguRjUydFX/kdDf56FwW2OQ0dVJQaipG2aceKXGwx8bYorIS7fAWvIOXmLmZbtxKdtggxDW4oSw0DUtWeKQ==}
- '@kinobi-so/visitors@0.21.0':
- resolution: {integrity: sha512-gigysLJCfVtNCFkdDMeHGB+1SOvoiQOPUVKxewzOq1wDYVioFmmf4aXfB1GCEslLlMvl63cTJrwvh8bDIZoaSA==}
+ '@kinobi-so/visitors@0.21.4':
+ resolution: {integrity: sha512-bebFAvRncmnY0Hy448XRb65a+2LkHJ4acnJyJi9dvJqWgJl6zbhX6Lj0NBYluzSwB28317DMynn+V7PSqOKBbQ==}
'@noble/hashes@1.4.0':
resolution: {integrity: sha512-V1JJ1WTRUqHHrOSh597hURcMqVKVGL/ea3kv0gSnEdsEZ0/+VyPghM1lMNGc00z7CIQorSvbKpuJkxvuHbvdbg==}
@@ -79,24 +79,24 @@ packages:
resolution: {integrity: sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==}
engines: {node: '>= 8'}
- '@solana/codecs-core@2.0.0-preview.4':
- resolution: {integrity: sha512-A0VVuDDA5kNKZUinOqHxJQK32aKTucaVbvn31YenGzHX1gPqq+SOnFwgaEY6pq4XEopSmaK16w938ZQS8IvCnw==}
+ '@solana/codecs-core@2.0.0-rc.1':
+ resolution: {integrity: sha512-bauxqMfSs8EHD0JKESaNmNuNvkvHSuN3bbWAF5RjOfDu2PugxHrvRebmYauvSumZ3cTfQ4HJJX6PG5rN852qyQ==}
peerDependencies:
typescript: '>=5'
- '@solana/codecs-numbers@2.0.0-preview.4':
- resolution: {integrity: sha512-Q061rLtMadsO7uxpguT+Z7G4UHnjQ6moVIxAQxR58nLxDPCC7MB1Pk106/Z7NDhDLHTcd18uO6DZ7ajHZEn2XQ==}
+ '@solana/codecs-numbers@2.0.0-rc.1':
+ resolution: {integrity: sha512-J5i5mOkvukXn8E3Z7sGIPxsThRCgSdgTWJDQeZvucQ9PT6Y3HiVXJ0pcWiOWAoQ3RX8e/f4I3IC+wE6pZiJzDQ==}
peerDependencies:
typescript: '>=5'
- '@solana/codecs-strings@2.0.0-preview.4':
- resolution: {integrity: sha512-YDbsQePRWm+xnrfS64losSGRg8Wb76cjK1K6qfR8LPmdwIC3787x9uW5/E4icl/k+9nwgbIRXZ65lpF+ucZUnw==}
+ '@solana/codecs-strings@2.0.0-rc.1':
+ resolution: {integrity: sha512-9/wPhw8TbGRTt6mHC4Zz1RqOnuPTqq1Nb4EyuvpZ39GW6O2t2Q7Q0XxiB3+BdoEjwA2XgPw6e2iRfvYgqty44g==}
peerDependencies:
fastestsmallesttextencoderdecoder: ^1.0.22
typescript: '>=5'
- '@solana/errors@2.0.0-preview.4':
- resolution: {integrity: sha512-kadtlbRv2LCWr8A9V22On15Us7Nn8BvqNaOB4hXsTB3O0fU40D1ru2l+cReqLcRPij4znqlRzW9Xi0m6J5DIhA==}
+ '@solana/errors@2.0.0-rc.1':
+ resolution: {integrity: sha512-ejNvQ2oJ7+bcFAYWj225lyRkHnixuAeb7RQCixm+5mH4n1IA4Qya/9Bmfy5RAAHQzxK43clu3kZmL5eF9VGtYQ==}
hasBin: true
peerDependencies:
typescript: '>=5'
@@ -137,10 +137,6 @@ packages:
resolution: {integrity: sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w==}
engines: {node: ^12.17.0 || ^14.13 || >=16.0.0}
- commander@12.0.0:
- resolution: {integrity: sha512-MwVNWlYjDTtOjX5PiD7o5pK0UrFU/OYgcJfjjK4RaHZETNtjJqrZa9Y9ds88+A+f+d5lv+561eZ+yCKoS3gbAA==}
- engines: {node: '>=18'}
-
commander@12.1.0:
resolution: {integrity: sha512-Vw8qHK3bZM9y/P10u3Vib8o/DdkvA2OtPtZvD871QKjy74Wj1WSKFILMPRPSdUSx5RFK1arlJzEtA4PkFgnbuA==}
engines: {node: '>=18'}
@@ -276,8 +272,8 @@ packages:
jsonify@0.0.1:
resolution: {integrity: sha512-2/Ki0GcmuqSrgFyelQq9M05y7PS0mEwuIzrf3f1fPqkVDVRvZrPZtVSMHxdgo8Aq0sxAOb/cr2aqqA3LeWHVPg==}
- kinobi@0.21.0:
- resolution: {integrity: sha512-T71VNh4yS8uSvtNp1FEWhJGygW5/8O82SAlFRlPYsWiwqWH9X3eZwwUthBVH7dfazqs8GLia0rAMEmUP99iwLw==}
+ kinobi@0.21.4:
+ resolution: {integrity: sha512-JPN41QCeZT+OB+XqaqAHaqNesybHCm+Qxw4tRKBOfRmPnaV3od9x0kuedvmut8pyv6mm2r2T3bJHNeA9yyOmtA==}
map-stream@0.1.0:
resolution: {integrity: sha512-CkYQrPYZfWnu/DAmVCpTSX/xHpKZ80eKh2lAkyA6AJTef6bW+6JpbQZN5rofum7da+SyN1bi5ctTm+lTfcCW3g==}
@@ -406,40 +402,40 @@ snapshots:
'@iarna/toml@2.2.5': {}
- '@kinobi-so/errors@0.21.0':
+ '@kinobi-so/errors@0.21.4':
dependencies:
- '@kinobi-so/node-types': 0.21.0
+ '@kinobi-so/node-types': 0.21.4
chalk: 5.3.0
- commander: 12.0.0
+ commander: 12.1.0
- '@kinobi-so/node-types@0.21.0': {}
+ '@kinobi-so/node-types@0.21.4': {}
- '@kinobi-so/nodes-from-anchor@0.20.9':
+ '@kinobi-so/nodes-from-anchor@0.21.2':
dependencies:
- '@kinobi-so/errors': 0.21.0
- '@kinobi-so/nodes': 0.21.0
- '@kinobi-so/visitors': 0.21.0
+ '@kinobi-so/errors': 0.21.4
+ '@kinobi-so/nodes': 0.21.4
+ '@kinobi-so/visitors': 0.21.4
'@noble/hashes': 1.4.0
- '@kinobi-so/nodes@0.21.0':
+ '@kinobi-so/nodes@0.21.4':
dependencies:
- '@kinobi-so/errors': 0.21.0
- '@kinobi-so/node-types': 0.21.0
+ '@kinobi-so/errors': 0.21.4
+ '@kinobi-so/node-types': 0.21.4
- '@kinobi-so/renderers-core@0.20.7':
+ '@kinobi-so/renderers-core@0.21.2':
dependencies:
- '@kinobi-so/errors': 0.21.0
- '@kinobi-so/nodes': 0.21.0
- '@kinobi-so/visitors-core': 0.21.0
+ '@kinobi-so/errors': 0.21.4
+ '@kinobi-so/nodes': 0.21.4
+ '@kinobi-so/visitors-core': 0.21.4
- '@kinobi-so/renderers-js@0.21.2(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@kinobi-so/renderers-js@0.21.8(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@kinobi-so/errors': 0.21.0
- '@kinobi-so/nodes': 0.21.0
- '@kinobi-so/nodes-from-anchor': 0.20.9
- '@kinobi-so/renderers-core': 0.20.7
- '@kinobi-so/visitors-core': 0.21.0
- '@solana/codecs-strings': 2.0.0-preview.4(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@kinobi-so/errors': 0.21.4
+ '@kinobi-so/nodes': 0.21.4
+ '@kinobi-so/nodes-from-anchor': 0.21.2
+ '@kinobi-so/renderers-core': 0.21.2
+ '@kinobi-so/visitors-core': 0.21.4
+ '@solana/codecs-strings': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
nunjucks: 3.2.4
prettier: 3.3.3
transitivePeerDependencies:
@@ -447,36 +443,36 @@ snapshots:
- fastestsmallesttextencoderdecoder
- typescript
- '@kinobi-so/renderers-rust@0.21.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@kinobi-so/renderers-rust@0.21.6(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@kinobi-so/errors': 0.21.0
- '@kinobi-so/nodes': 0.21.0
- '@kinobi-so/renderers-core': 0.20.7
- '@kinobi-so/visitors-core': 0.21.0
- '@solana/codecs-strings': 2.0.0-preview.4(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
+ '@kinobi-so/errors': 0.21.4
+ '@kinobi-so/nodes': 0.21.4
+ '@kinobi-so/renderers-core': 0.21.2
+ '@kinobi-so/visitors-core': 0.21.4
+ '@solana/codecs-strings': 2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)
nunjucks: 3.2.4
transitivePeerDependencies:
- chokidar
- fastestsmallesttextencoderdecoder
- typescript
- '@kinobi-so/validators@0.21.0':
+ '@kinobi-so/validators@0.21.4':
dependencies:
- '@kinobi-so/errors': 0.21.0
- '@kinobi-so/nodes': 0.21.0
- '@kinobi-so/visitors-core': 0.21.0
+ '@kinobi-so/errors': 0.21.4
+ '@kinobi-so/nodes': 0.21.4
+ '@kinobi-so/visitors-core': 0.21.4
- '@kinobi-so/visitors-core@0.21.0':
+ '@kinobi-so/visitors-core@0.21.4':
dependencies:
- '@kinobi-so/errors': 0.21.0
- '@kinobi-so/nodes': 0.21.0
+ '@kinobi-so/errors': 0.21.4
+ '@kinobi-so/nodes': 0.21.4
json-stable-stringify: 1.1.1
- '@kinobi-so/visitors@0.21.0':
+ '@kinobi-so/visitors@0.21.4':
dependencies:
- '@kinobi-so/errors': 0.21.0
- '@kinobi-so/nodes': 0.21.0
- '@kinobi-so/visitors-core': 0.21.0
+ '@kinobi-so/errors': 0.21.4
+ '@kinobi-so/nodes': 0.21.4
+ '@kinobi-so/visitors-core': 0.21.4
'@noble/hashes@1.4.0': {}
@@ -492,26 +488,26 @@ snapshots:
'@nodelib/fs.scandir': 2.1.5
fastq: 1.17.1
- '@solana/codecs-core@2.0.0-preview.4(typescript@5.5.3)':
+ '@solana/codecs-core@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
- '@solana/errors': 2.0.0-preview.4(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
- '@solana/codecs-numbers@2.0.0-preview.4(typescript@5.5.3)':
+ '@solana/codecs-numbers@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
- '@solana/codecs-core': 2.0.0-preview.4(typescript@5.5.3)
- '@solana/errors': 2.0.0-preview.4(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
typescript: 5.5.3
- '@solana/codecs-strings@2.0.0-preview.4(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
+ '@solana/codecs-strings@2.0.0-rc.1(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.5.3)':
dependencies:
- '@solana/codecs-core': 2.0.0-preview.4(typescript@5.5.3)
- '@solana/codecs-numbers': 2.0.0-preview.4(typescript@5.5.3)
- '@solana/errors': 2.0.0-preview.4(typescript@5.5.3)
+ '@solana/codecs-core': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/codecs-numbers': 2.0.0-rc.1(typescript@5.5.3)
+ '@solana/errors': 2.0.0-rc.1(typescript@5.5.3)
fastestsmallesttextencoderdecoder: 1.0.22
typescript: 5.5.3
- '@solana/errors@2.0.0-preview.4(typescript@5.5.3)':
+ '@solana/errors@2.0.0-rc.1(typescript@5.5.3)':
dependencies:
chalk: 5.3.0
commander: 12.1.0
@@ -554,8 +550,6 @@ snapshots:
chalk@5.3.0: {}
- commander@12.0.0: {}
-
commander@12.1.0: {}
commander@5.1.0: {}
@@ -696,12 +690,12 @@ snapshots:
jsonify@0.0.1: {}
- kinobi@0.21.0:
+ kinobi@0.21.4:
dependencies:
- '@kinobi-so/errors': 0.21.0
- '@kinobi-so/nodes': 0.21.0
- '@kinobi-so/validators': 0.21.0
- '@kinobi-so/visitors': 0.21.0
+ '@kinobi-so/errors': 0.21.4
+ '@kinobi-so/nodes': 0.21.4
+ '@kinobi-so/validators': 0.21.4
+ '@kinobi-so/visitors': 0.21.4
map-stream@0.1.0: {}
diff --git a/program/idl.json b/program/idl.json
index bd5219f..6da4a09 100644
--- a/program/idl.json
+++ b/program/idl.json
@@ -95,36 +95,39 @@
"name": "extensions",
"docs": ["The extensions activated on the mint account."],
"type": {
- "kind": "hiddenPrefixTypeNode",
- "type": {
- "kind": "arrayTypeNode",
- "item": {
- "kind": "definedTypeLinkNode",
- "name": "extension"
+ "kind": "remainderOptionTypeNode",
+ "item": {
+ "kind": "hiddenPrefixTypeNode",
+ "type": {
+ "kind": "arrayTypeNode",
+ "item": {
+ "kind": "definedTypeLinkNode",
+ "name": "extension"
+ },
+ "count": {
+ "kind": "remainderCountNode"
+ }
},
- "count": {
- "kind": "remainderCountNode"
- }
- },
- "prefix": [
- {
- "kind": "constantValueNode",
- "type": {
- "kind": "preOffsetTypeNode",
- "offset": 83,
- "strategy": "padded",
+ "prefix": [
+ {
+ "kind": "constantValueNode",
"type": {
- "kind": "numberTypeNode",
- "format": "u8",
- "endian": "le"
+ "kind": "preOffsetTypeNode",
+ "offset": 83,
+ "strategy": "padded",
+ "type": {
+ "kind": "numberTypeNode",
+ "format": "u8",
+ "endian": "le"
+ }
+ },
+ "value": {
+ "kind": "numberValueNode",
+ "number": 1
}
- },
- "value": {
- "kind": "numberValueNode",
- "number": 1
}
- }
- ]
+ ]
+ }
}
}
]
@@ -249,37 +252,39 @@
}
}
},
-
{
"kind": "structFieldTypeNode",
"name": "extensions",
"docs": ["The extensions activated on the token account."],
"type": {
- "kind": "hiddenPrefixTypeNode",
- "type": {
- "kind": "arrayTypeNode",
- "item": {
- "kind": "definedTypeLinkNode",
- "name": "extension"
- },
- "count": {
- "kind": "remainderCountNode"
- }
- },
- "prefix": [
- {
- "kind": "constantValueNode",
- "type": {
- "kind": "numberTypeNode",
- "format": "u8",
- "endian": "le"
+ "kind": "remainderOptionTypeNode",
+ "item": {
+ "kind": "hiddenPrefixTypeNode",
+ "type": {
+ "kind": "arrayTypeNode",
+ "item": {
+ "kind": "definedTypeLinkNode",
+ "name": "extension"
},
- "value": {
- "kind": "numberValueNode",
- "number": 2
+ "count": {
+ "kind": "remainderCountNode"
}
- }
- ]
+ },
+ "prefix": [
+ {
+ "kind": "constantValueNode",
+ "type": {
+ "kind": "numberTypeNode",
+ "format": "u8",
+ "endian": "le"
+ },
+ "value": {
+ "kind": "numberValueNode",
+ "number": 2
+ }
+ }
+ ]
+ }
}
}
]
@@ -2267,6 +2272,197 @@
"offset": 0
}
]
+ },
+ {
+ "kind": "instructionNode",
+ "name": "initializeMintCloseAuthority",
+ "docs": [
+ "Initialize the close account authority on a new mint.",
+ "",
+ "Fails if the mint has already been initialized, so must be called before `InitializeMint`.",
+ "",
+ "The mint must have exactly enough space allocated for the base mint (82",
+ "bytes), plus 83 bytes of padding, 1 byte reserved for the account type,",
+ "then space required for this extension, plus any others."
+ ],
+ "optionalAccountStrategy": "programId",
+ "accounts": [
+ {
+ "kind": "instructionAccountNode",
+ "name": "mint",
+ "isWritable": true,
+ "isSigner": false,
+ "isOptional": false,
+ "docs": ["The mint to initialize."]
+ }
+ ],
+ "arguments": [
+ {
+ "kind": "instructionArgumentNode",
+ "name": "discriminator",
+ "defaultValueStrategy": "omitted",
+ "docs": [],
+ "type": {
+ "kind": "numberTypeNode",
+ "format": "u8",
+ "endian": "le"
+ },
+ "defaultValue": {
+ "kind": "numberValueNode",
+ "number": 25
+ }
+ },
+ {
+ "kind": "instructionArgumentNode",
+ "name": "closeAuthority",
+ "docs": [
+ "Authority that must sign the `CloseAccount` instruction on a mint."
+ ],
+ "type": {
+ "kind": "optionTypeNode",
+ "fixed": false,
+ "item": {
+ "kind": "publicKeyTypeNode"
+ },
+ "prefix": {
+ "kind": "numberTypeNode",
+ "format": "u8",
+ "endian": "le"
+ }
+ }
+ }
+ ],
+ "discriminators": [
+ {
+ "kind": "fieldDiscriminatorNode",
+ "name": "discriminator",
+ "offset": 0
+ }
+ ]
+ },
+ {
+ "kind": "instructionNode",
+ "name": "initializeTransferFeeConfig",
+ "docs": [
+ "Initialize the transfer fee on a new mint.",
+ "",
+ "Fails if the mint has already been initialized, so must be called before `InitializeMint`.",
+ "",
+ "The mint must have exactly enough space allocated for the base mint (82",
+ "bytes), plus 83 bytes of padding, 1 byte reserved for the account type,",
+ "then space required for this extension, plus any others."
+ ],
+ "optionalAccountStrategy": "programId",
+ "accounts": [
+ {
+ "kind": "instructionAccountNode",
+ "name": "mint",
+ "isWritable": true,
+ "isSigner": false,
+ "isOptional": false,
+ "docs": ["The mint to initialize."]
+ }
+ ],
+ "arguments": [
+ {
+ "kind": "instructionArgumentNode",
+ "name": "discriminator",
+ "defaultValueStrategy": "omitted",
+ "docs": [],
+ "type": {
+ "kind": "numberTypeNode",
+ "format": "u8",
+ "endian": "le"
+ },
+ "defaultValue": {
+ "kind": "numberValueNode",
+ "number": 26
+ }
+ },
+ {
+ "kind": "instructionArgumentNode",
+ "name": "transferFeeDiscriminator",
+ "defaultValueStrategy": "omitted",
+ "docs": [],
+ "type": {
+ "kind": "numberTypeNode",
+ "format": "u8",
+ "endian": "le"
+ },
+ "defaultValue": {
+ "kind": "numberValueNode",
+ "number": 0
+ }
+ },
+ {
+ "kind": "instructionArgumentNode",
+ "name": "transferFeeConfigAuthority",
+ "docs": ["Pubkey that may update the fees."],
+ "type": {
+ "kind": "optionTypeNode",
+ "fixed": false,
+ "item": {
+ "kind": "publicKeyTypeNode"
+ },
+ "prefix": {
+ "kind": "numberTypeNode",
+ "format": "u8",
+ "endian": "le"
+ }
+ }
+ },
+ {
+ "kind": "instructionArgumentNode",
+ "name": "withdrawWithheldAuthority",
+ "docs": ["Withdraw instructions must be signed by this key."],
+ "type": {
+ "kind": "optionTypeNode",
+ "fixed": false,
+ "item": {
+ "kind": "publicKeyTypeNode"
+ },
+ "prefix": {
+ "kind": "numberTypeNode",
+ "format": "u8",
+ "endian": "le"
+ }
+ }
+ },
+ {
+ "kind": "instructionArgumentNode",
+ "name": "transferFeeBasisPoints",
+ "docs": [
+ "Amount of transfer collected as fees, expressed as basis points of the transfer amount."
+ ],
+ "type": {
+ "kind": "numberTypeNode",
+ "format": "u16",
+ "endian": "le"
+ }
+ },
+ {
+ "kind": "instructionArgumentNode",
+ "name": "maximumFee",
+ "docs": ["Maximum fee assessed on transfers."],
+ "type": {
+ "kind": "numberTypeNode",
+ "format": "u64",
+ "endian": "le"
+ }
+ }
+ ],
+ "discriminators": [
+ {
+ "kind": "fieldDiscriminatorNode",
+ "name": "discriminator",
+ "offset": 0
+ },
+ {
+ "kind": "fieldDiscriminatorNode",
+ "name": "transferFeeDiscriminator",
+ "offset": 1
+ }
+ ]
}
],
"definedTypes": [
@@ -3797,7 +3993,7 @@
"docs": ["SPL Token program."],
"defaultValue": {
"kind": "publicKeyValueNode",
- "publicKey": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
+ "publicKey": "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb"
}
}
],
@@ -3919,7 +4115,7 @@
"docs": ["SPL Token program."],
"defaultValue": {
"kind": "publicKeyValueNode",
- "publicKey": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
+ "publicKey": "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb"
}
}
],
@@ -4115,7 +4311,7 @@
"docs": ["SPL Token program."],
"defaultValue": {
"kind": "publicKeyValueNode",
- "publicKey": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
+ "publicKey": "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb"
}
}
],