@actioncodes/protocol 2.0.21 → 2.0.23
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 +239 -146
- package/dist/adapters/SolanaAdapter.d.ts.map +1 -1
- package/dist/constants.d.ts +1 -1
- package/dist/errors.d.ts +5 -0
- package/dist/errors.d.ts.map +1 -1
- package/dist/index.cjs +2 -2
- package/dist/index.cjs.map +6 -6
- package/dist/index.js +2 -2
- package/dist/index.js.map +6 -6
- package/dist/utils/protocolMeta.d.ts +1 -0
- package/dist/utils/protocolMeta.d.ts.map +1 -1
- package/docs/ActionCodesProtocol/README.md +2 -2
- package/docs/ActionCodesProtocol/classes/ActionCodesProtocol.md +183 -33
- package/docs/README.md +425 -8
- package/docs/adapters/BaseChainAdapter/README.md +3 -4
- package/docs/adapters/BaseChainAdapter/classes/BaseChainAdapter.md +87 -20
- package/docs/adapters/BaseChainAdapter/interfaces/ChainAdapter.md +68 -12
- package/docs/adapters/BaseChainAdapter/type-aliases/SignFn.md +25 -0
- package/docs/adapters/SolanaAdapter/README.md +6 -3
- package/docs/adapters/SolanaAdapter/classes/SolanaAdapter.md +140 -43
- package/docs/adapters/SolanaAdapter/type-aliases/SolanaTransaction.md +3 -3
- package/docs/adapters/SolanaAdapter/variables/ADAPTER_CHAIN_NAME.md +11 -0
- package/docs/constants/README.md +2 -2
- package/docs/constants/variables/CODE_CHARSET_DIGITS.md +2 -2
- package/docs/constants/variables/CODE_DEFAULT_LENGTH.md +2 -2
- package/docs/constants/variables/CODE_MAX_LENGTH.md +2 -2
- package/docs/constants/variables/CODE_MIN_LENGTH.md +2 -2
- package/docs/constants/variables/PROTOCOL_META_MAX_BYTES.md +3 -3
- package/docs/constants/variables/PROTOCOL_NORMALIZATION.md +2 -2
- package/docs/constants/variables/SUPPORTED_CHAINS.md +9 -3
- package/docs/errors/README.md +4 -2
- package/docs/errors/classes/ExpiredCodeError.md +85 -21
- package/docs/errors/classes/InvalidAdapterError.md +751 -0
- package/docs/errors/classes/InvalidCodeFormatError.md +85 -21
- package/docs/errors/classes/InvalidPubkeyFormatError.md +85 -21
- package/docs/errors/classes/InvalidSignatureError.md +85 -21
- package/docs/errors/classes/MetaMismatchError.md +85 -21
- package/docs/errors/classes/MissingMetaError.md +85 -21
- package/docs/errors/classes/ProtocolError.md +75 -21
- package/docs/errors/classes/TransactionNotSignedByIntendedOwnerError.md +85 -21
- package/docs/errors/classes/TransactionNotSignedByIssuerError.md +755 -0
- package/docs/errors/enumerations/ProtocolErrorCode.md +39 -15
- package/docs/index/README.md +170 -14
- package/docs/modules.md +3 -3
- package/docs/strategy/DelegationStrategy/README.md +11 -0
- package/docs/strategy/DelegationStrategy/classes/DelegationStrategy.md +79 -0
- package/docs/strategy/WalletStrategy/README.md +2 -2
- package/docs/strategy/WalletStrategy/classes/WalletStrategy.md +22 -18
- package/docs/types/README.md +11 -3
- package/docs/types/interfaces/ActionCode.md +23 -26
- package/docs/types/interfaces/ActionCodeRevoke.md +93 -0
- package/docs/types/interfaces/CanonicalMessageParts.md +5 -13
- package/docs/types/interfaces/CanonicalRevokeMessageParts.md +33 -0
- package/docs/types/interfaces/CodeGenerationConfig.md +6 -6
- package/docs/types/interfaces/DelegatedActionCode.md +97 -0
- package/docs/types/interfaces/DelegatedActionCodeRevoke.md +105 -0
- package/docs/types/interfaces/DelegationProof.md +49 -0
- package/docs/types/type-aliases/Chain.md +11 -0
- package/docs/utils/canonical/README.md +6 -2
- package/docs/utils/canonical/functions/getCanonicalMessageParts.md +21 -0
- package/docs/utils/canonical/functions/serializeCanonical.md +3 -3
- package/docs/utils/canonical/functions/serializeCanonicalRevoke.md +21 -0
- package/docs/utils/canonical/functions/serializeDelegationProof.md +21 -0
- package/docs/utils/canonical/variables/CANONICAL_MESSAGE_PREFIX.md +3 -3
- package/docs/utils/canonical/variables/CANONICAL_MESSAGE_VERSION.md +3 -3
- package/docs/utils/canonical/variables/CANONICAL_REVOKE_MESSAGE_PREFIX.md +11 -0
- package/docs/utils/crypto/README.md +2 -3
- package/docs/utils/crypto/functions/base32EncodeCrockford.md +2 -2
- package/docs/utils/crypto/functions/codeHash.md +2 -2
- package/docs/utils/crypto/functions/digestToDigits.md +2 -2
- package/docs/utils/crypto/functions/hkdfSha256.md +2 -2
- package/docs/utils/crypto/functions/hmacSha256.md +2 -2
- package/docs/utils/crypto/functions/sha256.md +2 -2
- package/docs/utils/crypto/functions/truncateBits.md +2 -2
- package/docs/utils/protocolMeta/README.md +2 -2
- package/docs/utils/protocolMeta/functions/buildProtocolMeta.md +3 -3
- package/docs/utils/protocolMeta/functions/parseProtocolMeta.md +3 -3
- package/docs/utils/protocolMeta/functions/validateProtocolMetaFormat.md +3 -3
- package/docs/utils/protocolMeta/interfaces/ProtocolMetaFields.md +11 -3
- package/docs/utils/protocolMeta/variables/SCHEME.md +3 -3
- package/package.json +7 -7
- package/docs/adapters/BaseChainAdapter/interfaces/BaseContext.md +0 -17
- package/docs/adapters/BaseChainAdapter/type-aliases/ChainContext.md +0 -23
- package/docs/adapters/NodeCryptoAdapter/README.md +0 -15
- package/docs/adapters/NodeCryptoAdapter/classes/NodeCryptoAdapter.md +0 -254
- package/docs/adapters/NodeCryptoAdapter/type-aliases/NodeCryptoContext.md +0 -27
- package/docs/adapters/SolanaAdapter/type-aliases/SolanaContext.md +0 -27
- package/docs/types/interfaces/CodeGenerationResult.md +0 -25
- package/docs/utils/crypto/functions/generateRandomSecret.md +0 -15
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
[**@actioncodes/protocol
|
|
1
|
+
[**@actioncodes/protocol**](../../README.md)
|
|
2
2
|
|
|
3
3
|
***
|
|
4
4
|
|
|
5
|
-
[@actioncodes/protocol
|
|
5
|
+
[@actioncodes/protocol](../../modules.md) / [errors](../README.md) / InvalidSignatureError
|
|
6
6
|
|
|
7
7
|
# Class: InvalidSignatureError
|
|
8
8
|
|
|
9
|
-
Defined in: src/errors.ts:
|
|
9
|
+
Defined in: src/errors.ts:224
|
|
10
10
|
|
|
11
11
|
## Extends
|
|
12
12
|
|
|
@@ -18,7 +18,7 @@ Defined in: src/errors.ts:189
|
|
|
18
18
|
|
|
19
19
|
> **new InvalidSignatureError**(`reason`): `InvalidSignatureError`
|
|
20
20
|
|
|
21
|
-
Defined in: src/errors.ts:
|
|
21
|
+
Defined in: src/errors.ts:225
|
|
22
22
|
|
|
23
23
|
#### Parameters
|
|
24
24
|
|
|
@@ -54,7 +54,7 @@ The cause of the error.
|
|
|
54
54
|
|
|
55
55
|
> `readonly` **code**: [`ProtocolErrorCode`](../enumerations/ProtocolErrorCode.md)
|
|
56
56
|
|
|
57
|
-
Defined in: src/errors.ts:
|
|
57
|
+
Defined in: src/errors.ts:34
|
|
58
58
|
|
|
59
59
|
#### Inherited from
|
|
60
60
|
|
|
@@ -66,7 +66,7 @@ Defined in: src/errors.ts:29
|
|
|
66
66
|
|
|
67
67
|
> `readonly` `optional` **details**: `Record`\<`string`, `unknown`\>
|
|
68
68
|
|
|
69
|
-
Defined in: src/errors.ts:
|
|
69
|
+
Defined in: src/errors.ts:36
|
|
70
70
|
|
|
71
71
|
#### Inherited from
|
|
72
72
|
|
|
@@ -234,7 +234,7 @@ Create .stack property on a target object
|
|
|
234
234
|
|
|
235
235
|
> `static` **create**(`code`, `message`, `details?`): [`ProtocolError`](ProtocolError.md)
|
|
236
236
|
|
|
237
|
-
Defined in: src/errors.ts:
|
|
237
|
+
Defined in: src/errors.ts:149
|
|
238
238
|
|
|
239
239
|
#### Parameters
|
|
240
240
|
|
|
@@ -264,7 +264,7 @@ Defined in: src/errors.ts:127
|
|
|
264
264
|
|
|
265
265
|
> `static` **cryptoError**(`operation`, `reason`): [`ProtocolError`](ProtocolError.md)
|
|
266
266
|
|
|
267
|
-
Defined in: src/errors.ts:
|
|
267
|
+
Defined in: src/errors.ts:127
|
|
268
268
|
|
|
269
269
|
#### Parameters
|
|
270
270
|
|
|
@@ -290,7 +290,7 @@ Defined in: src/errors.ts:110
|
|
|
290
290
|
|
|
291
291
|
> `static` **expiredCode**(`code`, `expiresAt`, `currentTime`): [`ExpiredCodeError`](ExpiredCodeError.md)
|
|
292
292
|
|
|
293
|
-
Defined in: src/errors.ts:
|
|
293
|
+
Defined in: src/errors.ts:43
|
|
294
294
|
|
|
295
295
|
#### Parameters
|
|
296
296
|
|
|
@@ -316,11 +316,49 @@ Defined in: src/errors.ts:38
|
|
|
316
316
|
|
|
317
317
|
***
|
|
318
318
|
|
|
319
|
+
### invalidAdapter()
|
|
320
|
+
|
|
321
|
+
> `static` **invalidAdapter**(`adapter`): [`InvalidAdapterError`](InvalidAdapterError.md)
|
|
322
|
+
|
|
323
|
+
Defined in: src/errors.ts:144
|
|
324
|
+
|
|
325
|
+
#### Parameters
|
|
326
|
+
|
|
327
|
+
##### adapter
|
|
328
|
+
|
|
329
|
+
`string`
|
|
330
|
+
|
|
331
|
+
#### Returns
|
|
332
|
+
|
|
333
|
+
[`InvalidAdapterError`](InvalidAdapterError.md)
|
|
334
|
+
|
|
335
|
+
#### Inherited from
|
|
336
|
+
|
|
337
|
+
[`ProtocolError`](ProtocolError.md).[`invalidAdapter`](ProtocolError.md#invalidadapter)
|
|
338
|
+
|
|
339
|
+
***
|
|
340
|
+
|
|
341
|
+
### invalidCode()
|
|
342
|
+
|
|
343
|
+
> `static` **invalidCode**(): [`ProtocolError`](ProtocolError.md)
|
|
344
|
+
|
|
345
|
+
Defined in: src/errors.ts:47
|
|
346
|
+
|
|
347
|
+
#### Returns
|
|
348
|
+
|
|
349
|
+
[`ProtocolError`](ProtocolError.md)
|
|
350
|
+
|
|
351
|
+
#### Inherited from
|
|
352
|
+
|
|
353
|
+
[`ProtocolError`](ProtocolError.md).[`invalidCode`](ProtocolError.md#invalidcode)
|
|
354
|
+
|
|
355
|
+
***
|
|
356
|
+
|
|
319
357
|
### invalidCodeFormat()
|
|
320
358
|
|
|
321
359
|
> `static` **invalidCodeFormat**(`code`, `reason`): [`InvalidCodeFormatError`](InvalidCodeFormatError.md)
|
|
322
360
|
|
|
323
|
-
Defined in: src/errors.ts:
|
|
361
|
+
Defined in: src/errors.ts:55
|
|
324
362
|
|
|
325
363
|
#### Parameters
|
|
326
364
|
|
|
@@ -346,7 +384,7 @@ Defined in: src/errors.ts:42
|
|
|
346
384
|
|
|
347
385
|
> `static` **invalidDigest**(`reason`): [`ProtocolError`](ProtocolError.md)
|
|
348
386
|
|
|
349
|
-
Defined in: src/errors.ts:
|
|
387
|
+
Defined in: src/errors.ts:135
|
|
350
388
|
|
|
351
389
|
#### Parameters
|
|
352
390
|
|
|
@@ -368,7 +406,7 @@ Defined in: src/errors.ts:118
|
|
|
368
406
|
|
|
369
407
|
> `static` **invalidInput**(`field`, `value`, `reason`): [`ProtocolError`](ProtocolError.md)
|
|
370
408
|
|
|
371
|
-
Defined in: src/errors.ts:
|
|
409
|
+
Defined in: src/errors.ts:110
|
|
372
410
|
|
|
373
411
|
#### Parameters
|
|
374
412
|
|
|
@@ -398,7 +436,7 @@ Defined in: src/errors.ts:93
|
|
|
398
436
|
|
|
399
437
|
> `static` **invalidMetaFormat**(`reason`): [`ProtocolError`](ProtocolError.md)
|
|
400
438
|
|
|
401
|
-
Defined in: src/errors.ts:
|
|
439
|
+
Defined in: src/errors.ts:68
|
|
402
440
|
|
|
403
441
|
#### Parameters
|
|
404
442
|
|
|
@@ -420,7 +458,7 @@ Defined in: src/errors.ts:55
|
|
|
420
458
|
|
|
421
459
|
> `static` **invalidPubkeyFormat**(`pubkey`, `reason`): [`InvalidPubkeyFormatError`](InvalidPubkeyFormatError.md)
|
|
422
460
|
|
|
423
|
-
Defined in: src/errors.ts:
|
|
461
|
+
Defined in: src/errors.ts:105
|
|
424
462
|
|
|
425
463
|
#### Parameters
|
|
426
464
|
|
|
@@ -446,7 +484,7 @@ Defined in: src/errors.ts:88
|
|
|
446
484
|
|
|
447
485
|
> `static` **invalidSignature**(`reason`): `InvalidSignatureError`
|
|
448
486
|
|
|
449
|
-
Defined in: src/errors.ts:
|
|
487
|
+
Defined in: src/errors.ts:59
|
|
450
488
|
|
|
451
489
|
#### Parameters
|
|
452
490
|
|
|
@@ -468,7 +506,7 @@ Defined in: src/errors.ts:46
|
|
|
468
506
|
|
|
469
507
|
> `static` **invalidTransactionFormat**(`reason`): [`ProtocolError`](ProtocolError.md)
|
|
470
508
|
|
|
471
|
-
Defined in: src/errors.ts:
|
|
509
|
+
Defined in: src/errors.ts:97
|
|
472
510
|
|
|
473
511
|
#### Parameters
|
|
474
512
|
|
|
@@ -542,7 +580,7 @@ True if the value is an instance of Error, false otherwise
|
|
|
542
580
|
|
|
543
581
|
> `static` **metaMismatch**(`expected`, `actual`, `field`): [`MetaMismatchError`](MetaMismatchError.md)
|
|
544
582
|
|
|
545
|
-
Defined in: src/errors.ts:
|
|
583
|
+
Defined in: src/errors.ts:76
|
|
546
584
|
|
|
547
585
|
#### Parameters
|
|
548
586
|
|
|
@@ -572,7 +610,7 @@ Defined in: src/errors.ts:63
|
|
|
572
610
|
|
|
573
611
|
> `static` **metaTooLarge**(`maxBytes`, `actualBytes`): [`ProtocolError`](ProtocolError.md)
|
|
574
612
|
|
|
575
|
-
Defined in: src/errors.ts:
|
|
613
|
+
Defined in: src/errors.ts:80
|
|
576
614
|
|
|
577
615
|
#### Parameters
|
|
578
616
|
|
|
@@ -598,7 +636,7 @@ Defined in: src/errors.ts:67
|
|
|
598
636
|
|
|
599
637
|
> `static` **missingMeta**(): [`MissingMetaError`](MissingMetaError.md)
|
|
600
638
|
|
|
601
|
-
Defined in: src/errors.ts:
|
|
639
|
+
Defined in: src/errors.ts:64
|
|
602
640
|
|
|
603
641
|
#### Returns
|
|
604
642
|
|
|
@@ -614,7 +652,7 @@ Defined in: src/errors.ts:51
|
|
|
614
652
|
|
|
615
653
|
> `static` **missingRequiredField**(`field`): [`ProtocolError`](ProtocolError.md)
|
|
616
654
|
|
|
617
|
-
Defined in: src/errors.ts:
|
|
655
|
+
Defined in: src/errors.ts:118
|
|
618
656
|
|
|
619
657
|
#### Parameters
|
|
620
658
|
|
|
@@ -666,7 +704,7 @@ https://v8.dev/docs/stack-trace-api#customizing-stack-traces
|
|
|
666
704
|
|
|
667
705
|
> `static` **transactionNotSignedByIntendedOwner**(`intended`, `actualSigners`): [`TransactionNotSignedByIntendedOwnerError`](TransactionNotSignedByIntendedOwnerError.md)
|
|
668
706
|
|
|
669
|
-
Defined in: src/errors.ts:
|
|
707
|
+
Defined in: src/errors.ts:89
|
|
670
708
|
|
|
671
709
|
#### Parameters
|
|
672
710
|
|
|
@@ -685,3 +723,29 @@ Defined in: src/errors.ts:76
|
|
|
685
723
|
#### Inherited from
|
|
686
724
|
|
|
687
725
|
[`ProtocolError`](ProtocolError.md).[`transactionNotSignedByIntendedOwner`](ProtocolError.md#transactionnotsignedbyintendedowner)
|
|
726
|
+
|
|
727
|
+
***
|
|
728
|
+
|
|
729
|
+
### transactionNotSignedByIssuer()
|
|
730
|
+
|
|
731
|
+
> `static` **transactionNotSignedByIssuer**(`issuer`, `actualSigners`): [`TransactionNotSignedByIssuerError`](TransactionNotSignedByIssuerError.md)
|
|
732
|
+
|
|
733
|
+
Defined in: src/errors.ts:93
|
|
734
|
+
|
|
735
|
+
#### Parameters
|
|
736
|
+
|
|
737
|
+
##### issuer
|
|
738
|
+
|
|
739
|
+
`string`
|
|
740
|
+
|
|
741
|
+
##### actualSigners
|
|
742
|
+
|
|
743
|
+
`string`[]
|
|
744
|
+
|
|
745
|
+
#### Returns
|
|
746
|
+
|
|
747
|
+
[`TransactionNotSignedByIssuerError`](TransactionNotSignedByIssuerError.md)
|
|
748
|
+
|
|
749
|
+
#### Inherited from
|
|
750
|
+
|
|
751
|
+
[`ProtocolError`](ProtocolError.md).[`transactionNotSignedByIssuer`](ProtocolError.md#transactionnotsignedbyissuer)
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
[**@actioncodes/protocol
|
|
1
|
+
[**@actioncodes/protocol**](../../README.md)
|
|
2
2
|
|
|
3
3
|
***
|
|
4
4
|
|
|
5
|
-
[@actioncodes/protocol
|
|
5
|
+
[@actioncodes/protocol](../../modules.md) / [errors](../README.md) / MetaMismatchError
|
|
6
6
|
|
|
7
7
|
# Class: MetaMismatchError
|
|
8
8
|
|
|
9
|
-
Defined in: src/errors.ts:
|
|
9
|
+
Defined in: src/errors.ts:176
|
|
10
10
|
|
|
11
11
|
## Extends
|
|
12
12
|
|
|
@@ -18,7 +18,7 @@ Defined in: src/errors.ts:154
|
|
|
18
18
|
|
|
19
19
|
> **new MetaMismatchError**(`expected`, `actual`, `field`): `MetaMismatchError`
|
|
20
20
|
|
|
21
|
-
Defined in: src/errors.ts:
|
|
21
|
+
Defined in: src/errors.ts:177
|
|
22
22
|
|
|
23
23
|
#### Parameters
|
|
24
24
|
|
|
@@ -62,7 +62,7 @@ The cause of the error.
|
|
|
62
62
|
|
|
63
63
|
> `readonly` **code**: [`ProtocolErrorCode`](../enumerations/ProtocolErrorCode.md)
|
|
64
64
|
|
|
65
|
-
Defined in: src/errors.ts:
|
|
65
|
+
Defined in: src/errors.ts:34
|
|
66
66
|
|
|
67
67
|
#### Inherited from
|
|
68
68
|
|
|
@@ -74,7 +74,7 @@ Defined in: src/errors.ts:29
|
|
|
74
74
|
|
|
75
75
|
> `readonly` `optional` **details**: `Record`\<`string`, `unknown`\>
|
|
76
76
|
|
|
77
|
-
Defined in: src/errors.ts:
|
|
77
|
+
Defined in: src/errors.ts:36
|
|
78
78
|
|
|
79
79
|
#### Inherited from
|
|
80
80
|
|
|
@@ -242,7 +242,7 @@ Create .stack property on a target object
|
|
|
242
242
|
|
|
243
243
|
> `static` **create**(`code`, `message`, `details?`): [`ProtocolError`](ProtocolError.md)
|
|
244
244
|
|
|
245
|
-
Defined in: src/errors.ts:
|
|
245
|
+
Defined in: src/errors.ts:149
|
|
246
246
|
|
|
247
247
|
#### Parameters
|
|
248
248
|
|
|
@@ -272,7 +272,7 @@ Defined in: src/errors.ts:127
|
|
|
272
272
|
|
|
273
273
|
> `static` **cryptoError**(`operation`, `reason`): [`ProtocolError`](ProtocolError.md)
|
|
274
274
|
|
|
275
|
-
Defined in: src/errors.ts:
|
|
275
|
+
Defined in: src/errors.ts:127
|
|
276
276
|
|
|
277
277
|
#### Parameters
|
|
278
278
|
|
|
@@ -298,7 +298,7 @@ Defined in: src/errors.ts:110
|
|
|
298
298
|
|
|
299
299
|
> `static` **expiredCode**(`code`, `expiresAt`, `currentTime`): [`ExpiredCodeError`](ExpiredCodeError.md)
|
|
300
300
|
|
|
301
|
-
Defined in: src/errors.ts:
|
|
301
|
+
Defined in: src/errors.ts:43
|
|
302
302
|
|
|
303
303
|
#### Parameters
|
|
304
304
|
|
|
@@ -324,11 +324,49 @@ Defined in: src/errors.ts:38
|
|
|
324
324
|
|
|
325
325
|
***
|
|
326
326
|
|
|
327
|
+
### invalidAdapter()
|
|
328
|
+
|
|
329
|
+
> `static` **invalidAdapter**(`adapter`): [`InvalidAdapterError`](InvalidAdapterError.md)
|
|
330
|
+
|
|
331
|
+
Defined in: src/errors.ts:144
|
|
332
|
+
|
|
333
|
+
#### Parameters
|
|
334
|
+
|
|
335
|
+
##### adapter
|
|
336
|
+
|
|
337
|
+
`string`
|
|
338
|
+
|
|
339
|
+
#### Returns
|
|
340
|
+
|
|
341
|
+
[`InvalidAdapterError`](InvalidAdapterError.md)
|
|
342
|
+
|
|
343
|
+
#### Inherited from
|
|
344
|
+
|
|
345
|
+
[`ProtocolError`](ProtocolError.md).[`invalidAdapter`](ProtocolError.md#invalidadapter)
|
|
346
|
+
|
|
347
|
+
***
|
|
348
|
+
|
|
349
|
+
### invalidCode()
|
|
350
|
+
|
|
351
|
+
> `static` **invalidCode**(): [`ProtocolError`](ProtocolError.md)
|
|
352
|
+
|
|
353
|
+
Defined in: src/errors.ts:47
|
|
354
|
+
|
|
355
|
+
#### Returns
|
|
356
|
+
|
|
357
|
+
[`ProtocolError`](ProtocolError.md)
|
|
358
|
+
|
|
359
|
+
#### Inherited from
|
|
360
|
+
|
|
361
|
+
[`ProtocolError`](ProtocolError.md).[`invalidCode`](ProtocolError.md#invalidcode)
|
|
362
|
+
|
|
363
|
+
***
|
|
364
|
+
|
|
327
365
|
### invalidCodeFormat()
|
|
328
366
|
|
|
329
367
|
> `static` **invalidCodeFormat**(`code`, `reason`): [`InvalidCodeFormatError`](InvalidCodeFormatError.md)
|
|
330
368
|
|
|
331
|
-
Defined in: src/errors.ts:
|
|
369
|
+
Defined in: src/errors.ts:55
|
|
332
370
|
|
|
333
371
|
#### Parameters
|
|
334
372
|
|
|
@@ -354,7 +392,7 @@ Defined in: src/errors.ts:42
|
|
|
354
392
|
|
|
355
393
|
> `static` **invalidDigest**(`reason`): [`ProtocolError`](ProtocolError.md)
|
|
356
394
|
|
|
357
|
-
Defined in: src/errors.ts:
|
|
395
|
+
Defined in: src/errors.ts:135
|
|
358
396
|
|
|
359
397
|
#### Parameters
|
|
360
398
|
|
|
@@ -376,7 +414,7 @@ Defined in: src/errors.ts:118
|
|
|
376
414
|
|
|
377
415
|
> `static` **invalidInput**(`field`, `value`, `reason`): [`ProtocolError`](ProtocolError.md)
|
|
378
416
|
|
|
379
|
-
Defined in: src/errors.ts:
|
|
417
|
+
Defined in: src/errors.ts:110
|
|
380
418
|
|
|
381
419
|
#### Parameters
|
|
382
420
|
|
|
@@ -406,7 +444,7 @@ Defined in: src/errors.ts:93
|
|
|
406
444
|
|
|
407
445
|
> `static` **invalidMetaFormat**(`reason`): [`ProtocolError`](ProtocolError.md)
|
|
408
446
|
|
|
409
|
-
Defined in: src/errors.ts:
|
|
447
|
+
Defined in: src/errors.ts:68
|
|
410
448
|
|
|
411
449
|
#### Parameters
|
|
412
450
|
|
|
@@ -428,7 +466,7 @@ Defined in: src/errors.ts:55
|
|
|
428
466
|
|
|
429
467
|
> `static` **invalidPubkeyFormat**(`pubkey`, `reason`): [`InvalidPubkeyFormatError`](InvalidPubkeyFormatError.md)
|
|
430
468
|
|
|
431
|
-
Defined in: src/errors.ts:
|
|
469
|
+
Defined in: src/errors.ts:105
|
|
432
470
|
|
|
433
471
|
#### Parameters
|
|
434
472
|
|
|
@@ -454,7 +492,7 @@ Defined in: src/errors.ts:88
|
|
|
454
492
|
|
|
455
493
|
> `static` **invalidSignature**(`reason`): [`InvalidSignatureError`](InvalidSignatureError.md)
|
|
456
494
|
|
|
457
|
-
Defined in: src/errors.ts:
|
|
495
|
+
Defined in: src/errors.ts:59
|
|
458
496
|
|
|
459
497
|
#### Parameters
|
|
460
498
|
|
|
@@ -476,7 +514,7 @@ Defined in: src/errors.ts:46
|
|
|
476
514
|
|
|
477
515
|
> `static` **invalidTransactionFormat**(`reason`): [`ProtocolError`](ProtocolError.md)
|
|
478
516
|
|
|
479
|
-
Defined in: src/errors.ts:
|
|
517
|
+
Defined in: src/errors.ts:97
|
|
480
518
|
|
|
481
519
|
#### Parameters
|
|
482
520
|
|
|
@@ -550,7 +588,7 @@ True if the value is an instance of Error, false otherwise
|
|
|
550
588
|
|
|
551
589
|
> `static` **metaMismatch**(`expected`, `actual`, `field`): `MetaMismatchError`
|
|
552
590
|
|
|
553
|
-
Defined in: src/errors.ts:
|
|
591
|
+
Defined in: src/errors.ts:76
|
|
554
592
|
|
|
555
593
|
#### Parameters
|
|
556
594
|
|
|
@@ -580,7 +618,7 @@ Defined in: src/errors.ts:63
|
|
|
580
618
|
|
|
581
619
|
> `static` **metaTooLarge**(`maxBytes`, `actualBytes`): [`ProtocolError`](ProtocolError.md)
|
|
582
620
|
|
|
583
|
-
Defined in: src/errors.ts:
|
|
621
|
+
Defined in: src/errors.ts:80
|
|
584
622
|
|
|
585
623
|
#### Parameters
|
|
586
624
|
|
|
@@ -606,7 +644,7 @@ Defined in: src/errors.ts:67
|
|
|
606
644
|
|
|
607
645
|
> `static` **missingMeta**(): [`MissingMetaError`](MissingMetaError.md)
|
|
608
646
|
|
|
609
|
-
Defined in: src/errors.ts:
|
|
647
|
+
Defined in: src/errors.ts:64
|
|
610
648
|
|
|
611
649
|
#### Returns
|
|
612
650
|
|
|
@@ -622,7 +660,7 @@ Defined in: src/errors.ts:51
|
|
|
622
660
|
|
|
623
661
|
> `static` **missingRequiredField**(`field`): [`ProtocolError`](ProtocolError.md)
|
|
624
662
|
|
|
625
|
-
Defined in: src/errors.ts:
|
|
663
|
+
Defined in: src/errors.ts:118
|
|
626
664
|
|
|
627
665
|
#### Parameters
|
|
628
666
|
|
|
@@ -674,7 +712,7 @@ https://v8.dev/docs/stack-trace-api#customizing-stack-traces
|
|
|
674
712
|
|
|
675
713
|
> `static` **transactionNotSignedByIntendedOwner**(`intended`, `actualSigners`): [`TransactionNotSignedByIntendedOwnerError`](TransactionNotSignedByIntendedOwnerError.md)
|
|
676
714
|
|
|
677
|
-
Defined in: src/errors.ts:
|
|
715
|
+
Defined in: src/errors.ts:89
|
|
678
716
|
|
|
679
717
|
#### Parameters
|
|
680
718
|
|
|
@@ -693,3 +731,29 @@ Defined in: src/errors.ts:76
|
|
|
693
731
|
#### Inherited from
|
|
694
732
|
|
|
695
733
|
[`ProtocolError`](ProtocolError.md).[`transactionNotSignedByIntendedOwner`](ProtocolError.md#transactionnotsignedbyintendedowner)
|
|
734
|
+
|
|
735
|
+
***
|
|
736
|
+
|
|
737
|
+
### transactionNotSignedByIssuer()
|
|
738
|
+
|
|
739
|
+
> `static` **transactionNotSignedByIssuer**(`issuer`, `actualSigners`): [`TransactionNotSignedByIssuerError`](TransactionNotSignedByIssuerError.md)
|
|
740
|
+
|
|
741
|
+
Defined in: src/errors.ts:93
|
|
742
|
+
|
|
743
|
+
#### Parameters
|
|
744
|
+
|
|
745
|
+
##### issuer
|
|
746
|
+
|
|
747
|
+
`string`
|
|
748
|
+
|
|
749
|
+
##### actualSigners
|
|
750
|
+
|
|
751
|
+
`string`[]
|
|
752
|
+
|
|
753
|
+
#### Returns
|
|
754
|
+
|
|
755
|
+
[`TransactionNotSignedByIssuerError`](TransactionNotSignedByIssuerError.md)
|
|
756
|
+
|
|
757
|
+
#### Inherited from
|
|
758
|
+
|
|
759
|
+
[`ProtocolError`](ProtocolError.md).[`transactionNotSignedByIssuer`](ProtocolError.md#transactionnotsignedbyissuer)
|