UNPKG

12.7 kBTypeScriptView Raw
1import { serializeError, deserializeError, createCustomErrorClass, addCustomErrorDeserializer } from "./helpers";
2export { serializeError, deserializeError, createCustomErrorClass, addCustomErrorDeserializer, };
3export declare const AccountNameRequiredError: (message?: string, fields?: {
4 [key: string]: any;
5}) => void;
6export declare const AccountNotSupported: (message?: string, fields?: {
7 [key: string]: any;
8}) => void;
9export declare const AmountRequired: (message?: string, fields?: {
10 [key: string]: any;
11}) => void;
12export declare const BluetoothRequired: (message?: string, fields?: {
13 [key: string]: any;
14}) => void;
15export declare const BtcUnmatchedApp: (message?: string, fields?: {
16 [key: string]: any;
17}) => void;
18export declare const CantOpenDevice: (message?: string, fields?: {
19 [key: string]: any;
20}) => void;
21export declare const CashAddrNotSupported: (message?: string, fields?: {
22 [key: string]: any;
23}) => void;
24export declare const CurrencyNotSupported: (message?: string, fields?: {
25 [key: string]: any;
26}) => void;
27export declare const DeviceAppVerifyNotSupported: (message?: string, fields?: {
28 [key: string]: any;
29}) => void;
30export declare const DeviceGenuineSocketEarlyClose: (message?: string, fields?: {
31 [key: string]: any;
32}) => void;
33export declare const DeviceNotGenuineError: (message?: string, fields?: {
34 [key: string]: any;
35}) => void;
36export declare const DeviceOnDashboardExpected: (message?: string, fields?: {
37 [key: string]: any;
38}) => void;
39export declare const DeviceOnDashboardUnexpected: (message?: string, fields?: {
40 [key: string]: any;
41}) => void;
42export declare const DeviceInOSUExpected: (message?: string, fields?: {
43 [key: string]: any;
44}) => void;
45export declare const DeviceHalted: (message?: string, fields?: {
46 [key: string]: any;
47}) => void;
48export declare const DeviceNameInvalid: (message?: string, fields?: {
49 [key: string]: any;
50}) => void;
51export declare const DeviceSocketFail: (message?: string, fields?: {
52 [key: string]: any;
53}) => void;
54export declare const DeviceSocketNoBulkStatus: (message?: string, fields?: {
55 [key: string]: any;
56}) => void;
57export declare const DisconnectedDevice: (message?: string, fields?: {
58 [key: string]: any;
59}) => void;
60export declare const DisconnectedDeviceDuringOperation: (message?: string, fields?: {
61 [key: string]: any;
62}) => void;
63export declare const EnpointConfigError: (message?: string, fields?: {
64 [key: string]: any;
65}) => void;
66export declare const EthAppPleaseEnableContractData: (message?: string, fields?: {
67 [key: string]: any;
68}) => void;
69export declare const FeeEstimationFailed: (message?: string, fields?: {
70 [key: string]: any;
71}) => void;
72export declare const FirmwareNotRecognized: (message?: string, fields?: {
73 [key: string]: any;
74}) => void;
75export declare const HardResetFail: (message?: string, fields?: {
76 [key: string]: any;
77}) => void;
78export declare const InvalidXRPTag: (message?: string, fields?: {
79 [key: string]: any;
80}) => void;
81export declare const InvalidAddress: (message?: string, fields?: {
82 [key: string]: any;
83}) => void;
84export declare const InvalidAddressBecauseDestinationIsAlsoSource: (message?: string, fields?: {
85 [key: string]: any;
86}) => void;
87export declare const LatestMCUInstalledError: (message?: string, fields?: {
88 [key: string]: any;
89}) => void;
90export declare const UnknownMCU: (message?: string, fields?: {
91 [key: string]: any;
92}) => void;
93export declare const LedgerAPIError: (message?: string, fields?: {
94 [key: string]: any;
95}) => void;
96export declare const LedgerAPIErrorWithMessage: (message?: string, fields?: {
97 [key: string]: any;
98}) => void;
99export declare const LedgerAPINotAvailable: (message?: string, fields?: {
100 [key: string]: any;
101}) => void;
102export declare const ManagerAppAlreadyInstalledError: (message?: string, fields?: {
103 [key: string]: any;
104}) => void;
105export declare const ManagerAppRelyOnBTCError: (message?: string, fields?: {
106 [key: string]: any;
107}) => void;
108export declare const ManagerAppDepInstallRequired: (message?: string, fields?: {
109 [key: string]: any;
110}) => void;
111export declare const ManagerAppDepUninstallRequired: (message?: string, fields?: {
112 [key: string]: any;
113}) => void;
114export declare const ManagerDeviceLockedError: (message?: string, fields?: {
115 [key: string]: any;
116}) => void;
117export declare const ManagerFirmwareNotEnoughSpaceError: (message?: string, fields?: {
118 [key: string]: any;
119}) => void;
120export declare const ManagerNotEnoughSpaceError: (message?: string, fields?: {
121 [key: string]: any;
122}) => void;
123export declare const ManagerUninstallBTCDep: (message?: string, fields?: {
124 [key: string]: any;
125}) => void;
126export declare const NetworkDown: (message?: string, fields?: {
127 [key: string]: any;
128}) => void;
129export declare const NoAddressesFound: (message?: string, fields?: {
130 [key: string]: any;
131}) => void;
132export declare const NotEnoughBalance: (message?: string, fields?: {
133 [key: string]: any;
134}) => void;
135export declare const NotEnoughBalanceToDelegate: (message?: string, fields?: {
136 [key: string]: any;
137}) => void;
138export declare const NotEnoughBalanceInParentAccount: (message?: string, fields?: {
139 [key: string]: any;
140}) => void;
141export declare const NotEnoughSpendableBalance: (message?: string, fields?: {
142 [key: string]: any;
143}) => void;
144export declare const NotEnoughBalanceBecauseDestinationNotCreated: (message?: string, fields?: {
145 [key: string]: any;
146}) => void;
147export declare const NoAccessToCamera: (message?: string, fields?: {
148 [key: string]: any;
149}) => void;
150export declare const NotEnoughGas: (message?: string, fields?: {
151 [key: string]: any;
152}) => void;
153export declare const NotSupportedLegacyAddress: (message?: string, fields?: {
154 [key: string]: any;
155}) => void;
156export declare const GasLessThanEstimate: (message?: string, fields?: {
157 [key: string]: any;
158}) => void;
159export declare const PasswordsDontMatchError: (message?: string, fields?: {
160 [key: string]: any;
161}) => void;
162export declare const PasswordIncorrectError: (message?: string, fields?: {
163 [key: string]: any;
164}) => void;
165export declare const RecommendSubAccountsToEmpty: (message?: string, fields?: {
166 [key: string]: any;
167}) => void;
168export declare const RecommendUndelegation: (message?: string, fields?: {
169 [key: string]: any;
170}) => void;
171export declare const TimeoutTagged: (message?: string, fields?: {
172 [key: string]: any;
173}) => void;
174export declare const UnexpectedBootloader: (message?: string, fields?: {
175 [key: string]: any;
176}) => void;
177export declare const MCUNotGenuineToDashboard: (message?: string, fields?: {
178 [key: string]: any;
179}) => void;
180export declare const RecipientRequired: (message?: string, fields?: {
181 [key: string]: any;
182}) => void;
183export declare const UnavailableTezosOriginatedAccountReceive: (message?: string, fields?: {
184 [key: string]: any;
185}) => void;
186export declare const UnavailableTezosOriginatedAccountSend: (message?: string, fields?: {
187 [key: string]: any;
188}) => void;
189export declare const UpdateFetchFileFail: (message?: string, fields?: {
190 [key: string]: any;
191}) => void;
192export declare const UpdateIncorrectHash: (message?: string, fields?: {
193 [key: string]: any;
194}) => void;
195export declare const UpdateIncorrectSig: (message?: string, fields?: {
196 [key: string]: any;
197}) => void;
198export declare const UpdateYourApp: (message?: string, fields?: {
199 [key: string]: any;
200}) => void;
201export declare const UserRefusedDeviceNameChange: (message?: string, fields?: {
202 [key: string]: any;
203}) => void;
204export declare const UserRefusedAddress: (message?: string, fields?: {
205 [key: string]: any;
206}) => void;
207export declare const UserRefusedFirmwareUpdate: (message?: string, fields?: {
208 [key: string]: any;
209}) => void;
210export declare const UserRefusedAllowManager: (message?: string, fields?: {
211 [key: string]: any;
212}) => void;
213export declare const UserRefusedOnDevice: (message?: string, fields?: {
214 [key: string]: any;
215}) => void;
216export declare const TransportOpenUserCancelled: (message?: string, fields?: {
217 [key: string]: any;
218}) => void;
219export declare const TransportInterfaceNotAvailable: (message?: string, fields?: {
220 [key: string]: any;
221}) => void;
222export declare const TransportRaceCondition: (message?: string, fields?: {
223 [key: string]: any;
224}) => void;
225export declare const TransportWebUSBGestureRequired: (message?: string, fields?: {
226 [key: string]: any;
227}) => void;
228export declare const DeviceShouldStayInApp: (message?: string, fields?: {
229 [key: string]: any;
230}) => void;
231export declare const WebsocketConnectionError: (message?: string, fields?: {
232 [key: string]: any;
233}) => void;
234export declare const WebsocketConnectionFailed: (message?: string, fields?: {
235 [key: string]: any;
236}) => void;
237export declare const WrongDeviceForAccount: (message?: string, fields?: {
238 [key: string]: any;
239}) => void;
240export declare const WrongAppForCurrency: (message?: string, fields?: {
241 [key: string]: any;
242}) => void;
243export declare const ETHAddressNonEIP: (message?: string, fields?: {
244 [key: string]: any;
245}) => void;
246export declare const CantScanQRCode: (message?: string, fields?: {
247 [key: string]: any;
248}) => void;
249export declare const FeeNotLoaded: (message?: string, fields?: {
250 [key: string]: any;
251}) => void;
252export declare const FeeRequired: (message?: string, fields?: {
253 [key: string]: any;
254}) => void;
255export declare const FeeTooHigh: (message?: string, fields?: {
256 [key: string]: any;
257}) => void;
258export declare const SyncError: (message?: string, fields?: {
259 [key: string]: any;
260}) => void;
261export declare const PairingFailed: (message?: string, fields?: {
262 [key: string]: any;
263}) => void;
264export declare const GenuineCheckFailed: (message?: string, fields?: {
265 [key: string]: any;
266}) => void;
267export declare const LedgerAPI4xx: (message?: string, fields?: {
268 [key: string]: any;
269}) => void;
270export declare const LedgerAPI5xx: (message?: string, fields?: {
271 [key: string]: any;
272}) => void;
273export declare const FirmwareOrAppUpdateRequired: (message?: string, fields?: {
274 [key: string]: any;
275}) => void;
276export declare const NoDBPathGiven: (message?: string, fields?: {
277 [key: string]: any;
278}) => void;
279export declare const DBWrongPassword: (message?: string, fields?: {
280 [key: string]: any;
281}) => void;
282export declare const DBNotReset: (message?: string, fields?: {
283 [key: string]: any;
284}) => void;
285/**
286 * TransportError is used for any generic transport errors.
287 * e.g. Error thrown when data received by exchanges are incorrect or if exchanged failed to communicate with the device for various reason.
288 */
289export declare function TransportError(message: string, id: string): void;
290export declare namespace TransportError {
291 var prototype: Error;
292}
293export declare const StatusCodes: {
294 PIN_REMAINING_ATTEMPTS: number;
295 INCORRECT_LENGTH: number;
296 MISSING_CRITICAL_PARAMETER: number;
297 COMMAND_INCOMPATIBLE_FILE_STRUCTURE: number;
298 SECURITY_STATUS_NOT_SATISFIED: number;
299 CONDITIONS_OF_USE_NOT_SATISFIED: number;
300 INCORRECT_DATA: number;
301 NOT_ENOUGH_MEMORY_SPACE: number;
302 REFERENCED_DATA_NOT_FOUND: number;
303 FILE_ALREADY_EXISTS: number;
304 INCORRECT_P1_P2: number;
305 INS_NOT_SUPPORTED: number;
306 CLA_NOT_SUPPORTED: number;
307 TECHNICAL_PROBLEM: number;
308 OK: number;
309 MEMORY_PROBLEM: number;
310 NO_EF_SELECTED: number;
311 INVALID_OFFSET: number;
312 FILE_NOT_FOUND: number;
313 INCONSISTENT_FILE: number;
314 ALGORITHM_NOT_SUPPORTED: number;
315 INVALID_KCV: number;
316 CODE_NOT_INITIALIZED: number;
317 ACCESS_CONDITION_NOT_FULFILLED: number;
318 CONTRADICTION_SECRET_CODE_STATUS: number;
319 CONTRADICTION_INVALIDATION: number;
320 CODE_BLOCKED: number;
321 MAX_VALUE_REACHED: number;
322 GP_AUTH_FAILED: number;
323 LICENSING: number;
324 HALTED: number;
325};
326export declare function getAltStatusMessage(code: number): string | undefined | null;
327/**
328 * Error thrown when a device returned a non success status.
329 * the error.statusCode is one of the `StatusCodes` exported by this library.
330 */
331export declare function TransportStatusError(statusCode: number): void;
332export declare namespace TransportStatusError {
333 var prototype: Error;
334}