Skip to content

Commit 6d653da

Browse files
Merge pull request #8573 from BitGo/WCI-65_operationId
refactor(express): update operationId lightningPayment
2 parents 791d510 + 9d74ab5 commit 6d653da

4 files changed

Lines changed: 4 additions & 7 deletions

File tree

modules/express/src/clientRoutes.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1835,10 +1835,7 @@ export function setupAPIRoutes(app: express.Application, config: Config): void {
18351835
router.put('express.pendingapprovals', [prepareBitGo(config), typedPromiseWrapper(handleV2PendingApproval)]);
18361836

18371837
// lightning - pay invoice
1838-
router.post('express.v2.wallet.lightningPayment', [
1839-
prepareBitGo(config),
1840-
typedPromiseWrapper(handlePayLightningInvoice),
1841-
]);
1838+
router.post('express.lightningpayinvoice', [prepareBitGo(config), typedPromiseWrapper(handlePayLightningInvoice)]);
18421839

18431840
// lightning - onchain withdrawal
18441841
router.post('express.lightningwithdrawonchain', [prepareBitGo(config), typedPromiseWrapper(handleLightningWithdraw)]);

modules/express/src/lightning/lightningInvoiceRoutes.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ export async function handleCreateLightningInvoice(req: express.Request): Promis
1919
}
2020

2121
export async function handlePayLightningInvoice(
22-
req: ExpressApiRouteRequest<'express.v2.wallet.lightningPayment', 'post'>
22+
req: ExpressApiRouteRequest<'express.lightningpayinvoice', 'post'>
2323
): Promise<any> {
2424
const bitgo = req.bitgo;
2525
const params = decodeOrElse(SubmitPaymentParams.name, SubmitPaymentParams, req.body, (error) => {

modules/express/src/typedRoutes/api/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ export const ExpressKeychainChangePasswordApiSpec = apiSpec({
222222
});
223223

224224
export const ExpressLightningWalletPaymentApiSpec = apiSpec({
225-
'express.v2.wallet.lightningPayment': {
225+
'express.lightningpayinvoice': {
226226
post: PostLightningWalletPayment,
227227
},
228228
});

modules/express/src/typedRoutes/api/v2/lightningPayment.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ export const LightningPaymentResponseObj = {
218218
* Pay a Lightning Network invoice from the given wallet.
219219
*
220220
*
221-
* @operationId express.v2.wallet.lightningPayment
221+
* @operationId express.lightningpayinvoice
222222
* @tag Express
223223
*/
224224
export const PostLightningWalletPayment = httpRoute({

0 commit comments

Comments
 (0)