@streamflow/stream 9.0.2 → 9.0.3
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/dist/cjs/{index-oCYfzJrc.d.cts → index-BgGtpOPg.d.cts} +5 -4
- package/dist/cjs/index.cjs +10 -7
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/cjs/index.d.cts +2 -2
- package/dist/cjs/solana/index.cjs +10 -7
- package/dist/cjs/solana/index.cjs.map +1 -1
- package/dist/cjs/solana/index.d.cts +1 -1
- package/dist/esm/{index-BNQVJtIE.d.ts → index-Dp5DXxr-.d.ts} +5 -4
- package/dist/esm/index.d.ts +2 -2
- package/dist/esm/index.js +10 -7
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/solana/index.d.ts +1 -1
- package/dist/esm/solana/index.js +10 -7
- package/dist/esm/solana/index.js.map +1 -1
- package/package.json +4 -4
package/dist/cjs/index.d.cts
CHANGED
|
@@ -2,8 +2,8 @@ import { A as AptosStreamClient, I as ICreateStreamAptosExt, a as ITransactionAp
|
|
|
2
2
|
export { i as StreamflowAptos } from './index-DYIamO0j.cjs';
|
|
3
3
|
import { E as EvmStreamClient } from './index-BMZATAYa.cjs';
|
|
4
4
|
export { i as StreamflowEVM } from './index-BMZATAYa.cjs';
|
|
5
|
-
import { S as SolanaStreamClient, I as ICreateStreamSolanaExt, a as IInteractStreamSolanaExt, b as ITopUpStreamSolanaExt } from './index-
|
|
6
|
-
export { s as AIRDROP_AMOUNT, q as AIRDROP_TEST_TOKEN, j as ALIGNED_COMPUTE_LIMIT, A as ALIGNED_PRECISION_FACTOR_POW, h as ALIGNED_UNLOCKS_PROGRAM_ID, k as CONTRACT_DISCRIMINATOR, m as CONTRACT_SEED, C as CREATE_PARAMS_PADDING, D as DEFAULT_STREAMFLOW_FEE, E as ESCROW_SEED, r as FEES_METADATA_SEED, F as FEE_ORACLE_PUBLIC_KEY, O as ORIGINAL_CONTRACT_SENDER_OFFSET, u as PARTNERS_SCHEMA, o as PARTNER_ORACLE_PROGRAM_ID, t as PARTNER_SCHEMA, P as PROGRAM_ID, w as SOLANA_ERROR_MAP, v as SOLANA_ERROR_MATCH_REGEX, p as STREAMFLOW_TREASURY_PUBLIC_KEY, g as STREAM_STRUCT_OFFSETS, f as STREAM_STRUCT_OFFSET_CLOSED, e as STREAM_STRUCT_OFFSET_MINT, d as STREAM_STRUCT_OFFSET_RECIPIENT, c as STREAM_STRUCT_OFFSET_SENDER, i as StreamflowSolana, l as TEST_ORACLE_DISCRIMINATOR, n as TEST_ORACLE_SEED, T as TX_FINALITY_CONFIRMED, W as WITHDRAWOR_PUBLIC_KEY } from './index-
|
|
5
|
+
import { S as SolanaStreamClient, I as ICreateStreamSolanaExt, a as IInteractStreamSolanaExt, b as ITopUpStreamSolanaExt } from './index-BgGtpOPg.cjs';
|
|
6
|
+
export { s as AIRDROP_AMOUNT, q as AIRDROP_TEST_TOKEN, j as ALIGNED_COMPUTE_LIMIT, A as ALIGNED_PRECISION_FACTOR_POW, h as ALIGNED_UNLOCKS_PROGRAM_ID, k as CONTRACT_DISCRIMINATOR, m as CONTRACT_SEED, C as CREATE_PARAMS_PADDING, D as DEFAULT_STREAMFLOW_FEE, E as ESCROW_SEED, r as FEES_METADATA_SEED, F as FEE_ORACLE_PUBLIC_KEY, O as ORIGINAL_CONTRACT_SENDER_OFFSET, u as PARTNERS_SCHEMA, o as PARTNER_ORACLE_PROGRAM_ID, t as PARTNER_SCHEMA, P as PROGRAM_ID, w as SOLANA_ERROR_MAP, v as SOLANA_ERROR_MATCH_REGEX, p as STREAMFLOW_TREASURY_PUBLIC_KEY, g as STREAM_STRUCT_OFFSETS, f as STREAM_STRUCT_OFFSET_CLOSED, e as STREAM_STRUCT_OFFSET_MINT, d as STREAM_STRUCT_OFFSET_RECIPIENT, c as STREAM_STRUCT_OFFSET_SENDER, i as StreamflowSolana, l as TEST_ORACLE_DISCRIMINATOR, n as TEST_ORACLE_SEED, T as TX_FINALITY_CONFIRMED, W as WITHDRAWOR_PUBLIC_KEY } from './index-BgGtpOPg.cjs';
|
|
7
7
|
import { S as SuiStreamClient } from './index-Y0HH2ugY.cjs';
|
|
8
8
|
export { i as StreamflowSui } from './index-Y0HH2ugY.cjs';
|
|
9
9
|
import { S as Stream, A as AlignedStream, I as ICreateStreamData, a as ICreateAlignedStreamData, b as StreamType, B as BaseStreamClient, c as SolanaStreamClientOptions, d as AptosStreamClientOptions, e as SuiStreamClientOptions, E as EvmStreamClientOptions, f as ICreateStreamSuiExt, g as ICreateResult, h as ICreateMultipleStreamData, i as IMultiTransactionResult, j as IWithdrawData, k as ITransactionSuiExt, l as ITransactionResult, m as ICancelData, n as ITransferData, o as ITopUpData, p as IGetOneData, q as IGetAllData, r as IUpdateData, s as IGetFeesData, t as IFees } from './BaseStreamClient-DOyJqO7R.cjs';
|
|
@@ -2454,6 +2454,9 @@ var SolanaStreamClient = class extends BaseStreamClient {
|
|
|
2454
2454
|
getProgramId() {
|
|
2455
2455
|
return this.programId.toBase58();
|
|
2456
2456
|
}
|
|
2457
|
+
getAlignedProxyProgramId() {
|
|
2458
|
+
return this.alignedProxyProgram.programId.toBase58();
|
|
2459
|
+
}
|
|
2457
2460
|
/**
|
|
2458
2461
|
* Builds transaction instructions for creating a new stream/vesting contract without creating a transaction.
|
|
2459
2462
|
* All fees are paid by sender (escrow metadata account rent, escrow token account rent, recipient's associated token account rent, Streamflow's service fee).
|
|
@@ -3682,6 +3685,13 @@ var SolanaStreamClient = class extends BaseStreamClient {
|
|
|
3682
3685
|
const logs = "logs" in err && Array.isArray(err.logs) ? err.logs : void 0;
|
|
3683
3686
|
return extractSolanaErrorCode(err.toString() ?? "Unknown error!", logs);
|
|
3684
3687
|
}
|
|
3688
|
+
/**
|
|
3689
|
+
* Utility function that checks whether the associated stream address is an aligned unlock contract, indicated by whether the sender/creator is a PDA
|
|
3690
|
+
*/
|
|
3691
|
+
isAlignedUnlock(streamPublicKey, senderPublicKey) {
|
|
3692
|
+
const pda = deriveContractPDA(this.alignedProxyProgram.programId, streamPublicKey);
|
|
3693
|
+
return senderPublicKey.equals(pda);
|
|
3694
|
+
}
|
|
3685
3695
|
/**
|
|
3686
3696
|
* Utility function to generate metadata for a Contract or return existing Pubkey
|
|
3687
3697
|
*/
|
|
@@ -3696,13 +3706,6 @@ var SolanaStreamClient = class extends BaseStreamClient {
|
|
|
3696
3706
|
}
|
|
3697
3707
|
return { metadata, metadataPubKey };
|
|
3698
3708
|
}
|
|
3699
|
-
/**
|
|
3700
|
-
* Utility function that checks whether the associated stream address is an aligned unlock contract, indicated by whether the sender/creator is a PDA
|
|
3701
|
-
*/
|
|
3702
|
-
isAlignedUnlock(streamPublicKey, senderPublicKey) {
|
|
3703
|
-
const pda = deriveContractPDA(this.alignedProxyProgram.programId, streamPublicKey);
|
|
3704
|
-
return senderPublicKey.equals(pda);
|
|
3705
|
-
}
|
|
3706
3709
|
/**
|
|
3707
3710
|
* Returns insrtuctions for creating associated token accounts for the provided owners
|
|
3708
3711
|
*/
|