@solana/subscriptions 0.1.0 → 0.2.0
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 +1 -0
- package/dist/index.cjs +298 -142
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +93 -48
- package/dist/index.d.ts +93 -48
- package/dist/index.js +280 -121
- package/dist/index.js.map +1 -1
- package/package.json +7 -7
package/dist/index.d.cts
CHANGED
|
@@ -703,7 +703,8 @@ declare enum SubscriptionsInstruction {
|
|
|
703
703
|
DeletePlan = 9,
|
|
704
704
|
TransferSubscription = 10,
|
|
705
705
|
Subscribe = 11,
|
|
706
|
-
CancelSubscription = 12
|
|
706
|
+
CancelSubscription = 12,
|
|
707
|
+
ResumeSubscription = 13
|
|
707
708
|
}
|
|
708
709
|
declare function identifySubscriptionsInstruction(instruction: {
|
|
709
710
|
data: ReadonlyUint8Array;
|
|
@@ -734,7 +735,9 @@ type ParsedSubscriptionsInstruction<TProgram extends string = 'De1egAFMkMWZSN5rY
|
|
|
734
735
|
instructionType: SubscriptionsInstruction.Subscribe;
|
|
735
736
|
} & ParsedSubscribeInstruction<TProgram>) | ({
|
|
736
737
|
instructionType: SubscriptionsInstruction.CancelSubscription;
|
|
737
|
-
} & ParsedCancelSubscriptionInstruction<TProgram>)
|
|
738
|
+
} & ParsedCancelSubscriptionInstruction<TProgram>) | ({
|
|
739
|
+
instructionType: SubscriptionsInstruction.ResumeSubscription;
|
|
740
|
+
} & ParsedResumeSubscriptionInstruction<TProgram>);
|
|
738
741
|
declare function parseSubscriptionsInstruction<TProgram extends string>(instruction: Instruction<TProgram> & InstructionWithData<ReadonlyUint8Array>): ParsedSubscriptionsInstruction<TProgram>;
|
|
739
742
|
type SubscriptionsPlugin$1 = {
|
|
740
743
|
accounts: SubscriptionsPluginAccounts;
|
|
@@ -763,6 +766,7 @@ type SubscriptionsPluginInstructions$1 = {
|
|
|
763
766
|
transferSubscription: (input: TransferSubscriptionInput$1) => ReturnType<typeof getTransferSubscriptionInstruction> & SelfPlanAndSendFunctions;
|
|
764
767
|
subscribe: (input: SubscribeAsyncInput) => ReturnType<typeof getSubscribeInstructionAsync> & SelfPlanAndSendFunctions;
|
|
765
768
|
cancelSubscription: (input: CancelSubscriptionAsyncInput) => ReturnType<typeof getCancelSubscriptionInstructionAsync> & SelfPlanAndSendFunctions;
|
|
769
|
+
resumeSubscription: (input: ResumeSubscriptionAsyncInput) => ReturnType<typeof getResumeSubscriptionInstructionAsync> & SelfPlanAndSendFunctions;
|
|
766
770
|
};
|
|
767
771
|
type SubscriptionsPluginPdas = {
|
|
768
772
|
fixedDelegation: typeof findFixedDelegationPda;
|
|
@@ -1199,6 +1203,79 @@ type ParsedInitSubscriptionAuthorityInstruction<TProgram extends string = typeof
|
|
|
1199
1203
|
};
|
|
1200
1204
|
declare function parseInitSubscriptionAuthorityInstruction<TProgram extends string, TAccountMetas extends readonly AccountMeta[]>(instruction: Instruction<TProgram> & InstructionWithAccounts<TAccountMetas> & InstructionWithData<ReadonlyUint8Array>): ParsedInitSubscriptionAuthorityInstruction<TProgram, TAccountMetas>;
|
|
1201
1205
|
|
|
1206
|
+
/**
|
|
1207
|
+
* This code was AUTOGENERATED using the Codama library.
|
|
1208
|
+
* Please DO NOT EDIT THIS FILE, instead use visitors
|
|
1209
|
+
* to add features, then rerun Codama to update it.
|
|
1210
|
+
*
|
|
1211
|
+
* @see https://github.com/codama-idl/codama
|
|
1212
|
+
*/
|
|
1213
|
+
|
|
1214
|
+
declare const RESUME_SUBSCRIPTION_DISCRIMINATOR = 13;
|
|
1215
|
+
declare function getResumeSubscriptionDiscriminatorBytes(): ReadonlyUint8Array;
|
|
1216
|
+
type ResumeSubscriptionInstruction<TProgram extends string = typeof SUBSCRIPTIONS_PROGRAM_ADDRESS, TAccountSubscriber extends string | AccountMeta<string> = string, TAccountPlanPda extends string | AccountMeta<string> = string, TAccountSubscriptionPda extends string | AccountMeta<string> = string, TAccountEventAuthority extends string | AccountMeta<string> = '3Hnj4BYoDgtpBuqXfiy7Y8cNa3jXaNd4oqgSXBzkMcH7', TAccountSelfProgram extends string | AccountMeta<string> = 'De1egAFMkMWZSN5rYXRj9CAdheBamobVNubTsi9avR44', TRemainingAccounts extends readonly AccountMeta<string>[] = []> = Instruction<TProgram> & InstructionWithData<ReadonlyUint8Array> & InstructionWithAccounts<[
|
|
1217
|
+
TAccountSubscriber extends string ? ReadonlySignerAccount<TAccountSubscriber> & AccountSignerMeta<TAccountSubscriber> : TAccountSubscriber,
|
|
1218
|
+
TAccountPlanPda extends string ? ReadonlyAccount<TAccountPlanPda> : TAccountPlanPda,
|
|
1219
|
+
TAccountSubscriptionPda extends string ? WritableAccount<TAccountSubscriptionPda> : TAccountSubscriptionPda,
|
|
1220
|
+
TAccountEventAuthority extends string ? ReadonlyAccount<TAccountEventAuthority> : TAccountEventAuthority,
|
|
1221
|
+
TAccountSelfProgram extends string ? ReadonlyAccount<TAccountSelfProgram> : TAccountSelfProgram,
|
|
1222
|
+
...TRemainingAccounts
|
|
1223
|
+
]>;
|
|
1224
|
+
type ResumeSubscriptionInstructionData = {
|
|
1225
|
+
discriminator: number;
|
|
1226
|
+
};
|
|
1227
|
+
type ResumeSubscriptionInstructionDataArgs = {};
|
|
1228
|
+
declare function getResumeSubscriptionInstructionDataEncoder(): FixedSizeEncoder<ResumeSubscriptionInstructionDataArgs>;
|
|
1229
|
+
declare function getResumeSubscriptionInstructionDataDecoder(): FixedSizeDecoder<ResumeSubscriptionInstructionData>;
|
|
1230
|
+
declare function getResumeSubscriptionInstructionDataCodec(): FixedSizeCodec<ResumeSubscriptionInstructionDataArgs, ResumeSubscriptionInstructionData>;
|
|
1231
|
+
type ResumeSubscriptionAsyncInput<TAccountSubscriber extends string = string, TAccountPlanPda extends string = string, TAccountSubscriptionPda extends string = string, TAccountEventAuthority extends string = string, TAccountSelfProgram extends string = string> = {
|
|
1232
|
+
/** The subscriber resuming the subscription */
|
|
1233
|
+
subscriber: TransactionSigner<TAccountSubscriber>;
|
|
1234
|
+
/** The plan PDA for the subscription */
|
|
1235
|
+
planPda: Address<TAccountPlanPda>;
|
|
1236
|
+
/** The subscription PDA being resumed */
|
|
1237
|
+
subscriptionPda?: Address<TAccountSubscriptionPda>;
|
|
1238
|
+
/** The event authority PDA */
|
|
1239
|
+
eventAuthority?: Address<TAccountEventAuthority>;
|
|
1240
|
+
/** This program (for self-CPI) */
|
|
1241
|
+
selfProgram?: Address<TAccountSelfProgram>;
|
|
1242
|
+
};
|
|
1243
|
+
declare function getResumeSubscriptionInstructionAsync<TAccountSubscriber extends string, TAccountPlanPda extends string, TAccountSubscriptionPda extends string, TAccountEventAuthority extends string, TAccountSelfProgram extends string, TProgramAddress extends Address = typeof SUBSCRIPTIONS_PROGRAM_ADDRESS>(input: ResumeSubscriptionAsyncInput<TAccountSubscriber, TAccountPlanPda, TAccountSubscriptionPda, TAccountEventAuthority, TAccountSelfProgram>, config?: {
|
|
1244
|
+
programAddress?: TProgramAddress;
|
|
1245
|
+
}): Promise<ResumeSubscriptionInstruction<TProgramAddress, TAccountSubscriber, TAccountPlanPda, TAccountSubscriptionPda, TAccountEventAuthority, TAccountSelfProgram>>;
|
|
1246
|
+
type ResumeSubscriptionInput$1<TAccountSubscriber extends string = string, TAccountPlanPda extends string = string, TAccountSubscriptionPda extends string = string, TAccountEventAuthority extends string = string, TAccountSelfProgram extends string = string> = {
|
|
1247
|
+
/** The subscriber resuming the subscription */
|
|
1248
|
+
subscriber: TransactionSigner<TAccountSubscriber>;
|
|
1249
|
+
/** The plan PDA for the subscription */
|
|
1250
|
+
planPda: Address<TAccountPlanPda>;
|
|
1251
|
+
/** The subscription PDA being resumed */
|
|
1252
|
+
subscriptionPda: Address<TAccountSubscriptionPda>;
|
|
1253
|
+
/** The event authority PDA */
|
|
1254
|
+
eventAuthority?: Address<TAccountEventAuthority>;
|
|
1255
|
+
/** This program (for self-CPI) */
|
|
1256
|
+
selfProgram?: Address<TAccountSelfProgram>;
|
|
1257
|
+
};
|
|
1258
|
+
declare function getResumeSubscriptionInstruction<TAccountSubscriber extends string, TAccountPlanPda extends string, TAccountSubscriptionPda extends string, TAccountEventAuthority extends string, TAccountSelfProgram extends string, TProgramAddress extends Address = typeof SUBSCRIPTIONS_PROGRAM_ADDRESS>(input: ResumeSubscriptionInput$1<TAccountSubscriber, TAccountPlanPda, TAccountSubscriptionPda, TAccountEventAuthority, TAccountSelfProgram>, config?: {
|
|
1259
|
+
programAddress?: TProgramAddress;
|
|
1260
|
+
}): ResumeSubscriptionInstruction<TProgramAddress, TAccountSubscriber, TAccountPlanPda, TAccountSubscriptionPda, TAccountEventAuthority, TAccountSelfProgram>;
|
|
1261
|
+
type ParsedResumeSubscriptionInstruction<TProgram extends string = typeof SUBSCRIPTIONS_PROGRAM_ADDRESS, TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[]> = {
|
|
1262
|
+
programAddress: Address<TProgram>;
|
|
1263
|
+
accounts: {
|
|
1264
|
+
/** The subscriber resuming the subscription */
|
|
1265
|
+
subscriber: TAccountMetas[0];
|
|
1266
|
+
/** The plan PDA for the subscription */
|
|
1267
|
+
planPda: TAccountMetas[1];
|
|
1268
|
+
/** The subscription PDA being resumed */
|
|
1269
|
+
subscriptionPda: TAccountMetas[2];
|
|
1270
|
+
/** The event authority PDA */
|
|
1271
|
+
eventAuthority: TAccountMetas[3];
|
|
1272
|
+
/** This program (for self-CPI) */
|
|
1273
|
+
selfProgram: TAccountMetas[4];
|
|
1274
|
+
};
|
|
1275
|
+
data: ResumeSubscriptionInstructionData;
|
|
1276
|
+
};
|
|
1277
|
+
declare function parseResumeSubscriptionInstruction<TProgram extends string, TAccountMetas extends readonly AccountMeta[]>(instruction: Instruction<TProgram> & InstructionWithAccounts<TAccountMetas> & InstructionWithData<ReadonlyUint8Array>): ParsedResumeSubscriptionInstruction<TProgram, TAccountMetas>;
|
|
1278
|
+
|
|
1202
1279
|
/**
|
|
1203
1280
|
* This code was AUTOGENERATED using the Codama library.
|
|
1204
1281
|
* Please DO NOT EDIT THIS FILE, instead use visitors
|
|
@@ -1742,50 +1819,6 @@ declare const METADATA_URI_LEN = 128;
|
|
|
1742
1819
|
/** On-chain delegation variant identifier (matches the `kind` tag in the `Delegation` union). */
|
|
1743
1820
|
type DelegationKindId = 'fixed' | 'recurring' | 'subscription';
|
|
1744
1821
|
|
|
1745
|
-
/**
|
|
1746
|
-
* `subscriptionsProgram()` — `@solana/kit` plugin that wraps the Codama-generated
|
|
1747
|
-
* `subscriptionsProgram()` plugin with higher-level instruction overlays
|
|
1748
|
-
* (PDA derivation, sponsor `payer` trailing accounts, ATA derivation, validators)
|
|
1749
|
-
* and a `queries` namespace for common account fetches.
|
|
1750
|
-
*
|
|
1751
|
-
* Each overlay defaults its actor field (`owner` / `delegator` / `subscriber`
|
|
1752
|
-
* / `authority` / `delegatee` / `caller`) to `client.identity`, and any
|
|
1753
|
-
* `payer` slot to `client.payer`. Sponsor flows install separate signers via
|
|
1754
|
-
* `payer()` + `identity()` instead of `signer()`.
|
|
1755
|
-
*
|
|
1756
|
-
* @example Same signer for everything
|
|
1757
|
-
* ```ts
|
|
1758
|
-
* import { createClient } from '@solana/kit';
|
|
1759
|
-
* import { signer } from '@solana/kit-plugin-signer';
|
|
1760
|
-
* import { solanaLocalRpc } from '@solana/kit-plugin-rpc';
|
|
1761
|
-
* import { subscriptionsProgram } from '@solana/subscriptions';
|
|
1762
|
-
*
|
|
1763
|
-
* const client = createClient()
|
|
1764
|
-
* .use(signer(mySigner))
|
|
1765
|
-
* .use(solanaLocalRpc())
|
|
1766
|
-
* .use(subscriptionsProgram());
|
|
1767
|
-
*
|
|
1768
|
-
* await client.subscriptions.instructions
|
|
1769
|
-
* .createPlan({ planId, mint, amount, periodHours, endTs, destinations, pullers, metadataUri })
|
|
1770
|
-
* .sendTransaction();
|
|
1771
|
-
* ```
|
|
1772
|
-
*
|
|
1773
|
-
* @example Sponsor pays fees + rent on behalf of the user
|
|
1774
|
-
* ```ts
|
|
1775
|
-
* import { payer, identity } from '@solana/kit-plugin-signer';
|
|
1776
|
-
*
|
|
1777
|
-
* const client = createClient()
|
|
1778
|
-
* .use(payer(sponsorSigner)) // pays gas + rent
|
|
1779
|
-
* .use(identity(userSigner)) // signs as delegator
|
|
1780
|
-
* .use(solanaLocalRpc())
|
|
1781
|
-
* .use(subscriptionsProgram());
|
|
1782
|
-
*
|
|
1783
|
-
* await client.subscriptions.instructions
|
|
1784
|
-
* .createFixedDelegation({ delegatee, nonce, amount, expiryTs, tokenMint })
|
|
1785
|
-
* .sendTransaction();
|
|
1786
|
-
* ```
|
|
1787
|
-
*/
|
|
1788
|
-
|
|
1789
1822
|
type WithProgramAddress = {
|
|
1790
1823
|
programAddress?: Address;
|
|
1791
1824
|
};
|
|
@@ -1901,6 +1934,11 @@ type CancelSubscriptionInput = WithProgramAddress & {
|
|
|
1901
1934
|
subscriber: TransactionSigner;
|
|
1902
1935
|
subscriptionPda?: Address;
|
|
1903
1936
|
};
|
|
1937
|
+
type ResumeSubscriptionInput = WithProgramAddress & {
|
|
1938
|
+
planPda: Address;
|
|
1939
|
+
subscriber: TransactionSigner;
|
|
1940
|
+
subscriptionPda?: Address;
|
|
1941
|
+
};
|
|
1904
1942
|
declare function getInitSubscriptionAuthorityOverlayInstructionAsync(input: InitSubscriptionAuthorityInput): Promise<Instruction>;
|
|
1905
1943
|
declare function getCloseSubscriptionAuthorityOverlayInstructionAsync(input: CloseSubscriptionAuthorityInput): Promise<Instruction>;
|
|
1906
1944
|
declare function getCreateFixedDelegationOverlayInstructionAsync(input: CreateFixedDelegationInput): Promise<Instruction>;
|
|
@@ -1920,6 +1958,7 @@ declare function getUpdatePlanOverlayInstruction(input: UpdatePlanInput): Instru
|
|
|
1920
1958
|
declare function getDeletePlanOverlayInstruction(input: DeletePlanInput): Instruction;
|
|
1921
1959
|
declare function getSubscribeOverlayInstructionAsync(input: SubscribeInput): Promise<Instruction>;
|
|
1922
1960
|
declare function getCancelSubscriptionOverlayInstructionAsync(input: CancelSubscriptionInput): Promise<Instruction>;
|
|
1961
|
+
declare function getResumeSubscriptionOverlayInstructionAsync(input: ResumeSubscriptionInput): Promise<Instruction>;
|
|
1923
1962
|
type SubscriptionsPluginRequirements = ClientWithIdentity & ClientWithPayer & ClientWithRpc<GetProgramAccountsApi> & SubscriptionsPluginRequirements$1;
|
|
1924
1963
|
type Self<T> = SelfPlanAndSendFunctions & T;
|
|
1925
1964
|
type SubscriptionsPluginInstructions = {
|
|
@@ -1930,6 +1969,7 @@ type SubscriptionsPluginInstructions = {
|
|
|
1930
1969
|
createRecurringDelegation: (input: MakeOptional<CreateRecurringDelegationInput, 'delegator' | 'payer'>) => Self<Promise<Instruction>>;
|
|
1931
1970
|
deletePlan: (input: MakeOptional<DeletePlanInput, 'owner'>) => Self<Instruction>;
|
|
1932
1971
|
initSubscriptionAuthority: (input: MakeOptional<InitSubscriptionAuthorityInput, 'owner' | 'payer'>) => Self<Promise<Instruction>>;
|
|
1972
|
+
resumeSubscription: (input: MakeOptional<ResumeSubscriptionInput, 'subscriber'>) => Self<Promise<Instruction>>;
|
|
1933
1973
|
revokeDelegation: (input: MakeOptional<RevokeDelegationInput, 'authority'>) => Self<Instruction>;
|
|
1934
1974
|
revokeSubscription: (input: MakeOptional<RevokeSubscriptionInput, 'authority'>) => Self<Instruction>;
|
|
1935
1975
|
subscribe: (input: MakeOptional<SubscribeInput, 'payer' | 'subscriber'>) => Self<Promise<Instruction>>;
|
|
@@ -1963,7 +2003,12 @@ type SubscriptionsPlugin = Omit<SubscriptionsPlugin$1, 'instructions'> & {
|
|
|
1963
2003
|
queries: SubscriptionsPluginQueries;
|
|
1964
2004
|
};
|
|
1965
2005
|
declare function subscriptionsProgram(): <T extends SubscriptionsPluginRequirements>(client: T) => Omit<T, "subscriptions"> & {
|
|
1966
|
-
subscriptions:
|
|
2006
|
+
subscriptions: {
|
|
2007
|
+
instructions: SubscriptionsPluginInstructions;
|
|
2008
|
+
queries: SubscriptionsPluginQueries;
|
|
2009
|
+
accounts: SubscriptionsPluginAccounts;
|
|
2010
|
+
pdas: SubscriptionsPluginPdas;
|
|
2011
|
+
};
|
|
1967
2012
|
};
|
|
1968
2013
|
|
|
1969
2014
|
/** Client-side validation failure (e.g. max destinations exceeded). */
|
|
@@ -1971,4 +2016,4 @@ declare class ValidationError extends Error {
|
|
|
1971
2016
|
constructor(message: string);
|
|
1972
2017
|
}
|
|
1973
2018
|
|
|
1974
|
-
export { AccountDiscriminator, type AccountDiscriminatorArgs, CANCEL_SUBSCRIPTION_DISCRIMINATOR, CLOSE_SUBSCRIPTION_AUTHORITY_DISCRIMINATOR, CREATE_FIXED_DELEGATION_DISCRIMINATOR, CREATE_PLAN_DISCRIMINATOR, CREATE_RECURRING_DELEGATION_DISCRIMINATOR, CURRENT_PROGRAM_VERSION, type CancelSubscriptionAsyncInput, type CancelSubscriptionInput, type CancelSubscriptionInstruction, type CancelSubscriptionInstructionData, type CancelSubscriptionInstructionDataArgs, type CloseSubscriptionAuthorityInput, type CloseSubscriptionAuthorityInstruction, type CloseSubscriptionAuthorityInstructionData, type CloseSubscriptionAuthorityInstructionDataArgs, type CreateFixedDelegationData, type CreateFixedDelegationDataArgs, type CreateFixedDelegationInput, type CreateFixedDelegationInstruction, type CreateFixedDelegationInstructionData, type CreateFixedDelegationInstructionDataArgs, type CreatePlanInput, type CreatePlanInstruction, type CreatePlanInstructionData, type CreatePlanInstructionDataArgs, type CreateRecurringDelegationData, type CreateRecurringDelegationDataArgs, type CreateRecurringDelegationInput, type CreateRecurringDelegationInstruction, type CreateRecurringDelegationInstructionData, type CreateRecurringDelegationInstructionDataArgs, DELEGATEE_OFFSET, DELEGATION_SEED, DELEGATOR_OFFSET, DELETE_PLAN_DISCRIMINATOR, DISCRIMINATOR_OFFSET, type Delegation, type DelegationKindId, type DeletePlanInput, type DeletePlanInstruction, type DeletePlanInstructionData, type DeletePlanInstructionDataArgs, EVENT_AUTHORITY_SEED, type EventAuthority, type EventAuthorityArgs, type FixedDelegation, type FixedDelegationArgs, type FixedDelegationSeeds, type Header, type HeaderArgs, INIT_SUBSCRIPTION_AUTHORITY_DISCRIMINATOR, type InitSubscriptionAuthorityAsyncInput, type InitSubscriptionAuthorityInput, type InitSubscriptionAuthorityInstruction, type InitSubscriptionAuthorityInstructionData, type InitSubscriptionAuthorityInstructionDataArgs, MAX_PLAN_DESTINATIONS, MAX_PLAN_PULLERS, METADATA_URI_LEN, PLAN_OWNER_OFFSET, PLAN_SEED, PLAN_SIZE, PROGRAM_ID, type ParsedCancelSubscriptionInstruction, type ParsedCloseSubscriptionAuthorityInstruction, type ParsedCreateFixedDelegationInstruction, type ParsedCreatePlanInstruction, type ParsedCreateRecurringDelegationInstruction, type ParsedDeletePlanInstruction, type ParsedInitSubscriptionAuthorityInstruction, type ParsedRevokeDelegationInstruction, type ParsedSubscribeInstruction, type ParsedSubscriptionsInstruction, type ParsedTransferFixedInstruction, type ParsedTransferRecurringInstruction, type ParsedTransferSubscriptionInstruction, type ParsedUpdatePlanInstruction, type Plan, type PlanArgs, type PlanData, type PlanDataArgs, type PlanSeeds, PlanStatus, type PlanStatusArgs, type PlanTerms, type PlanTermsArgs, type PlanWithAddress, REVOKE_DELEGATION_DISCRIMINATOR, type RawProgramAccount, type RecurringDelegation, type RecurringDelegationArgs, type RecurringDelegationSeeds, type RevokeDelegationInput, type RevokeDelegationInstruction, type RevokeDelegationInstructionData, type RevokeDelegationInstructionDataArgs, type RevokeSubscriptionInput, SUBSCRIBE_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__ACCOUNT_NOT_WRITABLE, SUBSCRIPTIONS_ERROR__ALREADY_SUBSCRIBED, SUBSCRIPTIONS_ERROR__AMOUNT_EXCEEDS_LIMIT, SUBSCRIPTIONS_ERROR__AMOUNT_EXCEEDS_PERIOD_LIMIT, SUBSCRIPTIONS_ERROR__ARITHMETIC_OVERFLOW, SUBSCRIPTIONS_ERROR__ARITHMETIC_UNDERFLOW, SUBSCRIPTIONS_ERROR__ATA_OWNER_MISMATCH, SUBSCRIPTIONS_ERROR__DELEGATION_ALREADY_EXISTS, SUBSCRIPTIONS_ERROR__DELEGATION_EXPIRED, SUBSCRIPTIONS_ERROR__DELEGATION_NOT_STARTED, SUBSCRIPTIONS_ERROR__DELEGATION_VERSION_MISMATCH, SUBSCRIPTIONS_ERROR__FIXED_DELEGATION_AMOUNT_ZERO, SUBSCRIPTIONS_ERROR__FIXED_DELEGATION_EXPIRY_IN_PAST, SUBSCRIPTIONS_ERROR__INVALID_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_ACCOUNT_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__INVALID_ADDRESS, SUBSCRIPTIONS_ERROR__INVALID_AMOUNT, SUBSCRIPTIONS_ERROR__INVALID_ASSOCIATED_TOKEN_ACCOUNT_DERIVED_ADDRESS, SUBSCRIPTIONS_ERROR__INVALID_DELEGATE_PDA, SUBSCRIPTIONS_ERROR__INVALID_END_TS, SUBSCRIPTIONS_ERROR__INVALID_ESCROW_PDA, SUBSCRIPTIONS_ERROR__INVALID_EVENT_AUTHORITY, SUBSCRIPTIONS_ERROR__INVALID_EVENT_DATA, SUBSCRIPTIONS_ERROR__INVALID_EVENT_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__INVALID_EVENT_TAG, SUBSCRIPTIONS_ERROR__INVALID_HEADER_DATA, SUBSCRIPTIONS_ERROR__INVALID_INSTRUCTION, SUBSCRIPTIONS_ERROR__INVALID_INSTRUCTION_DATA, SUBSCRIPTIONS_ERROR__INVALID_NUM_DESTINATIONS, SUBSCRIPTIONS_ERROR__INVALID_PAYER_DATA, SUBSCRIPTIONS_ERROR__INVALID_PERIOD_LENGTH, SUBSCRIPTIONS_ERROR__INVALID_PLAN_PDA, SUBSCRIPTIONS_ERROR__INVALID_PLAN_STATUS, SUBSCRIPTIONS_ERROR__INVALID_SUBSCRIPTION_AUTHORITY_PDA, SUBSCRIPTIONS_ERROR__INVALID_SUBSCRIPTION_PDA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN2022_MINT_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN2022_TOKEN_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_PROGRAM, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_SPL_MINT_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_SPL_TOKEN_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__MIGRATION_REQUIRED, SUBSCRIPTIONS_ERROR__MINT_HAS_CONFIDENTIAL_TRANSFER, SUBSCRIPTIONS_ERROR__MINT_HAS_MINT_CLOSE_AUTHORITY, SUBSCRIPTIONS_ERROR__MINT_HAS_NON_TRANSFERABLE, SUBSCRIPTIONS_ERROR__MINT_HAS_PAUSABLE, SUBSCRIPTIONS_ERROR__MINT_HAS_PERMANENT_DELEGATE, SUBSCRIPTIONS_ERROR__MINT_HAS_TRANSFER_FEE, SUBSCRIPTIONS_ERROR__MINT_HAS_TRANSFER_HOOK, SUBSCRIPTIONS_ERROR__MINT_MISMATCH, SUBSCRIPTIONS_ERROR__NOT_ENOUGH_ACCOUNT_KEYS, SUBSCRIPTIONS_ERROR__NOT_PLAN_OWNER, SUBSCRIPTIONS_ERROR__NOT_SIGNER, SUBSCRIPTIONS_ERROR__NOT_SYSTEM_PROGRAM, SUBSCRIPTIONS_ERROR__PERIOD_NOT_ELAPSED, SUBSCRIPTIONS_ERROR__PLAN_ALREADY_EXISTS, SUBSCRIPTIONS_ERROR__PLAN_CLOSED, SUBSCRIPTIONS_ERROR__PLAN_EXPIRED, SUBSCRIPTIONS_ERROR__PLAN_IMMUTABLE_AFTER_SUNSET, SUBSCRIPTIONS_ERROR__PLAN_NOT_EXPIRED, SUBSCRIPTIONS_ERROR__PLAN_SUNSET, SUBSCRIPTIONS_ERROR__PLAN_TERMS_MISMATCH, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_AMOUNT_ZERO, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_START_TIME_GREATER_THAN_EXPIRY, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_START_TIME_IN_PAST, SUBSCRIPTIONS_ERROR__STALE_SUBSCRIPTION_AUTHORITY, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_ALREADY_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_NOT_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_PLAN_MISMATCH, SUBSCRIPTIONS_ERROR__SUNSET_REQUIRES_END_TS, SUBSCRIPTIONS_ERROR__UNAUTHORIZED, SUBSCRIPTIONS_ERROR__UNAUTHORIZED_DESTINATION, SUBSCRIPTIONS_PROGRAM_ADDRESS, SUBSCRIPTION_AUTHORITY_SEED, SUBSCRIPTION_SEED, SUBSCRIPTION_SIZE, type SubscribeAsyncInput, type SubscribeData, type SubscribeDataArgs, type SubscribeInput, type SubscribeInstruction, type SubscribeInstructionData, type SubscribeInstructionDataArgs, type SubscriptionAuthority, type SubscriptionAuthorityArgs, type SubscriptionAuthoritySeeds, type SubscriptionDelegation, type SubscriptionDelegationArgs, type SubscriptionDelegationSeeds, SubscriptionsAccount, type SubscriptionsError, SubscriptionsInstruction, type SubscriptionsPlugin, type SubscriptionsPluginAccounts, type SubscriptionsPluginInstructions, type SubscriptionsPluginPdas, type SubscriptionsPluginQueries, type SubscriptionsPluginRequirements, TRANSFER_FIXED_DISCRIMINATOR, TRANSFER_RECURRING_DISCRIMINATOR, TRANSFER_SUBSCRIPTION_DISCRIMINATOR, type TransferData, type TransferDataArgs, type TransferDelegationInput, type TransferFixedInput, type TransferFixedInstruction, type TransferFixedInstructionData, type TransferFixedInstructionDataArgs, type TransferRecurringInput, type TransferRecurringInstruction, type TransferRecurringInstructionData, type TransferRecurringInstructionDataArgs, type TransferSubscriptionInput, type TransferSubscriptionInstruction, type TransferSubscriptionInstructionData, type TransferSubscriptionInstructionDataArgs, U64_BYTE_SIZE, UPDATE_PLAN_DISCRIMINATOR, type UpdatePlanData, type UpdatePlanDataArgs, type UpdatePlanInput, type UpdatePlanInstruction, type UpdatePlanInstructionData, type UpdatePlanInstructionDataArgs, ValidationError, ZERO_ADDRESS, decodeDelegationAccount, decodeEventAuthority, decodeFixedDelegation, decodePlan, decodeRecurringDelegation, decodeSubscriptionAuthority, decodeSubscriptionDelegation, fetchAllEventAuthority, fetchAllFixedDelegation, fetchAllMaybeEventAuthority, fetchAllMaybeFixedDelegation, fetchAllMaybePlan, fetchAllMaybeRecurringDelegation, fetchAllMaybeSubscriptionAuthority, fetchAllMaybeSubscriptionDelegation, fetchAllPlan, fetchAllRecurringDelegation, fetchAllSubscriptionAuthority, fetchAllSubscriptionDelegation, fetchDelegationsByDelegatee, fetchDelegationsByDelegator, fetchEventAuthority, fetchEventAuthorityFromSeeds, fetchFixedDelegation, fetchFixedDelegationFromSeeds, fetchMaybeEventAuthority, fetchMaybeEventAuthorityFromSeeds, fetchMaybeFixedDelegation, fetchMaybeFixedDelegationFromSeeds, fetchMaybePlan, fetchMaybePlanFromSeeds, fetchMaybeRecurringDelegation, fetchMaybeRecurringDelegationFromSeeds, fetchMaybeSubscriptionAuthority, fetchMaybeSubscriptionAuthorityFromSeeds, fetchMaybeSubscriptionDelegation, fetchMaybeSubscriptionDelegationFromSeeds, fetchPlan, fetchPlanFromSeeds, fetchPlansForOwner, fetchRecurringDelegation, fetchRecurringDelegationFromSeeds, fetchSubscriptionAuthority, fetchSubscriptionAuthorityFromSeeds, fetchSubscriptionDelegation, fetchSubscriptionDelegationFromSeeds, fetchSubscriptionsForUser, findEventAuthorityPda, findFixedDelegationPda, findPlanPda, findRecurringDelegationPda, findSubscriptionAuthorityPda, findSubscriptionDelegationPda, getAccountDiscriminatorCodec, getAccountDiscriminatorDecoder, getAccountDiscriminatorEncoder, getCancelSubscriptionDiscriminatorBytes, getCancelSubscriptionInstruction, getCancelSubscriptionInstructionAsync, getCancelSubscriptionInstructionDataCodec, getCancelSubscriptionInstructionDataDecoder, getCancelSubscriptionInstructionDataEncoder, getCancelSubscriptionOverlayInstructionAsync, getCloseSubscriptionAuthorityDiscriminatorBytes, getCloseSubscriptionAuthorityInstruction, getCloseSubscriptionAuthorityInstructionDataCodec, getCloseSubscriptionAuthorityInstructionDataDecoder, getCloseSubscriptionAuthorityInstructionDataEncoder, getCloseSubscriptionAuthorityOverlayInstructionAsync, getCreateFixedDelegationDataCodec, getCreateFixedDelegationDataDecoder, getCreateFixedDelegationDataEncoder, getCreateFixedDelegationDiscriminatorBytes, getCreateFixedDelegationInstruction, getCreateFixedDelegationInstructionDataCodec, getCreateFixedDelegationInstructionDataDecoder, getCreateFixedDelegationInstructionDataEncoder, getCreateFixedDelegationOverlayInstructionAsync, getCreatePlanDiscriminatorBytes, getCreatePlanInstruction, getCreatePlanInstructionDataCodec, getCreatePlanInstructionDataDecoder, getCreatePlanInstructionDataEncoder, getCreatePlanOverlayInstructionAsync, getCreateRecurringDelegationDataCodec, getCreateRecurringDelegationDataDecoder, getCreateRecurringDelegationDataEncoder, getCreateRecurringDelegationDiscriminatorBytes, getCreateRecurringDelegationInstruction, getCreateRecurringDelegationInstructionDataCodec, getCreateRecurringDelegationInstructionDataDecoder, getCreateRecurringDelegationInstructionDataEncoder, getCreateRecurringDelegationOverlayInstructionAsync, getDeletePlanDiscriminatorBytes, getDeletePlanInstruction, getDeletePlanInstructionDataCodec, getDeletePlanInstructionDataDecoder, getDeletePlanInstructionDataEncoder, getDeletePlanOverlayInstruction, getEventAuthorityCodec, getEventAuthorityDecoder, getEventAuthorityEncoder, getFixedDelegationCodec, getFixedDelegationDecoder, getFixedDelegationEncoder, getHeaderCodec, getHeaderDecoder, getHeaderEncoder, getInitSubscriptionAuthorityDiscriminatorBytes, getInitSubscriptionAuthorityInstruction, getInitSubscriptionAuthorityInstructionAsync, getInitSubscriptionAuthorityInstructionDataCodec, getInitSubscriptionAuthorityInstructionDataDecoder, getInitSubscriptionAuthorityInstructionDataEncoder, getInitSubscriptionAuthorityOverlayInstructionAsync, getPlanCodec, getPlanDataCodec, getPlanDataDecoder, getPlanDataEncoder, getPlanDecoder, getPlanEncoder, getPlanStatusCodec, getPlanStatusDecoder, getPlanStatusEncoder, getPlanTermsCodec, getPlanTermsDecoder, getPlanTermsEncoder, getRecurringDelegationCodec, getRecurringDelegationDecoder, getRecurringDelegationEncoder, getRevokeDelegationDiscriminatorBytes, getRevokeDelegationInstruction, getRevokeDelegationInstructionDataCodec, getRevokeDelegationInstructionDataDecoder, getRevokeDelegationInstructionDataEncoder, getRevokeDelegationOverlayInstruction, getRevokeSubscriptionOverlayInstruction, getSubscribeDataCodec, getSubscribeDataDecoder, getSubscribeDataEncoder, getSubscribeDiscriminatorBytes, getSubscribeInstruction, getSubscribeInstructionAsync, getSubscribeInstructionDataCodec, getSubscribeInstructionDataDecoder, getSubscribeInstructionDataEncoder, getSubscribeOverlayInstructionAsync, getSubscriptionAuthorityCodec, getSubscriptionAuthorityDecoder, getSubscriptionAuthorityEncoder, getSubscriptionDelegationCodec, getSubscriptionDelegationDecoder, getSubscriptionDelegationEncoder, getSubscriptionsErrorMessage, getTransferDataCodec, getTransferDataDecoder, getTransferDataEncoder, getTransferFixedDiscriminatorBytes, getTransferFixedInstruction, getTransferFixedInstructionDataCodec, getTransferFixedInstructionDataDecoder, getTransferFixedInstructionDataEncoder, getTransferFixedOverlayInstructionAsync, getTransferRecurringDiscriminatorBytes, getTransferRecurringInstruction, getTransferRecurringInstructionDataCodec, getTransferRecurringInstructionDataDecoder, getTransferRecurringInstructionDataEncoder, getTransferRecurringOverlayInstructionAsync, getTransferSubscriptionDiscriminatorBytes, getTransferSubscriptionInstruction, getTransferSubscriptionInstructionDataCodec, getTransferSubscriptionInstructionDataDecoder, getTransferSubscriptionInstructionDataEncoder, getTransferSubscriptionOverlayInstructionAsync, getUpdatePlanDataCodec, getUpdatePlanDataDecoder, getUpdatePlanDataEncoder, getUpdatePlanDiscriminatorBytes, getUpdatePlanInstruction, getUpdatePlanInstructionDataCodec, getUpdatePlanInstructionDataDecoder, getUpdatePlanInstructionDataEncoder, getUpdatePlanOverlayInstruction, identifySubscriptionsInstruction, isSubscriptionsError, parseCancelSubscriptionInstruction, parseCloseSubscriptionAuthorityInstruction, parseCreateFixedDelegationInstruction, parseCreatePlanInstruction, parseCreateRecurringDelegationInstruction, parseDeletePlanInstruction, parseInitSubscriptionAuthorityInstruction, parseRevokeDelegationInstruction, parseSubscribeInstruction, parseSubscriptionsInstruction, parseTransferFixedInstruction, parseTransferRecurringInstruction, parseTransferSubscriptionInstruction, parseUpdatePlanInstruction, subscriptionsProgram, toEncodedAccount };
|
|
2019
|
+
export { AccountDiscriminator, type AccountDiscriminatorArgs, CANCEL_SUBSCRIPTION_DISCRIMINATOR, CLOSE_SUBSCRIPTION_AUTHORITY_DISCRIMINATOR, CREATE_FIXED_DELEGATION_DISCRIMINATOR, CREATE_PLAN_DISCRIMINATOR, CREATE_RECURRING_DELEGATION_DISCRIMINATOR, CURRENT_PROGRAM_VERSION, type CancelSubscriptionAsyncInput, type CancelSubscriptionInput, type CancelSubscriptionInstruction, type CancelSubscriptionInstructionData, type CancelSubscriptionInstructionDataArgs, type CloseSubscriptionAuthorityInput, type CloseSubscriptionAuthorityInstruction, type CloseSubscriptionAuthorityInstructionData, type CloseSubscriptionAuthorityInstructionDataArgs, type CreateFixedDelegationData, type CreateFixedDelegationDataArgs, type CreateFixedDelegationInput, type CreateFixedDelegationInstruction, type CreateFixedDelegationInstructionData, type CreateFixedDelegationInstructionDataArgs, type CreatePlanInput, type CreatePlanInstruction, type CreatePlanInstructionData, type CreatePlanInstructionDataArgs, type CreateRecurringDelegationData, type CreateRecurringDelegationDataArgs, type CreateRecurringDelegationInput, type CreateRecurringDelegationInstruction, type CreateRecurringDelegationInstructionData, type CreateRecurringDelegationInstructionDataArgs, DELEGATEE_OFFSET, DELEGATION_SEED, DELEGATOR_OFFSET, DELETE_PLAN_DISCRIMINATOR, DISCRIMINATOR_OFFSET, type Delegation, type DelegationKindId, type DeletePlanInput, type DeletePlanInstruction, type DeletePlanInstructionData, type DeletePlanInstructionDataArgs, EVENT_AUTHORITY_SEED, type EventAuthority, type EventAuthorityArgs, type FixedDelegation, type FixedDelegationArgs, type FixedDelegationSeeds, type Header, type HeaderArgs, INIT_SUBSCRIPTION_AUTHORITY_DISCRIMINATOR, type InitSubscriptionAuthorityAsyncInput, type InitSubscriptionAuthorityInput, type InitSubscriptionAuthorityInstruction, type InitSubscriptionAuthorityInstructionData, type InitSubscriptionAuthorityInstructionDataArgs, MAX_PLAN_DESTINATIONS, MAX_PLAN_PULLERS, METADATA_URI_LEN, PLAN_OWNER_OFFSET, PLAN_SEED, PLAN_SIZE, PROGRAM_ID, type ParsedCancelSubscriptionInstruction, type ParsedCloseSubscriptionAuthorityInstruction, type ParsedCreateFixedDelegationInstruction, type ParsedCreatePlanInstruction, type ParsedCreateRecurringDelegationInstruction, type ParsedDeletePlanInstruction, type ParsedInitSubscriptionAuthorityInstruction, type ParsedResumeSubscriptionInstruction, type ParsedRevokeDelegationInstruction, type ParsedSubscribeInstruction, type ParsedSubscriptionsInstruction, type ParsedTransferFixedInstruction, type ParsedTransferRecurringInstruction, type ParsedTransferSubscriptionInstruction, type ParsedUpdatePlanInstruction, type Plan, type PlanArgs, type PlanData, type PlanDataArgs, type PlanSeeds, PlanStatus, type PlanStatusArgs, type PlanTerms, type PlanTermsArgs, type PlanWithAddress, RESUME_SUBSCRIPTION_DISCRIMINATOR, REVOKE_DELEGATION_DISCRIMINATOR, type RawProgramAccount, type RecurringDelegation, type RecurringDelegationArgs, type RecurringDelegationSeeds, type ResumeSubscriptionAsyncInput, type ResumeSubscriptionInput, type ResumeSubscriptionInstruction, type ResumeSubscriptionInstructionData, type ResumeSubscriptionInstructionDataArgs, type RevokeDelegationInput, type RevokeDelegationInstruction, type RevokeDelegationInstructionData, type RevokeDelegationInstructionDataArgs, type RevokeSubscriptionInput, SUBSCRIBE_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__ACCOUNT_NOT_WRITABLE, SUBSCRIPTIONS_ERROR__ALREADY_SUBSCRIBED, SUBSCRIPTIONS_ERROR__AMOUNT_EXCEEDS_LIMIT, SUBSCRIPTIONS_ERROR__AMOUNT_EXCEEDS_PERIOD_LIMIT, SUBSCRIPTIONS_ERROR__ARITHMETIC_OVERFLOW, SUBSCRIPTIONS_ERROR__ARITHMETIC_UNDERFLOW, SUBSCRIPTIONS_ERROR__ATA_OWNER_MISMATCH, SUBSCRIPTIONS_ERROR__DELEGATION_ALREADY_EXISTS, SUBSCRIPTIONS_ERROR__DELEGATION_EXPIRED, SUBSCRIPTIONS_ERROR__DELEGATION_NOT_STARTED, SUBSCRIPTIONS_ERROR__DELEGATION_VERSION_MISMATCH, SUBSCRIPTIONS_ERROR__FIXED_DELEGATION_AMOUNT_ZERO, SUBSCRIPTIONS_ERROR__FIXED_DELEGATION_EXPIRY_IN_PAST, SUBSCRIPTIONS_ERROR__INVALID_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_ACCOUNT_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__INVALID_ADDRESS, SUBSCRIPTIONS_ERROR__INVALID_AMOUNT, SUBSCRIPTIONS_ERROR__INVALID_ASSOCIATED_TOKEN_ACCOUNT_DERIVED_ADDRESS, SUBSCRIPTIONS_ERROR__INVALID_DELEGATE_PDA, SUBSCRIPTIONS_ERROR__INVALID_END_TS, SUBSCRIPTIONS_ERROR__INVALID_ESCROW_PDA, SUBSCRIPTIONS_ERROR__INVALID_EVENT_AUTHORITY, SUBSCRIPTIONS_ERROR__INVALID_EVENT_DATA, SUBSCRIPTIONS_ERROR__INVALID_EVENT_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__INVALID_EVENT_TAG, SUBSCRIPTIONS_ERROR__INVALID_HEADER_DATA, SUBSCRIPTIONS_ERROR__INVALID_INSTRUCTION, SUBSCRIPTIONS_ERROR__INVALID_INSTRUCTION_DATA, SUBSCRIPTIONS_ERROR__INVALID_NUM_DESTINATIONS, SUBSCRIPTIONS_ERROR__INVALID_PAYER_DATA, SUBSCRIPTIONS_ERROR__INVALID_PERIOD_LENGTH, SUBSCRIPTIONS_ERROR__INVALID_PLAN_PDA, SUBSCRIPTIONS_ERROR__INVALID_PLAN_STATUS, SUBSCRIPTIONS_ERROR__INVALID_SUBSCRIPTION_AUTHORITY_PDA, SUBSCRIPTIONS_ERROR__INVALID_SUBSCRIPTION_PDA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN2022_MINT_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN2022_TOKEN_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_PROGRAM, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_SPL_MINT_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_SPL_TOKEN_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__MIGRATION_REQUIRED, SUBSCRIPTIONS_ERROR__MINT_HAS_CONFIDENTIAL_TRANSFER, SUBSCRIPTIONS_ERROR__MINT_HAS_MINT_CLOSE_AUTHORITY, SUBSCRIPTIONS_ERROR__MINT_HAS_NON_TRANSFERABLE, SUBSCRIPTIONS_ERROR__MINT_HAS_PAUSABLE, SUBSCRIPTIONS_ERROR__MINT_HAS_PERMANENT_DELEGATE, SUBSCRIPTIONS_ERROR__MINT_HAS_TRANSFER_FEE, SUBSCRIPTIONS_ERROR__MINT_HAS_TRANSFER_HOOK, SUBSCRIPTIONS_ERROR__MINT_MISMATCH, SUBSCRIPTIONS_ERROR__NOT_ENOUGH_ACCOUNT_KEYS, SUBSCRIPTIONS_ERROR__NOT_PLAN_OWNER, SUBSCRIPTIONS_ERROR__NOT_SIGNER, SUBSCRIPTIONS_ERROR__NOT_SYSTEM_PROGRAM, SUBSCRIPTIONS_ERROR__PERIOD_NOT_ELAPSED, SUBSCRIPTIONS_ERROR__PLAN_ALREADY_EXISTS, SUBSCRIPTIONS_ERROR__PLAN_CLOSED, SUBSCRIPTIONS_ERROR__PLAN_EXPIRED, SUBSCRIPTIONS_ERROR__PLAN_IMMUTABLE_AFTER_SUNSET, SUBSCRIPTIONS_ERROR__PLAN_NOT_EXPIRED, SUBSCRIPTIONS_ERROR__PLAN_SUNSET, SUBSCRIPTIONS_ERROR__PLAN_TERMS_MISMATCH, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_AMOUNT_ZERO, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_START_TIME_GREATER_THAN_EXPIRY, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_START_TIME_IN_PAST, SUBSCRIPTIONS_ERROR__STALE_SUBSCRIPTION_AUTHORITY, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_ALREADY_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_NOT_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_PLAN_MISMATCH, SUBSCRIPTIONS_ERROR__SUNSET_REQUIRES_END_TS, SUBSCRIPTIONS_ERROR__UNAUTHORIZED, SUBSCRIPTIONS_ERROR__UNAUTHORIZED_DESTINATION, SUBSCRIPTIONS_PROGRAM_ADDRESS, SUBSCRIPTION_AUTHORITY_SEED, SUBSCRIPTION_SEED, SUBSCRIPTION_SIZE, type SubscribeAsyncInput, type SubscribeData, type SubscribeDataArgs, type SubscribeInput, type SubscribeInstruction, type SubscribeInstructionData, type SubscribeInstructionDataArgs, type SubscriptionAuthority, type SubscriptionAuthorityArgs, type SubscriptionAuthoritySeeds, type SubscriptionDelegation, type SubscriptionDelegationArgs, type SubscriptionDelegationSeeds, SubscriptionsAccount, type SubscriptionsError, SubscriptionsInstruction, type SubscriptionsPlugin, type SubscriptionsPluginAccounts, type SubscriptionsPluginInstructions, type SubscriptionsPluginPdas, type SubscriptionsPluginQueries, type SubscriptionsPluginRequirements, TRANSFER_FIXED_DISCRIMINATOR, TRANSFER_RECURRING_DISCRIMINATOR, TRANSFER_SUBSCRIPTION_DISCRIMINATOR, type TransferData, type TransferDataArgs, type TransferDelegationInput, type TransferFixedInput, type TransferFixedInstruction, type TransferFixedInstructionData, type TransferFixedInstructionDataArgs, type TransferRecurringInput, type TransferRecurringInstruction, type TransferRecurringInstructionData, type TransferRecurringInstructionDataArgs, type TransferSubscriptionInput, type TransferSubscriptionInstruction, type TransferSubscriptionInstructionData, type TransferSubscriptionInstructionDataArgs, U64_BYTE_SIZE, UPDATE_PLAN_DISCRIMINATOR, type UpdatePlanData, type UpdatePlanDataArgs, type UpdatePlanInput, type UpdatePlanInstruction, type UpdatePlanInstructionData, type UpdatePlanInstructionDataArgs, ValidationError, ZERO_ADDRESS, decodeDelegationAccount, decodeEventAuthority, decodeFixedDelegation, decodePlan, decodeRecurringDelegation, decodeSubscriptionAuthority, decodeSubscriptionDelegation, fetchAllEventAuthority, fetchAllFixedDelegation, fetchAllMaybeEventAuthority, fetchAllMaybeFixedDelegation, fetchAllMaybePlan, fetchAllMaybeRecurringDelegation, fetchAllMaybeSubscriptionAuthority, fetchAllMaybeSubscriptionDelegation, fetchAllPlan, fetchAllRecurringDelegation, fetchAllSubscriptionAuthority, fetchAllSubscriptionDelegation, fetchDelegationsByDelegatee, fetchDelegationsByDelegator, fetchEventAuthority, fetchEventAuthorityFromSeeds, fetchFixedDelegation, fetchFixedDelegationFromSeeds, fetchMaybeEventAuthority, fetchMaybeEventAuthorityFromSeeds, fetchMaybeFixedDelegation, fetchMaybeFixedDelegationFromSeeds, fetchMaybePlan, fetchMaybePlanFromSeeds, fetchMaybeRecurringDelegation, fetchMaybeRecurringDelegationFromSeeds, fetchMaybeSubscriptionAuthority, fetchMaybeSubscriptionAuthorityFromSeeds, fetchMaybeSubscriptionDelegation, fetchMaybeSubscriptionDelegationFromSeeds, fetchPlan, fetchPlanFromSeeds, fetchPlansForOwner, fetchRecurringDelegation, fetchRecurringDelegationFromSeeds, fetchSubscriptionAuthority, fetchSubscriptionAuthorityFromSeeds, fetchSubscriptionDelegation, fetchSubscriptionDelegationFromSeeds, fetchSubscriptionsForUser, findEventAuthorityPda, findFixedDelegationPda, findPlanPda, findRecurringDelegationPda, findSubscriptionAuthorityPda, findSubscriptionDelegationPda, getAccountDiscriminatorCodec, getAccountDiscriminatorDecoder, getAccountDiscriminatorEncoder, getCancelSubscriptionDiscriminatorBytes, getCancelSubscriptionInstruction, getCancelSubscriptionInstructionAsync, getCancelSubscriptionInstructionDataCodec, getCancelSubscriptionInstructionDataDecoder, getCancelSubscriptionInstructionDataEncoder, getCancelSubscriptionOverlayInstructionAsync, getCloseSubscriptionAuthorityDiscriminatorBytes, getCloseSubscriptionAuthorityInstruction, getCloseSubscriptionAuthorityInstructionDataCodec, getCloseSubscriptionAuthorityInstructionDataDecoder, getCloseSubscriptionAuthorityInstructionDataEncoder, getCloseSubscriptionAuthorityOverlayInstructionAsync, getCreateFixedDelegationDataCodec, getCreateFixedDelegationDataDecoder, getCreateFixedDelegationDataEncoder, getCreateFixedDelegationDiscriminatorBytes, getCreateFixedDelegationInstruction, getCreateFixedDelegationInstructionDataCodec, getCreateFixedDelegationInstructionDataDecoder, getCreateFixedDelegationInstructionDataEncoder, getCreateFixedDelegationOverlayInstructionAsync, getCreatePlanDiscriminatorBytes, getCreatePlanInstruction, getCreatePlanInstructionDataCodec, getCreatePlanInstructionDataDecoder, getCreatePlanInstructionDataEncoder, getCreatePlanOverlayInstructionAsync, getCreateRecurringDelegationDataCodec, getCreateRecurringDelegationDataDecoder, getCreateRecurringDelegationDataEncoder, getCreateRecurringDelegationDiscriminatorBytes, getCreateRecurringDelegationInstruction, getCreateRecurringDelegationInstructionDataCodec, getCreateRecurringDelegationInstructionDataDecoder, getCreateRecurringDelegationInstructionDataEncoder, getCreateRecurringDelegationOverlayInstructionAsync, getDeletePlanDiscriminatorBytes, getDeletePlanInstruction, getDeletePlanInstructionDataCodec, getDeletePlanInstructionDataDecoder, getDeletePlanInstructionDataEncoder, getDeletePlanOverlayInstruction, getEventAuthorityCodec, getEventAuthorityDecoder, getEventAuthorityEncoder, getFixedDelegationCodec, getFixedDelegationDecoder, getFixedDelegationEncoder, getHeaderCodec, getHeaderDecoder, getHeaderEncoder, getInitSubscriptionAuthorityDiscriminatorBytes, getInitSubscriptionAuthorityInstruction, getInitSubscriptionAuthorityInstructionAsync, getInitSubscriptionAuthorityInstructionDataCodec, getInitSubscriptionAuthorityInstructionDataDecoder, getInitSubscriptionAuthorityInstructionDataEncoder, getInitSubscriptionAuthorityOverlayInstructionAsync, getPlanCodec, getPlanDataCodec, getPlanDataDecoder, getPlanDataEncoder, getPlanDecoder, getPlanEncoder, getPlanStatusCodec, getPlanStatusDecoder, getPlanStatusEncoder, getPlanTermsCodec, getPlanTermsDecoder, getPlanTermsEncoder, getRecurringDelegationCodec, getRecurringDelegationDecoder, getRecurringDelegationEncoder, getResumeSubscriptionDiscriminatorBytes, getResumeSubscriptionInstruction, getResumeSubscriptionInstructionAsync, getResumeSubscriptionInstructionDataCodec, getResumeSubscriptionInstructionDataDecoder, getResumeSubscriptionInstructionDataEncoder, getResumeSubscriptionOverlayInstructionAsync, getRevokeDelegationDiscriminatorBytes, getRevokeDelegationInstruction, getRevokeDelegationInstructionDataCodec, getRevokeDelegationInstructionDataDecoder, getRevokeDelegationInstructionDataEncoder, getRevokeDelegationOverlayInstruction, getRevokeSubscriptionOverlayInstruction, getSubscribeDataCodec, getSubscribeDataDecoder, getSubscribeDataEncoder, getSubscribeDiscriminatorBytes, getSubscribeInstruction, getSubscribeInstructionAsync, getSubscribeInstructionDataCodec, getSubscribeInstructionDataDecoder, getSubscribeInstructionDataEncoder, getSubscribeOverlayInstructionAsync, getSubscriptionAuthorityCodec, getSubscriptionAuthorityDecoder, getSubscriptionAuthorityEncoder, getSubscriptionDelegationCodec, getSubscriptionDelegationDecoder, getSubscriptionDelegationEncoder, getSubscriptionsErrorMessage, getTransferDataCodec, getTransferDataDecoder, getTransferDataEncoder, getTransferFixedDiscriminatorBytes, getTransferFixedInstruction, getTransferFixedInstructionDataCodec, getTransferFixedInstructionDataDecoder, getTransferFixedInstructionDataEncoder, getTransferFixedOverlayInstructionAsync, getTransferRecurringDiscriminatorBytes, getTransferRecurringInstruction, getTransferRecurringInstructionDataCodec, getTransferRecurringInstructionDataDecoder, getTransferRecurringInstructionDataEncoder, getTransferRecurringOverlayInstructionAsync, getTransferSubscriptionDiscriminatorBytes, getTransferSubscriptionInstruction, getTransferSubscriptionInstructionDataCodec, getTransferSubscriptionInstructionDataDecoder, getTransferSubscriptionInstructionDataEncoder, getTransferSubscriptionOverlayInstructionAsync, getUpdatePlanDataCodec, getUpdatePlanDataDecoder, getUpdatePlanDataEncoder, getUpdatePlanDiscriminatorBytes, getUpdatePlanInstruction, getUpdatePlanInstructionDataCodec, getUpdatePlanInstructionDataDecoder, getUpdatePlanInstructionDataEncoder, getUpdatePlanOverlayInstruction, identifySubscriptionsInstruction, isSubscriptionsError, parseCancelSubscriptionInstruction, parseCloseSubscriptionAuthorityInstruction, parseCreateFixedDelegationInstruction, parseCreatePlanInstruction, parseCreateRecurringDelegationInstruction, parseDeletePlanInstruction, parseInitSubscriptionAuthorityInstruction, parseResumeSubscriptionInstruction, parseRevokeDelegationInstruction, parseSubscribeInstruction, parseSubscriptionsInstruction, parseTransferFixedInstruction, parseTransferRecurringInstruction, parseTransferSubscriptionInstruction, parseUpdatePlanInstruction, subscriptionsProgram, toEncodedAccount };
|
package/dist/index.d.ts
CHANGED
|
@@ -703,7 +703,8 @@ declare enum SubscriptionsInstruction {
|
|
|
703
703
|
DeletePlan = 9,
|
|
704
704
|
TransferSubscription = 10,
|
|
705
705
|
Subscribe = 11,
|
|
706
|
-
CancelSubscription = 12
|
|
706
|
+
CancelSubscription = 12,
|
|
707
|
+
ResumeSubscription = 13
|
|
707
708
|
}
|
|
708
709
|
declare function identifySubscriptionsInstruction(instruction: {
|
|
709
710
|
data: ReadonlyUint8Array;
|
|
@@ -734,7 +735,9 @@ type ParsedSubscriptionsInstruction<TProgram extends string = 'De1egAFMkMWZSN5rY
|
|
|
734
735
|
instructionType: SubscriptionsInstruction.Subscribe;
|
|
735
736
|
} & ParsedSubscribeInstruction<TProgram>) | ({
|
|
736
737
|
instructionType: SubscriptionsInstruction.CancelSubscription;
|
|
737
|
-
} & ParsedCancelSubscriptionInstruction<TProgram>)
|
|
738
|
+
} & ParsedCancelSubscriptionInstruction<TProgram>) | ({
|
|
739
|
+
instructionType: SubscriptionsInstruction.ResumeSubscription;
|
|
740
|
+
} & ParsedResumeSubscriptionInstruction<TProgram>);
|
|
738
741
|
declare function parseSubscriptionsInstruction<TProgram extends string>(instruction: Instruction<TProgram> & InstructionWithData<ReadonlyUint8Array>): ParsedSubscriptionsInstruction<TProgram>;
|
|
739
742
|
type SubscriptionsPlugin$1 = {
|
|
740
743
|
accounts: SubscriptionsPluginAccounts;
|
|
@@ -763,6 +766,7 @@ type SubscriptionsPluginInstructions$1 = {
|
|
|
763
766
|
transferSubscription: (input: TransferSubscriptionInput$1) => ReturnType<typeof getTransferSubscriptionInstruction> & SelfPlanAndSendFunctions;
|
|
764
767
|
subscribe: (input: SubscribeAsyncInput) => ReturnType<typeof getSubscribeInstructionAsync> & SelfPlanAndSendFunctions;
|
|
765
768
|
cancelSubscription: (input: CancelSubscriptionAsyncInput) => ReturnType<typeof getCancelSubscriptionInstructionAsync> & SelfPlanAndSendFunctions;
|
|
769
|
+
resumeSubscription: (input: ResumeSubscriptionAsyncInput) => ReturnType<typeof getResumeSubscriptionInstructionAsync> & SelfPlanAndSendFunctions;
|
|
766
770
|
};
|
|
767
771
|
type SubscriptionsPluginPdas = {
|
|
768
772
|
fixedDelegation: typeof findFixedDelegationPda;
|
|
@@ -1199,6 +1203,79 @@ type ParsedInitSubscriptionAuthorityInstruction<TProgram extends string = typeof
|
|
|
1199
1203
|
};
|
|
1200
1204
|
declare function parseInitSubscriptionAuthorityInstruction<TProgram extends string, TAccountMetas extends readonly AccountMeta[]>(instruction: Instruction<TProgram> & InstructionWithAccounts<TAccountMetas> & InstructionWithData<ReadonlyUint8Array>): ParsedInitSubscriptionAuthorityInstruction<TProgram, TAccountMetas>;
|
|
1201
1205
|
|
|
1206
|
+
/**
|
|
1207
|
+
* This code was AUTOGENERATED using the Codama library.
|
|
1208
|
+
* Please DO NOT EDIT THIS FILE, instead use visitors
|
|
1209
|
+
* to add features, then rerun Codama to update it.
|
|
1210
|
+
*
|
|
1211
|
+
* @see https://github.com/codama-idl/codama
|
|
1212
|
+
*/
|
|
1213
|
+
|
|
1214
|
+
declare const RESUME_SUBSCRIPTION_DISCRIMINATOR = 13;
|
|
1215
|
+
declare function getResumeSubscriptionDiscriminatorBytes(): ReadonlyUint8Array;
|
|
1216
|
+
type ResumeSubscriptionInstruction<TProgram extends string = typeof SUBSCRIPTIONS_PROGRAM_ADDRESS, TAccountSubscriber extends string | AccountMeta<string> = string, TAccountPlanPda extends string | AccountMeta<string> = string, TAccountSubscriptionPda extends string | AccountMeta<string> = string, TAccountEventAuthority extends string | AccountMeta<string> = '3Hnj4BYoDgtpBuqXfiy7Y8cNa3jXaNd4oqgSXBzkMcH7', TAccountSelfProgram extends string | AccountMeta<string> = 'De1egAFMkMWZSN5rYXRj9CAdheBamobVNubTsi9avR44', TRemainingAccounts extends readonly AccountMeta<string>[] = []> = Instruction<TProgram> & InstructionWithData<ReadonlyUint8Array> & InstructionWithAccounts<[
|
|
1217
|
+
TAccountSubscriber extends string ? ReadonlySignerAccount<TAccountSubscriber> & AccountSignerMeta<TAccountSubscriber> : TAccountSubscriber,
|
|
1218
|
+
TAccountPlanPda extends string ? ReadonlyAccount<TAccountPlanPda> : TAccountPlanPda,
|
|
1219
|
+
TAccountSubscriptionPda extends string ? WritableAccount<TAccountSubscriptionPda> : TAccountSubscriptionPda,
|
|
1220
|
+
TAccountEventAuthority extends string ? ReadonlyAccount<TAccountEventAuthority> : TAccountEventAuthority,
|
|
1221
|
+
TAccountSelfProgram extends string ? ReadonlyAccount<TAccountSelfProgram> : TAccountSelfProgram,
|
|
1222
|
+
...TRemainingAccounts
|
|
1223
|
+
]>;
|
|
1224
|
+
type ResumeSubscriptionInstructionData = {
|
|
1225
|
+
discriminator: number;
|
|
1226
|
+
};
|
|
1227
|
+
type ResumeSubscriptionInstructionDataArgs = {};
|
|
1228
|
+
declare function getResumeSubscriptionInstructionDataEncoder(): FixedSizeEncoder<ResumeSubscriptionInstructionDataArgs>;
|
|
1229
|
+
declare function getResumeSubscriptionInstructionDataDecoder(): FixedSizeDecoder<ResumeSubscriptionInstructionData>;
|
|
1230
|
+
declare function getResumeSubscriptionInstructionDataCodec(): FixedSizeCodec<ResumeSubscriptionInstructionDataArgs, ResumeSubscriptionInstructionData>;
|
|
1231
|
+
type ResumeSubscriptionAsyncInput<TAccountSubscriber extends string = string, TAccountPlanPda extends string = string, TAccountSubscriptionPda extends string = string, TAccountEventAuthority extends string = string, TAccountSelfProgram extends string = string> = {
|
|
1232
|
+
/** The subscriber resuming the subscription */
|
|
1233
|
+
subscriber: TransactionSigner<TAccountSubscriber>;
|
|
1234
|
+
/** The plan PDA for the subscription */
|
|
1235
|
+
planPda: Address<TAccountPlanPda>;
|
|
1236
|
+
/** The subscription PDA being resumed */
|
|
1237
|
+
subscriptionPda?: Address<TAccountSubscriptionPda>;
|
|
1238
|
+
/** The event authority PDA */
|
|
1239
|
+
eventAuthority?: Address<TAccountEventAuthority>;
|
|
1240
|
+
/** This program (for self-CPI) */
|
|
1241
|
+
selfProgram?: Address<TAccountSelfProgram>;
|
|
1242
|
+
};
|
|
1243
|
+
declare function getResumeSubscriptionInstructionAsync<TAccountSubscriber extends string, TAccountPlanPda extends string, TAccountSubscriptionPda extends string, TAccountEventAuthority extends string, TAccountSelfProgram extends string, TProgramAddress extends Address = typeof SUBSCRIPTIONS_PROGRAM_ADDRESS>(input: ResumeSubscriptionAsyncInput<TAccountSubscriber, TAccountPlanPda, TAccountSubscriptionPda, TAccountEventAuthority, TAccountSelfProgram>, config?: {
|
|
1244
|
+
programAddress?: TProgramAddress;
|
|
1245
|
+
}): Promise<ResumeSubscriptionInstruction<TProgramAddress, TAccountSubscriber, TAccountPlanPda, TAccountSubscriptionPda, TAccountEventAuthority, TAccountSelfProgram>>;
|
|
1246
|
+
type ResumeSubscriptionInput$1<TAccountSubscriber extends string = string, TAccountPlanPda extends string = string, TAccountSubscriptionPda extends string = string, TAccountEventAuthority extends string = string, TAccountSelfProgram extends string = string> = {
|
|
1247
|
+
/** The subscriber resuming the subscription */
|
|
1248
|
+
subscriber: TransactionSigner<TAccountSubscriber>;
|
|
1249
|
+
/** The plan PDA for the subscription */
|
|
1250
|
+
planPda: Address<TAccountPlanPda>;
|
|
1251
|
+
/** The subscription PDA being resumed */
|
|
1252
|
+
subscriptionPda: Address<TAccountSubscriptionPda>;
|
|
1253
|
+
/** The event authority PDA */
|
|
1254
|
+
eventAuthority?: Address<TAccountEventAuthority>;
|
|
1255
|
+
/** This program (for self-CPI) */
|
|
1256
|
+
selfProgram?: Address<TAccountSelfProgram>;
|
|
1257
|
+
};
|
|
1258
|
+
declare function getResumeSubscriptionInstruction<TAccountSubscriber extends string, TAccountPlanPda extends string, TAccountSubscriptionPda extends string, TAccountEventAuthority extends string, TAccountSelfProgram extends string, TProgramAddress extends Address = typeof SUBSCRIPTIONS_PROGRAM_ADDRESS>(input: ResumeSubscriptionInput$1<TAccountSubscriber, TAccountPlanPda, TAccountSubscriptionPda, TAccountEventAuthority, TAccountSelfProgram>, config?: {
|
|
1259
|
+
programAddress?: TProgramAddress;
|
|
1260
|
+
}): ResumeSubscriptionInstruction<TProgramAddress, TAccountSubscriber, TAccountPlanPda, TAccountSubscriptionPda, TAccountEventAuthority, TAccountSelfProgram>;
|
|
1261
|
+
type ParsedResumeSubscriptionInstruction<TProgram extends string = typeof SUBSCRIPTIONS_PROGRAM_ADDRESS, TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[]> = {
|
|
1262
|
+
programAddress: Address<TProgram>;
|
|
1263
|
+
accounts: {
|
|
1264
|
+
/** The subscriber resuming the subscription */
|
|
1265
|
+
subscriber: TAccountMetas[0];
|
|
1266
|
+
/** The plan PDA for the subscription */
|
|
1267
|
+
planPda: TAccountMetas[1];
|
|
1268
|
+
/** The subscription PDA being resumed */
|
|
1269
|
+
subscriptionPda: TAccountMetas[2];
|
|
1270
|
+
/** The event authority PDA */
|
|
1271
|
+
eventAuthority: TAccountMetas[3];
|
|
1272
|
+
/** This program (for self-CPI) */
|
|
1273
|
+
selfProgram: TAccountMetas[4];
|
|
1274
|
+
};
|
|
1275
|
+
data: ResumeSubscriptionInstructionData;
|
|
1276
|
+
};
|
|
1277
|
+
declare function parseResumeSubscriptionInstruction<TProgram extends string, TAccountMetas extends readonly AccountMeta[]>(instruction: Instruction<TProgram> & InstructionWithAccounts<TAccountMetas> & InstructionWithData<ReadonlyUint8Array>): ParsedResumeSubscriptionInstruction<TProgram, TAccountMetas>;
|
|
1278
|
+
|
|
1202
1279
|
/**
|
|
1203
1280
|
* This code was AUTOGENERATED using the Codama library.
|
|
1204
1281
|
* Please DO NOT EDIT THIS FILE, instead use visitors
|
|
@@ -1742,50 +1819,6 @@ declare const METADATA_URI_LEN = 128;
|
|
|
1742
1819
|
/** On-chain delegation variant identifier (matches the `kind` tag in the `Delegation` union). */
|
|
1743
1820
|
type DelegationKindId = 'fixed' | 'recurring' | 'subscription';
|
|
1744
1821
|
|
|
1745
|
-
/**
|
|
1746
|
-
* `subscriptionsProgram()` — `@solana/kit` plugin that wraps the Codama-generated
|
|
1747
|
-
* `subscriptionsProgram()` plugin with higher-level instruction overlays
|
|
1748
|
-
* (PDA derivation, sponsor `payer` trailing accounts, ATA derivation, validators)
|
|
1749
|
-
* and a `queries` namespace for common account fetches.
|
|
1750
|
-
*
|
|
1751
|
-
* Each overlay defaults its actor field (`owner` / `delegator` / `subscriber`
|
|
1752
|
-
* / `authority` / `delegatee` / `caller`) to `client.identity`, and any
|
|
1753
|
-
* `payer` slot to `client.payer`. Sponsor flows install separate signers via
|
|
1754
|
-
* `payer()` + `identity()` instead of `signer()`.
|
|
1755
|
-
*
|
|
1756
|
-
* @example Same signer for everything
|
|
1757
|
-
* ```ts
|
|
1758
|
-
* import { createClient } from '@solana/kit';
|
|
1759
|
-
* import { signer } from '@solana/kit-plugin-signer';
|
|
1760
|
-
* import { solanaLocalRpc } from '@solana/kit-plugin-rpc';
|
|
1761
|
-
* import { subscriptionsProgram } from '@solana/subscriptions';
|
|
1762
|
-
*
|
|
1763
|
-
* const client = createClient()
|
|
1764
|
-
* .use(signer(mySigner))
|
|
1765
|
-
* .use(solanaLocalRpc())
|
|
1766
|
-
* .use(subscriptionsProgram());
|
|
1767
|
-
*
|
|
1768
|
-
* await client.subscriptions.instructions
|
|
1769
|
-
* .createPlan({ planId, mint, amount, periodHours, endTs, destinations, pullers, metadataUri })
|
|
1770
|
-
* .sendTransaction();
|
|
1771
|
-
* ```
|
|
1772
|
-
*
|
|
1773
|
-
* @example Sponsor pays fees + rent on behalf of the user
|
|
1774
|
-
* ```ts
|
|
1775
|
-
* import { payer, identity } from '@solana/kit-plugin-signer';
|
|
1776
|
-
*
|
|
1777
|
-
* const client = createClient()
|
|
1778
|
-
* .use(payer(sponsorSigner)) // pays gas + rent
|
|
1779
|
-
* .use(identity(userSigner)) // signs as delegator
|
|
1780
|
-
* .use(solanaLocalRpc())
|
|
1781
|
-
* .use(subscriptionsProgram());
|
|
1782
|
-
*
|
|
1783
|
-
* await client.subscriptions.instructions
|
|
1784
|
-
* .createFixedDelegation({ delegatee, nonce, amount, expiryTs, tokenMint })
|
|
1785
|
-
* .sendTransaction();
|
|
1786
|
-
* ```
|
|
1787
|
-
*/
|
|
1788
|
-
|
|
1789
1822
|
type WithProgramAddress = {
|
|
1790
1823
|
programAddress?: Address;
|
|
1791
1824
|
};
|
|
@@ -1901,6 +1934,11 @@ type CancelSubscriptionInput = WithProgramAddress & {
|
|
|
1901
1934
|
subscriber: TransactionSigner;
|
|
1902
1935
|
subscriptionPda?: Address;
|
|
1903
1936
|
};
|
|
1937
|
+
type ResumeSubscriptionInput = WithProgramAddress & {
|
|
1938
|
+
planPda: Address;
|
|
1939
|
+
subscriber: TransactionSigner;
|
|
1940
|
+
subscriptionPda?: Address;
|
|
1941
|
+
};
|
|
1904
1942
|
declare function getInitSubscriptionAuthorityOverlayInstructionAsync(input: InitSubscriptionAuthorityInput): Promise<Instruction>;
|
|
1905
1943
|
declare function getCloseSubscriptionAuthorityOverlayInstructionAsync(input: CloseSubscriptionAuthorityInput): Promise<Instruction>;
|
|
1906
1944
|
declare function getCreateFixedDelegationOverlayInstructionAsync(input: CreateFixedDelegationInput): Promise<Instruction>;
|
|
@@ -1920,6 +1958,7 @@ declare function getUpdatePlanOverlayInstruction(input: UpdatePlanInput): Instru
|
|
|
1920
1958
|
declare function getDeletePlanOverlayInstruction(input: DeletePlanInput): Instruction;
|
|
1921
1959
|
declare function getSubscribeOverlayInstructionAsync(input: SubscribeInput): Promise<Instruction>;
|
|
1922
1960
|
declare function getCancelSubscriptionOverlayInstructionAsync(input: CancelSubscriptionInput): Promise<Instruction>;
|
|
1961
|
+
declare function getResumeSubscriptionOverlayInstructionAsync(input: ResumeSubscriptionInput): Promise<Instruction>;
|
|
1923
1962
|
type SubscriptionsPluginRequirements = ClientWithIdentity & ClientWithPayer & ClientWithRpc<GetProgramAccountsApi> & SubscriptionsPluginRequirements$1;
|
|
1924
1963
|
type Self<T> = SelfPlanAndSendFunctions & T;
|
|
1925
1964
|
type SubscriptionsPluginInstructions = {
|
|
@@ -1930,6 +1969,7 @@ type SubscriptionsPluginInstructions = {
|
|
|
1930
1969
|
createRecurringDelegation: (input: MakeOptional<CreateRecurringDelegationInput, 'delegator' | 'payer'>) => Self<Promise<Instruction>>;
|
|
1931
1970
|
deletePlan: (input: MakeOptional<DeletePlanInput, 'owner'>) => Self<Instruction>;
|
|
1932
1971
|
initSubscriptionAuthority: (input: MakeOptional<InitSubscriptionAuthorityInput, 'owner' | 'payer'>) => Self<Promise<Instruction>>;
|
|
1972
|
+
resumeSubscription: (input: MakeOptional<ResumeSubscriptionInput, 'subscriber'>) => Self<Promise<Instruction>>;
|
|
1933
1973
|
revokeDelegation: (input: MakeOptional<RevokeDelegationInput, 'authority'>) => Self<Instruction>;
|
|
1934
1974
|
revokeSubscription: (input: MakeOptional<RevokeSubscriptionInput, 'authority'>) => Self<Instruction>;
|
|
1935
1975
|
subscribe: (input: MakeOptional<SubscribeInput, 'payer' | 'subscriber'>) => Self<Promise<Instruction>>;
|
|
@@ -1963,7 +2003,12 @@ type SubscriptionsPlugin = Omit<SubscriptionsPlugin$1, 'instructions'> & {
|
|
|
1963
2003
|
queries: SubscriptionsPluginQueries;
|
|
1964
2004
|
};
|
|
1965
2005
|
declare function subscriptionsProgram(): <T extends SubscriptionsPluginRequirements>(client: T) => Omit<T, "subscriptions"> & {
|
|
1966
|
-
subscriptions:
|
|
2006
|
+
subscriptions: {
|
|
2007
|
+
instructions: SubscriptionsPluginInstructions;
|
|
2008
|
+
queries: SubscriptionsPluginQueries;
|
|
2009
|
+
accounts: SubscriptionsPluginAccounts;
|
|
2010
|
+
pdas: SubscriptionsPluginPdas;
|
|
2011
|
+
};
|
|
1967
2012
|
};
|
|
1968
2013
|
|
|
1969
2014
|
/** Client-side validation failure (e.g. max destinations exceeded). */
|
|
@@ -1971,4 +2016,4 @@ declare class ValidationError extends Error {
|
|
|
1971
2016
|
constructor(message: string);
|
|
1972
2017
|
}
|
|
1973
2018
|
|
|
1974
|
-
export { AccountDiscriminator, type AccountDiscriminatorArgs, CANCEL_SUBSCRIPTION_DISCRIMINATOR, CLOSE_SUBSCRIPTION_AUTHORITY_DISCRIMINATOR, CREATE_FIXED_DELEGATION_DISCRIMINATOR, CREATE_PLAN_DISCRIMINATOR, CREATE_RECURRING_DELEGATION_DISCRIMINATOR, CURRENT_PROGRAM_VERSION, type CancelSubscriptionAsyncInput, type CancelSubscriptionInput, type CancelSubscriptionInstruction, type CancelSubscriptionInstructionData, type CancelSubscriptionInstructionDataArgs, type CloseSubscriptionAuthorityInput, type CloseSubscriptionAuthorityInstruction, type CloseSubscriptionAuthorityInstructionData, type CloseSubscriptionAuthorityInstructionDataArgs, type CreateFixedDelegationData, type CreateFixedDelegationDataArgs, type CreateFixedDelegationInput, type CreateFixedDelegationInstruction, type CreateFixedDelegationInstructionData, type CreateFixedDelegationInstructionDataArgs, type CreatePlanInput, type CreatePlanInstruction, type CreatePlanInstructionData, type CreatePlanInstructionDataArgs, type CreateRecurringDelegationData, type CreateRecurringDelegationDataArgs, type CreateRecurringDelegationInput, type CreateRecurringDelegationInstruction, type CreateRecurringDelegationInstructionData, type CreateRecurringDelegationInstructionDataArgs, DELEGATEE_OFFSET, DELEGATION_SEED, DELEGATOR_OFFSET, DELETE_PLAN_DISCRIMINATOR, DISCRIMINATOR_OFFSET, type Delegation, type DelegationKindId, type DeletePlanInput, type DeletePlanInstruction, type DeletePlanInstructionData, type DeletePlanInstructionDataArgs, EVENT_AUTHORITY_SEED, type EventAuthority, type EventAuthorityArgs, type FixedDelegation, type FixedDelegationArgs, type FixedDelegationSeeds, type Header, type HeaderArgs, INIT_SUBSCRIPTION_AUTHORITY_DISCRIMINATOR, type InitSubscriptionAuthorityAsyncInput, type InitSubscriptionAuthorityInput, type InitSubscriptionAuthorityInstruction, type InitSubscriptionAuthorityInstructionData, type InitSubscriptionAuthorityInstructionDataArgs, MAX_PLAN_DESTINATIONS, MAX_PLAN_PULLERS, METADATA_URI_LEN, PLAN_OWNER_OFFSET, PLAN_SEED, PLAN_SIZE, PROGRAM_ID, type ParsedCancelSubscriptionInstruction, type ParsedCloseSubscriptionAuthorityInstruction, type ParsedCreateFixedDelegationInstruction, type ParsedCreatePlanInstruction, type ParsedCreateRecurringDelegationInstruction, type ParsedDeletePlanInstruction, type ParsedInitSubscriptionAuthorityInstruction, type ParsedRevokeDelegationInstruction, type ParsedSubscribeInstruction, type ParsedSubscriptionsInstruction, type ParsedTransferFixedInstruction, type ParsedTransferRecurringInstruction, type ParsedTransferSubscriptionInstruction, type ParsedUpdatePlanInstruction, type Plan, type PlanArgs, type PlanData, type PlanDataArgs, type PlanSeeds, PlanStatus, type PlanStatusArgs, type PlanTerms, type PlanTermsArgs, type PlanWithAddress, REVOKE_DELEGATION_DISCRIMINATOR, type RawProgramAccount, type RecurringDelegation, type RecurringDelegationArgs, type RecurringDelegationSeeds, type RevokeDelegationInput, type RevokeDelegationInstruction, type RevokeDelegationInstructionData, type RevokeDelegationInstructionDataArgs, type RevokeSubscriptionInput, SUBSCRIBE_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__ACCOUNT_NOT_WRITABLE, SUBSCRIPTIONS_ERROR__ALREADY_SUBSCRIBED, SUBSCRIPTIONS_ERROR__AMOUNT_EXCEEDS_LIMIT, SUBSCRIPTIONS_ERROR__AMOUNT_EXCEEDS_PERIOD_LIMIT, SUBSCRIPTIONS_ERROR__ARITHMETIC_OVERFLOW, SUBSCRIPTIONS_ERROR__ARITHMETIC_UNDERFLOW, SUBSCRIPTIONS_ERROR__ATA_OWNER_MISMATCH, SUBSCRIPTIONS_ERROR__DELEGATION_ALREADY_EXISTS, SUBSCRIPTIONS_ERROR__DELEGATION_EXPIRED, SUBSCRIPTIONS_ERROR__DELEGATION_NOT_STARTED, SUBSCRIPTIONS_ERROR__DELEGATION_VERSION_MISMATCH, SUBSCRIPTIONS_ERROR__FIXED_DELEGATION_AMOUNT_ZERO, SUBSCRIPTIONS_ERROR__FIXED_DELEGATION_EXPIRY_IN_PAST, SUBSCRIPTIONS_ERROR__INVALID_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_ACCOUNT_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__INVALID_ADDRESS, SUBSCRIPTIONS_ERROR__INVALID_AMOUNT, SUBSCRIPTIONS_ERROR__INVALID_ASSOCIATED_TOKEN_ACCOUNT_DERIVED_ADDRESS, SUBSCRIPTIONS_ERROR__INVALID_DELEGATE_PDA, SUBSCRIPTIONS_ERROR__INVALID_END_TS, SUBSCRIPTIONS_ERROR__INVALID_ESCROW_PDA, SUBSCRIPTIONS_ERROR__INVALID_EVENT_AUTHORITY, SUBSCRIPTIONS_ERROR__INVALID_EVENT_DATA, SUBSCRIPTIONS_ERROR__INVALID_EVENT_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__INVALID_EVENT_TAG, SUBSCRIPTIONS_ERROR__INVALID_HEADER_DATA, SUBSCRIPTIONS_ERROR__INVALID_INSTRUCTION, SUBSCRIPTIONS_ERROR__INVALID_INSTRUCTION_DATA, SUBSCRIPTIONS_ERROR__INVALID_NUM_DESTINATIONS, SUBSCRIPTIONS_ERROR__INVALID_PAYER_DATA, SUBSCRIPTIONS_ERROR__INVALID_PERIOD_LENGTH, SUBSCRIPTIONS_ERROR__INVALID_PLAN_PDA, SUBSCRIPTIONS_ERROR__INVALID_PLAN_STATUS, SUBSCRIPTIONS_ERROR__INVALID_SUBSCRIPTION_AUTHORITY_PDA, SUBSCRIPTIONS_ERROR__INVALID_SUBSCRIPTION_PDA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN2022_MINT_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN2022_TOKEN_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_PROGRAM, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_SPL_MINT_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_SPL_TOKEN_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__MIGRATION_REQUIRED, SUBSCRIPTIONS_ERROR__MINT_HAS_CONFIDENTIAL_TRANSFER, SUBSCRIPTIONS_ERROR__MINT_HAS_MINT_CLOSE_AUTHORITY, SUBSCRIPTIONS_ERROR__MINT_HAS_NON_TRANSFERABLE, SUBSCRIPTIONS_ERROR__MINT_HAS_PAUSABLE, SUBSCRIPTIONS_ERROR__MINT_HAS_PERMANENT_DELEGATE, SUBSCRIPTIONS_ERROR__MINT_HAS_TRANSFER_FEE, SUBSCRIPTIONS_ERROR__MINT_HAS_TRANSFER_HOOK, SUBSCRIPTIONS_ERROR__MINT_MISMATCH, SUBSCRIPTIONS_ERROR__NOT_ENOUGH_ACCOUNT_KEYS, SUBSCRIPTIONS_ERROR__NOT_PLAN_OWNER, SUBSCRIPTIONS_ERROR__NOT_SIGNER, SUBSCRIPTIONS_ERROR__NOT_SYSTEM_PROGRAM, SUBSCRIPTIONS_ERROR__PERIOD_NOT_ELAPSED, SUBSCRIPTIONS_ERROR__PLAN_ALREADY_EXISTS, SUBSCRIPTIONS_ERROR__PLAN_CLOSED, SUBSCRIPTIONS_ERROR__PLAN_EXPIRED, SUBSCRIPTIONS_ERROR__PLAN_IMMUTABLE_AFTER_SUNSET, SUBSCRIPTIONS_ERROR__PLAN_NOT_EXPIRED, SUBSCRIPTIONS_ERROR__PLAN_SUNSET, SUBSCRIPTIONS_ERROR__PLAN_TERMS_MISMATCH, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_AMOUNT_ZERO, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_START_TIME_GREATER_THAN_EXPIRY, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_START_TIME_IN_PAST, SUBSCRIPTIONS_ERROR__STALE_SUBSCRIPTION_AUTHORITY, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_ALREADY_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_NOT_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_PLAN_MISMATCH, SUBSCRIPTIONS_ERROR__SUNSET_REQUIRES_END_TS, SUBSCRIPTIONS_ERROR__UNAUTHORIZED, SUBSCRIPTIONS_ERROR__UNAUTHORIZED_DESTINATION, SUBSCRIPTIONS_PROGRAM_ADDRESS, SUBSCRIPTION_AUTHORITY_SEED, SUBSCRIPTION_SEED, SUBSCRIPTION_SIZE, type SubscribeAsyncInput, type SubscribeData, type SubscribeDataArgs, type SubscribeInput, type SubscribeInstruction, type SubscribeInstructionData, type SubscribeInstructionDataArgs, type SubscriptionAuthority, type SubscriptionAuthorityArgs, type SubscriptionAuthoritySeeds, type SubscriptionDelegation, type SubscriptionDelegationArgs, type SubscriptionDelegationSeeds, SubscriptionsAccount, type SubscriptionsError, SubscriptionsInstruction, type SubscriptionsPlugin, type SubscriptionsPluginAccounts, type SubscriptionsPluginInstructions, type SubscriptionsPluginPdas, type SubscriptionsPluginQueries, type SubscriptionsPluginRequirements, TRANSFER_FIXED_DISCRIMINATOR, TRANSFER_RECURRING_DISCRIMINATOR, TRANSFER_SUBSCRIPTION_DISCRIMINATOR, type TransferData, type TransferDataArgs, type TransferDelegationInput, type TransferFixedInput, type TransferFixedInstruction, type TransferFixedInstructionData, type TransferFixedInstructionDataArgs, type TransferRecurringInput, type TransferRecurringInstruction, type TransferRecurringInstructionData, type TransferRecurringInstructionDataArgs, type TransferSubscriptionInput, type TransferSubscriptionInstruction, type TransferSubscriptionInstructionData, type TransferSubscriptionInstructionDataArgs, U64_BYTE_SIZE, UPDATE_PLAN_DISCRIMINATOR, type UpdatePlanData, type UpdatePlanDataArgs, type UpdatePlanInput, type UpdatePlanInstruction, type UpdatePlanInstructionData, type UpdatePlanInstructionDataArgs, ValidationError, ZERO_ADDRESS, decodeDelegationAccount, decodeEventAuthority, decodeFixedDelegation, decodePlan, decodeRecurringDelegation, decodeSubscriptionAuthority, decodeSubscriptionDelegation, fetchAllEventAuthority, fetchAllFixedDelegation, fetchAllMaybeEventAuthority, fetchAllMaybeFixedDelegation, fetchAllMaybePlan, fetchAllMaybeRecurringDelegation, fetchAllMaybeSubscriptionAuthority, fetchAllMaybeSubscriptionDelegation, fetchAllPlan, fetchAllRecurringDelegation, fetchAllSubscriptionAuthority, fetchAllSubscriptionDelegation, fetchDelegationsByDelegatee, fetchDelegationsByDelegator, fetchEventAuthority, fetchEventAuthorityFromSeeds, fetchFixedDelegation, fetchFixedDelegationFromSeeds, fetchMaybeEventAuthority, fetchMaybeEventAuthorityFromSeeds, fetchMaybeFixedDelegation, fetchMaybeFixedDelegationFromSeeds, fetchMaybePlan, fetchMaybePlanFromSeeds, fetchMaybeRecurringDelegation, fetchMaybeRecurringDelegationFromSeeds, fetchMaybeSubscriptionAuthority, fetchMaybeSubscriptionAuthorityFromSeeds, fetchMaybeSubscriptionDelegation, fetchMaybeSubscriptionDelegationFromSeeds, fetchPlan, fetchPlanFromSeeds, fetchPlansForOwner, fetchRecurringDelegation, fetchRecurringDelegationFromSeeds, fetchSubscriptionAuthority, fetchSubscriptionAuthorityFromSeeds, fetchSubscriptionDelegation, fetchSubscriptionDelegationFromSeeds, fetchSubscriptionsForUser, findEventAuthorityPda, findFixedDelegationPda, findPlanPda, findRecurringDelegationPda, findSubscriptionAuthorityPda, findSubscriptionDelegationPda, getAccountDiscriminatorCodec, getAccountDiscriminatorDecoder, getAccountDiscriminatorEncoder, getCancelSubscriptionDiscriminatorBytes, getCancelSubscriptionInstruction, getCancelSubscriptionInstructionAsync, getCancelSubscriptionInstructionDataCodec, getCancelSubscriptionInstructionDataDecoder, getCancelSubscriptionInstructionDataEncoder, getCancelSubscriptionOverlayInstructionAsync, getCloseSubscriptionAuthorityDiscriminatorBytes, getCloseSubscriptionAuthorityInstruction, getCloseSubscriptionAuthorityInstructionDataCodec, getCloseSubscriptionAuthorityInstructionDataDecoder, getCloseSubscriptionAuthorityInstructionDataEncoder, getCloseSubscriptionAuthorityOverlayInstructionAsync, getCreateFixedDelegationDataCodec, getCreateFixedDelegationDataDecoder, getCreateFixedDelegationDataEncoder, getCreateFixedDelegationDiscriminatorBytes, getCreateFixedDelegationInstruction, getCreateFixedDelegationInstructionDataCodec, getCreateFixedDelegationInstructionDataDecoder, getCreateFixedDelegationInstructionDataEncoder, getCreateFixedDelegationOverlayInstructionAsync, getCreatePlanDiscriminatorBytes, getCreatePlanInstruction, getCreatePlanInstructionDataCodec, getCreatePlanInstructionDataDecoder, getCreatePlanInstructionDataEncoder, getCreatePlanOverlayInstructionAsync, getCreateRecurringDelegationDataCodec, getCreateRecurringDelegationDataDecoder, getCreateRecurringDelegationDataEncoder, getCreateRecurringDelegationDiscriminatorBytes, getCreateRecurringDelegationInstruction, getCreateRecurringDelegationInstructionDataCodec, getCreateRecurringDelegationInstructionDataDecoder, getCreateRecurringDelegationInstructionDataEncoder, getCreateRecurringDelegationOverlayInstructionAsync, getDeletePlanDiscriminatorBytes, getDeletePlanInstruction, getDeletePlanInstructionDataCodec, getDeletePlanInstructionDataDecoder, getDeletePlanInstructionDataEncoder, getDeletePlanOverlayInstruction, getEventAuthorityCodec, getEventAuthorityDecoder, getEventAuthorityEncoder, getFixedDelegationCodec, getFixedDelegationDecoder, getFixedDelegationEncoder, getHeaderCodec, getHeaderDecoder, getHeaderEncoder, getInitSubscriptionAuthorityDiscriminatorBytes, getInitSubscriptionAuthorityInstruction, getInitSubscriptionAuthorityInstructionAsync, getInitSubscriptionAuthorityInstructionDataCodec, getInitSubscriptionAuthorityInstructionDataDecoder, getInitSubscriptionAuthorityInstructionDataEncoder, getInitSubscriptionAuthorityOverlayInstructionAsync, getPlanCodec, getPlanDataCodec, getPlanDataDecoder, getPlanDataEncoder, getPlanDecoder, getPlanEncoder, getPlanStatusCodec, getPlanStatusDecoder, getPlanStatusEncoder, getPlanTermsCodec, getPlanTermsDecoder, getPlanTermsEncoder, getRecurringDelegationCodec, getRecurringDelegationDecoder, getRecurringDelegationEncoder, getRevokeDelegationDiscriminatorBytes, getRevokeDelegationInstruction, getRevokeDelegationInstructionDataCodec, getRevokeDelegationInstructionDataDecoder, getRevokeDelegationInstructionDataEncoder, getRevokeDelegationOverlayInstruction, getRevokeSubscriptionOverlayInstruction, getSubscribeDataCodec, getSubscribeDataDecoder, getSubscribeDataEncoder, getSubscribeDiscriminatorBytes, getSubscribeInstruction, getSubscribeInstructionAsync, getSubscribeInstructionDataCodec, getSubscribeInstructionDataDecoder, getSubscribeInstructionDataEncoder, getSubscribeOverlayInstructionAsync, getSubscriptionAuthorityCodec, getSubscriptionAuthorityDecoder, getSubscriptionAuthorityEncoder, getSubscriptionDelegationCodec, getSubscriptionDelegationDecoder, getSubscriptionDelegationEncoder, getSubscriptionsErrorMessage, getTransferDataCodec, getTransferDataDecoder, getTransferDataEncoder, getTransferFixedDiscriminatorBytes, getTransferFixedInstruction, getTransferFixedInstructionDataCodec, getTransferFixedInstructionDataDecoder, getTransferFixedInstructionDataEncoder, getTransferFixedOverlayInstructionAsync, getTransferRecurringDiscriminatorBytes, getTransferRecurringInstruction, getTransferRecurringInstructionDataCodec, getTransferRecurringInstructionDataDecoder, getTransferRecurringInstructionDataEncoder, getTransferRecurringOverlayInstructionAsync, getTransferSubscriptionDiscriminatorBytes, getTransferSubscriptionInstruction, getTransferSubscriptionInstructionDataCodec, getTransferSubscriptionInstructionDataDecoder, getTransferSubscriptionInstructionDataEncoder, getTransferSubscriptionOverlayInstructionAsync, getUpdatePlanDataCodec, getUpdatePlanDataDecoder, getUpdatePlanDataEncoder, getUpdatePlanDiscriminatorBytes, getUpdatePlanInstruction, getUpdatePlanInstructionDataCodec, getUpdatePlanInstructionDataDecoder, getUpdatePlanInstructionDataEncoder, getUpdatePlanOverlayInstruction, identifySubscriptionsInstruction, isSubscriptionsError, parseCancelSubscriptionInstruction, parseCloseSubscriptionAuthorityInstruction, parseCreateFixedDelegationInstruction, parseCreatePlanInstruction, parseCreateRecurringDelegationInstruction, parseDeletePlanInstruction, parseInitSubscriptionAuthorityInstruction, parseRevokeDelegationInstruction, parseSubscribeInstruction, parseSubscriptionsInstruction, parseTransferFixedInstruction, parseTransferRecurringInstruction, parseTransferSubscriptionInstruction, parseUpdatePlanInstruction, subscriptionsProgram, toEncodedAccount };
|
|
2019
|
+
export { AccountDiscriminator, type AccountDiscriminatorArgs, CANCEL_SUBSCRIPTION_DISCRIMINATOR, CLOSE_SUBSCRIPTION_AUTHORITY_DISCRIMINATOR, CREATE_FIXED_DELEGATION_DISCRIMINATOR, CREATE_PLAN_DISCRIMINATOR, CREATE_RECURRING_DELEGATION_DISCRIMINATOR, CURRENT_PROGRAM_VERSION, type CancelSubscriptionAsyncInput, type CancelSubscriptionInput, type CancelSubscriptionInstruction, type CancelSubscriptionInstructionData, type CancelSubscriptionInstructionDataArgs, type CloseSubscriptionAuthorityInput, type CloseSubscriptionAuthorityInstruction, type CloseSubscriptionAuthorityInstructionData, type CloseSubscriptionAuthorityInstructionDataArgs, type CreateFixedDelegationData, type CreateFixedDelegationDataArgs, type CreateFixedDelegationInput, type CreateFixedDelegationInstruction, type CreateFixedDelegationInstructionData, type CreateFixedDelegationInstructionDataArgs, type CreatePlanInput, type CreatePlanInstruction, type CreatePlanInstructionData, type CreatePlanInstructionDataArgs, type CreateRecurringDelegationData, type CreateRecurringDelegationDataArgs, type CreateRecurringDelegationInput, type CreateRecurringDelegationInstruction, type CreateRecurringDelegationInstructionData, type CreateRecurringDelegationInstructionDataArgs, DELEGATEE_OFFSET, DELEGATION_SEED, DELEGATOR_OFFSET, DELETE_PLAN_DISCRIMINATOR, DISCRIMINATOR_OFFSET, type Delegation, type DelegationKindId, type DeletePlanInput, type DeletePlanInstruction, type DeletePlanInstructionData, type DeletePlanInstructionDataArgs, EVENT_AUTHORITY_SEED, type EventAuthority, type EventAuthorityArgs, type FixedDelegation, type FixedDelegationArgs, type FixedDelegationSeeds, type Header, type HeaderArgs, INIT_SUBSCRIPTION_AUTHORITY_DISCRIMINATOR, type InitSubscriptionAuthorityAsyncInput, type InitSubscriptionAuthorityInput, type InitSubscriptionAuthorityInstruction, type InitSubscriptionAuthorityInstructionData, type InitSubscriptionAuthorityInstructionDataArgs, MAX_PLAN_DESTINATIONS, MAX_PLAN_PULLERS, METADATA_URI_LEN, PLAN_OWNER_OFFSET, PLAN_SEED, PLAN_SIZE, PROGRAM_ID, type ParsedCancelSubscriptionInstruction, type ParsedCloseSubscriptionAuthorityInstruction, type ParsedCreateFixedDelegationInstruction, type ParsedCreatePlanInstruction, type ParsedCreateRecurringDelegationInstruction, type ParsedDeletePlanInstruction, type ParsedInitSubscriptionAuthorityInstruction, type ParsedResumeSubscriptionInstruction, type ParsedRevokeDelegationInstruction, type ParsedSubscribeInstruction, type ParsedSubscriptionsInstruction, type ParsedTransferFixedInstruction, type ParsedTransferRecurringInstruction, type ParsedTransferSubscriptionInstruction, type ParsedUpdatePlanInstruction, type Plan, type PlanArgs, type PlanData, type PlanDataArgs, type PlanSeeds, PlanStatus, type PlanStatusArgs, type PlanTerms, type PlanTermsArgs, type PlanWithAddress, RESUME_SUBSCRIPTION_DISCRIMINATOR, REVOKE_DELEGATION_DISCRIMINATOR, type RawProgramAccount, type RecurringDelegation, type RecurringDelegationArgs, type RecurringDelegationSeeds, type ResumeSubscriptionAsyncInput, type ResumeSubscriptionInput, type ResumeSubscriptionInstruction, type ResumeSubscriptionInstructionData, type ResumeSubscriptionInstructionDataArgs, type RevokeDelegationInput, type RevokeDelegationInstruction, type RevokeDelegationInstructionData, type RevokeDelegationInstructionDataArgs, type RevokeSubscriptionInput, SUBSCRIBE_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__ACCOUNT_NOT_WRITABLE, SUBSCRIPTIONS_ERROR__ALREADY_SUBSCRIBED, SUBSCRIPTIONS_ERROR__AMOUNT_EXCEEDS_LIMIT, SUBSCRIPTIONS_ERROR__AMOUNT_EXCEEDS_PERIOD_LIMIT, SUBSCRIPTIONS_ERROR__ARITHMETIC_OVERFLOW, SUBSCRIPTIONS_ERROR__ARITHMETIC_UNDERFLOW, SUBSCRIPTIONS_ERROR__ATA_OWNER_MISMATCH, SUBSCRIPTIONS_ERROR__DELEGATION_ALREADY_EXISTS, SUBSCRIPTIONS_ERROR__DELEGATION_EXPIRED, SUBSCRIPTIONS_ERROR__DELEGATION_NOT_STARTED, SUBSCRIPTIONS_ERROR__DELEGATION_VERSION_MISMATCH, SUBSCRIPTIONS_ERROR__FIXED_DELEGATION_AMOUNT_ZERO, SUBSCRIPTIONS_ERROR__FIXED_DELEGATION_EXPIRY_IN_PAST, SUBSCRIPTIONS_ERROR__INVALID_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_ACCOUNT_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__INVALID_ADDRESS, SUBSCRIPTIONS_ERROR__INVALID_AMOUNT, SUBSCRIPTIONS_ERROR__INVALID_ASSOCIATED_TOKEN_ACCOUNT_DERIVED_ADDRESS, SUBSCRIPTIONS_ERROR__INVALID_DELEGATE_PDA, SUBSCRIPTIONS_ERROR__INVALID_END_TS, SUBSCRIPTIONS_ERROR__INVALID_ESCROW_PDA, SUBSCRIPTIONS_ERROR__INVALID_EVENT_AUTHORITY, SUBSCRIPTIONS_ERROR__INVALID_EVENT_DATA, SUBSCRIPTIONS_ERROR__INVALID_EVENT_DISCRIMINATOR, SUBSCRIPTIONS_ERROR__INVALID_EVENT_TAG, SUBSCRIPTIONS_ERROR__INVALID_HEADER_DATA, SUBSCRIPTIONS_ERROR__INVALID_INSTRUCTION, SUBSCRIPTIONS_ERROR__INVALID_INSTRUCTION_DATA, SUBSCRIPTIONS_ERROR__INVALID_NUM_DESTINATIONS, SUBSCRIPTIONS_ERROR__INVALID_PAYER_DATA, SUBSCRIPTIONS_ERROR__INVALID_PERIOD_LENGTH, SUBSCRIPTIONS_ERROR__INVALID_PLAN_PDA, SUBSCRIPTIONS_ERROR__INVALID_PLAN_STATUS, SUBSCRIPTIONS_ERROR__INVALID_SUBSCRIPTION_AUTHORITY_PDA, SUBSCRIPTIONS_ERROR__INVALID_SUBSCRIPTION_PDA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN2022_MINT_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN2022_TOKEN_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_PROGRAM, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_SPL_MINT_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__INVALID_TOKEN_SPL_TOKEN_ACCOUNT_DATA, SUBSCRIPTIONS_ERROR__MIGRATION_REQUIRED, SUBSCRIPTIONS_ERROR__MINT_HAS_CONFIDENTIAL_TRANSFER, SUBSCRIPTIONS_ERROR__MINT_HAS_MINT_CLOSE_AUTHORITY, SUBSCRIPTIONS_ERROR__MINT_HAS_NON_TRANSFERABLE, SUBSCRIPTIONS_ERROR__MINT_HAS_PAUSABLE, SUBSCRIPTIONS_ERROR__MINT_HAS_PERMANENT_DELEGATE, SUBSCRIPTIONS_ERROR__MINT_HAS_TRANSFER_FEE, SUBSCRIPTIONS_ERROR__MINT_HAS_TRANSFER_HOOK, SUBSCRIPTIONS_ERROR__MINT_MISMATCH, SUBSCRIPTIONS_ERROR__NOT_ENOUGH_ACCOUNT_KEYS, SUBSCRIPTIONS_ERROR__NOT_PLAN_OWNER, SUBSCRIPTIONS_ERROR__NOT_SIGNER, SUBSCRIPTIONS_ERROR__NOT_SYSTEM_PROGRAM, SUBSCRIPTIONS_ERROR__PERIOD_NOT_ELAPSED, SUBSCRIPTIONS_ERROR__PLAN_ALREADY_EXISTS, SUBSCRIPTIONS_ERROR__PLAN_CLOSED, SUBSCRIPTIONS_ERROR__PLAN_EXPIRED, SUBSCRIPTIONS_ERROR__PLAN_IMMUTABLE_AFTER_SUNSET, SUBSCRIPTIONS_ERROR__PLAN_NOT_EXPIRED, SUBSCRIPTIONS_ERROR__PLAN_SUNSET, SUBSCRIPTIONS_ERROR__PLAN_TERMS_MISMATCH, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_AMOUNT_ZERO, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_START_TIME_GREATER_THAN_EXPIRY, SUBSCRIPTIONS_ERROR__RECURRING_DELEGATION_START_TIME_IN_PAST, SUBSCRIPTIONS_ERROR__STALE_SUBSCRIPTION_AUTHORITY, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_ALREADY_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_NOT_CANCELLED, SUBSCRIPTIONS_ERROR__SUBSCRIPTION_PLAN_MISMATCH, SUBSCRIPTIONS_ERROR__SUNSET_REQUIRES_END_TS, SUBSCRIPTIONS_ERROR__UNAUTHORIZED, SUBSCRIPTIONS_ERROR__UNAUTHORIZED_DESTINATION, SUBSCRIPTIONS_PROGRAM_ADDRESS, SUBSCRIPTION_AUTHORITY_SEED, SUBSCRIPTION_SEED, SUBSCRIPTION_SIZE, type SubscribeAsyncInput, type SubscribeData, type SubscribeDataArgs, type SubscribeInput, type SubscribeInstruction, type SubscribeInstructionData, type SubscribeInstructionDataArgs, type SubscriptionAuthority, type SubscriptionAuthorityArgs, type SubscriptionAuthoritySeeds, type SubscriptionDelegation, type SubscriptionDelegationArgs, type SubscriptionDelegationSeeds, SubscriptionsAccount, type SubscriptionsError, SubscriptionsInstruction, type SubscriptionsPlugin, type SubscriptionsPluginAccounts, type SubscriptionsPluginInstructions, type SubscriptionsPluginPdas, type SubscriptionsPluginQueries, type SubscriptionsPluginRequirements, TRANSFER_FIXED_DISCRIMINATOR, TRANSFER_RECURRING_DISCRIMINATOR, TRANSFER_SUBSCRIPTION_DISCRIMINATOR, type TransferData, type TransferDataArgs, type TransferDelegationInput, type TransferFixedInput, type TransferFixedInstruction, type TransferFixedInstructionData, type TransferFixedInstructionDataArgs, type TransferRecurringInput, type TransferRecurringInstruction, type TransferRecurringInstructionData, type TransferRecurringInstructionDataArgs, type TransferSubscriptionInput, type TransferSubscriptionInstruction, type TransferSubscriptionInstructionData, type TransferSubscriptionInstructionDataArgs, U64_BYTE_SIZE, UPDATE_PLAN_DISCRIMINATOR, type UpdatePlanData, type UpdatePlanDataArgs, type UpdatePlanInput, type UpdatePlanInstruction, type UpdatePlanInstructionData, type UpdatePlanInstructionDataArgs, ValidationError, ZERO_ADDRESS, decodeDelegationAccount, decodeEventAuthority, decodeFixedDelegation, decodePlan, decodeRecurringDelegation, decodeSubscriptionAuthority, decodeSubscriptionDelegation, fetchAllEventAuthority, fetchAllFixedDelegation, fetchAllMaybeEventAuthority, fetchAllMaybeFixedDelegation, fetchAllMaybePlan, fetchAllMaybeRecurringDelegation, fetchAllMaybeSubscriptionAuthority, fetchAllMaybeSubscriptionDelegation, fetchAllPlan, fetchAllRecurringDelegation, fetchAllSubscriptionAuthority, fetchAllSubscriptionDelegation, fetchDelegationsByDelegatee, fetchDelegationsByDelegator, fetchEventAuthority, fetchEventAuthorityFromSeeds, fetchFixedDelegation, fetchFixedDelegationFromSeeds, fetchMaybeEventAuthority, fetchMaybeEventAuthorityFromSeeds, fetchMaybeFixedDelegation, fetchMaybeFixedDelegationFromSeeds, fetchMaybePlan, fetchMaybePlanFromSeeds, fetchMaybeRecurringDelegation, fetchMaybeRecurringDelegationFromSeeds, fetchMaybeSubscriptionAuthority, fetchMaybeSubscriptionAuthorityFromSeeds, fetchMaybeSubscriptionDelegation, fetchMaybeSubscriptionDelegationFromSeeds, fetchPlan, fetchPlanFromSeeds, fetchPlansForOwner, fetchRecurringDelegation, fetchRecurringDelegationFromSeeds, fetchSubscriptionAuthority, fetchSubscriptionAuthorityFromSeeds, fetchSubscriptionDelegation, fetchSubscriptionDelegationFromSeeds, fetchSubscriptionsForUser, findEventAuthorityPda, findFixedDelegationPda, findPlanPda, findRecurringDelegationPda, findSubscriptionAuthorityPda, findSubscriptionDelegationPda, getAccountDiscriminatorCodec, getAccountDiscriminatorDecoder, getAccountDiscriminatorEncoder, getCancelSubscriptionDiscriminatorBytes, getCancelSubscriptionInstruction, getCancelSubscriptionInstructionAsync, getCancelSubscriptionInstructionDataCodec, getCancelSubscriptionInstructionDataDecoder, getCancelSubscriptionInstructionDataEncoder, getCancelSubscriptionOverlayInstructionAsync, getCloseSubscriptionAuthorityDiscriminatorBytes, getCloseSubscriptionAuthorityInstruction, getCloseSubscriptionAuthorityInstructionDataCodec, getCloseSubscriptionAuthorityInstructionDataDecoder, getCloseSubscriptionAuthorityInstructionDataEncoder, getCloseSubscriptionAuthorityOverlayInstructionAsync, getCreateFixedDelegationDataCodec, getCreateFixedDelegationDataDecoder, getCreateFixedDelegationDataEncoder, getCreateFixedDelegationDiscriminatorBytes, getCreateFixedDelegationInstruction, getCreateFixedDelegationInstructionDataCodec, getCreateFixedDelegationInstructionDataDecoder, getCreateFixedDelegationInstructionDataEncoder, getCreateFixedDelegationOverlayInstructionAsync, getCreatePlanDiscriminatorBytes, getCreatePlanInstruction, getCreatePlanInstructionDataCodec, getCreatePlanInstructionDataDecoder, getCreatePlanInstructionDataEncoder, getCreatePlanOverlayInstructionAsync, getCreateRecurringDelegationDataCodec, getCreateRecurringDelegationDataDecoder, getCreateRecurringDelegationDataEncoder, getCreateRecurringDelegationDiscriminatorBytes, getCreateRecurringDelegationInstruction, getCreateRecurringDelegationInstructionDataCodec, getCreateRecurringDelegationInstructionDataDecoder, getCreateRecurringDelegationInstructionDataEncoder, getCreateRecurringDelegationOverlayInstructionAsync, getDeletePlanDiscriminatorBytes, getDeletePlanInstruction, getDeletePlanInstructionDataCodec, getDeletePlanInstructionDataDecoder, getDeletePlanInstructionDataEncoder, getDeletePlanOverlayInstruction, getEventAuthorityCodec, getEventAuthorityDecoder, getEventAuthorityEncoder, getFixedDelegationCodec, getFixedDelegationDecoder, getFixedDelegationEncoder, getHeaderCodec, getHeaderDecoder, getHeaderEncoder, getInitSubscriptionAuthorityDiscriminatorBytes, getInitSubscriptionAuthorityInstruction, getInitSubscriptionAuthorityInstructionAsync, getInitSubscriptionAuthorityInstructionDataCodec, getInitSubscriptionAuthorityInstructionDataDecoder, getInitSubscriptionAuthorityInstructionDataEncoder, getInitSubscriptionAuthorityOverlayInstructionAsync, getPlanCodec, getPlanDataCodec, getPlanDataDecoder, getPlanDataEncoder, getPlanDecoder, getPlanEncoder, getPlanStatusCodec, getPlanStatusDecoder, getPlanStatusEncoder, getPlanTermsCodec, getPlanTermsDecoder, getPlanTermsEncoder, getRecurringDelegationCodec, getRecurringDelegationDecoder, getRecurringDelegationEncoder, getResumeSubscriptionDiscriminatorBytes, getResumeSubscriptionInstruction, getResumeSubscriptionInstructionAsync, getResumeSubscriptionInstructionDataCodec, getResumeSubscriptionInstructionDataDecoder, getResumeSubscriptionInstructionDataEncoder, getResumeSubscriptionOverlayInstructionAsync, getRevokeDelegationDiscriminatorBytes, getRevokeDelegationInstruction, getRevokeDelegationInstructionDataCodec, getRevokeDelegationInstructionDataDecoder, getRevokeDelegationInstructionDataEncoder, getRevokeDelegationOverlayInstruction, getRevokeSubscriptionOverlayInstruction, getSubscribeDataCodec, getSubscribeDataDecoder, getSubscribeDataEncoder, getSubscribeDiscriminatorBytes, getSubscribeInstruction, getSubscribeInstructionAsync, getSubscribeInstructionDataCodec, getSubscribeInstructionDataDecoder, getSubscribeInstructionDataEncoder, getSubscribeOverlayInstructionAsync, getSubscriptionAuthorityCodec, getSubscriptionAuthorityDecoder, getSubscriptionAuthorityEncoder, getSubscriptionDelegationCodec, getSubscriptionDelegationDecoder, getSubscriptionDelegationEncoder, getSubscriptionsErrorMessage, getTransferDataCodec, getTransferDataDecoder, getTransferDataEncoder, getTransferFixedDiscriminatorBytes, getTransferFixedInstruction, getTransferFixedInstructionDataCodec, getTransferFixedInstructionDataDecoder, getTransferFixedInstructionDataEncoder, getTransferFixedOverlayInstructionAsync, getTransferRecurringDiscriminatorBytes, getTransferRecurringInstruction, getTransferRecurringInstructionDataCodec, getTransferRecurringInstructionDataDecoder, getTransferRecurringInstructionDataEncoder, getTransferRecurringOverlayInstructionAsync, getTransferSubscriptionDiscriminatorBytes, getTransferSubscriptionInstruction, getTransferSubscriptionInstructionDataCodec, getTransferSubscriptionInstructionDataDecoder, getTransferSubscriptionInstructionDataEncoder, getTransferSubscriptionOverlayInstructionAsync, getUpdatePlanDataCodec, getUpdatePlanDataDecoder, getUpdatePlanDataEncoder, getUpdatePlanDiscriminatorBytes, getUpdatePlanInstruction, getUpdatePlanInstructionDataCodec, getUpdatePlanInstructionDataDecoder, getUpdatePlanInstructionDataEncoder, getUpdatePlanOverlayInstruction, identifySubscriptionsInstruction, isSubscriptionsError, parseCancelSubscriptionInstruction, parseCloseSubscriptionAuthorityInstruction, parseCreateFixedDelegationInstruction, parseCreatePlanInstruction, parseCreateRecurringDelegationInstruction, parseDeletePlanInstruction, parseInitSubscriptionAuthorityInstruction, parseResumeSubscriptionInstruction, parseRevokeDelegationInstruction, parseSubscribeInstruction, parseSubscriptionsInstruction, parseTransferFixedInstruction, parseTransferRecurringInstruction, parseTransferSubscriptionInstruction, parseUpdatePlanInstruction, subscriptionsProgram, toEncodedAccount };
|