@intent-engine/core 0.1.40 → 0.1.42
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/generated/client/accounts/claimBoard.d.ts +4 -0
- package/dist/generated/client/accounts/claimBoard.js +5 -1
- package/dist/generated/client/accounts/claimBoard.js.map +1 -1
- package/dist/generated/client/accounts/index.d.ts +1 -0
- package/dist/generated/client/accounts/index.js +1 -0
- package/dist/generated/client/accounts/index.js.map +1 -1
- package/dist/generated/client/accounts/standby.d.ts +40 -0
- package/dist/generated/client/accounts/standby.js +67 -0
- package/dist/generated/client/accounts/standby.js.map +1 -0
- package/dist/generated/client/errors/intentEngine.d.ts +11 -1
- package/dist/generated/client/errors/intentEngine.js +15 -0
- package/dist/generated/client/errors/intentEngine.js.map +1 -1
- package/dist/generated/client/events/index.d.ts +2 -0
- package/dist/generated/client/events/index.js +2 -0
- package/dist/generated/client/events/index.js.map +1 -1
- package/dist/generated/client/events/lineLeft.d.ts +30 -0
- package/dist/generated/client/events/lineLeft.js +42 -0
- package/dist/generated/client/events/lineLeft.js.map +1 -0
- package/dist/generated/client/events/stoodBy.d.ts +32 -0
- package/dist/generated/client/events/stoodBy.js +46 -0
- package/dist/generated/client/events/stoodBy.js.map +1 -0
- package/dist/generated/client/instructions/advance.d.ts +79 -0
- package/dist/generated/client/instructions/advance.js +167 -0
- package/dist/generated/client/instructions/advance.js.map +1 -0
- package/dist/generated/client/instructions/dropClaim.d.ts +29 -9
- package/dist/generated/client/instructions/dropClaim.js +41 -2
- package/dist/generated/client/instructions/dropClaim.js.map +1 -1
- package/dist/generated/client/instructions/index.d.ts +3 -0
- package/dist/generated/client/instructions/index.js +3 -0
- package/dist/generated/client/instructions/index.js.map +1 -1
- package/dist/generated/client/instructions/leave.d.ts +68 -0
- package/dist/generated/client/instructions/leave.js +142 -0
- package/dist/generated/client/instructions/leave.js.map +1 -0
- package/dist/generated/client/instructions/standBy.d.ts +72 -0
- package/dist/generated/client/instructions/standBy.js +163 -0
- package/dist/generated/client/instructions/standBy.js.map +1 -0
- package/dist/generated/client/pdas/entry.d.ts +15 -0
- package/dist/generated/client/pdas/entry.js +20 -0
- package/dist/generated/client/pdas/entry.js.map +1 -0
- package/dist/generated/client/pdas/index.d.ts +1 -0
- package/dist/generated/client/pdas/index.js +1 -0
- package/dist/generated/client/pdas/index.js.map +1 -1
- package/dist/generated/client/programs/intentEngine.d.ts +121 -98
- package/dist/generated/client/programs/intentEngine.js +154 -98
- package/dist/generated/client/programs/intentEngine.js.map +1 -1
- package/dist/src/claims.d.ts +32 -2
- package/dist/src/claims.js +54 -2
- package/dist/src/claims.js.map +1 -1
- package/dist/src/describe.js +1 -1
- package/dist/src/describe.js.map +1 -1
- package/dist/src/errors.d.ts +1 -1
- package/dist/src/errors.js +3 -0
- package/dist/src/errors.js.map +1 -1
- package/dist/src/events.d.ts +3 -1
- package/dist/src/events.js +3 -1
- package/dist/src/events.js.map +1 -1
- package/dist/src/fee.d.ts +13 -0
- package/dist/src/fee.js +28 -0
- package/dist/src/fee.js.map +1 -1
- package/dist/src/index.d.ts +1 -0
- package/dist/src/index.js +1 -0
- package/dist/src/index.js.map +1 -1
- package/dist/src/memo.d.ts +0 -9
- package/dist/src/memo.js +0 -31
- package/dist/src/memo.js.map +1 -1
- package/dist/src/sealed-delivery.d.ts +25 -0
- package/dist/src/sealed-delivery.js +163 -0
- package/dist/src/sealed-delivery.js.map +1 -0
- package/dist/src/sealed.d.ts +2 -0
- package/dist/src/sealed.js +8 -23
- package/dist/src/sealed.js.map +1 -1
- package/generated/idl.json +394 -0
- package/package.json +1 -1
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This code was AUTOGENERATED using the Codama library.
|
|
3
|
+
* Please DO NOT EDIT THIS FILE, instead use visitors
|
|
4
|
+
* to add features, then rerun Codama to update it.
|
|
5
|
+
*
|
|
6
|
+
* @see https://github.com/codama-idl/codama
|
|
7
|
+
*/
|
|
8
|
+
import { combineCodec, fixDecoderSize, fixEncoderSize, getBytesDecoder, getBytesEncoder, getStructDecoder, getStructEncoder, SOLANA_ERROR__PROGRAM_CLIENTS__INSUFFICIENT_ACCOUNT_METAS, SolanaError, transformEncoder, } from "@solana/kit";
|
|
9
|
+
import { getAccountMetaFactory, getAddressFromResolvedInstructionAccount, } from "@solana/kit/program-client-core";
|
|
10
|
+
import { findBoardPda } from "../pdas/index.js";
|
|
11
|
+
import { INTENT_ENGINE_PROGRAM_ADDRESS } from "../programs/index.js";
|
|
12
|
+
export const ADVANCE_DISCRIMINATOR = new Uint8Array([
|
|
13
|
+
7, 56, 108, 201, 36, 20, 57, 89,
|
|
14
|
+
]);
|
|
15
|
+
export function getAdvanceDiscriminatorBytes() {
|
|
16
|
+
return fixEncoderSize(getBytesEncoder(), 8).encode(ADVANCE_DISCRIMINATOR);
|
|
17
|
+
}
|
|
18
|
+
export function getAdvanceInstructionDataEncoder() {
|
|
19
|
+
return transformEncoder(getStructEncoder([["discriminator", fixEncoderSize(getBytesEncoder(), 8)]]), (value) => ({ ...value, discriminator: ADVANCE_DISCRIMINATOR }));
|
|
20
|
+
}
|
|
21
|
+
export function getAdvanceInstructionDataDecoder() {
|
|
22
|
+
return getStructDecoder([
|
|
23
|
+
["discriminator", fixDecoderSize(getBytesDecoder(), 8)],
|
|
24
|
+
]);
|
|
25
|
+
}
|
|
26
|
+
export function getAdvanceInstructionDataCodec() {
|
|
27
|
+
return combineCodec(getAdvanceInstructionDataEncoder(), getAdvanceInstructionDataDecoder());
|
|
28
|
+
}
|
|
29
|
+
export async function getAdvanceInstructionAsync(input, config) {
|
|
30
|
+
// Program address.
|
|
31
|
+
const programAddress = config?.programAddress ?? INTENT_ENGINE_PROGRAM_ADDRESS;
|
|
32
|
+
// Account meta helper.
|
|
33
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
34
|
+
// Original accounts.
|
|
35
|
+
const originalAccounts = {
|
|
36
|
+
intent: { value: input.intent ?? null, isSigner: false, isWritable: false },
|
|
37
|
+
board: { value: input.board ?? null, isSigner: false, isWritable: true },
|
|
38
|
+
owner: { value: input.owner ?? null, isSigner: false, isWritable: true },
|
|
39
|
+
nextWorker: {
|
|
40
|
+
value: input.nextWorker ?? null,
|
|
41
|
+
isSigner: false,
|
|
42
|
+
isWritable: true,
|
|
43
|
+
},
|
|
44
|
+
entry0: { value: input.entry0 ?? null, isSigner: false, isWritable: true },
|
|
45
|
+
entry1: { value: input.entry1 ?? null, isSigner: false, isWritable: true },
|
|
46
|
+
entry2: { value: input.entry2 ?? null, isSigner: false, isWritable: true },
|
|
47
|
+
entry3: { value: input.entry3 ?? null, isSigner: false, isWritable: true },
|
|
48
|
+
eventAuthority: {
|
|
49
|
+
value: input.eventAuthority ?? null,
|
|
50
|
+
isSigner: false,
|
|
51
|
+
isWritable: false,
|
|
52
|
+
},
|
|
53
|
+
program: {
|
|
54
|
+
value: input.program ?? null,
|
|
55
|
+
isSigner: false,
|
|
56
|
+
isWritable: false,
|
|
57
|
+
},
|
|
58
|
+
};
|
|
59
|
+
const accounts = originalAccounts;
|
|
60
|
+
// Resolve default values.
|
|
61
|
+
if (!accounts.board.value) {
|
|
62
|
+
accounts.board.value = await findBoardPda({
|
|
63
|
+
intent: getAddressFromResolvedInstructionAccount("intent", accounts.intent.value),
|
|
64
|
+
}, { programAddress });
|
|
65
|
+
}
|
|
66
|
+
return Object.freeze({
|
|
67
|
+
accounts: [
|
|
68
|
+
getAccountMeta("intent", accounts.intent),
|
|
69
|
+
getAccountMeta("board", accounts.board),
|
|
70
|
+
getAccountMeta("owner", accounts.owner),
|
|
71
|
+
getAccountMeta("nextWorker", accounts.nextWorker),
|
|
72
|
+
getAccountMeta("entry0", accounts.entry0),
|
|
73
|
+
getAccountMeta("entry1", accounts.entry1),
|
|
74
|
+
getAccountMeta("entry2", accounts.entry2),
|
|
75
|
+
getAccountMeta("entry3", accounts.entry3),
|
|
76
|
+
getAccountMeta("eventAuthority", accounts.eventAuthority),
|
|
77
|
+
getAccountMeta("program", accounts.program),
|
|
78
|
+
],
|
|
79
|
+
data: getAdvanceInstructionDataEncoder().encode({}),
|
|
80
|
+
programAddress,
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
export function getAdvanceInstruction(input, config) {
|
|
84
|
+
// Program address.
|
|
85
|
+
const programAddress = config?.programAddress ?? INTENT_ENGINE_PROGRAM_ADDRESS;
|
|
86
|
+
// Account meta helper.
|
|
87
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
88
|
+
// Original accounts.
|
|
89
|
+
const originalAccounts = {
|
|
90
|
+
intent: { value: input.intent ?? null, isSigner: false, isWritable: false },
|
|
91
|
+
board: { value: input.board ?? null, isSigner: false, isWritable: true },
|
|
92
|
+
owner: { value: input.owner ?? null, isSigner: false, isWritable: true },
|
|
93
|
+
nextWorker: {
|
|
94
|
+
value: input.nextWorker ?? null,
|
|
95
|
+
isSigner: false,
|
|
96
|
+
isWritable: true,
|
|
97
|
+
},
|
|
98
|
+
entry0: { value: input.entry0 ?? null, isSigner: false, isWritable: true },
|
|
99
|
+
entry1: { value: input.entry1 ?? null, isSigner: false, isWritable: true },
|
|
100
|
+
entry2: { value: input.entry2 ?? null, isSigner: false, isWritable: true },
|
|
101
|
+
entry3: { value: input.entry3 ?? null, isSigner: false, isWritable: true },
|
|
102
|
+
eventAuthority: {
|
|
103
|
+
value: input.eventAuthority ?? null,
|
|
104
|
+
isSigner: false,
|
|
105
|
+
isWritable: false,
|
|
106
|
+
},
|
|
107
|
+
program: {
|
|
108
|
+
value: input.program ?? null,
|
|
109
|
+
isSigner: false,
|
|
110
|
+
isWritable: false,
|
|
111
|
+
},
|
|
112
|
+
};
|
|
113
|
+
const accounts = originalAccounts;
|
|
114
|
+
return Object.freeze({
|
|
115
|
+
accounts: [
|
|
116
|
+
getAccountMeta("intent", accounts.intent),
|
|
117
|
+
getAccountMeta("board", accounts.board),
|
|
118
|
+
getAccountMeta("owner", accounts.owner),
|
|
119
|
+
getAccountMeta("nextWorker", accounts.nextWorker),
|
|
120
|
+
getAccountMeta("entry0", accounts.entry0),
|
|
121
|
+
getAccountMeta("entry1", accounts.entry1),
|
|
122
|
+
getAccountMeta("entry2", accounts.entry2),
|
|
123
|
+
getAccountMeta("entry3", accounts.entry3),
|
|
124
|
+
getAccountMeta("eventAuthority", accounts.eventAuthority),
|
|
125
|
+
getAccountMeta("program", accounts.program),
|
|
126
|
+
],
|
|
127
|
+
data: getAdvanceInstructionDataEncoder().encode({}),
|
|
128
|
+
programAddress,
|
|
129
|
+
});
|
|
130
|
+
}
|
|
131
|
+
export function parseAdvanceInstruction(instruction) {
|
|
132
|
+
if (instruction.accounts.length < 10) {
|
|
133
|
+
throw new SolanaError(SOLANA_ERROR__PROGRAM_CLIENTS__INSUFFICIENT_ACCOUNT_METAS, {
|
|
134
|
+
actualAccountMetas: instruction.accounts.length,
|
|
135
|
+
expectedAccountMetas: 10,
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
let accountIndex = 0;
|
|
139
|
+
const getNextAccount = () => {
|
|
140
|
+
const accountMeta = instruction.accounts[accountIndex];
|
|
141
|
+
accountIndex += 1;
|
|
142
|
+
return accountMeta;
|
|
143
|
+
};
|
|
144
|
+
const getNextOptionalAccount = () => {
|
|
145
|
+
const accountMeta = getNextAccount();
|
|
146
|
+
return accountMeta.address === INTENT_ENGINE_PROGRAM_ADDRESS
|
|
147
|
+
? undefined
|
|
148
|
+
: accountMeta;
|
|
149
|
+
};
|
|
150
|
+
return {
|
|
151
|
+
programAddress: instruction.programAddress,
|
|
152
|
+
accounts: {
|
|
153
|
+
intent: getNextAccount(),
|
|
154
|
+
board: getNextAccount(),
|
|
155
|
+
owner: getNextAccount(),
|
|
156
|
+
nextWorker: getNextOptionalAccount(),
|
|
157
|
+
entry0: getNextOptionalAccount(),
|
|
158
|
+
entry1: getNextOptionalAccount(),
|
|
159
|
+
entry2: getNextOptionalAccount(),
|
|
160
|
+
entry3: getNextOptionalAccount(),
|
|
161
|
+
eventAuthority: getNextAccount(),
|
|
162
|
+
program: getNextAccount(),
|
|
163
|
+
},
|
|
164
|
+
data: getAdvanceInstructionDataDecoder().decode(instruction.data),
|
|
165
|
+
};
|
|
166
|
+
}
|
|
167
|
+
//# sourceMappingURL=advance.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"advance.js","sourceRoot":"","sources":["../../../../generated/client/instructions/advance.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,YAAY,EACZ,cAAc,EACd,cAAc,EACd,eAAe,EACf,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,yDAAyD,EACzD,WAAW,EACX,gBAAgB,GAYjB,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,qBAAqB,EACrB,wCAAwC,GAKzC,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,OAAO,EAAE,6BAA6B,EAAE,MAAM,sBAAsB,CAAC;AAErE,MAAM,CAAC,MAAM,qBAAqB,GAAuB,IAAI,UAAU,CAAC;IACtE,CAAC,EAAE,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE;CAChC,CAAC,CAAC;AAEH,MAAM,UAAU,4BAA4B;IAC1C,OAAO,cAAc,CAAC,eAAe,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,qBAAqB,CAAC,CAAC;AAC5E,CAAC;AAyDD,MAAM,UAAU,gCAAgC;IAC9C,OAAO,gBAAgB,CACrB,gBAAgB,CAAC,CAAC,CAAC,eAAe,EAAE,cAAc,CAAC,eAAe,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,EAC3E,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,EAAE,GAAG,KAAK,EAAE,aAAa,EAAE,qBAAqB,EAAE,CAAC,CAChE,CAAC;AACJ,CAA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CAAC,IAAI,CAAC;KAClE,CAAC;AACJ,CAAC"}
|
|
@@ -10,10 +10,15 @@ import { type InstructionAccountInput, type InstructionAccountInputAddress, type
|
|
|
10
10
|
import { INTENT_ENGINE_PROGRAM_ADDRESS } from "../programs/index.js";
|
|
11
11
|
export declare const DROP_CLAIM_DISCRIMINATOR: ReadonlyUint8Array;
|
|
12
12
|
export declare function getDropClaimDiscriminatorBytes(): ReadonlyUint8Array;
|
|
13
|
-
export type DropClaimInstruction<TProgram extends string = typeof INTENT_ENGINE_PROGRAM_ADDRESS, TAccountWorker extends string | AccountMeta<string> = string, TAccountIntent extends string | AccountMeta<string> = string, TAccountBoard extends string | AccountMeta<string> = string, TAccountEventAuthority extends string | AccountMeta<string> = string, TAccountProgram extends string | AccountMeta<string> = string, TRemainingAccounts extends readonly AccountMeta<string>[] = []> = Instruction<TProgram> & InstructionWithData<ReadonlyUint8Array> & InstructionWithAccounts<[
|
|
13
|
+
export type DropClaimInstruction<TProgram extends string = typeof INTENT_ENGINE_PROGRAM_ADDRESS, TAccountWorker extends string | AccountMeta<string> = string, TAccountIntent extends string | AccountMeta<string> = string, TAccountBoard extends string | AccountMeta<string> = string, TAccountNextWorker extends string | AccountMeta<string> = string, TAccountEntry0 extends string | AccountMeta<string> = string, TAccountEntry1 extends string | AccountMeta<string> = string, TAccountEntry2 extends string | AccountMeta<string> = string, TAccountEntry3 extends string | AccountMeta<string> = string, TAccountEventAuthority extends string | AccountMeta<string> = string, TAccountProgram extends string | AccountMeta<string> = string, TRemainingAccounts extends readonly AccountMeta<string>[] = []> = Instruction<TProgram> & InstructionWithData<ReadonlyUint8Array> & InstructionWithAccounts<[
|
|
14
14
|
TAccountWorker extends string ? WritableSignerAccount<TAccountWorker> & AccountSignerMeta<TAccountWorker> : TAccountWorker,
|
|
15
15
|
TAccountIntent extends string ? ReadonlyAccount<TAccountIntent> : TAccountIntent,
|
|
16
16
|
TAccountBoard extends string ? WritableAccount<TAccountBoard> : TAccountBoard,
|
|
17
|
+
TAccountNextWorker extends string ? WritableAccount<TAccountNextWorker> : TAccountNextWorker,
|
|
18
|
+
TAccountEntry0 extends string ? WritableAccount<TAccountEntry0> : TAccountEntry0,
|
|
19
|
+
TAccountEntry1 extends string ? WritableAccount<TAccountEntry1> : TAccountEntry1,
|
|
20
|
+
TAccountEntry2 extends string ? WritableAccount<TAccountEntry2> : TAccountEntry2,
|
|
21
|
+
TAccountEntry3 extends string ? WritableAccount<TAccountEntry3> : TAccountEntry3,
|
|
17
22
|
TAccountEventAuthority extends string ? ReadonlyAccount<TAccountEventAuthority> : TAccountEventAuthority,
|
|
18
23
|
TAccountProgram extends string ? ReadonlyAccount<TAccountProgram> : TAccountProgram,
|
|
19
24
|
...TRemainingAccounts
|
|
@@ -25,34 +30,49 @@ export type DropClaimInstructionDataArgs = {};
|
|
|
25
30
|
export declare function getDropClaimInstructionDataEncoder(): FixedSizeEncoder<DropClaimInstructionDataArgs>;
|
|
26
31
|
export declare function getDropClaimInstructionDataDecoder(): FixedSizeDecoder<DropClaimInstructionData>;
|
|
27
32
|
export declare function getDropClaimInstructionDataCodec(): FixedSizeCodec<DropClaimInstructionDataArgs, DropClaimInstructionData>;
|
|
28
|
-
export type DropClaimAsyncInput<TAccountWorker extends InstructionSignerInput = InstructionSignerInput, TAccountIntent extends InstructionAccountInput = InstructionAccountInput, TAccountBoard extends InstructionAccountInput = InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput = InstructionAccountInput, TAccountProgram extends InstructionAccountInput = InstructionAccountInput> = {
|
|
33
|
+
export type DropClaimAsyncInput<TAccountWorker extends InstructionSignerInput = InstructionSignerInput, TAccountIntent extends InstructionAccountInput = InstructionAccountInput, TAccountBoard extends InstructionAccountInput = InstructionAccountInput, TAccountNextWorker extends InstructionAccountInput = InstructionAccountInput, TAccountEntry0 extends InstructionAccountInput = InstructionAccountInput, TAccountEntry1 extends InstructionAccountInput = InstructionAccountInput, TAccountEntry2 extends InstructionAccountInput = InstructionAccountInput, TAccountEntry3 extends InstructionAccountInput = InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput = InstructionAccountInput, TAccountProgram extends InstructionAccountInput = InstructionAccountInput> = {
|
|
29
34
|
worker: TAccountWorker;
|
|
30
35
|
intent: TAccountIntent;
|
|
31
36
|
board?: TAccountBoard;
|
|
37
|
+
nextWorker?: TAccountNextWorker;
|
|
38
|
+
entry0?: TAccountEntry0;
|
|
39
|
+
entry1?: TAccountEntry1;
|
|
40
|
+
entry2?: TAccountEntry2;
|
|
41
|
+
entry3?: TAccountEntry3;
|
|
32
42
|
eventAuthority: TAccountEventAuthority;
|
|
33
43
|
program: TAccountProgram;
|
|
34
44
|
};
|
|
35
|
-
export declare function getDropClaimInstructionAsync<TAccountWorker extends InstructionSignerInput, TAccountIntent extends InstructionAccountInput, TAccountBoard extends InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput, TAccountProgram extends InstructionAccountInput, TProgramAddress extends Address = typeof INTENT_ENGINE_PROGRAM_ADDRESS>(input: DropClaimAsyncInput<TAccountWorker, TAccountIntent, TAccountBoard, TAccountEventAuthority, TAccountProgram>, config?: {
|
|
45
|
+
export declare function getDropClaimInstructionAsync<TAccountWorker extends InstructionSignerInput, TAccountIntent extends InstructionAccountInput, TAccountBoard extends InstructionAccountInput, TAccountNextWorker extends InstructionAccountInput, TAccountEntry0 extends InstructionAccountInput, TAccountEntry1 extends InstructionAccountInput, TAccountEntry2 extends InstructionAccountInput, TAccountEntry3 extends InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput, TAccountProgram extends InstructionAccountInput, TProgramAddress extends Address = typeof INTENT_ENGINE_PROGRAM_ADDRESS>(input: DropClaimAsyncInput<TAccountWorker, TAccountIntent, TAccountBoard, TAccountNextWorker, TAccountEntry0, TAccountEntry1, TAccountEntry2, TAccountEntry3, TAccountEventAuthority, TAccountProgram>, config?: {
|
|
36
46
|
programAddress?: TProgramAddress;
|
|
37
|
-
}): Promise<DropClaimInstruction<TProgramAddress, ResolvedInstructionAccountMeta<TAccountWorker, InstructionAccountInputAddress<TAccountWorker>>, ResolvedInstructionAccountMeta<TAccountIntent, InstructionAccountInputAddress<TAccountIntent>>, ResolvedInstructionAccountMeta<TAccountBoard, InstructionAccountInputAddress<TAccountBoard>>, ResolvedInstructionAccountMeta<TAccountEventAuthority, InstructionAccountInputAddress<TAccountEventAuthority>>, ResolvedInstructionAccountMeta<TAccountProgram, InstructionAccountInputAddress<TAccountProgram>>>>;
|
|
38
|
-
export type DropClaimInput<TAccountWorker extends InstructionSignerInput = InstructionSignerInput, TAccountIntent extends InstructionAccountInput = InstructionAccountInput, TAccountBoard extends InstructionAccountInput = InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput = InstructionAccountInput, TAccountProgram extends InstructionAccountInput = InstructionAccountInput> = {
|
|
47
|
+
}): Promise<DropClaimInstruction<TProgramAddress, ResolvedInstructionAccountMeta<TAccountWorker, InstructionAccountInputAddress<TAccountWorker>>, ResolvedInstructionAccountMeta<TAccountIntent, InstructionAccountInputAddress<TAccountIntent>>, ResolvedInstructionAccountMeta<TAccountBoard, InstructionAccountInputAddress<TAccountBoard>>, ResolvedInstructionAccountMeta<TAccountNextWorker, InstructionAccountInputAddress<TAccountNextWorker>>, ResolvedInstructionAccountMeta<TAccountEntry0, InstructionAccountInputAddress<TAccountEntry0>>, ResolvedInstructionAccountMeta<TAccountEntry1, InstructionAccountInputAddress<TAccountEntry1>>, ResolvedInstructionAccountMeta<TAccountEntry2, InstructionAccountInputAddress<TAccountEntry2>>, ResolvedInstructionAccountMeta<TAccountEntry3, InstructionAccountInputAddress<TAccountEntry3>>, ResolvedInstructionAccountMeta<TAccountEventAuthority, InstructionAccountInputAddress<TAccountEventAuthority>>, ResolvedInstructionAccountMeta<TAccountProgram, InstructionAccountInputAddress<TAccountProgram>>>>;
|
|
48
|
+
export type DropClaimInput<TAccountWorker extends InstructionSignerInput = InstructionSignerInput, TAccountIntent extends InstructionAccountInput = InstructionAccountInput, TAccountBoard extends InstructionAccountInput = InstructionAccountInput, TAccountNextWorker extends InstructionAccountInput = InstructionAccountInput, TAccountEntry0 extends InstructionAccountInput = InstructionAccountInput, TAccountEntry1 extends InstructionAccountInput = InstructionAccountInput, TAccountEntry2 extends InstructionAccountInput = InstructionAccountInput, TAccountEntry3 extends InstructionAccountInput = InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput = InstructionAccountInput, TAccountProgram extends InstructionAccountInput = InstructionAccountInput> = {
|
|
39
49
|
worker: TAccountWorker;
|
|
40
50
|
intent: TAccountIntent;
|
|
41
51
|
board: TAccountBoard;
|
|
52
|
+
nextWorker?: TAccountNextWorker;
|
|
53
|
+
entry0?: TAccountEntry0;
|
|
54
|
+
entry1?: TAccountEntry1;
|
|
55
|
+
entry2?: TAccountEntry2;
|
|
56
|
+
entry3?: TAccountEntry3;
|
|
42
57
|
eventAuthority: TAccountEventAuthority;
|
|
43
58
|
program: TAccountProgram;
|
|
44
59
|
};
|
|
45
|
-
export declare function getDropClaimInstruction<TAccountWorker extends InstructionSignerInput, TAccountIntent extends InstructionAccountInput, TAccountBoard extends InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput, TAccountProgram extends InstructionAccountInput, TProgramAddress extends Address = typeof INTENT_ENGINE_PROGRAM_ADDRESS>(input: DropClaimInput<TAccountWorker, TAccountIntent, TAccountBoard, TAccountEventAuthority, TAccountProgram>, config?: {
|
|
60
|
+
export declare function getDropClaimInstruction<TAccountWorker extends InstructionSignerInput, TAccountIntent extends InstructionAccountInput, TAccountBoard extends InstructionAccountInput, TAccountNextWorker extends InstructionAccountInput, TAccountEntry0 extends InstructionAccountInput, TAccountEntry1 extends InstructionAccountInput, TAccountEntry2 extends InstructionAccountInput, TAccountEntry3 extends InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput, TAccountProgram extends InstructionAccountInput, TProgramAddress extends Address = typeof INTENT_ENGINE_PROGRAM_ADDRESS>(input: DropClaimInput<TAccountWorker, TAccountIntent, TAccountBoard, TAccountNextWorker, TAccountEntry0, TAccountEntry1, TAccountEntry2, TAccountEntry3, TAccountEventAuthority, TAccountProgram>, config?: {
|
|
46
61
|
programAddress?: TProgramAddress;
|
|
47
|
-
}): DropClaimInstruction<TProgramAddress, ResolvedInstructionAccountMeta<TAccountWorker, InstructionAccountInputAddress<TAccountWorker>>, ResolvedInstructionAccountMeta<TAccountIntent, InstructionAccountInputAddress<TAccountIntent>>, ResolvedInstructionAccountMeta<TAccountBoard, InstructionAccountInputAddress<TAccountBoard>>, ResolvedInstructionAccountMeta<TAccountEventAuthority, InstructionAccountInputAddress<TAccountEventAuthority>>, ResolvedInstructionAccountMeta<TAccountProgram, InstructionAccountInputAddress<TAccountProgram>>>;
|
|
62
|
+
}): DropClaimInstruction<TProgramAddress, ResolvedInstructionAccountMeta<TAccountWorker, InstructionAccountInputAddress<TAccountWorker>>, ResolvedInstructionAccountMeta<TAccountIntent, InstructionAccountInputAddress<TAccountIntent>>, ResolvedInstructionAccountMeta<TAccountBoard, InstructionAccountInputAddress<TAccountBoard>>, ResolvedInstructionAccountMeta<TAccountNextWorker, InstructionAccountInputAddress<TAccountNextWorker>>, ResolvedInstructionAccountMeta<TAccountEntry0, InstructionAccountInputAddress<TAccountEntry0>>, ResolvedInstructionAccountMeta<TAccountEntry1, InstructionAccountInputAddress<TAccountEntry1>>, ResolvedInstructionAccountMeta<TAccountEntry2, InstructionAccountInputAddress<TAccountEntry2>>, ResolvedInstructionAccountMeta<TAccountEntry3, InstructionAccountInputAddress<TAccountEntry3>>, ResolvedInstructionAccountMeta<TAccountEventAuthority, InstructionAccountInputAddress<TAccountEventAuthority>>, ResolvedInstructionAccountMeta<TAccountProgram, InstructionAccountInputAddress<TAccountProgram>>>;
|
|
48
63
|
export type ParsedDropClaimInstruction<TProgram extends string = typeof INTENT_ENGINE_PROGRAM_ADDRESS, TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[]> = {
|
|
49
64
|
programAddress: Address<TProgram>;
|
|
50
65
|
accounts: {
|
|
51
66
|
worker: TAccountMetas[0];
|
|
52
67
|
intent: TAccountMetas[1];
|
|
53
68
|
board: TAccountMetas[2];
|
|
54
|
-
|
|
55
|
-
|
|
69
|
+
nextWorker?: TAccountMetas[3] | undefined;
|
|
70
|
+
entry0?: TAccountMetas[4] | undefined;
|
|
71
|
+
entry1?: TAccountMetas[5] | undefined;
|
|
72
|
+
entry2?: TAccountMetas[6] | undefined;
|
|
73
|
+
entry3?: TAccountMetas[7] | undefined;
|
|
74
|
+
eventAuthority: TAccountMetas[8];
|
|
75
|
+
program: TAccountMetas[9];
|
|
56
76
|
};
|
|
57
77
|
data: DropClaimInstructionData;
|
|
58
78
|
};
|
|
@@ -36,6 +36,15 @@ export async function getDropClaimInstructionAsync(input, config) {
|
|
|
36
36
|
worker: { value: input.worker ?? null, isSigner: true, isWritable: true },
|
|
37
37
|
intent: { value: input.intent ?? null, isSigner: false, isWritable: false },
|
|
38
38
|
board: { value: input.board ?? null, isSigner: false, isWritable: true },
|
|
39
|
+
nextWorker: {
|
|
40
|
+
value: input.nextWorker ?? null,
|
|
41
|
+
isSigner: false,
|
|
42
|
+
isWritable: true,
|
|
43
|
+
},
|
|
44
|
+
entry0: { value: input.entry0 ?? null, isSigner: false, isWritable: true },
|
|
45
|
+
entry1: { value: input.entry1 ?? null, isSigner: false, isWritable: true },
|
|
46
|
+
entry2: { value: input.entry2 ?? null, isSigner: false, isWritable: true },
|
|
47
|
+
entry3: { value: input.entry3 ?? null, isSigner: false, isWritable: true },
|
|
39
48
|
eventAuthority: {
|
|
40
49
|
value: input.eventAuthority ?? null,
|
|
41
50
|
isSigner: false,
|
|
@@ -59,6 +68,11 @@ export async function getDropClaimInstructionAsync(input, config) {
|
|
|
59
68
|
getAccountMeta("worker", accounts.worker),
|
|
60
69
|
getAccountMeta("intent", accounts.intent),
|
|
61
70
|
getAccountMeta("board", accounts.board),
|
|
71
|
+
getAccountMeta("nextWorker", accounts.nextWorker),
|
|
72
|
+
getAccountMeta("entry0", accounts.entry0),
|
|
73
|
+
getAccountMeta("entry1", accounts.entry1),
|
|
74
|
+
getAccountMeta("entry2", accounts.entry2),
|
|
75
|
+
getAccountMeta("entry3", accounts.entry3),
|
|
62
76
|
getAccountMeta("eventAuthority", accounts.eventAuthority),
|
|
63
77
|
getAccountMeta("program", accounts.program),
|
|
64
78
|
],
|
|
@@ -76,6 +90,15 @@ export function getDropClaimInstruction(input, config) {
|
|
|
76
90
|
worker: { value: input.worker ?? null, isSigner: true, isWritable: true },
|
|
77
91
|
intent: { value: input.intent ?? null, isSigner: false, isWritable: false },
|
|
78
92
|
board: { value: input.board ?? null, isSigner: false, isWritable: true },
|
|
93
|
+
nextWorker: {
|
|
94
|
+
value: input.nextWorker ?? null,
|
|
95
|
+
isSigner: false,
|
|
96
|
+
isWritable: true,
|
|
97
|
+
},
|
|
98
|
+
entry0: { value: input.entry0 ?? null, isSigner: false, isWritable: true },
|
|
99
|
+
entry1: { value: input.entry1 ?? null, isSigner: false, isWritable: true },
|
|
100
|
+
entry2: { value: input.entry2 ?? null, isSigner: false, isWritable: true },
|
|
101
|
+
entry3: { value: input.entry3 ?? null, isSigner: false, isWritable: true },
|
|
79
102
|
eventAuthority: {
|
|
80
103
|
value: input.eventAuthority ?? null,
|
|
81
104
|
isSigner: false,
|
|
@@ -93,6 +116,11 @@ export function getDropClaimInstruction(input, config) {
|
|
|
93
116
|
getAccountMeta("worker", accounts.worker),
|
|
94
117
|
getAccountMeta("intent", accounts.intent),
|
|
95
118
|
getAccountMeta("board", accounts.board),
|
|
119
|
+
getAccountMeta("nextWorker", accounts.nextWorker),
|
|
120
|
+
getAccountMeta("entry0", accounts.entry0),
|
|
121
|
+
getAccountMeta("entry1", accounts.entry1),
|
|
122
|
+
getAccountMeta("entry2", accounts.entry2),
|
|
123
|
+
getAccountMeta("entry3", accounts.entry3),
|
|
96
124
|
getAccountMeta("eventAuthority", accounts.eventAuthority),
|
|
97
125
|
getAccountMeta("program", accounts.program),
|
|
98
126
|
],
|
|
@@ -101,10 +129,10 @@ export function getDropClaimInstruction(input, config) {
|
|
|
101
129
|
});
|
|
102
130
|
}
|
|
103
131
|
export function parseDropClaimInstruction(instruction) {
|
|
104
|
-
if (instruction.accounts.length <
|
|
132
|
+
if (instruction.accounts.length < 10) {
|
|
105
133
|
throw new SolanaError(SOLANA_ERROR__PROGRAM_CLIENTS__INSUFFICIENT_ACCOUNT_METAS, {
|
|
106
134
|
actualAccountMetas: instruction.accounts.length,
|
|
107
|
-
expectedAccountMetas:
|
|
135
|
+
expectedAccountMetas: 10,
|
|
108
136
|
});
|
|
109
137
|
}
|
|
110
138
|
let accountIndex = 0;
|
|
@@ -113,12 +141,23 @@ export function parseDropClaimInstruction(instruction) {
|
|
|
113
141
|
accountIndex += 1;
|
|
114
142
|
return accountMeta;
|
|
115
143
|
};
|
|
144
|
+
const getNextOptionalAccount = () => {
|
|
145
|
+
const accountMeta = getNextAccount();
|
|
146
|
+
return accountMeta.address === INTENT_ENGINE_PROGRAM_ADDRESS
|
|
147
|
+
? undefined
|
|
148
|
+
: accountMeta;
|
|
149
|
+
};
|
|
116
150
|
return {
|
|
117
151
|
programAddress: instruction.programAddress,
|
|
118
152
|
accounts: {
|
|
119
153
|
worker: getNextAccount(),
|
|
120
154
|
intent: getNextAccount(),
|
|
121
155
|
board: getNextAccount(),
|
|
156
|
+
nextWorker: getNextOptionalAccount(),
|
|
157
|
+
entry0: getNextOptionalAccount(),
|
|
158
|
+
entry1: getNextOptionalAccount(),
|
|
159
|
+
entry2: getNextOptionalAccount(),
|
|
160
|
+
entry3: getNextOptionalAccount(),
|
|
122
161
|
eventAuthority: getNextAccount(),
|
|
123
162
|
program: getNextAccount(),
|
|
124
163
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dropClaim.js","sourceRoot":"","sources":["../../../../generated/client/instructions/dropClaim.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,YAAY,EACZ,cAAc,EACd,cAAc,EACd,eAAe,EACf,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,yDAAyD,EACzD,WAAW,EACX,gBAAgB,GAcjB,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,qBAAqB,EACrB,wCAAwC,GAMzC,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,OAAO,EAAE,6BAA6B,EAAE,MAAM,sBAAsB,CAAC;AAErE,MAAM,CAAC,MAAM,wBAAwB,GAAuB,IAAI,UAAU,CAAC;IACzE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,EAAE,EAAE,EAAE,EAAE,GAAG,EAAE,EAAE;CACpC,CAAC,CAAC;AAEH,MAAM,UAAU,8BAA8B;IAC5C,OAAO,cAAc,CAAC,eAAe,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,wBAAwB,CAAC,CAAC;AAC/E,CAAC;
|
|
1
|
+
{"version":3,"file":"dropClaim.js","sourceRoot":"","sources":["../../../../generated/client/instructions/dropClaim.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,YAAY,EACZ,cAAc,EACd,cAAc,EACd,eAAe,EACf,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,yDAAyD,EACzD,WAAW,EACX,gBAAgB,GAcjB,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,qBAAqB,EACrB,wCAAwC,GAMzC,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,OAAO,EAAE,6BAA6B,EAAE,MAAM,sBAAsB,CAAC;AAErE,MAAM,CAAC,MAAM,wBAAwB,GAAuB,IAAI,UAAU,CAAC;IACzE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,EAAE,EAAE,EAAE,EAAE,GAAG,EAAE,EAAE;CACpC,CAAC,CAAC;AAEH,MAAM,UAAU,8BAA8B;IAC5C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;YACR,MAAM,EAAE,cAAc,EAAE;YACxB,MAAM,EAAE,cAAc,EAAE;YACxB,KAAK,EAAE,cAAc,EAAE;YACvB,UAAU,EAAE,sBAAsB,EAAE;YACpC,MAAM,EAAE,sBAAsB,EAAE;YAChC,MAAM,EAAE,sBAAsB,EAAE;YAChC,MAAM,EAAE,sBAAsB,EAAE;YAChC,MAAM,EAAE,sBAAsB,EAAE;YAChC,cAAc,EAAE,cAAc,EAAE;YAChC,OAAO,EAAE,cAAc,EAAE;SAC1B;QACD,IAAI,EAAE,kCAAkC,EAAE,CAAC,MAAM,CAAC,WAAW,CAAC,IAAI,CAAC;KACpE,CAAC;AACJ,CAAC"}
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
export * from "./acceptAdmin.js";
|
|
9
|
+
export * from "./advance.js";
|
|
9
10
|
export * from "./advanceEpoch.js";
|
|
10
11
|
export * from "./advanceNonce.js";
|
|
11
12
|
export * from "./beginFill.js";
|
|
@@ -29,6 +30,7 @@ export * from "./fillAttestedSplitCommittee.js";
|
|
|
29
30
|
export * from "./fillIntent.js";
|
|
30
31
|
export * from "./initConfig.js";
|
|
31
32
|
export * from "./initUser.js";
|
|
33
|
+
export * from "./leave.js";
|
|
32
34
|
export * from "./lowerPause.js";
|
|
33
35
|
export * from "./openClaims.js";
|
|
34
36
|
export * from "./proposeAdmin.js";
|
|
@@ -37,6 +39,7 @@ export * from "./revokeMandate.js";
|
|
|
37
39
|
export * from "./setCapsRequired.js";
|
|
38
40
|
export * from "./setMintCap.js";
|
|
39
41
|
export * from "./settleClaims.js";
|
|
42
|
+
export * from "./standBy.js";
|
|
40
43
|
export * from "./updateConfig.js";
|
|
41
44
|
export * from "./updateEconomics.js";
|
|
42
45
|
export * from "./updateProfile.js";
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
* @see https://github.com/codama-idl/codama
|
|
7
7
|
*/
|
|
8
8
|
export * from "./acceptAdmin.js";
|
|
9
|
+
export * from "./advance.js";
|
|
9
10
|
export * from "./advanceEpoch.js";
|
|
10
11
|
export * from "./advanceNonce.js";
|
|
11
12
|
export * from "./beginFill.js";
|
|
@@ -29,6 +30,7 @@ export * from "./fillAttestedSplitCommittee.js";
|
|
|
29
30
|
export * from "./fillIntent.js";
|
|
30
31
|
export * from "./initConfig.js";
|
|
31
32
|
export * from "./initUser.js";
|
|
33
|
+
export * from "./leave.js";
|
|
32
34
|
export * from "./lowerPause.js";
|
|
33
35
|
export * from "./openClaims.js";
|
|
34
36
|
export * from "./proposeAdmin.js";
|
|
@@ -37,6 +39,7 @@ export * from "./revokeMandate.js";
|
|
|
37
39
|
export * from "./setCapsRequired.js";
|
|
38
40
|
export * from "./setMintCap.js";
|
|
39
41
|
export * from "./settleClaims.js";
|
|
42
|
+
export * from "./standBy.js";
|
|
40
43
|
export * from "./updateConfig.js";
|
|
41
44
|
export * from "./updateEconomics.js";
|
|
42
45
|
export * from "./updateProfile.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../generated/client/instructions/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,mBAAmB,CAAC;AAClC,cAAc,eAAe,CAAC;AAC9B,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,cAAc,mBAAmB,CAAC;AAClC,cAAc,0BAA0B,CAAC;AACzC,cAAc,yBAAyB,CAAC;AACxC,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,wBAAwB,CAAC;AACvC,cAAc,iCAAiC,CAAC;AAChD,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,iBAAiB,CAAC;AAChC,cAAc,oBAAoB,CAAC;AACnC,cAAc,sBAAsB,CAAC;AACrC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../generated/client/instructions/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,cAAc,kBAAkB,CAAC;AACjC,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,mBAAmB,CAAC;AAClC,cAAc,eAAe,CAAC;AAC9B,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,cAAc,mBAAmB,CAAC;AAClC,cAAc,0BAA0B,CAAC;AACzC,cAAc,yBAAyB,CAAC;AACxC,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,wBAAwB,CAAC;AACvC,cAAc,iCAAiC,CAAC;AAChD,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,YAAY,CAAC;AAC3B,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,iBAAiB,CAAC;AAChC,cAAc,oBAAoB,CAAC;AACnC,cAAc,sBAAsB,CAAC;AACrC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This code was AUTOGENERATED using the Codama library.
|
|
3
|
+
* Please DO NOT EDIT THIS FILE, instead use visitors
|
|
4
|
+
* to add features, then rerun Codama to update it.
|
|
5
|
+
*
|
|
6
|
+
* @see https://github.com/codama-idl/codama
|
|
7
|
+
*/
|
|
8
|
+
import { type AccountMeta, type AccountSignerMeta, type Address, type FixedSizeCodec, type FixedSizeDecoder, type FixedSizeEncoder, type Instruction, type InstructionWithAccounts, type InstructionWithData, type ReadonlyAccount, type ReadonlySignerAccount, type ReadonlyUint8Array, type WritableAccount } from "@solana/kit";
|
|
9
|
+
import { type InstructionAccountInput, type InstructionAccountInputAddress, type InstructionSignerInput, type ResolvedInstructionAccountMeta } from "@solana/kit/program-client-core";
|
|
10
|
+
import { INTENT_ENGINE_PROGRAM_ADDRESS } from "../programs/index.js";
|
|
11
|
+
export declare const LEAVE_DISCRIMINATOR: ReadonlyUint8Array;
|
|
12
|
+
export declare function getLeaveDiscriminatorBytes(): ReadonlyUint8Array;
|
|
13
|
+
export type LeaveInstruction<TProgram extends string = typeof INTENT_ENGINE_PROGRAM_ADDRESS, TAccountCaller extends string | AccountMeta<string> = string, TAccountIntent extends string | AccountMeta<string> = string, TAccountEntry extends string | AccountMeta<string> = string, TAccountWorker extends string | AccountMeta<string> = string, TAccountEventAuthority extends string | AccountMeta<string> = string, TAccountProgram extends string | AccountMeta<string> = string, TRemainingAccounts extends readonly AccountMeta<string>[] = []> = Instruction<TProgram> & InstructionWithData<ReadonlyUint8Array> & InstructionWithAccounts<[
|
|
14
|
+
TAccountCaller extends string ? ReadonlySignerAccount<TAccountCaller> & AccountSignerMeta<TAccountCaller> : TAccountCaller,
|
|
15
|
+
TAccountIntent extends string ? ReadonlyAccount<TAccountIntent> : TAccountIntent,
|
|
16
|
+
TAccountEntry extends string ? WritableAccount<TAccountEntry> : TAccountEntry,
|
|
17
|
+
TAccountWorker extends string ? WritableAccount<TAccountWorker> : TAccountWorker,
|
|
18
|
+
TAccountEventAuthority extends string ? ReadonlyAccount<TAccountEventAuthority> : TAccountEventAuthority,
|
|
19
|
+
TAccountProgram extends string ? ReadonlyAccount<TAccountProgram> : TAccountProgram,
|
|
20
|
+
...TRemainingAccounts
|
|
21
|
+
]>;
|
|
22
|
+
export type LeaveInstructionData = {
|
|
23
|
+
discriminator: ReadonlyUint8Array;
|
|
24
|
+
seq: number;
|
|
25
|
+
};
|
|
26
|
+
export type LeaveInstructionDataArgs = {
|
|
27
|
+
seq: number;
|
|
28
|
+
};
|
|
29
|
+
export declare function getLeaveInstructionDataEncoder(): FixedSizeEncoder<LeaveInstructionDataArgs>;
|
|
30
|
+
export declare function getLeaveInstructionDataDecoder(): FixedSizeDecoder<LeaveInstructionData>;
|
|
31
|
+
export declare function getLeaveInstructionDataCodec(): FixedSizeCodec<LeaveInstructionDataArgs, LeaveInstructionData>;
|
|
32
|
+
export type LeaveAsyncInput<TAccountCaller extends InstructionSignerInput = InstructionSignerInput, TAccountIntent extends InstructionAccountInput = InstructionAccountInput, TAccountEntry extends InstructionAccountInput = InstructionAccountInput, TAccountWorker extends InstructionAccountInput = InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput = InstructionAccountInput, TAccountProgram extends InstructionAccountInput = InstructionAccountInput> = {
|
|
33
|
+
caller: TAccountCaller;
|
|
34
|
+
intent: TAccountIntent;
|
|
35
|
+
entry?: TAccountEntry;
|
|
36
|
+
worker: TAccountWorker;
|
|
37
|
+
eventAuthority: TAccountEventAuthority;
|
|
38
|
+
program: TAccountProgram;
|
|
39
|
+
seq: LeaveInstructionDataArgs["seq"];
|
|
40
|
+
};
|
|
41
|
+
export declare function getLeaveInstructionAsync<TAccountCaller extends InstructionSignerInput, TAccountIntent extends InstructionAccountInput, TAccountEntry extends InstructionAccountInput, TAccountWorker extends InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput, TAccountProgram extends InstructionAccountInput, TProgramAddress extends Address = typeof INTENT_ENGINE_PROGRAM_ADDRESS>(input: LeaveAsyncInput<TAccountCaller, TAccountIntent, TAccountEntry, TAccountWorker, TAccountEventAuthority, TAccountProgram>, config?: {
|
|
42
|
+
programAddress?: TProgramAddress;
|
|
43
|
+
}): Promise<LeaveInstruction<TProgramAddress, ResolvedInstructionAccountMeta<TAccountCaller, InstructionAccountInputAddress<TAccountCaller>>, ResolvedInstructionAccountMeta<TAccountIntent, InstructionAccountInputAddress<TAccountIntent>>, ResolvedInstructionAccountMeta<TAccountEntry, InstructionAccountInputAddress<TAccountEntry>>, ResolvedInstructionAccountMeta<TAccountWorker, InstructionAccountInputAddress<TAccountWorker>>, ResolvedInstructionAccountMeta<TAccountEventAuthority, InstructionAccountInputAddress<TAccountEventAuthority>>, ResolvedInstructionAccountMeta<TAccountProgram, InstructionAccountInputAddress<TAccountProgram>>>>;
|
|
44
|
+
export type LeaveInput<TAccountCaller extends InstructionSignerInput = InstructionSignerInput, TAccountIntent extends InstructionAccountInput = InstructionAccountInput, TAccountEntry extends InstructionAccountInput = InstructionAccountInput, TAccountWorker extends InstructionAccountInput = InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput = InstructionAccountInput, TAccountProgram extends InstructionAccountInput = InstructionAccountInput> = {
|
|
45
|
+
caller: TAccountCaller;
|
|
46
|
+
intent: TAccountIntent;
|
|
47
|
+
entry: TAccountEntry;
|
|
48
|
+
worker: TAccountWorker;
|
|
49
|
+
eventAuthority: TAccountEventAuthority;
|
|
50
|
+
program: TAccountProgram;
|
|
51
|
+
seq: LeaveInstructionDataArgs["seq"];
|
|
52
|
+
};
|
|
53
|
+
export declare function getLeaveInstruction<TAccountCaller extends InstructionSignerInput, TAccountIntent extends InstructionAccountInput, TAccountEntry extends InstructionAccountInput, TAccountWorker extends InstructionAccountInput, TAccountEventAuthority extends InstructionAccountInput, TAccountProgram extends InstructionAccountInput, TProgramAddress extends Address = typeof INTENT_ENGINE_PROGRAM_ADDRESS>(input: LeaveInput<TAccountCaller, TAccountIntent, TAccountEntry, TAccountWorker, TAccountEventAuthority, TAccountProgram>, config?: {
|
|
54
|
+
programAddress?: TProgramAddress;
|
|
55
|
+
}): LeaveInstruction<TProgramAddress, ResolvedInstructionAccountMeta<TAccountCaller, InstructionAccountInputAddress<TAccountCaller>>, ResolvedInstructionAccountMeta<TAccountIntent, InstructionAccountInputAddress<TAccountIntent>>, ResolvedInstructionAccountMeta<TAccountEntry, InstructionAccountInputAddress<TAccountEntry>>, ResolvedInstructionAccountMeta<TAccountWorker, InstructionAccountInputAddress<TAccountWorker>>, ResolvedInstructionAccountMeta<TAccountEventAuthority, InstructionAccountInputAddress<TAccountEventAuthority>>, ResolvedInstructionAccountMeta<TAccountProgram, InstructionAccountInputAddress<TAccountProgram>>>;
|
|
56
|
+
export type ParsedLeaveInstruction<TProgram extends string = typeof INTENT_ENGINE_PROGRAM_ADDRESS, TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[]> = {
|
|
57
|
+
programAddress: Address<TProgram>;
|
|
58
|
+
accounts: {
|
|
59
|
+
caller: TAccountMetas[0];
|
|
60
|
+
intent: TAccountMetas[1];
|
|
61
|
+
entry: TAccountMetas[2];
|
|
62
|
+
worker: TAccountMetas[3];
|
|
63
|
+
eventAuthority: TAccountMetas[4];
|
|
64
|
+
program: TAccountMetas[5];
|
|
65
|
+
};
|
|
66
|
+
data: LeaveInstructionData;
|
|
67
|
+
};
|
|
68
|
+
export declare function parseLeaveInstruction<TProgram extends string, TAccountMetas extends readonly AccountMeta[]>(instruction: Instruction<TProgram> & InstructionWithAccounts<TAccountMetas> & InstructionWithData<ReadonlyUint8Array>): ParsedLeaveInstruction<TProgram, TAccountMetas>;
|