@cityofzion/blockchain-service 1.17.1 → 1.18.1

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.
@@ -1,4 +1,4 @@
1
1
  import { FullTransactionsByAddressParams } from '../interfaces';
2
2
  export declare class BSFullTransactionsByAddressHelper {
3
- static validateFullTransactionsByAddressParams(params: FullTransactionsByAddressParams): void;
3
+ static validateFullTransactionsByAddressParams(params: Omit<FullTransactionsByAddressParams, 'nextCursor'>): void;
4
4
  }
@@ -76,12 +76,17 @@ export interface BSWithLedger<BSName extends string = string> {
76
76
  ledgerService: LedgerService<BSName>;
77
77
  generateAccountFromPublicKey(publicKey: string): Account<BSName>;
78
78
  }
79
+ export type TransactionNotificationTypedResponse = {
80
+ type: string;
81
+ value?: string;
82
+ };
83
+ export type TransactionNotificationStateResponse = {
84
+ type: string;
85
+ value?: string | TransactionNotificationTypedResponse[];
86
+ };
79
87
  export type TransactionNotifications = {
80
88
  eventName: string;
81
- state: {
82
- type: string;
83
- value: string;
84
- }[];
89
+ state?: TransactionNotificationStateResponse | TransactionNotificationStateResponse[];
85
90
  };
86
91
  export type TransactionTransferAsset = {
87
92
  amount: string;
@@ -122,8 +127,14 @@ export type FullTransactionsByAddressParams = {
122
127
  address: string;
123
128
  dateFrom: string;
124
129
  dateTo: string;
130
+ pageSize?: number;
125
131
  nextCursor?: string;
126
132
  };
133
+ export type ExportTransactionsByAddressParams = {
134
+ address: string;
135
+ dateFrom: string;
136
+ dateTo: string;
137
+ };
127
138
  export type FullTransactionNftEvent = {
128
139
  eventType: 'nft';
129
140
  amount: string;
@@ -192,6 +203,7 @@ export interface BlockchainDataService {
192
203
  getTransaction(txid: string): Promise<TransactionResponse>;
193
204
  getTransactionsByAddress(params: TransactionsByAddressParams): Promise<TransactionsByAddressResponse>;
194
205
  getFullTransactionsByAddress(params: FullTransactionsByAddressParams): Promise<FullTransactionsByAddressResponse>;
206
+ exportFullTransactionsByAddress(params: ExportTransactionsByAddressParams): Promise<string>;
195
207
  getContract(contractHash: string): Promise<ContractResponse>;
196
208
  getTokenInfo(tokenHash: string): Promise<Token>;
197
209
  getBalance(address: string): Promise<BalanceResponse[]>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cityofzion/blockchain-service",
3
- "version": "1.17.1",
3
+ "version": "1.18.1",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "repository": "https://github.com/CityOfZion/blockchain-services",