@hypercerts-org/marketplace-sdk 0.5.1 → 0.5.2
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/index.cjs.js +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/utils/api.d.ts +98 -92
- package/dist/utils/graphl.d.ts +50 -47
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
package/dist/index.esm.js
CHANGED
package/dist/utils/api.d.ts
CHANGED
@@ -43,56 +43,59 @@ export declare class ApiClient {
|
|
43
43
|
* @param strategy strategy for the order
|
44
44
|
*/
|
45
45
|
fetchOrders: ({ signer, chainId }: Partial<FetchOrderArgs>) => Promise<{
|
46
|
-
|
47
|
-
|
48
|
-
hypercert_id: string | null;
|
49
|
-
creator_address: string | null;
|
50
|
-
contracts_id: string | null;
|
51
|
-
creation_block_number: unknown;
|
52
|
-
creation_block_timestamp: unknown;
|
46
|
+
count: number | null;
|
47
|
+
data: {
|
53
48
|
id: string;
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
external_url: string | null;
|
49
|
+
hypercert: {
|
50
|
+
hypercert_id: string | null;
|
51
|
+
creator_address: string | null;
|
52
|
+
contracts_id: string | null;
|
53
|
+
creation_block_number: unknown;
|
54
|
+
creation_block_timestamp: unknown;
|
61
55
|
id: string;
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
56
|
+
last_update_block_number: unknown;
|
57
|
+
last_update_block_timestamp: unknown;
|
58
|
+
metadata: {
|
59
|
+
allow_list_uri: string | null;
|
60
|
+
contributors: string[] | null;
|
61
|
+
description: string | null;
|
62
|
+
external_url: string | null;
|
63
|
+
id: string;
|
64
|
+
impact_scope: string[] | null;
|
65
|
+
impact_timeframe_from: unknown;
|
66
|
+
impact_timeframe_to: unknown;
|
67
|
+
name: string | null;
|
68
|
+
properties: unknown;
|
69
|
+
rights: string[] | null;
|
70
|
+
uri: string | null;
|
71
|
+
work_scope: string[] | null;
|
72
|
+
work_timeframe_from: unknown;
|
73
|
+
work_timeframe_to: unknown;
|
74
|
+
} | null;
|
75
|
+
token_id: unknown;
|
76
|
+
units: unknown;
|
68
77
|
uri: string | null;
|
69
|
-
work_scope: string[] | null;
|
70
|
-
work_timeframe_from: unknown;
|
71
|
-
work_timeframe_to: unknown;
|
72
78
|
} | null;
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
strategyId: number;
|
94
|
-
subsetNonce: number;
|
95
|
-
}[] | null | undefined>;
|
79
|
+
additionalParameters: string;
|
80
|
+
amounts: number[];
|
81
|
+
chainId: unknown;
|
82
|
+
collection: string;
|
83
|
+
collectionType: number;
|
84
|
+
createdAt: string;
|
85
|
+
currency: string;
|
86
|
+
endTime: number;
|
87
|
+
globalNonce: string;
|
88
|
+
itemIds: string[];
|
89
|
+
orderNonce: string;
|
90
|
+
price: string;
|
91
|
+
quoteType: number;
|
92
|
+
signature: string;
|
93
|
+
signer: string;
|
94
|
+
startTime: number;
|
95
|
+
strategyId: number;
|
96
|
+
subsetNonce: number;
|
97
|
+
}[] | null;
|
98
|
+
} | undefined>;
|
96
99
|
/**
|
97
100
|
* @deprecated use the GraphQL API instead
|
98
101
|
* Fetches orders from API by hypercert ID
|
@@ -102,56 +105,59 @@ export declare class ApiClient {
|
|
102
105
|
fetchOrdersByHypercertId: ({ hypercertId }: {
|
103
106
|
hypercertId: string;
|
104
107
|
}) => Promise<{
|
105
|
-
|
106
|
-
|
107
|
-
hypercert_id: string | null;
|
108
|
-
creator_address: string | null;
|
109
|
-
contracts_id: string | null;
|
110
|
-
creation_block_number: unknown;
|
111
|
-
creation_block_timestamp: unknown;
|
108
|
+
count: number | null;
|
109
|
+
data: {
|
112
110
|
id: string;
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
external_url: string | null;
|
111
|
+
hypercert: {
|
112
|
+
hypercert_id: string | null;
|
113
|
+
creator_address: string | null;
|
114
|
+
contracts_id: string | null;
|
115
|
+
creation_block_number: unknown;
|
116
|
+
creation_block_timestamp: unknown;
|
120
117
|
id: string;
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
118
|
+
last_update_block_number: unknown;
|
119
|
+
last_update_block_timestamp: unknown;
|
120
|
+
metadata: {
|
121
|
+
allow_list_uri: string | null;
|
122
|
+
contributors: string[] | null;
|
123
|
+
description: string | null;
|
124
|
+
external_url: string | null;
|
125
|
+
id: string;
|
126
|
+
impact_scope: string[] | null;
|
127
|
+
impact_timeframe_from: unknown;
|
128
|
+
impact_timeframe_to: unknown;
|
129
|
+
name: string | null;
|
130
|
+
properties: unknown;
|
131
|
+
rights: string[] | null;
|
132
|
+
uri: string | null;
|
133
|
+
work_scope: string[] | null;
|
134
|
+
work_timeframe_from: unknown;
|
135
|
+
work_timeframe_to: unknown;
|
136
|
+
} | null;
|
137
|
+
token_id: unknown;
|
138
|
+
units: unknown;
|
127
139
|
uri: string | null;
|
128
|
-
work_scope: string[] | null;
|
129
|
-
work_timeframe_from: unknown;
|
130
|
-
work_timeframe_to: unknown;
|
131
140
|
} | null;
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
strategyId: number;
|
153
|
-
subsetNonce: number;
|
154
|
-
}[] | null | undefined>;
|
141
|
+
additionalParameters: string;
|
142
|
+
amounts: number[];
|
143
|
+
chainId: unknown;
|
144
|
+
collection: string;
|
145
|
+
collectionType: number;
|
146
|
+
createdAt: string;
|
147
|
+
currency: string;
|
148
|
+
endTime: number;
|
149
|
+
globalNonce: string;
|
150
|
+
itemIds: string[];
|
151
|
+
orderNonce: string;
|
152
|
+
price: string;
|
153
|
+
quoteType: number;
|
154
|
+
signature: string;
|
155
|
+
signer: string;
|
156
|
+
startTime: number;
|
157
|
+
strategyId: number;
|
158
|
+
subsetNonce: number;
|
159
|
+
}[] | null;
|
160
|
+
} | undefined>;
|
155
161
|
handleResponse: <T>(res: Response) => Promise<T>;
|
156
162
|
updateOrderValidity: (tokenIds: bigint[], chainId: number) => Promise<{
|
157
163
|
id: string;
|
package/dist/utils/graphl.d.ts
CHANGED
@@ -7,57 +7,60 @@ export declare const getFractionsById: (fractionId: string, client: Client) => P
|
|
7
7
|
units: unknown;
|
8
8
|
}[] | null | undefined>;
|
9
9
|
export declare const getOrders: (filter: {
|
10
|
-
chainId?:
|
10
|
+
chainId?: bigint;
|
11
11
|
signer?: `0x${string}`;
|
12
12
|
hypercertId?: string;
|
13
13
|
}, client: Client) => Promise<{
|
14
|
-
|
15
|
-
|
16
|
-
hypercert_id: string | null;
|
17
|
-
creator_address: string | null;
|
18
|
-
contracts_id: string | null;
|
19
|
-
creation_block_number: unknown;
|
20
|
-
creation_block_timestamp: unknown;
|
14
|
+
count: number | null;
|
15
|
+
data: {
|
21
16
|
id: string;
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
external_url: string | null;
|
17
|
+
hypercert: {
|
18
|
+
hypercert_id: string | null;
|
19
|
+
creator_address: string | null;
|
20
|
+
contracts_id: string | null;
|
21
|
+
creation_block_number: unknown;
|
22
|
+
creation_block_timestamp: unknown;
|
29
23
|
id: string;
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
24
|
+
last_update_block_number: unknown;
|
25
|
+
last_update_block_timestamp: unknown;
|
26
|
+
metadata: {
|
27
|
+
allow_list_uri: string | null;
|
28
|
+
contributors: string[] | null;
|
29
|
+
description: string | null;
|
30
|
+
external_url: string | null;
|
31
|
+
id: string;
|
32
|
+
impact_scope: string[] | null;
|
33
|
+
impact_timeframe_from: unknown;
|
34
|
+
impact_timeframe_to: unknown;
|
35
|
+
name: string | null;
|
36
|
+
properties: unknown;
|
37
|
+
rights: string[] | null;
|
38
|
+
uri: string | null;
|
39
|
+
work_scope: string[] | null;
|
40
|
+
work_timeframe_from: unknown;
|
41
|
+
work_timeframe_to: unknown;
|
42
|
+
} | null;
|
43
|
+
token_id: unknown;
|
44
|
+
units: unknown;
|
36
45
|
uri: string | null;
|
37
|
-
work_scope: string[] | null;
|
38
|
-
work_timeframe_from: unknown;
|
39
|
-
work_timeframe_to: unknown;
|
40
46
|
} | null;
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
strategyId: number;
|
62
|
-
subsetNonce: number;
|
63
|
-
}[] | null | undefined>;
|
47
|
+
additionalParameters: string;
|
48
|
+
amounts: number[];
|
49
|
+
chainId: unknown;
|
50
|
+
collection: string;
|
51
|
+
collectionType: number;
|
52
|
+
createdAt: string;
|
53
|
+
currency: string;
|
54
|
+
endTime: number;
|
55
|
+
globalNonce: string;
|
56
|
+
itemIds: string[];
|
57
|
+
orderNonce: string;
|
58
|
+
price: string;
|
59
|
+
quoteType: number;
|
60
|
+
signature: string;
|
61
|
+
signer: string;
|
62
|
+
startTime: number;
|
63
|
+
strategyId: number;
|
64
|
+
subsetNonce: number;
|
65
|
+
}[] | null;
|
66
|
+
} | undefined>;
|