Skip to content

Commit

Permalink
lib+protos: bump tapd to v0.5.0 and litd to v0.14.0-alpha
Browse files Browse the repository at this point in the history
  • Loading branch information
jamaljsr committed Dec 12, 2024
1 parent 1bfb704 commit 7307f8a
Show file tree
Hide file tree
Showing 35 changed files with 9,944 additions and 663 deletions.
17 changes: 16 additions & 1 deletion lib/api/tapd.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
import { serviceNames as sn } from '../types/proto/schema';
import { AssetWallet } from '../types/proto/tapd/assetwalletrpc/assetwallet';
import { Mint } from '../types/proto/tapd/mintrpc/mint';
import { PriceOracle } from '../types/proto/tapd/priceoraclerpc/price_oracle';
import { Rfq } from '../types/proto/tapd/rfqrpc/rfq';
import { TaprootAssetChannels } from '../types/proto/tapd/tapchannelrpc/tapchannel';
import { TapDev } from '../types/proto/tapd/tapdevrpc/tapdev';
import { TaprootAssets } from '../types/proto/tapd/taprootassets';
import { Universe } from '../types/proto/tapd/universerpc/universe';

Expand All @@ -11,12 +15,23 @@ class TaprootAssetsApi {
taprootAssets: TaprootAssets;
assetWallet: AssetWallet;
mint: Mint;
priceOracle: PriceOracle;
rfq: Rfq;
tapChannels: TaprootAssetChannels;
tapDev: TapDev;
universe: Universe;

constructor(createRpc: Function, lnc: any) {
this.taprootAssets = createRpc(sn.taprpc.TaprootAssets, lnc);
this.mint = createRpc(sn.mintrpc.Mint, lnc);
this.assetWallet = createRpc(sn.assetwalletrpc.AssetWallet, lnc);
this.mint = createRpc(sn.mintrpc.Mint, lnc);
this.priceOracle = createRpc(sn.priceoraclerpc.PriceOracle, lnc);
this.rfq = createRpc(sn.rfqrpc.Rfq, lnc);
this.tapChannels = createRpc(
sn.tapchannelrpc.TaprootAssetChannels,
lnc
);
this.tapDev = createRpc(sn.tapdevrpc.TapDev, lnc);
this.universe = createRpc(sn.universerpc.Universe, lnc);
}
}
Expand Down
8 changes: 8 additions & 0 deletions lib/types/proto/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ import * as looprpc from './looprpc';
import * as poolrpc from './poolrpc';
import * as assetwalletrpc from './assetwalletrpc';
import * as mintrpc from './mintrpc';
import * as priceoraclerpc from './priceoraclerpc';
import * as rfqrpc from './rfqrpc';
import * as tapchannelrpc from './tapchannelrpc';
import * as tapdevrpc from './tapdevrpc';
import * as taprpc from './taprpc';
import * as universerpc from './universerpc';
export {
Expand All @@ -31,6 +35,10 @@ export {
poolrpc,
assetwalletrpc,
mintrpc,
priceoraclerpc,
rfqrpc,
tapchannelrpc,
tapdevrpc,
taprpc,
universerpc
};
1 change: 1 addition & 0 deletions lib/types/proto/priceoraclerpc.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './tapd/priceoraclerpc/price_oracle';
1 change: 1 addition & 0 deletions lib/types/proto/rfqrpc.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './tapd/rfqrpc/rfq';
35 changes: 33 additions & 2 deletions lib/types/proto/schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,12 @@ export const serviceNames = {
},
assetwalletrpc: { AssetWallet: 'assetwalletrpc.AssetWallet' },
mintrpc: { Mint: 'mintrpc.Mint' },
priceoraclerpc: { PriceOracle: 'priceoraclerpc.PriceOracle' },
rfqrpc: { Rfq: 'rfqrpc.Rfq' },
tapchannelrpc: {
TaprootAssetChannels: 'tapchannelrpc.TaprootAssetChannels'
},
tapdevrpc: { TapDev: 'tapdevrpc.TapDev' },
taprpc: { TaprootAssets: 'taprpc.TaprootAssets' },
universerpc: { Universe: 'universerpc.Universe' }
};
Expand Down Expand Up @@ -70,6 +76,31 @@ export const subscriptionMethods = [
'poolrpc.ChannelAuctioneer.SubscribeBatchAuction',
'poolrpc.ChannelAuctioneer.SubscribeSidecar',
'poolrpc.HashMail.RecvStream',
'taprpc.TaprootAssets.SubscribeSendAssetEventNtfns',
'taprpc.TaprootAssets.SubscribeReceiveAssetEventNtfns'
'lnrpc.Lightning.SubscribeTransactions',
'lnrpc.Lightning.SubscribePeerEvents',
'lnrpc.Lightning.SubscribeChannelEvents',
'lnrpc.Lightning.OpenChannel',
'lnrpc.Lightning.ChannelAcceptor',
'lnrpc.Lightning.CloseChannel',
'lnrpc.Lightning.SendPayment',
'lnrpc.Lightning.SendToRoute',
'lnrpc.Lightning.SubscribeInvoices',
'lnrpc.Lightning.SubscribeChannelGraph',
'lnrpc.Lightning.SubscribeChannelBackups',
'lnrpc.Lightning.RegisterRPCMiddleware',
'lnrpc.Lightning.SubscribeCustomMessages',
'mintrpc.Mint.SubscribeMintEvents',
'rfqrpc.Rfq.SubscribeRfqEventNtfns',
'routerrpc.Router.SendPaymentV2',
'routerrpc.Router.TrackPaymentV2',
'routerrpc.Router.TrackPayments',
'routerrpc.Router.SubscribeHtlcEvents',
'routerrpc.Router.SendPayment',
'routerrpc.Router.TrackPayment',
'routerrpc.Router.HtlcInterceptor',
'tapchannelrpc.TaprootAssetChannels.SendPayment',
'tapdevrpc.TapDev.SubscribeSendAssetEventNtfns',
'tapdevrpc.TapDev.SubscribeReceiveAssetEventNtfns',
'taprpc.TaprootAssets.SubscribeReceiveEvents',
'taprpc.TaprootAssets.SubscribeSendEvents'
];
1 change: 1 addition & 0 deletions lib/types/proto/tapchannelrpc.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './tapd/tapchannelrpc/tapchannel';
Loading

0 comments on commit 7307f8a

Please sign in to comment.