@ar.io/sdk 4.0.0-alpha.2 → 4.0.0-alpha.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -403,7 +403,7 @@ const ario = ARIO.init({
403
403
  On localnet (Surfpool) source program IDs from
404
404
  `migration/localnet/out/localnet.env` in the `solana-ar-io` monorepo.
405
405
 
406
- ##### Faucet
406
+ <!-- ##### Faucet
407
407
 
408
408
  The SDK exposes a `createFaucet` HTTP wrapper around the ar.io faucet
409
409
  service ([faucet.ar.io](https://faucet.ar.io)). The faucet backend has
@@ -476,7 +476,7 @@ if (
476
476
  }
477
477
  ```
478
478
 
479
- </details>
479
+ </details> -->
480
480
 
481
481
  ### Vaults
482
482
 
@@ -2264,7 +2264,7 @@ console.log(`ANT was spawned with module: ${moduleId}`);
2264
2264
 
2265
2265
  // With custom GraphQL URL and retries
2266
2266
  const moduleId = await ant.getModuleId({
2267
- graphqlUrl: "https://arweave.net/graphql",
2267
+ graphqlUrl: "https://turbo-gateway.com/graphql",
2268
2268
  retries: 5,
2269
2269
  });
2270
2270
  ```
@@ -2665,7 +2665,7 @@ const balance = await ant.getBalance({
2665
2665
 
2666
2666
  #### `transfer({ target })`
2667
2667
 
2668
- Transfers ownership of the ANT to a new target address. Target MUST be an Arweave address.
2668
+ Transfers ownership of the ANT to a new target address. Target must be a Solana address. ANT transfers are standard Metaplex Core NFT transfers.
2669
2669
 
2670
2670
  _Note: Requires `signer` to be provided on `ANT.init` to sign the transaction._
2671
2671
 
@@ -3422,4 +3422,4 @@ For more information on how to contribute, please see [CONTRIBUTING.md].
3422
3422
 
3423
3423
  ```
3424
3424
 
3425
- ```
3425
+ ```
@@ -229,10 +229,17 @@ export function encodeReportTxId(reportTxId) {
229
229
  }
230
230
  /**
231
231
  * Max `compound_delegation_rewards` instructions packed into one batched tx.
232
- * Each carries a gateway + delegation + delegator account; 12 stays well within
233
- * the per-tx account/1232-byte budget even when none share a gateway.
232
+ * Each is a SEPARATE instruction carrying a gateway + delegation + delegator
233
+ * account, so unlike the single-ix `remaining_accounts` lifecycle batch (see
234
+ * `MAX_LIFECYCLE_BATCH`) and unlike prescribe (which uses an ALT) — the per-item
235
+ * tx cost is high and there is nothing to compress. Cap low enough that a full
236
+ * worst-case batch (all-distinct gateways → no account dedup) stays under
237
+ * Solana's 1232-byte transaction limit. A full batch of 12 overflows it and
238
+ * wedged epoch progression on staging-V2 (the RPC rejected the tx — observed at
239
+ * 1928B base64, well over the 1232B raw cap). Exported so the regression test in
240
+ * `compound-crank.test.ts` asserts this invariant against the live constant.
234
241
  */
235
- const MAX_COMPOUND_BATCH = 12;
242
+ export const MAX_COMPOUND_BATCH = 6;
236
243
  /** Observation PDAs closed per tx before close_epoch (each ix carries Epoch +
237
244
  * Observation + payer + system accounts — keep well under the tx account cap). */
238
245
  const MAX_CLOSE_OBSERVATION_BATCH = 8;
@@ -14,4 +14,4 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  // AUTOMATICALLY GENERATED FILE - DO NOT TOUCH
17
- export const version = '4.0.0-alpha.2';
17
+ export const version = '4.0.0-alpha.4';
@@ -121,6 +121,19 @@ export declare function buildObservationBitmap(registryAddresses: string[], fail
121
121
  * auditability that the field exists for.
122
122
  */
123
123
  export declare function encodeReportTxId(reportTxId: string | undefined): Buffer;
124
+ /**
125
+ * Max `compound_delegation_rewards` instructions packed into one batched tx.
126
+ * Each is a SEPARATE instruction carrying a gateway + delegation + delegator
127
+ * account, so — unlike the single-ix `remaining_accounts` lifecycle batch (see
128
+ * `MAX_LIFECYCLE_BATCH`) and unlike prescribe (which uses an ALT) — the per-item
129
+ * tx cost is high and there is nothing to compress. Cap low enough that a full
130
+ * worst-case batch (all-distinct gateways → no account dedup) stays under
131
+ * Solana's 1232-byte transaction limit. A full batch of 12 overflows it and
132
+ * wedged epoch progression on staging-V2 (the RPC rejected the tx — observed at
133
+ * 1928B base64, well over the 1232B raw cap). Exported so the regression test in
134
+ * `compound-crank.test.ts` asserts this invariant against the live constant.
135
+ */
136
+ export declare const MAX_COMPOUND_BATCH = 6;
124
137
  /** The single on-chain action a {@link SolanaARIOWriteable.crankEpochStep} call performed. */
125
138
  export type CrankAction = 'create' | 'tally' | 'prescribe' | 'distribute' | 'compound' | 'update_demand_factor' | 'prune_returned_names' | 'close_observation' | 'close' | 'idle';
126
139
  /** Options for {@link SolanaARIOWriteable.crankEpochStep}. */
@@ -13,4 +13,4 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- export declare const version = "4.0.0-alpha.1";
16
+ export declare const version = "4.0.0-alpha.3";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ar.io/sdk",
3
- "version": "4.0.0-alpha.2",
3
+ "version": "4.0.0-alpha.4",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/ar-io/ar-io-sdk.git"
@@ -114,7 +114,7 @@
114
114
  "typescript": "^5.1.6"
115
115
  },
116
116
  "dependencies": {
117
- "@ar.io/solana-contracts": "0.8.0-staging.18",
117
+ "@ar.io/solana-contracts": "1.0.0",
118
118
  "@noble/hashes": "^1.8.0",
119
119
  "@solana-program/address-lookup-table": "^0.11.0",
120
120
  "@solana-program/compute-budget": "^0.15.0",