@metamask-previews/ramps-controller 29.0.0-preview-770db011a → 29.0.0-preview-4a273a7

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 (2) hide show
  1. package/CHANGELOG.md +16 -10
  2. package/package.json +3 -2
package/CHANGELOG.md CHANGED
@@ -7,24 +7,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
- ## [29.0.0]
11
-
12
10
  ### Added
13
11
 
14
12
  - Add `NeoBankServiceInvalidateQueriesAction`, `NeoBankServiceCacheUpdatedEvent` and `NeoBankServiceGranularCacheUpdatedEvent`, also included in `NeoBankServiceActions` and `NeoBankServiceEvents` ([#10882](https://github.com/MetaMask/core/pull/10882))
15
- - Add `NeoBankService.getCustomerAbilities`, exposed on the messenger, which returns the customer's rail abilities from neobank-proxy unmodified, and the `NeoBankCustomerAbilities`, `NeoBankFiatAbilities`, `NeoBankAbilityStatus`, `NeoBankCurrencyAbility` and `NeoBankAbilityCurrency` types ([#11225](https://github.com/MetaMask/core/pull/11225))
16
- - MoonPay rejects an autoramp create with a 422 when the rail it needs is not `Active`, so clients can check the rail first. Any non-2xx response throws an `HttpError`.
17
- - It resolves the MoonPay customer through `AuthenticationController:getSessionProfile`, so hosts must delegate that action to the `NeoBankService` messenger as well as `AuthenticationController:getBearerToken`. `getMicrodeposits` needs it too.
18
- - Add `RampsController.refreshCustomerAbilities`, exposed on the messenger, which stores the result in the new `vbaCustomerAbilities` state ([#11225](https://github.com/MetaMask/core/pull/11225))
19
- - The state is not persisted. A failed fetch throws and keeps the stored value. Discarding a VBA session owned by another profile clears it.
20
- - Add `getMusdAutorampDepositRailReadiness` and the `MusdAutorampDepositRailReadiness` type, which read from customer abilities whether the deposit rails a fiat → mUSD autoramp needs are `active`, `pending` or `blocked` ([#11225](https://github.com/MetaMask/core/pull/11225))
21
- - BRL needs `pix` and `pix_thirdparty`, USD needs `ach` and `ach_thirdparty`. Other fiats report `active`.
22
13
 
23
14
  ### Changed
24
15
 
25
16
  - **BREAKING:** `NeoBankService` now extends `BaseDataService` from `@metamask/base-data-service`, so reads and writes share one circuit breaker (previously each had its own) and repeated read failures can now block writes ([#10882](https://github.com/MetaMask/core/pull/10882))
26
17
  - `NeoBankServiceMessenger` now includes the `NeoBankService:invalidateQueries` action and `NeoBankService:cacheUpdated` events. Messengers built from `NeoBankServiceActions` / `NeoBankServiceEvents` pick these up automatically.
27
- - **BREAKING:** `RAMPS_CONTROLLER_REQUIRED_SERVICE_ACTIONS` now includes `NeoBankService:getCustomerAbilities`. Hosts must delegate that action to `RampsController` ([#11225](https://github.com/MetaMask/core/pull/11225))
28
18
  - `NeoBankService.getAutorampQuote`, `getAutorampQuoteForAutoramp`, `getCustomerByExternalId`, `registerPixAddress` and `attachAutorampQuote` now return `Promise<Json>` instead of `Promise<unknown>` ([#10882](https://github.com/MetaMask/core/pull/10882))
29
19
  - Concurrent identical NeoBank reads (`getAutoramp`, `getAutoramps`, `getPixDepositInstructions`, `getDepositInstructions`, `getMicrodeposits`, `getCustomerAbilities`, `listAutorampTransactions`, `getAutorampQuote`, `getAutorampQuoteForAutoramp`, `getCustomerByExternalId`) are now deduplicated: while one request is in flight, identical calls reuse it instead of sending another. Sequential reads still always hit the API ([#10882](https://github.com/MetaMask/core/pull/10882))
30
20
  - `getAutoramps` fetches each cursor page as its own query, so a failed page is retried on its own and concurrent calls with the same `customerId` reuse each in flight page request.
@@ -37,6 +27,22 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
37
27
 
38
28
  - **BREAKING:** Remove `onRetry`, `onBreak` and `onDegraded` from `NeoBankService` ([#10882](https://github.com/MetaMask/core/pull/10882))
39
29
 
30
+ ## [29.0.0]
31
+
32
+ ### Added
33
+
34
+ - Add `NeoBankService.getCustomerAbilities`, exposed on the messenger, which returns the customer's rail abilities from neobank-proxy unmodified, and the `NeoBankCustomerAbilities`, `NeoBankFiatAbilities`, `NeoBankAbilityStatus`, `NeoBankCurrencyAbility` and `NeoBankAbilityCurrency` types ([#11225](https://github.com/MetaMask/core/pull/11225))
35
+ - MoonPay rejects an autoramp create with a 422 when the rail it needs is not `Active`, so clients can check the rail first. Any non-2xx response throws an `HttpError`.
36
+ - It resolves the MoonPay customer through `AuthenticationController:getSessionProfile`, so hosts must delegate that action to the `NeoBankService` messenger as well as `AuthenticationController:getBearerToken`. `getMicrodeposits` needs it too.
37
+ - Add `RampsController.refreshCustomerAbilities`, exposed on the messenger, which stores the result in the new `vbaCustomerAbilities` state ([#11225](https://github.com/MetaMask/core/pull/11225))
38
+ - The state is not persisted. A failed fetch throws and keeps the stored value. Discarding a VBA session owned by another profile clears it.
39
+ - Add `getMusdAutorampDepositRailReadiness` and the `MusdAutorampDepositRailReadiness` type, which read from customer abilities whether the deposit rails a fiat → mUSD autoramp needs are `active`, `pending` or `blocked` ([#11225](https://github.com/MetaMask/core/pull/11225))
40
+ - BRL needs `pix` and `pix_thirdparty`, USD needs `ach` and `ach_thirdparty`. Other fiats report `active`.
41
+
42
+ ### Changed
43
+
44
+ - **BREAKING:** `RAMPS_CONTROLLER_REQUIRED_SERVICE_ACTIONS` now includes `NeoBankService:getCustomerAbilities`. Hosts must delegate that action to `RampsController` ([#11225](https://github.com/MetaMask/core/pull/11225))
45
+
40
46
  ### Fixed
41
47
 
42
48
  - Require provider-side `finalStatus` approval before `hydrateVbaOnboarding` reports KYC as approved; relay `kycStatus` approval alone remains pending and does not start account setup ([#11243](https://github.com/MetaMask/core/pull/11243))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@metamask-previews/ramps-controller",
3
- "version": "29.0.0-preview-770db011a",
3
+ "version": "29.0.0-preview-4a273a7",
4
4
  "description": "A controller for managing cryptocurrency on/off ramps functionality",
5
5
  "keywords": [
6
6
  "Ethereum",
@@ -47,6 +47,7 @@
47
47
  "since-latest-release": "../../scripts/since-latest-release.sh",
48
48
  "test": "vitest",
49
49
  "test:clean": "vitest --clearCache",
50
+ "test:coverage": "vitest --coverage",
50
51
  "test:verbose": "vitest --reporter=verbose",
51
52
  "test:watch": "vitest --watch"
52
53
  },
@@ -70,7 +71,7 @@
70
71
  "typedoc": "^0.28.20",
71
72
  "typedoc-plugin-missing-exports": "^4.1.4",
72
73
  "typescript": "npm:@typescript/typescript6@^6.0.2",
73
- "vitest": "^5.0.0"
74
+ "vitest": "5.0.3"
74
75
  },
75
76
  "engines": {
76
77
  "node": "^22.14.0 || ^24 || ^26"