@usesigil/kit 0.15.0 → 0.16.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/dist/agent-bootstrap.d.ts +118 -0
- package/dist/agent-bootstrap.d.ts.map +1 -0
- package/dist/agent-bootstrap.js +211 -0
- package/dist/agent-bootstrap.js.map +1 -0
- package/dist/agent-errors.d.ts +3 -3
- package/dist/agent-errors.d.ts.map +1 -1
- package/dist/agent-errors.js +227 -142
- package/dist/agent-errors.js.map +1 -1
- package/dist/build-unsigned.d.ts +152 -0
- package/dist/build-unsigned.d.ts.map +1 -0
- package/dist/build-unsigned.js +152 -0
- package/dist/build-unsigned.js.map +1 -0
- package/dist/constraints/index.d.ts +23 -0
- package/dist/constraints/index.d.ts.map +1 -0
- package/dist/constraints/index.js +24 -0
- package/dist/constraints/index.js.map +1 -0
- package/dist/create-vault.d.ts +10 -1
- package/dist/create-vault.d.ts.map +1 -1
- package/dist/create-vault.js +10 -2
- package/dist/create-vault.js.map +1 -1
- package/dist/dashboard/constraint-builders.d.ts +82 -0
- package/dist/dashboard/constraint-builders.d.ts.map +1 -0
- package/dist/dashboard/constraint-builders.js +204 -0
- package/dist/dashboard/constraint-builders.js.map +1 -0
- package/dist/dashboard/errors.d.ts +37 -0
- package/dist/dashboard/errors.d.ts.map +1 -1
- package/dist/dashboard/errors.js +76 -0
- package/dist/dashboard/errors.js.map +1 -1
- package/dist/dashboard/from-json.d.ts.map +1 -1
- package/dist/dashboard/from-json.js +1 -2
- package/dist/dashboard/from-json.js.map +1 -1
- package/dist/dashboard/index.d.ts +29 -3
- package/dist/dashboard/index.d.ts.map +1 -1
- package/dist/dashboard/index.js +36 -1
- package/dist/dashboard/index.js.map +1 -1
- package/dist/dashboard/mutations.d.ts +60 -1
- package/dist/dashboard/mutations.d.ts.map +1 -1
- package/dist/dashboard/mutations.js +127 -20
- package/dist/dashboard/mutations.js.map +1 -1
- package/dist/dashboard/post-assertion-validation.d.ts +88 -0
- package/dist/dashboard/post-assertion-validation.d.ts.map +1 -0
- package/dist/dashboard/post-assertion-validation.js +191 -0
- package/dist/dashboard/post-assertion-validation.js.map +1 -0
- package/dist/dashboard/reads.d.ts +93 -1
- package/dist/dashboard/reads.d.ts.map +1 -1
- package/dist/dashboard/reads.js +238 -9
- package/dist/dashboard/reads.js.map +1 -1
- package/dist/dashboard/types.d.ts +147 -11
- package/dist/dashboard/types.d.ts.map +1 -1
- package/dist/errors/codes.js +1 -1
- package/dist/events.d.ts.map +1 -1
- package/dist/events.js +2 -1
- package/dist/events.js.map +1 -1
- package/dist/generated/accounts/pendingAgentPermissionsUpdate.d.ts +12 -0
- package/dist/generated/accounts/pendingAgentPermissionsUpdate.d.ts.map +1 -1
- package/dist/generated/accounts/pendingAgentPermissionsUpdate.js +3 -1
- package/dist/generated/accounts/pendingAgentPermissionsUpdate.js.map +1 -1
- package/dist/generated/accounts/pendingCloseConstraints.d.ts +12 -0
- package/dist/generated/accounts/pendingCloseConstraints.d.ts.map +1 -1
- package/dist/generated/accounts/pendingCloseConstraints.js +4 -2
- package/dist/generated/accounts/pendingCloseConstraints.js.map +1 -1
- package/dist/generated/accounts/pendingConstraintsUpdate.d.ts +14 -0
- package/dist/generated/accounts/pendingConstraintsUpdate.d.ts.map +1 -1
- package/dist/generated/accounts/pendingConstraintsUpdate.js +4 -2
- package/dist/generated/accounts/pendingConstraintsUpdate.js.map +1 -1
- package/dist/generated/accounts/pendingPolicyUpdate.d.ts +24 -4
- package/dist/generated/accounts/pendingPolicyUpdate.d.ts.map +1 -1
- package/dist/generated/accounts/pendingPolicyUpdate.js +6 -4
- package/dist/generated/accounts/pendingPolicyUpdate.js.map +1 -1
- package/dist/generated/accounts/policyConfig.d.ts +28 -10
- package/dist/generated/accounts/policyConfig.d.ts.map +1 -1
- package/dist/generated/accounts/policyConfig.js +4 -4
- package/dist/generated/accounts/policyConfig.js.map +1 -1
- package/dist/generated/accounts/sessionAuthority.d.ts +18 -4
- package/dist/generated/accounts/sessionAuthority.d.ts.map +1 -1
- package/dist/generated/accounts/sessionAuthority.js +3 -3
- package/dist/generated/accounts/sessionAuthority.js.map +1 -1
- package/dist/generated/errors/sigil.d.ts +95 -81
- package/dist/generated/errors/sigil.d.ts.map +1 -1
- package/dist/generated/errors/sigil.js +107 -86
- package/dist/generated/errors/sigil.js.map +1 -1
- package/dist/generated/event-discriminators.d.ts.map +1 -1
- package/dist/generated/event-discriminators.js +2 -1
- package/dist/generated/event-discriminators.js.map +1 -1
- package/dist/generated/instructions/cleanupOrphanConstraintsPda.d.ts +67 -0
- package/dist/generated/instructions/cleanupOrphanConstraintsPda.d.ts.map +1 -0
- package/dist/generated/instructions/cleanupOrphanConstraintsPda.js +120 -0
- package/dist/generated/instructions/cleanupOrphanConstraintsPda.js.map +1 -0
- package/dist/generated/instructions/freezeVault.d.ts +8 -5
- package/dist/generated/instructions/freezeVault.d.ts.map +1 -1
- package/dist/generated/instructions/freezeVault.js +14 -3
- package/dist/generated/instructions/freezeVault.js.map +1 -1
- package/dist/generated/instructions/index.d.ts +1 -0
- package/dist/generated/instructions/index.d.ts.map +1 -1
- package/dist/generated/instructions/index.js +1 -0
- package/dist/generated/instructions/index.js.map +1 -1
- package/dist/generated/instructions/initializeVault.d.ts +0 -4
- package/dist/generated/instructions/initializeVault.d.ts.map +1 -1
- package/dist/generated/instructions/initializeVault.js +0 -2
- package/dist/generated/instructions/initializeVault.js.map +1 -1
- package/dist/generated/instructions/queuePolicyUpdate.d.ts +8 -8
- package/dist/generated/instructions/queuePolicyUpdate.d.ts.map +1 -1
- package/dist/generated/instructions/queuePolicyUpdate.js +4 -4
- package/dist/generated/instructions/queuePolicyUpdate.js.map +1 -1
- package/dist/generated/programs/sigil.d.ts +29 -25
- package/dist/generated/programs/sigil.d.ts.map +1 -1
- package/dist/generated/programs/sigil.js +37 -25
- package/dist/generated/programs/sigil.js.map +1 -1
- package/dist/generated/types/accountConstraint.d.ts +16 -1
- package/dist/generated/types/accountConstraint.d.ts.map +1 -1
- package/dist/generated/types/accountConstraint.js +2 -0
- package/dist/generated/types/accountConstraint.js.map +1 -1
- package/dist/generated/types/accountConstraintZC.d.ts +7 -0
- package/dist/generated/types/accountConstraintZC.d.ts.map +1 -1
- package/dist/generated/types/accountConstraintZC.js +4 -2
- package/dist/generated/types/accountConstraintZC.js.map +1 -1
- package/dist/generated/types/constraintEntry.d.ts +0 -4
- package/dist/generated/types/constraintEntry.d.ts.map +1 -1
- package/dist/generated/types/constraintEntry.js +1 -3
- package/dist/generated/types/constraintEntry.js.map +1 -1
- package/dist/generated/types/constraintEntryZC.d.ts +17 -12
- package/dist/generated/types/constraintEntryZC.d.ts.map +1 -1
- package/dist/generated/types/constraintEntryZC.js +2 -2
- package/dist/generated/types/constraintEntryZC.js.map +1 -1
- package/dist/generated/types/index.d.ts +1 -0
- package/dist/generated/types/index.d.ts.map +1 -1
- package/dist/generated/types/index.js +1 -0
- package/dist/generated/types/index.js.map +1 -1
- package/dist/generated/types/orphanConstraintsPdaCleaned.d.ts +22 -0
- package/dist/generated/types/orphanConstraintsPdaCleaned.d.ts.map +1 -0
- package/dist/generated/types/orphanConstraintsPdaCleaned.js +26 -0
- package/dist/generated/types/orphanConstraintsPdaCleaned.js.map +1 -0
- package/dist/generated/types/vaultFrozen.d.ts +12 -0
- package/dist/generated/types/vaultFrozen.d.ts.map +1 -1
- package/dist/generated/types/vaultFrozen.js +3 -1
- package/dist/generated/types/vaultFrozen.js.map +1 -1
- package/dist/index.d.ts +11 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +22 -1
- package/dist/index.js.map +1 -1
- package/dist/inscribe.d.ts +0 -4
- package/dist/inscribe.d.ts.map +1 -1
- package/dist/inscribe.js +0 -1
- package/dist/inscribe.js.map +1 -1
- package/dist/kit-adapter.d.ts +1 -1
- package/dist/kit-adapter.d.ts.map +1 -1
- package/dist/kit-adapter.js +1 -1
- package/dist/kit-adapter.js.map +1 -1
- package/dist/logger.d.ts +48 -0
- package/dist/logger.d.ts.map +1 -1
- package/dist/logger.js +36 -0
- package/dist/logger.js.map +1 -1
- package/dist/owner-transaction.d.ts +8 -0
- package/dist/owner-transaction.d.ts.map +1 -1
- package/dist/owner-transaction.js +1 -0
- package/dist/owner-transaction.js.map +1 -1
- package/dist/post-assertions/cross-field-lte.d.ts +134 -0
- package/dist/post-assertions/cross-field-lte.d.ts.map +1 -0
- package/dist/post-assertions/cross-field-lte.js +129 -0
- package/dist/post-assertions/cross-field-lte.js.map +1 -0
- package/dist/post-assertions/index.d.ts +28 -0
- package/dist/post-assertions/index.d.ts.map +1 -0
- package/dist/post-assertions/index.js +28 -0
- package/dist/post-assertions/index.js.map +1 -0
- package/dist/post-assertions/presets/flash-trade.d.ts +139 -0
- package/dist/post-assertions/presets/flash-trade.d.ts.map +1 -0
- package/dist/post-assertions/presets/flash-trade.js +154 -0
- package/dist/post-assertions/presets/flash-trade.js.map +1 -0
- package/dist/presets.d.ts +1 -7
- package/dist/presets.d.ts.map +1 -1
- package/dist/presets.js +0 -5
- package/dist/presets.js.map +1 -1
- package/dist/preview-create-vault.d.ts +280 -0
- package/dist/preview-create-vault.d.ts.map +1 -0
- package/dist/preview-create-vault.js +477 -0
- package/dist/preview-create-vault.js.map +1 -0
- package/dist/protocol-registry/annotations/drift.json +7 -0
- package/dist/protocol-registry/annotations/flash-trade.json +7 -0
- package/dist/protocol-registry/annotations/jupiter-borrow.json +7 -0
- package/dist/protocol-registry/annotations/jupiter-earn.json +7 -0
- package/dist/protocol-registry/annotations/jupiter-lend.json +7 -0
- package/dist/protocol-registry/annotations/jupiter.json +7 -0
- package/dist/protocol-registry/annotations/kamino.json +7 -0
- package/dist/protocol-registry/index.d.ts +45 -0
- package/dist/protocol-registry/index.d.ts.map +1 -0
- package/dist/protocol-registry/index.js +76 -0
- package/dist/protocol-registry/index.js.map +1 -0
- package/dist/protocol-tier.d.ts +157 -0
- package/dist/protocol-tier.d.ts.map +1 -0
- package/dist/protocol-tier.js +104 -0
- package/dist/protocol-tier.js.map +1 -0
- package/dist/seal.d.ts.map +1 -1
- package/dist/seal.js +26 -2
- package/dist/seal.js.map +1 -1
- package/dist/sigil.d.ts +0 -4
- package/dist/sigil.d.ts.map +1 -1
- package/dist/simulation.d.ts.map +1 -1
- package/dist/simulation.js +72 -91
- package/dist/simulation.js.map +1 -1
- package/dist/testing/devnet.d.ts.map +1 -1
- package/dist/testing/devnet.js +0 -1
- package/dist/testing/devnet.js.map +1 -1
- package/dist/testing/errors/expect.d.ts +137 -0
- package/dist/testing/errors/expect.d.ts.map +1 -0
- package/dist/testing/errors/expect.js +372 -0
- package/dist/testing/errors/expect.js.map +1 -0
- package/dist/testing/errors/index.d.ts +3 -0
- package/dist/testing/errors/index.d.ts.map +1 -0
- package/dist/testing/errors/index.js +8 -0
- package/dist/testing/errors/index.js.map +1 -0
- package/dist/testing/errors/names.generated.d.ts +188 -0
- package/dist/testing/errors/names.generated.d.ts.map +1 -0
- package/dist/testing/errors/names.generated.js +183 -0
- package/dist/testing/errors/names.generated.js.map +1 -0
- package/dist/testing/index.d.ts +1 -0
- package/dist/testing/index.d.ts.map +1 -1
- package/dist/testing/index.js +8 -0
- package/dist/testing/index.js.map +1 -1
- package/dist/testing/mock-rpc.d.ts +8 -0
- package/dist/testing/mock-rpc.d.ts.map +1 -1
- package/dist/testing/mock-rpc.js +14 -0
- package/dist/testing/mock-rpc.js.map +1 -1
- package/dist/testing/mock-state.js +2 -2
- package/dist/testing/mock-state.js.map +1 -1
- package/package.json +15 -3
- package/dist/integrations/protocol-handler.d.ts +0 -59
- package/dist/integrations/protocol-handler.d.ts.map +0 -1
- package/dist/integrations/protocol-handler.js +0 -9
- package/dist/integrations/protocol-handler.js.map +0 -1
|
@@ -21,157 +21,172 @@ export const SIGIL_ERROR__PROTOCOL_NOT_ALLOWED = 0x1774; // 6004
|
|
|
21
21
|
export const SIGIL_ERROR__TRANSACTION_TOO_LARGE = 0x1775; // 6005
|
|
22
22
|
/** SpendingCapExceeded: Rolling 24h spending cap would be exceeded */
|
|
23
23
|
export const SIGIL_ERROR__SPENDING_CAP_EXCEEDED = 0x1776; // 6006
|
|
24
|
-
/** LeverageTooHigh: Leverage exceeds maximum allowed */
|
|
25
|
-
export const SIGIL_ERROR__LEVERAGE_TOO_HIGH = 0x1777; // 6007
|
|
26
24
|
/** SessionNotAuthorized: Session not authorized */
|
|
27
|
-
export const SIGIL_ERROR__SESSION_NOT_AUTHORIZED =
|
|
25
|
+
export const SIGIL_ERROR__SESSION_NOT_AUTHORIZED = 0x1777; // 6007
|
|
28
26
|
/** InvalidSession: Invalid session: does not belong to this vault */
|
|
29
|
-
export const SIGIL_ERROR__INVALID_SESSION =
|
|
27
|
+
export const SIGIL_ERROR__INVALID_SESSION = 0x1778; // 6008
|
|
30
28
|
/** TooManyAllowedProtocols: Policy configuration invalid: too many allowed protocols */
|
|
31
|
-
export const SIGIL_ERROR__TOO_MANY_ALLOWED_PROTOCOLS =
|
|
29
|
+
export const SIGIL_ERROR__TOO_MANY_ALLOWED_PROTOCOLS = 0x1779; // 6009
|
|
32
30
|
/** AgentAlreadyRegistered: Agent already registered for this vault */
|
|
33
|
-
export const SIGIL_ERROR__AGENT_ALREADY_REGISTERED =
|
|
31
|
+
export const SIGIL_ERROR__AGENT_ALREADY_REGISTERED = 0x177a; // 6010
|
|
34
32
|
/** NoAgentRegistered: No agent registered for this vault */
|
|
35
|
-
export const SIGIL_ERROR__NO_AGENT_REGISTERED =
|
|
33
|
+
export const SIGIL_ERROR__NO_AGENT_REGISTERED = 0x177b; // 6011
|
|
36
34
|
/** VaultNotFrozen: Vault is not frozen (expected frozen for reactivation) */
|
|
37
|
-
export const SIGIL_ERROR__VAULT_NOT_FROZEN =
|
|
35
|
+
export const SIGIL_ERROR__VAULT_NOT_FROZEN = 0x177c; // 6012
|
|
38
36
|
/** VaultAlreadyClosed: Vault is already closed */
|
|
39
|
-
export const SIGIL_ERROR__VAULT_ALREADY_CLOSED =
|
|
37
|
+
export const SIGIL_ERROR__VAULT_ALREADY_CLOSED = 0x177d; // 6013
|
|
40
38
|
/** InsufficientBalance: Insufficient vault balance for withdrawal */
|
|
41
|
-
export const SIGIL_ERROR__INSUFFICIENT_BALANCE =
|
|
39
|
+
export const SIGIL_ERROR__INSUFFICIENT_BALANCE = 0x177e; // 6014
|
|
42
40
|
/** DeveloperFeeTooHigh: Developer fee rate exceeds maximum (500 / 1,000,000 = 5 BPS) */
|
|
43
|
-
export const SIGIL_ERROR__DEVELOPER_FEE_TOO_HIGH =
|
|
41
|
+
export const SIGIL_ERROR__DEVELOPER_FEE_TOO_HIGH = 0x177f; // 6015
|
|
44
42
|
/** InvalidFeeDestination: Fee destination account invalid */
|
|
45
|
-
export const SIGIL_ERROR__INVALID_FEE_DESTINATION =
|
|
43
|
+
export const SIGIL_ERROR__INVALID_FEE_DESTINATION = 0x1780; // 6016
|
|
46
44
|
/** InvalidProtocolTreasury: Protocol treasury account does not match expected address */
|
|
47
|
-
export const SIGIL_ERROR__INVALID_PROTOCOL_TREASURY =
|
|
45
|
+
export const SIGIL_ERROR__INVALID_PROTOCOL_TREASURY = 0x1781; // 6017
|
|
48
46
|
/** InvalidAgentKey: Invalid agent: cannot be the zero address */
|
|
49
|
-
export const SIGIL_ERROR__INVALID_AGENT_KEY =
|
|
47
|
+
export const SIGIL_ERROR__INVALID_AGENT_KEY = 0x1782; // 6018
|
|
50
48
|
/** AgentIsOwner: Invalid agent: agent cannot be the vault owner */
|
|
51
|
-
export const SIGIL_ERROR__AGENT_IS_OWNER =
|
|
49
|
+
export const SIGIL_ERROR__AGENT_IS_OWNER = 0x1783; // 6019
|
|
52
50
|
/** Overflow: Arithmetic overflow */
|
|
53
|
-
export const SIGIL_ERROR__OVERFLOW =
|
|
51
|
+
export const SIGIL_ERROR__OVERFLOW = 0x1784; // 6020
|
|
54
52
|
/** InvalidTokenAccount: Token account does not belong to vault or has wrong mint */
|
|
55
|
-
export const SIGIL_ERROR__INVALID_TOKEN_ACCOUNT =
|
|
53
|
+
export const SIGIL_ERROR__INVALID_TOKEN_ACCOUNT = 0x1785; // 6021
|
|
56
54
|
/** TimelockNotExpired: Timelock period has not expired yet */
|
|
57
|
-
export const SIGIL_ERROR__TIMELOCK_NOT_EXPIRED =
|
|
55
|
+
export const SIGIL_ERROR__TIMELOCK_NOT_EXPIRED = 0x1786; // 6022
|
|
58
56
|
/** NoTimelockConfigured: No timelock configured on this vault */
|
|
59
|
-
export const SIGIL_ERROR__NO_TIMELOCK_CONFIGURED =
|
|
57
|
+
export const SIGIL_ERROR__NO_TIMELOCK_CONFIGURED = 0x1787; // 6023
|
|
60
58
|
/** DestinationNotAllowed: Destination not in allowed list */
|
|
61
|
-
export const SIGIL_ERROR__DESTINATION_NOT_ALLOWED =
|
|
59
|
+
export const SIGIL_ERROR__DESTINATION_NOT_ALLOWED = 0x1788; // 6024
|
|
62
60
|
/** TooManyDestinations: Too many destinations (max 10) */
|
|
63
|
-
export const SIGIL_ERROR__TOO_MANY_DESTINATIONS =
|
|
61
|
+
export const SIGIL_ERROR__TOO_MANY_DESTINATIONS = 0x1789; // 6025
|
|
64
62
|
/** InvalidProtocolMode: Invalid protocol mode (must be 0, 1, or 2) */
|
|
65
|
-
export const SIGIL_ERROR__INVALID_PROTOCOL_MODE =
|
|
66
|
-
/** InvalidNonSpendingAmount: Non-spending action must have amount = 0 */
|
|
67
|
-
export const SIGIL_ERROR__INVALID_NON_SPENDING_AMOUNT = 0x178c; // 6028
|
|
63
|
+
export const SIGIL_ERROR__INVALID_PROTOCOL_MODE = 0x178a; // 6026
|
|
68
64
|
/** CpiCallNotAllowed: Instruction must be top-level (CPI calls not allowed) */
|
|
69
|
-
export const SIGIL_ERROR__CPI_CALL_NOT_ALLOWED =
|
|
65
|
+
export const SIGIL_ERROR__CPI_CALL_NOT_ALLOWED = 0x178b; // 6027
|
|
70
66
|
/** MissingFinalizeInstruction: Transaction must include finalize_session after validate */
|
|
71
|
-
export const SIGIL_ERROR__MISSING_FINALIZE_INSTRUCTION =
|
|
67
|
+
export const SIGIL_ERROR__MISSING_FINALIZE_INSTRUCTION = 0x178c; // 6028
|
|
72
68
|
/** NonTrackedSwapMustReturnStablecoin: Non-stablecoin swap must return stablecoin (balance did not increase) */
|
|
73
|
-
export const SIGIL_ERROR__NON_TRACKED_SWAP_MUST_RETURN_STABLECOIN =
|
|
69
|
+
export const SIGIL_ERROR__NON_TRACKED_SWAP_MUST_RETURN_STABLECOIN = 0x178d; // 6029
|
|
74
70
|
/** SwapSlippageExceeded: Swap slippage exceeds policy max_slippage_bps or quoted output is zero */
|
|
75
|
-
export const SIGIL_ERROR__SWAP_SLIPPAGE_EXCEEDED =
|
|
71
|
+
export const SIGIL_ERROR__SWAP_SLIPPAGE_EXCEEDED = 0x178e; // 6030
|
|
76
72
|
/** InvalidJupiterInstruction: Cannot parse Jupiter swap instruction data */
|
|
77
|
-
export const SIGIL_ERROR__INVALID_JUPITER_INSTRUCTION =
|
|
73
|
+
export const SIGIL_ERROR__INVALID_JUPITER_INSTRUCTION = 0x178f; // 6031
|
|
78
74
|
/** UnauthorizedTokenTransfer: Top-level SPL Token transfer not allowed between validate and finalize */
|
|
79
|
-
export const SIGIL_ERROR__UNAUTHORIZED_TOKEN_TRANSFER =
|
|
75
|
+
export const SIGIL_ERROR__UNAUTHORIZED_TOKEN_TRANSFER = 0x1790; // 6032
|
|
80
76
|
/** SlippageBpsTooHigh: Slippage BPS exceeds maximum (5000 = 50%) */
|
|
81
|
-
export const SIGIL_ERROR__SLIPPAGE_BPS_TOO_HIGH =
|
|
77
|
+
export const SIGIL_ERROR__SLIPPAGE_BPS_TOO_HIGH = 0x1791; // 6033
|
|
82
78
|
/** ProtocolMismatch: DeFi instruction program does not match declared target_protocol */
|
|
83
|
-
export const SIGIL_ERROR__PROTOCOL_MISMATCH =
|
|
79
|
+
export const SIGIL_ERROR__PROTOCOL_MISMATCH = 0x1792; // 6034
|
|
84
80
|
/** TooManyDeFiInstructions: Spending allows at most one DeFi instruction */
|
|
85
|
-
export const SIGIL_ERROR__TOO_MANY_DE_FI_INSTRUCTIONS =
|
|
81
|
+
export const SIGIL_ERROR__TOO_MANY_DE_FI_INSTRUCTIONS = 0x1793; // 6035
|
|
86
82
|
/** MaxAgentsReached: Maximum agents per vault reached (limit: 10) */
|
|
87
|
-
export const SIGIL_ERROR__MAX_AGENTS_REACHED =
|
|
83
|
+
export const SIGIL_ERROR__MAX_AGENTS_REACHED = 0x1794; // 6036
|
|
88
84
|
/** InsufficientPermissions: Agent lacks permission for this action type */
|
|
89
|
-
export const SIGIL_ERROR__INSUFFICIENT_PERMISSIONS =
|
|
85
|
+
export const SIGIL_ERROR__INSUFFICIENT_PERMISSIONS = 0x1795; // 6037
|
|
90
86
|
/** InvalidPermissions: Permission bitmask contains invalid bits */
|
|
91
|
-
export const SIGIL_ERROR__INVALID_PERMISSIONS =
|
|
87
|
+
export const SIGIL_ERROR__INVALID_PERMISSIONS = 0x1796; // 6038
|
|
92
88
|
/** EscrowNotActive: Escrow is not in Active status */
|
|
93
|
-
export const SIGIL_ERROR__ESCROW_NOT_ACTIVE =
|
|
89
|
+
export const SIGIL_ERROR__ESCROW_NOT_ACTIVE = 0x1797; // 6039
|
|
94
90
|
/** EscrowExpired: Escrow has expired */
|
|
95
|
-
export const SIGIL_ERROR__ESCROW_EXPIRED =
|
|
91
|
+
export const SIGIL_ERROR__ESCROW_EXPIRED = 0x1798; // 6040
|
|
96
92
|
/** EscrowNotExpired: Escrow has not expired yet */
|
|
97
|
-
export const SIGIL_ERROR__ESCROW_NOT_EXPIRED =
|
|
93
|
+
export const SIGIL_ERROR__ESCROW_NOT_EXPIRED = 0x1799; // 6041
|
|
98
94
|
/** InvalidEscrowVault: Invalid escrow vault */
|
|
99
|
-
export const SIGIL_ERROR__INVALID_ESCROW_VAULT =
|
|
95
|
+
export const SIGIL_ERROR__INVALID_ESCROW_VAULT = 0x179a; // 6042
|
|
100
96
|
/** EscrowConditionsNotMet: Escrow conditions not met */
|
|
101
|
-
export const SIGIL_ERROR__ESCROW_CONDITIONS_NOT_MET =
|
|
97
|
+
export const SIGIL_ERROR__ESCROW_CONDITIONS_NOT_MET = 0x179b; // 6043
|
|
102
98
|
/** EscrowDurationExceeded: Escrow duration exceeds maximum (30 days) */
|
|
103
|
-
export const SIGIL_ERROR__ESCROW_DURATION_EXCEEDED =
|
|
99
|
+
export const SIGIL_ERROR__ESCROW_DURATION_EXCEEDED = 0x179c; // 6044
|
|
104
100
|
/** InvalidConstraintConfig: Invalid constraint configuration: bounds exceeded */
|
|
105
|
-
export const SIGIL_ERROR__INVALID_CONSTRAINT_CONFIG =
|
|
101
|
+
export const SIGIL_ERROR__INVALID_CONSTRAINT_CONFIG = 0x179d; // 6045
|
|
106
102
|
/** ConstraintViolated: Instruction constraint violated */
|
|
107
|
-
export const SIGIL_ERROR__CONSTRAINT_VIOLATED =
|
|
103
|
+
export const SIGIL_ERROR__CONSTRAINT_VIOLATED = 0x179e; // 6046
|
|
108
104
|
/** InvalidConstraintsPda: Invalid constraints PDA: wrong owner or vault */
|
|
109
|
-
export const SIGIL_ERROR__INVALID_CONSTRAINTS_PDA =
|
|
105
|
+
export const SIGIL_ERROR__INVALID_CONSTRAINTS_PDA = 0x179f; // 6047
|
|
110
106
|
/** InvalidPendingConstraintsPda: Invalid pending constraints PDA: wrong owner or vault */
|
|
111
|
-
export const SIGIL_ERROR__INVALID_PENDING_CONSTRAINTS_PDA =
|
|
107
|
+
export const SIGIL_ERROR__INVALID_PENDING_CONSTRAINTS_PDA = 0x17a0; // 6048
|
|
112
108
|
/** AgentSpendLimitExceeded: Agent rolling 24h spend exceeds per-agent spending limit */
|
|
113
|
-
export const SIGIL_ERROR__AGENT_SPEND_LIMIT_EXCEEDED =
|
|
109
|
+
export const SIGIL_ERROR__AGENT_SPEND_LIMIT_EXCEEDED = 0x17a1; // 6049
|
|
114
110
|
/** OverlaySlotExhausted: Per-agent overlay is full; cannot register agent with spending limit */
|
|
115
|
-
export const SIGIL_ERROR__OVERLAY_SLOT_EXHAUSTED =
|
|
111
|
+
export const SIGIL_ERROR__OVERLAY_SLOT_EXHAUSTED = 0x17a2; // 6050
|
|
116
112
|
/** AgentSlotNotFound: Agent has per-agent spending limit but no overlay tracking slot */
|
|
117
|
-
export const SIGIL_ERROR__AGENT_SLOT_NOT_FOUND =
|
|
113
|
+
export const SIGIL_ERROR__AGENT_SLOT_NOT_FOUND = 0x17a3; // 6051
|
|
118
114
|
/** UnauthorizedTokenApproval: Unauthorized SPL Token Approve between validate and finalize */
|
|
119
|
-
export const SIGIL_ERROR__UNAUTHORIZED_TOKEN_APPROVAL =
|
|
115
|
+
export const SIGIL_ERROR__UNAUTHORIZED_TOKEN_APPROVAL = 0x17a4; // 6052
|
|
120
116
|
/** InvalidSessionExpiry: Session expiry slots out of range (10-450) */
|
|
121
|
-
export const SIGIL_ERROR__INVALID_SESSION_EXPIRY =
|
|
117
|
+
export const SIGIL_ERROR__INVALID_SESSION_EXPIRY = 0x17a5; // 6053
|
|
122
118
|
/** UnconstrainedProgramBlocked: Program has no constraint entry and strict mode is enabled */
|
|
123
|
-
export const SIGIL_ERROR__UNCONSTRAINED_PROGRAM_BLOCKED =
|
|
119
|
+
export const SIGIL_ERROR__UNCONSTRAINED_PROGRAM_BLOCKED = 0x17a6; // 6054
|
|
124
120
|
/** ProtocolCapExceeded: Per-protocol rolling 24h spending cap would be exceeded */
|
|
125
|
-
export const SIGIL_ERROR__PROTOCOL_CAP_EXCEEDED =
|
|
121
|
+
export const SIGIL_ERROR__PROTOCOL_CAP_EXCEEDED = 0x17a7; // 6055
|
|
126
122
|
/** ProtocolCapsMismatch: protocol_caps length must match protocols length when has_protocol_caps is true */
|
|
127
|
-
export const SIGIL_ERROR__PROTOCOL_CAPS_MISMATCH =
|
|
123
|
+
export const SIGIL_ERROR__PROTOCOL_CAPS_MISMATCH = 0x17a8; // 6056
|
|
128
124
|
/** ActiveEscrowsExist: Cannot close vault with active escrow deposits */
|
|
129
|
-
export const SIGIL_ERROR__ACTIVE_ESCROWS_EXIST =
|
|
125
|
+
export const SIGIL_ERROR__ACTIVE_ESCROWS_EXIST = 0x17a9; // 6057
|
|
130
126
|
/** ConstraintsNotClosed: Instruction constraints must be closed before closing vault */
|
|
131
|
-
export const SIGIL_ERROR__CONSTRAINTS_NOT_CLOSED =
|
|
127
|
+
export const SIGIL_ERROR__CONSTRAINTS_NOT_CLOSED = 0x17aa; // 6058
|
|
132
128
|
/** PendingPolicyExists: Pending policy update must be applied or cancelled before closing vault */
|
|
133
|
-
export const SIGIL_ERROR__PENDING_POLICY_EXISTS =
|
|
129
|
+
export const SIGIL_ERROR__PENDING_POLICY_EXISTS = 0x17ab; // 6059
|
|
134
130
|
/** AgentPaused: Agent is paused and cannot execute actions */
|
|
135
|
-
export const SIGIL_ERROR__AGENT_PAUSED =
|
|
131
|
+
export const SIGIL_ERROR__AGENT_PAUSED = 0x17ac; // 6060
|
|
136
132
|
/** AgentAlreadyPaused: Agent is already paused */
|
|
137
|
-
export const SIGIL_ERROR__AGENT_ALREADY_PAUSED =
|
|
133
|
+
export const SIGIL_ERROR__AGENT_ALREADY_PAUSED = 0x17ad; // 6061
|
|
138
134
|
/** AgentNotPaused: Agent is not paused */
|
|
139
|
-
export const SIGIL_ERROR__AGENT_NOT_PAUSED =
|
|
135
|
+
export const SIGIL_ERROR__AGENT_NOT_PAUSED = 0x17ae; // 6062
|
|
140
136
|
/** UnauthorizedPostFinalizeInstruction: Instructions after finalize_session must be ComputeBudget or SystemProgram only */
|
|
141
|
-
export const SIGIL_ERROR__UNAUTHORIZED_POST_FINALIZE_INSTRUCTION =
|
|
137
|
+
export const SIGIL_ERROR__UNAUTHORIZED_POST_FINALIZE_INSTRUCTION = 0x17af; // 6063
|
|
142
138
|
/** UnexpectedBalanceDecrease: Vault balance decreased more than delegated amount — potential CPI attack */
|
|
143
|
-
export const SIGIL_ERROR__UNEXPECTED_BALANCE_DECREASE =
|
|
139
|
+
export const SIGIL_ERROR__UNEXPECTED_BALANCE_DECREASE = 0x17b0; // 6064
|
|
144
140
|
/** TimelockTooShort: Timelock duration below minimum (1800 seconds / 30 minutes) */
|
|
145
|
-
export const SIGIL_ERROR__TIMELOCK_TOO_SHORT =
|
|
141
|
+
export const SIGIL_ERROR__TIMELOCK_TOO_SHORT = 0x17b1; // 6065
|
|
146
142
|
/** PolicyVersionMismatch: Policy version mismatch — policy changed since agent's last RPC read */
|
|
147
|
-
export const SIGIL_ERROR__POLICY_VERSION_MISMATCH =
|
|
148
|
-
/** PendingAgentPermsExists: A pending agent permissions update already exists for this agent */
|
|
149
|
-
export const SIGIL_ERROR__PENDING_AGENT_PERMS_EXISTS = 0x17b5; // 6069
|
|
150
|
-
/** PendingCloseConstraintsExists: A pending close constraints operation already exists for this vault */
|
|
151
|
-
export const SIGIL_ERROR__PENDING_CLOSE_CONSTRAINTS_EXISTS = 0x17b6; // 6070
|
|
143
|
+
export const SIGIL_ERROR__POLICY_VERSION_MISMATCH = 0x17b2; // 6066
|
|
152
144
|
/** ActiveSessionsExist: Cannot close vault with active sessions (finalize pending sessions first) */
|
|
153
|
-
export const SIGIL_ERROR__ACTIVE_SESSIONS_EXIST =
|
|
145
|
+
export const SIGIL_ERROR__ACTIVE_SESSIONS_EXIST = 0x17b3; // 6067
|
|
154
146
|
/** PostAssertionFailed: Post-execution assertion failed: account state did not satisfy constraint */
|
|
155
|
-
export const SIGIL_ERROR__POST_ASSERTION_FAILED =
|
|
147
|
+
export const SIGIL_ERROR__POST_ASSERTION_FAILED = 0x17b4; // 6068
|
|
156
148
|
/** InvalidPostAssertionIndex: Post-assertion constraint references invalid instruction index */
|
|
157
|
-
export const SIGIL_ERROR__INVALID_POST_ASSERTION_INDEX =
|
|
149
|
+
export const SIGIL_ERROR__INVALID_POST_ASSERTION_INDEX = 0x17b5; // 6069
|
|
158
150
|
/** UnauthorizedPreValidateInstruction: Non-infrastructure instruction detected before validate_and_authorize */
|
|
159
|
-
export const SIGIL_ERROR__UNAUTHORIZED_PRE_VALIDATE_INSTRUCTION =
|
|
151
|
+
export const SIGIL_ERROR__UNAUTHORIZED_PRE_VALIDATE_INSTRUCTION = 0x17b6; // 6070
|
|
160
152
|
/** SnapshotNotCaptured: Delta assertion snapshot was not captured in validate_and_authorize */
|
|
161
|
-
export const SIGIL_ERROR__SNAPSHOT_NOT_CAPTURED =
|
|
162
|
-
/** ConstraintIndexOutOfBounds: Constraint entry index out of bounds for zero-copy array */
|
|
163
|
-
export const SIGIL_ERROR__CONSTRAINT_INDEX_OUT_OF_BOUNDS = 0x17bc; // 6076
|
|
153
|
+
export const SIGIL_ERROR__SNAPSHOT_NOT_CAPTURED = 0x17b7; // 6071
|
|
164
154
|
/** InvalidConstraintOperator: Constraint operator value is not a valid ConstraintOperator discriminant */
|
|
165
|
-
export const SIGIL_ERROR__INVALID_CONSTRAINT_OPERATOR =
|
|
155
|
+
export const SIGIL_ERROR__INVALID_CONSTRAINT_OPERATOR = 0x17b8; // 6072
|
|
166
156
|
/** ConstraintsVaultMismatch: Zero-copy constraints account has wrong vault */
|
|
167
|
-
export const SIGIL_ERROR__CONSTRAINTS_VAULT_MISMATCH =
|
|
168
|
-
/** ConstraintEntryCountExceeded: Cannot pack entries: entry count exceeds MAX_CONSTRAINT_ENTRIES */
|
|
169
|
-
export const SIGIL_ERROR__CONSTRAINT_ENTRY_COUNT_EXCEEDED = 0x17bf; // 6079
|
|
157
|
+
export const SIGIL_ERROR__CONSTRAINTS_VAULT_MISMATCH = 0x17b9; // 6073
|
|
170
158
|
/** BlockedSplOpcode: SPL opcode is blocked at runtime and cannot be used in constraints */
|
|
171
|
-
export const SIGIL_ERROR__BLOCKED_SPL_OPCODE =
|
|
159
|
+
export const SIGIL_ERROR__BLOCKED_SPL_OPCODE = 0x17ba; // 6074
|
|
160
|
+
/** QueuedUpdateExpired: Queued update is too old (>MAX_APPLY_AGE_SLOTS) — re-queue to apply. Defends against durable-nonce pre-signing. */
|
|
161
|
+
export const SIGIL_ERROR__QUEUED_UPDATE_EXPIRED = 0x17bb; // 6075
|
|
162
|
+
/** AccountWritabilityMismatch: Account writability flag does not match constraint requirement */
|
|
163
|
+
export const SIGIL_ERROR__ACCOUNT_WRITABILITY_MISMATCH = 0x17bc; // 6076
|
|
164
|
+
/** SysvarScanBoundExceeded: Sysvar instruction scan exceeded the per-tx safety bound */
|
|
165
|
+
export const SIGIL_ERROR__SYSVAR_SCAN_BOUND_EXCEEDED = 0x17bd; // 6077
|
|
166
|
+
/** AsyncFulfillmentNotPermitted: Async-fulfillment program is not permitted in V1 (Jupiter Perps, Drift, Drift JIT). Spending cannot be measured because keeper submits the actual transfer in a separate transaction after finalize_session returns. */
|
|
167
|
+
export const SIGIL_ERROR__ASYNC_FULFILLMENT_NOT_PERMITTED = 0x17be; // 6078
|
|
168
|
+
/** ConstraintsAlreadyPopulated: Cannot clean an active constraints PDA; use queue+apply_close_constraints */
|
|
169
|
+
export const SIGIL_ERROR__CONSTRAINTS_ALREADY_POPULATED = 0x17bf; // 6079
|
|
170
|
+
/** OrphanPdaWrongOwner: PDA at constraints seeds is not program-owned */
|
|
171
|
+
export const SIGIL_ERROR__ORPHAN_PDA_WRONG_OWNER = 0x17c0; // 6080
|
|
172
|
+
/** OrphanPdaPopulated: PDA is fully populated; not an orphan */
|
|
173
|
+
export const SIGIL_ERROR__ORPHAN_PDA_POPULATED = 0x17c1; // 6081
|
|
174
|
+
/** ConfidentialTransferBlocked: Token-2022 ConfidentialTransfer not permitted between validate and finalize */
|
|
175
|
+
export const SIGIL_ERROR__CONFIDENTIAL_TRANSFER_BLOCKED = 0x17c2; // 6082
|
|
176
|
+
/** PermanentDelegateBlocked: Token-2022 PermanentDelegate not permitted between validate and finalize */
|
|
177
|
+
export const SIGIL_ERROR__PERMANENT_DELEGATE_BLOCKED = 0x17c3; // 6083
|
|
178
|
+
/** TransferHookBlocked: Token-2022 TransferHook not permitted between validate and finalize */
|
|
179
|
+
export const SIGIL_ERROR__TRANSFER_HOOK_BLOCKED = 0x17c4; // 6084
|
|
180
|
+
/** LamportDrainBlocked: Token-2022 destructive-balance ix (opcodes 38/45/46) not permitted between validate and finalize */
|
|
181
|
+
export const SIGIL_ERROR__LAMPORT_DRAIN_BLOCKED = 0x17c5; // 6085
|
|
182
|
+
/** BatchInstructionBlocked: Token-2022 Batch instruction (opcode 255) is blocked outright — wraps inner instructions and bypasses byte-0 blocklist */
|
|
183
|
+
export const SIGIL_ERROR__BATCH_INSTRUCTION_BLOCKED = 0x17c6; // 6086
|
|
184
|
+
/** InvalidDestinationMode: Invalid destination mode (must be 0 = Restricted or 1 = OpenWithCap) */
|
|
185
|
+
export const SIGIL_ERROR__INVALID_DESTINATION_MODE = 0x17c7; // 6087
|
|
172
186
|
let sigilErrorMessages;
|
|
173
187
|
if (process.env.NODE_ENV !== "production") {
|
|
174
188
|
sigilErrorMessages = {
|
|
189
|
+
[SIGIL_ERROR__ACCOUNT_WRITABILITY_MISMATCH]: `Account writability flag does not match constraint requirement`,
|
|
175
190
|
[SIGIL_ERROR__ACTIVE_ESCROWS_EXIST]: `Cannot close vault with active escrow deposits`,
|
|
176
191
|
[SIGIL_ERROR__ACTIVE_SESSIONS_EXIST]: `Cannot close vault with active sessions (finalize pending sessions first)`,
|
|
177
192
|
[SIGIL_ERROR__AGENT_ALREADY_PAUSED]: `Agent is already paused`,
|
|
@@ -181,9 +196,11 @@ if (process.env.NODE_ENV !== "production") {
|
|
|
181
196
|
[SIGIL_ERROR__AGENT_PAUSED]: `Agent is paused and cannot execute actions`,
|
|
182
197
|
[SIGIL_ERROR__AGENT_SLOT_NOT_FOUND]: `Agent has per-agent spending limit but no overlay tracking slot`,
|
|
183
198
|
[SIGIL_ERROR__AGENT_SPEND_LIMIT_EXCEEDED]: `Agent rolling 24h spend exceeds per-agent spending limit`,
|
|
199
|
+
[SIGIL_ERROR__ASYNC_FULFILLMENT_NOT_PERMITTED]: `Async-fulfillment program is not permitted in V1 (Jupiter Perps, Drift, Drift JIT). Spending cannot be measured because keeper submits the actual transfer in a separate transaction after finalize_session returns.`,
|
|
200
|
+
[SIGIL_ERROR__BATCH_INSTRUCTION_BLOCKED]: `Token-2022 Batch instruction (opcode 255) is blocked outright — wraps inner instructions and bypasses byte-0 blocklist`,
|
|
184
201
|
[SIGIL_ERROR__BLOCKED_SPL_OPCODE]: `SPL opcode is blocked at runtime and cannot be used in constraints`,
|
|
185
|
-
[
|
|
186
|
-
[
|
|
202
|
+
[SIGIL_ERROR__CONFIDENTIAL_TRANSFER_BLOCKED]: `Token-2022 ConfidentialTransfer not permitted between validate and finalize`,
|
|
203
|
+
[SIGIL_ERROR__CONSTRAINTS_ALREADY_POPULATED]: `Cannot clean an active constraints PDA; use queue+apply_close_constraints`,
|
|
187
204
|
[SIGIL_ERROR__CONSTRAINTS_NOT_CLOSED]: `Instruction constraints must be closed before closing vault`,
|
|
188
205
|
[SIGIL_ERROR__CONSTRAINTS_VAULT_MISMATCH]: `Zero-copy constraints account has wrong vault`,
|
|
189
206
|
[SIGIL_ERROR__CONSTRAINT_VIOLATED]: `Instruction constraint violated`,
|
|
@@ -201,10 +218,10 @@ if (process.env.NODE_ENV !== "production") {
|
|
|
201
218
|
[SIGIL_ERROR__INVALID_CONSTRAINT_CONFIG]: `Invalid constraint configuration: bounds exceeded`,
|
|
202
219
|
[SIGIL_ERROR__INVALID_CONSTRAINT_OPERATOR]: `Constraint operator value is not a valid ConstraintOperator discriminant`,
|
|
203
220
|
[SIGIL_ERROR__INVALID_CONSTRAINTS_PDA]: `Invalid constraints PDA: wrong owner or vault`,
|
|
221
|
+
[SIGIL_ERROR__INVALID_DESTINATION_MODE]: `Invalid destination mode (must be 0 = Restricted or 1 = OpenWithCap)`,
|
|
204
222
|
[SIGIL_ERROR__INVALID_ESCROW_VAULT]: `Invalid escrow vault`,
|
|
205
223
|
[SIGIL_ERROR__INVALID_FEE_DESTINATION]: `Fee destination account invalid`,
|
|
206
224
|
[SIGIL_ERROR__INVALID_JUPITER_INSTRUCTION]: `Cannot parse Jupiter swap instruction data`,
|
|
207
|
-
[SIGIL_ERROR__INVALID_NON_SPENDING_AMOUNT]: `Non-spending action must have amount = 0`,
|
|
208
225
|
[SIGIL_ERROR__INVALID_PENDING_CONSTRAINTS_PDA]: `Invalid pending constraints PDA: wrong owner or vault`,
|
|
209
226
|
[SIGIL_ERROR__INVALID_PERMISSIONS]: `Permission bitmask contains invalid bits`,
|
|
210
227
|
[SIGIL_ERROR__INVALID_POST_ASSERTION_INDEX]: `Post-assertion constraint references invalid instruction index`,
|
|
@@ -213,34 +230,38 @@ if (process.env.NODE_ENV !== "production") {
|
|
|
213
230
|
[SIGIL_ERROR__INVALID_SESSION]: `Invalid session: does not belong to this vault`,
|
|
214
231
|
[SIGIL_ERROR__INVALID_SESSION_EXPIRY]: `Session expiry slots out of range (10-450)`,
|
|
215
232
|
[SIGIL_ERROR__INVALID_TOKEN_ACCOUNT]: `Token account does not belong to vault or has wrong mint`,
|
|
216
|
-
[
|
|
233
|
+
[SIGIL_ERROR__LAMPORT_DRAIN_BLOCKED]: `Token-2022 destructive-balance ix (opcodes 38/45/46) not permitted between validate and finalize`,
|
|
217
234
|
[SIGIL_ERROR__MAX_AGENTS_REACHED]: `Maximum agents per vault reached (limit: 10)`,
|
|
218
235
|
[SIGIL_ERROR__MISSING_FINALIZE_INSTRUCTION]: `Transaction must include finalize_session after validate`,
|
|
219
236
|
[SIGIL_ERROR__NO_AGENT_REGISTERED]: `No agent registered for this vault`,
|
|
220
237
|
[SIGIL_ERROR__NON_TRACKED_SWAP_MUST_RETURN_STABLECOIN]: `Non-stablecoin swap must return stablecoin (balance did not increase)`,
|
|
221
238
|
[SIGIL_ERROR__NO_TIMELOCK_CONFIGURED]: `No timelock configured on this vault`,
|
|
239
|
+
[SIGIL_ERROR__ORPHAN_PDA_POPULATED]: `PDA is fully populated; not an orphan`,
|
|
240
|
+
[SIGIL_ERROR__ORPHAN_PDA_WRONG_OWNER]: `PDA at constraints seeds is not program-owned`,
|
|
222
241
|
[SIGIL_ERROR__OVERFLOW]: `Arithmetic overflow`,
|
|
223
242
|
[SIGIL_ERROR__OVERLAY_SLOT_EXHAUSTED]: `Per-agent overlay is full; cannot register agent with spending limit`,
|
|
224
|
-
[SIGIL_ERROR__PENDING_AGENT_PERMS_EXISTS]: `A pending agent permissions update already exists for this agent`,
|
|
225
|
-
[SIGIL_ERROR__PENDING_CLOSE_CONSTRAINTS_EXISTS]: `A pending close constraints operation already exists for this vault`,
|
|
226
243
|
[SIGIL_ERROR__PENDING_POLICY_EXISTS]: `Pending policy update must be applied or cancelled before closing vault`,
|
|
244
|
+
[SIGIL_ERROR__PERMANENT_DELEGATE_BLOCKED]: `Token-2022 PermanentDelegate not permitted between validate and finalize`,
|
|
227
245
|
[SIGIL_ERROR__POLICY_VERSION_MISMATCH]: `Policy version mismatch — policy changed since agent's last RPC read`,
|
|
228
246
|
[SIGIL_ERROR__POST_ASSERTION_FAILED]: `Post-execution assertion failed: account state did not satisfy constraint`,
|
|
229
247
|
[SIGIL_ERROR__PROTOCOL_CAP_EXCEEDED]: `Per-protocol rolling 24h spending cap would be exceeded`,
|
|
230
248
|
[SIGIL_ERROR__PROTOCOL_CAPS_MISMATCH]: `protocol_caps length must match protocols length when has_protocol_caps is true`,
|
|
231
249
|
[SIGIL_ERROR__PROTOCOL_MISMATCH]: `DeFi instruction program does not match declared target_protocol`,
|
|
232
250
|
[SIGIL_ERROR__PROTOCOL_NOT_ALLOWED]: `Protocol not allowed by policy`,
|
|
251
|
+
[SIGIL_ERROR__QUEUED_UPDATE_EXPIRED]: `Queued update is too old (>MAX_APPLY_AGE_SLOTS) — re-queue to apply. Defends against durable-nonce pre-signing.`,
|
|
233
252
|
[SIGIL_ERROR__SESSION_NOT_AUTHORIZED]: `Session not authorized`,
|
|
234
253
|
[SIGIL_ERROR__SLIPPAGE_BPS_TOO_HIGH]: `Slippage BPS exceeds maximum (5000 = 50%)`,
|
|
235
254
|
[SIGIL_ERROR__SNAPSHOT_NOT_CAPTURED]: `Delta assertion snapshot was not captured in validate_and_authorize`,
|
|
236
255
|
[SIGIL_ERROR__SPENDING_CAP_EXCEEDED]: `Rolling 24h spending cap would be exceeded`,
|
|
237
256
|
[SIGIL_ERROR__SWAP_SLIPPAGE_EXCEEDED]: `Swap slippage exceeds policy max_slippage_bps or quoted output is zero`,
|
|
257
|
+
[SIGIL_ERROR__SYSVAR_SCAN_BOUND_EXCEEDED]: `Sysvar instruction scan exceeded the per-tx safety bound`,
|
|
238
258
|
[SIGIL_ERROR__TIMELOCK_NOT_EXPIRED]: `Timelock period has not expired yet`,
|
|
239
259
|
[SIGIL_ERROR__TIMELOCK_TOO_SHORT]: `Timelock duration below minimum (1800 seconds / 30 minutes)`,
|
|
240
260
|
[SIGIL_ERROR__TOO_MANY_ALLOWED_PROTOCOLS]: `Policy configuration invalid: too many allowed protocols`,
|
|
241
261
|
[SIGIL_ERROR__TOO_MANY_DE_FI_INSTRUCTIONS]: `Spending allows at most one DeFi instruction`,
|
|
242
262
|
[SIGIL_ERROR__TOO_MANY_DESTINATIONS]: `Too many destinations (max 10)`,
|
|
243
263
|
[SIGIL_ERROR__TRANSACTION_TOO_LARGE]: `Transaction exceeds maximum single transaction size`,
|
|
264
|
+
[SIGIL_ERROR__TRANSFER_HOOK_BLOCKED]: `Token-2022 TransferHook not permitted between validate and finalize`,
|
|
244
265
|
[SIGIL_ERROR__UNAUTHORIZED_AGENT]: `Unauthorized: signer is not the registered agent`,
|
|
245
266
|
[SIGIL_ERROR__UNAUTHORIZED_OWNER]: `Unauthorized: signer is not the vault owner`,
|
|
246
267
|
[SIGIL_ERROR__UNAUTHORIZED_POST_FINALIZE_INSTRUCTION]: `Instructions after finalize_session must be ComputeBudget or SystemProgram only`,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sigil.js","sourceRoot":"","sources":["../../../src/generated/errors/sigil.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,cAAc,GAIf,MAAM,aAAa,CAAC;AACrB,OAAO,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AwC,CAAC,EAAE,8DAA8D;QAC1G,CAAC,wCAAwC,CAAC,EAAE,wEAAwE;QACpH,CAAC,0CAA0C,CAAC,EAAE,4DAA4D;QAC1G,CAAC,wCAAwC,CAAC,EAAE,2EAA2E;QACvH,CAAC,8BAA8B,CAAC,EAAE,0DAA0D;QAC5F,CAAC,iCAAiC,CAAC,EAAE,yBAAyB;QAC9D,CAAC,6BAA6B,CAAC,EAAE,qBAAqB;QACtD,CAAC,6BAA6B,CAAC,EAAE,wDAAwD;KAC1F,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,oBAAoB,CAAC,IAAgB;IACnD,IAAI,OAAO,CAAC,GAAG,CAAC,QAAQ,KAAK,YAAY,EAAE,CAAC;QAC1C,OAAQ,kBAAiD,CAAC,IAAI,CAAC,CAAC;IAClE,CAAC;IAED,OAAO,oDAAoD,CAAC;AAC9D,CAAC;AAED,MAAM,UAAU,YAAY,CAC1B,KAAc,EACd,kBAEC,EACD,IAAwB;IAGxB,OAAO,cAAc,CACnB,KAAK,EACL,kBAAkB,EAClB,qBAAqB,EACrB,IAAI,CACL,CAAC;AACJ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"event-discriminators.d.ts","sourceRoot":"","sources":["../../src/generated/event-discriminators.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,uBAAuB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"event-discriminators.d.ts","sourceRoot":"","sources":["../../src/generated/event-discriminators.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,uBAAuB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAuC1D,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// AUTO-GENERATED by codama.mjs — do not edit manually.
|
|
2
2
|
// Re-run `pnpm run codama` after any Rust event changes.
|
|
3
3
|
//
|
|
4
|
-
// Source: target/idl/sigil.json (
|
|
4
|
+
// Source: target/idl/sigil.json (38 events)
|
|
5
5
|
// Discriminator = SHA256("event:<EventName>")[0..8]
|
|
6
6
|
export const EVENT_DISCRIMINATOR_MAP = {
|
|
7
7
|
"555a3bda7e08b33f": "ActionAuthorized",
|
|
@@ -28,6 +28,7 @@ export const EVENT_DISCRIMINATOR_MAP = {
|
|
|
28
28
|
"9dd1645f3b640344": "FundsDeposited",
|
|
29
29
|
"3882e69a235c0b76": "FundsWithdrawn",
|
|
30
30
|
"08aa63e81fd8391a": "InstructionConstraintsCreated",
|
|
31
|
+
"a1ea93831fa39119": "OrphanConstraintsPdaCleaned",
|
|
31
32
|
"1b63c3c6ee3503b5": "PdaAllocated",
|
|
32
33
|
"43975f4f0c0b33f2": "PdaExtended",
|
|
33
34
|
"68590564b4ca3449": "PolicyChangeApplied",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"event-discriminators.js","sourceRoot":"","sources":["../../src/generated/event-discriminators.ts"],"names":[],"mappings":"AAAA,uDAAuD;AACvD,yDAAyD;AACzD,EAAE;AACF,4CAA4C;AAC5C,oDAAoD;AAEpD,MAAM,CAAC,MAAM,uBAAuB,GAA2B;IAC7D,kBAAkB,EAAE,kBAAkB;IACtC,kBAAkB,EAAE,kBAAkB;IACtC,kBAAkB,EAAE,+BAA+B;IACnD,kBAAkB,EAAE,iCAAiC;IACrD,kBAAkB,EAAE,8BAA8B;IAClD,kBAAkB,EAAE,iBAAiB;IACrC,kBAAkB,EAAE,cAAc;IAClC,kBAAkB,EAAE,wBAAwB;IAC5C,kBAAkB,EAAE,uBAAuB;IAC3C,kBAAkB,EAAE,oBAAoB;IACxC,kBAAkB,EAAE,yBAAyB;IAC7C,kBAAkB,EAAE,2BAA2B;IAC/C,kBAAkB,EAAE,wBAAwB;IAC5C,kBAAkB,EAAE,0BAA0B;IAC9C,kBAAkB,EAAE,4BAA4B;IAChD,kBAAkB,EAAE,yBAAyB;IAC7C,kBAAkB,EAAE,mBAAmB;IACvC,kBAAkB,EAAE,eAAe;IACnC,kBAAkB,EAAE,gBAAgB;IACpC,kBAAkB,EAAE,eAAe;IACnC,kBAAkB,EAAE,eAAe;IACnC,kBAAkB,EAAE,gBAAgB;IACpC,kBAAkB,EAAE,gBAAgB;IACpC,kBAAkB,EAAE,+BAA+B;IACnD,kBAAkB,EAAE,cAAc;IAClC,kBAAkB,EAAE,aAAa;IACjC,kBAAkB,EAAE,qBAAqB;IACzC,kBAAkB,EAAE,uBAAuB;IAC3C,kBAAkB,EAAE,oBAAoB;IACxC,kBAAkB,EAAE,sBAAsB;IAC1C,kBAAkB,EAAE,sBAAsB;IAC1C,kBAAkB,EAAE,uBAAuB;IAC3C,kBAAkB,EAAE,kBAAkB;IACtC,kBAAkB,EAAE,aAAa;IACjC,kBAAkB,EAAE,cAAc;IAClC,kBAAkB,EAAE,aAAa;IACjC,kBAAkB,EAAE,kBAAkB;CACvC,CAAC"}
|
|
1
|
+
{"version":3,"file":"event-discriminators.js","sourceRoot":"","sources":["../../src/generated/event-discriminators.ts"],"names":[],"mappings":"AAAA,uDAAuD;AACvD,yDAAyD;AACzD,EAAE;AACF,4CAA4C;AAC5C,oDAAoD;AAEpD,MAAM,CAAC,MAAM,uBAAuB,GAA2B;IAC7D,kBAAkB,EAAE,kBAAkB;IACtC,kBAAkB,EAAE,kBAAkB;IACtC,kBAAkB,EAAE,+BAA+B;IACnD,kBAAkB,EAAE,iCAAiC;IACrD,kBAAkB,EAAE,8BAA8B;IAClD,kBAAkB,EAAE,iBAAiB;IACrC,kBAAkB,EAAE,cAAc;IAClC,kBAAkB,EAAE,wBAAwB;IAC5C,kBAAkB,EAAE,uBAAuB;IAC3C,kBAAkB,EAAE,oBAAoB;IACxC,kBAAkB,EAAE,yBAAyB;IAC7C,kBAAkB,EAAE,2BAA2B;IAC/C,kBAAkB,EAAE,wBAAwB;IAC5C,kBAAkB,EAAE,0BAA0B;IAC9C,kBAAkB,EAAE,4BAA4B;IAChD,kBAAkB,EAAE,yBAAyB;IAC7C,kBAAkB,EAAE,mBAAmB;IACvC,kBAAkB,EAAE,eAAe;IACnC,kBAAkB,EAAE,gBAAgB;IACpC,kBAAkB,EAAE,eAAe;IACnC,kBAAkB,EAAE,eAAe;IACnC,kBAAkB,EAAE,gBAAgB;IACpC,kBAAkB,EAAE,gBAAgB;IACpC,kBAAkB,EAAE,+BAA+B;IACnD,kBAAkB,EAAE,6BAA6B;IACjD,kBAAkB,EAAE,cAAc;IAClC,kBAAkB,EAAE,aAAa;IACjC,kBAAkB,EAAE,qBAAqB;IACzC,kBAAkB,EAAE,uBAAuB;IAC3C,kBAAkB,EAAE,oBAAoB;IACxC,kBAAkB,EAAE,sBAAsB;IAC1C,kBAAkB,EAAE,sBAAsB;IAC1C,kBAAkB,EAAE,uBAAuB;IAC3C,kBAAkB,EAAE,kBAAkB;IACtC,kBAAkB,EAAE,aAAa;IACjC,kBAAkB,EAAE,cAAc;IAClC,kBAAkB,EAAE,aAAa;IACjC,kBAAkB,EAAE,kBAAkB;CACvC,CAAC"}
|
|
@@ -0,0 +1,67 @@
|
|
|
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 ReadonlyUint8Array, type TransactionSigner, type WritableAccount, type WritableSignerAccount } from "@solana/kit";
|
|
9
|
+
import { SIGIL_PROGRAM_ADDRESS } from "../programs/index.js";
|
|
10
|
+
export declare const CLEANUP_ORPHAN_CONSTRAINTS_PDA_DISCRIMINATOR: Uint8Array<ArrayBuffer>;
|
|
11
|
+
export declare function getCleanupOrphanConstraintsPdaDiscriminatorBytes(): ReadonlyUint8Array<ArrayBuffer>;
|
|
12
|
+
export type CleanupOrphanConstraintsPdaInstruction<TProgram extends string = typeof SIGIL_PROGRAM_ADDRESS, TAccountOwner extends string | AccountMeta<string> = string, TAccountVault extends string | AccountMeta<string> = string, TAccountPolicy extends string | AccountMeta<string> = string, TAccountOrphanPda extends string | AccountMeta<string> = string, TRemainingAccounts extends readonly AccountMeta<string>[] = []> = Instruction<TProgram> & InstructionWithData<ReadonlyUint8Array> & InstructionWithAccounts<[
|
|
13
|
+
TAccountOwner extends string ? WritableSignerAccount<TAccountOwner> & AccountSignerMeta<TAccountOwner> : TAccountOwner,
|
|
14
|
+
TAccountVault extends string ? ReadonlyAccount<TAccountVault> : TAccountVault,
|
|
15
|
+
TAccountPolicy extends string ? ReadonlyAccount<TAccountPolicy> : TAccountPolicy,
|
|
16
|
+
TAccountOrphanPda extends string ? WritableAccount<TAccountOrphanPda> : TAccountOrphanPda,
|
|
17
|
+
...TRemainingAccounts
|
|
18
|
+
]>;
|
|
19
|
+
export type CleanupOrphanConstraintsPdaInstructionData = {
|
|
20
|
+
discriminator: ReadonlyUint8Array;
|
|
21
|
+
};
|
|
22
|
+
export type CleanupOrphanConstraintsPdaInstructionDataArgs = {};
|
|
23
|
+
export declare function getCleanupOrphanConstraintsPdaInstructionDataEncoder(): FixedSizeEncoder<CleanupOrphanConstraintsPdaInstructionDataArgs>;
|
|
24
|
+
export declare function getCleanupOrphanConstraintsPdaInstructionDataDecoder(): FixedSizeDecoder<CleanupOrphanConstraintsPdaInstructionData>;
|
|
25
|
+
export declare function getCleanupOrphanConstraintsPdaInstructionDataCodec(): FixedSizeCodec<CleanupOrphanConstraintsPdaInstructionDataArgs, CleanupOrphanConstraintsPdaInstructionData>;
|
|
26
|
+
export type CleanupOrphanConstraintsPdaAsyncInput<TAccountOwner extends string = string, TAccountVault extends string = string, TAccountPolicy extends string = string, TAccountOrphanPda extends string = string> = {
|
|
27
|
+
owner: TransactionSigner<TAccountOwner>;
|
|
28
|
+
vault: Address<TAccountVault>;
|
|
29
|
+
policy?: Address<TAccountPolicy>;
|
|
30
|
+
/**
|
|
31
|
+
* by this program, and discriminator zero (orphan from incomplete
|
|
32
|
+
* allocate+extend+populate chain).
|
|
33
|
+
*/
|
|
34
|
+
orphanPda?: Address<TAccountOrphanPda>;
|
|
35
|
+
};
|
|
36
|
+
export declare function getCleanupOrphanConstraintsPdaInstructionAsync<TAccountOwner extends string, TAccountVault extends string, TAccountPolicy extends string, TAccountOrphanPda extends string, TProgramAddress extends Address = typeof SIGIL_PROGRAM_ADDRESS>(input: CleanupOrphanConstraintsPdaAsyncInput<TAccountOwner, TAccountVault, TAccountPolicy, TAccountOrphanPda>, config?: {
|
|
37
|
+
programAddress?: TProgramAddress;
|
|
38
|
+
}): Promise<CleanupOrphanConstraintsPdaInstruction<TProgramAddress, TAccountOwner, TAccountVault, TAccountPolicy, TAccountOrphanPda>>;
|
|
39
|
+
export type CleanupOrphanConstraintsPdaInput<TAccountOwner extends string = string, TAccountVault extends string = string, TAccountPolicy extends string = string, TAccountOrphanPda extends string = string> = {
|
|
40
|
+
owner: TransactionSigner<TAccountOwner>;
|
|
41
|
+
vault: Address<TAccountVault>;
|
|
42
|
+
policy: Address<TAccountPolicy>;
|
|
43
|
+
/**
|
|
44
|
+
* by this program, and discriminator zero (orphan from incomplete
|
|
45
|
+
* allocate+extend+populate chain).
|
|
46
|
+
*/
|
|
47
|
+
orphanPda: Address<TAccountOrphanPda>;
|
|
48
|
+
};
|
|
49
|
+
export declare function getCleanupOrphanConstraintsPdaInstruction<TAccountOwner extends string, TAccountVault extends string, TAccountPolicy extends string, TAccountOrphanPda extends string, TProgramAddress extends Address = typeof SIGIL_PROGRAM_ADDRESS>(input: CleanupOrphanConstraintsPdaInput<TAccountOwner, TAccountVault, TAccountPolicy, TAccountOrphanPda>, config?: {
|
|
50
|
+
programAddress?: TProgramAddress;
|
|
51
|
+
}): CleanupOrphanConstraintsPdaInstruction<TProgramAddress, TAccountOwner, TAccountVault, TAccountPolicy, TAccountOrphanPda>;
|
|
52
|
+
export type ParsedCleanupOrphanConstraintsPdaInstruction<TProgram extends string = typeof SIGIL_PROGRAM_ADDRESS, TAccountMetas extends readonly AccountMeta[] = readonly AccountMeta[]> = {
|
|
53
|
+
programAddress: Address<TProgram>;
|
|
54
|
+
accounts: {
|
|
55
|
+
owner: TAccountMetas[0];
|
|
56
|
+
vault: TAccountMetas[1];
|
|
57
|
+
policy: TAccountMetas[2];
|
|
58
|
+
/**
|
|
59
|
+
* by this program, and discriminator zero (orphan from incomplete
|
|
60
|
+
* allocate+extend+populate chain).
|
|
61
|
+
*/
|
|
62
|
+
orphanPda: TAccountMetas[3];
|
|
63
|
+
};
|
|
64
|
+
data: CleanupOrphanConstraintsPdaInstructionData;
|
|
65
|
+
};
|
|
66
|
+
export declare function parseCleanupOrphanConstraintsPdaInstruction<TProgram extends string, TAccountMetas extends readonly AccountMeta[]>(instruction: Instruction<TProgram> & InstructionWithAccounts<TAccountMetas> & InstructionWithData<ReadonlyUint8Array>): ParsedCleanupOrphanConstraintsPdaInstruction<TProgram, TAccountMetas>;
|
|
67
|
+
//# sourceMappingURL=cleanupOrphanConstraintsPda.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cleanupOrphanConstraintsPda.d.ts","sourceRoot":"","sources":["../../../src/generated/instructions/cleanupOrphanConstraintsPda.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAaL,KAAK,WAAW,EAChB,KAAK,iBAAiB,EACtB,KAAK,OAAO,EACZ,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,mBAAmB,EACxB,KAAK,eAAe,EACpB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,eAAe,EACpB,KAAK,qBAAqB,EAC3B,MAAM,aAAa,CAAC;AAMrB,OAAO,EAAE,qBAAqB,EAAE,M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ama 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, getAddressEncoder, getBytesDecoder, getBytesEncoder, getProgramDerivedAddress, getStructDecoder, getStructEncoder, SOLANA_ERROR__PROGRAM_CLIENTS__INSUFFICIENT_ACCOUNT_METAS, SolanaError, transformEncoder, } from "@solana/kit";
|
|
9
|
+
import { getAccountMetaFactory, getAddressFromResolvedInstructionAccount, } from "@solana/program-client-core";
|
|
10
|
+
import { SIGIL_PROGRAM_ADDRESS } from "../programs/index.js";
|
|
11
|
+
export const CLEANUP_ORPHAN_CONSTRAINTS_PDA_DISCRIMINATOR = new Uint8Array([
|
|
12
|
+
69, 181, 93, 235, 116, 229, 116, 4,
|
|
13
|
+
]);
|
|
14
|
+
export function getCleanupOrphanConstraintsPdaDiscriminatorBytes() {
|
|
15
|
+
return fixEncoderSize(getBytesEncoder(), 8).encode(CLEANUP_ORPHAN_CONSTRAINTS_PDA_DISCRIMINATOR);
|
|
16
|
+
}
|
|
17
|
+
export function getCleanupOrphanConstraintsPdaInstructionDataEncoder() {
|
|
18
|
+
return transformEncoder(getStructEncoder([["discriminator", fixEncoderSize(getBytesEncoder(), 8)]]), (value) => ({
|
|
19
|
+
...value,
|
|
20
|
+
discriminator: CLEANUP_ORPHAN_CONSTRAINTS_PDA_DISCRIMINATOR,
|
|
21
|
+
}));
|
|
22
|
+
}
|
|
23
|
+
export function getCleanupOrphanConstraintsPdaInstructionDataDecoder() {
|
|
24
|
+
return getStructDecoder([
|
|
25
|
+
["discriminator", fixDecoderSize(getBytesDecoder(), 8)],
|
|
26
|
+
]);
|
|
27
|
+
}
|
|
28
|
+
export function getCleanupOrphanConstraintsPdaInstructionDataCodec() {
|
|
29
|
+
return combineCodec(getCleanupOrphanConstraintsPdaInstructionDataEncoder(), getCleanupOrphanConstraintsPdaInstructionDataDecoder());
|
|
30
|
+
}
|
|
31
|
+
export async function getCleanupOrphanConstraintsPdaInstructionAsync(input, config) {
|
|
32
|
+
// Program address.
|
|
33
|
+
const programAddress = config?.programAddress ?? SIGIL_PROGRAM_ADDRESS;
|
|
34
|
+
// Original accounts.
|
|
35
|
+
const originalAccounts = {
|
|
36
|
+
owner: { value: input.owner ?? null, isWritable: true },
|
|
37
|
+
vault: { value: input.vault ?? null, isWritable: false },
|
|
38
|
+
policy: { value: input.policy ?? null, isWritable: false },
|
|
39
|
+
orphanPda: { value: input.orphanPda ?? null, isWritable: true },
|
|
40
|
+
};
|
|
41
|
+
const accounts = originalAccounts;
|
|
42
|
+
// Resolve default values.
|
|
43
|
+
if (!accounts.policy.value) {
|
|
44
|
+
accounts.policy.value = await getProgramDerivedAddress({
|
|
45
|
+
programAddress,
|
|
46
|
+
seeds: [
|
|
47
|
+
getBytesEncoder().encode(new Uint8Array([112, 111, 108, 105, 99, 121])),
|
|
48
|
+
getAddressEncoder().encode(getAddressFromResolvedInstructionAccount("vault", accounts.vault.value)),
|
|
49
|
+
],
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
if (!accounts.orphanPda.value) {
|
|
53
|
+
accounts.orphanPda.value = await getProgramDerivedAddress({
|
|
54
|
+
programAddress,
|
|
55
|
+
seeds: [
|
|
56
|
+
getBytesEncoder().encode(new Uint8Array([99, 111, 110, 115, 116, 114, 97, 105, 110, 116, 115])),
|
|
57
|
+
getAddressEncoder().encode(getAddressFromResolvedInstructionAccount("vault", accounts.vault.value)),
|
|
58
|
+
],
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
62
|
+
return Object.freeze({
|
|
63
|
+
accounts: [
|
|
64
|
+
getAccountMeta("owner", accounts.owner),
|
|
65
|
+
getAccountMeta("vault", accounts.vault),
|
|
66
|
+
getAccountMeta("policy", accounts.policy),
|
|
67
|
+
getAccountMeta("orphanPda", accounts.orphanPda),
|
|
68
|
+
],
|
|
69
|
+
data: getCleanupOrphanConstraintsPdaInstructionDataEncoder().encode({}),
|
|
70
|
+
programAddress,
|
|
71
|
+
});
|
|
72
|
+
}
|
|
73
|
+
export function getCleanupOrphanConstraintsPdaInstruction(input, config) {
|
|
74
|
+
// Program address.
|
|
75
|
+
const programAddress = config?.programAddress ?? SIGIL_PROGRAM_ADDRESS;
|
|
76
|
+
// Original accounts.
|
|
77
|
+
const originalAccounts = {
|
|
78
|
+
owner: { value: input.owner ?? null, isWritable: true },
|
|
79
|
+
vault: { value: input.vault ?? null, isWritable: false },
|
|
80
|
+
policy: { value: input.policy ?? null, isWritable: false },
|
|
81
|
+
orphanPda: { value: input.orphanPda ?? null, isWritable: true },
|
|
82
|
+
};
|
|
83
|
+
const accounts = originalAccounts;
|
|
84
|
+
const getAccountMeta = getAccountMetaFactory(programAddress, "programId");
|
|
85
|
+
return Object.freeze({
|
|
86
|
+
accounts: [
|
|
87
|
+
getAccountMeta("owner", accounts.owner),
|
|
88
|
+
getAccountMeta("vault", accounts.vault),
|
|
89
|
+
getAccountMeta("policy", accounts.policy),
|
|
90
|
+
getAccountMeta("orphanPda", accounts.orphanPda),
|
|
91
|
+
],
|
|
92
|
+
data: getCleanupOrphanConstraintsPdaInstructionDataEncoder().encode({}),
|
|
93
|
+
programAddress,
|
|
94
|
+
});
|
|
95
|
+
}
|
|
96
|
+
export function parseCleanupOrphanConstraintsPdaInstruction(instruction) {
|
|
97
|
+
if (instruction.accounts.length < 4) {
|
|
98
|
+
throw new SolanaError(SOLANA_ERROR__PROGRAM_CLIENTS__INSUFFICIENT_ACCOUNT_METAS, {
|
|
99
|
+
actualAccountMetas: instruction.accounts.length,
|
|
100
|
+
expectedAccountMetas: 4,
|
|
101
|
+
});
|
|
102
|
+
}
|
|
103
|
+
let accountIndex = 0;
|
|
104
|
+
const getNextAccount = () => {
|
|
105
|
+
const accountMeta = instruction.accounts[accountIndex];
|
|
106
|
+
accountIndex += 1;
|
|
107
|
+
return accountMeta;
|
|
108
|
+
};
|
|
109
|
+
return {
|
|
110
|
+
programAddress: instruction.programAddress,
|
|
111
|
+
accounts: {
|
|
112
|
+
owner: getNextAccount(),
|
|
113
|
+
vault: getNextAccount(),
|
|
114
|
+
policy: getNextAccount(),
|
|
115
|
+
orphanPda: getNextAccount(),
|
|
116
|
+
},
|
|
117
|
+
data: getCleanupOrphanConstraintsPdaInstructionDataDecoder().decode(instruction.data),
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
//# sourceMappingURL=cleanupOrphanConstraintsPda.js.map
|