@iota/graphql-transport 0.0.0-dev-20251015065834
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/CHANGELOG.md +248 -0
- package/LICENSE +201 -0
- package/README.md +104 -0
- package/dist/cjs/generated/queries.d.ts +9099 -0
- package/dist/cjs/generated/queries.js +3021 -0
- package/dist/cjs/generated/queries.js.map +7 -0
- package/dist/cjs/index.d.ts +1 -0
- package/dist/cjs/index.js +19 -0
- package/dist/cjs/index.js.map +7 -0
- package/dist/cjs/mappers/bcs.d.ts +4 -0
- package/dist/cjs/mappers/bcs.js +71 -0
- package/dist/cjs/mappers/bcs.js.map +7 -0
- package/dist/cjs/mappers/checkpoint.d.ts +3 -0
- package/dist/cjs/mappers/checkpoint.js +64 -0
- package/dist/cjs/mappers/checkpoint.js.map +7 -0
- package/dist/cjs/mappers/display.d.ts +8 -0
- package/dist/cjs/mappers/display.js +43 -0
- package/dist/cjs/mappers/display.js.map +7 -0
- package/dist/cjs/mappers/move.d.ts +57 -0
- package/dist/cjs/mappers/move.js +231 -0
- package/dist/cjs/mappers/move.js.map +7 -0
- package/dist/cjs/mappers/object.d.ts +10 -0
- package/dist/cjs/mappers/object.js +79 -0
- package/dist/cjs/mappers/object.js.map +7 -0
- package/dist/cjs/mappers/owner.d.ts +3 -0
- package/dist/cjs/mappers/owner.js +48 -0
- package/dist/cjs/mappers/owner.js.map +7 -0
- package/dist/cjs/mappers/stakes.d.ts +3 -0
- package/dist/cjs/mappers/stakes.js +48 -0
- package/dist/cjs/mappers/stakes.js.map +7 -0
- package/dist/cjs/mappers/transaction-block.d.ts +7 -0
- package/dist/cjs/mappers/transaction-block.js +487 -0
- package/dist/cjs/mappers/transaction-block.js.map +7 -0
- package/dist/cjs/mappers/util.d.ts +2 -0
- package/dist/cjs/mappers/util.js +31 -0
- package/dist/cjs/mappers/util.js.map +7 -0
- package/dist/cjs/mappers/validator.d.ts +3 -0
- package/dist/cjs/mappers/validator.js +64 -0
- package/dist/cjs/mappers/validator.js.map +7 -0
- package/dist/cjs/methods.d.ts +19 -0
- package/dist/cjs/methods.js +1377 -0
- package/dist/cjs/methods.js.map +7 -0
- package/dist/cjs/package.json +5 -0
- package/dist/cjs/transport.d.ts +44 -0
- package/dist/cjs/transport.js +155 -0
- package/dist/cjs/transport.js.map +7 -0
- package/dist/esm/generated/queries.d.ts +9099 -0
- package/dist/esm/generated/queries.js +3001 -0
- package/dist/esm/generated/queries.js.map +7 -0
- package/dist/esm/index.d.ts +1 -0
- package/dist/esm/index.js +2 -0
- package/dist/esm/index.js.map +7 -0
- package/dist/esm/mappers/bcs.d.ts +4 -0
- package/dist/esm/mappers/bcs.js +51 -0
- package/dist/esm/mappers/bcs.js.map +7 -0
- package/dist/esm/mappers/checkpoint.d.ts +3 -0
- package/dist/esm/mappers/checkpoint.js +44 -0
- package/dist/esm/mappers/checkpoint.js.map +7 -0
- package/dist/esm/mappers/display.d.ts +8 -0
- package/dist/esm/mappers/display.js +23 -0
- package/dist/esm/mappers/display.js.map +7 -0
- package/dist/esm/mappers/move.d.ts +57 -0
- package/dist/esm/mappers/move.js +211 -0
- package/dist/esm/mappers/move.js.map +7 -0
- package/dist/esm/mappers/object.d.ts +10 -0
- package/dist/esm/mappers/object.js +59 -0
- package/dist/esm/mappers/object.js.map +7 -0
- package/dist/esm/mappers/owner.d.ts +3 -0
- package/dist/esm/mappers/owner.js +28 -0
- package/dist/esm/mappers/owner.js.map +7 -0
- package/dist/esm/mappers/stakes.d.ts +3 -0
- package/dist/esm/mappers/stakes.js +28 -0
- package/dist/esm/mappers/stakes.js.map +7 -0
- package/dist/esm/mappers/transaction-block.d.ts +7 -0
- package/dist/esm/mappers/transaction-block.js +467 -0
- package/dist/esm/mappers/transaction-block.js.map +7 -0
- package/dist/esm/mappers/util.d.ts +2 -0
- package/dist/esm/mappers/util.js +11 -0
- package/dist/esm/mappers/util.js.map +7 -0
- package/dist/esm/mappers/validator.d.ts +3 -0
- package/dist/esm/mappers/validator.js +44 -0
- package/dist/esm/mappers/validator.js.map +7 -0
- package/dist/esm/methods.d.ts +19 -0
- package/dist/esm/methods.js +1406 -0
- package/dist/esm/methods.js.map +7 -0
- package/dist/esm/package.json +5 -0
- package/dist/esm/transport.d.ts +44 -0
- package/dist/esm/transport.js +135 -0
- package/dist/esm/transport.js.map +7 -0
- package/dist/tsconfig.esm.tsbuildinfo +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/package.json +67 -0
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,248 @@
|
|
|
1
|
+
# @iota/graphql-transport
|
|
2
|
+
|
|
3
|
+
## 0.0.0-dev-20251015065834
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- a0b225d: Support the new node method `isTransactionIndexedOnNode`
|
|
8
|
+
- 4c68076: Sync with Node changes.
|
|
9
|
+
- 92dd15e: Add a new `waitMode` in `waitForTransaction`
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- c12d044: Internal simplification of the codegen
|
|
14
|
+
- 58997cb: map Option correctly in moveDataToRpcContent
|
|
15
|
+
- Updated dependencies [c12d044]
|
|
16
|
+
- Updated dependencies [a0b225d]
|
|
17
|
+
- Updated dependencies [4c68076]
|
|
18
|
+
- Updated dependencies [92dd15e]
|
|
19
|
+
- @iota/iota-sdk@0.0.0-dev-20251015065834
|
|
20
|
+
|
|
21
|
+
## 0.9.2
|
|
22
|
+
|
|
23
|
+
### Patch Changes
|
|
24
|
+
|
|
25
|
+
- Updated dependencies [3244c29]
|
|
26
|
+
- @iota/iota-sdk@1.6.1
|
|
27
|
+
|
|
28
|
+
## 0.9.1
|
|
29
|
+
|
|
30
|
+
### Patch Changes
|
|
31
|
+
|
|
32
|
+
- Updated dependencies [c5543f0]
|
|
33
|
+
- Updated dependencies [bd17ba9]
|
|
34
|
+
- Updated dependencies [0accdb0]
|
|
35
|
+
- @iota/iota-sdk@1.6.0
|
|
36
|
+
|
|
37
|
+
## 0.9.0
|
|
38
|
+
|
|
39
|
+
### Minor Changes
|
|
40
|
+
|
|
41
|
+
- 61b0944: Added support for WrappedOrDeletedObject in TransactionBlockFilter
|
|
42
|
+
- 464c15a: Sync the APIs with the "Domain" -> "Name" rename of IotaNames
|
|
43
|
+
|
|
44
|
+
### Patch Changes
|
|
45
|
+
|
|
46
|
+
- Updated dependencies [40576ed]
|
|
47
|
+
- Updated dependencies [61b0944]
|
|
48
|
+
- Updated dependencies [966f83c]
|
|
49
|
+
- Updated dependencies [f008db3]
|
|
50
|
+
- Updated dependencies [733df30]
|
|
51
|
+
- Updated dependencies [13ca264]
|
|
52
|
+
- Updated dependencies [5bbafa8]
|
|
53
|
+
- Updated dependencies [28ce666]
|
|
54
|
+
- Updated dependencies [c855f8c]
|
|
55
|
+
- Updated dependencies [f008db3]
|
|
56
|
+
- Updated dependencies [464c15a]
|
|
57
|
+
- @iota/iota-sdk@1.5.0
|
|
58
|
+
- @iota/bcs@1.2.0
|
|
59
|
+
|
|
60
|
+
## 0.8.0
|
|
61
|
+
|
|
62
|
+
### Minor Changes
|
|
63
|
+
|
|
64
|
+
- ecea738: Improved logic around `fallbackMethods` in graphql-transport Introduced
|
|
65
|
+
`unsupportedMethods` in graphql-transport Improved IotaClient compatibility with
|
|
66
|
+
graphql-transport
|
|
67
|
+
|
|
68
|
+
### Patch Changes
|
|
69
|
+
|
|
70
|
+
- ecea738: Added missing GraphQL query option fields.
|
|
71
|
+
- 59342b2: Renamed all instances of 'domain' to 'name' for IOTA-Names.
|
|
72
|
+
- Updated dependencies [f04033d]
|
|
73
|
+
- Updated dependencies [f04033d]
|
|
74
|
+
- Updated dependencies [59342b2]
|
|
75
|
+
- Updated dependencies [f04033d]
|
|
76
|
+
- Updated dependencies [f04033d]
|
|
77
|
+
- Updated dependencies [ecea738]
|
|
78
|
+
- @iota/iota-sdk@1.4.0
|
|
79
|
+
- @iota/bcs@1.1.0
|
|
80
|
+
|
|
81
|
+
## 0.7.0
|
|
82
|
+
|
|
83
|
+
### Minor Changes
|
|
84
|
+
|
|
85
|
+
- c837b79: Removed support for iota-bridge
|
|
86
|
+
|
|
87
|
+
### Patch Changes
|
|
88
|
+
|
|
89
|
+
- Updated dependencies [6051799]
|
|
90
|
+
- Updated dependencies [5db9797]
|
|
91
|
+
- Updated dependencies [c4c6d9a]
|
|
92
|
+
- Updated dependencies [c837b79]
|
|
93
|
+
- @iota/iota-sdk@1.3.0
|
|
94
|
+
|
|
95
|
+
## 0.6.0
|
|
96
|
+
|
|
97
|
+
### Minor Changes
|
|
98
|
+
|
|
99
|
+
- 53d5058: Added iota names rpc methods to IotaClient and also GraphQL queries.
|
|
100
|
+
|
|
101
|
+
### Patch Changes
|
|
102
|
+
|
|
103
|
+
- Updated dependencies [53d5058]
|
|
104
|
+
- @iota/iota-sdk@1.2.0
|
|
105
|
+
|
|
106
|
+
## 0.5.2
|
|
107
|
+
|
|
108
|
+
### Patch Changes
|
|
109
|
+
|
|
110
|
+
- Updated dependencies [acc502a]
|
|
111
|
+
- Updated dependencies [1128809]
|
|
112
|
+
- @iota/iota-sdk@1.1.0
|
|
113
|
+
|
|
114
|
+
## 0.5.1
|
|
115
|
+
|
|
116
|
+
### Patch Changes
|
|
117
|
+
|
|
118
|
+
- Updated dependencies [26cf13b]
|
|
119
|
+
- @iota/iota-sdk@1.0.1
|
|
120
|
+
|
|
121
|
+
## 0.5.0
|
|
122
|
+
|
|
123
|
+
### Minor Changes
|
|
124
|
+
|
|
125
|
+
- 864fd32: Rename `getLatestIotaSystemState` to `getLatestIotaSystemStateV1` and add a new
|
|
126
|
+
backwards-compatible and future-proof `getLatestIotaSystemState` method that dynamically calls
|
|
127
|
+
``getLatestIotaSystemStateV1`or`getLatestIotaSystemStateV2` based on the protocol version of the
|
|
128
|
+
node.
|
|
129
|
+
|
|
130
|
+
### Patch Changes
|
|
131
|
+
|
|
132
|
+
- f5d40a4: Added type mapping for consensus_gc_depth field of ProtocolConfig
|
|
133
|
+
- Updated dependencies [f4d75c7]
|
|
134
|
+
- Updated dependencies [daa968f]
|
|
135
|
+
- Updated dependencies [864fd32]
|
|
136
|
+
- @iota/iota-sdk@1.0.0
|
|
137
|
+
- @iota/bcs@1.0.0
|
|
138
|
+
|
|
139
|
+
## 0.4.0
|
|
140
|
+
|
|
141
|
+
### Minor Changes
|
|
142
|
+
|
|
143
|
+
- bdb736e: Update clients after RPC updates to base64
|
|
144
|
+
|
|
145
|
+
### Patch Changes
|
|
146
|
+
|
|
147
|
+
- 1ad39f9: Update dependencies
|
|
148
|
+
- Updated dependencies [42898f1]
|
|
149
|
+
- Updated dependencies [1ad39f9]
|
|
150
|
+
- Updated dependencies [bdb736e]
|
|
151
|
+
- Updated dependencies [65a0900]
|
|
152
|
+
- @iota/iota-sdk@0.7.0
|
|
153
|
+
|
|
154
|
+
## 0.3.0
|
|
155
|
+
|
|
156
|
+
### Minor Changes
|
|
157
|
+
|
|
158
|
+
- 1a4505b: Update clients to support committee selection protocol changes
|
|
159
|
+
- e629a39: Aligns the Typescript SDK for the "fixed gas price" protocol changes:
|
|
160
|
+
|
|
161
|
+
- Add typing support for IotaChangeEpochV2 (computationCharge, computationChargeBurned).
|
|
162
|
+
- Add Typescript SDK client support for versioned IotaSystemStateSummary.
|
|
163
|
+
|
|
164
|
+
### Patch Changes
|
|
165
|
+
|
|
166
|
+
- Updated dependencies [1a4505b]
|
|
167
|
+
- Updated dependencies [e629a39]
|
|
168
|
+
- Updated dependencies [2717145]
|
|
169
|
+
- Updated dependencies [3fe0747]
|
|
170
|
+
- Updated dependencies [e213517]
|
|
171
|
+
- @iota/iota-sdk@0.6.0
|
|
172
|
+
|
|
173
|
+
## 0.2.4
|
|
174
|
+
|
|
175
|
+
### Patch Changes
|
|
176
|
+
|
|
177
|
+
- Updated dependencies [6e00091]
|
|
178
|
+
- @iota/iota-sdk@0.5.0
|
|
179
|
+
|
|
180
|
+
## 0.2.3
|
|
181
|
+
|
|
182
|
+
### Patch Changes
|
|
183
|
+
|
|
184
|
+
- Updated dependencies [5214d28]
|
|
185
|
+
- @iota/iota-sdk@0.4.1
|
|
186
|
+
|
|
187
|
+
## 0.2.2
|
|
188
|
+
|
|
189
|
+
### Patch Changes
|
|
190
|
+
|
|
191
|
+
- Updated dependencies [9864dcb]
|
|
192
|
+
- @iota/iota-sdk@0.4.0
|
|
193
|
+
|
|
194
|
+
## 0.2.1
|
|
195
|
+
|
|
196
|
+
### Patch Changes
|
|
197
|
+
|
|
198
|
+
- 220fa7a: First public release.
|
|
199
|
+
- Updated dependencies [220fa7a]
|
|
200
|
+
- @iota/bcs@0.2.1
|
|
201
|
+
- @iota/iota-sdk@0.3.1
|
|
202
|
+
|
|
203
|
+
## 0.2.0
|
|
204
|
+
|
|
205
|
+
### Minor Changes
|
|
206
|
+
|
|
207
|
+
- 6eabd18: Changes for compatibility with the node, simplification of exposed APIs and general
|
|
208
|
+
improvements.
|
|
209
|
+
|
|
210
|
+
### Patch Changes
|
|
211
|
+
|
|
212
|
+
- Updated dependencies [6eabd18]
|
|
213
|
+
- @iota/bcs@0.2.0
|
|
214
|
+
- @iota/iota-sdk@0.3.0
|
|
215
|
+
|
|
216
|
+
## 0.1.2
|
|
217
|
+
|
|
218
|
+
### Patch Changes
|
|
219
|
+
|
|
220
|
+
- d423314: Sync API changes:
|
|
221
|
+
|
|
222
|
+
- restore extended api metrics endpoints
|
|
223
|
+
- remove nameservice endpoints
|
|
224
|
+
|
|
225
|
+
- b91a3d5: Update auto-generated files to latest IotaGenesisTransaction event updates
|
|
226
|
+
- Updated dependencies [d423314]
|
|
227
|
+
- Updated dependencies [b91a3d5]
|
|
228
|
+
- Updated dependencies [a3c1937]
|
|
229
|
+
- @iota/iota-sdk@0.2.0
|
|
230
|
+
|
|
231
|
+
## 0.1.1
|
|
232
|
+
|
|
233
|
+
### Patch Changes
|
|
234
|
+
|
|
235
|
+
- Updated dependencies [4a4ba5a]
|
|
236
|
+
- @iota/iota-sdk@0.1.1
|
|
237
|
+
|
|
238
|
+
## 0.1.0
|
|
239
|
+
|
|
240
|
+
### Minor Changes
|
|
241
|
+
|
|
242
|
+
- 249a7d0: First release
|
|
243
|
+
|
|
244
|
+
### Patch Changes
|
|
245
|
+
|
|
246
|
+
- Updated dependencies [249a7d0]
|
|
247
|
+
- @iota/bcs@0.1.0
|
|
248
|
+
- @iota/iota-sdk@0.1.0
|
package/LICENSE
ADDED
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
Apache License
|
|
2
|
+
Version 2.0, January 2004
|
|
3
|
+
http://www.apache.org/licenses/
|
|
4
|
+
|
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
|
+
|
|
7
|
+
1. Definitions.
|
|
8
|
+
|
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
11
|
+
|
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
13
|
+
the copyright owner that is granting the License.
|
|
14
|
+
|
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
16
|
+
other entities that control, are controlled by, or are under common
|
|
17
|
+
control with that entity. For the purposes of this definition,
|
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
19
|
+
direction or management of such entity, whether by contract or
|
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
22
|
+
|
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
24
|
+
exercising permissions granted by this License.
|
|
25
|
+
|
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
27
|
+
including but not limited to software source code, documentation
|
|
28
|
+
source, and configuration files.
|
|
29
|
+
|
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
|
31
|
+
transformation or translation of a Source form, including but
|
|
32
|
+
not limited to compiled object code, generated documentation,
|
|
33
|
+
and conversions to other media types.
|
|
34
|
+
|
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
36
|
+
Object form, made available under the License, as indicated by a
|
|
37
|
+
copyright notice that is included in or attached to the work
|
|
38
|
+
(an example is provided in the Appendix below).
|
|
39
|
+
|
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
46
|
+
the Work and Derivative Works thereof.
|
|
47
|
+
|
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
|
49
|
+
the original version of the Work and any modifications or additions
|
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
61
|
+
|
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
64
|
+
subsequently incorporated within the Work.
|
|
65
|
+
|
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
|
72
|
+
|
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
78
|
+
where such license applies only to those patent claims licensable
|
|
79
|
+
by such Contributor that are necessarily infringed by their
|
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
82
|
+
institute patent litigation against any entity (including a
|
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
85
|
+
or contributory patent infringement, then any patent licenses
|
|
86
|
+
granted to You under this License for that Work shall terminate
|
|
87
|
+
as of the date such litigation is filed.
|
|
88
|
+
|
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
91
|
+
modifications, and in Source or Object form, provided that You
|
|
92
|
+
meet the following conditions:
|
|
93
|
+
|
|
94
|
+
(a) You must give any other recipients of the Work or
|
|
95
|
+
Derivative Works a copy of this License; and
|
|
96
|
+
|
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
|
98
|
+
stating that You changed the files; and
|
|
99
|
+
|
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
|
102
|
+
attribution notices from the Source form of the Work,
|
|
103
|
+
excluding those notices that do not pertain to any part of
|
|
104
|
+
the Derivative Works; and
|
|
105
|
+
|
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
|
108
|
+
include a readable copy of the attribution notices contained
|
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
|
111
|
+
of the following places: within a NOTICE text file distributed
|
|
112
|
+
as part of the Derivative Works; within the Source form or
|
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
|
114
|
+
within a display generated by the Derivative Works, if and
|
|
115
|
+
wherever such third-party notices normally appear. The contents
|
|
116
|
+
of the NOTICE file are for informational purposes only and
|
|
117
|
+
do not modify the License. You may add Your own attribution
|
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
120
|
+
that such additional attribution notices cannot be construed
|
|
121
|
+
as modifying the License.
|
|
122
|
+
|
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
|
124
|
+
may provide additional or different license terms and conditions
|
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
128
|
+
the conditions stated in this License.
|
|
129
|
+
|
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
133
|
+
this License, without any additional terms or conditions.
|
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
135
|
+
the terms of any separate license agreement you may have executed
|
|
136
|
+
with Licensor regarding such Contributions.
|
|
137
|
+
|
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
140
|
+
except as required for reasonable and customary use in describing the
|
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
142
|
+
|
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
|
152
|
+
|
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
|
158
|
+
incidental, or consequential damages of any character arising as a
|
|
159
|
+
result of this License or out of the use or inability to use the
|
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
162
|
+
other commercial damages or losses), even if such Contributor
|
|
163
|
+
has been advised of the possibility of such damages.
|
|
164
|
+
|
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
168
|
+
or other liability obligations and/or rights consistent with this
|
|
169
|
+
License. However, in accepting such obligations, You may act only
|
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
174
|
+
of your accepting any such warranty or additional liability.
|
|
175
|
+
|
|
176
|
+
END OF TERMS AND CONDITIONS
|
|
177
|
+
|
|
178
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
179
|
+
|
|
180
|
+
To apply the Apache License to your work, attach the following
|
|
181
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
182
|
+
replaced with your own identifying information. (Don't include
|
|
183
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
184
|
+
comment syntax for the file format. We also recommend that a
|
|
185
|
+
file or class name and description of purpose be included on the
|
|
186
|
+
same "printed page" as the copyright notice for easier
|
|
187
|
+
identification within third-party archives.
|
|
188
|
+
|
|
189
|
+
Copyright [yyyy] [name of copyright owner]
|
|
190
|
+
|
|
191
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
192
|
+
you may not use this file except in compliance with the License.
|
|
193
|
+
You may obtain a copy of the License at
|
|
194
|
+
|
|
195
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
196
|
+
|
|
197
|
+
Unless required by applicable law or agreed to in writing, software
|
|
198
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
199
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
200
|
+
See the License for the specific language governing permissions and
|
|
201
|
+
limitations under the License.
|
package/README.md
ADDED
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
# `@iota/graphql-transport`
|
|
2
|
+
|
|
3
|
+
`@iota/graphql-transport` is part of the **IOTA Rebased SDK**, designed specifically for interacting with the IOTA Rebased protocol.
|
|
4
|
+
|
|
5
|
+
This package provides a `IotaTransport` that enables `IotaClient` to make requests using the RPC 2.0
|
|
6
|
+
(GraphQL) API instead of the JSON RPC API.
|
|
7
|
+
|
|
8
|
+
## Install
|
|
9
|
+
|
|
10
|
+
```bash
|
|
11
|
+
npm install --save @iota/graphql-transport
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Setup
|
|
15
|
+
|
|
16
|
+
```ts
|
|
17
|
+
import { IotaClientGraphQLTransport } from '@iota/graphql-transport';
|
|
18
|
+
import { getFullnodeUrl, IotaClient } from '@iota/iota-sdk/client';
|
|
19
|
+
|
|
20
|
+
const client = new IotaClient({
|
|
21
|
+
transport: new IotaClientGraphQLTransport({
|
|
22
|
+
url: 'https://iota-testnet.iota.org/graphql',
|
|
23
|
+
// When specified, the transport will fallback to JSON RPC for unsupported method and parameters
|
|
24
|
+
fallbackFullNodeUrl: getFullnodeUrl('testnet'),
|
|
25
|
+
}),
|
|
26
|
+
});
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
## Limitations
|
|
30
|
+
|
|
31
|
+
### Unsupported methods
|
|
32
|
+
|
|
33
|
+
The following methods are currently unsupported in IotaClientGraphQLTransport, and will either
|
|
34
|
+
error, or fallback to the JSON RPC API if a `fallbackFullNodeUrl` is provided:
|
|
35
|
+
|
|
36
|
+
- `subscribeTransaction`
|
|
37
|
+
- `subscribeEvents`
|
|
38
|
+
- `call`
|
|
39
|
+
- `getNetworkMetrics`
|
|
40
|
+
- `getMoveCallMetrics`
|
|
41
|
+
- `getAddressMetrics`
|
|
42
|
+
- `getEpochs`
|
|
43
|
+
- `dryRunTransactionBlock`
|
|
44
|
+
- `devInspectTransactionBlock`
|
|
45
|
+
- `executeTransactionBlock`
|
|
46
|
+
- `getParticipationMetrics`
|
|
47
|
+
- `getCirculatingSupply`
|
|
48
|
+
|
|
49
|
+
### Unsupported parameters
|
|
50
|
+
|
|
51
|
+
Some supported methods in `IotaClientGraphQLTransport` do not support the full set of parameters
|
|
52
|
+
available in the JSON RPC API.
|
|
53
|
+
|
|
54
|
+
If an unsupported parameter is used, the request will error, or fallback to JSON RPC API if a
|
|
55
|
+
`fallbackFullNodeUrl` is provided.
|
|
56
|
+
|
|
57
|
+
- `getOwnedObjects`:
|
|
58
|
+
- missing the `MatchAll`, `MatchAny`, `MatchNone`, and `Version` filters
|
|
59
|
+
- `queryEvents`:
|
|
60
|
+
- missing the `MoveEventField`, `Module`, `TimeRange`, `All`, `Any`, `And`, and `Or` filters
|
|
61
|
+
|
|
62
|
+
### Unsupported fields
|
|
63
|
+
|
|
64
|
+
- `queryTransactionBlocks`, `getTransactionBlock`, and `multiGetTransactionBlocks`
|
|
65
|
+
- missing `messageVersion`, `eventsDigest`, `sharedObjects`, `unwrapped`, `wrapped`, and
|
|
66
|
+
`unwrappedThenDeleted` in effects
|
|
67
|
+
- missing `id` for `events`
|
|
68
|
+
- `getStakes` and `getStakesByIds`
|
|
69
|
+
- missing `validatorAddress`
|
|
70
|
+
- `getLatestIotaSystemState` and `getLatestIotaSystemStateV2`
|
|
71
|
+
- missing `stakingPoolMappingsId`, `inactivePoolsId`, `pendingActiveValidatorsId`,
|
|
72
|
+
`validatorCandidatesId`
|
|
73
|
+
- missing `reportRecords` on validators
|
|
74
|
+
- `getCurrentEpoch`
|
|
75
|
+
- missing `reportRecords` on validators
|
|
76
|
+
- `queryEvents`
|
|
77
|
+
- missing `id` for `events`
|
|
78
|
+
- `getCheckpoint` and `getCheckpoints`
|
|
79
|
+
- missing `checkpointCommitments`
|
|
80
|
+
- `getCurrentEpoch`
|
|
81
|
+
- missing `epochTotalTransactions`
|
|
82
|
+
- `getDynamicFields`
|
|
83
|
+
- missing `objectId`, `digest` and `version` available for `DynamicObject` but not
|
|
84
|
+
`DynamicField`
|
|
85
|
+
|
|
86
|
+
### Performance
|
|
87
|
+
|
|
88
|
+
Some may require multiple requests to properly resolve:
|
|
89
|
+
|
|
90
|
+
- `getDynamicFieldObject` requires 2 requests
|
|
91
|
+
- `queryTransactionBlocks`, `getTransactionBlock`, and `multiGetTransactionBlocks`
|
|
92
|
+
- may require additional requests to load all `objectChanges`, `balanceChanges`,
|
|
93
|
+
`dependencies` and `events`
|
|
94
|
+
- `getNormalizedMoveModule` and `getNormalizedMoveModulesByPage`
|
|
95
|
+
- may require additional requests to load all `friends`, `functions`, and `structs`
|
|
96
|
+
- `getCheckpoint` and `getCheckpoints`,
|
|
97
|
+
- may require additional requests to load all `transactionBlocks` and `validators`
|
|
98
|
+
- `getLatestIotaSystemState`,`getLatestIotaSystemStateV2`, `getCurrentEpoch`, `getValidatorsApy` and `getCommitteeInfo`:
|
|
99
|
+
- may require additional requests to load all `validators`
|
|
100
|
+
|
|
101
|
+
### Pagination
|
|
102
|
+
|
|
103
|
+
Page sizes and limits for paginated methods are based on the defaults and limits of the GraphQL API,
|
|
104
|
+
so page sizes and limits may be different than those returned by the JSON RPC API
|