@metamask-previews/keyring-api 8.1.0-38c4bd5

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 (105) hide show
  1. package/CHANGELOG.md +428 -0
  2. package/README.md +401 -0
  3. package/dist/JsonRpcRequest.d.ts +16 -0
  4. package/dist/JsonRpcRequest.js +13 -0
  5. package/dist/JsonRpcRequest.js.map +1 -0
  6. package/dist/KeyringClient.d.ts +28 -0
  7. package/dist/KeyringClient.js +124 -0
  8. package/dist/KeyringClient.js.map +1 -0
  9. package/dist/KeyringSnapRpcClient.d.ts +39 -0
  10. package/dist/KeyringSnapRpcClient.js +68 -0
  11. package/dist/KeyringSnapRpcClient.js.map +1 -0
  12. package/dist/api/account.d.ts +62 -0
  13. package/dist/api/account.js +56 -0
  14. package/dist/api/account.js.map +1 -0
  15. package/dist/api/balance.d.ts +9 -0
  16. package/dist/api/balance.js +11 -0
  17. package/dist/api/balance.js.map +1 -0
  18. package/dist/api/caip.d.ts +37 -0
  19. package/dist/api/caip.js +48 -0
  20. package/dist/api/caip.js.map +1 -0
  21. package/dist/api/export.d.ts +8 -0
  22. package/dist/api/export.js +7 -0
  23. package/dist/api/export.js.map +1 -0
  24. package/dist/api/index.d.ts +7 -0
  25. package/dist/api/index.js +24 -0
  26. package/dist/api/index.js.map +1 -0
  27. package/dist/api/keyring.d.ts +159 -0
  28. package/dist/api/keyring.js +3 -0
  29. package/dist/api/keyring.js.map +1 -0
  30. package/dist/api/request.d.ts +39 -0
  31. package/dist/api/request.js +29 -0
  32. package/dist/api/request.js.map +1 -0
  33. package/dist/api/response.d.ts +24 -0
  34. package/dist/api/response.js +44 -0
  35. package/dist/api/response.js.map +1 -0
  36. package/dist/btc/index.d.ts +1 -0
  37. package/dist/btc/index.js +18 -0
  38. package/dist/btc/index.js.map +1 -0
  39. package/dist/btc/types.d.ts +33 -0
  40. package/dist/btc/types.js +40 -0
  41. package/dist/btc/types.js.map +1 -0
  42. package/dist/contexts.d.ts +7 -0
  43. package/dist/contexts.js +3 -0
  44. package/dist/contexts.js.map +1 -0
  45. package/dist/eth/erc4337/index.d.ts +1 -0
  46. package/dist/eth/erc4337/index.js +18 -0
  47. package/dist/eth/erc4337/index.js.map +1 -0
  48. package/dist/eth/erc4337/types.d.ts +96 -0
  49. package/dist/eth/erc4337/types.js +61 -0
  50. package/dist/eth/erc4337/types.js.map +1 -0
  51. package/dist/eth/index.d.ts +3 -0
  52. package/dist/eth/index.js +20 -0
  53. package/dist/eth/index.js.map +1 -0
  54. package/dist/eth/types.d.ts +80 -0
  55. package/dist/eth/types.js +73 -0
  56. package/dist/eth/types.js.map +1 -0
  57. package/dist/eth/utils.d.ts +8 -0
  58. package/dist/eth/utils.js +15 -0
  59. package/dist/eth/utils.js.map +1 -0
  60. package/dist/events.d.ts +10 -0
  61. package/dist/events.js +17 -0
  62. package/dist/events.js.map +1 -0
  63. package/dist/index.d.ts +11 -0
  64. package/dist/index.js +28 -0
  65. package/dist/index.js.map +1 -0
  66. package/dist/internal/api.d.ts +415 -0
  67. package/dist/internal/api.js +139 -0
  68. package/dist/internal/api.js.map +1 -0
  69. package/dist/internal/eth/EthKeyring.d.ts +33 -0
  70. package/dist/internal/eth/EthKeyring.js +3 -0
  71. package/dist/internal/eth/EthKeyring.js.map +1 -0
  72. package/dist/internal/eth/index.d.ts +1 -0
  73. package/dist/internal/eth/index.js +18 -0
  74. package/dist/internal/eth/index.js.map +1 -0
  75. package/dist/internal/events.d.ts +159 -0
  76. package/dist/internal/events.js +72 -0
  77. package/dist/internal/events.js.map +1 -0
  78. package/dist/internal/index.d.ts +5 -0
  79. package/dist/internal/index.js +22 -0
  80. package/dist/internal/index.js.map +1 -0
  81. package/dist/internal/rpc.d.ts +25 -0
  82. package/dist/internal/rpc.js +33 -0
  83. package/dist/internal/rpc.js.map +1 -0
  84. package/dist/internal/types.d.ts +330 -0
  85. package/dist/internal/types.js +49 -0
  86. package/dist/internal/types.js.map +1 -0
  87. package/dist/rpc-handler.d.ts +29 -0
  88. package/dist/rpc-handler.js +136 -0
  89. package/dist/rpc-handler.js.map +1 -0
  90. package/dist/snap-utils.d.ts +11 -0
  91. package/dist/snap-utils.js +21 -0
  92. package/dist/snap-utils.js.map +1 -0
  93. package/dist/superstruct.d.ts +83 -0
  94. package/dist/superstruct.js +81 -0
  95. package/dist/superstruct.js.map +1 -0
  96. package/dist/utils/index.d.ts +2 -0
  97. package/dist/utils/index.js +19 -0
  98. package/dist/utils/index.js.map +1 -0
  99. package/dist/utils/types.d.ts +17 -0
  100. package/dist/utils/types.js +29 -0
  101. package/dist/utils/types.js.map +1 -0
  102. package/dist/utils/typing.d.ts +32 -0
  103. package/dist/utils/typing.js +21 -0
  104. package/dist/utils/typing.js.map +1 -0
  105. package/package.json +84 -0
