@stellar/stellar-sdk 11.0.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.
Files changed (112) hide show
  1. package/CHANGELOG.md +1275 -0
  2. package/LICENSE +228 -0
  3. package/README.md +274 -0
  4. package/dist/stellar-sdk.js +56470 -0
  5. package/dist/stellar-sdk.min.js +2 -0
  6. package/dist/stellar-sdk.min.js.LICENSE.txt +71 -0
  7. package/lib/browser.d.ts +6 -0
  8. package/lib/browser.js +37 -0
  9. package/lib/config.d.ts +52 -0
  10. package/lib/config.js +49 -0
  11. package/lib/contract_spec.d.ts +130 -0
  12. package/lib/contract_spec.js +549 -0
  13. package/lib/errors.d.ts +59 -0
  14. package/lib/errors.js +105 -0
  15. package/lib/federation/api.d.ts +11 -0
  16. package/lib/federation/api.js +7 -0
  17. package/lib/federation/index.d.ts +2 -0
  18. package/lib/federation/index.js +24 -0
  19. package/lib/federation/server.d.ts +118 -0
  20. package/lib/federation/server.js +253 -0
  21. package/lib/friendbot/index.d.ts +5 -0
  22. package/lib/friendbot/index.js +7 -0
  23. package/lib/horizon/account_call_builder.d.ts +55 -0
  24. package/lib/horizon/account_call_builder.js +64 -0
  25. package/lib/horizon/account_response.d.ts +58 -0
  26. package/lib/horizon/account_response.js +50 -0
  27. package/lib/horizon/assets_call_builder.d.ts +27 -0
  28. package/lib/horizon/assets_call_builder.js +45 -0
  29. package/lib/horizon/call_builder.d.ts +128 -0
  30. package/lib/horizon/call_builder.js +360 -0
  31. package/lib/horizon/claimable_balances_call_builder.d.ts +49 -0
  32. package/lib/horizon/claimable_balances_call_builder.js +58 -0
  33. package/lib/horizon/effect_call_builder.d.ts +53 -0
  34. package/lib/horizon/effect_call_builder.js +58 -0
  35. package/lib/horizon/friendbot_builder.d.ts +5 -0
  36. package/lib/horizon/friendbot_builder.js +33 -0
  37. package/lib/horizon/horizon_api.d.ts +523 -0
  38. package/lib/horizon/horizon_api.js +96 -0
  39. package/lib/horizon/horizon_axios_client.d.ts +30 -0
  40. package/lib/horizon/horizon_axios_client.js +48 -0
  41. package/lib/horizon/index.d.ts +7 -0
  42. package/lib/horizon/index.js +78 -0
  43. package/lib/horizon/ledger_call_builder.d.ts +22 -0
  44. package/lib/horizon/ledger_call_builder.js +39 -0
  45. package/lib/horizon/liquidity_pool_call_builder.d.ts +38 -0
  46. package/lib/horizon/liquidity_pool_call_builder.js +61 -0
  47. package/lib/horizon/offer_call_builder.d.ts +64 -0
  48. package/lib/horizon/offer_call_builder.js +81 -0
  49. package/lib/horizon/operation_call_builder.d.ts +68 -0
  50. package/lib/horizon/operation_call_builder.js +71 -0
  51. package/lib/horizon/orderbook_call_builder.d.ts +16 -0
  52. package/lib/horizon/orderbook_call_builder.js +46 -0
  53. package/lib/horizon/path_call_builder.d.ts +31 -0
  54. package/lib/horizon/path_call_builder.js +42 -0
  55. package/lib/horizon/payment_call_builder.d.ts +36 -0
  56. package/lib/horizon/payment_call_builder.js +48 -0
  57. package/lib/horizon/server.d.ts +361 -0
  58. package/lib/horizon/server.js +507 -0
  59. package/lib/horizon/server_api.d.ts +279 -0
  60. package/lib/horizon/server_api.js +19 -0
  61. package/lib/horizon/strict_receive_path_call_builder.d.ts +34 -0
  62. package/lib/horizon/strict_receive_path_call_builder.js +51 -0
  63. package/lib/horizon/strict_send_path_call_builder.d.ts +34 -0
  64. package/lib/horizon/strict_send_path_call_builder.js +51 -0
  65. package/lib/horizon/trade_aggregation_call_builder.d.ts +48 -0
  66. package/lib/horizon/trade_aggregation_call_builder.js +82 -0
  67. package/lib/horizon/trades_call_builder.d.ts +50 -0
  68. package/lib/horizon/trades_call_builder.js +74 -0
  69. package/lib/horizon/transaction_call_builder.d.ts +58 -0
  70. package/lib/horizon/transaction_call_builder.js +66 -0
  71. package/lib/horizon/types/account.d.ts +5 -0
  72. package/lib/horizon/types/account.js +5 -0
  73. package/lib/horizon/types/assets.d.ts +19 -0
  74. package/lib/horizon/types/assets.js +5 -0
  75. package/lib/horizon/types/effects.d.ts +285 -0
  76. package/lib/horizon/types/effects.js +62 -0
  77. package/lib/horizon/types/offer.d.ts +20 -0
  78. package/lib/horizon/types/offer.js +5 -0
  79. package/lib/horizon/types/trade.d.ts +13 -0
  80. package/lib/horizon/types/trade.js +5 -0
  81. package/lib/index.d.ts +14 -0
  82. package/lib/index.js +79 -0
  83. package/lib/soroban/api.d.ts +247 -0
  84. package/lib/soroban/api.js +32 -0
  85. package/lib/soroban/axios.d.ts +3 -0
  86. package/lib/soroban/axios.js +16 -0
  87. package/lib/soroban/browser.d.ts +6 -0
  88. package/lib/soroban/browser.js +37 -0
  89. package/lib/soroban/index.d.ts +8 -0
  90. package/lib/soroban/index.js +72 -0
  91. package/lib/soroban/jsonrpc.d.ts +33 -0
  92. package/lib/soroban/jsonrpc.js +93 -0
  93. package/lib/soroban/parsers.d.ts +17 -0
  94. package/lib/soroban/parsers.js +111 -0
  95. package/lib/soroban/server.d.ts +427 -0
  96. package/lib/soroban/server.js +598 -0
  97. package/lib/soroban/transaction.d.ts +20 -0
  98. package/lib/soroban/transaction.js +55 -0
  99. package/lib/soroban/utils.d.ts +1 -0
  100. package/lib/soroban/utils.js +9 -0
  101. package/lib/stellartoml/index.d.ts +121 -0
  102. package/lib/stellartoml/index.js +78 -0
  103. package/lib/utils.d.ts +12 -0
  104. package/lib/utils.js +32 -0
  105. package/lib/webauth/errors.d.ts +4 -0
  106. package/lib/webauth/errors.js +37 -0
  107. package/lib/webauth/index.d.ts +2 -0
  108. package/lib/webauth/index.js +27 -0
  109. package/lib/webauth/utils.d.ts +294 -0
  110. package/lib/webauth/utils.js +332 -0
  111. package/package.json +153 -0
  112. package/types/dom-monkeypatch.d.ts +126 -0
