@trezor/blockchain-link-types
Advanced tools
Comparing version 1.0.5 to 1.0.6
@@ -0,1 +1,6 @@ | ||
# 1.0.6 | ||
- feat(blockchain-link-types): add block filters (78dd71d4c) | ||
- chore: replace deprecated String.subst with Sting.substing (57f45d4cd) | ||
# 1.0.5 | ||
@@ -2,0 +7,0 @@ |
@@ -298,3 +298,3 @@ export interface APIError { | ||
id: string; | ||
method: 'getAccountInfo' | 'getInfo' | 'getBlockHash' | 'getBlock' | 'getAccountUtxo' | 'getBalanceHistory' | 'getTransaction' | 'getTransactionSpecific' | 'estimateFee' | 'sendTransaction' | 'subscribeNewBlock' | 'unsubscribeNewBlock' | 'subscribeNewTransaction' | 'unsubscribeNewTransaction' | 'subscribeAddresses' | 'unsubscribeAddresses' | 'subscribeFiatRates' | 'unsubscribeFiatRates' | 'ping' | 'getCurrentFiatRates' | 'getFiatRatesForTimestamps' | 'getFiatRatesTickersList'; | ||
method: 'getAccountInfo' | 'getInfo' | 'getBlockHash' | 'getBlock' | 'getAccountUtxo' | 'getBalanceHistory' | 'getTransaction' | 'getTransactionSpecific' | 'estimateFee' | 'sendTransaction' | 'subscribeNewBlock' | 'unsubscribeNewBlock' | 'subscribeNewTransaction' | 'unsubscribeNewTransaction' | 'subscribeAddresses' | 'unsubscribeAddresses' | 'subscribeFiatRates' | 'unsubscribeFiatRates' | 'ping' | 'getCurrentFiatRates' | 'getFiatRatesForTimestamps' | 'getFiatRatesTickersList' | 'getMempoolFilters'; | ||
params: any; | ||
@@ -346,2 +346,9 @@ } | ||
} | ||
export interface WsBlockFilterReq { | ||
blockHash: string; | ||
} | ||
export interface WsBlockFiltersBatchReq { | ||
bestKnownBlockHash: string; | ||
pageSize?: number; | ||
} | ||
export interface WsAccountUtxoReq { | ||
@@ -403,2 +410,11 @@ descriptor: string; | ||
} | ||
export interface WsMempoolFiltersReq { | ||
scriptType: string; | ||
fromTimestamp: number; | ||
} | ||
export interface MempoolTxidFilterEntries { | ||
entries?: { | ||
[key: string]: string; | ||
}; | ||
} | ||
//# sourceMappingURL=blockbook-api.d.ts.map |
import type { AccountBalanceHistoryParams, GetCurrentFiatRatesParams, GetFiatRatesForTimestampsParams, GetFiatRatesTickersListParams, EstimateFeeParams, AccountInfoParams } from './params'; | ||
import type { AccountBalanceHistory, FiatRates, TokenStandard } from './common'; | ||
import type { Vin, Vout, Utxo as BlockbookUtxo, WsInfoRes, WsBlockHashRes, Token as BlockbookToken, EthereumParsedInputData as BlockbookEthereumParsedInputData, EthereumSpecific as BlockbookEthereumSpecific, TokenTransfer as BlockbookTokenTransfer, AddressAlias } from './blockbook-api'; | ||
import type { Vin, Vout, Utxo as BlockbookUtxo, WsInfoRes, WsBlockHashRes, WsBlockFilterReq, WsBlockFiltersBatchReq, MempoolTxidFilterEntries, Token as BlockbookToken, EthereumParsedInputData as BlockbookEthereumParsedInputData, EthereumSpecific as BlockbookEthereumSpecific, TokenTransfer as BlockbookTokenTransfer, AddressAlias } from './blockbook-api'; | ||
type OptionalKey<M, K extends keyof M> = Omit<M, K> & Partial<Pick<M, K>>; | ||
@@ -21,11 +21,15 @@ type RequiredKey<M, K extends keyof M> = Omit<M, K> & Required<Pick<M, K>>; | ||
} | ||
export interface MempoolFiltersParams { | ||
scriptType: 'taproot'; | ||
export interface FilterRequestParams { | ||
scriptType: 'taproot' | 'taproot-noordinals'; | ||
M?: number; | ||
} | ||
export interface MempoolFiltersParams extends FilterRequestParams { | ||
fromTimestamp?: number; | ||
} | ||
export interface MempoolFilters { | ||
entries?: { | ||
[txid: string]: string; | ||
}; | ||
export interface FilterResponse { | ||
P: number; | ||
M: number; | ||
zeroedKey: boolean; | ||
} | ||
type BlockFiltersBatch = `${string}:${string}:${string}`[]; | ||
export type XPUBAddress = { | ||
@@ -146,3 +150,9 @@ type: 'XPUBAddress'; | ||
}): Promise<Block>; | ||
declare function FSend(method: 'getMempoolFilters', params: MempoolFiltersParams): Promise<MempoolFilters>; | ||
declare function FSend(method: 'getBlockFilter', params: WsBlockFilterReq & FilterRequestParams): Promise<FilterResponse & { | ||
blockFilter: string; | ||
}>; | ||
declare function FSend(method: 'getBlockFiltersBatch', params: WsBlockFiltersBatchReq & FilterRequestParams): Promise<FilterResponse & { | ||
blockFiltersBatch: BlockFiltersBatch; | ||
}>; | ||
declare function FSend(method: 'getMempoolFilters', params: MempoolFiltersParams): Promise<FilterResponse & MempoolTxidFilterEntries>; | ||
declare function FSend(method: 'getAccountInfo', params: AccountInfoParams): Promise<AccountInfo>; | ||
@@ -149,0 +159,0 @@ declare function FSend(method: 'getAccountUtxo', params: AccountUtxoParams): Promise<AccountUtxo>; |
@@ -32,3 +32,3 @@ "use strict"; | ||
else if (message.indexOf('+') === 0) { | ||
this.message = `${msg} ${message.substr(1, message.length)}`; | ||
this.message = `${msg} ${message.substring(1)}`; | ||
} | ||
@@ -35,0 +35,0 @@ } |
{ | ||
"name": "@trezor/blockchain-link-types", | ||
"version": "1.0.5", | ||
"version": "1.0.6", | ||
"license": "See LICENSE.md in repo root", | ||
@@ -19,3 +19,3 @@ "sideEffects": false, | ||
"devDependencies": { | ||
"@trezor/utxo-lib": "1.0.10", | ||
"@trezor/utxo-lib": "1.0.11", | ||
"rimraf": "^5.0.1", | ||
@@ -22,0 +22,0 @@ "ripple-lib": "^1.10.1", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
53076
1620