@shelby-protocol/sdk 0.0.9 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser/index.d.ts +17 -10
- package/dist/browser/index.mjs +89 -28
- package/dist/{chunk-XWAPNLU6.mjs → chunk-2WEX3K7C.mjs} +6 -4
- package/dist/chunk-4MG4XGY4.mjs +91 -0
- package/dist/{chunk-SEXQTDX6.mjs → chunk-4ZOFT75Q.mjs} +16 -2
- package/dist/{chunk-BTHSKDJR.mjs → chunk-7PN65RDX.mjs} +44 -10
- package/dist/chunk-AABBONAF.mjs +34 -0
- package/dist/{chunk-ZPW742E7.mjs → chunk-AUQDI5BS.mjs} +17 -2
- package/dist/{chunk-HFGEQP5N.mjs → chunk-CGYJLKBU.mjs} +4 -4
- package/dist/chunk-CQ6QPIZK.mjs +37 -0
- package/dist/{chunk-VRLIOKWG.mjs → chunk-D6GQHO6G.mjs} +5 -1
- package/dist/chunk-E5QCRTBU.mjs +493 -0
- package/dist/chunk-HPPMI7DC.mjs +56 -0
- package/dist/chunk-IE6LYVIA.mjs +26 -0
- package/dist/{chunk-67F5YZ25.mjs → chunk-JTXYKO3U.mjs} +10 -0
- package/dist/{chunk-WJKSPJSS.mjs → chunk-KJ24NKPH.mjs} +46 -0
- package/dist/{chunk-WBFEX7OM.mjs → chunk-MV6FNYAU.mjs} +31 -7
- package/dist/{chunk-PZF2VTGP.mjs → chunk-NHWWORCH.mjs} +3 -1
- package/dist/{chunk-NLPIHQ7K.mjs → chunk-OGKZ575S.mjs} +6 -19
- package/dist/{chunk-5I3MBJGN.mjs → chunk-PJVWGMVI.mjs} +164 -35
- package/dist/{chunk-7UVMDCCR.mjs → chunk-SRV4YWFH.mjs} +232 -47
- package/dist/chunk-W37FZSMA.mjs +83 -0
- package/dist/chunk-WTICJPDB.mjs +0 -0
- package/dist/chunk-Z4FZ7W6L.mjs +39 -0
- package/dist/{chunk-QFWQ7FIC.mjs → chunk-ZEDD2MPU.mjs} +1 -1
- package/dist/{clay-codes-pdZFxI_B.d.ts → clay-codes-DHP-bYcP.d.ts} +6 -2
- package/dist/core/blobs.d.ts +2 -0
- package/dist/core/chunk.d.ts +10 -1
- package/dist/core/chunk.mjs +2 -2
- package/dist/core/clients/ShelbyBlobClient.d.ts +165 -12
- package/dist/core/clients/ShelbyBlobClient.mjs +13 -11
- package/dist/core/clients/ShelbyClient.d.ts +21 -4
- package/dist/core/clients/ShelbyClient.mjs +17 -14
- package/dist/core/clients/ShelbyClientConfig.d.ts +7 -2
- package/dist/{node → core}/clients/ShelbyMetadataClient.d.ts +3 -3
- package/dist/core/clients/ShelbyMetadataClient.mjs +9 -0
- package/dist/core/clients/ShelbyMicropaymentChannelClient.d.ts +349 -0
- package/dist/core/clients/ShelbyMicropaymentChannelClient.mjs +16 -0
- package/dist/core/clients/ShelbyPlacementGroupClient.d.ts +73 -0
- package/dist/core/clients/ShelbyPlacementGroupClient.mjs +11 -0
- package/dist/core/clients/ShelbyRPCClient.d.ts +30 -4
- package/dist/core/clients/ShelbyRPCClient.mjs +8 -8
- package/dist/core/clients/index.d.ts +11 -5
- package/dist/core/clients/index.mjs +35 -15
- package/dist/core/clients/utils.d.ts +54 -0
- package/dist/core/clients/utils.mjs +1 -1
- package/dist/core/commitments.d.ts +6 -2
- package/dist/core/commitments.mjs +5 -3
- package/dist/core/constants.d.ts +18 -3
- package/dist/core/constants.mjs +5 -1
- package/dist/core/erasure/clay-codes.d.ts +1 -1
- package/dist/core/erasure/clay-codes.mjs +5 -5
- package/dist/core/erasure/constants.d.ts +15 -3
- package/dist/core/erasure/constants.mjs +3 -1
- package/dist/core/erasure/default.d.ts +5 -2
- package/dist/core/erasure/default.mjs +12 -6
- package/dist/core/erasure/index.d.ts +3 -3
- package/dist/core/erasure/index.mjs +15 -7
- package/dist/core/erasure/provider.d.ts +1 -1
- package/dist/core/erasure/reed-solomon.d.ts +1 -1
- package/dist/core/erasure/reed-solomon.mjs +1 -1
- package/dist/core/erasure/utils.d.ts +1 -1
- package/dist/core/errors.d.ts +58 -0
- package/dist/core/errors.mjs +15 -0
- package/dist/core/index.d.ts +17 -10
- package/dist/core/index.mjs +89 -28
- package/dist/core/layout.d.ts +5 -16
- package/dist/core/layout.mjs +3 -9
- package/dist/core/networks.d.ts +1 -1
- package/dist/core/networks.mjs +1 -1
- package/dist/core/operations/generated/sdk.d.ts +207 -17
- package/dist/core/operations/generated/sdk.mjs +7 -1
- package/dist/core/operations/index.d.ts +9 -3
- package/dist/core/operations/index.mjs +10 -4
- package/dist/core/rpc-responses.d.ts +69 -0
- package/dist/core/rpc-responses.mjs +15 -0
- package/dist/core/types/blobs.d.ts +8 -4
- package/dist/core/types/encodings.d.ts +1 -1
- package/dist/core/types/index.d.ts +4 -2
- package/dist/core/types/index.mjs +12 -2
- package/dist/core/types/payments.d.ts +94 -0
- package/dist/core/types/payments.mjs +9 -0
- package/dist/core/types/placement_groups.d.ts +30 -1
- package/dist/core/types/placement_groups.mjs +1 -0
- package/dist/core/types/storage_providers.d.ts +32 -2
- package/dist/node/clients/ShelbyNodeClient.d.ts +9 -6
- package/dist/node/clients/ShelbyNodeClient.mjs +18 -15
- package/dist/node/clients/index.d.ts +7 -6
- package/dist/node/clients/index.mjs +19 -17
- package/dist/node/index.d.ts +17 -11
- package/dist/node/index.mjs +91 -34
- package/package.json +3 -2
- package/dist/chunk-CPNZAQVY.mjs +0 -29
- package/dist/chunk-GY5DCVVL.mjs +0 -86
- package/dist/chunk-RBFWGDMY.mjs +0 -30
- package/dist/node/clients/ShelbyMetadataClient.mjs +0 -9
- /package/dist/{chunk-DJJD2AXO.mjs → chunk-AD2G3QYD.mjs} +0 -0
- /package/dist/{chunk-MWDW4ROU.mjs → chunk-EM67QTMR.mjs} +0 -0
- /package/dist/{chunk-RNXGC54D.mjs → chunk-QQ57OGQ2.mjs} +0 -0
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
export { BlobActivity, BlobActivityType, BlobEncoding, BlobMetadata, ClayEncoding, StorageProviderAck } from './blobs.js';
|
|
2
|
-
export {
|
|
2
|
+
export { ChannelInfo, SenderBuiltMicropayment, StaleChannelStateError } from './payments.js';
|
|
3
|
+
export { PlacementGroupInfo, PlacementGroupSlot, PlacementGroupSlotStatus } from './placement_groups.js';
|
|
4
|
+
export { ActiveStateDetails, FrozenStateDetails, StorageProviderInfo, StorageProviderStateDetails, WaitlistedStateDetails } from './storage_providers.js';
|
|
3
5
|
import '@aptos-labs/ts-sdk';
|
|
4
|
-
import '../../clay-codes-
|
|
6
|
+
import '../../clay-codes-DHP-bYcP.js';
|
|
5
7
|
import '@shelby-protocol/clay-codes';
|
|
6
8
|
import '../layout.js';
|
|
7
9
|
import 'zod';
|
|
@@ -1,3 +1,13 @@
|
|
|
1
|
-
import "../../chunk-
|
|
2
|
-
import "../../chunk-MQUVYMNQ.mjs";
|
|
1
|
+
import "../../chunk-QQ57OGQ2.mjs";
|
|
3
2
|
import "../../chunk-ZHXCVRZX.mjs";
|
|
3
|
+
import "../../chunk-AD2G3QYD.mjs";
|
|
4
|
+
import "../../chunk-MQUVYMNQ.mjs";
|
|
5
|
+
import {
|
|
6
|
+
SenderBuiltMicropayment,
|
|
7
|
+
StaleChannelStateError
|
|
8
|
+
} from "../../chunk-4MG4XGY4.mjs";
|
|
9
|
+
import "../../chunk-7P6ASYW6.mjs";
|
|
10
|
+
export {
|
|
11
|
+
SenderBuiltMicropayment,
|
|
12
|
+
StaleChannelStateError
|
|
13
|
+
};
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { Serializable, MultiAgentTransaction, AccountAuthenticator, Serializer, Hex, AccountAddress } from '@aptos-labs/ts-sdk';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Error thrown when a micropayment is stale (sequence number or amount is behind
|
|
5
|
+
* the server's stored state). This can happen if the client lost their local state.
|
|
6
|
+
*
|
|
7
|
+
* The error includes the server's stored micropayment, which the client can use
|
|
8
|
+
* to reset their local channel state and retry.
|
|
9
|
+
*/
|
|
10
|
+
declare class StaleChannelStateError extends Error {
|
|
11
|
+
/**
|
|
12
|
+
* The last valid micropayment stored by the server.
|
|
13
|
+
* Clients can use this to reset their local channel state.
|
|
14
|
+
*/
|
|
15
|
+
readonly storedMicropayment: SenderBuiltMicropayment;
|
|
16
|
+
constructor(storedMicropayment: SenderBuiltMicropayment, message?: string);
|
|
17
|
+
/**
|
|
18
|
+
* Returns the stored micropayment as a base64-encoded string.
|
|
19
|
+
*/
|
|
20
|
+
toBase64(): string;
|
|
21
|
+
/**
|
|
22
|
+
* Creates a StaleChannelStateError from a base64-encoded micropayment string.
|
|
23
|
+
*/
|
|
24
|
+
static fromBase64(base64: string, message?: string): StaleChannelStateError;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* A handy container for the things that constitute a half-built micropayment. It
|
|
28
|
+
* still needs to be signed and submitted by the receiver.
|
|
29
|
+
*/
|
|
30
|
+
declare class SenderBuiltMicropayment implements Serializable {
|
|
31
|
+
/**
|
|
32
|
+
* The actual micropayment transaction. It is built with the receiver address as fee payer and also requires a signature from the receiver to submit.
|
|
33
|
+
*/
|
|
34
|
+
readonly micropayment: MultiAgentTransaction;
|
|
35
|
+
/**
|
|
36
|
+
* The sender's signature.
|
|
37
|
+
*/
|
|
38
|
+
readonly senderSignature: AccountAuthenticator;
|
|
39
|
+
constructor(micropayment: MultiAgentTransaction, senderSignature: AccountAuthenticator);
|
|
40
|
+
serialize(serializer: Serializer): void;
|
|
41
|
+
bcsToBytes(): Uint8Array;
|
|
42
|
+
bcsToHex(): Hex;
|
|
43
|
+
toStringWithoutPrefix(): string;
|
|
44
|
+
toString(): string;
|
|
45
|
+
/**
|
|
46
|
+
* Deserializes a SenderBuiltMicropayment from BCS bytes.
|
|
47
|
+
* @param bytes - The bytes to deserialize from (Uint8Array or hex string).
|
|
48
|
+
* @returns A new SenderBuiltMicropayment instance.
|
|
49
|
+
*/
|
|
50
|
+
static deserialize(bytes: Uint8Array | string): SenderBuiltMicropayment;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* The information associtated with a micropayment channel.
|
|
54
|
+
*/
|
|
55
|
+
interface ChannelInfo {
|
|
56
|
+
/**
|
|
57
|
+
* The sender/owner of the channel.
|
|
58
|
+
*/
|
|
59
|
+
sender: AccountAddress;
|
|
60
|
+
/**
|
|
61
|
+
* The receiver of the channel.
|
|
62
|
+
*/
|
|
63
|
+
receiver?: AccountAddress;
|
|
64
|
+
/**
|
|
65
|
+
* The address of the fungible asset.
|
|
66
|
+
*/
|
|
67
|
+
fungibleAssetAddress: AccountAddress;
|
|
68
|
+
/**
|
|
69
|
+
* The balance of the channel.
|
|
70
|
+
*/
|
|
71
|
+
balance: number;
|
|
72
|
+
/**
|
|
73
|
+
* The creation timestamp of the channel.
|
|
74
|
+
*/
|
|
75
|
+
creationMicros: number;
|
|
76
|
+
/**
|
|
77
|
+
* The current expiration timestamp of the channel.
|
|
78
|
+
*/
|
|
79
|
+
expirationMicros: number;
|
|
80
|
+
/**
|
|
81
|
+
* The sequence number for the next allowed withdrawal.
|
|
82
|
+
*/
|
|
83
|
+
nextWithdrawnSequenceNumber: number;
|
|
84
|
+
/**
|
|
85
|
+
* The channel's payment id.
|
|
86
|
+
*/
|
|
87
|
+
paymentChannelId: number;
|
|
88
|
+
/**
|
|
89
|
+
* The amount already withdrawn by the receiver.
|
|
90
|
+
*/
|
|
91
|
+
receiverWithdrawnAmount: number;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export { type ChannelInfo, SenderBuiltMicropayment, StaleChannelStateError };
|
|
@@ -11,5 +11,34 @@ interface PlacementGroupInfo {
|
|
|
11
11
|
*/
|
|
12
12
|
members: AccountAddress[];
|
|
13
13
|
}
|
|
14
|
+
/**
|
|
15
|
+
* The status of a placement group slot.
|
|
16
|
+
*/
|
|
17
|
+
type PlacementGroupSlotStatus = "joining" | "active" | "left";
|
|
18
|
+
/**
|
|
19
|
+
* A placement group slot representing an assignment of a storage provider to a placement group.
|
|
20
|
+
*/
|
|
21
|
+
interface PlacementGroupSlot {
|
|
22
|
+
/**
|
|
23
|
+
* The address of the placement group.
|
|
24
|
+
*/
|
|
25
|
+
placementGroup: string;
|
|
26
|
+
/**
|
|
27
|
+
* The index of the slot within the placement group.
|
|
28
|
+
*/
|
|
29
|
+
slotIndex: number;
|
|
30
|
+
/**
|
|
31
|
+
* The address of the storage provider assigned to this slot.
|
|
32
|
+
*/
|
|
33
|
+
storageProvider: string;
|
|
34
|
+
/**
|
|
35
|
+
* The status of this slot (joining, active, or left).
|
|
36
|
+
*/
|
|
37
|
+
status: PlacementGroupSlotStatus;
|
|
38
|
+
/**
|
|
39
|
+
* The timestamp when this slot was last updated (in microseconds).
|
|
40
|
+
*/
|
|
41
|
+
updatedAt: number;
|
|
42
|
+
}
|
|
14
43
|
|
|
15
|
-
export type { PlacementGroupInfo };
|
|
44
|
+
export type { PlacementGroupInfo, PlacementGroupSlot, PlacementGroupSlotStatus };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import "../../chunk-AD2G3QYD.mjs";
|
|
@@ -1,9 +1,35 @@
|
|
|
1
1
|
import { AccountAddress } from '@aptos-labs/ts-sdk';
|
|
2
2
|
|
|
3
|
+
/**
|
|
4
|
+
* State details for active storage providers
|
|
5
|
+
*/
|
|
6
|
+
interface ActiveStateDetails {
|
|
7
|
+
variant: "Active";
|
|
8
|
+
quota: string;
|
|
9
|
+
stakeAtStartOfStakingEpoch: string;
|
|
10
|
+
faulty: boolean;
|
|
11
|
+
leaving: boolean;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* State details for waitlisted storage providers
|
|
15
|
+
*/
|
|
16
|
+
interface WaitlistedStateDetails {
|
|
17
|
+
variant: "Waitlisted";
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* State details for frozen storage providers
|
|
21
|
+
*/
|
|
22
|
+
interface FrozenStateDetails {
|
|
23
|
+
variant: "Frozen";
|
|
24
|
+
frozenReason: string;
|
|
25
|
+
frozenFrom: string;
|
|
26
|
+
frozenTill: string;
|
|
27
|
+
}
|
|
28
|
+
type StorageProviderStateDetails = ActiveStateDetails | WaitlistedStateDetails | FrozenStateDetails;
|
|
3
29
|
/**
|
|
4
30
|
* The metadata of a storage provider.
|
|
5
31
|
*
|
|
6
|
-
* @link https://github.com/shelby/shelby/blob/da805cff8f0f55a0837cf43586eb4eaa04ad3f1f/move/shelby_contract/sources/
|
|
32
|
+
* @link https://github.com/shelby/shelby/blob/da805cff8f0f55a0837cf43586eb4eaa04ad3f1f/move/shelby_contract/sources/storage_provider_registry.move
|
|
7
33
|
*/
|
|
8
34
|
interface StorageProviderInfo {
|
|
9
35
|
/**
|
|
@@ -26,6 +52,10 @@ interface StorageProviderInfo {
|
|
|
26
52
|
* The failure domain of the storage provider.
|
|
27
53
|
*/
|
|
28
54
|
failureDomain: string;
|
|
55
|
+
/**
|
|
56
|
+
* The state details of the storage provider (Active, Waitlisted, or Frozen).
|
|
57
|
+
*/
|
|
58
|
+
state: StorageProviderStateDetails;
|
|
29
59
|
}
|
|
30
60
|
|
|
31
|
-
export type { StorageProviderInfo };
|
|
61
|
+
export type { ActiveStateDetails, FrozenStateDetails, StorageProviderInfo, StorageProviderStateDetails, WaitlistedStateDetails };
|
|
@@ -1,19 +1,22 @@
|
|
|
1
|
+
import '../../core/clients/ShelbyMetadataClient.js';
|
|
1
2
|
import { ShelbyClient } from '../../core/clients/ShelbyClient.js';
|
|
2
|
-
import '../../core/clients/ShelbyBlobClient.js';
|
|
3
3
|
import '@aptos-labs/ts-sdk';
|
|
4
|
+
import '../../core/types/storage_providers.js';
|
|
5
|
+
import '../../core/clients/ShelbyClientConfig.js';
|
|
6
|
+
import '../../core/networks.js';
|
|
7
|
+
import '../../core/blobs.js';
|
|
4
8
|
import '../../core/layout.js';
|
|
5
9
|
import 'zod';
|
|
6
|
-
import '../../
|
|
7
|
-
import '../../clay-codes-pdZFxI_B.js';
|
|
10
|
+
import '../../clay-codes-DHP-bYcP.js';
|
|
8
11
|
import '@shelby-protocol/clay-codes';
|
|
12
|
+
import '../../core/clients/ShelbyBlobClient.js';
|
|
13
|
+
import '../../core/types/blobs.js';
|
|
9
14
|
import '../../core/operations/index.js';
|
|
10
15
|
import 'graphql-request';
|
|
11
|
-
import '../../core/clients/ShelbyClientConfig.js';
|
|
12
|
-
import '../../core/networks.js';
|
|
13
16
|
import '../../core/operations/generated/sdk.js';
|
|
14
17
|
import 'graphql';
|
|
15
|
-
import '../../core/blobs.js';
|
|
16
18
|
import '../../core/clients/ShelbyRPCClient.js';
|
|
19
|
+
import '../../core/types/payments.js';
|
|
17
20
|
|
|
18
21
|
declare class ShelbyNodeClient extends ShelbyClient {
|
|
19
22
|
}
|
|
@@ -1,24 +1,27 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ShelbyNodeClient
|
|
3
|
-
} from "../../chunk-
|
|
4
|
-
import "../../chunk-
|
|
5
|
-
import "../../chunk-
|
|
3
|
+
} from "../../chunk-ZEDD2MPU.mjs";
|
|
4
|
+
import "../../chunk-7PN65RDX.mjs";
|
|
5
|
+
import "../../chunk-SRV4YWFH.mjs";
|
|
6
6
|
import "../../chunk-XNEIWM4O.mjs";
|
|
7
|
-
import "../../chunk-
|
|
8
|
-
import "../../chunk-
|
|
9
|
-
import "../../chunk-
|
|
10
|
-
import "../../chunk-
|
|
11
|
-
import "../../chunk-
|
|
12
|
-
import "../../chunk-
|
|
13
|
-
import "../../chunk-
|
|
7
|
+
import "../../chunk-HPPMI7DC.mjs";
|
|
8
|
+
import "../../chunk-OGKZ575S.mjs";
|
|
9
|
+
import "../../chunk-NHWWORCH.mjs";
|
|
10
|
+
import "../../chunk-MV6FNYAU.mjs";
|
|
11
|
+
import "../../chunk-PJVWGMVI.mjs";
|
|
12
|
+
import "../../chunk-4MG4XGY4.mjs";
|
|
13
|
+
import "../../chunk-CGYJLKBU.mjs";
|
|
14
|
+
import "../../chunk-KJ24NKPH.mjs";
|
|
15
|
+
import "../../chunk-AABBONAF.mjs";
|
|
14
16
|
import "../../chunk-I6NG5GNL.mjs";
|
|
15
|
-
import "../../chunk-
|
|
17
|
+
import "../../chunk-IE6LYVIA.mjs";
|
|
16
18
|
import "../../chunk-OTBLZL2S.mjs";
|
|
17
|
-
import "../../chunk-
|
|
19
|
+
import "../../chunk-2WEX3K7C.mjs";
|
|
18
20
|
import "../../chunk-4JZO2D7T.mjs";
|
|
19
|
-
import "../../chunk-
|
|
20
|
-
import "../../chunk-
|
|
21
|
-
import "../../chunk-
|
|
21
|
+
import "../../chunk-JTXYKO3U.mjs";
|
|
22
|
+
import "../../chunk-AUQDI5BS.mjs";
|
|
23
|
+
import "../../chunk-4ZOFT75Q.mjs";
|
|
24
|
+
import "../../chunk-Z4FZ7W6L.mjs";
|
|
22
25
|
import "../../chunk-7P6ASYW6.mjs";
|
|
23
26
|
export {
|
|
24
27
|
ShelbyNodeClient
|
|
@@ -1,19 +1,20 @@
|
|
|
1
|
-
export { ShelbyMetadataClient } from '
|
|
1
|
+
export { ShelbyMetadataClient } from '../../core/clients/ShelbyMetadataClient.js';
|
|
2
2
|
export { ShelbyNodeClient } from './ShelbyNodeClient.js';
|
|
3
3
|
import '@aptos-labs/ts-sdk';
|
|
4
|
+
import '../../core/types/storage_providers.js';
|
|
4
5
|
import '../../core/clients/ShelbyClientConfig.js';
|
|
5
6
|
import '../../core/networks.js';
|
|
6
|
-
import '../../core/types/storage_providers.js';
|
|
7
7
|
import '../../core/clients/ShelbyClient.js';
|
|
8
|
-
import '../../core/
|
|
8
|
+
import '../../core/blobs.js';
|
|
9
9
|
import '../../core/layout.js';
|
|
10
10
|
import 'zod';
|
|
11
|
-
import '../../
|
|
12
|
-
import '../../clay-codes-pdZFxI_B.js';
|
|
11
|
+
import '../../clay-codes-DHP-bYcP.js';
|
|
13
12
|
import '@shelby-protocol/clay-codes';
|
|
13
|
+
import '../../core/clients/ShelbyBlobClient.js';
|
|
14
|
+
import '../../core/types/blobs.js';
|
|
14
15
|
import '../../core/operations/index.js';
|
|
15
16
|
import 'graphql-request';
|
|
16
17
|
import '../../core/operations/generated/sdk.js';
|
|
17
18
|
import 'graphql';
|
|
18
|
-
import '../../core/blobs.js';
|
|
19
19
|
import '../../core/clients/ShelbyRPCClient.js';
|
|
20
|
+
import '../../core/types/payments.js';
|
|
@@ -1,28 +1,30 @@
|
|
|
1
1
|
import "../../chunk-MB7C7VQF.mjs";
|
|
2
2
|
import {
|
|
3
3
|
ShelbyNodeClient
|
|
4
|
-
} from "../../chunk-
|
|
4
|
+
} from "../../chunk-ZEDD2MPU.mjs";
|
|
5
|
+
import "../../chunk-7PN65RDX.mjs";
|
|
6
|
+
import "../../chunk-SRV4YWFH.mjs";
|
|
7
|
+
import "../../chunk-XNEIWM4O.mjs";
|
|
8
|
+
import "../../chunk-HPPMI7DC.mjs";
|
|
9
|
+
import "../../chunk-OGKZ575S.mjs";
|
|
10
|
+
import "../../chunk-NHWWORCH.mjs";
|
|
5
11
|
import {
|
|
6
12
|
ShelbyMetadataClient
|
|
7
|
-
} from "../../chunk-
|
|
8
|
-
import "../../chunk-
|
|
9
|
-
import "../../chunk-
|
|
10
|
-
import "../../chunk-
|
|
11
|
-
import "../../chunk-
|
|
12
|
-
import "../../chunk-
|
|
13
|
-
import "../../chunk-PZF2VTGP.mjs";
|
|
14
|
-
import "../../chunk-5I3MBJGN.mjs";
|
|
15
|
-
import "../../chunk-HFGEQP5N.mjs";
|
|
16
|
-
import "../../chunk-WJKSPJSS.mjs";
|
|
17
|
-
import "../../chunk-GY5DCVVL.mjs";
|
|
13
|
+
} from "../../chunk-MV6FNYAU.mjs";
|
|
14
|
+
import "../../chunk-PJVWGMVI.mjs";
|
|
15
|
+
import "../../chunk-4MG4XGY4.mjs";
|
|
16
|
+
import "../../chunk-CGYJLKBU.mjs";
|
|
17
|
+
import "../../chunk-KJ24NKPH.mjs";
|
|
18
|
+
import "../../chunk-AABBONAF.mjs";
|
|
18
19
|
import "../../chunk-I6NG5GNL.mjs";
|
|
19
|
-
import "../../chunk-
|
|
20
|
+
import "../../chunk-IE6LYVIA.mjs";
|
|
20
21
|
import "../../chunk-OTBLZL2S.mjs";
|
|
21
|
-
import "../../chunk-
|
|
22
|
+
import "../../chunk-2WEX3K7C.mjs";
|
|
22
23
|
import "../../chunk-4JZO2D7T.mjs";
|
|
23
|
-
import "../../chunk-
|
|
24
|
-
import "../../chunk-
|
|
25
|
-
import "../../chunk-
|
|
24
|
+
import "../../chunk-JTXYKO3U.mjs";
|
|
25
|
+
import "../../chunk-AUQDI5BS.mjs";
|
|
26
|
+
import "../../chunk-4ZOFT75Q.mjs";
|
|
27
|
+
import "../../chunk-Z4FZ7W6L.mjs";
|
|
26
28
|
import "../../chunk-7P6ASYW6.mjs";
|
|
27
29
|
export {
|
|
28
30
|
ShelbyMetadataClient,
|
package/dist/node/index.d.ts
CHANGED
|
@@ -1,26 +1,32 @@
|
|
|
1
1
|
export { getAptosAccountExplorerUrl, getAptosTransactionExplorerUrl } from '../core/aptos-explorer.js';
|
|
2
2
|
export { ShelbyBlob, createBlobKey } from '../core/blobs.js';
|
|
3
3
|
export { CHUNK_SIZE_PARAMS, ChunkSizeScheme, DEFAULT_CHUNKSET_SIZE_BYTES, DEFAULT_CHUNK_SIZE_BYTES, ERASURE_CODE_AND_CHUNK_MAPPING } from '../core/chunk.js';
|
|
4
|
-
export { ShelbyBlobClient } from '../core/clients/ShelbyBlobClient.js';
|
|
4
|
+
export { AckTransactionOptions, BuildOptions, MissingTransactionSubmitterError, ShelbyBlobClient, UsdSponsorOptions, WriteBlobCommitmentsOptions } from '../core/clients/ShelbyBlobClient.js';
|
|
5
5
|
export { ShelbyClient, UploadOptions } from '../core/clients/ShelbyClient.js';
|
|
6
6
|
export { ShelbyClientConfig, ShelbyIndexerConfig, ShelbyRPCConfig } from '../core/clients/ShelbyClientConfig.js';
|
|
7
|
-
export {
|
|
8
|
-
export {
|
|
9
|
-
export {
|
|
10
|
-
export {
|
|
11
|
-
export {
|
|
12
|
-
export {
|
|
13
|
-
export {
|
|
7
|
+
export { ShelbyMetadataClient } from '../core/clients/ShelbyMetadataClient.js';
|
|
8
|
+
export { ShelbyMicropaymentChannelClient } from '../core/clients/ShelbyMicropaymentChannelClient.js';
|
|
9
|
+
export { ShelbyPlacementGroupClient } from '../core/clients/ShelbyPlacementGroupClient.js';
|
|
10
|
+
export { BlobDataSource, PutBlobProgress, ShelbyRPCClient } from '../core/clients/ShelbyRPCClient.js';
|
|
11
|
+
export { BlobCommitments, BlobCommitmentsSchema, COMMITMENT_SCHEMA_VERSION, ChunksetCommitment, ChunksetCommitmentSchema, GenerateCommitmentsOptions, expectedTotalChunksets, generateCommitments, generateMerkleRoot } from '../core/commitments.js';
|
|
12
|
+
export { DEFAULT_PROJECT_DESCRIPTION, DEFAULT_PROJECT_NAME, MICROPAYMENTS_DEPLOYER, NetworkToGasStationBaseUrl, NetworkToShelbyBlobIndexerBaseUrl, NetworkToShelbyRPCBaseUrl, SHELBYUSD_FA_METADATA_ADDRESS, SHELBYUSD_TOKEN_ADDRESS, SHELBYUSD_TOKEN_MODULE, SHELBYUSD_TOKEN_NAME, SHELBY_DEPLOYER, TOKEN_DEPLOYER, TOKEN_OBJECT_ADDRESS } from '../core/constants.js';
|
|
13
|
+
export { C as ClayErasureCodingProvider, D as DecodeConfig, E as ErasureCodingConfig, a as ErasureCodingProvider, R as ReedSolomonErasureCodingProvider } from '../clay-codes-DHP-bYcP.js';
|
|
14
|
+
export { DEFAULT_ERASURE_D, DEFAULT_ERASURE_K, DEFAULT_ERASURE_M, DEFAULT_ERASURE_N, DEFAULT_SAMPLE_SIZE, ERASURE_CODE_PARAMS, ErasureCodeParams, ErasureCodingScheme, ErasureSchemeParams } from '../core/erasure/constants.js';
|
|
15
|
+
export { createDefaultErasureCodingProvider, defaultErasureCodingConfig, erasureCodingConfig16Total10Data13Helper, erasureCodingConfig4Total2Data3Helper } from '../core/erasure/default.js';
|
|
16
|
+
export { ShelbyErrorCodes, isAccessDeniedError, isBlobAlreadyExistsError, isBlobExpiredError, isBlobNotFoundError } from '../core/errors.js';
|
|
17
|
+
export { BlobName, BlobNameSchema, ChunkKey } from '../core/layout.js';
|
|
14
18
|
export { ShelbyNetwork, isShelbyNetwork, shelbyNetworks } from '../core/networks.js';
|
|
15
19
|
export { ShelbyIndexerClient, createShelbyIndexerClient, getShelbyIndexerClient } from '../core/operations/index.js';
|
|
20
|
+
export { CompleteMultipartUploadResponse, CompleteMultipartUploadResponseSchema, RPCErrorResponse, RPCErrorResponseSchema, StaleMicropaymentErrorResponse, StaleMicropaymentErrorResponseSchema, StartMultipartUploadResponse, StartMultipartUploadResponseSchema, UploadPartResponse, UploadPartResponseSchema } from '../core/rpc-responses.js';
|
|
16
21
|
export { getShelbyAccountBlobsExplorerUrl, getShelbyAccountExplorerUrl, getShelbyBlobExplorerUrl } from '../core/shelby-explorer.js';
|
|
17
22
|
export { BlobActivity, BlobActivityType, BlobEncoding, BlobMetadata, ClayEncoding, StorageProviderAck } from '../core/types/blobs.js';
|
|
18
|
-
export {
|
|
23
|
+
export { ChannelInfo, SenderBuiltMicropayment, StaleChannelStateError } from '../core/types/payments.js';
|
|
24
|
+
export { PlacementGroupInfo, PlacementGroupSlot, PlacementGroupSlotStatus } from '../core/types/placement_groups.js';
|
|
25
|
+
export { ActiveStateDetails, FrozenStateDetails, StorageProviderInfo, StorageProviderStateDetails, WaitlistedStateDetails } from '../core/types/storage_providers.js';
|
|
19
26
|
export { buildRequestUrl, concatHashes, getBlobNameSuffix, readInChunks, zeroPadBytes } from '../core/utils.js';
|
|
20
|
-
export { ShelbyMetadataClient } from './clients/ShelbyMetadataClient.js';
|
|
21
27
|
export { ShelbyNodeClient } from './clients/ShelbyNodeClient.js';
|
|
22
28
|
export { t as testUtil } from '../testUtil-BnxAchIN.js';
|
|
23
|
-
export { Bigint_Comparison_Exp, Blob_Activities, Blob_Activities_Aggregate, Blob_Activities_Aggregate_Fields, Blob_Activities_Aggregate_FieldsCountArgs, Blob_Activities_Avg_Fields, Blob_Activities_Bool_Exp, Blob_Activities_Max_Fields, Blob_Activities_Min_Fields, Blob_Activities_Order_By, Blob_Activities_Select_Column, Blob_Activities_Stddev_Fields, Blob_Activities_Stddev_Pop_Fields, Blob_Activities_Stddev_Samp_Fields, Blob_Activities_Stream_Cursor_Input, Blob_Activities_Stream_Cursor_Value_Input, Blob_Activities_Sum_Fields, Blob_Activities_Var_Pop_Fields, Blob_Activities_Var_Samp_Fields, Blob_Activities_Variance_Fields, Blobs, BlobsPlacement_Group_SlotsArgs, Blobs_Aggregate, Blobs_Aggregate_Fields, Blobs_Aggregate_FieldsCountArgs, Blobs_Avg_Fields, Blobs_Bool_Exp, Blobs_Max_Fields, Blobs_Min_Fields, Blobs_Order_By, Blobs_Select_Column, Blobs_Stddev_Fields, Blobs_Stddev_Pop_Fields, Blobs_Stddev_Samp_Fields, Blobs_Stream_Cursor_Input, Blobs_Stream_Cursor_Value_Input, Blobs_Sum_Fields, Blobs_Var_Pop_Fields, Blobs_Var_Samp_Fields, Blobs_Variance_Fields, Cursor_Ordering, Exact, GetBlobActivitiesCountDocument, GetBlobActivitiesCountQuery, GetBlobActivitiesCountQueryVariables, GetBlobActivitiesDocument, GetBlobActivitiesQuery, GetBlobActivitiesQueryVariables, GetBlobsCountDocument, GetBlobsCountQuery, GetBlobsCountQueryVariables, GetBlobsDocument, GetBlobsQuery, GetBlobsQueryVariables, Incremental, InputMaybe, MakeEmpty, MakeMaybe, MakeOptional, Maybe, Numeric_Comparison_Exp, Order_By, Placement_Group_Slots, Placement_Group_Slots_Aggregate_Order_By, Placement_Group_Slots_Avg_Order_By, Placement_Group_Slots_Bool_Exp, Placement_Group_Slots_Max_Order_By, Placement_Group_Slots_Min_Order_By, Placement_Group_Slots_Order_By, Placement_Group_Slots_Select_Column, Placement_Group_Slots_Stddev_Order_By, Placement_Group_Slots_Stddev_Pop_Order_By, Placement_Group_Slots_Stddev_Samp_Order_By, Placement_Group_Slots_Stream_Cursor_Input, Placement_Group_Slots_Stream_Cursor_Value_Input, Placement_Group_Slots_Sum_Order_By, Placement_Group_Slots_Var_Pop_Order_By, Placement_Group_Slots_Var_Samp_Order_By, Placement_Group_Slots_Variance_Order_By, Processor_Status, Processor_Status_Bool_Exp, Processor_Status_Order_By, Processor_Status_Select_Column, Processor_Status_Stream_Cursor_Input, Processor_Status_Stream_Cursor_Value_Input, Query_Root, Query_RootBlob_ActivitiesArgs, Query_RootBlob_Activities_AggregateArgs, Query_RootBlob_Activities_By_PkArgs, Query_RootBlobsArgs, Query_RootBlobs_AggregateArgs, Query_RootBlobs_By_PkArgs, Query_RootPlacement_Group_SlotsArgs, Query_RootPlacement_Group_Slots_By_PkArgs, Query_RootProcessor_StatusArgs, Scalars, Sdk, SdkFunctionWrapper, String_Comparison_Exp, Subscription_Root, Subscription_RootBlob_ActivitiesArgs, Subscription_RootBlob_Activities_AggregateArgs, Subscription_RootBlob_Activities_By_PkArgs, Subscription_RootBlob_Activities_StreamArgs, Subscription_RootBlobsArgs, Subscription_RootBlobs_AggregateArgs, Subscription_RootBlobs_By_PkArgs, Subscription_RootBlobs_StreamArgs, Subscription_RootPlacement_Group_SlotsArgs, Subscription_RootPlacement_Group_Slots_By_PkArgs, Subscription_RootPlacement_Group_Slots_StreamArgs, Subscription_RootProcessor_StatusArgs, Subscription_RootProcessor_Status_StreamArgs, Timestamp_Comparison_Exp, getSdk } from '../core/operations/generated/sdk.js';
|
|
29
|
+
export { Bigint_Comparison_Exp, Blob_Activities, Blob_Activities_Aggregate, Blob_Activities_Aggregate_Fields, Blob_Activities_Aggregate_FieldsCountArgs, Blob_Activities_Avg_Fields, Blob_Activities_Bool_Exp, Blob_Activities_Max_Fields, Blob_Activities_Min_Fields, Blob_Activities_Order_By, Blob_Activities_Select_Column, Blob_Activities_Stddev_Fields, Blob_Activities_Stddev_Pop_Fields, Blob_Activities_Stddev_Samp_Fields, Blob_Activities_Stream_Cursor_Input, Blob_Activities_Stream_Cursor_Value_Input, Blob_Activities_Sum_Fields, Blob_Activities_Var_Pop_Fields, Blob_Activities_Var_Samp_Fields, Blob_Activities_Variance_Fields, Blobs, BlobsPlacement_Group_SlotsArgs, BlobsPlacement_Group_Slots_AggregateArgs, Blobs_Aggregate, Blobs_Aggregate_Fields, Blobs_Aggregate_FieldsCountArgs, Blobs_Avg_Fields, Blobs_Bool_Exp, Blobs_Max_Fields, Blobs_Min_Fields, Blobs_Order_By, Blobs_Select_Column, Blobs_Stddev_Fields, Blobs_Stddev_Pop_Fields, Blobs_Stddev_Samp_Fields, Blobs_Stream_Cursor_Input, Blobs_Stream_Cursor_Value_Input, Blobs_Sum_Fields, Blobs_Var_Pop_Fields, Blobs_Var_Samp_Fields, Blobs_Variance_Fields, Cursor_Ordering, Exact, GetBlobActivitiesCountDocument, GetBlobActivitiesCountQuery, GetBlobActivitiesCountQueryVariables, GetBlobActivitiesDocument, GetBlobActivitiesQuery, GetBlobActivitiesQueryVariables, GetBlobsCountDocument, GetBlobsCountQuery, GetBlobsCountQueryVariables, GetBlobsDocument, GetBlobsQuery, GetBlobsQueryVariables, GetPlacementGroupSlotsCountDocument, GetPlacementGroupSlotsCountQuery, GetPlacementGroupSlotsCountQueryVariables, GetPlacementGroupSlotsDocument, GetPlacementGroupSlotsQuery, GetPlacementGroupSlotsQueryVariables, GetProcessorStatusDocument, GetProcessorStatusQuery, GetProcessorStatusQueryVariables, Incremental, InputMaybe, Int_Comparison_Exp, MakeEmpty, MakeMaybe, MakeOptional, Maybe, Numeric_Comparison_Exp, Order_By, Placement_Group_Slots, Placement_Group_Slots_Aggregate, Placement_Group_Slots_Aggregate_Bool_Exp, Placement_Group_Slots_Aggregate_Bool_Exp_Count, Placement_Group_Slots_Aggregate_Fields, Placement_Group_Slots_Aggregate_FieldsCountArgs, Placement_Group_Slots_Aggregate_Order_By, Placement_Group_Slots_Avg_Fields, Placement_Group_Slots_Avg_Order_By, Placement_Group_Slots_Bool_Exp, Placement_Group_Slots_Max_Fields, Placement_Group_Slots_Max_Order_By, Placement_Group_Slots_Min_Fields, Placement_Group_Slots_Min_Order_By, Placement_Group_Slots_Order_By, Placement_Group_Slots_Select_Column, Placement_Group_Slots_Stddev_Fields, Placement_Group_Slots_Stddev_Order_By, Placement_Group_Slots_Stddev_Pop_Fields, Placement_Group_Slots_Stddev_Pop_Order_By, Placement_Group_Slots_Stddev_Samp_Fields, Placement_Group_Slots_Stddev_Samp_Order_By, Placement_Group_Slots_Stream_Cursor_Input, Placement_Group_Slots_Stream_Cursor_Value_Input, Placement_Group_Slots_Sum_Fields, Placement_Group_Slots_Sum_Order_By, Placement_Group_Slots_Var_Pop_Fields, Placement_Group_Slots_Var_Pop_Order_By, Placement_Group_Slots_Var_Samp_Fields, Placement_Group_Slots_Var_Samp_Order_By, Placement_Group_Slots_Variance_Fields, Placement_Group_Slots_Variance_Order_By, Processor_Status, Processor_Status_Bool_Exp, Processor_Status_Order_By, Processor_Status_Select_Column, Processor_Status_Stream_Cursor_Input, Processor_Status_Stream_Cursor_Value_Input, Query_Root, Query_RootBlob_ActivitiesArgs, Query_RootBlob_Activities_AggregateArgs, Query_RootBlob_Activities_By_PkArgs, Query_RootBlobsArgs, Query_RootBlobs_AggregateArgs, Query_RootBlobs_By_PkArgs, Query_RootPlacement_Group_SlotsArgs, Query_RootPlacement_Group_Slots_AggregateArgs, Query_RootPlacement_Group_Slots_By_PkArgs, Query_RootProcessor_StatusArgs, Scalars, Sdk, SdkFunctionWrapper, String_Comparison_Exp, Subscription_Root, Subscription_RootBlob_ActivitiesArgs, Subscription_RootBlob_Activities_AggregateArgs, Subscription_RootBlob_Activities_By_PkArgs, Subscription_RootBlob_Activities_StreamArgs, Subscription_RootBlobsArgs, Subscription_RootBlobs_AggregateArgs, Subscription_RootBlobs_By_PkArgs, Subscription_RootBlobs_StreamArgs, Subscription_RootPlacement_Group_SlotsArgs, Subscription_RootPlacement_Group_Slots_AggregateArgs, Subscription_RootPlacement_Group_Slots_By_PkArgs, Subscription_RootPlacement_Group_Slots_StreamArgs, Subscription_RootProcessor_StatusArgs, Subscription_RootProcessor_Status_StreamArgs, Timestamp_Comparison_Exp, getSdk } from '../core/operations/generated/sdk.js';
|
|
24
30
|
import '@aptos-labs/ts-sdk';
|
|
25
31
|
import 'zod';
|
|
26
32
|
import '@shelby-protocol/clay-codes';
|