@chainlink/ccip-sdk 0.95.0 → 0.97.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/all-chains.d.ts +23 -0
- package/dist/all-chains.d.ts.map +1 -0
- package/dist/all-chains.js +24 -0
- package/dist/all-chains.js.map +1 -0
- package/dist/api/index.d.ts +31 -19
- package/dist/api/index.d.ts.map +1 -1
- package/dist/api/index.js +46 -25
- package/dist/api/index.js.map +1 -1
- package/dist/api/types.d.ts +24 -30
- package/dist/api/types.d.ts.map +1 -1
- package/dist/aptos/exec.d.ts +2 -2
- package/dist/aptos/exec.d.ts.map +1 -1
- package/dist/aptos/exec.js.map +1 -1
- package/dist/aptos/hasher.d.ts.map +1 -1
- package/dist/aptos/hasher.js +1 -1
- package/dist/aptos/hasher.js.map +1 -1
- package/dist/aptos/index.d.ts +43 -15
- package/dist/aptos/index.d.ts.map +1 -1
- package/dist/aptos/index.js +112 -105
- package/dist/aptos/index.js.map +1 -1
- package/dist/aptos/types.d.ts +2 -19
- package/dist/aptos/types.d.ts.map +1 -1
- package/dist/aptos/types.js +0 -11
- package/dist/aptos/types.js.map +1 -1
- package/dist/chain.d.ts +734 -174
- package/dist/chain.d.ts.map +1 -1
- package/dist/chain.js +216 -31
- package/dist/chain.js.map +1 -1
- package/dist/commits.d.ts +4 -6
- package/dist/commits.d.ts.map +1 -1
- package/dist/commits.js +4 -4
- package/dist/commits.js.map +1 -1
- package/dist/errors/CCIPError.d.ts +33 -4
- package/dist/errors/CCIPError.d.ts.map +1 -1
- package/dist/errors/CCIPError.js +33 -4
- package/dist/errors/CCIPError.js.map +1 -1
- package/dist/errors/codes.d.ts +5 -0
- package/dist/errors/codes.d.ts.map +1 -1
- package/dist/errors/codes.js +5 -1
- package/dist/errors/codes.js.map +1 -1
- package/dist/errors/index.d.ts +2 -2
- package/dist/errors/index.d.ts.map +1 -1
- package/dist/errors/index.js +2 -2
- package/dist/errors/index.js.map +1 -1
- package/dist/errors/recovery.d.ts.map +1 -1
- package/dist/errors/recovery.js +6 -1
- package/dist/errors/recovery.js.map +1 -1
- package/dist/errors/specialized.d.ts +1702 -121
- package/dist/errors/specialized.d.ts.map +1 -1
- package/dist/errors/specialized.js +1729 -125
- package/dist/errors/specialized.js.map +1 -1
- package/dist/errors/utils.d.ts.map +1 -1
- package/dist/errors/utils.js +0 -1
- package/dist/errors/utils.js.map +1 -1
- package/dist/evm/abi/OffRamp_2_0.d.ts +764 -0
- package/dist/evm/abi/OffRamp_2_0.d.ts.map +1 -0
- package/dist/evm/abi/OffRamp_2_0.js +744 -0
- package/dist/evm/abi/OffRamp_2_0.js.map +1 -0
- package/dist/evm/abi/OnRamp_2_0.d.ts +925 -0
- package/dist/evm/abi/OnRamp_2_0.d.ts.map +1 -0
- package/dist/evm/abi/OnRamp_2_0.js +992 -0
- package/dist/evm/abi/OnRamp_2_0.js.map +1 -0
- package/dist/evm/const.d.ts +12 -2
- package/dist/evm/const.d.ts.map +1 -1
- package/dist/evm/const.js +8 -2
- package/dist/evm/const.js.map +1 -1
- package/dist/evm/errors.d.ts.map +1 -1
- package/dist/evm/errors.js +7 -2
- package/dist/evm/errors.js.map +1 -1
- package/dist/evm/extra-args.d.ts +25 -0
- package/dist/evm/extra-args.d.ts.map +1 -0
- package/dist/evm/extra-args.js +309 -0
- package/dist/evm/extra-args.js.map +1 -0
- package/dist/evm/gas.d.ts.map +1 -1
- package/dist/evm/gas.js +7 -12
- package/dist/evm/gas.js.map +1 -1
- package/dist/evm/hasher.d.ts.map +1 -1
- package/dist/evm/hasher.js +23 -13
- package/dist/evm/hasher.js.map +1 -1
- package/dist/evm/index.d.ts +140 -35
- package/dist/evm/index.d.ts.map +1 -1
- package/dist/evm/index.js +306 -226
- package/dist/evm/index.js.map +1 -1
- package/dist/evm/messages.d.ts +59 -5
- package/dist/evm/messages.d.ts.map +1 -1
- package/dist/evm/messages.js +210 -0
- package/dist/evm/messages.js.map +1 -1
- package/dist/evm/offchain.js.map +1 -1
- package/dist/evm/types.d.ts +7 -2
- package/dist/evm/types.d.ts.map +1 -1
- package/dist/evm/types.js +22 -1
- package/dist/evm/types.js.map +1 -1
- package/dist/execution.d.ts +62 -22
- package/dist/execution.d.ts.map +1 -1
- package/dist/execution.js +102 -51
- package/dist/execution.js.map +1 -1
- package/dist/extra-args.d.ts +113 -4
- package/dist/extra-args.d.ts.map +1 -1
- package/dist/extra-args.js +38 -3
- package/dist/extra-args.js.map +1 -1
- package/dist/gas.d.ts +31 -5
- package/dist/gas.d.ts.map +1 -1
- package/dist/gas.js +43 -9
- package/dist/gas.js.map +1 -1
- package/dist/index.d.ts +11 -10
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -8
- package/dist/index.js.map +1 -1
- package/dist/requests.d.ts +101 -22
- package/dist/requests.d.ts.map +1 -1
- package/dist/requests.js +115 -24
- package/dist/requests.js.map +1 -1
- package/dist/selectors.d.ts.map +1 -1
- package/dist/selectors.js +24 -0
- package/dist/selectors.js.map +1 -1
- package/dist/shared/bcs-codecs.d.ts +61 -0
- package/dist/shared/bcs-codecs.d.ts.map +1 -0
- package/dist/shared/bcs-codecs.js +102 -0
- package/dist/shared/bcs-codecs.js.map +1 -0
- package/dist/shared/constants.d.ts +3 -0
- package/dist/shared/constants.d.ts.map +1 -0
- package/dist/shared/constants.js +3 -0
- package/dist/shared/constants.js.map +1 -0
- package/dist/solana/exec.d.ts +2 -2
- package/dist/solana/exec.d.ts.map +1 -1
- package/dist/solana/exec.js.map +1 -1
- package/dist/solana/index.d.ts +148 -30
- package/dist/solana/index.d.ts.map +1 -1
- package/dist/solana/index.js +137 -44
- package/dist/solana/index.js.map +1 -1
- package/dist/sui/hasher.d.ts.map +1 -1
- package/dist/sui/hasher.js +1 -1
- package/dist/sui/hasher.js.map +1 -1
- package/dist/sui/index.d.ts +49 -19
- package/dist/sui/index.d.ts.map +1 -1
- package/dist/sui/index.js +76 -43
- package/dist/sui/index.js.map +1 -1
- package/dist/sui/manuallyExec/encoder.d.ts +2 -2
- package/dist/sui/manuallyExec/encoder.d.ts.map +1 -1
- package/dist/sui/manuallyExec/encoder.js.map +1 -1
- package/dist/sui/manuallyExec/index.d.ts +2 -2
- package/dist/sui/manuallyExec/index.d.ts.map +1 -1
- package/dist/ton/exec.d.ts +2 -2
- package/dist/ton/exec.d.ts.map +1 -1
- package/dist/ton/exec.js.map +1 -1
- package/dist/ton/index.d.ts +66 -27
- package/dist/ton/index.d.ts.map +1 -1
- package/dist/ton/index.js +172 -47
- package/dist/ton/index.js.map +1 -1
- package/dist/ton/send.d.ts +52 -0
- package/dist/ton/send.d.ts.map +1 -0
- package/dist/ton/send.js +166 -0
- package/dist/ton/send.js.map +1 -0
- package/dist/ton/types.d.ts +2 -2
- package/dist/ton/types.d.ts.map +1 -1
- package/dist/ton/types.js.map +1 -1
- package/dist/types.d.ts +148 -12
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +6 -1
- package/dist/types.js.map +1 -1
- package/dist/utils.d.ts +79 -4
- package/dist/utils.d.ts.map +1 -1
- package/dist/utils.js +92 -7
- package/dist/utils.js.map +1 -1
- package/package.json +16 -11
- package/src/all-chains.ts +26 -0
- package/src/api/index.ts +58 -34
- package/src/api/types.ts +24 -31
- package/src/aptos/exec.ts +2 -2
- package/src/aptos/hasher.ts +1 -1
- package/src/aptos/index.ts +127 -129
- package/src/aptos/types.ts +2 -15
- package/src/chain.ts +837 -191
- package/src/commits.ts +9 -9
- package/src/errors/CCIPError.ts +33 -4
- package/src/errors/codes.ts +5 -1
- package/src/errors/index.ts +2 -1
- package/src/errors/recovery.ts +9 -1
- package/src/errors/specialized.ts +1745 -132
- package/src/errors/utils.ts +0 -1
- package/src/evm/abi/OffRamp_2_0.ts +743 -0
- package/src/evm/abi/OnRamp_2_0.ts +991 -0
- package/src/evm/const.ts +10 -3
- package/src/evm/errors.ts +6 -2
- package/src/evm/extra-args.ts +360 -0
- package/src/evm/gas.ts +14 -13
- package/src/evm/hasher.ts +30 -18
- package/src/evm/index.ts +376 -281
- package/src/evm/messages.ts +323 -11
- package/src/evm/offchain.ts +2 -2
- package/src/evm/types.ts +20 -2
- package/src/execution.ts +126 -71
- package/src/extra-args.ts +118 -4
- package/src/gas.ts +44 -11
- package/src/index.ts +14 -11
- package/src/requests.ts +128 -24
- package/src/selectors.ts +24 -0
- package/src/shared/bcs-codecs.ts +132 -0
- package/src/shared/constants.ts +2 -0
- package/src/solana/exec.ts +4 -4
- package/src/solana/index.ts +170 -82
- package/src/sui/hasher.ts +1 -1
- package/src/sui/index.ts +88 -56
- package/src/sui/manuallyExec/encoder.ts +2 -2
- package/src/sui/manuallyExec/index.ts +2 -2
- package/src/ton/exec.ts +2 -2
- package/src/ton/index.ts +220 -58
- package/src/ton/send.ts +222 -0
- package/src/ton/types.ts +2 -2
- package/src/types.ts +173 -30
- package/src/utils.ts +91 -7
- package/dist/aptos/utils.d.ts +0 -12
- package/dist/aptos/utils.d.ts.map +0 -1
- package/dist/aptos/utils.js +0 -15
- package/dist/aptos/utils.js.map +0 -1
- package/src/aptos/utils.ts +0 -24
package/src/commits.ts
CHANGED
|
@@ -2,33 +2,33 @@ import type { PickDeep } from 'type-fest'
|
|
|
2
2
|
|
|
3
3
|
import type { Chain, ChainStatic, LogFilter } from './chain.ts'
|
|
4
4
|
import { CCIPCommitNotFoundError } from './errors/index.ts'
|
|
5
|
-
import { type
|
|
5
|
+
import { type CCIPRequest, type CCIPVerifications, CCIPVersion } from './types.ts'
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Look for a CommitReport at dest for given CCIPRequest
|
|
9
9
|
* Provides a basic/generic implementation, but subclasses of Chain may override with more specific
|
|
10
|
-
* logic in Chain.
|
|
10
|
+
* logic in Chain.getVerifications method
|
|
11
11
|
*
|
|
12
12
|
* @param dest - Destination network provider
|
|
13
|
-
* @param
|
|
13
|
+
* @param offRamp - Commit store address
|
|
14
14
|
* @param request - CCIP request info
|
|
15
15
|
* @param hints - Additional filtering hints
|
|
16
16
|
* @returns CCIP commit info
|
|
17
17
|
**/
|
|
18
|
-
export async function
|
|
18
|
+
export async function getOnchainCommitReport(
|
|
19
19
|
dest: Chain,
|
|
20
|
-
|
|
20
|
+
offRamp: string,
|
|
21
21
|
{
|
|
22
22
|
lane,
|
|
23
23
|
message,
|
|
24
24
|
tx: { timestamp: requestTimestamp },
|
|
25
|
-
}: PickDeep<CCIPRequest, 'lane' | '
|
|
26
|
-
hints?: Pick<LogFilter, 'page' | 'watch'
|
|
27
|
-
): Promise<
|
|
25
|
+
}: PickDeep<CCIPRequest, 'lane' | `message.${'sequenceNumber' | 'messageId'}` | 'tx.timestamp'>,
|
|
26
|
+
hints?: Pick<LogFilter, 'page' | 'watch' | 'startBlock'>,
|
|
27
|
+
): Promise<CCIPVerifications> {
|
|
28
28
|
for await (const log of dest.getLogs({
|
|
29
29
|
...hints,
|
|
30
30
|
...(!hints?.startBlock ? { startTime: requestTimestamp } : { startBlock: hints.startBlock }),
|
|
31
|
-
address:
|
|
31
|
+
address: offRamp,
|
|
32
32
|
topics: [lane.version < CCIPVersion.V1_6 ? 'ReportAccepted' : 'CommitReportAccepted'],
|
|
33
33
|
})) {
|
|
34
34
|
const reports = (dest.constructor as ChainStatic).decodeCommits(log, lane)
|
package/src/errors/CCIPError.ts
CHANGED
|
@@ -41,7 +41,13 @@ export class CCIPError extends Error {
|
|
|
41
41
|
|
|
42
42
|
override readonly name: string = 'CCIPError'
|
|
43
43
|
|
|
44
|
-
/**
|
|
44
|
+
/**
|
|
45
|
+
* Creates a CCIPError with code, message, and options.
|
|
46
|
+
*
|
|
47
|
+
* @param code - Machine-readable error code
|
|
48
|
+
* @param message - Human-readable error message
|
|
49
|
+
* @param options - Additional error options (cause, context, isTransient, etc.)
|
|
50
|
+
*/
|
|
45
51
|
constructor(code: CCIPErrorCode, message: string, options?: CCIPErrorOptions) {
|
|
46
52
|
super(message, { cause: options?.cause })
|
|
47
53
|
Object.setPrototypeOf(this, new.target.prototype)
|
|
@@ -55,7 +61,15 @@ export class CCIPError extends Error {
|
|
|
55
61
|
Error.captureStackTrace(this, this.constructor)
|
|
56
62
|
}
|
|
57
63
|
|
|
58
|
-
/**
|
|
64
|
+
/**
|
|
65
|
+
* Type guard for CCIPError.
|
|
66
|
+
*
|
|
67
|
+
* Prefer this over `instanceof` to handle the dual package hazard
|
|
68
|
+
* when multiple versions of the SDK may be present.
|
|
69
|
+
*
|
|
70
|
+
* @param error - The error to check
|
|
71
|
+
* @returns True if the error is a CCIPError instance
|
|
72
|
+
*/
|
|
59
73
|
static isCCIPError(error: unknown): error is CCIPError {
|
|
60
74
|
return (
|
|
61
75
|
error instanceof CCIPError ||
|
|
@@ -63,7 +77,15 @@ export class CCIPError extends Error {
|
|
|
63
77
|
)
|
|
64
78
|
}
|
|
65
79
|
|
|
66
|
-
/**
|
|
80
|
+
/**
|
|
81
|
+
* Wraps an unknown caught value in a CCIPError.
|
|
82
|
+
*
|
|
83
|
+
* Useful for normalizing errors in catch blocks.
|
|
84
|
+
*
|
|
85
|
+
* @param error - The error to wrap
|
|
86
|
+
* @param code - Optional error code (defaults to 'UNKNOWN')
|
|
87
|
+
* @returns A CCIPError wrapping the original error
|
|
88
|
+
*/
|
|
67
89
|
static from(error: unknown, code?: CCIPErrorCode): CCIPError {
|
|
68
90
|
if (error instanceof CCIPError) return error
|
|
69
91
|
if (error instanceof Error) {
|
|
@@ -72,7 +94,14 @@ export class CCIPError extends Error {
|
|
|
72
94
|
return new CCIPError(code ?? 'UNKNOWN', String(error))
|
|
73
95
|
}
|
|
74
96
|
|
|
75
|
-
/**
|
|
97
|
+
/**
|
|
98
|
+
* Serializes the error for logging.
|
|
99
|
+
*
|
|
100
|
+
* Use this instead of `JSON.stringify(error)` directly, as Error properties
|
|
101
|
+
* are non-enumerable and would be lost.
|
|
102
|
+
*
|
|
103
|
+
* @returns An object containing all error properties
|
|
104
|
+
*/
|
|
76
105
|
toJSON(): Record<string, unknown> {
|
|
77
106
|
return {
|
|
78
107
|
name: this.name,
|
package/src/errors/codes.ts
CHANGED
|
@@ -4,6 +4,7 @@ export const CCIPErrorCode = {
|
|
|
4
4
|
CHAIN_NOT_FOUND: 'CHAIN_NOT_FOUND',
|
|
5
5
|
CHAIN_SELECTOR_NOT_FOUND: 'CHAIN_SELECTOR_NOT_FOUND',
|
|
6
6
|
CHAIN_FAMILY_UNSUPPORTED: 'CHAIN_FAMILY_UNSUPPORTED',
|
|
7
|
+
NETWORK_FAMILY_UNSUPPORTED: 'NETWORK_FAMILY_UNSUPPORTED',
|
|
7
8
|
METHOD_UNSUPPORTED: 'METHOD_UNSUPPORTED',
|
|
8
9
|
CHAIN_FAMILY_MISMATCH: 'CHAIN_FAMILY_MISMATCH',
|
|
9
10
|
APTOS_NETWORK_UNKNOWN: 'APTOS_NETWORK_UNKNOWN',
|
|
@@ -80,6 +81,7 @@ export const CCIPErrorCode = {
|
|
|
80
81
|
TOKEN_NOT_IN_REGISTRY: 'TOKEN_NOT_IN_REGISTRY',
|
|
81
82
|
TOKEN_NOT_CONFIGURED: 'TOKEN_NOT_CONFIGURED',
|
|
82
83
|
TOKEN_NOT_REGISTERED: 'TOKEN_NOT_REGISTERED',
|
|
84
|
+
TOKEN_REMOTE_NOT_CONFIGURED: 'TOKEN_REMOTE_NOT_CONFIGURED',
|
|
83
85
|
TOKEN_DECIMALS_INSUFFICIENT: 'TOKEN_DECIMALS_INSUFFICIENT',
|
|
84
86
|
TOKEN_INVALID_SPL: 'TOKEN_INVALID_SPL',
|
|
85
87
|
TOKEN_DATA_PARSE_FAILED: 'TOKEN_DATA_PARSE_FAILED',
|
|
@@ -89,6 +91,7 @@ export const CCIPErrorCode = {
|
|
|
89
91
|
TOKEN_POOL_STATE_NOT_FOUND: 'TOKEN_POOL_STATE_NOT_FOUND',
|
|
90
92
|
TOKEN_POOL_INFO_NOT_FOUND: 'TOKEN_POOL_INFO_NOT_FOUND',
|
|
91
93
|
TOKEN_ACCOUNT_NOT_FOUND: 'TOKEN_ACCOUNT_NOT_FOUND',
|
|
94
|
+
LEGACY_TOKEN_POOLS_UNSUPPORTED: 'LEGACY_TOKEN_POOLS_UNSUPPORTED',
|
|
92
95
|
|
|
93
96
|
// Wallet & Signer
|
|
94
97
|
WALLET_NOT_SIGNER: 'WALLET_NOT_SIGNER',
|
|
@@ -135,6 +138,7 @@ export const CCIPErrorCode = {
|
|
|
135
138
|
APTOS_TX_TYPE_UNEXPECTED: 'APTOS_TX_TYPE_UNEXPECTED',
|
|
136
139
|
APTOS_ADDRESS_MODULE_REQUIRED: 'APTOS_ADDRESS_MODULE_REQUIRED',
|
|
137
140
|
APTOS_HASHER_VERSION_UNSUPPORTED: 'APTOS_HASHER_VERSION_UNSUPPORTED',
|
|
141
|
+
APTOS_TOPIC_INVALID: 'APTOS_TOPIC_INVALID',
|
|
138
142
|
|
|
139
143
|
// HTTP & RPC
|
|
140
144
|
HTTP_ERROR: 'HTTP_ERROR',
|
|
@@ -153,6 +157,7 @@ export const CCIPErrorCode = {
|
|
|
153
157
|
|
|
154
158
|
// CLI & Validation
|
|
155
159
|
ARGUMENT_INVALID: 'ARGUMENT_INVALID',
|
|
160
|
+
INSUFFICIENT_BALANCE: 'INSUFFICIENT_BALANCE',
|
|
156
161
|
|
|
157
162
|
// Internal
|
|
158
163
|
NOT_IMPLEMENTED: 'NOT_IMPLEMENTED',
|
|
@@ -171,7 +176,6 @@ export const TRANSIENT_ERROR_CODES = new Set<CCIPErrorCode>([
|
|
|
171
176
|
CCIPErrorCode.TRANSACTION_NOT_FOUND,
|
|
172
177
|
CCIPErrorCode.BLOCK_TIME_NOT_FOUND,
|
|
173
178
|
CCIPErrorCode.TRANSACTION_NOT_FINALIZED,
|
|
174
|
-
CCIPErrorCode.MESSAGE_NOT_FOUND_IN_TX,
|
|
175
179
|
CCIPErrorCode.MESSAGE_ID_NOT_FOUND,
|
|
176
180
|
CCIPErrorCode.MESSAGE_BATCH_INCOMPLETE,
|
|
177
181
|
CCIPErrorCode.COMMIT_NOT_FOUND,
|
package/src/errors/index.ts
CHANGED
|
@@ -144,6 +144,7 @@ export {
|
|
|
144
144
|
// Specialized errors - Sui-specific
|
|
145
145
|
export {
|
|
146
146
|
CCIPSuiHasherVersionUnsupportedError,
|
|
147
|
+
CCIPSuiLogInvalidError,
|
|
147
148
|
CCIPSuiMessageVersionInvalidError,
|
|
148
149
|
} from './specialized.ts'
|
|
149
150
|
|
|
@@ -179,7 +180,7 @@ export { CCIPAddressInvalidEvmError } from './specialized.ts'
|
|
|
179
180
|
export { CCIPSourceChainUnsupportedError } from './specialized.ts'
|
|
180
181
|
|
|
181
182
|
// Specialized errors - CLI & Validation
|
|
182
|
-
export { CCIPArgumentInvalidError } from './specialized.ts'
|
|
183
|
+
export { CCIPArgumentInvalidError, CCIPInsufficientBalanceError } from './specialized.ts'
|
|
183
184
|
|
|
184
185
|
// HTTP Status codes (re-exported from root)
|
|
185
186
|
export { HttpStatus, isServerError, isTransientHttpStatus } from '../http-status.ts'
|
package/src/errors/recovery.ts
CHANGED
|
@@ -8,6 +8,8 @@ export const DEFAULT_RECOVERY_HINTS: Partial<Record<CCIPErrorCode, string>> = {
|
|
|
8
8
|
'Verify the chain selector is valid. Use networkInfo() to look up selectors.',
|
|
9
9
|
CHAIN_FAMILY_UNSUPPORTED:
|
|
10
10
|
'This chain family is not supported. Check the method documentation for supported chain families.',
|
|
11
|
+
NETWORK_FAMILY_UNSUPPORTED:
|
|
12
|
+
'This network family is not supported. Supported families: evm, solana, aptos, sui, ton.',
|
|
11
13
|
CHAIN_FAMILY_MISMATCH:
|
|
12
14
|
'Use the correct Chain class for this chain family (e.g., EVMChain for EVM, SolanaChain for Solana).',
|
|
13
15
|
METHOD_UNSUPPORTED:
|
|
@@ -25,7 +27,7 @@ export const DEFAULT_RECOVERY_HINTS: Partial<Record<CCIPErrorCode, string>> = {
|
|
|
25
27
|
'Ensure the data is a valid CCIPSendRequested event log. Check the transaction on the source chain explorer.',
|
|
26
28
|
MESSAGE_CCIP_DECODE_FAILED:
|
|
27
29
|
'Ensure the log data is from a CCIPSendRequested event. Verify the source chain and transaction hash.',
|
|
28
|
-
MESSAGE_NOT_FOUND_IN_TX: 'No
|
|
30
|
+
MESSAGE_NOT_FOUND_IN_TX: 'No CCIP request event found in tx. Verify the transaction hash.',
|
|
29
31
|
MESSAGE_ID_NOT_FOUND: 'Wait and retry. The message may still be in transit (5-20 min typical).',
|
|
30
32
|
MESSAGE_ID_INVALID:
|
|
31
33
|
'Verify the message ID format. Must be a valid 32-byte hex string (0x-prefixed, 64 hex chars).',
|
|
@@ -96,6 +98,7 @@ export const DEFAULT_RECOVERY_HINTS: Partial<Record<CCIPErrorCode, string>> = {
|
|
|
96
98
|
TOKEN_NOT_IN_REGISTRY: 'Token not found in TokenAdminRegistry.',
|
|
97
99
|
TOKEN_NOT_CONFIGURED: 'Token is not configured in the registry.',
|
|
98
100
|
TOKEN_NOT_REGISTERED: 'Token is not registered in the TokenAdminRegistry.',
|
|
101
|
+
TOKEN_REMOTE_NOT_CONFIGURED: 'Remote network is not registered in TokenPool.',
|
|
99
102
|
TOKEN_DECIMALS_INSUFFICIENT: 'Destination token has insufficient decimals.',
|
|
100
103
|
TOKEN_INVALID_SPL: 'Invalid SPL token or Token-2022.',
|
|
101
104
|
TOKEN_DATA_PARSE_FAILED:
|
|
@@ -109,6 +112,8 @@ export const DEFAULT_RECOVERY_HINTS: Partial<Record<CCIPErrorCode, string>> = {
|
|
|
109
112
|
'Check that the token pool is deployed and configured for this lane. Verify supported tokens: https://docs.chain.link/ccip/directory',
|
|
110
113
|
TOKEN_ACCOUNT_NOT_FOUND:
|
|
111
114
|
'The token account does not exist for this holder. The holder has never held this token. You may treat this as zero balance.',
|
|
115
|
+
LEGACY_TOKEN_POOLS_UNSUPPORTED:
|
|
116
|
+
'Legacy token pools (CCIP <1.5) are not supported. Upgrade to CCIP 1.5+ token pools.',
|
|
112
117
|
|
|
113
118
|
WALLET_NOT_SIGNER: 'Provide a wallet with signing capability (Signer interface).',
|
|
114
119
|
WALLET_INVALID: 'Provide a valid Wallet instance.',
|
|
@@ -158,6 +163,8 @@ export const DEFAULT_RECOVERY_HINTS: Partial<Record<CCIPErrorCode, string>> = {
|
|
|
158
163
|
'Check that the transaction is a standard user transaction, not a script or module deployment.',
|
|
159
164
|
APTOS_ADDRESS_MODULE_REQUIRED: 'Provide an address with module for Aptos log filtering.',
|
|
160
165
|
APTOS_HASHER_VERSION_UNSUPPORTED: 'This hasher version is not supported for Aptos.',
|
|
166
|
+
APTOS_TOPIC_INVALID:
|
|
167
|
+
'Invalid Aptos event topic. Ensure the topic matches a known CCIP event type.',
|
|
161
168
|
|
|
162
169
|
HTTP_ERROR: 'HTTP request failed. 429 indicates rate limiting.',
|
|
163
170
|
RPC_NOT_FOUND: 'No RPC endpoint found. Configure an RPC URL.',
|
|
@@ -178,6 +185,7 @@ export const DEFAULT_RECOVERY_HINTS: Partial<Record<CCIPErrorCode, string>> = {
|
|
|
178
185
|
BORSH_METHOD_UNKNOWN: 'Unknown Borsh method.',
|
|
179
186
|
|
|
180
187
|
ARGUMENT_INVALID: 'Check the command-line argument format and requirements.',
|
|
188
|
+
INSUFFICIENT_BALANCE: 'Fund the wallet to cover the transaction fee.',
|
|
181
189
|
|
|
182
190
|
NOT_IMPLEMENTED: 'This feature is not yet implemented.',
|
|
183
191
|
UNKNOWN: 'An unknown error occurred. Check the error details.',
|