File tree Expand file tree Collapse file tree 1 file changed +15
-6
lines changed
modules/express/src/typedRoutes/api/v2 Expand file tree Collapse file tree 1 file changed +15
-6
lines changed Original file line number Diff line number Diff line change @@ -13,6 +13,20 @@ export const LightningStateParams = {
1313 walletId : t . string ,
1414} ;
1515
16+ /**
17+ * Response
18+ * - 200: Returns the current Lightning wallet/node state('NON_EXISTING' | 'LOCKED' | 'UNLOCKED' | 'RPC_ACTIVE' | 'SERVER_ACTIVE' | 'WAITING_TO_START'.
19+ * - 400: BitGo Express error payload when the request is invalid (e.g., invalid coin or wallet not a self-custody lightning wallet).
20+ *
21+ * See platform spec: GET /api/v2/{coin}/wallet/{walletId}/state
22+ */
23+ export const LightningStateResponse = {
24+ 200 : t . type ( {
25+ state : WalletState ,
26+ } ) ,
27+ 400 : BitgoExpressError ,
28+ } as const ;
29+
1630/**
1731 * Lightning - Get node state
1832 *
@@ -26,10 +40,5 @@ export const GetLightningState = httpRoute({
2640 request : httpRequest ( {
2741 params : LightningStateParams ,
2842 } ) ,
29- response : {
30- 200 : t . type ( {
31- state : WalletState ,
32- } ) ,
33- 400 : BitgoExpressError ,
34- } ,
43+ response : LightningStateResponse ,
3544} ) ;
You can’t perform that action at this time.
0 commit comments