package/CHANGELOG.md ADDED
@@ -0,0 +1,428 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project will be documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
+
8
+ ## [Unreleased]
9
+
10
+ ## [8.1.0]
11
+
12
+ ### Added
13
+
14
+ - Add optional `nameLastUpdatedAt` metadata field ([#366](https://github.com/MetaMask/keyring-api/pull/366))
15
+
16
+ ### Changed
17
+
18
+ - Bump @metamask/snaps-sdk from 6.1.0 to 6.2.0 ([#367](https://github.com/MetaMask/keyring-api/pull/367))
19
+ - Bump @metamask/providers from 17.1.1 to 17.1.2 ([#362](https://github.com/MetaMask/keyring-api/pull/362))
20
+
21
+ ## [8.0.2]
22
+
23
+ ### Changed
24
+
25
+ - Bump `@metamask/snaps-sdk` from `^6.0.0` to `^6.1.0` ([#358](https://github.com/MetaMask/keyring-api/pull/358))
26
+
27
+ ## [8.0.1]
28
+
29
+ ### Changed
30
+
31
+ - Migrate to @metamask/superstruct and update required dependencies ([#355](https://github.com/MetaMask/keyring-api/pull/355)).
32
+ - Bump @metamask/providers from 17.1.0 to 17.1.1 ([#354](https://github.com/MetaMask/keyring-api/pull/354)).
33
+ - Bump @metamask/key-tree from 9.1.1 to 9.1.2 ([#351](https://github.com/MetaMask/keyring-api/pull/351)).
34
+ - Bump @metamask/rpc-errors from 6.3.0 to 6.3.1 ([#350](https://github.com/MetaMask/keyring-api/pull/350)).
35
+ - Bump @metamask/providers from 17.0.0 to 17.1.0 ([#348](https://github.com/MetaMask/keyring-api/pull/348)).
36
+ - Bump @metamask/snaps-sdk from 4.4.2 to 6.0.0 ([#347](https://github.com/MetaMask/keyring-api/pull/347)).
37
+ - Bump braces from 3.0.2 to 3.0.3 ([#345](https://github.com/MetaMask/keyring-api/pull/345)).
38
+
39
+ ## [8.0.0]
40
+
41
+ ### Changed
42
+
43
+ - **BREAKING:** Revert "feat: allow multiple address per account (#315)" ([#342](https://github.com/MetaMask/keyring-api/pull/342)).
44
+
45
+ ## [7.0.0]
46
+
47
+ ### Added
48
+
49
+ - Add `getAccountBalances` to `KeyringClient` ([#340](https://github.com/MetaMask/keyring-api/pull/340)).
50
+ - **BREAKING:** Allow multiple address per account ([#315](https://github.com/MetaMask/keyring-api/pull/315)).
51
+
52
+ ### Changed
53
+
54
+ - **BREAKING:** Keep all ETH methods in the same `enum` ([#313](https://github.com/MetaMask/keyring-api/pull/313)).
55
+ - Bump @metamask/snaps-sdk from 4.4.1 to 4.4.2 ([#339](https://github.com/MetaMask/keyring-api/pull/339)).
56
+ - Bump @metamask/rpc-errors from 6.2.1 to 6.3.0 ([#337](https://github.com/MetaMask/keyring-api/pull/337)).
57
+ - Bump @metamask/json-rpc-middleware-stream from 7.0.1 to 7.0.2 ([#333](https://github.com/MetaMask/keyring-api/pull/333)).
58
+ - Bump @metamask/snaps-sdk from 4.4.0 to 4.4.1 ([#334](https://github.com/MetaMask/keyring-api/pull/334)).
59
+
60
+ ### Fixed
61
+
62
+ - Allow stale action to be run manually and fix permissions ([#336](https://github.com/MetaMask/keyring-api/pull/336)).
63
+
64
+ ## [6.4.0]
65
+
66
+ ### Changed
67
+
68
+ - **BREAKING:** Keep all ETH methods in the same `enum` ([#313](https://github.com/MetaMask/keyring-api/pull/313)).
69
+ - Add support for `@metamask/providers` v17 ([#329](https://github.com/MetaMask/keyring-api/pull/329)).
70
+
71
+ ## [6.3.1]
72
+
73
+ ### Changed
74
+
75
+ - **BREAKING:** Keep all ETH methods in the same `enum` ([#313](https://github.com/MetaMask/keyring-api/pull/313)).
76
+
77
+ ### Fixed
78
+
79
+ - Export `Caip*` types used in the API ([#325](https://github.com/MetaMask/keyring-api/pull/325)).
80
+
81
+ ## [6.3.0]
82
+
83
+ ### Added
84
+
85
+ - Add `getAccountBalances` method to `Keyring` interface ([#320](https://github.com/MetaMask/keyring-api/pull/320)).
86
+ - Add CAIP-19 types to `utils` ([#321](https://github.com/MetaMask/keyring-api/pull/321)).
87
+
88
+ ### Changed
89
+
90
+ - **BREAKING:** Keep all ETH methods in the same `enum` ([#313](https://github.com/MetaMask/keyring-api/pull/313)).
91
+ - Bump @metamask/snaps-sdk from 4.2.0 to 4.3.0 ([#323](https://github.com/MetaMask/keyring-api/pull/323)).
92
+ - Split `api.ts` into different files ([#319](https://github.com/MetaMask/keyring-api/pull/319)).
93
+ - Make the `KeyringAccount` type less rigid ([#311](https://github.com/MetaMask/keyring-api/pull/311)).
94
+
95
+ ### Fixed
96
+
97
+ - Ensure that errors are JSON-serializable ([#162](https://github.com/MetaMask/keyring-api/pull/162)).
98
+ - Don't use internal types in the public API ([#312](https://github.com/MetaMask/keyring-api/pull/312)).
99
+
100
+ ## [6.2.1]
101
+
102
+ ### Changed
103
+
104
+ - Bump @metamask/key-tree from 9.1.0 to 9.1.1 ([#310](https://github.com/MetaMask/keyring-api/pull/310)).
105
+
106
+ ### Fixed
107
+
108
+ - Use internal `object` function instead of the upstream one ([#316](https://github.com/MetaMask/keyring-api/pull/316)).
109
+
110
+ ## [6.2.0]
111
+
112
+ ### Added
113
+
114
+ - Add `accountNameSuggestion` field to the `AccountCreatedEvent` ([#291](https://github.com/MetaMask/keyring-api/pull/291))
115
+ - Add `displayConfirmation` field to the `AccountCreatedEvent` ([#307](https://github.com/MetaMask/keyring-api/pull/307))
116
+
117
+ ## [6.1.1]
118
+
119
+ ### Changed
120
+
121
+ - Fix `isEvmAccountType` accountType type to `string` or `InternalAccountType` ([#304](https://github.com/MetaMask/keyring-api/pull/304))
122
+ - Bump @metamask/snaps-sdk from ^4.0.0 to ^4.2.0 ([#305](https://github.com/MetaMask/keyring-api/pull/305))
123
+
124
+ ## [6.1.0]
125
+
126
+ ### Added
127
+
128
+ - Add `isEvmAccountType` helper ([#297](https://github.com/MetaMask/keyring-api/pull/297))
129
+ - Add `bip121:p2wpkh` account support ([#294](https://github.com/MetaMask/keyring-api/pull/294))
130
+
131
+ ### Changed
132
+
133
+ - Remove incorrect `SignTransaction` from `EthErc4337Account` ([#300](https://github.com/MetaMask/keyring-api/pull/300))
134
+ - Bump @metamask/providers from 16.0.0 to 16.1.0 ([#298](https://github.com/MetaMask/keyring-api/pull/298))
135
+ - Bump @metamask/snaps-sdk from 4.0.0 to 4.0.1 ([#292](https://github.com/MetaMask/keyring-api/pull/292))
136
+ - Split account types (EOA + Erc4337) ([#293](https://github.com/MetaMask/keyring-api/pull/293))
137
+
138
+ ## [6.0.0]
139
+
140
+ ### Changed
141
+
142
+ - **BREAKING**: Add `importTime` property to `InternalAccount` metadata ([#289](https://github.com/MetaMask/keyring-api/pull/289))
143
+ - Bump tar from 6.1.15 to 6.2.1 ([#286](https://github.com/MetaMask/keyring-api/pull/286))
144
+ - Bump @metamask/snaps-sdk from 3.2.0 to 4.0.0 ([#287](https://github.com/MetaMask/keyring-api/pull/287))
145
+ - Add documentation for `eth_decodeUserOperationCallData` ([#254](https://github.com/MetaMask/keyring-api/pull/254))
146
+ - Bump @metamask/snaps-sdk from 3.1.1 to 3.2.0 ([#284](https://github.com/MetaMask/keyring-api/pull/284))
147
+
148
+ ## [5.1.0]
149
+
150
+ ### Changed
151
+
152
+ - Use @metamask/providers as a peer dependency ([#282](https://github.com/MetaMask/keyring-api/pull/282))
153
+ - Bump @metamask/utils from 8.3.0 to 8.4.0 ([#280](https://github.com/MetaMask/keyring-api/pull/280))
154
+ - Add stale CI workflow to close issues and PRs ([#279](https://github.com/MetaMask/keyring-api/pull/279))
155
+
156
+ ## [5.0.0]
157
+
158
+ ### Changed
159
+
160
+ - **BREAKING**: Add new `KeyringExecutionContext` to user operation methods ([#275](https://github.com/MetaMask/keyring-api/pull/275))
161
+ - Fix bundler type (defined as `string` now) ([#277](https://github.com/MetaMask/keyring-api/pull/277))
162
+ - Bump @metamask/providers from 15.0.0 to 16.0.0 ([#276](https://github.com/MetaMask/keyring-api/pull/276))
163
+ - Bump @metamask/safe-event-emitter from 3.1.0 to 3.1.1 ([#274](https://github.com/MetaMask/keyring-api/pull/274))
164
+
165
+ ## [4.0.2]
166
+
167
+ ### Changed
168
+
169
+ - Bump @metamask/snaps-sdk to ^3.1.1 ([#271](https://github.com/MetaMask/keyring-api/pull/271))
170
+ - Bump @metamask/safe-event-emitter from 3.0.0 to 3.1.0 ([#270](https://github.com/MetaMask/keyring-api/pull/270))
171
+ - Fix bundler URL validation ([#262](https://github.com/MetaMask/keyring-api/pull/262))
172
+
173
+ ## [4.0.1]
174
+
175
+ ### Changed
176
+
177
+ - Bump @metamask/providers to 15.0.0, @metamask/snaps-sdk to ^3.1.0 and @@metamask/utils to ^8.3.0([#266](https://github.com/MetaMask/keyring-api/pull/266))
178
+ - Bump @metamask/json-rpc-engine from 7.3.2 to 7.3.3 ([#264](https://github.com/MetaMask/keyring-api/pull/264))
179
+ - Bump @metamask/snaps-sdk from 3.0.0 to 3.0.1 ([#261](https://github.com/MetaMask/keyring-api/pull/261))
180
+ - Bump @metamask/snaps-sdk from 1.4.0 to 3.0.0 ([#259](https://github.com/MetaMask/keyring-api/pull/259))
181
+ - Bump @metamask/rpc-errors from 6.1.0 to 6.2.1 ([#258](https://github.com/MetaMask/keyring-api/pull/258))
182
+
183
+ ## [4.0.0]
184
+
185
+ ### Changed
186
+
187
+ - **BREAKING** Update node min version to 18.x ([#247](https://github.com/MetaMask/keyring-api/pull/247))
188
+ - Update `eth_patchUserOperation` to return optional gas limit values ([#250](https://github.com/MetaMask/keyring-api/pull/250))
189
+ - Bump `ip` from 2.0.0 to 2.0.1 ([#253](https://github.com/MetaMask/keyring-api/pull/253))
190
+ - Bump `@metamask/json-rpc-engine` from 7.3.1 to 7.3.2 ([#246](https://github.com/MetaMask/keyring-api/pull/246))
191
+ - Bump `@metamask/snaps-sdk` from 1.3.2 to 1.4.0 ([#243](https://github.com/MetaMask/keyring-api/pull/243))
192
+
193
+ ## [3.0.0]
194
+
195
+ ### Changed
196
+
197
+ - Bump `@metamask/utils` from 8.2.1 to 8.3.0 ([#238](https://github.com/MetaMask/keyring-api/pull/238))
198
+ - Bump Snap dependencies ([#236](https://github.com/MetaMask/keyring-api/pull/236))
199
+ - Bump `@metamask/snaps-controllers` to ^4.0.0
200
+ - Bump `@metamask/snaps-sdk` to ^1.3.2
201
+ - Bump `@metamask/snaps-utils` to ^5.1.2
202
+ - Bump `@metamask/approval-controller` from 5.0.0 to 5.1.1 ([#225](https://github.com/MetaMask/keyring-api/pull/225))
203
+ - Bump `@metamask/base-controller` from 4.0.0 to 4.0.1 ([#226](https://github.com/MetaMask/keyring-api/pull/226))
204
+ - Bump `@metamask/json-rpc-engine` from 7.3.0 to 7.3.1 ([#227](https://github.com/MetaMask/keyring-api/pull/227))
205
+ - Bump `@metamask/auto-changelog` from 3.4.3 to 3.4.4 ([#223](https://github.com/MetaMask/keyring-api/pull/223))
206
+ - Bump `@metamask/snaps-sdk` from 1.3.0 to 1.3.1 ([#222](https://github.com/MetaMask/keyring-api/pull/222))
207
+
208
+ ### Removed
209
+
210
+ - **BREAKING**: remove `KeyringSnapControllerClient` class to fix dependency problems ([#241](https://github.com/MetaMask/keyring-api/pull/241))
211
+
212
+ ## [2.0.0]
213
+
214
+ ### Added
215
+
216
+ - **BREAKING**: Add support for ERC-4337 transactions ([#213](https://github.com/MetaMask/keyring-api/pull/213))
217
+ - Enum `EthMethods` has been extended with `eth_prepareUserOperation`, `eth_patchUserOperation`, `eth_signUserOperation`
218
+ - Enum `EthAccountType` has been extended with `eip155:erc4337`
219
+
220
+ ### Changed
221
+
222
+ - **BREAKING**: Update `@metamask/providers` from `^13.0.0` to `^14.0.1` ([#209](https://github.com/MetaMask/keyring-api/pull/209))
223
+ - Consolidation on `readable-stream@^3.6.2`. Users should upgrade to `extension-port-stream@^3.0.0` and `json-rpc-middleware-stream@^5.0.0`.
224
+ - Replace deprecated `@metamask/snaps-ui` with `@metamask/snaps-sdk` ([#204](https://github.com/MetaMask/keyring-api/pull/204))
225
+ - Replace `@metamask/snaps-rpc-methods` with `@metamask/snaps-sdk`
226
+ - Update `@metamask/snaps-controllers` and `@metamask/snaps-utils` to versions that don't rely on `@metamask/snaps-ui`
227
+ - Documentation updates ([#185](https://github.com/MetaMask/keyring-api/pull/185)) ([#201](https://github.com/MetaMask/keyring-api/pull/201))
228
+
229
+ ### Removed
230
+
231
+ - **BREAKING** `EthAccountType.Eip4337` has been removed. `eip155:eip4337` should be replaced with `erc:4337`
232
+
233
+ ### Fixed
234
+
235
+ - Exclude `*.test-d.ts` files from builds ([#184](https://github.com/MetaMask/keyring-api/pull/184))
236
+ - Remove `@metamask/snaps-ui` from dependency tree ([#204](https://github.com/MetaMask/keyring-api/pull/204))
237
+
238
+ ## [1.1.0]
239
+
240
+ ### Changed
241
+
242
+ - `UuidStruct` is now a named type ([#159](https://github.com/MetaMask/keyring-api/pull/159))
243
+ - Migrate from `@metamask/rpc-methods` to `@metamask/snaps-rpc-methods` ([#175](https://github.com/MetaMask/keyring-api/pull/175))
244
+
245
+ ### Fixed
246
+
247
+ - Allow the request ID to be a string, number or null ([#156](https://github.com/MetaMask/keyring-api/pull/156))
248
+ - Documentation fixes ([#160](https://github.com/MetaMask/keyring-api/pull/160)) ([#174](https://github.com/MetaMask/keyring-api/pull/174)) ([#173](https://github.com/MetaMask/keyring-api/pull/173)) ([#172](https://github.com/MetaMask/keyring-api/pull/172))
249
+ - Use `UuidStruct` for IDs in the internal API ([#158](https://github.com/MetaMask/keyring-api/pull/158))
250
+ - Bump `@metamask/json-rpc-engine` from `^7.1.1` to `^7.2.0` ([#164](https://github.com/MetaMask/keyring-api/pull/164))
251
+
252
+ ## [1.0.0]
253
+
254
+ ### Added
255
+
256
+ - Add migration steps to 1.0.0 ([#149](https://github.com/MetaMask/keyring-api/pull/149)).
257
+ - Add Account Snaps security guidelines ([#143](https://github.com/MetaMask/keyring-api/pull/143)).
258
+
259
+ ### Changed
260
+
261
+ - Bump @metamask/rpc-errors from 6.0.0 to 6.1.0 ([#151](https://github.com/MetaMask/keyring-api/pull/151)).
262
+ - Bump postcss from 8.4.24 to 8.4.31 ([#150](https://github.com/MetaMask/keyring-api/pull/150)).
263
+
264
+ ## [1.0.0-rc.1]
265
+
266
+ ### Added
267
+
268
+ - Document how to migrate from API 0.1.x to 0.2.x ([#124](https://github.com/MetaMask/keyring-api/pull/124)).
269
+
270
+ ### Changed
271
+
272
+ - **BREAKING:** Use the `onKeyringRequest` snap export ([#145](https://github.com/MetaMask/keyring-api/pull/145)).
273
+ - **BREAKING:** Change the events' prefix to `notify:` ([#139](https://github.com/MetaMask/keyring-api/pull/139)).
274
+
275
+ ## [0.2.7]
276
+
277
+ ### Added
278
+
279
+ - Export events types ([#125](https://github.com/MetaMask/keyring-api/pull/125))
280
+
281
+ ## [0.2.6]
282
+
283
+ ### Changed
284
+
285
+ - Remove unused lavamoat allowed scripts ([#122](https://github.com/MetaMask/keyring-api/pull/122)).
286
+ - Update events in sequence diagram ([#121](https://github.com/MetaMask/keyring-api/pull/121)).
287
+ - Update Snap and ESLint dependencies ([#117](https://github.com/MetaMask/keyring-api/pull/117)).
288
+ - Bump @metamask/rpc-methods from 0.38.1-flask.1 to 2.0.0 ([#120](https://github.com/MetaMask/keyring-api/pull/120)).
289
+
290
+ ## [0.2.5]
291
+
292
+ ### Changed
293
+
294
+ - Remove `buildHandlersChain` ([#114](https://github.com/MetaMask/keyring-api/pull/114)).
295
+ - Update doc for `eth_signTransaction` ([#111](https://github.com/MetaMask/keyring-api/pull/111)).
296
+ - Remove un-versioned `eth_signTypedData` method ([#113](https://github.com/MetaMask/keyring-api/pull/113)).
297
+
298
+ ## [0.2.4]
299
+
300
+ ### Changed
301
+
302
+ - Fix linting and compatibility with older `tsc` ([#108](https://github.com/MetaMask/keyring-api/pull/108)).
303
+
304
+ ## [0.2.3]
305
+
306
+ ### Added
307
+
308
+ - Add redirection message to snap async response ([#102](https://github.com/MetaMask/keyring-api/pull/102)).
309
+
310
+ ### Changed
311
+
312
+ - Use `Omit` instead of `OmitUnion` ([#106](https://github.com/MetaMask/keyring-api/pull/106)).
313
+ - Update `KeyringResponse` comment ([#103](https://github.com/MetaMask/keyring-api/pull/103)).
314
+ - Use `KeyringRpcMethod` enum instead of string ([#105](https://github.com/MetaMask/keyring-api/pull/105)).
315
+ - Refactor tests to match superstruct examples ([#104](https://github.com/MetaMask/keyring-api/pull/104)).
316
+ - Add `exactOptional()` superstruct type ([#100](https://github.com/MetaMask/keyring-api/pull/100)).
317
+ - Bump @metamask/providers from 11.1.2 to 12.0.0 ([#99](https://github.com/MetaMask/keyring-api/pull/99)).
318
+ - Bump @metamask/providers from 11.1.1 to 11.1.2 ([#98](https://github.com/MetaMask/keyring-api/pull/98)).
319
+
320
+ ## [0.2.2]
321
+
322
+ ### Added
323
+
324
+ - Add architecture and EVM methods docs ([#86](https://github.com/MetaMask/keyring-api/pull/86)).
325
+ - Add `lastSelected` and `lastActive` to metadata ([#92](https://github.com/MetaMask/keyring-api/pull/92)).
326
+
327
+ ### Changed
328
+
329
+ - Make request `params` optional ([#96](https://github.com/MetaMask/keyring-api/pull/96)).
330
+ - Remove `lastActive` field from internal account model ([#95](https://github.com/MetaMask/keyring-api/pull/95)).
331
+ - Move request ID to outer request ([#94](https://github.com/MetaMask/keyring-api/pull/94)).
332
+
333
+ ## [0.2.1]
334
+
335
+ ### Changed
336
+
337
+ - Set `snap` object keys to be mandatory and move `name` to `metadata` ([#87](https://github.com/MetaMask/keyring-api/pull/87)).
338
+
339
+ ## [0.2.0]
340
+
341
+ ### Added
342
+
343
+ - Add `InternalAccount` type and create submodule `internal` ([#65](https://github.com/MetaMask/keyring-api/pull/65)).
344
+ - Add keyring events and helper functions ([#74](https://github.com/MetaMask/keyring-api/pull/74)).
345
+ - Add a `redirect` field to asynchronous request responses ([#75](https://github.com/MetaMask/keyring-api/pull/75)).
346
+ - Add `exportAccount` method ([#60](https://github.com/MetaMask/keyring-api/pull/60)).
347
+ - Add `getController` to client ([#43](https://github.com/MetaMask/keyring-api/pull/43)).
348
+
349
+ ### Changed
350
+
351
+ - Rename `erc4337` -> `eip4337` ([#42](https://github.com/MetaMask/keyring-api/pull/42)).
352
+ - Make `options` a mandatory field of `KeyringAccount` ([#30](https://github.com/MetaMask/keyring-api/pull/30)).
353
+ - Make `approveRequest` and `rejectRequest` optional ([#63](https://github.com/MetaMask/keyring-api/pull/63)).
354
+ - Make `exportAccount`, `listRequests` and `getRequest` optional ([#73](https://github.com/MetaMask/keyring-api/pull/73)).
355
+ - Export enums with account methods and types ([#66](https://github.com/MetaMask/keyring-api/pull/66)).
356
+ - Make `approveRequest` accept a `result` argument ([#59](https://github.com/MetaMask/keyring-api/pull/59)).
357
+ - Remove account name from `KeyringAccount` type ([#55](https://github.com/MetaMask/keyring-api/pull/55)).
358
+ - Remove `eth_sendTransaction` method ([#50](https://github.com/MetaMask/keyring-api/pull/50)).
359
+ - Rename `supportedMethods` to `methods` ([#35](https://github.com/MetaMask/keyring-api/pull/35)).
360
+
361
+ ## [0.1.3]
362
+
363
+ ### Changed
364
+
365
+ - Downgrade snaps dependencies to `0.35.2-flask.1` ([#25](https://github.com/MetaMask/keyring-api/pull/25)).
366
+
367
+ ## [0.1.2]
368
+
369
+ ### Changed
370
+
371
+ - Update snaps dependencies ([#21](https://github.com/MetaMask/keyring-api/pull/21)).
372
+
373
+ ## [0.1.1]
374
+
375
+ ### Added
376
+
377
+ - Validate snap responses for type correctness ([#15](https://github.com/MetaMask/keyring-api/pull/15)).
378
+
379
+ ### Changed
380
+
381
+ - Rename RPC handling functions ([#16](https://github.com/MetaMask/keyring-api/pull/16)).
382
+
383
+ ## [0.1.0] - 2023-06-20
384
+
385
+ ### Added
386
+
387
+ - Usage examples to [`README.md`](./README.md).
388
+ - Keyring API definition.
389
+ - JSON-RPC snap keyring client. It is intended to be used by a snap's companion dapp to send requests to the snap.
390
+ - SnapController keyring client. It is intended to be used by MetaMask to talk to the snap.
391
+ - Helper functions to create keyring handler in the snap.
392
+
393
+ [Unreleased]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@8.1.0...HEAD
394
+ [8.1.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@8.0.2...@metamask/keyring-api@8.1.0
395
+ [8.0.2]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@8.0.1...@metamask/keyring-api@8.0.2
396
+ [8.0.1]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@8.0.0...@metamask/keyring-api@8.0.1
397
+ [8.0.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@7.0.0...@metamask/keyring-api@8.0.0
398
+ [7.0.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@6.4.0...@metamask/keyring-api@7.0.0
399
+ [6.4.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@6.3.1...@metamask/keyring-api@6.4.0
400
+ [6.3.1]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@6.3.0...@metamask/keyring-api@6.3.1
401
+ [6.3.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@6.2.1...@metamask/keyring-api@6.3.0
402
+ [6.2.1]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@6.2.0...@metamask/keyring-api@6.2.1
403
+ [6.2.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@6.1.1...@metamask/keyring-api@6.2.0
404
+ [6.1.1]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@6.1.0...@metamask/keyring-api@6.1.1
405
+ [6.1.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@6.0.0...@metamask/keyring-api@6.1.0
406
+ [6.0.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@5.1.0...@metamask/keyring-api@6.0.0
407
+ [5.1.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@5.0.0...@metamask/keyring-api@5.1.0
408
+ [5.0.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@4.0.2...@metamask/keyring-api@5.0.0
409
+ [4.0.2]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@4.0.1...@metamask/keyring-api@4.0.2
410
+ [4.0.1]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@4.0.0...@metamask/keyring-api@4.0.1
411
+ [4.0.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@3.0.0...@metamask/keyring-api@4.0.0
412
+ [3.0.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@2.0.0...@metamask/keyring-api@3.0.0
413
+ [2.0.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@1.1.0...@metamask/keyring-api@2.0.0
414
+ [1.1.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@1.0.0...@metamask/keyring-api@1.1.0
415
+ [1.0.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@1.0.0-rc.1...@metamask/keyring-api@1.0.0
416
+ [1.0.0-rc.1]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.2.7...@metamask/keyring-api@1.0.0-rc.1
417
+ [0.2.7]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.2.6...@metamask/keyring-api@0.2.7
418
+ [0.2.6]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.2.5...@metamask/keyring-api@0.2.6
419
+ [0.2.5]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.2.4...@metamask/keyring-api@0.2.5
420
+ [0.2.4]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.2.3...@metamask/keyring-api@0.2.4
421
+ [0.2.3]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.2.2...@metamask/keyring-api@0.2.3
422
+ [0.2.2]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.2.1...@metamask/keyring-api@0.2.2
423
+ [0.2.1]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.2.0...@metamask/keyring-api@0.2.1
424
+ [0.2.0]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.1.3...@metamask/keyring-api@0.2.0
425
+ [0.1.3]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.1.2...@metamask/keyring-api@0.1.3
426
+ [0.1.2]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.1.1...@metamask/keyring-api@0.1.2
427
+ [0.1.1]: https://github.com/MetaMask/accounts/compare/@metamask/keyring-api@0.1.0...@metamask/keyring-api@0.1.1
428
+ [0.1.0]: https://github.com/MetaMask/accounts/releases/tag/@metamask/keyring-api@0.1.0