@xyo-network/xl1-protocol 1.25.32 → 1.26.1
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/neutral/index.d.ts +4 -24
- package/dist/neutral/index.d.ts.map +1 -1
- package/dist/neutral/index.mjs +5 -2047
- package/dist/neutral/index.mjs.map +1 -1
- package/package.json +17 -14
- package/src/index.ts +4 -24
- package/LICENSE +0 -165
- package/README.md +0 -81
- package/dist/neutral/BlockNumber/BlockNumber.d.ts +0 -35
- package/dist/neutral/BlockNumber/BlockNumber.d.ts.map +0 -1
- package/dist/neutral/BlockNumber/EthBlockNumber.d.ts +0 -46
- package/dist/neutral/BlockNumber/EthBlockNumber.d.ts.map +0 -1
- package/dist/neutral/BlockNumber/Numberish.d.ts +0 -6
- package/dist/neutral/BlockNumber/Numberish.d.ts.map +0 -1
- package/dist/neutral/BlockNumber/XL1BlockNumber.d.ts +0 -46
- package/dist/neutral/BlockNumber/XL1BlockNumber.d.ts.map +0 -1
- package/dist/neutral/BlockNumber/index.d.ts +0 -5
- package/dist/neutral/BlockNumber/index.d.ts.map +0 -1
- package/dist/neutral/Initializable.d.ts +0 -9
- package/dist/neutral/Initializable.d.ts.map +0 -1
- package/dist/neutral/OpenTelemetryProviders.d.ts +0 -7
- package/dist/neutral/OpenTelemetryProviders.d.ts.map +0 -1
- package/dist/neutral/RecordKeyType.d.ts +0 -4
- package/dist/neutral/RecordKeyType.d.ts.map +0 -1
- package/dist/neutral/Step/StepHash.d.ts +0 -11
- package/dist/neutral/Step/StepHash.d.ts.map +0 -1
- package/dist/neutral/Step/StepIdentity.d.ts +0 -19
- package/dist/neutral/Step/StepIdentity.d.ts.map +0 -1
- package/dist/neutral/Step/StepSizes.d.ts +0 -12
- package/dist/neutral/Step/StepSizes.d.ts.map +0 -1
- package/dist/neutral/Step/index.d.ts +0 -4
- package/dist/neutral/Step/index.d.ts.map +0 -1
- package/dist/neutral/TransferPayload.d.ts +0 -79
- package/dist/neutral/TransferPayload.d.ts.map +0 -1
- package/dist/neutral/amount/ShiftedBigIntConfig.d.ts +0 -9
- package/dist/neutral/amount/ShiftedBigIntConfig.d.ts.map +0 -1
- package/dist/neutral/amount/XL1AmountInstance.d.ts +0 -16
- package/dist/neutral/amount/XL1AmountInstance.d.ts.map +0 -1
- package/dist/neutral/amount/index.d.ts +0 -3
- package/dist/neutral/amount/index.d.ts.map +0 -1
- package/dist/neutral/block/AllowedBlockPayload.d.ts +0 -40
- package/dist/neutral/block/AllowedBlockPayload.d.ts.map +0 -1
- package/dist/neutral/block/BlockBoundWitness.d.ts +0 -544
- package/dist/neutral/block/BlockBoundWitness.d.ts.map +0 -1
- package/dist/neutral/block/HydratedBlock.d.ts +0 -1466
- package/dist/neutral/block/HydratedBlock.d.ts.map +0 -1
- package/dist/neutral/block/index.d.ts +0 -6
- package/dist/neutral/block/index.d.ts.map +0 -1
- package/dist/neutral/block/signed/SignedBlockBoundWitness.d.ts +0 -168
- package/dist/neutral/block/signed/SignedBlockBoundWitness.d.ts.map +0 -1
- package/dist/neutral/block/signed/SignedBlockBoundWitnessWithHashMeta.d.ts +0 -286
- package/dist/neutral/block/signed/SignedBlockBoundWitnessWithHashMeta.d.ts.map +0 -1
- package/dist/neutral/block/signed/SignedBlockBoundWitnessWithStorageMeta.d.ts +0 -343
- package/dist/neutral/block/signed/SignedBlockBoundWitnessWithStorageMeta.d.ts.map +0 -1
- package/dist/neutral/block/signed/index.d.ts +0 -4
- package/dist/neutral/block/signed/index.d.ts.map +0 -1
- package/dist/neutral/block/unsigned/UnsignedBlockBoundWitness.d.ts +0 -168
- package/dist/neutral/block/unsigned/UnsignedBlockBoundWitness.d.ts.map +0 -1
- package/dist/neutral/block/unsigned/index.d.ts +0 -2
- package/dist/neutral/block/unsigned/index.d.ts.map +0 -1
- package/dist/neutral/chain/Chain.d.ts +0 -4
- package/dist/neutral/chain/Chain.d.ts.map +0 -1
- package/dist/neutral/chain/ChainAnalyzer.d.ts +0 -10
- package/dist/neutral/chain/ChainAnalyzer.d.ts.map +0 -1
- package/dist/neutral/chain/ChainId.d.ts +0 -4
- package/dist/neutral/chain/ChainId.d.ts.map +0 -1
- package/dist/neutral/chain/index.d.ts +0 -4
- package/dist/neutral/chain/index.d.ts.map +0 -1
- package/dist/neutral/fields/Addressable.d.ts +0 -6
- package/dist/neutral/fields/Addressable.d.ts.map +0 -1
- package/dist/neutral/fields/BlockDuration.d.ts +0 -25
- package/dist/neutral/fields/BlockDuration.d.ts.map +0 -1
- package/dist/neutral/fields/BlockNumber.d.ts +0 -32
- package/dist/neutral/fields/BlockNumber.d.ts.map +0 -1
- package/dist/neutral/fields/ChainReference.d.ts +0 -11
- package/dist/neutral/fields/ChainReference.d.ts.map +0 -1
- package/dist/neutral/fields/index.d.ts +0 -5
- package/dist/neutral/fields/index.d.ts.map +0 -1
- package/dist/neutral/map/AsyncMap.d.ts +0 -42
- package/dist/neutral/map/AsyncMap.d.ts.map +0 -1
- package/dist/neutral/map/MapType.d.ts +0 -17
- package/dist/neutral/map/MapType.d.ts.map +0 -1
- package/dist/neutral/map/SyncMap.d.ts +0 -41
- package/dist/neutral/map/SyncMap.d.ts.map +0 -1
- package/dist/neutral/map/index.d.ts +0 -4
- package/dist/neutral/map/index.d.ts.map +0 -1
- package/dist/neutral/model/AccountBalance.d.ts +0 -133
- package/dist/neutral/model/AccountBalance.d.ts.map +0 -1
- package/dist/neutral/model/ArrayBuffer.d.ts +0 -6
- package/dist/neutral/model/ArrayBuffer.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/BlockRange.d.ts +0 -32
- package/dist/neutral/model/BlockRange/BlockRange.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/EthBlockRange.d.ts +0 -32
- package/dist/neutral/model/BlockRange/EthBlockRange.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/Numberish.d.ts +0 -4
- package/dist/neutral/model/BlockRange/Numberish.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/Range.d.ts +0 -18
- package/dist/neutral/model/BlockRange/Range.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/XL1BlockRange.d.ts +0 -32
- package/dist/neutral/model/BlockRange/XL1BlockRange.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/index.d.ts +0 -5
- package/dist/neutral/model/BlockRange/index.d.ts.map +0 -1
- package/dist/neutral/model/BlockRate.d.ts +0 -290
- package/dist/neutral/model/BlockRate.d.ts.map +0 -1
- package/dist/neutral/model/ChainQualification.d.ts +0 -57
- package/dist/neutral/model/ChainQualification.d.ts.map +0 -1
- package/dist/neutral/model/Context/BaseContext.d.ts +0 -5
- package/dist/neutral/model/Context/BaseContext.d.ts.map +0 -1
- package/dist/neutral/model/Context/BaseContext.zod.d.ts +0 -26
- package/dist/neutral/model/Context/BaseContext.zod.d.ts.map +0 -1
- package/dist/neutral/model/Context/BlockContext.d.ts +0 -9
- package/dist/neutral/model/Context/BlockContext.d.ts.map +0 -1
- package/dist/neutral/model/Context/BlockContext.zod.d.ts +0 -33
- package/dist/neutral/model/Context/BlockContext.zod.d.ts.map +0 -1
- package/dist/neutral/model/Context/CachingContext.d.ts +0 -5
- package/dist/neutral/model/Context/CachingContext.d.ts.map +0 -1
- package/dist/neutral/model/Context/CachingContext.zod.d.ts +0 -10
- package/dist/neutral/model/Context/CachingContext.zod.d.ts.map +0 -1
- package/dist/neutral/model/Context/ChainContext.d.ts +0 -9
- package/dist/neutral/model/Context/ChainContext.d.ts.map +0 -1
- package/dist/neutral/model/Context/ChainContext.zod.d.ts +0 -115
- package/dist/neutral/model/Context/ChainContext.zod.d.ts.map +0 -1
- package/dist/neutral/model/Context/HeadContext.d.ts +0 -5
- package/dist/neutral/model/Context/HeadContext.d.ts.map +0 -1
- package/dist/neutral/model/Context/HeadContext.zod.d.ts +0 -70
- package/dist/neutral/model/Context/HeadContext.zod.d.ts.map +0 -1
- package/dist/neutral/model/Context/index.d.ts +0 -11
- package/dist/neutral/model/Context/index.d.ts.map +0 -1
- package/dist/neutral/model/GatewayName.d.ts +0 -6
- package/dist/neutral/model/GatewayName.d.ts.map +0 -1
- package/dist/neutral/model/HydratedTransaction.d.ts +0 -2300
- package/dist/neutral/model/HydratedTransaction.d.ts.map +0 -1
- package/dist/neutral/model/OpCodes.d.ts +0 -3
- package/dist/neutral/model/OpCodes.d.ts.map +0 -1
- package/dist/neutral/model/PayloadMap.d.ts +0 -10
- package/dist/neutral/model/PayloadMap.d.ts.map +0 -1
- package/dist/neutral/model/Permission.d.ts +0 -59
- package/dist/neutral/model/Permission.d.ts.map +0 -1
- package/dist/neutral/model/Position.d.ts +0 -13
- package/dist/neutral/model/Position.d.ts.map +0 -1
- package/dist/neutral/model/PositionId.d.ts +0 -6
- package/dist/neutral/model/PositionId.d.ts.map +0 -1
- package/dist/neutral/model/RangeMultipliers.d.ts +0 -10
- package/dist/neutral/model/RangeMultipliers.d.ts.map +0 -1
- package/dist/neutral/model/RewardShare.d.ts +0 -3
- package/dist/neutral/model/RewardShare.d.ts.map +0 -1
- package/dist/neutral/model/RewardsRangeOptions.d.ts +0 -16
- package/dist/neutral/model/RewardsRangeOptions.d.ts.map +0 -1
- package/dist/neutral/model/Sequence.d.ts +0 -15
- package/dist/neutral/model/Sequence.d.ts.map +0 -1
- package/dist/neutral/model/Stake.d.ts +0 -121
- package/dist/neutral/model/Stake.d.ts.map +0 -1
- package/dist/neutral/model/StakeShare.d.ts +0 -3
- package/dist/neutral/model/StakeShare.d.ts.map +0 -1
- package/dist/neutral/model/TimeDomain.d.ts +0 -4
- package/dist/neutral/model/TimeDomain.d.ts.map +0 -1
- package/dist/neutral/model/TransferPair.d.ts +0 -12
- package/dist/neutral/model/TransferPair.d.ts.map +0 -1
- package/dist/neutral/model/addresses.d.ts +0 -28
- package/dist/neutral/model/addresses.d.ts.map +0 -1
- package/dist/neutral/model/defaultRewardRatio.d.ts +0 -3
- package/dist/neutral/model/defaultRewardRatio.d.ts.map +0 -1
- package/dist/neutral/model/defaultTransactionFees.d.ts +0 -4
- package/dist/neutral/model/defaultTransactionFees.d.ts.map +0 -1
- package/dist/neutral/model/index.d.ts +0 -28
- package/dist/neutral/model/index.d.ts.map +0 -1
- package/dist/neutral/model/minTransactionFees.d.ts +0 -4
- package/dist/neutral/model/minTransactionFees.d.ts.map +0 -1
- package/dist/neutral/model/rewards.d.ts +0 -15
- package/dist/neutral/model/rewards.d.ts.map +0 -1
- package/dist/neutral/model/version.d.ts +0 -11
- package/dist/neutral/model/version.d.ts.map +0 -1
- package/dist/neutral/network/NetworkId.d.ts +0 -12
- package/dist/neutral/network/NetworkId.d.ts.map +0 -1
- package/dist/neutral/network/Status.d.ts +0 -26
- package/dist/neutral/network/Status.d.ts.map +0 -1
- package/dist/neutral/network/index.d.ts +0 -3
- package/dist/neutral/network/index.d.ts.map +0 -1
- package/dist/neutral/payload/StepIdentityPayload.d.ts +0 -20
- package/dist/neutral/payload/StepIdentityPayload.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/BridgeCompletion.d.ts +0 -23
- package/dist/neutral/payload/elevatable/Bridge/BridgeCompletion.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/BridgeDestinationObservation.d.ts +0 -33
- package/dist/neutral/payload/elevatable/Bridge/BridgeDestinationObservation.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/BridgeDetails.d.ts +0 -45
- package/dist/neutral/payload/elevatable/Bridge/BridgeDetails.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/BridgeIntent.d.ts +0 -31
- package/dist/neutral/payload/elevatable/Bridge/BridgeIntent.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/BridgeSourceObservation.d.ts +0 -33
- package/dist/neutral/payload/elevatable/Bridge/BridgeSourceObservation.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/index.d.ts +0 -6
- package/dist/neutral/payload/elevatable/Bridge/index.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/ChainStakeIntent.d.ts +0 -24
- package/dist/neutral/payload/elevatable/ChainStakeIntent.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Executable.d.ts +0 -20
- package/dist/neutral/payload/elevatable/Executable.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Hash.d.ts +0 -21
- package/dist/neutral/payload/elevatable/Hash.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/StepComplete.d.ts +0 -22
- package/dist/neutral/payload/elevatable/StepComplete.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Time.d.ts +0 -71
- package/dist/neutral/payload/elevatable/Time.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/index.d.ts +0 -7
- package/dist/neutral/payload/elevatable/index.d.ts.map +0 -1
- package/dist/neutral/payload/index.d.ts +0 -3
- package/dist/neutral/payload/index.d.ts.map +0 -1
- package/dist/neutral/permissions/InvokerPermission.d.ts +0 -53
- package/dist/neutral/permissions/InvokerPermission.d.ts.map +0 -1
- package/dist/neutral/permissions/XyoPermissions.d.ts +0 -33
- package/dist/neutral/permissions/XyoPermissions.d.ts.map +0 -1
- package/dist/neutral/permissions/index.d.ts +0 -3
- package/dist/neutral/permissions/index.d.ts.map +0 -1
- package/dist/neutral/provider/Provider.d.ts +0 -6
- package/dist/neutral/provider/Provider.d.ts.map +0 -1
- package/dist/neutral/provider/ProviderMoniker.d.ts +0 -9
- package/dist/neutral/provider/ProviderMoniker.d.ts.map +0 -1
- package/dist/neutral/provider/index.d.ts +0 -3
- package/dist/neutral/provider/index.d.ts.map +0 -1
- package/dist/neutral/providers/DataLake/Provider.d.ts +0 -10
- package/dist/neutral/providers/DataLake/Provider.d.ts.map +0 -1
- package/dist/neutral/providers/DataLake/Runner.d.ts +0 -15
- package/dist/neutral/providers/DataLake/Runner.d.ts.map +0 -1
- package/dist/neutral/providers/DataLake/Viewer.d.ts +0 -14
- package/dist/neutral/providers/DataLake/Viewer.d.ts.map +0 -1
- package/dist/neutral/providers/DataLake/index.d.ts +0 -4
- package/dist/neutral/providers/DataLake/index.d.ts.map +0 -1
- package/dist/neutral/providers/TransactionHelper.d.ts +0 -9
- package/dist/neutral/providers/TransactionHelper.d.ts.map +0 -1
- package/dist/neutral/providers/XyoClient.d.ts +0 -23
- package/dist/neutral/providers/XyoClient.d.ts.map +0 -1
- package/dist/neutral/providers/XyoConnection.d.ts +0 -18
- package/dist/neutral/providers/XyoConnection.d.ts.map +0 -1
- package/dist/neutral/providers/XyoGateway.d.ts +0 -20
- package/dist/neutral/providers/XyoGateway.d.ts.map +0 -1
- package/dist/neutral/providers/XyoGatewayRunner.d.ts +0 -55
- package/dist/neutral/providers/XyoGatewayRunner.d.ts.map +0 -1
- package/dist/neutral/providers/XyoNetwork.d.ts +0 -7
- package/dist/neutral/providers/XyoNetwork.d.ts.map +0 -1
- package/dist/neutral/providers/XyoRunner.d.ts +0 -17
- package/dist/neutral/providers/XyoRunner.d.ts.map +0 -1
- package/dist/neutral/providers/index.d.ts +0 -9
- package/dist/neutral/providers/index.d.ts.map +0 -1
- package/dist/neutral/providers/signer/XyoSigner.d.ts +0 -25
- package/dist/neutral/providers/signer/XyoSigner.d.ts.map +0 -1
- package/dist/neutral/providers/signer/index.d.ts +0 -2
- package/dist/neutral/providers/signer/index.d.ts.map +0 -1
- package/dist/neutral/repository/Repository.d.ts +0 -27
- package/dist/neutral/repository/Repository.d.ts.map +0 -1
- package/dist/neutral/repository/TransactionReadRepository.d.ts +0 -7
- package/dist/neutral/repository/TransactionReadRepository.d.ts.map +0 -1
- package/dist/neutral/repository/TransactionRepository.d.ts +0 -13
- package/dist/neutral/repository/TransactionRepository.d.ts.map +0 -1
- package/dist/neutral/repository/TransactionRepositoryIterator.d.ts +0 -7
- package/dist/neutral/repository/TransactionRepositoryIterator.d.ts.map +0 -1
- package/dist/neutral/repository/TransactionWriteRepository.d.ts +0 -6
- package/dist/neutral/repository/TransactionWriteRepository.d.ts.map +0 -1
- package/dist/neutral/repository/index.d.ts +0 -6
- package/dist/neutral/repository/index.d.ts.map +0 -1
- package/dist/neutral/runners/Block.d.ts +0 -17
- package/dist/neutral/runners/Block.d.ts.map +0 -1
- package/dist/neutral/runners/Finalization.d.ts +0 -16
- package/dist/neutral/runners/Finalization.d.ts.map +0 -1
- package/dist/neutral/runners/Mempool.d.ts +0 -27
- package/dist/neutral/runners/Mempool.d.ts.map +0 -1
- package/dist/neutral/runners/index.d.ts +0 -4
- package/dist/neutral/runners/index.d.ts.map +0 -1
- package/dist/neutral/transaction/TransactionBoundWitness.d.ts +0 -2127
- package/dist/neutral/transaction/TransactionBoundWitness.d.ts.map +0 -1
- package/dist/neutral/transaction/TransactionFees.d.ts +0 -138
- package/dist/neutral/transaction/TransactionFees.d.ts.map +0 -1
- package/dist/neutral/transaction/TransactionGasCosts.d.ts +0 -38
- package/dist/neutral/transaction/TransactionGasCosts.d.ts.map +0 -1
- package/dist/neutral/transaction/index.d.ts +0 -4
- package/dist/neutral/transaction/index.d.ts.map +0 -1
- package/dist/neutral/validation/block/BlockValidationFunction.d.ts +0 -8
- package/dist/neutral/validation/block/BlockValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/block/HydratedBlockStateValidationFunction.d.ts +0 -22
- package/dist/neutral/validation/block/HydratedBlockStateValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/block/HydratedBlockValidationFunction.d.ts +0 -17
- package/dist/neutral/validation/block/HydratedBlockValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/block/error.d.ts +0 -22
- package/dist/neutral/validation/block/error.d.ts.map +0 -1
- package/dist/neutral/validation/block/index.d.ts +0 -5
- package/dist/neutral/validation/block/index.d.ts.map +0 -1
- package/dist/neutral/validation/boundwitness/BoundWitnessValidationFunction.d.ts +0 -6
- package/dist/neutral/validation/boundwitness/BoundWitnessValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/boundwitness/HydratedBoundWitnessValidationFunction.d.ts +0 -8
- package/dist/neutral/validation/boundwitness/HydratedBoundWitnessValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/boundwitness/error.d.ts +0 -13
- package/dist/neutral/validation/boundwitness/error.d.ts.map +0 -1
- package/dist/neutral/validation/boundwitness/index.d.ts +0 -4
- package/dist/neutral/validation/boundwitness/index.d.ts.map +0 -1
- package/dist/neutral/validation/error.d.ts +0 -11
- package/dist/neutral/validation/error.d.ts.map +0 -1
- package/dist/neutral/validation/index.d.ts +0 -6
- package/dist/neutral/validation/index.d.ts.map +0 -1
- package/dist/neutral/validation/payload/InBlockPayloadValidationFunction.d.ts +0 -11
- package/dist/neutral/validation/payload/InBlockPayloadValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/payload/error.d.ts +0 -12
- package/dist/neutral/validation/payload/error.d.ts.map +0 -1
- package/dist/neutral/validation/payload/index.d.ts +0 -3
- package/dist/neutral/validation/payload/index.d.ts.map +0 -1
- package/dist/neutral/validation/transaction/HydratedTransactionStateValidationFunction.d.ts +0 -19
- package/dist/neutral/validation/transaction/HydratedTransactionStateValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/transaction/HydratedTransactionValidationFunction.d.ts +0 -18
- package/dist/neutral/validation/transaction/HydratedTransactionValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/transaction/error.d.ts +0 -8
- package/dist/neutral/validation/transaction/error.d.ts.map +0 -1
- package/dist/neutral/validation/transaction/index.d.ts +0 -4
- package/dist/neutral/validation/transaction/index.d.ts.map +0 -1
- package/dist/neutral/viewers/Block.d.ts +0 -33
- package/dist/neutral/viewers/Block.d.ts.map +0 -1
- package/dist/neutral/viewers/BlockInvalidation.d.ts +0 -69
- package/dist/neutral/viewers/BlockInvalidation.d.ts.map +0 -1
- package/dist/neutral/viewers/BlockReward.d.ts +0 -16
- package/dist/neutral/viewers/BlockReward.d.ts.map +0 -1
- package/dist/neutral/viewers/BlockValidation.d.ts +0 -69
- package/dist/neutral/viewers/BlockValidation.d.ts.map +0 -1
- package/dist/neutral/viewers/ChainContract.d.ts +0 -24
- package/dist/neutral/viewers/ChainContract.d.ts.map +0 -1
- package/dist/neutral/viewers/ChainStakeViewer.d.ts +0 -11
- package/dist/neutral/viewers/ChainStakeViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/Finalization.d.ts +0 -21
- package/dist/neutral/viewers/Finalization.d.ts.map +0 -1
- package/dist/neutral/viewers/Fork.d.ts +0 -9
- package/dist/neutral/viewers/Fork.d.ts.map +0 -1
- package/dist/neutral/viewers/Mempool.d.ts +0 -33
- package/dist/neutral/viewers/Mempool.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/NetworkStakeViewer.d.ts +0 -17
- package/dist/neutral/viewers/NetworkStake/NetworkStakeViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/ByPositionViewer.d.ts +0 -14
- package/dist/neutral/viewers/NetworkStake/Rewards/ByPositionViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/ByStakerViewer.d.ts +0 -15
- package/dist/neutral/viewers/NetworkStake/Rewards/ByStakerViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/ByStepViewer.d.ts +0 -15
- package/dist/neutral/viewers/NetworkStake/Rewards/ByStepViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/Options.d.ts +0 -20
- package/dist/neutral/viewers/NetworkStake/Rewards/Options.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/TotalViewer.d.ts +0 -15
- package/dist/neutral/viewers/NetworkStake/Rewards/TotalViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/Viewer.d.ts +0 -20
- package/dist/neutral/viewers/NetworkStake/Rewards/Viewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/index.d.ts +0 -8
- package/dist/neutral/viewers/NetworkStake/Rewards/index.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/ByIndexMethodsTemplate.d.ts +0 -7
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/ByIndexMethodsTemplate.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/MethodsTemplate.d.ts +0 -10
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/MethodsTemplate.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/index.d.ts +0 -3
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/index.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/index.d.ts +0 -3
- package/dist/neutral/viewers/NetworkStake/index.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStakeStepReward.d.ts +0 -42
- package/dist/neutral/viewers/NetworkStakeStepReward.d.ts.map +0 -1
- package/dist/neutral/viewers/Stake.d.ts +0 -39
- package/dist/neutral/viewers/Stake.d.ts.map +0 -1
- package/dist/neutral/viewers/StakeEvents.d.ts +0 -44
- package/dist/neutral/viewers/StakeEvents.d.ts.map +0 -1
- package/dist/neutral/viewers/StakeIntent.d.ts +0 -17
- package/dist/neutral/viewers/StakeIntent.d.ts.map +0 -1
- package/dist/neutral/viewers/StakeTotals.d.ts +0 -20
- package/dist/neutral/viewers/StakeTotals.d.ts.map +0 -1
- package/dist/neutral/viewers/StepStake.d.ts +0 -15
- package/dist/neutral/viewers/StepStake.d.ts.map +0 -1
- package/dist/neutral/viewers/StepViewer.d.ts +0 -39
- package/dist/neutral/viewers/StepViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/TimeSync.d.ts +0 -22
- package/dist/neutral/viewers/TimeSync.d.ts.map +0 -1
- package/dist/neutral/viewers/Transaction.d.ts +0 -23
- package/dist/neutral/viewers/Transaction.d.ts.map +0 -1
- package/dist/neutral/viewers/TransactionInvalidation.d.ts +0 -67
- package/dist/neutral/viewers/TransactionInvalidation.d.ts.map +0 -1
- package/dist/neutral/viewers/TransactionValidation.d.ts +0 -68
- package/dist/neutral/viewers/TransactionValidation.d.ts.map +0 -1
- package/dist/neutral/viewers/TransferBalance.d.ts +0 -35
- package/dist/neutral/viewers/TransferBalance.d.ts.map +0 -1
- package/dist/neutral/viewers/WindowedBlock.d.ts +0 -19
- package/dist/neutral/viewers/WindowedBlock.d.ts.map +0 -1
- package/dist/neutral/viewers/XyoViewer.d.ts +0 -57
- package/dist/neutral/viewers/XyoViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/index.d.ts +0 -24
- package/dist/neutral/viewers/index.d.ts.map +0 -1
- package/dist/neutral/xl1/AttoXL1.d.ts +0 -15
- package/dist/neutral/xl1/AttoXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/FemtoXL1.d.ts +0 -15
- package/dist/neutral/xl1/FemtoXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/MicroXL1.d.ts +0 -15
- package/dist/neutral/xl1/MicroXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/MilliXL1.d.ts +0 -15
- package/dist/neutral/xl1/MilliXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/NanoXL1.d.ts +0 -15
- package/dist/neutral/xl1/NanoXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/PicoXL1.d.ts +0 -15
- package/dist/neutral/xl1/PicoXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/XL1.d.ts +0 -15
- package/dist/neutral/xl1/XL1.d.ts.map +0 -1
- package/dist/neutral/xl1/XL1Units.d.ts +0 -10
- package/dist/neutral/xl1/XL1Units.d.ts.map +0 -1
- package/dist/neutral/xl1/index.d.ts +0 -9
- package/dist/neutral/xl1/index.d.ts.map +0 -1
- package/dist/neutral/xl1/isXL1Factory.d.ts +0 -12
- package/dist/neutral/xl1/isXL1Factory.d.ts.map +0 -1
- package/dist/neutral/xl1/xl1MaxValue.d.ts +0 -3
- package/dist/neutral/xl1/xl1MaxValue.d.ts.map +0 -1
- package/src/BlockNumber/BlockNumber.ts +0 -24
- package/src/BlockNumber/EthBlockNumber.ts +0 -25
- package/src/BlockNumber/Numberish.ts +0 -9
- package/src/BlockNumber/XL1BlockNumber.ts +0 -25
- package/src/BlockNumber/index.ts +0 -4
- package/src/Initializable.ts +0 -13
- package/src/OpenTelemetryProviders.ts +0 -7
- package/src/RecordKeyType.ts +0 -5
- package/src/Step/StepHash.ts +0 -10
- package/src/Step/StepIdentity.ts +0 -46
- package/src/Step/StepSizes.ts +0 -47
- package/src/Step/index.ts +0 -3
- package/src/TransferPayload.ts +0 -35
- package/src/amount/ShiftedBigIntConfig.ts +0 -8
- package/src/amount/XL1AmountInstance.ts +0 -19
- package/src/amount/index.ts +0 -2
- package/src/block/AllowedBlockPayload.ts +0 -73
- package/src/block/BlockBoundWitness.ts +0 -72
- package/src/block/HydratedBlock.ts +0 -135
- package/src/block/index.ts +0 -5
- package/src/block/signed/SignedBlockBoundWitness.ts +0 -22
- package/src/block/signed/SignedBlockBoundWitnessWithHashMeta.ts +0 -35
- package/src/block/signed/SignedBlockBoundWitnessWithStorageMeta.ts +0 -41
- package/src/block/signed/index.ts +0 -3
- package/src/block/unsigned/UnsignedBlockBoundWitness.ts +0 -22
- package/src/block/unsigned/index.ts +0 -1
- package/src/chain/Chain.ts +0 -7
- package/src/chain/ChainAnalyzer.ts +0 -11
- package/src/chain/ChainId.ts +0 -4
- package/src/chain/index.ts +0 -3
- package/src/fields/Addressable.ts +0 -7
- package/src/fields/BlockDuration.ts +0 -25
- package/src/fields/BlockNumber.ts +0 -40
- package/src/fields/ChainReference.ts +0 -11
- package/src/fields/index.ts +0 -4
- package/src/map/AsyncMap.ts +0 -38
- package/src/map/MapType.ts +0 -27
- package/src/map/SyncMap.ts +0 -38
- package/src/map/index.ts +0 -3
- package/src/model/AccountBalance.ts +0 -58
- package/src/model/ArrayBuffer.ts +0 -44
- package/src/model/BlockRange/BlockRange.ts +0 -43
- package/src/model/BlockRange/EthBlockRange.ts +0 -43
- package/src/model/BlockRange/Numberish.ts +0 -6
- package/src/model/BlockRange/Range.ts +0 -17
- package/src/model/BlockRange/XL1BlockRange.ts +0 -43
- package/src/model/BlockRange/index.ts +0 -4
- package/src/model/BlockRate.ts +0 -108
- package/src/model/ChainQualification.ts +0 -48
- package/src/model/Context/BaseContext.ts +0 -6
- package/src/model/Context/BaseContext.zod.ts +0 -36
- package/src/model/Context/BlockContext.ts +0 -12
- package/src/model/Context/BlockContext.zod.ts +0 -20
- package/src/model/Context/CachingContext.ts +0 -6
- package/src/model/Context/CachingContext.zod.ts +0 -4
- package/src/model/Context/ChainContext.ts +0 -12
- package/src/model/Context/ChainContext.zod.ts +0 -17
- package/src/model/Context/HeadContext.ts +0 -6
- package/src/model/Context/HeadContext.zod.ts +0 -13
- package/src/model/Context/index.ts +0 -10
- package/src/model/GatewayName.ts +0 -4
- package/src/model/HydratedTransaction.ts +0 -169
- package/src/model/OpCodes.ts +0 -2
- package/src/model/PayloadMap.ts +0 -13
- package/src/model/Permission.ts +0 -29
- package/src/model/Position.ts +0 -21
- package/src/model/PositionId.ts +0 -4
- package/src/model/RangeMultipliers.ts +0 -13
- package/src/model/RewardShare.ts +0 -2
- package/src/model/RewardsRangeOptions.ts +0 -13
- package/src/model/Sequence.ts +0 -21
- package/src/model/Stake.ts +0 -47
- package/src/model/StakeShare.ts +0 -2
- package/src/model/TimeDomain.ts +0 -8
- package/src/model/TransferPair.ts +0 -7
- package/src/model/addresses.ts +0 -36
- package/src/model/defaultRewardRatio.ts +0 -3
- package/src/model/defaultTransactionFees.ts +0 -11
- package/src/model/index.ts +0 -27
- package/src/model/minTransactionFees.ts +0 -10
- package/src/model/rewards.ts +0 -18
- package/src/model/spec/fixtures/index.ts +0 -2
- package/src/model/spec/fixtures/signedHydratedTransaction.ts +0 -58
- package/src/model/spec/fixtures/unsignedHydratedTransaction.ts +0 -62
- package/src/model/version.ts +0 -10
- package/src/network/NetworkId.ts +0 -6
- package/src/network/Status.ts +0 -30
- package/src/network/index.ts +0 -2
- package/src/payload/StepIdentityPayload.ts +0 -25
- package/src/payload/elevatable/Bridge/BridgeCompletion.ts +0 -28
- package/src/payload/elevatable/Bridge/BridgeDestinationObservation.ts +0 -38
- package/src/payload/elevatable/Bridge/BridgeDetails.ts +0 -69
- package/src/payload/elevatable/Bridge/BridgeIntent.ts +0 -36
- package/src/payload/elevatable/Bridge/BridgeSourceObservation.ts +0 -37
- package/src/payload/elevatable/Bridge/index.ts +0 -5
- package/src/payload/elevatable/ChainStakeIntent.ts +0 -45
- package/src/payload/elevatable/Executable.ts +0 -35
- package/src/payload/elevatable/Hash.ts +0 -25
- package/src/payload/elevatable/StepComplete.ts +0 -31
- package/src/payload/elevatable/Time.ts +0 -61
- package/src/payload/elevatable/index.ts +0 -6
- package/src/payload/index.ts +0 -2
- package/src/permissions/InvokerPermission.ts +0 -58
- package/src/permissions/XyoPermissions.ts +0 -41
- package/src/permissions/index.ts +0 -2
- package/src/provider/Provider.ts +0 -6
- package/src/provider/ProviderMoniker.ts +0 -15
- package/src/provider/index.ts +0 -2
- package/src/providers/DataLake/Provider.ts +0 -12
- package/src/providers/DataLake/Runner.ts +0 -16
- package/src/providers/DataLake/Viewer.ts +0 -16
- package/src/providers/DataLake/index.ts +0 -3
- package/src/providers/TransactionHelper.ts +0 -16
- package/src/providers/XyoClient.ts +0 -26
- package/src/providers/XyoConnection.ts +0 -19
- package/src/providers/XyoGateway.ts +0 -23
- package/src/providers/XyoGatewayRunner.ts +0 -76
- package/src/providers/XyoNetwork.ts +0 -8
- package/src/providers/XyoRunner.ts +0 -20
- package/src/providers/index.ts +0 -8
- package/src/providers/signer/XyoSigner.ts +0 -39
- package/src/providers/signer/index.ts +0 -1
- package/src/repository/Repository.ts +0 -32
- package/src/repository/TransactionReadRepository.ts +0 -6
- package/src/repository/TransactionRepository.ts +0 -12
- package/src/repository/TransactionRepositoryIterator.ts +0 -6
- package/src/repository/TransactionWriteRepository.ts +0 -5
- package/src/repository/index.ts +0 -5
- package/src/runners/Block.ts +0 -22
- package/src/runners/Finalization.ts +0 -19
- package/src/runners/Mempool.ts +0 -32
- package/src/runners/index.ts +0 -3
- package/src/transaction/TransactionBoundWitness.ts +0 -187
- package/src/transaction/TransactionFees.ts +0 -73
- package/src/transaction/TransactionGasCosts.ts +0 -42
- package/src/transaction/index.ts +0 -3
- package/src/validation/block/BlockValidationFunction.ts +0 -13
- package/src/validation/block/HydratedBlockStateValidationFunction.ts +0 -31
- package/src/validation/block/HydratedBlockValidationFunction.ts +0 -22
- package/src/validation/block/error.ts +0 -50
- package/src/validation/block/index.ts +0 -4
- package/src/validation/boundwitness/BoundWitnessValidationFunction.ts +0 -9
- package/src/validation/boundwitness/HydratedBoundWitnessValidationFunction.ts +0 -15
- package/src/validation/boundwitness/error.ts +0 -29
- package/src/validation/boundwitness/index.ts +0 -3
- package/src/validation/error.ts +0 -25
- package/src/validation/index.ts +0 -5
- package/src/validation/payload/InBlockPayloadValidationFunction.ts +0 -17
- package/src/validation/payload/error.ts +0 -24
- package/src/validation/payload/index.ts +0 -2
- package/src/validation/transaction/HydratedTransactionStateValidationFunction.ts +0 -27
- package/src/validation/transaction/HydratedTransactionValidationFunction.ts +0 -23
- package/src/validation/transaction/error.ts +0 -15
- package/src/validation/transaction/index.ts +0 -3
- package/src/viewers/Block.ts +0 -44
- package/src/viewers/BlockInvalidation.ts +0 -80
- package/src/viewers/BlockReward.ts +0 -19
- package/src/viewers/BlockValidation.ts +0 -80
- package/src/viewers/ChainContract.ts +0 -29
- package/src/viewers/ChainStakeViewer.ts +0 -14
- package/src/viewers/Finalization.ts +0 -24
- package/src/viewers/Fork.ts +0 -11
- package/src/viewers/Mempool.ts +0 -41
- package/src/viewers/NetworkStake/NetworkStakeViewer.ts +0 -20
- package/src/viewers/NetworkStake/Rewards/ByPositionViewer.ts +0 -18
- package/src/viewers/NetworkStake/Rewards/ByStakerViewer.ts +0 -20
- package/src/viewers/NetworkStake/Rewards/ByStepViewer.ts +0 -18
- package/src/viewers/NetworkStake/Rewards/Options.ts +0 -24
- package/src/viewers/NetworkStake/Rewards/TotalViewer.ts +0 -17
- package/src/viewers/NetworkStake/Rewards/Viewer.ts +0 -21
- package/src/viewers/NetworkStake/Rewards/index.ts +0 -7
- package/src/viewers/NetworkStake/Rewards/templates/ByIndexMethodsTemplate.ts +0 -7
- package/src/viewers/NetworkStake/Rewards/templates/MethodsTemplate.ts +0 -10
- package/src/viewers/NetworkStake/Rewards/templates/index.ts +0 -2
- package/src/viewers/NetworkStake/index.ts +0 -4
- package/src/viewers/NetworkStakeStepReward.ts +0 -83
- package/src/viewers/Stake.ts +0 -45
- package/src/viewers/StakeEvents.ts +0 -55
- package/src/viewers/StakeIntent.ts +0 -22
- package/src/viewers/StakeTotals.ts +0 -22
- package/src/viewers/StepStake.ts +0 -28
- package/src/viewers/StepViewer.ts +0 -57
- package/src/viewers/TimeSync.ts +0 -27
- package/src/viewers/Transaction.ts +0 -27
- package/src/viewers/TransactionInvalidation.ts +0 -70
- package/src/viewers/TransactionValidation.ts +0 -71
- package/src/viewers/TransferBalance.ts +0 -39
- package/src/viewers/WindowedBlock.ts +0 -22
- package/src/viewers/XyoViewer.ts +0 -74
- package/src/viewers/index.ts +0 -23
- package/src/xl1/AttoXL1.ts +0 -19
- package/src/xl1/FemtoXL1.ts +0 -20
- package/src/xl1/MicroXL1.ts +0 -20
- package/src/xl1/MilliXL1.ts +0 -20
- package/src/xl1/NanoXL1.ts +0 -20
- package/src/xl1/PicoXL1.ts +0 -20
- package/src/xl1/XL1.ts +0 -20
- package/src/xl1/XL1Units.ts +0 -26
- package/src/xl1/index.ts +0 -8
- package/src/xl1/isXL1Factory.ts +0 -56
- package/src/xl1/xl1MaxValue.ts +0 -2
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
import { HexZod } from '@xylabs/sdk-js'
|
|
2
|
-
import { z } from 'zod'
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Represents a transfer destination
|
|
6
|
-
*/
|
|
7
|
-
export const BridgeDetailsDestinationFieldsZod = z.object({
|
|
8
|
-
/**
|
|
9
|
-
* Destination network
|
|
10
|
-
*/
|
|
11
|
-
dest: HexZod.describe('The destination network identifier'),
|
|
12
|
-
/**
|
|
13
|
-
* Destination address (EOA or contract)
|
|
14
|
-
*/
|
|
15
|
-
destAddress: HexZod.describe('The destination address (EOA or contract)'),
|
|
16
|
-
/**
|
|
17
|
-
* Token amount to bridge to destination
|
|
18
|
-
*/
|
|
19
|
-
destAmount: HexZod.describe('The token amount to bridge to destination'),
|
|
20
|
-
/**
|
|
21
|
-
* Token being bridged to
|
|
22
|
-
*/
|
|
23
|
-
destToken: HexZod.describe('The token being bridged to'),
|
|
24
|
-
})
|
|
25
|
-
|
|
26
|
-
/**
|
|
27
|
-
* Represents a transfer destination
|
|
28
|
-
*/
|
|
29
|
-
export type BridgeDetailsDestinationFields = z.infer<typeof BridgeDetailsDestinationFieldsZod>
|
|
30
|
-
|
|
31
|
-
/**
|
|
32
|
-
* Represents a transfer source
|
|
33
|
-
*/
|
|
34
|
-
export const BridgeDetailsSourceFieldsZod = z.object({
|
|
35
|
-
/**
|
|
36
|
-
* Source network
|
|
37
|
-
*/
|
|
38
|
-
src: HexZod.describe('The source network identifier'),
|
|
39
|
-
|
|
40
|
-
/**
|
|
41
|
-
* Source address (EOA or contract)
|
|
42
|
-
*/
|
|
43
|
-
srcAddress: HexZod.describe('The source address (EOA or contract)'),
|
|
44
|
-
/**
|
|
45
|
-
* Token amount to bridge from source
|
|
46
|
-
*/
|
|
47
|
-
srcAmount: HexZod.describe('The token amount to bridge from source'),
|
|
48
|
-
/**
|
|
49
|
-
* Token being bridged from
|
|
50
|
-
*/
|
|
51
|
-
srcToken: HexZod.describe('The token being bridged from'),
|
|
52
|
-
})
|
|
53
|
-
|
|
54
|
-
/**
|
|
55
|
-
* Represents a transfer source
|
|
56
|
-
*/
|
|
57
|
-
export type BridgeDetailsSourceFields = z.infer<typeof BridgeDetailsSourceFieldsZod>
|
|
58
|
-
|
|
59
|
-
/**
|
|
60
|
-
* Represents a transfer from a source chain/token/address/amount to a destination chain/token/address/amount.
|
|
61
|
-
*/
|
|
62
|
-
export const BridgeDetailsFieldsZod = BridgeDetailsSourceFieldsZod.extend(
|
|
63
|
-
BridgeDetailsDestinationFieldsZod.shape,
|
|
64
|
-
)
|
|
65
|
-
|
|
66
|
-
/**
|
|
67
|
-
* Represents a transfer from a source chain/token/address/amount to a destination chain/token/address/amount.
|
|
68
|
-
*/
|
|
69
|
-
export type BridgeDetailsFields = z.infer<typeof BridgeDetailsFieldsZod>
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import { AsObjectFactory } from '@xylabs/sdk-js'
|
|
2
|
-
import type { Payload } from '@xyo-network/sdk-js'
|
|
3
|
-
import { asSchema, isPayloadOfZodType } from '@xyo-network/sdk-js'
|
|
4
|
-
import { z } from 'zod'
|
|
5
|
-
|
|
6
|
-
import { BridgeDetailsFieldsZod } from './BridgeDetails.ts'
|
|
7
|
-
|
|
8
|
-
/** Schema identifier for BridgeIntent payloads. */
|
|
9
|
-
export const BridgeIntentSchema = asSchema('network.xyo.chain.bridge.intent', true)
|
|
10
|
-
/** Schema type for BridgeIntent payloads. */
|
|
11
|
-
export type BridgeIntentSchema = typeof BridgeIntentSchema
|
|
12
|
-
|
|
13
|
-
/**
|
|
14
|
-
* Represents an Address's intent to initiate a token bridge.
|
|
15
|
-
*/
|
|
16
|
-
export const BridgeIntentFieldsZod = BridgeDetailsFieldsZod.extend({
|
|
17
|
-
/**
|
|
18
|
-
* Unique identifier for replay protection
|
|
19
|
-
*/
|
|
20
|
-
nonce: z.string().describe('Unique identifier for replay protection'),
|
|
21
|
-
})
|
|
22
|
-
|
|
23
|
-
/** BridgeIntentFields type. */
|
|
24
|
-
export type BridgeIntentFields = z.infer<typeof BridgeIntentFieldsZod>
|
|
25
|
-
|
|
26
|
-
/** BridgeIntent type. */
|
|
27
|
-
export type BridgeIntent = Payload<BridgeIntentFields, BridgeIntentSchema>
|
|
28
|
-
|
|
29
|
-
/** Type guard that checks if a value is a valid BridgeIntent. */
|
|
30
|
-
export const isBridgeIntent = isPayloadOfZodType<BridgeIntent>(
|
|
31
|
-
BridgeIntentFieldsZod,
|
|
32
|
-
BridgeIntentSchema,
|
|
33
|
-
)
|
|
34
|
-
|
|
35
|
-
/** Converts a value to BridgeIntent, throwing if invalid. */
|
|
36
|
-
export const asBridgeIntent = AsObjectFactory.create(isBridgeIntent)
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { AsObjectFactory, HexZod } from '@xylabs/sdk-js'
|
|
2
|
-
import type { Payload } from '@xyo-network/sdk-js'
|
|
3
|
-
import { asSchema, isPayloadOfZodType } from '@xyo-network/sdk-js'
|
|
4
|
-
import type { z } from 'zod'
|
|
5
|
-
|
|
6
|
-
import { BridgeDetailsFieldsZod } from './BridgeDetails.ts'
|
|
7
|
-
|
|
8
|
-
/** Schema identifier for BridgeSourceObservation payloads. */
|
|
9
|
-
export const BridgeSourceObservationSchema = asSchema('network.xyo.chain.bridge.observation.source', true)
|
|
10
|
-
/** Schema type for BridgeSourceObservation payloads. */
|
|
11
|
-
export type BridgeSourceObservationSchema = typeof BridgeSourceObservationSchema
|
|
12
|
-
|
|
13
|
-
/**
|
|
14
|
-
* Represents an observation that confirms a bridge action occurred on the source chain.
|
|
15
|
-
*/
|
|
16
|
-
export const BridgeSourceObservationFieldsZod = BridgeDetailsFieldsZod.extend({
|
|
17
|
-
/**
|
|
18
|
-
* Source chain confirmation
|
|
19
|
-
*/
|
|
20
|
-
srcConfirmation: HexZod.optional().describe('Source chain confirmation'),
|
|
21
|
-
})
|
|
22
|
-
|
|
23
|
-
/** BridgeSourceObservationFields type. */
|
|
24
|
-
export type BridgeSourceObservationFields = z.infer<typeof BridgeSourceObservationFieldsZod>
|
|
25
|
-
/**
|
|
26
|
-
* Represents an observation that confirms a bridge action occurred on the source chain.
|
|
27
|
-
*/
|
|
28
|
-
export type BridgeSourceObservation = Payload<BridgeSourceObservationFields, BridgeSourceObservationSchema>
|
|
29
|
-
|
|
30
|
-
/** Type guard that checks if a value is a valid BridgeSourceObservation. */
|
|
31
|
-
export const isBridgeSourceObservation = isPayloadOfZodType<BridgeSourceObservation>(
|
|
32
|
-
BridgeSourceObservationFieldsZod,
|
|
33
|
-
BridgeSourceObservationSchema,
|
|
34
|
-
)
|
|
35
|
-
|
|
36
|
-
/** Converts a value to BridgeSourceObservation, throwing if invalid. */
|
|
37
|
-
export const asBridgeSourceObservation = AsObjectFactory.create(isBridgeSourceObservation)
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import { AsObjectFactory } from '@xylabs/sdk-js'
|
|
2
|
-
import type { Payload, WithStorageMeta } from '@xyo-network/sdk-js'
|
|
3
|
-
import {
|
|
4
|
-
asSchema, isPayloadOfSchemaType, isStorageMeta,
|
|
5
|
-
} from '@xyo-network/sdk-js'
|
|
6
|
-
|
|
7
|
-
import type { BlockDuration } from '../../fields/index.ts'
|
|
8
|
-
import type { FromFields } from './Executable.ts'
|
|
9
|
-
|
|
10
|
-
/** Schema identifier for chain stake intent payloads. */
|
|
11
|
-
export const ChainStakeIntentSchema = asSchema('network.xyo.chain.stake.intent', true)
|
|
12
|
-
/** Schema type for ChainStakeIntent payloads. */
|
|
13
|
-
export type ChainStakeIntentSchema = typeof ChainStakeIntentSchema
|
|
14
|
-
|
|
15
|
-
/** The type of staking intent, currently limited to 'producer'. */
|
|
16
|
-
export type Intent = 'producer' // | 'bank'
|
|
17
|
-
|
|
18
|
-
/** Fields for a chain stake intent, including the staking intent type and source address. */
|
|
19
|
-
export interface ChainStakeIntentFields extends BlockDuration, FromFields {
|
|
20
|
-
/*
|
|
21
|
-
* The intent of the staking
|
|
22
|
-
*/
|
|
23
|
-
intent: Intent
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
/** A payload representing an intent to stake on the chain. */
|
|
27
|
-
export type ChainStakeIntent = Payload<ChainStakeIntentFields, ChainStakeIntentSchema>
|
|
28
|
-
|
|
29
|
-
/** Type guard that checks whether a value is a valid ChainStakeIntent with non-negative nbf and exp. */
|
|
30
|
-
export const isChainStakeIntent = (x?: unknown | null): x is ChainStakeIntent => {
|
|
31
|
-
return isPayloadOfSchemaType<ChainStakeIntent>(ChainStakeIntentSchema)(x)
|
|
32
|
-
&& asNonNegativeInteger(x.nbf) !== undefined
|
|
33
|
-
&& asNonNegativeInteger(x.exp) !== undefined
|
|
34
|
-
}
|
|
35
|
-
/** Casts a value to ChainStakeIntent or returns undefined if it does not match. */
|
|
36
|
-
export const asChainStakeIntent = AsObjectFactory.create(isChainStakeIntent)
|
|
37
|
-
|
|
38
|
-
/** Type guard that checks whether a value is a ChainStakeIntent with storage metadata. */
|
|
39
|
-
export const isChainStakeIntentWithStorageMeta = (x?: unknown | null): x is WithStorageMeta<ChainStakeIntent> => {
|
|
40
|
-
return isChainStakeIntent(x) && isStorageMeta(x)
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
const asNonNegativeInteger = (num: number) => {
|
|
44
|
-
return (Number.isInteger(num) && num >= 0) ? num : undefined
|
|
45
|
-
}
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import type { Address, EmptyObject } from '@xylabs/sdk-js'
|
|
2
|
-
import { isAnyPayload } from '@xyo-network/sdk-js'
|
|
3
|
-
|
|
4
|
-
/** FromFields interface. */
|
|
5
|
-
export interface FromFields {
|
|
6
|
-
// the address that is treated as the source of this action
|
|
7
|
-
from: Address
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
/** hasFrom constant. */
|
|
11
|
-
export const hasFrom = (value: unknown): value is FromFields => {
|
|
12
|
-
return (value as FromFields).from !== undefined
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
/** ExecutableFields interface. */
|
|
16
|
-
export interface ExecutableFields {
|
|
17
|
-
script: string[]
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
/** Executable type. */
|
|
21
|
-
export type Executable<T extends EmptyObject = EmptyObject> = T & ExecutableFields
|
|
22
|
-
/** OptionalExecutable type. */
|
|
23
|
-
export type OptionalExecutable<T extends EmptyObject = EmptyObject> = T & Partial<ExecutableFields>
|
|
24
|
-
|
|
25
|
-
/** Type guard that checks if a value is a valid Executable. */
|
|
26
|
-
export const isExecutable = <T extends EmptyObject>(value: T | undefined): value is Executable<T> => {
|
|
27
|
-
return isAnyPayload(value) && Array.isArray((value as unknown as ExecutableFields).script)
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
/** Converts a value to Executable, throwing if invalid. */
|
|
31
|
-
export const asExecutable = <T extends EmptyObject>(value: T | undefined): Executable<T> | undefined => {
|
|
32
|
-
return isExecutable(value)
|
|
33
|
-
? value as unknown as Executable<T>
|
|
34
|
-
: undefined
|
|
35
|
-
}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import type { Hash } from '@xylabs/sdk-js'
|
|
2
|
-
import { AsObjectFactory } from '@xylabs/sdk-js'
|
|
3
|
-
import type { Payload } from '@xyo-network/sdk-js'
|
|
4
|
-
import { asSchema, isPayloadOfSchemaType } from '@xyo-network/sdk-js'
|
|
5
|
-
|
|
6
|
-
/** Schema identifier for hash payloads. */
|
|
7
|
-
export const HashSchema = asSchema('network.xyo.hash', true)
|
|
8
|
-
/** Schema type for Hash payloads. */
|
|
9
|
-
export type HashSchema = typeof HashSchema
|
|
10
|
-
|
|
11
|
-
/** Fields for a hash payload containing a single hash value. */
|
|
12
|
-
export interface HashFields {
|
|
13
|
-
hash: Hash
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
/** A payload containing a hash value. */
|
|
17
|
-
export type HashPayload = Payload<HashFields, HashSchema>
|
|
18
|
-
|
|
19
|
-
/** Type guard that checks whether a value is a HashPayload. */
|
|
20
|
-
export const isHashPayload = isPayloadOfSchemaType<HashPayload>(HashSchema)
|
|
21
|
-
|
|
22
|
-
/** Casts a value to HashPayload or returns undefined if it does not match. */
|
|
23
|
-
export const asHashPayload = AsObjectFactory.create(isHashPayload)
|
|
24
|
-
/** Casts a value to HashPayload with storage metadata or returns undefined. */
|
|
25
|
-
export const asHashPayloadWithStorageMeta = AsObjectFactory.create(isHashPayload)
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import type { Hash } from '@xylabs/sdk-js'
|
|
2
|
-
import { AsObjectFactory } from '@xylabs/sdk-js'
|
|
3
|
-
import type { Payload } from '@xyo-network/sdk-js'
|
|
4
|
-
import { asSchema, isPayloadOfSchemaType } from '@xyo-network/sdk-js'
|
|
5
|
-
|
|
6
|
-
import type { FromFields } from './Executable.ts'
|
|
7
|
-
|
|
8
|
-
/** Schema identifier for StepComplete payloads. */
|
|
9
|
-
export const StepCompleteSchema = asSchema('network.xyo.chain.step.complete', true)
|
|
10
|
-
/** Schema type for StepComplete payloads. */
|
|
11
|
-
export type StepCompleteSchema = typeof StepCompleteSchema
|
|
12
|
-
|
|
13
|
-
/* This records the completion of a step in the network - needed for network staking rewards */
|
|
14
|
-
/* We will only write these for steps that are eligible for rewards Step 3 (2311) */
|
|
15
|
-
|
|
16
|
-
export interface StepCompleteFields extends FromFields {
|
|
17
|
-
block: number /* The block number on the XL1 network */
|
|
18
|
-
hash: Hash /* The Step Hash */
|
|
19
|
-
size: number /* The size of the step */
|
|
20
|
-
stakeBlock: number /* The block number on ethereum or other staking system */
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
// if this payload is included in a boundwitness, it needs to be available for inspection to be included in block
|
|
24
|
-
/** StepComplete type. */
|
|
25
|
-
export type StepComplete = Payload<StepCompleteFields, StepCompleteSchema>
|
|
26
|
-
|
|
27
|
-
/** Type guard that checks if a value is a valid StepComplete. */
|
|
28
|
-
export const isStepComplete = isPayloadOfSchemaType<StepComplete>(StepCompleteSchema)
|
|
29
|
-
|
|
30
|
-
/** Converts a value to StepComplete, throwing if invalid. */
|
|
31
|
-
export const asStepComplete = AsObjectFactory.create(isStepComplete)
|
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
import { AsObjectFactory, HashZod } from '@xylabs/sdk-js'
|
|
2
|
-
import {
|
|
3
|
-
asSchema, isPayloadOfSchemaType, PayloadZodOfSchema,
|
|
4
|
-
} from '@xyo-network/sdk-js'
|
|
5
|
-
import { z } from 'zod'
|
|
6
|
-
|
|
7
|
-
// xl1 = xl1 block number, epoch = epoch number, ethereum = ethereum block number
|
|
8
|
-
/** Supported time domains: xl1 block number, epoch timestamp, or ethereum block number. */
|
|
9
|
-
export type TimeDomain = 'xl1' | 'epoch' | 'ethereum'
|
|
10
|
-
|
|
11
|
-
/** Schema identifier for time payloads. */
|
|
12
|
-
export const TimeSchema = asSchema('network.xyo.time', true)
|
|
13
|
-
/** Schema type for Time payloads. */
|
|
14
|
-
export type TimeSchema = typeof TimeSchema
|
|
15
|
-
|
|
16
|
-
/** Zod schema for XL1 time fields including block number and hash. */
|
|
17
|
-
export const XL1TimeFieldsZod = z.object({
|
|
18
|
-
// block number
|
|
19
|
-
xl1: z.number().optional(),
|
|
20
|
-
// block hash
|
|
21
|
-
xl1Hash: HashZod.optional(),
|
|
22
|
-
})
|
|
23
|
-
|
|
24
|
-
/** Zod schema for Ethereum time fields including block number and hash. */
|
|
25
|
-
export const EthereumTimeFieldsZod = z.object({
|
|
26
|
-
// block number
|
|
27
|
-
ethereum: z.number().optional(),
|
|
28
|
-
// block hash
|
|
29
|
-
ethereumHash: HashZod.optional(),
|
|
30
|
-
})
|
|
31
|
-
|
|
32
|
-
/** Zod schema for epoch time fields in milliseconds. */
|
|
33
|
-
export const EpochTimeFieldsZod = z.object({
|
|
34
|
-
// in milliseconds
|
|
35
|
-
epoch: z.number(),
|
|
36
|
-
})
|
|
37
|
-
|
|
38
|
-
/** Combined Zod schema for all time fields across XL1, Ethereum, and epoch domains. */
|
|
39
|
-
export const TimeFieldsZod = XL1TimeFieldsZod.extend(XL1TimeFieldsZod.shape).extend(EthereumTimeFieldsZod.shape).extend(EpochTimeFieldsZod.shape)
|
|
40
|
-
|
|
41
|
-
/** Zod schema for a complete time payload including schema and all time fields. */
|
|
42
|
-
export const TimePayloadZod = PayloadZodOfSchema(TimeSchema).extend(TimeFieldsZod.shape)
|
|
43
|
-
|
|
44
|
-
/** A payload containing time information across multiple domains. */
|
|
45
|
-
export type TimePayload = z.infer<typeof TimePayloadZod>
|
|
46
|
-
|
|
47
|
-
// to prevent scaling problems, we use double the current time as a max safe epoch
|
|
48
|
-
/** Checks whether a value is a safe epoch timestamp (less than double the current time). */
|
|
49
|
-
export const isSafeEpoch = (value: unknown): value is number => {
|
|
50
|
-
return typeof value === 'number' && value < 2 * Date.now()
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
/** Type guard that checks whether a value is a valid TimePayload with a safe epoch. */
|
|
54
|
-
export const isTimePayload = (value: unknown): value is TimePayload => {
|
|
55
|
-
return isPayloadOfSchemaType<TimePayload>(TimeSchema)(value) && isSafeEpoch(value.epoch)
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
/** Casts a value to TimePayload or returns undefined if it does not match. */
|
|
59
|
-
export const asTimePayload = AsObjectFactory.create(isTimePayload)
|
|
60
|
-
/** Casts a value to TimePayload with storage metadata or returns undefined. */
|
|
61
|
-
export const asTimePayloadWithStorageMeta = AsObjectFactory.create(isTimePayload)
|
package/src/payload/index.ts
DELETED
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
import type { JsonValue } from '@xylabs/sdk-js'
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Modeled after EIP-2255
|
|
5
|
-
* See - https://eips.ethereum.org/EIPS/eip-2255#specification
|
|
6
|
-
*
|
|
7
|
-
* In order to send multiple permission requests at once, do not send multiple parentCapability keys.
|
|
8
|
-
* Instead, send multiple PermissionRequest objects in the params array of the rpc call.
|
|
9
|
-
*/
|
|
10
|
-
export interface PermissionRequest {
|
|
11
|
-
[parentCapability: string]: {
|
|
12
|
-
[caveatName: string]: JsonValue
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* Modeled after EIP-2255
|
|
18
|
-
* See - https://eips.ethereum.org/EIPS/eip-2255#specification
|
|
19
|
-
*/
|
|
20
|
-
export interface RequestedPermission {
|
|
21
|
-
/** Optional timestamp for when the permission was granted */
|
|
22
|
-
date?: number
|
|
23
|
-
/** Permission identifier (i.e. RPC method, action, etc.) */
|
|
24
|
-
parentCapability: string
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
/** CaveatTypes type. */
|
|
28
|
-
export type CaveatTypes = 'chain' | 'expiration' | 'filteredResponse' | 'rateLimit' | 'restrictReturnedAccounts'
|
|
29
|
-
|
|
30
|
-
/**
|
|
31
|
-
* Modeled after EIP-2255
|
|
32
|
-
* See - https://eips.ethereum.org/EIPS/eip-2255#specification
|
|
33
|
-
*/
|
|
34
|
-
export interface Caveats {
|
|
35
|
-
/** Type of caveat */
|
|
36
|
-
type: CaveatTypes
|
|
37
|
-
/** Value for the caveat (i.e. chain id, subset of accounts, expiration, max request per minute, etc.) */
|
|
38
|
-
value: JsonValue
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* Modeled after EIP-2255
|
|
43
|
-
* See - https://eips.ethereum.org/EIPS/eip-2255#specification
|
|
44
|
-
*/
|
|
45
|
-
export interface Permission {
|
|
46
|
-
/** Caveats for the permission, if applicable (i.e. allowed accounts, signing, etc.) */
|
|
47
|
-
caveats?: Caveats[]
|
|
48
|
-
/** Invoker for the given permission (URI, domain, webpage, address, etc.) */
|
|
49
|
-
invoker: string
|
|
50
|
-
/** Permission identifier (i.e. RPC method, action, etc.) */
|
|
51
|
-
parentCapability: string
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
/** InvokerPermission interface. */
|
|
55
|
-
export interface InvokerPermission extends Permission {
|
|
56
|
-
/** Time at which the permission was granted */
|
|
57
|
-
date?: number
|
|
58
|
-
}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
InvokerPermission, PermissionRequest, RequestedPermission,
|
|
3
|
-
} from './InvokerPermission.ts'
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* Handles Getting Permissions
|
|
7
|
-
*/
|
|
8
|
-
export interface PermissionsGetHandler {
|
|
9
|
-
/**
|
|
10
|
-
* Returns the permissions that are currently granted
|
|
11
|
-
*
|
|
12
|
-
* Per the spec - "The wallet_getPermissions method is used for getting an array of current permissions
|
|
13
|
-
* (empty by default). It takes no parameters and returns an array of Permission objects."
|
|
14
|
-
*
|
|
15
|
-
* See - https://eips.ethereum.org/EIPS/eip-2255#specification
|
|
16
|
-
*/
|
|
17
|
-
getPermissions(): Promise<InvokerPermission[]>
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
/**
|
|
21
|
-
* Handles Permission Requests
|
|
22
|
-
*/
|
|
23
|
-
export interface PermissionRequestsHandler {
|
|
24
|
-
// Given a permissions request, attempts to request the permissions from the user
|
|
25
|
-
requestPermissions(permissions: PermissionRequest[]): Promise<RequestedPermission[]>
|
|
26
|
-
// Given a permissions request, attempts to revoke the permissions from the user
|
|
27
|
-
revokePermissions(permissions: PermissionRequest): Promise<RequestedPermission[]>
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
/**
|
|
31
|
-
* Interface for getting, requesting and revoking permissions
|
|
32
|
-
*
|
|
33
|
-
* See - https://eips.ethereum.org/EIPS/eip-2255
|
|
34
|
-
*/
|
|
35
|
-
export interface XyoPermissions extends PermissionsGetHandler, PermissionRequestsHandler {
|
|
36
|
-
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
// @deprecated - use XyoPermissions instead
|
|
40
|
-
/** PermissionsProvider interface. */
|
|
41
|
-
export interface PermissionsProvider extends XyoPermissions {}
|
package/src/permissions/index.ts
DELETED
package/src/provider/Provider.ts
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { assertEx, isString } from '@xylabs/sdk-js'
|
|
2
|
-
|
|
3
|
-
/** Type literal for the Provider provider moniker. */
|
|
4
|
-
export type ProviderMoniker = string
|
|
5
|
-
|
|
6
|
-
/** Moniker identifier for the asProvider provider. */
|
|
7
|
-
export const asProviderMoniker = <T>(value: T) => {
|
|
8
|
-
const moniker = isString(value) ? (value as unknown as ProviderMoniker) : undefined
|
|
9
|
-
return assertEx(moniker)
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
/** Moniker identifier for the DefaultProvider provider. */
|
|
13
|
-
export const DefaultProviderMoniker = 'Provider' as const
|
|
14
|
-
/** Type literal for the DefaultProvider provider moniker. */
|
|
15
|
-
export type DefaultProviderMoniker = typeof DefaultProviderMoniker
|
package/src/provider/index.ts
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import type { Payload, Schema } from '@xyo-network/sdk-js'
|
|
2
|
-
|
|
3
|
-
import type { Provider, ProviderMoniker } from '../../provider/index.ts'
|
|
4
|
-
|
|
5
|
-
/** DataLakeData type. */
|
|
6
|
-
export type DataLakeData = Payload | ArrayBuffer
|
|
7
|
-
|
|
8
|
-
/** DataLakeProvider interface. */
|
|
9
|
-
export interface DataLakeProvider<TMoniker extends ProviderMoniker = ProviderMoniker> extends Provider<TMoniker> {
|
|
10
|
-
allowedSchemas?: Schema[]
|
|
11
|
-
disallowedSchemas?: Schema[]
|
|
12
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import type { Hash } from '@xylabs/sdk-js'
|
|
2
|
-
import type { WriteArchivistFunctions } from '@xyo-network/sdk-js'
|
|
3
|
-
|
|
4
|
-
import type { DataLakeData, DataLakeProvider } from './Provider.ts'
|
|
5
|
-
import type { DataLakeViewer, DataLakeViewerMethods } from './Viewer.ts'
|
|
6
|
-
|
|
7
|
-
/** Moniker identifier for the DataLakeRunner provider. */
|
|
8
|
-
export const DataLakeRunnerMoniker = 'DataLakeRunner' as const
|
|
9
|
-
/** Type literal for the DataLakeRunner provider moniker. */
|
|
10
|
-
export type DataLakeRunnerMoniker = typeof DataLakeRunnerMoniker
|
|
11
|
-
|
|
12
|
-
/** DataLakeRunnerMethods interface. */
|
|
13
|
-
export interface DataLakeRunnerMethods extends WriteArchivistFunctions<DataLakeData, DataLakeData, DataLakeData, Hash>, DataLakeViewerMethods {}
|
|
14
|
-
|
|
15
|
-
/** Runner interface for executing DataLake operations. */
|
|
16
|
-
export interface DataLakeRunner extends DataLakeProvider<DataLakeRunnerMoniker>, DataLakeRunnerMethods, Omit<DataLakeViewer, 'moniker'> {}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import type { Hash } from '@xylabs/sdk-js'
|
|
2
|
-
import type { ReadArchivistFunctions, Sequence } from '@xyo-network/sdk-js'
|
|
3
|
-
|
|
4
|
-
import type { DataLakeData, DataLakeProvider } from './Provider.ts'
|
|
5
|
-
|
|
6
|
-
/** Moniker identifier for the DataLakeViewer provider. */
|
|
7
|
-
export const DataLakeViewerMoniker = 'DataLakeViewer' as const
|
|
8
|
-
/** Type literal for the DataLakeViewer provider moniker. */
|
|
9
|
-
export type DataLakeViewerMoniker = typeof DataLakeViewerMoniker
|
|
10
|
-
|
|
11
|
-
/** DataLakeViewerMethods interface. */
|
|
12
|
-
export interface DataLakeViewerMethods extends ReadArchivistFunctions<DataLakeData, Hash, Sequence> {}
|
|
13
|
-
|
|
14
|
-
/** Viewer interface for reading DataLake data. */
|
|
15
|
-
export interface DataLakeViewer extends DataLakeProvider<DataLakeViewerMoniker>, DataLakeViewerMethods {
|
|
16
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/* eslint-disable @typescript-eslint/member-ordering */
|
|
2
|
-
import type { Payload } from '@xyo-network/sdk-js'
|
|
3
|
-
|
|
4
|
-
import type { UnsignedHydratedTransaction } from '../model/index.ts'
|
|
5
|
-
|
|
6
|
-
/** TransactionHelper interface. */
|
|
7
|
-
export interface TransactionHelper {
|
|
8
|
-
// build tx, sign tx, send tx
|
|
9
|
-
addPayloadsToChain(onChain: Payload[], offChain: Payload[]): void
|
|
10
|
-
|
|
11
|
-
// sign tx, send tx
|
|
12
|
-
addUnsignedTransactionToChain(tx: UnsignedHydratedTransaction): void
|
|
13
|
-
|
|
14
|
-
// send tx (primitive)
|
|
15
|
-
addSignedTransactionToChain(tx: UnsignedHydratedTransaction): void
|
|
16
|
-
}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import type { GatewayName } from '../model/index.ts'
|
|
2
|
-
import type { XyoPermissions } from '../permissions/index.ts'
|
|
3
|
-
import type { XyoGateway } from './XyoGateway.ts'
|
|
4
|
-
import type { XyoGatewayRunner } from './XyoGatewayRunner.ts'
|
|
5
|
-
|
|
6
|
-
/** @deprecated */
|
|
7
|
-
export interface XyoGatewayConfig {
|
|
8
|
-
name: GatewayName
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
/** @deprecated */
|
|
12
|
-
export interface XyoRpcGatewayConfig extends XyoGatewayConfig {
|
|
13
|
-
dataLakeEndpoint: string
|
|
14
|
-
networkEndpoint: string
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
/** XyoClient interface. */
|
|
18
|
-
export interface XyoClient {
|
|
19
|
-
gateways: Readonly<Partial<Record<GatewayName, XyoGatewayRunner>>>
|
|
20
|
-
permissions: XyoPermissions
|
|
21
|
-
|
|
22
|
-
/** @deprecated */
|
|
23
|
-
addGateway?(providerOrConfig: XyoGatewayConfig | XyoRpcGatewayConfig | XyoGateway): Promise<XyoGateway>
|
|
24
|
-
/** @deprecated */
|
|
25
|
-
removeGateway?(name: GatewayName): Promise<void>
|
|
26
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import type { Provider } from '../provider/index.ts'
|
|
2
|
-
import type { NetworkStakeViewer, XyoViewer } from '../viewers/index.ts'
|
|
3
|
-
import type { DataLakeRunner, DataLakeViewer } from './DataLake/index.ts'
|
|
4
|
-
import type { XyoNetwork } from './XyoNetwork.ts'
|
|
5
|
-
import type { XyoRunner } from './XyoRunner.ts'
|
|
6
|
-
|
|
7
|
-
/** Moniker identifier for the XyoConnection provider. */
|
|
8
|
-
export const XyoConnectionMoniker = 'XyoConnection' as const
|
|
9
|
-
/** Type literal for the XyoConnection provider moniker. */
|
|
10
|
-
export type XyoConnectionMoniker = typeof XyoConnectionMoniker
|
|
11
|
-
|
|
12
|
-
/** XyoConnection interface. */
|
|
13
|
-
export interface XyoConnection extends Provider<XyoConnectionMoniker> {
|
|
14
|
-
network?: XyoNetwork
|
|
15
|
-
networkStake?: NetworkStakeViewer
|
|
16
|
-
runner?: XyoRunner
|
|
17
|
-
storage?: DataLakeRunner | DataLakeViewer | (DataLakeRunner & DataLakeViewer)
|
|
18
|
-
viewer?: XyoViewer
|
|
19
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import type { Provider, ProviderMoniker } from '../provider/index.ts'
|
|
2
|
-
import type { XyoConnection } from './XyoConnection.ts'
|
|
3
|
-
|
|
4
|
-
/** Moniker identifier for the XyoGateway provider. */
|
|
5
|
-
export const XyoGatewayMoniker = 'XyoGateway' as const
|
|
6
|
-
/** Type literal for the XyoGateway provider moniker. */
|
|
7
|
-
export type XyoGatewayMoniker = typeof XyoGatewayMoniker
|
|
8
|
-
|
|
9
|
-
/** XyoGatewayMethods interface. */
|
|
10
|
-
export interface XyoGatewayMethods {}
|
|
11
|
-
|
|
12
|
-
/** XyoGatewayProvider interface. */
|
|
13
|
-
export interface XyoGatewayProvider<
|
|
14
|
-
TMoniker extends ProviderMoniker = ProviderMoniker> extends XyoGatewayMethods, Provider<TMoniker> {
|
|
15
|
-
/**
|
|
16
|
-
* Returns the connection provider for this gateway.
|
|
17
|
-
*/
|
|
18
|
-
connection: XyoConnection
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
/** XyoGateway interface. */
|
|
22
|
-
export interface XyoGateway extends XyoGatewayProvider<XyoGatewayMoniker>, Provider<XyoGatewayMoniker> {
|
|
23
|
-
}
|