package/CHANGELOG.md ADDED
@@ -0,0 +1,1275 @@
1
+ # Changelog
2
+
3
+ A breaking change will get clearly marked in this log.
4
+
5
+
6
+ ## [v11.0.0](https://github.com/stellar/js-stellar-sdk/compare/v10.2.1...v11.0.0)
7
+
8
+ ### Breaking Changes
9
+
10
+ * The package has been renamed to `@stellar/stellar-sdk`.
11
+ * The new minimum supported version is Node 18.
12
+ * The `PaymentCallBuilder` was incorrectly indicating that it would return a collection of `Payment` records, while [in reality](https://developers.stellar.org/api/horizon/resources/list-all-payments) it can return a handful of "payment-like" records ([#885](https://github.com/stellar/js-stellar-sdk/pull/885)).
13
+
14
+ ### Fixed
15
+ * The `SorobanRpc.Server.getEvents` method now correctly parses responses without a `contractId` field set. The `events[i].contractId` field on an event is now optional, omitted if there was no ID for the event (e.g. system events; ([#883](https://github.com/stellar/js-stellar-sdk/pull/883))).
16
+
17
+
18
+ ## [v11.0.0-beta.6](https://github.com/stellar/js-stellar-sdk/compare/v11.0.0-beta.5...v11.0.0-beta.6)
19
+
20
+ ### Fixed
21
+ * The `stellar-base` library has been upgraded to `beta.4` which contains a bugfix for large sequence numbers ([#877](https://github.com/stellar/js-stellar-sdk/pull/877)).
22
+ * The `SorobanRpc.Server.getTransaction()` method will now return the full response when encountering a `FAILED` transaction result ([#872](https://github.com/stellar/js-stellar-sdk/pull/872)).
23
+ * The `SorobanRpc.Server.getEvents()` method will correctly parse the event value (which is an `xdr.ScVal` rather than an `xdr.DiagnosticEvent`, see the modified `SorobanRpc.Api.EventResponse.value`; [#876](https://github.com/stellar/js-stellar-sdk/pull/876)).
24
+
25
+
26
+ ## [v11.0.0-beta.5](https://github.com/stellar/js-stellar-sdk/compare/v11.0.0-beta.4...v11.0.0-beta.5)
27
+
28
+ ### Breaking Changes
29
+ * The `soroban-client` library ([stellar/js-soroban-client](https://github.com/stellar/js-soroban-client)) has been merged into this package, causing significant breaking changes in the module structure ([#860](https://github.com/stellar/js-stellar-sdk/pull/860)):
30
+ - The namespaces have changed to move each server-dependent component into its own module. Shared components (e.g. `TransactionBuilder`) are still in the top level, Horizon-specific interactions are in the `Horizon` namespace (i.e. `Server` is now `Horizon.Server`), and new Soroban RPC interactions are in the `SorobanRpc` namespace.
31
+ - There is a [detailed migration guide](https://gist.github.com/Shaptic/5ce4f16d9cce7118f391fbde398c2f30) available to outline both the literal (i.e. necessary code changes) and philosophical (i.e. how to find certain functionality) changes needed to adapt to this merge.
32
+ * The `SorobanRpc.Server.prepareTransaction` and `SorobanRpc.assembleTransaction` methods no longer need an optional `networkPassphrase` parameter, because it is implicitly part of the transaction already ([#870](https://github.com/stellar/js-stellar-sdk/pull/870)).
33
+
34
+
35
+ ## [v11.0.0-beta.4](https://github.com/stellar/js-stellar-sdk/compare/v11.0.0-beta.3...v11.0.0-beta.4)
36
+
37
+ ### Fixed
38
+ - The `stellar-base` dependency has been pinned to a specific version to avoid incorrect semver resolution ([#867](https://github.com/stellar/js-stellar-sdk/pull/867)).
39
+
40
+
41
+ ## [v11.0.0-beta.3](https://github.com/stellar/js-stellar-sdk/compare/v11.0.0-beta.2...v11.0.0-beta.3)
42
+
43
+ ### Fixed
44
+ - Fix a webpack error preventing correct exports of the SDK for browsers ([#862](https://github.com/stellar/js-stellar-sdk/pull/862)).
45
+
46
+
47
+ ## [v11.0.0-beta.2](https://github.com/stellar/js-stellar-sdk/compare/v11.0.0-beta.1...v11.0.0-beta.2)
48
+
49
+ ### Breaking Changes
50
+ - Certain effects have been renamed to align better with the "tense" that other structures have ([#844](https://github.com/stellar/js-stellar-sdk/pull/844)):
51
+ * `DepositLiquidityEffect` -> `LiquidityPoolDeposited`
52
+ * `WithdrawLiquidityEffect` -> `LiquidityPoolWithdrew`
53
+ * `LiquidityPoolTradeEffect` -> `LiquidityPoolTrade`
54
+ * `LiquidityPoolCreatedEffect` -> `LiquidityPoolCreated`
55
+ * `LiquidityPoolRevokedEffect` -> `LiquidityPoolRevoked`
56
+ * `LiquidityPoolRemovedEffect` -> `LiquidityPoolRemoved`
57
+
58
+ ### Add
59
+ - New effects have been added to support Protocol 20 (Soroban) ([#842](https://github.com/stellar/js-stellar-sdk/pull/842)):
60
+ * `ContractCredited` occurs when a Stellar asset moves **into** its corresponding Stellar Asset Contract instance
61
+ * `ContractDebited` occurs when a Stellar asset moves **out of** its corresponding Stellar Asset Contract instance
62
+ - Asset stat records (`ServerApi.AssetRecord`) contain two new fields to support the Protocol 20 (Soroban) release ([#841](https://github.com/stellar/js-stellar-sdk/pull/841)):
63
+ * `num_contracts` - the integer quantity of contracts that hold this asset
64
+ * `contracts_amount` - the total units of that asset held by contracts
65
+ - New operation responses ([#845](https://github.com/stellar/js-stellar-sdk/pull/845)):
66
+ * `invokeHostFunction`: see `Horizon.InvokeHostFunctionOperationResponse`
67
+ * `bumpFootprintExpiration`: see `Horizon.BumpFootprintExpirationOperationResponse`
68
+ * `restoreFootprint`: see `Horizon.RestoreFootprintOperationResponse`
69
+ * You can refer to the actual definitions for details, but the gist of the schemas is below:
70
+ ```ts
71
+ interface InvokeHostFunctionOperationResponse {
72
+ function: string;
73
+ parameters: {
74
+ value: string;
75
+ type: string;
76
+ }[];
77
+ address: string;
78
+ salt: string;
79
+ asset_balance_changes: {
80
+ type: string;
81
+ from: string;
82
+ to: string;
83
+ amount: string;
84
+ }[];
85
+ }
86
+ interface BumpFootprintExpirationOperationResponse {
87
+ ledgersToExpire: string;
88
+ }
89
+ interface RestoreFootprintOperationResponse {};
90
+ ```
91
+
92
+ ### Fixed
93
+ - Some effect definitions that were missing have been added ([#842](https://github.com/stellar/js-stellar-sdk/pull/842)):
94
+ * `ClaimableBalanceClawedBack` is now defined
95
+ * `type EffectRecord` now has all of the effect types
96
+ - The `stellar-base` library has been upgraded to support the latest Protocol 20 XDR schema and all Soroban functionality ([]()).
97
+
98
+
99
+ ## [v11.0.0-beta.1](https://github.com/stellar/js-stellar-sdk/compare/v11.0.0-beta.0...v11.0.0-beta.1)
100
+
101
+ ### Update
102
+
103
+ - Bundle size has decreased by dropping unnecessary dependencies (`lodash`: [#822](https://github.com/stellar/js-stellar-sdk/pull/822), `es6-promise`: [#823](https://github.com/stellar/js-stellar-sdk/pull/823), polyfills: [#825](https://github.com/stellar/js-stellar-sdk/pull/825), `detect-node`: [#831](https://github.com/stellar/js-stellar-sdk/issues/831)).
104
+ - Dependencies (including `stellar-base`) have been updated to their latest versions ([#825](https://github.com/stellar/js-stellar-sdk/pull/825), [#827](https://github.com/stellar/js-stellar-sdk/pull/827)).
105
+
106
+
107
+ ## [v11.0.0-beta.0](https://github.com/stellar/js-stellar-sdk/compare/v10.4.1...v11.0.0-beta.0)
108
+
109
+ This version is marked by a major version bump because of the significant upgrades to underlying dependencies. While there should be no noticeable API changes from a downstream perspective, there may be breaking changes in the way that this library is bundled.
110
+
111
+ ### Update
112
+
113
+ - Build system has been overhauled to support Webpack 5 ([#814](https://github.com/stellar/js-stellar-sdk/pull/814)).
114
+ - `stellar-base` has been updated to its corresponding overhaul ([#818](https://github.com/stellar/js-stellar-sdk/pull/818)).
115
+
116
+ ### Fix
117
+
118
+ - Missing fields have been added to certain API responses ([#801](https://github.com/stellar/js-stellar-sdk/pull/801) and [#797](https://github.com/stellar/js-stellar-sdk/pull/797)).
119
+
120
+
121
+ ## [v10.4.1](https://github.com/stellar/js-stellar-sdk/compare/v10.4.0...v10.4.1)
122
+
123
+ ### Update
124
+
125
+ - Bumps `stellar-base` version to [v8.2.2](https://github.com/stellar/js-stellar-base/releases/tag/v8.2.2) to include latest fix: enabling fast signing in service workers ([#806](https://github.com/stellar/js-stellar-sdk/pull/806)).
126
+
127
+
128
+ ## [v10.4.0](https://github.com/stellar/js-stellar-sdk/compare/v10.3.0...v10.4.0)
129
+
130
+ ### Add
131
+
132
+ - Add [SEP-1](https://stellar.org/protocol/sep-1) fields to `StellarTomlResolver` for type checks ([#794](https://github.com/stellar/js-stellar-sdk/pull/794)).
133
+ - Add support for passing `X-Auth-Token` as a custom header ([#795](https://github.com/stellar/js-stellar-sdk/pull/795)).
134
+
135
+ ### Update
136
+
137
+ - Bumps `stellar-base` version to [v8.2.1](https://github.com/stellar/js-stellar-base/releases/tag/v8.2.1) to include latest fixes.
138
+
139
+
140
+ ## [v10.3.0](https://github.com/stellar/js-stellar-sdk/compare/v10.2.0...v10.3.0)
141
+
142
+ ### Fix
143
+
144
+ - Adds `successful` field to transaction submission response ([#790](https://github.com/stellar/js-stellar-sdk/pull/790)).
145
+
146
+ ### Update
147
+
148
+ - Bumps `stellar-base` version to [v8.2.0](https://github.com/stellar/js-stellar-base/releases/tag/v8.2.0) to include CAP-40 support in `Operation.setOptions`.
149
+
150
+
151
+ ## [v10.2.0](https://github.com/stellar/js-stellar-sdk/compare/v10.1.2...v10.2.0)
152
+
153
+ ### Fix
154
+
155
+ - Adds the missing `successful` field to transaction responses ([#790](https://github.com/stellar/js-stellar-sdk/pull/790)).
156
+
157
+ ### Update
158
+
159
+ - Bumps `stellar-base` version to [v8.1.0](https://github.com/stellar/js-stellar-base/releases/tag/v8.1.0) to include bug fixes and latest XDR changes.
160
+
161
+
162
+ ## [v10.1.2](https://github.com/stellar/js-stellar-sdk/compare/v10.1.1...v10.1.2)
163
+
164
+ ### Fix
165
+
166
+ - Upgrades the `eventsource` dependency to fix a critical security vulnerability ([#783](https://github.com/stellar/js-stellar-sdk/pull/783)).
167
+
168
+
169
+ ## [v10.1.1](https://github.com/stellar/js-stellar-sdk/compare/v10.1.0...v10.1.1)
170
+
171
+ ### Fix
172
+
173
+ - Reverts a change from [v10.1.0](#v10.1.0) which caused streams to die prematurely ([#780](https://github.com/stellar/js-stellar-sdk/pull/780)).
174
+ - Bumps `stellar-base` version to [v8.0.1](https://github.com/stellar/js-stellar-base/releases/tag/v8.0.1) to include latest bugfixes.
175
+
176
+
177
+ ## [v10.1.0](https://github.com/stellar/js-stellar-sdk/compare/v10.0.1...v10.1.0-beta.0)
178
+
179
+ This is a promotion from the beta version without changes, besides upgrading the underlying [stellar-base@v8.0.0](https://github.com/stellar/js-stellar-base/releases/tag/v8.0.0) to its stable release.
180
+
181
+
182
+ ## [v10.1.0-beta.0](https://github.com/stellar/js-stellar-sdk/compare/v10.0.1...v10.1.0-beta.0)
183
+
184
+ ### Add
185
+
186
+ - Add a way to filter offers by seller: `OfferCallBuilder.seller(string)`, corresponding to `GET /offers?seller=<string>` ([#773](https://github.com/stellar/js-stellar-sdk/pull/773)).
187
+
188
+ ### Add
189
+
190
+ - Support for Protocol 19 ([#775](https://github.com/stellar/js-stellar-sdk/pull/775)):
191
+ * new precondition fields on a `TransactionResponse`
192
+ * new account fields on `AccountResponse` and `AccountRecord`
193
+ * bumping `stellar-base` to the latest beta version
194
+
195
+ ### Fix
196
+
197
+ - Add missing field to account responses: `last_modified_time` which is the time equivalent of the existing `last_modified_ledger` ([#770](https://github.com/stellar/js-stellar-sdk/pull/770)).
198
+ - Stop opening extra connections when SSE streams receive `event: close` events ([#772](https://github.com/stellar/js-stellar-sdk/pull/772)).
199
+ - Fix SSE streams not loading under React Native (thank you, @hunterpetersen!) ([#761](https://github.com/stellar/js-stellar-sdk/pull/761)).
200
+
201
+
202
+ ## [v10.0.1](https://github.com/stellar/js-stellar-sdk/compare/v10.0.0...v10.0.1)
203
+
204
+ ### Fix
205
+
206
+ - Add missing fields to the `LedgerRecord`: `successful_transaction_count` and `failed_transaction_count` ([#740](https://github.com/stellar/js-stellar-sdk/pull/740)). Note that this also marks several fields as _deprecated_ because they don't actually exist in the Horizon API response:
207
+ * `transaction_count`: superceded by the sum of the aforementioned fields
208
+ * `base_fee`: superceded by the `base_fee_in_stroops` field
209
+ * `base_reserve`: superceded by the `base_reserve_in_stroops` field
210
+
211
+ These deprecated fields will be removed in the next major version. It's unlikely that this breaking change should affect anyone, as these fields have likely been missing/invalid for some time.
212
+
213
+ ### Update
214
+ - Update a number of dependencies that needed various security updates:
215
+ * several dependencies bumped their patch version ([#736](https://github.com/stellar/js-stellar-sdk/pull/736), [#684](https://github.com/stellar/js-stellar-sdk/pull/684), [#672](https://github.com/stellar/js-stellar-sdk/pull/672), [#666](https://github.com/stellar/js-stellar-sdk/pull/666), [#644](https://github.com/stellar/js-stellar-sdk/pull/644), [#622](https://github.com/stellar/js-stellar-sdk/pull/622))
216
+ * axios has been bumped to 0.25.0 without causing breaking changes ([#742](https://github.com/stellar/js-stellar-sdk/pull/742))
217
+ * the `karma` suite of packages has been updated to the latest major version ([#743](https://github.com/stellar/js-stellar-sdk/pull/743))
218
+
219
+ All of the dependencies in question besides `axios` were _developer_ dependencies, so there never was downstream security impact nor will there be downstream upgrade impact.
220
+
221
+
222
+ ## [v10.0.0](https://github.com/stellar/js-stellar-sdk/compare/v9.1.0...v10.0.0)
223
+
224
+ This release introduces breaking changes from `stellar-base`. It adds **unconditional support for muxed accounts**. Please refer to the corresponding [release notes](https://github.com/stellar/js-stellar-base/releases/tag/v7.0.0) for details on the breaking changes there.
225
+
226
+ ### Breaking Updates
227
+
228
+ - Upgrades the stellar-base library to v7.0.0 ([#735](https://github.com/stellar/js-stellar-sdk/pull/735)).
229
+
230
+ - Removes the `AccountResponse.createSubaccount` method since this is also gone from the underlying `Account` interface. The `stellar-base` release notes describe alternative construction methods ([#735](https://github.com/stellar/js-stellar-sdk/pull/735)).
231
+
232
+ ### Fix
233
+
234
+ - Use the right string for liquidity pool trades ([#734](https://github.com/stellar/js-stellar-sdk/pull/734)).
235
+
236
+
237
+ ## [v9.1.0](https://github.com/stellar/js-stellar-sdk/compare/v9.0.1...v9.1.0)
238
+
239
+ ### Add
240
+
241
+ - Adds a way to filter liquidity pools by participating account: `server.liquidityPools.forAccount(id)` ([#727](https://github.com/stellar/js-stellar-sdk/pull/727)).
242
+
243
+ ### Updates
244
+
245
+ - Updates the following SEP-10 utility functions to include [client domain verification](https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0010.md#verifying-the-client-domain) functionality ([#720](https://github.com/stellar/js-stellar-sdk/pull/720)):
246
+ - `Utils.buildChallengeTx()` accepts the `clientDomain` and `clientSigningKey` optional parameters
247
+ - `Utils.readChallengeTx()` parses challenge transactions containing a `client_domain` ManageData operation
248
+ - `Utils.verifyChallengeTxSigners()` verifies an additional signature from the `clientSigningKey` keypair if a `client_domain` Manage Data operation is included in the challenge
249
+
250
+ - Bumps `stellar-base` version to [v6.0.6](https://github.com/stellar/js-stellar-base/releases/tag/v6.0.6).
251
+
252
+ ### Fix
253
+
254
+ - Fixes the `type_i` enumeration field to accurately reflect liquidity pool effects ([#723](https://github.com/stellar/js-stellar-sdk/pull/723)).
255
+
256
+ - Upgrades axios dependency to v0.21.4 to alleviate security concern ([GHSA-cph5-m8f7-6c5x](https://github.com/advisories/GHSA-cph5-m8f7-6c5x), [#724](https://github.com/stellar/js-stellar-sdk/pull/724)).
257
+
258
+ - Publish Bower package to [stellar/bower-js-stellar-sdk](https://github.com/stellar/bower-js-stellar-sdk) ([#725](https://github.com/stellar/js-stellar-sdk/pull/725)).
259
+
260
+
261
+ ## [v9.0.1](https://github.com/stellar/js-stellar-sdk/compare/v9.0.0-beta.1...v9.0.1)
262
+
263
+ This stable release adds **support for Protocol 18**. For details, you can refer to [CAP-38](https://stellar.org/protocol/cap-38) for XDR changes and [this document](https://docs.google.com/document/d/1pXL8kr1a2vfYSap9T67R-g72B_WWbaE1YsLMa04OgoU/view) for changes to the Horizon API.
264
+
265
+ Refer to the release notes for the betas (e.g. [v9.0.0-beta.0](https://github.com/stellar/js-stellar-sdk/releases/v9.0.0-beta.0)) for a comprehensive list of changes to this library.
266
+
267
+ ### Fix
268
+
269
+ - Corrects the `reserves` field on `LiquidityPoolRecord`s to be an array ([#715](https://github.com/stellar/js-stellar-sdk/pull/715)).
270
+ - Bumps the `stellar-base` dependency to [v6.0.4](https://github.com/stellar/js-stellar-base/releases/tag/v6.0.4) ([#715](https://github.com/stellar/js-stellar-sdk/pull/715)).
271
+
272
+
273
+ ## [v9.0.0-beta.1](https://github.com/stellar/js-stellar-sdk/compare/v9.0.0-beta.0...v9.0.0-beta.1)
274
+
275
+ ### Add
276
+
277
+ - Add `/liquidity_pools/:id/trades` endpoint ([#710](https://github.com/stellar/js-stellar-sdk/pull/710))
278
+
279
+ ### Updates
280
+
281
+ - Updates the following SEP-10 utility functions to be compilant with the protocols ([#709](https://github.com/stellar/js-stellar-sdk/pull/709/), [stellar-protocol/#1036](https://github.com/stellar/stellar-protocol/pull/1036))
282
+ - Updated `utils.buildChallengeTx()` to accept muxed accounts (`M...`) for client account IDs
283
+ - Updated `utils.buildChallengeTx()` to accept a `memo` parameter to attach to the challenge transaction
284
+ - Updated `utils.readChallengeTx()` to provide a `memo` property in the returned object
285
+ - Updated `utils.readChallengeTx()` to validate challenge transactions with muxed accounts (`M...`) as the client account ID
286
+
287
+ ### Fix
288
+
289
+ - Drops the `chai-http` dependency to be only for developers ([#707](https://github.com/stellar/js-stellar-sdk/pull/707)).
290
+
291
+ ## [v9.0.0-beta.0](https://github.com/stellar/js-stellar-sdk/compare/v8.2.5...v9.0.0-beta.0)
292
+
293
+ This beta release adds **support for Automated Market Makers**. For details, you can refer to [CAP-38](https://stellar.org/protocol/cap-38) for XDR changes and [this document](https://docs.google.com/document/d/1pXL8kr1a2vfYSap9T67R-g72B_WWbaE1YsLMa04OgoU/view) for detailed changes to the Horizon API.
294
+
295
+ ### Add
296
+
297
+ - Introduced a `LiquidityPoolCallBuilder` to make calls to a new endpoint:
298
+ * `/liquidity_pools[?reserves=...]` - a collection of liquidity pools, optionally filtered by one or more assets ([#682](https://github.com/stellar/js-stellar-sdk/pull/682))
299
+ * `/liquidity_pools/:id` - a specific liquidity pool ([#687](https://github.com/stellar/js-stellar-sdk/pull/687))
300
+
301
+ - Expanded the `TransactionCallBuilder`, `OperationCallBuilder`, and `EffectsCallBuilder`s to apply to specific liquidity pools ([#689](https://github.com/stellar/js-stellar-sdk/pull/689)). This corresponds to the following new endpoints:
302
+ * `/liquidity_pools/:id/transactions`
303
+ * `/liquidity_pools/:id/operations`
304
+ * `/liquidity_pools/:id/effects`
305
+
306
+ - Expanded the `TradesCallBuilder` to support fetching liquidity pool trades and accepts a new `trade_type` filter ([#685](https://github.com/stellar/js-stellar-sdk/pull/685)):
307
+ * `/trades?trade_type={orderbook,liquidity_pools,all}`. By default, the filter is `all`, including both liquidity pool and orderbook records.
308
+ * A liquidity pool trade contains the following fields:
309
+ - `liquidity_pool_fee_bp`: LP fee expressed in basis points, and *either*
310
+ - `base_liquidity_pool_id` or `counter_liquidity_pool_id`
311
+
312
+ - Added new effects related to liquidity pools ([#690](https://github.com/stellar/js-stellar-sdk/pull/690)):
313
+ * `DepositLiquidityEffect`
314
+ * `WithdrawLiquidityEffect`
315
+ * `LiquidityPoolTradeEffect`
316
+ * `LiquidityPoolCreatedEffect`
317
+ * `LiquidityPoolRemovedEffect`
318
+ * `LiquidityPoolRevokedEffect`
319
+
320
+ - Added new responses related to liquidity pool operations ([#692](https://github.com/stellar/js-stellar-sdk/pull/692)):
321
+ * `DepositLiquidityOperationResponse`
322
+ * `WithdrawLiquidityOperationResponse`
323
+
324
+ ### Updates
325
+
326
+ - Updated the underlying `stellar-base` library to [v6.0.1](https://github.com/stellar/js-stellar-base/releases/tag/v6.0.1) to include CAP-38 changes ([#681](https://github.com/stellar/js-stellar-sdk/pull/681)).
327
+
328
+ - Updated various developer dependencies to secure versions ([#671](https://github.com/stellar/js-stellar-sdk/pull/671)).
329
+
330
+ - Updated `AccountResponse` to include liquidity pool shares in its `balances` field ([#688](https://github.com/stellar/js-stellar-sdk/pull/688)).
331
+
332
+ - Updated `AccountCallBuilder` to allow filtering based on participation in a certain liquidity pool ([#688](https://github.com/stellar/js-stellar-sdk/pull/688)), corresponding to the following new filter:
333
+ * `/accounts?reserves=[...list of assets...]`
334
+
335
+ - Updated `RevokeSponsorshipOperationResponse` to contain an optional attribute `trustline_liquidity_pool_id`, for when a liquidity pool trustline is revoked ([#690](https://github.com/stellar/js-stellar-sdk/pull/690)).
336
+
337
+ ### Breaking changes
338
+
339
+ - A `TradeRecord` can now correspond to two different types of trades and has changed ([#685](https://github.com/stellar/js-stellar-sdk/pull/685)):
340
+ * `Orderbook` (the existing structure)
341
+ - `counter_offer_id` and `base_offer_id` only show up in these records
342
+ - the redundant `offer_id` field was removed; it matches `base_offer_id`
343
+ * `LiquidityPool` (new)
344
+ - `base_account` xor `counter_account` will appear in these records
345
+ * `price` fields changed from `number`s to `string`s
346
+ * The links to `base` and `counter` can now point to *either* an account or a liquidity pool
347
+
348
+ - An account's `balances` array can now include a new type ([#688](https://github.com/stellar/js-stellar-sdk/pull/688)):
349
+ * `asset_type` can now be `liquidity_pool_shares`
350
+ * The following fields are *not* included in pool share balances:
351
+ - `buying_liabilities`
352
+ - `selling_liabilities`
353
+ - `asset_code`
354
+ - `asset_issue`
355
+
356
+ - The `ChangeTrustOperationResponse` has changed ([#688](https://github.com/stellar/js-stellar-sdk/pull/688), [#692](https://github.com/stellar/js-stellar-sdk/pull/692)):
357
+ * `asset_type` can now be `liquidity_pool_shares`
358
+ * `asset_code`, `asset_issuer`, and `trustee` are now optional
359
+ * `liquidity_pool_id` is a new optional field
360
+
361
+ - The trustline effects (`TrustlineCreated`, `TrustlineUpdated`, `TrustlineRevoked`) have changed ([#690](https://github.com/stellar/js-stellar-sdk/pull/690)):
362
+ * the asset type can now be `liquidity_pool_shares`
363
+ * they can optionally include a `liquidity_pool_id`
364
+
365
+ - Trustline sponsorship effects (`TrustlineSponsorshipCreated`, `TrustlineSponsorshipUpdated`, `TrustlineSponsorshipRemoved`) have been updated ([#690](https://github.com/stellar/js-stellar-sdk/pull/690)):
366
+ * the `asset` field is now optional, and is replaced by
367
+ * the `liquidity_pool_id` field for liquidity pools
368
+
369
+
370
+ ## [v8.2.5](https://github.com/stellar/js-stellar-sdk/compare/v8.2.4...v8.2.5)
371
+
372
+ ### Update
373
+ - The `js-stellar-base` library has been updated to [v5.3.2](https://github.com/stellar/js-stellar-base/releases/tag/v5.3.2), which fixes a muxed account bug and updates vulnerable dependencies ([#670](https://github.com/stellar/js-stellar-sdk/pull/670)).
374
+
375
+
376
+ ## [v8.2.4](https://github.com/stellar/js-stellar-sdk/compare/v8.2.3...v8.2.4)
377
+
378
+ ### Fix
379
+ - Utils.readTransactionTx now checks timebounds with a 5-minute grace period to account for clock drift.
380
+
381
+
382
+ ## [v8.2.3](https://github.com/stellar/js-stellar-sdk/compare/v8.2.2...v8.2.3)
383
+
384
+ ### Fix
385
+ - Fix server signature verification in `Utils.readChallengeTx`. The function was
386
+ not verifying the server account had signed the challenge transaction.
387
+
388
+
389
+ ## [v8.2.2](https://github.com/stellar/js-stellar-sdk/compare/v8.2.1...v8.2.2)
390
+
391
+ ### Fix
392
+ - Fixes a breaking bug introduced in v8.2.0 in which `AccountResponse` no longer conformed to the `StellarBase.Account` interface, which was updated in [stellar-base@v5.2.0](https://github.com/stellar/js-stellar-base/releases/tag/v5.2.0) [(#655)](https://github.com/stellar/js-stellar-sdk/pull/655).
393
+
394
+
395
+ ## [v8.2.1](https://github.com/stellar/js-stellar-sdk/compare/v8.2.0...v8.2.1)
396
+
397
+ ### Fix
398
+ - A defunct query paramater (`?c=[...]`) has been removed now that Horizon properly sends Cache-Control headers [(#652)](https://github.com/stellar/js-stellar-sdk/pull/652).
399
+
400
+
401
+ ## [v8.2.0](https://github.com/stellar/js-stellar-sdk/compare/v8.1.1...v8.2.0)
402
+
403
+ ### Add
404
+ - Added support for querying the relevant transactions and operations for a claimable balance [(#628)](https://github.com/stellar/js-stellar-sdk/pull/628):
405
+ * `TransactionCallBuilder.forClaimableBalance()`: builds a query to `/claimable_balances/:id/transactions/`
406
+ * `OperationCallBuilder.forClaimableBalance()`: builds a query to `/claimable_balances/:id/operations/`
407
+
408
+ - Added support for new stat fields on the `/assets` endpoint [(#628)](https://github.com/stellar/js-stellar-sdk/pull/628):
409
+ * `accounts` - a breakdown of accounts using this asset by authorization type
410
+ * `balances` - a breakdown of balances by account authorization type
411
+ * `num_claimable_balances` - the number of pending claimable balances
412
+ * `claimable_balances_amount` - the total balance of pending claimable balances
413
+
414
+ - Added types for all Effects supported as an enum, and moved `Trade`, `Asset`, `Offer`, and `Account` types to separate files [(#635)](https://github.com/stellar/js-stellar-sdk/pull/635).
415
+
416
+ ### Update
417
+ - Upgraded `js-stellar-base` package to version `^5.2.1` from `^5.1.0`, refer to its [release notes](https://github.com/stellar/js-stellar-base/releases/tag/v5.2.0) for more [(#639)](https://github.com/stellar/js-stellar-sdk/pull/639):
418
+ * opt-in **support for muxed accounts** ([SEP-23](https://stellar.org/protocol/sep-23))
419
+ * exposing the `AuthClawbackEnabled` flag to Typescript to **complete Protocol 17 support**
420
+ * fixing a public key parsing regression
421
+
422
+ - Exposed more Protocol 17 (CAP-35) operations [(#633)](https://github.com/stellar/js-stellar-sdk/pull/633):
423
+ * The `/accounts` endpoint now resolves the `flags.auth_clawback_enabled` field.
424
+ * The operation responses for `clawback`, `clawbackClaimableBalance`, and `setTrustLineFlags` are now defined.
425
+ * The operation response for `setOptions` has been updated to show `auth_clawback_enabled`.
426
+
427
+ ## [v8.1.1](https://github.com/stellar/js-stellar-sdk/compare/v8.1.0...v8.1.1)
428
+
429
+ ### Fix
430
+
431
+ - Upgraded `js-stellar-base` package to version `^5.1.0` from `^5.0.0` to expose the Typescript hints for CAP-35 operations [(#629)](https://github.com/stellar/js-stellar-sdk/pull/629).
432
+
433
+
434
+ ## [v8.1.0](https://github.com/stellar/js-stellar-sdk/compare/v8.0.0...v8.1.0)
435
+
436
+ ### Update
437
+
438
+ - Upgraded `js-stellar-base` package to version `^5.0.0` from `^4.0.3` to support new CAP-35 operations [(#624)](https://github.com/stellar/js-stellar-sdk/pull/624)
439
+
440
+
441
+ ## [v8.0.0](https://github.com/stellar/js-stellar-sdk/compare/v7.0.0...v8.0.0)
442
+
443
+ ### Breaking
444
+
445
+ - Updates the SEP-10 utility function parameters to support [SEP-10 v3.1](https://github.com/stellar/stellar-protocol/commit/6c8c9cf6685c85509835188a136ffb8cd6b9c11c) [(#607)](https://github.com/stellar/js-stellar-sdk/pull/607)
446
+ - A new required `webAuthDomain` parameter was added to the following functions
447
+ - `utils.buildChallengeTx()`
448
+ - `utils.readChallengeTx()`
449
+ - `utils.verifyChallengeTxThreshold()`
450
+ - `utils.verifyChallengeTxSigners()`
451
+ - The `webAuthDomain` parameter is expected to match the value of the Manage Data operation with the 'web_auth_domain' key, if present
452
+
453
+ ### Fix
454
+
455
+ - Fixes bug where the first Manage Data operation in a challenge transaction could have a null value [(#591)](https://github.com/stellar/js-stellar-sdk/pull/591)
456
+
457
+ ### Update
458
+
459
+ - Upgraded `axios` package to version `^0.21.1` from `^0.19.0` to fix security vulnerabilities [(#608)](https://github.com/stellar/js-stellar-sdk/pull/608)
460
+
461
+ - Upgraded `js-stellar-base` package to version `^4.0.3` from `^4.0.0` to allow accounts with a balance of zero [(#616)](https://github.com/stellar/js-stellar-sdk/pull/616)
462
+
463
+ ## [v7.0.0](https://github.com/stellar/js-stellar-sdk/compare/v6.2.0...v7.0.0)
464
+
465
+ This release includes a major-version increase due to breaking changes included.
466
+
467
+ ### Breaking
468
+
469
+ - Updates the SEP-10 utility function parameters and return values to support [SEP-10 v3.0](https://github.com/stellar/stellar-protocol/commit/9d121f98fd2201a5edfe0ed2befe92f4bf88bfe4)
470
+ - The following functions replaced the `homeDomain` parameter with `homeDomains` (note: plural):
471
+ - `utils.readChallengeTx()`
472
+ - `utils.verifyChallengeTxThreshold()`
473
+ - `utils.verifyChallengeTxSigners()`
474
+ - `utils.readChallengeTx()` now returns an additional object attribute, `matchedHomeDomain`
475
+
476
+ ### Update
477
+
478
+ - Update challenge transaction helpers for SEP0010 v3.0.0. ([#596](https://github.com/stellar/js-stellar-sdk/pull/596))
479
+ * Restore `homeDomain` validation in `readChallengeTx()`.
480
+
481
+ ## [v6.2.0](https://github.com/stellar/js-stellar-sdk/compare/v6.1.0...v6.2.0)
482
+
483
+ ### Update
484
+
485
+ - Update challenge transaction helpers for SEP0010 v2.1.0. ([#581](https://github.com/stellar/js-stellar-sdk/issues/581))
486
+ * Remove verification of home domain.
487
+ * Allow additional manage data operations that have the source account set as the server key.
488
+
489
+ ## [v6.1.0](https://github.com/stellar/js-stellar-sdk/compare/v6.0.0...v6.1.0)
490
+
491
+ ### Update
492
+
493
+ - Update claim predicate fields to match Horizon 1.9.1 ([#575](https://github.com/stellar/js-stellar-sdk/pull/575)).
494
+
495
+ ## [v6.0.0](https://github.com/stellar/js-stellar-sdk/compare/v5.0.4...v6.0.0)
496
+
497
+ ### Add
498
+
499
+ - Add support for claimable balances ([#572](https://github.com/stellar/js-stellar-sdk/pull/572)).
500
+ Extend server class to allow loading claimable balances from Horizon. The following functions are available:
501
+
502
+ ```
503
+ server.claimableBalances();
504
+ server.claimableBalances().claimant(claimant);
505
+ server.claimableBalances().sponsor(sponsorID);
506
+ server.claimableBalances().asset(asset);
507
+ server.claimableBalances().claimableBalance(balanceID);
508
+ ```
509
+ - Add the following attributes to `AccountResponse` ([#572](https://github.com/stellar/js-stellar-sdk/pull/572)):
510
+ * `sponsor?: string`
511
+ * `num_sponsoring: number`
512
+ * `num_sponsored: number`
513
+
514
+ - Add the optional attribute `sponsor` to `AccountSigner`, `BalanceLineAsset`, `ClaimableBalanceRecord`, and `OfferRecord` ([#572](https://github.com/stellar/js-stellar-sdk/pull/572)).
515
+
516
+ - Add `sponsor` filtering support for `offers` and `accounts` ([#572](https://github.com/stellar/js-stellar-sdk/pull/572)).
517
+ * `server.offers().sponsor(accountID)`
518
+ * `server.accounts().sponsor(accountID)`
519
+
520
+ - Extend operation responses to support new operations ([#572](https://github.com/stellar/js-stellar-sdk/pull/572)).
521
+ * `create_claimable_balance` with the following fields:
522
+ * `asset` - asset available to be claimed (in canonical form),
523
+ * `amount` - amount available to be claimed,
524
+ * `claimants` - list of claimants with predicates (see below):
525
+ * `destination` - destination account ID,
526
+ * `predicate` - predicate required to claim a balance (see below).
527
+ * `claim_claimable_balance` with the following fields:
528
+ * `balance_id` - unique ID of balance to be claimed,
529
+ * `claimant` - account ID of a claimant.
530
+ * `begin_sponsoring_future_reserves` with the following fields:
531
+ * `sponsored_id` - account ID for which future reserves will be sponsored.
532
+ * `end_sponsoring_future_reserves` with the following fields:
533
+ * `begin_sponsor` - account sponsoring reserves.
534
+ * `revoke_sponsorship` with the following fields:
535
+ * `account_id` - if account sponsorship was revoked,
536
+ * `claimable_balance_id` - if claimable balance sponsorship was revoked,
537
+ * `data_account_id` - if account data sponsorship was revoked,
538
+ * `data_name` - if account data sponsorship was revoked,
539
+ * `offer_id` - if offer sponsorship was revoked,
540
+ * `trustline_account_id` - if trustline sponsorship was revoked,
541
+ * `trustline_asset` - if trustline sponsorship was revoked,
542
+ * `signer_account_id` - if signer sponsorship was revoked,
543
+ * `signer_key` - if signer sponsorship was revoked.
544
+
545
+ - Extend effect responses to support new effects ([#572](https://github.com/stellar/js-stellar-sdk/pull/572)).
546
+ * `claimable_balance_created` with the following fields:
547
+ * `balance_id` - unique ID of claimable balance,
548
+ * `asset` - asset available to be claimed (in canonical form),
549
+ * `amount` - amount available to be claimed.
550
+ * `claimable_balance_claimant_created` with the following fields:
551
+ * `balance_id` - unique ID of a claimable balance,
552
+ * `asset` - asset available to be claimed (in canonical form),
553
+ * `amount` - amount available to be claimed,
554
+ * `predicate` - predicate required to claim a balance (see below).
555
+ * `claimable_balance_claimed` with the following fields:
556
+ * `balance_id` - unique ID of a claimable balance,
557
+ * `asset` - asset available to be claimed (in canonical form),
558
+ * `amount` - amount available to be claimed,
559
+ * `account_sponsorship_created` with the following fields:
560
+ * `sponsor` - sponsor of an account.
561
+ * `account_sponsorship_updated` with the following fields:
562
+ * `new_sponsor` - new sponsor of an account,
563
+ * `former_sponsor` - former sponsor of an account.
564
+ * `account_sponsorship_removed` with the following fields:
565
+ * `former_sponsor` - former sponsor of an account.
566
+ * `trustline_sponsorship_created` with the following fields:
567
+ * `sponsor` - sponsor of a trustline.
568
+ * `trustline_sponsorship_updated` with the following fields:
569
+ * `new_sponsor` - new sponsor of a trustline,
570
+ * `former_sponsor` - former sponsor of a trustline.
571
+ * `trustline_sponsorship_removed` with the following fields:
572
+ * `former_sponsor` - former sponsor of a trustline.
573
+ * `claimable_balance_sponsorship_created` with the following fields:
574
+ * `sponsor` - sponsor of a claimable balance.
575
+ * `claimable_balance_sponsorship_updated` with the following fields:
576
+ * `new_sponsor` - new sponsor of a claimable balance,
577
+ * `former_sponsor` - former sponsor of a claimable balance.
578
+ * `claimable_balance_sponsorship_removed` with the following fields:
579
+ * `former_sponsor` - former sponsor of a claimable balance.
580
+ * `signer_sponsorship_created` with the following fields:
581
+ * `signer` - signer being sponsored.
582
+ * `sponsor` - signer sponsor.
583
+ * `signer_sponsorship_updated` with the following fields:
584
+ * `signer` - signer being sponsored.
585
+ * `former_sponsor` - the former sponsor of the signer.
586
+ * `new_sponsor` - the new sponsor of the signer.
587
+ * `signer_sponsorship_removed` with the following fields:
588
+ * `former_sponsor` - former sponsor of a signer.
589
+
590
+ ### Breaking
591
+
592
+ - Update `stellar-base` to `v4.0.0` which introduces a breaking change in the internal XDR library.
593
+
594
+ The following functions were renamed:
595
+
596
+ - `xdr.OperationBody.setOption()` -> `xdr.OperationBody.setOptions()`
597
+ - `xdr.OperationBody.manageDatum()` -> `xdr.OperationBody.manageData()`
598
+ - `xdr.OperationType.setOption()` -> `xdr.OperationType.setOptions()`
599
+ - `xdr.OperationType.manageDatum()` -> `xdr.OperationType.manageData()`
600
+
601
+ The following enum values were rename in `OperationType`:
602
+
603
+ - `setOption` -> `setOptions`
604
+ - `manageDatum` -> `manageData`
605
+
606
+
607
+ ## [v5.0.4](https://github.com/stellar/js-stellar-sdk/compare/v5.0.3...v5.0.4)
608
+
609
+ ### Update
610
+ - Add `tx_set_operation_count` to `ledger` resource ([#559](https://github.com/stellar/js-stellar-sdk/pull/559)).
611
+
612
+ ## [v5.0.3](https://github.com/stellar/js-stellar-sdk/compare/v5.0.2...v5.0.3)
613
+
614
+ ### Fix
615
+ - Fix regression on `server.offer().forAccount()` which wasn't allowing streaming ([#533](https://github.com/stellar/js-stellar-sdk/pull/553)).
616
+
617
+ ## [v5.0.2](https://github.com/stellar/js-stellar-sdk/compare/v5.0.1...v5.0.2)
618
+
619
+ ### Update
620
+
621
+ - Allow submitTransaction to receive a FeeBumpTransaction ([#548](https://github.com/stellar/js-stellar-sdk/pull/548)).
622
+
623
+ ## [v5.0.1](https://github.com/stellar/js-stellar-sdk/compare/v5.0.0...v5.0.1)
624
+
625
+ ### Update
626
+
627
+ - Skip SEP0029 (memo required check) for multiplexed accounts ([#538](https://github.com/stellar/js-stellar-sdk/pull/538)).
628
+
629
+ ### Fix
630
+ - Fix missing documentation for `stellar-base` ([#544](https://github.com/stellar/js-stellar-sdk/pull/544)).
631
+ - Move dom-monkeypatch to root types and publish to npm ([#543](https://github.com/stellar/js-stellar-sdk/pull/543)).
632
+
633
+ ## [v5.0.0](https://github.com/stellar/js-stellar-sdk/compare/v4.1.0...v5.0.0)
634
+
635
+ ### Add
636
+ - Add fee bump related attributes to `TransactionResponse` ([#532](https://github.com/stellar/js-stellar-sdk/pull/532)):
637
+ - `fee_account: string`.
638
+ - `fee_bump_transaction: FeeBumpTransactionResponse`:
639
+ ```js
640
+ interface FeeBumpTransactionResponse {
641
+ hash: string;
642
+ signatures: string[];
643
+ }
644
+ ```
645
+ - `inner_transaction: InnerTransactionResponse`:
646
+ ```js
647
+ interface InnerTransactionResponse {
648
+ hash: string;
649
+ signatures: string[];
650
+ max_fee: string;
651
+ }
652
+ ```
653
+ - Add `memo_bytes: string` to `TransactionResponse` ([#532](https://github.com/stellar/js-stellar-sdk/pull/532)).
654
+ - Add `authorize_to_maintain_liabilities: boolean` to `AllowTrustOperation` ([#532](https://github.com/stellar/js-stellar-sdk/pull/532)).
655
+ - Add `is_authorized_to_maintain_liabilities: boolean` to `BalanceLineNative` ([#532](https://github.com/stellar/js-stellar-sdk/pull/532)).
656
+ - Add new result codes to `TransactionFailedResultCodes` ([#531](https://github.com/stellar/js-stellar-sdk/pull/531)).
657
+ ```js
658
+ TX_FEE_BUMP_INNER_SUCCESS = "tx_fee_bump_inner_success",
659
+ TX_FEE_BUMP_INNER_FAILED = "tx_fee_bump_inner_failed",
660
+ TX_NOT_SUPPORTED = "tx_not_supported",
661
+ TX_SUCCESS = "tx_success",
662
+ TX_TOO_EARLY = "tx_too_early",
663
+ TX_TOO_LATE = "tx_too_late",
664
+ TX_MISSING_OPERATION = "tx_missing_operation",
665
+ TX_INSUFFICIENT_BALANCE = "tx_insufficient_balance",
666
+ TX_NO_SOURCE_ACCOUNT = "tx_no_source_account",
667
+ TX_INSUFFICIENT_FEE = "tx_insufficient_fee",
668
+ TX_INTERNAL_ERROR = "tx_internal_error",
669
+ ```
670
+
671
+ ### Breaking changes
672
+ - The attributes `max_fee` and `fee_charged` in `TransactionResponse` can be now a `number` or a `string`.
673
+ Update your code to handle both types since Horizon will start sending `string` in version `1.3.0` ([#528](https://github.com/stellar/js-stellar-sdk/pull/528)).
674
+ - Bump `stellar-base` to `v3.0.0`: This new version of stellar-base brings support for protocol 13, including multiple breaking changes which might affect your code, please review the list of breaking changes in [stellar-base@3.0.0](https://github.com/stellar/js-stellar-base/releases/tag/v3.0.0) release ([#524](https://github.com/stellar/js-stellar-sdk/pull/524)).
675
+ - Make `networkPassphrase` a required argument in `Utils.buildChallengeTx` and `Utils.readChallengeTx` ([#524](https://github.com/stellar/js-stellar-sdk/pull/524)).
676
+ - Remove `Server.paths` ([#525](https://github.com/stellar/js-stellar-sdk/pull/525)).
677
+
678
+ ## [v5.0.0-alpha.2](https://github.com/stellar/js-stellar-sdk/compare/v5.0.0-alpha.1..v5.0.0-alpha.2)
679
+
680
+ ### Update
681
+ - Update `stellar-base` to `v3.0.0-alpha-1`.
682
+
683
+ ## [v5.0.0-alpha.1](https://github.com/stellar/js-stellar-sdk/compare/v4.1.0...v5.0.0-alpha.1)
684
+
685
+ ### Breaking changes
686
+ - Bump `stellar-base` to `v3.0.0-alpha-0`: This new version of stellar-base brings support for protocol 13, including multiple breaking changes which might affect your code, please review the list of breaking changes in [stellar-base@3.0.0-alpha.0](https://github.com/stellar/js-stellar-base/releases/tag/v3.0.0-alpha.0) release ([#524](https://github.com/stellar/js-stellar-sdk/pull/524)).
687
+ - Make `networkPassphrase` a required argument in `Utils.buildChallengeTx` and `Utils.readChallengeTx` ([#524](https://github.com/stellar/js-stellar-sdk/pull/524)).
688
+ - Remove `Server.paths` ([#525](https://github.com/stellar/js-stellar-sdk/pull/525)).
689
+
690
+ ## [v4.1.0](https://github.com/stellar/js-stellar-sdk/compare/v4.0.2...v4.1.0)
691
+
692
+ ### Add
693
+ - Add SEP0029 (memo required) support. ([#516](https://github.com/stellar/js-stellar-sdk/issues/516))
694
+
695
+ Extends `server.submitTransaction` to always run a memo required check before
696
+ sending the transaction. If any of the destinations require a memo and the
697
+ transaction doesn't include one, then an `AccountRequiresMemoError` will be thrown.
698
+
699
+ You can skip this check by passing `{skipMemoRequiredCheck: true}` to `server.submitTransaction`:
700
+
701
+ ```
702
+ server.submitTransaction(tx, {skipMemoRequiredCheck: true})
703
+ ```
704
+
705
+ The check runs for each operation of type:
706
+ - `payment`
707
+ - `pathPaymentStrictReceive`
708
+ - `pathPaymentStrictSend`
709
+ - `mergeAccount`
710
+
711
+ If the transaction includes a memo, then memo required checking is skipped.
712
+
713
+ See [SEP0029](https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0029.md) for more information about memo required check.
714
+
715
+ ## [v4.0.2](https://github.com/stellar/js-stellar-sdk/compare/v4.0.1...v4.0.2)
716
+
717
+ ### Fix
718
+ - Fix URI TypeScript reference. ([#509](https://github.com/stellar/js-stellar-sdk/issues/509))
719
+ - Fix docs build. ([#503](https://github.com/stellar/js-stellar-sdk/issues/503))
720
+ - Fix documentation for method to filter offers by account. ([#507](https://github.com/stellar/js-stellar-sdk/issues/507))
721
+ - Fix types and add missing attribute to `account_response`. ([#504](https://github.com/stellar/js-stellar-sdk/issues/504))
722
+
723
+ ## [v4.0.1](https://github.com/stellar/js-stellar-sdk/compare/v4.0.0...v4.0.1)
724
+
725
+ ### Add
726
+ - Add `.offer` method to `OfferCallBuilder` which allows fetching a single offer by ID. ([#499](https://github.com/stellar/js-stellar-sdk/issues/499))
727
+
728
+ ### Fix
729
+ - Fix broken link to Stellar logo+wordmark. ([#496](https://github.com/stellar/js-stellar-sdk/issues/496))
730
+ - Fix `_link` omition for AccountResponse class. ([#495](https://github.com/stellar/js-stellar-sdk/issues/495))
731
+
732
+ ### Update
733
+ - Update challenge transaction helpers for SEP0010. ([#497](https://github.com/stellar/js-stellar-sdk/issues/497))
734
+
735
+ ## [v4.0.0](https://github.com/stellar/js-stellar-sdk/compare/v3.3.0...v4.0.0)
736
+
737
+ ### Added
738
+ - Add support for top-level offers endpoint with `seller`, `selling`, and `buying` filter. ([#485](https://github.com/stellar/js-stellar-sdk/issues/485))
739
+ Horizon 1.0 includes a new `/offers` end-point, which allows you to list all offers, supporting filtering by `seller`, `selling`, or `buying` asset.
740
+
741
+ You can fetch data from this endpoint by doing `server.offers()` and use any of the following filters:
742
+
743
+ - `seller`: `server.offers().forAccount(accountId)`
744
+ - `buying`: `server.offers().buying(asset)`
745
+ - `selling`: `server.offers().selling(asset)`
746
+
747
+ This introduced a breaking change since it modified the signature for the function `server.offers()`.
748
+
749
+ Before, if you wanted to list all the offers for a given account, you'd do:
750
+
751
+ ```
752
+ server.offers('accounts', accountID)
753
+ ```
754
+
755
+ Starting on this version you'll need to do:
756
+
757
+ ```
758
+ server.offers().forAccount(accountId)
759
+ ```
760
+
761
+ You can do now things that were not possible before, like finding
762
+ all offers for an account filtering by the selling or buying asset
763
+
764
+ ```
765
+ server.offers().forAccount(accountId).selling(assetA).buying(assetB)
766
+ ```
767
+
768
+ - Add support for filtering accounts by `signer` or `asset` ([#474](https://github.com/stellar/js-stellar-sdk/issues/474))
769
+ Horizon 1.0 includes a new `/accounts` end-point, which allows you to list all accounts who have another account as a signer or hold a given asset.
770
+
771
+ You can fetch data from this endpoint by doing `server.accounts()` and use any of the following filters:
772
+
773
+ - `accountID`: `server.accounts().accountId(accountId)`, returns a single account.
774
+ - `forSigner`: `server.accounts().forSigner(accountId)`, returns accounts where `accountId` is a signer.
775
+ - `forAsset`: `server.accounts().forAsset(asset)`, returns accounts which hold the `asset`.
776
+
777
+ - Add TypeScript typings for new fields in `fee_stats`. ([#462](https://github.com/stellar/js-stellar-sdk/issues/462))
778
+
779
+
780
+ ### Changed
781
+ - Changed TypeScript typing for multiple operations "type", it will match the new value on Horizon. ([#477](https://github.com/stellar/js-stellar-sdk/issues/477))
782
+
783
+ ### Fixed
784
+ - Fix fetchTimebounds() ([#487](https://github.com/stellar/js-stellar-sdk/issues/487))
785
+ - Clone the passed URI in CallBuilder constructor, to not mutate the outside ref ([#473](https://github.com/stellar/js-stellar-sdk/issues/473))
786
+ - Use axios CancelToken to ensure timeout ([#482](https://github.com/stellar/js-stellar-sdk/issues/482))
787
+
788
+ ### Breaking
789
+ - Remove `fee_paid` field from transaction response. ([#476](https://github.com/stellar/js-stellar-sdk/issues/476))
790
+ - Remove all `*_accepted_fee` from FeeStatsResponse. ([#463](https://github.com/stellar/js-stellar-sdk/issues/463))
791
+ - Change function signature for `server.offers`. ([#485](https://github.com/stellar/js-stellar-sdk/issues/485))
792
+ The signature for the function `server.offers()` was changed to bring suppport for other filters.
793
+
794
+ Before, if you wanted to list all the offers for a given account, you'd do:
795
+
796
+ ```
797
+ server.offers('accounts', accountID)
798
+ ```
799
+
800
+ Starting on this version you'll need to do:
801
+
802
+ ```
803
+ server.offers().accountId(accountId)
804
+ ```
805
+
806
+
807
+ ## [v3.3.0](https://github.com/stellar/js-stellar-sdk/compare/v3.2.0...v3.3.0)
808
+
809
+ ### Deprecated ⚠️
810
+
811
+ - Horizon 0.25.0 will change the data type for multiple attributes from `Int64` to
812
+ `string`. When the JSON payload includes an `Int64`, there are
813
+ scenarios where large number data can be incorrectly parsed, since JavaScript doesn't support
814
+ `Int64` values. You can read more about it in [#1363](https://github.com/stellar/go/issues/1363).
815
+
816
+ This release extends the data types for the following attributes to be of type `string` or `number`:
817
+
818
+ - `EffectRecord#offer_id`
819
+ - `EffectRecord#new_seq`
820
+ - `OfferRecord#id`
821
+ - `TradeAggregationRecord#timestamp`
822
+ - `TradeAggregationRecord#trade_count`
823
+ - `ManageOfferOperationResponse#offer_id`
824
+ - `PassiveOfferOperationResponse#offer_id`
825
+
826
+ We recommend you update your code to handle both `string` or `number` in
827
+ the fields listed above, so that once Horizon 0.25.0 is released, your application
828
+ will be able to handle the new type without breaking.
829
+
830
+ ## [v3.2.0](https://github.com/stellar/js-stellar-sdk/compare/v3.1.2...v3.2.0)
831
+
832
+ ### Add ➕
833
+
834
+ - Add `fee_charged` an `max_fee` to `TransactionResponse` interface. ([455](https://github.com/stellar/js-stellar-sdk/pull/455))
835
+
836
+ ### Deprecated ⚠️
837
+
838
+ - Horizon 0.25 will stop sending the property `fee_paid` in the transaction response. Use `fee_charged` and `max_fee`, read more about it in [450](https://github.com/stellar/js-stellar-sdk/issues/450).
839
+
840
+ ## [v3.1.2](https://github.com/stellar/js-stellar-sdk/compare/v3.1.1...v3.1.2)
841
+
842
+ ### Change
843
+
844
+ - Upgrade `stellar-base` to `v2.1.2`. ([452](https://github.com/stellar/js-stellar-sdk/pull/452))
845
+
846
+ ## [v3.1.1](https://github.com/stellar/js-stellar-sdk/compare/v3.1.0...v3.1.1)
847
+
848
+ ### Change ⚠️
849
+
850
+ - Change arguments on [server.strictReceivePaths](https://stellar.github.io/js-stellar-sdk/Server.html#strictReceivePaths) since we included `destinationAccount` as an argument, but it is not longer required by Horizon. ([477](https://github.com/stellar/js-stellar-sdk/pull/447))
851
+
852
+ ## [v3.1.0](https://github.com/stellar/js-stellar-sdk/compare/v3.0.0...v3.1.0)
853
+
854
+ ### Add ➕
855
+
856
+ - Add `server.strictReceivePaths` which adds support for `/paths/strict-receive`. ([444](https://github.com/stellar/js-stellar-sdk/pull/444))
857
+ This function takes a list of source assets or a source address, a destination
858
+ address, a destination asset and a destination amount.
859
+
860
+ You can call it passing a list of source assets:
861
+
862
+ ```
863
+ server.strictReceivePaths(sourceAssets,destinationAsset, destinationAmount)
864
+ ```
865
+
866
+ Or a by passing a Stellar source account address:
867
+
868
+ ```
869
+ server.strictReceivePaths(sourceAccount,destinationAsset, destinationAmount)
870
+ ```
871
+
872
+ When you call this function with a Stellar account address, it will look at the account’s trustlines and use them to determine all payment paths that can satisfy the desired amount.
873
+
874
+ - Add `server.strictSendPaths` which adds support for `/paths/strict-send`. ([444](https://github.com/stellar/js-stellar-sdk/pull/444))
875
+ This function takes the asset you want to send, and the amount of that asset,
876
+ along with either a list of destination assets or a destination address.
877
+
878
+ You can call it passing a list of destination assets:
879
+
880
+ ```
881
+ server.strictSendPaths(sourceAsset, sourceAmount, [destinationAsset]).call()
882
+ ```
883
+
884
+ Or a by passing a Stellar account address:
885
+
886
+ ```
887
+ server.strictSendPaths(sourceAsset, sourceAmount, "GDRREYWHQWJDICNH4SAH4TT2JRBYRPTDYIMLK4UWBDT3X3ZVVYT6I4UQ").call()
888
+ ```
889
+
890
+ When you call this function with a Stellar account address, it will look at the account’s trustlines and use them to determine all payment paths that can satisfy the desired amount.
891
+
892
+ ### Deprecated ⚠️
893
+
894
+ - [Server#paths](https://stellar.github.io/js-stellar-sdk/Server.html#paths) is deprecated in favor of [Server#strictReceivePaths](https://stellar.github.io/js-stellar-sdk/Server.html#strictReceivePaths). ([444](https://github.com/stellar/js-stellar-sdk/pull/444))
895
+
896
+ ## [v3.0.1](https://github.com/stellar/js-stellar-sdk/compare/v3.0.0...v3.0.1)
897
+
898
+ ### Add
899
+ - Add join method to call builder. ([#436](https://github.com/stellar/js-stellar-sdk/issues/436))
900
+
901
+ ## [v3.0.0](https://github.com/stellar/js-stellar-sdk/compare/v2.3.0...v3.0.0)
902
+
903
+ ### BREAKING CHANGES ⚠
904
+
905
+ - Drop Support for Node 6 since it has been end-of-lifed and no longer in LTS. We now require Node 10 which is the current LTS until April 1st, 2021. ([#424](https://github.com/stellar/js-stellar-sdk/pull/424)
906
+
907
+ ## [v2.3.0](https://github.com/stellar/js-stellar-sdk/compare/v2.2.3...v2.3.0)
908
+
909
+ ### Add
910
+ - Add feeStats support. ([#409](https://github.com/stellar/js-stellar-sdk/issues/409))
911
+
912
+ ### Fix
913
+ - Fix Util.verifyChallengeTx documentation ([#405](https://github.com/stellar/js-stellar-sdk/issues/405))
914
+ - Fix: listen to stream events with addEventListener ([#408](https://github.com/stellar/js-stellar-sdk/issues/408))
915
+
916
+ ## [v2.2.3](https://github.com/stellar/js-stellar-sdk/compare/v2.2.2...v2.2.3)
917
+
918
+ ### Fix
919
+ - Fix ServerApi's OrderbookRecord type ([#401](https://github.com/stellar/js-stellar-sdk/issues/401))
920
+
921
+ ### Set
922
+ - Set `name` in custom errors ([#403](https://github.com/stellar/js-stellar-sdk/issues/403))
923
+
924
+ ## [v2.2.2](https://github.com/stellar/js-stellar-sdk/compare/v2.2.1...v2.2.2)
925
+
926
+ ### Fix
927
+
928
+ - Fix manage data value in SEP0010 challenge builder. ([#396](https://github.com/stellar/js-stellar-sdk/issues/396))
929
+
930
+ ### Add
931
+
932
+ - Add support for networkPassphrase in SEP0010 challenge builder. ([#397](https://github.com/stellar/js-stellar-sdk/issues/397))
933
+
934
+ ## [v2.2.1](https://github.com/stellar/js-stellar-sdk/compare/v2.2.0...v2.2.1)
935
+
936
+ ### Fix
937
+
938
+ - Fix [#391](https://github.com/stellar/js-stellar-sdk/issues/391): Remove instance check for MessageEvent on stream error. ([#392](https://github.com/stellar/js-stellar-sdk/issues/392))
939
+
940
+
941
+ ## [v2.2.0](https://github.com/stellar/js-stellar-sdk/compare/v2.1.1...v2.2.0)
942
+
943
+ ### Add
944
+ - Add helper `Utils.verifyChallengeTx` to verify SEP0010 "Challenge" Transaction. ([#388](https://github.com/stellar/js-stellar-sdk/issues/388))
945
+ - Add helper `Utils.verifyTxSignedBy` to verify that a transaction has been signed by a given account. ([#388](https://github.com/stellar/js-stellar-sdk/pull/388/commits/2cbf36891e529f63867d46bcf321b5bb76acef50))
946
+
947
+ ### Fix
948
+ - Check for a global EventSource before deciding what to use. This allows you to inject polyfills in other environments like react-native. ([#389](https://github.com/stellar/js-stellar-sdk/issues/389))
949
+
950
+ ## [v2.1.1](https://github.com/stellar/js-stellar-sdk/compare/v2.1.0...v2.1.1)
951
+
952
+ ### Fix
953
+ - Fix CallBuilder onmessage type ([#385](https://github.com/stellar/js-stellar-sdk/issues/385))
954
+
955
+ ## [v2.1.0](https://github.com/stellar/js-stellar-sdk/compare/v2.0.1...v2.1.0)
956
+
957
+ ### Add
958
+ - Add single script to build docs and call it when combined with jsdoc. ([#380](https://github.com/stellar/js-stellar-sdk/issues/380))
959
+ - Add SEP0010 transaction challenge builder. ([#375](https://github.com/stellar/js-stellar-sdk/issues/375))
960
+ - Add `home_domain` to ServerApi.AccountRecord ([#376](https://github.com/stellar/js-stellar-sdk/issues/376))
961
+
962
+ ### Bump
963
+ - Bump stellar-base to 1.0.3. ([#378](https://github.com/stellar/js-stellar-sdk/issues/378))
964
+ - Bump @stellar/tslint-config ([#377](https://github.com/stellar/js-stellar-sdk/issues/377))
965
+
966
+ ### Fix
967
+ - Fix jsdoc's build in after_deploy ([#373](https://github.com/stellar/js-stellar-sdk/issues/373))
968
+ - Create new URI instead of passing serverUrl (Fix [#379](https://github.com/stellar/js-stellar-sdk/issues/379)). ([#382](https://github.com/stellar/js-stellar-sdk/issues/382))
969
+
970
+ ## [v2.0.1](https://github.com/stellar/js-stellar-sdk/compare/v1.0.2...v2.0.1)
971
+
972
+ - **Breaking change** Port stellar-sdk to Typescript. Because we use a slightly
973
+ different build process, there could be some unanticipated bugs. Additionally,
974
+ some type definitions have changed:
975
+ - Types that were once in the `Server` namespace but didn't actually deal with
976
+ the `Server` class have been broken out into a new namespace, `ServerApi`.
977
+ So, for example, `Server.AccountRecord` -> `ServerApi.AccountRecord`.
978
+ - `Server.AccountResponse` is out of the `Server` namespace ->
979
+ `AccountResponse`
980
+ - `Server.*CallBuilder` is out of the `Server` namespace -> `*CallBuilder`
981
+ - `HorizonResponseAccount` is now `Horizon.AccountResponse`
982
+ - Upgrade Webpack to v4.
983
+ - Add support for providing app name and version to request headers.
984
+ - (NPM wouldn't accept the 2.0.0 version, so we're publishing to 2.0.1.)
985
+
986
+ Many thanks to @Ffloriel and @Akuukis for their help with this release!
987
+
988
+ ## [v1.0.5](https://github.com/stellar/js-stellar-sdk/compare/v1.0.4...v1.0.5)
989
+
990
+ - Make CallCollectionFunction return a CollectionPage.
991
+ - Update Horizon.AccountSigner[] types.
992
+
993
+ ## [v1.0.4](https://github.com/stellar/js-stellar-sdk/compare/v1.0.3...v1.0.4)
994
+
995
+ - Automatically tag alpha / beta releases as "next" in NPM.
996
+
997
+ ## [v1.0.3](https://github.com/stellar/js-stellar-sdk/compare/v1.0.2...v1.0.3)
998
+
999
+ - Upgrade axios to 0.19.0 to close a security vulnerability.
1000
+ - Some type fixes.
1001
+
1002
+ ## [v1.0.2](https://github.com/stellar/js-stellar-sdk/compare/v1.0.1...v1.0.2)
1003
+
1004
+ - Upgrade stellar-base to v1.0.2 to fix a bug with the browser bundle.
1005
+
1006
+ ## [v1.0.1](https://github.com/stellar/js-stellar-sdk/compare/v1.0.0...v1.0.1)
1007
+
1008
+ - Upgrade stellar-base to v1.0.1, which makes available again the deprecated
1009
+ operation functions `Operation.manageOffer` and `Operation.createPassiveOffer`
1010
+ (with a warning).
1011
+ - Fix the documentation around timebounds.
1012
+
1013
+ ## [v1.0.0](https://github.com/stellar/js-stellar-sdk/compare/v0.15.4...v1.0.0)
1014
+
1015
+ - Upgrade stellar-base to
1016
+ [v1.0.0](https://github.com/stellar/js-stellar-base/releases/tag/v1.0.0),
1017
+ which introduces two breaking changes.
1018
+ - Switch stellar-sdk's versioning to true semver! 🎉
1019
+
1020
+ ## [v0.15.4](https://github.com/stellar/js-stellar-sdk/compare/v0.15.3...v0.15.4)
1021
+
1022
+ - Add types for LedgerCallBuilder.ledger.
1023
+ - Add types for Server.operationFeeStats.
1024
+ - Add types for the HorizonAxiosClient export.
1025
+ - Move @types/\* from devDependencies to dependencies.
1026
+ - Pass and use a stream response type to CallBuilders if it's different from the
1027
+ normal call response.
1028
+ - Upgrade stellar-base to a version that includes types, and remove
1029
+ @types/stellar-base as a result.
1030
+
1031
+ ## [v0.15.3](https://github.com/stellar/js-stellar-sdk/compare/v0.15.2...v0.15.3)
1032
+
1033
+ - In .travis.yml, try to switch from the encrypted API key to an environment
1034
+ var.
1035
+
1036
+ ## [v0.15.2](https://github.com/stellar/js-stellar-sdk/compare/v0.15.1...v0.15.2)
1037
+
1038
+ - Fix Server.transactions and Server.payments definitions to properly return
1039
+ collections
1040
+ - Renew the npm publish key
1041
+
1042
+ ## [v0.15.1](https://github.com/stellar/js-stellar-sdk/compare/v0.15.0...v0.15.1)
1043
+
1044
+ - Add Typescript type definitions (imported from DefinitelyTyped).
1045
+ - Make these changes to those definitions:
1046
+ - Add definitions for Server.fetchBaseFee and Server.fetchTimebounds
1047
+ - CallBuilder: No long always returns CollectionPaged results. Interfaces that
1048
+ extend CallBuilder should specify whether their response is a collection or
1049
+ not
1050
+ - CallBuilder: Add inflation_destination and last_modified_ledger property
1051
+ - OfferRecord: Fix the returned properties
1052
+ - TradeRecord: Fix the returned properties
1053
+ - TradesCallBuilder: Add forAccount method
1054
+ - TransactionCallBuilder: Add includeFailed method
1055
+ - Horizon.BalanceLineNative/Asset: Add buying_liabilities /
1056
+ selling_liabilities properties
1057
+ - Fix documentation links.
1058
+
1059
+ ## [v0.15.0](https://github.com/stellar/js-stellar-sdk/compare/v0.14.0...v0.15.0)
1060
+
1061
+ - **Breaking change**: `stellar-sdk` no longer ships with an `EventSource`
1062
+ polyfill. If you plan to support IE11 / Edge, please use
1063
+ [`event-source-polyfill`](https://www.npmjs.com/package/event-source-polyfill)
1064
+ to set `window.EventSource`.
1065
+ - Upgrade `stellar-base` to a version that doesn't use the `crypto` library,
1066
+ fixing a bug with Angular 6
1067
+ - Add `Server.prototype.fetchTimebounds`, a helper function that helps you set
1068
+ the `timebounds` property when initting `TransactionBuilder`. It bases the
1069
+ timebounds on server time rather than local time.
1070
+
1071
+ ## [v0.14.0](https://github.com/stellar/js-stellar-sdk/compare/v0.13.0...v0.14.0)
1072
+
1073
+ - Updated some out-of-date dependencies
1074
+ - Update documentation to explicitly set fees
1075
+ - Add `Server.prototype.fetchBaseFee`, which devs can use to fetch the current
1076
+ base fee; we plan to add more functions to help suggest fees in future
1077
+ releases
1078
+ - Add `includeFailed` to `OperationCallBuilder` for including failed
1079
+ transactions in calls
1080
+ - Add `operationFeeStats` to `Server` for the new fee stats endpoint
1081
+ - After submitting a transaction with a `manageOffer` operation, return a new
1082
+ property `offerResults`, which explains what happened to the offer. See
1083
+ [`Server.prototype.submitTransaction`](https://stellar.github.io/js-stellar-sdk/Server.html#submitTransaction)
1084
+ for documentation.
1085
+
1086
+ ## 0.13.0
1087
+
1088
+ - Update `stellar-base` to `0.11.0`
1089
+ - Added ESLint and Prettier to enforce code style
1090
+ - Upgraded dependencies, including Babel to 6
1091
+ - Bump local node version to 6.14.0
1092
+
1093
+ ## 0.12.0
1094
+
1095
+ - Update `stellar-base` to `0.10.0`:
1096
+ - **Breaking change** Added
1097
+ [`TransactionBuilder.setTimeout`](https://stellar.github.io/js-stellar-base/TransactionBuilder.html#setTimeout)
1098
+ method that sets `timebounds.max_time` on a transaction. Because of the
1099
+ distributed nature of the Stellar network it is possible that the status of
1100
+ your transaction will be determined after a long time if the network is
1101
+ highly congested. If you want to be sure to receive the status of the
1102
+ transaction within a given period you should set the TimeBounds with
1103
+ `maxTime` on the transaction (this is what `setTimeout` does internally; if
1104
+ there's `minTime` set but no `maxTime` it will be added). Call to
1105
+ `TransactionBuilder.setTimeout` is required if Transaction does not have
1106
+ `max_time` set. If you don't want to set timeout, use `TimeoutInfinite`. In
1107
+ general you should set `TimeoutInfinite` only in smart contracts. Please
1108
+ check
1109
+ [`TransactionBuilder.setTimeout`](https://stellar.github.io/js-stellar-base/TransactionBuilder.html#setTimeout)
1110
+ docs for more information.
1111
+ - Fixed decoding empty `homeDomain`.
1112
+ - Add `offset` parameter to TradeAggregationCallBuilder to reflect new changes
1113
+ to the endpoint in horizon-0.15.0
1114
+
1115
+ ## 0.11.0
1116
+
1117
+ - Update `js-xdr` (by updating `stellar-base`) to support unmarshaling non-utf8
1118
+ strings.
1119
+ - String fields returned by `Operation.fromXDRObject()` are of type `Buffer` now
1120
+ (except `SetOptions.home_domain` and `ManageData.name` - both required to be
1121
+ ASCII by stellar-core).
1122
+
1123
+ ## 0.10.3
1124
+
1125
+ - Update `stellar-base` and xdr files.
1126
+
1127
+ ## 0.10.2
1128
+
1129
+ - Update `stellar-base` (and `js-xdr`).
1130
+
1131
+ ## 0.10.1
1132
+
1133
+ - Update `stellar-base` to `0.8.1`.
1134
+
1135
+ ## 0.10.0
1136
+
1137
+ - Update `stellar-base` to `0.8.0` with `bump_sequence` support.
1138
+
1139
+ ## 0.9.2
1140
+
1141
+ - Removed `.babelrc` file from the NPM package.
1142
+
1143
+ ## 0.9.1
1144
+
1145
+ ### Breaking changes
1146
+
1147
+ - `stellar-sdk` is now using native `Promise` instead of `bluebird`. The `catch`
1148
+ function is different. Instead of:
1149
+
1150
+ ```js
1151
+ .catch(StellarSdk.NotFoundError, function (err) { /* ... */ })
1152
+ ```
1153
+
1154
+ please use the following snippet:
1155
+
1156
+ ```js
1157
+ .catch(function (err) {
1158
+ if (err instanceof StellarSdk.NotFoundError) { /* ... */ }
1159
+ })
1160
+ ```
1161
+
1162
+ - We no longer support IE 11, Firefox < 42, Chrome < 49.
1163
+
1164
+ ### Changes
1165
+
1166
+ - Fixed `_ is undefined` bug.
1167
+ - Browser build is around 130 KB smaller!
1168
+
1169
+ ## 0.8.2
1170
+
1171
+ - Added `timeout` option to `StellarTomlResolver` and `FederationServer` calls
1172
+ (https://github.com/stellar/js-stellar-sdk/issues/158).
1173
+ - Fixed adding random value to URLs multiple times
1174
+ (https://github.com/stellar/js-stellar-sdk/issues/169).
1175
+ - Fixed jsdoc for classes that extend `CallBuilder`.
1176
+ - Updated dependencies.
1177
+ - Added `yarn.lock` file to repository.
1178
+
1179
+ ## 0.8.1
1180
+
1181
+ - Add an allowed trade aggregation resolution of one minute
1182
+ - Various bug fixes
1183
+ - Improved documentation
1184
+
1185
+ ## 0.8.0
1186
+
1187
+ - Modify `/trades` endpoint to reflect changes in horizon.
1188
+ - Add `/trade_aggregations` support.
1189
+ - Add `/assets` support.
1190
+
1191
+ ## 0.7.3
1192
+
1193
+ - Upgrade `stellar-base`.
1194
+
1195
+ ## 0.7.2
1196
+
1197
+ - Allow hex string in setOptions signers.
1198
+
1199
+ ## 0.7.1
1200
+
1201
+ - Upgrade `stellar-base`.
1202
+
1203
+ ## 0.7.0
1204
+
1205
+ - Support for new signer types: `sha256Hash`, `preAuthTx`.
1206
+ - `StrKey` helper class with `strkey` encoding related methods.
1207
+ - Removed deprecated methods: `Keypair.isValidPublicKey` (use `StrKey`),
1208
+ `Keypair.isValidSecretKey` (use `StrKey`), `Keypair.fromSeed`, `Keypair.seed`,
1209
+ `Keypair.rawSeed`.
1210
+ - **Breaking changes**:
1211
+ - `Network` must be explicitly selected. Previously testnet was a default
1212
+ network.
1213
+ - `Operation.setOptions()` method `signer` param changed.
1214
+ - `Keypair.fromAccountId()` renamed to `Keypair.fromPublicKey()`.
1215
+ - `Keypair.accountId()` renamed to `Keypair.publicKey()`.
1216
+ - Dropping support for `End-of-Life` node versions.
1217
+
1218
+ ## 0.6.2
1219
+
1220
+ - Updated `stellar.toml` location
1221
+
1222
+ ## 0.6.1
1223
+
1224
+ - `forUpdate` methods of call builders now accept strings and numbers.
1225
+ - Create a copy of attribute in a response if there is a link with the same name
1226
+ (ex. `transaction.ledger`, `transaction._links.ledger`).
1227
+
1228
+ ## 0.6.0
1229
+
1230
+ - **Breaking change** `CallBuilder.stream` now reconnects when no data was
1231
+ received for a long time. This is to prevent permanent disconnects (more in:
1232
+ [#76](https://github.com/stellar/js-stellar-sdk/pull/76)). Also, this method
1233
+ now returns `close` callback instead of `EventSource` object.
1234
+ - **Breaking change** `Server.loadAccount` now returns the `AccountResponse`
1235
+ object.
1236
+ - **Breaking change** Upgraded `stellar-base` to `0.6.0`. `ed25519` package is
1237
+ now an optional dependency. Check `StellarSdk.FastSigning` variable to check
1238
+ if `ed25519` package is available. More in README file.
1239
+ - New `StellarTomlResolver` class that allows getting `stellar.toml` file for a
1240
+ domain.
1241
+ - New `Config` class to set global config values.
1242
+
1243
+ ## 0.5.1
1244
+
1245
+ - Fixed XDR decoding issue when using firefox
1246
+
1247
+ ## 0.5.0
1248
+
1249
+ - **Breaking change** `Server` and `FederationServer` constructors no longer
1250
+ accept object in `serverUrl` parameter.
1251
+ - **Breaking change** Removed `AccountCallBuilder.address` method. Use
1252
+ `AccountCallBuilder.accountId` instead.
1253
+ - **Breaking change** It's no longer possible to connect to insecure server in
1254
+ `Server` or `FederationServer` unless `allowHttp` flag in `opts` is set.
1255
+ - Updated dependencies.
1256
+
1257
+ ## 0.4.3
1258
+
1259
+ - Updated dependency (`stellar-base`).
1260
+
1261
+ ## 0.4.2
1262
+
1263
+ - Updated dependencies.
1264
+ - Added tests.
1265
+ - Added `CHANGELOG.md` file.
1266
+
1267
+ ## 0.4.1
1268
+
1269
+ - `stellar-base` bump. (c90c68f)
1270
+
1271
+ ## 0.4.0
1272
+
1273
+ - **Breaking change** Bumped `stellar-base` to
1274
+ [0.5.0](https://github.com/stellar/js-stellar-base/blob/master/CHANGELOG.md#050).
1275
+ (b810aef)