@onekeyfe/hd-core 1.2.0-alpha.18 → 1.2.0-alpha.19
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.
- package/__tests__/device-features-state.test.ts +78 -0
- package/__tests__/device-identity.test.ts +30 -0
- package/__tests__/device-pool-state.test.ts +113 -0
- package/__tests__/device-settings.test.ts +108 -0
- package/__tests__/device-state-contract.test.ts +27 -0
- package/__tests__/device-state-events.test.ts +163 -0
- package/__tests__/device-state-mapper.test.ts +222 -0
- package/__tests__/device-state-projector.test.ts +94 -0
- package/__tests__/device-state-store.test.ts +115 -0
- package/__tests__/device-wallet-session-store.test.ts +46 -0
- package/__tests__/deviceFeaturesUtils.test.ts +13 -1
- package/__tests__/deviceSettings.test.ts +54 -0
- package/__tests__/get-device-state.test.ts +367 -0
- package/__tests__/logBlockEvent.test.ts +13 -0
- package/__tests__/protocol-v2.test.ts +358 -413
- package/__tests__/public-device-state-api.test.ts +153 -0
- package/__tests__/refresh-device-state.test.ts +101 -0
- package/__tests__/request-context-logging.test.ts +16 -0
- package/__tests__/search-devices.test.ts +93 -0
- package/dist/api/ClearSessionCache.d.ts.map +1 -1
- package/dist/api/FirmwareUpdateV4.d.ts.map +1 -1
- package/dist/api/GetDeviceState.d.ts +7 -0
- package/dist/api/GetDeviceState.d.ts.map +1 -0
- package/dist/api/GetFeatures.d.ts +1 -1
- package/dist/api/GetFeatures.d.ts.map +1 -1
- package/dist/api/GetOnekeyFeatures.d.ts.map +1 -1
- package/dist/api/GetPassphraseState.d.ts.map +1 -1
- package/dist/api/SearchDevices.d.ts.map +1 -1
- package/dist/api/device/DeviceRebootToBoardloader.d.ts.map +1 -1
- package/dist/api/device/DeviceRebootToBootloader.d.ts.map +1 -1
- package/dist/api/device/DeviceSettings.d.ts.map +1 -1
- package/dist/api/index.d.ts +1 -4
- package/dist/api/index.d.ts.map +1 -1
- package/dist/api/internal.d.ts +4 -0
- package/dist/api/internal.d.ts.map +1 -0
- package/dist/api/protocol-v2/DeviceInfoGet.d.ts +0 -1
- package/dist/api/protocol-v2/DeviceInfoGet.d.ts.map +1 -1
- package/dist/api/protocol-v2/DeviceReboot.d.ts.map +1 -1
- package/dist/api/protocol-v2/DeviceSettingsGet.d.ts.map +1 -1
- package/dist/api/protocol-v2/DeviceSettingsSet.d.ts.map +1 -1
- package/dist/api/protocol-v2/DeviceStatusGet.d.ts.map +1 -1
- package/dist/api/utils.d.ts +2 -1
- package/dist/api/utils.d.ts.map +1 -1
- package/dist/constants/index.d.ts +1 -1
- package/dist/constants/index.d.ts.map +1 -1
- package/dist/core/index.d.ts.map +1 -1
- package/dist/device/Device.d.ts +22 -3
- package/dist/device/Device.d.ts.map +1 -1
- package/dist/device/DeviceFeaturesState.d.ts +4 -0
- package/dist/device/DeviceFeaturesState.d.ts.map +1 -0
- package/dist/device/DevicePool.d.ts +1 -0
- package/dist/device/DevicePool.d.ts.map +1 -1
- package/dist/device/DeviceStateMapper.d.ts +13 -0
- package/dist/device/DeviceStateMapper.d.ts.map +1 -0
- package/dist/device/DeviceStateProjector.d.ts +8 -0
- package/dist/device/DeviceStateProjector.d.ts.map +1 -0
- package/dist/device/DeviceStateStore.d.ts +23 -0
- package/dist/device/DeviceStateStore.d.ts.map +1 -0
- package/dist/device/deviceIdentity.d.ts +5 -0
- package/dist/device/deviceIdentity.d.ts.map +1 -0
- package/dist/deviceProfile/buildDeviceFeatures.d.ts.map +1 -1
- package/dist/deviceProfile/index.d.ts +0 -1
- package/dist/deviceProfile/index.d.ts.map +1 -1
- package/dist/events/device.d.ts +7 -2
- package/dist/events/device.d.ts.map +1 -1
- package/dist/index.d.ts +688 -639
- package/dist/index.js +1274 -942
- package/dist/inject.d.ts.map +1 -1
- package/dist/protocols/protocol-v2/features.d.ts +1 -0
- package/dist/protocols/protocol-v2/features.d.ts.map +1 -1
- package/dist/protocols/protocol-v2/index.d.ts +1 -1
- package/dist/protocols/protocol-v2/index.d.ts.map +1 -1
- package/dist/protocols/protocol-v2/walletSession.d.ts.map +1 -1
- package/dist/types/api/deviceSettings.d.ts +8 -0
- package/dist/types/api/deviceSettings.d.ts.map +1 -1
- package/dist/types/api/getDeviceState.d.ts +12 -0
- package/dist/types/api/getDeviceState.d.ts.map +1 -0
- package/dist/types/api/index.d.ts +4 -7
- package/dist/types/api/index.d.ts.map +1 -1
- package/dist/types/api/protocolV2.d.ts +1 -6
- package/dist/types/api/protocolV2.d.ts.map +1 -1
- package/dist/types/device.d.ts +121 -1
- package/dist/types/device.d.ts.map +1 -1
- package/dist/utils/deviceFeaturesUtils.d.ts.map +1 -1
- package/dist/utils/deviceSettings.d.ts.map +1 -1
- package/dist/utils/patch.d.ts +1 -1
- package/dist/utils/tracing.d.ts.map +1 -1
- package/package.json +4 -4
- package/src/api/ClearSessionCache.ts +4 -0
- package/src/api/FirmwareUpdateV4.ts +15 -7
- package/src/api/GetDeviceState.ts +55 -0
- package/src/api/GetFeatures.ts +8 -3
- package/src/api/GetOnekeyFeatures.ts +3 -72
- package/src/api/GetPassphraseState.ts +3 -1
- package/src/api/SearchDevices.ts +25 -4
- package/src/api/device/DeviceRebootToBoardloader.ts +1 -0
- package/src/api/device/DeviceRebootToBootloader.ts +1 -0
- package/src/api/device/DeviceSettings.ts +28 -0
- package/src/api/index.ts +1 -4
- package/src/api/internal.ts +9 -0
- package/src/api/protocol-v2/DeviceInfoGet.ts +3 -5
- package/src/api/protocol-v2/DeviceReboot.ts +3 -1
- package/src/api/protocol-v2/DeviceSettingsGet.ts +3 -1
- package/src/api/protocol-v2/DeviceSettingsSet.ts +2 -0
- package/src/api/protocol-v2/DeviceStatusGet.ts +1 -0
- package/src/api/utils.ts +9 -3
- package/src/constants/index.ts +1 -4
- package/src/core/index.ts +7 -1
- package/src/data/messages/messages-protocol-v2.json +22 -13
- package/src/device/Device.ts +256 -78
- package/src/device/DeviceFeaturesState.ts +34 -0
- package/src/device/DevicePool.ts +35 -9
- package/src/device/DeviceStateMapper.ts +364 -0
- package/src/device/DeviceStateProjector.ts +92 -0
- package/src/device/DeviceStateStore.ts +242 -0
- package/src/device/deviceIdentity.ts +18 -0
- package/src/deviceProfile/buildDeviceFeatures.ts +166 -109
- package/src/deviceProfile/index.ts +0 -1
- package/src/events/device.ts +13 -1
- package/src/events/logBlockEvent.ts +1 -1
- package/src/inject.ts +4 -5
- package/src/protocols/protocol-v2/features.ts +18 -9
- package/src/protocols/protocol-v2/index.ts +1 -0
- package/src/protocols/protocol-v2/walletSession.ts +5 -7
- package/src/types/api/deviceSettings.ts +8 -0
- package/src/types/api/getDeviceState.ts +19 -0
- package/src/types/api/index.ts +3 -20
- package/src/types/api/protocolV2.ts +0 -24
- package/src/types/device.ts +148 -1
- package/src/utils/deviceFeaturesUtils.ts +5 -1
- package/src/utils/deviceSettings.ts +41 -0
- package/src/utils/tracing.ts +3 -1
- package/dist/api/GetDeviceInfo.d.ts +0 -9
- package/dist/api/GetDeviceInfo.d.ts.map +0 -1
- package/dist/deviceProfile/buildDeviceProfile.d.ts +0 -22
- package/dist/deviceProfile/buildDeviceProfile.d.ts.map +0 -1
- package/dist/types/api/getDeviceInfo.d.ts +0 -88
- package/dist/types/api/getDeviceInfo.d.ts.map +0 -1
- package/src/api/GetDeviceInfo.ts +0 -152
- package/src/deviceProfile/buildDeviceProfile.ts +0 -370
- package/src/types/api/getDeviceInfo.ts +0 -106
package/dist/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import EventEmitter, { EventEmitter as EventEmitter$1 } from 'events';
|
|
2
|
-
import { DeviceFirmwareTargetType, DeviceFirmwareUpdateRecordFields, DeviceRebootType, DeviceFirmwareTarget, Messages, Transport, TransportCallOptions,
|
|
2
|
+
import { DeviceFirmwareTargetType, DeviceFirmwareUpdateRecordFields, DeviceRebootType, DeviceFirmwareTarget, Messages, Transport, TransportCallOptions, OneKeyDeviceCommType, ProtocolV2DeviceInfo, DeviceStatus as DeviceStatus$1, OneKeyDeviceInfo, Success as Success$1, LowlevelTransportSharedPlugin, DeviceSessionResume, DeviceHostPassphrase, DevicePassphraseOnDevice, DeviceAttachPinOnDevice, DeviceSettings, DeviceSettingsPage, ProtocolInfo, DevOnboardingStatus, DeviceSession, DeviceFirmwareUpdateStatus, DeviceFactoryInfo, Features as Features$1, RecoveryDeviceType, SafetyCheckLevel, ResourceType, NextU2FCounter, SetU2FCounter, CipheredKeyValue as CipheredKeyValue$1, UintType, EthereumPublicKey, EthereumMessageSignature, Address, MultisigRedeemScriptType, InputScriptType, PublicKey, MessageSignature, SignedPsbt, PrevInput, TxOutputBinType, TxInput, TxOutputType, TxInputType, StarcoinAddress as StarcoinAddress$1, StarcoinPublicKey as StarcoinPublicKey$1, StarcoinMessageSignature, StarcoinSignedTx, NEMAddress as NEMAddress$1, NEMSignedTx, SolanaAddress as SolanaAddress$1, SolanaSignedTx as SolanaSignedTx$1, SolanaTxExtraInfo, SolanaOffChainMessageVersion, SolanaOffChainMessageFormat, StellarAddress as StellarAddress$1, StellarSignedTx, TronAddress as TronAddress$1, TronResourceCode, TronSignedTx, TronMessageSignature, ConfluxAddress as ConfluxAddress$1, ConfluxMessageSignature, NearAddress as NearAddress$1, NearSignedTx, AptosAddress as AptosAddress$1, AptosMessageSignature as AptosMessageSignature$1, AptosSignedTx as AptosSignedTx$1, AlgorandAddress, AlgorandSignedTx, CosmosAddress as CosmosAddress$1, CosmosSignedTx as CosmosSignedTx$1, SuiAddress as SuiAddress$1, SuiMessageSignature, CardanoAddressParametersType, CardanoMessageSignature, FilecoinAddress as FilecoinAddress$1, FilecoinSignedTx as FilecoinSignedTx$1, PolkadotAddress as PolkadotAddress$1, PolkadotSignedTx as PolkadotSignedTx$1, KaspaAddress as KaspaAddress$1, NervosAddress as NervosAddress$1, NervosSignedTx as NervosSignedTx$1, DnxAddress as DnxAddress$1, TonWalletVersion, TonWorkChain, TonSignedMessage, TonSignedProof, TonSignDataType, TonSignedData, ScdoAddress as ScdoAddress$1, ScdoSignedMessage, ScdoSignedTx as ScdoSignedTx$1, AlephiumMessageSignature, AlephiumSignedTx as AlephiumSignedTx$1, BenfenAddress as BenfenAddress$1, BenfenMessageSignature, ChangeOutputScriptType } from '@onekeyfe/hd-transport';
|
|
3
3
|
export { Success as DeviceSuccess, HDNodeType, Messages as PROTO, ResourceType, TonSignDataType, TonWalletVersion } from '@onekeyfe/hd-transport';
|
|
4
4
|
import * as _onekeyfe_hd_shared from '@onekeyfe/hd-shared';
|
|
5
|
-
import { HardwareConnectProtocol,
|
|
5
|
+
import { HardwareConnectProtocol, EFirmwareType, EDeviceType, Deferred } from '@onekeyfe/hd-shared';
|
|
6
6
|
|
|
7
7
|
interface CommonParams {
|
|
8
8
|
keepSession?: boolean;
|
|
@@ -92,12 +92,12 @@ type DefaultMessageResponse = TypedCallResponseMap[MessageKey];
|
|
|
92
92
|
declare class DeviceCommands {
|
|
93
93
|
instanceId: string;
|
|
94
94
|
currentResponseID?: number;
|
|
95
|
-
device: Device
|
|
95
|
+
device: Device;
|
|
96
96
|
transport: Transport;
|
|
97
97
|
mainId: string;
|
|
98
98
|
disposed: boolean;
|
|
99
99
|
callPromise?: Promise<DefaultMessageResponse>;
|
|
100
|
-
constructor(device: Device
|
|
100
|
+
constructor(device: Device, mainId: string);
|
|
101
101
|
dispose(_cancelRequest: boolean): Promise<void>;
|
|
102
102
|
checkDisposed(): void;
|
|
103
103
|
cancelDeviceOnOneKeyDevice(): Promise<{
|
|
@@ -150,6 +150,435 @@ declare class DeviceCommands {
|
|
|
150
150
|
}): Promise<PassphrasePromptResponse>;
|
|
151
151
|
}
|
|
152
152
|
|
|
153
|
+
type transportEnv = 'node' | 'web' | 'webextension' | 'electron' | 'react-native' | 'webusb' | 'desktop-webusb' | 'desktop-web-ble' | 'emulator' | 'lowlevel' | 'node-usb';
|
|
154
|
+
type ConnectSettings = {
|
|
155
|
+
connectSrc?: string;
|
|
156
|
+
debug?: boolean;
|
|
157
|
+
transportReconnect?: boolean;
|
|
158
|
+
lazyLoad?: boolean;
|
|
159
|
+
origin?: string;
|
|
160
|
+
parentOrigin?: string;
|
|
161
|
+
configSrc: string;
|
|
162
|
+
iframeSrc: string;
|
|
163
|
+
version: string;
|
|
164
|
+
priority: number;
|
|
165
|
+
trustedHost: boolean;
|
|
166
|
+
supportedBrowser?: boolean;
|
|
167
|
+
env: transportEnv;
|
|
168
|
+
timestamp: number;
|
|
169
|
+
isFrame?: boolean;
|
|
170
|
+
preRelease?: boolean;
|
|
171
|
+
fetchConfig?: boolean;
|
|
172
|
+
extension?: string;
|
|
173
|
+
configFetcher?: (url: string) => Promise<RemoteConfigResponse | null>;
|
|
174
|
+
};
|
|
175
|
+
type IVersionArray = [number, number, number];
|
|
176
|
+
type ILocale = 'zh-CN' | 'en-US';
|
|
177
|
+
type IProtocolV2FirmwareComponentTarget = 'ROMLOADER' | 'BOOTLOADER' | 'APPLICATION_P1' | 'APPLICATION_P2' | 'COPROCESSOR' | 'SE01' | 'SE02' | 'SE03' | 'SE04';
|
|
178
|
+
type IProtocolV2FirmwareComponent = {
|
|
179
|
+
target: IProtocolV2FirmwareComponentTarget;
|
|
180
|
+
url: string;
|
|
181
|
+
fingerprint?: string;
|
|
182
|
+
version?: IVersionArray;
|
|
183
|
+
};
|
|
184
|
+
type IProtocolV2ResourceBundle = {
|
|
185
|
+
name: string;
|
|
186
|
+
url: string;
|
|
187
|
+
devicePath: string;
|
|
188
|
+
version?: IVersionArray;
|
|
189
|
+
payloadHash?: string;
|
|
190
|
+
headerHash?: string;
|
|
191
|
+
};
|
|
192
|
+
type IFirmwareReleaseInfo = {
|
|
193
|
+
required: boolean;
|
|
194
|
+
url: string;
|
|
195
|
+
firmwareType?: EFirmwareType;
|
|
196
|
+
resource?: string;
|
|
197
|
+
fullResource?: string;
|
|
198
|
+
fullResourceRange?: string[];
|
|
199
|
+
bootloaderResource?: string;
|
|
200
|
+
bootloaderVersion?: IVersionArray;
|
|
201
|
+
displayBootloaderVersion?: IVersionArray;
|
|
202
|
+
bootloaderRelatedFirmwareVersion?: IVersionArray;
|
|
203
|
+
upgradeType?: 'payload-package-set' | string;
|
|
204
|
+
components?: Record<string, IProtocolV2FirmwareComponent>;
|
|
205
|
+
installOrder?: string[];
|
|
206
|
+
resourceBundles?: IProtocolV2ResourceBundle[];
|
|
207
|
+
bootloaderChangelog?: {
|
|
208
|
+
[k in ILocale]: string;
|
|
209
|
+
};
|
|
210
|
+
fingerprint: string;
|
|
211
|
+
version: IVersionArray;
|
|
212
|
+
changelog: {
|
|
213
|
+
[k in ILocale]: string;
|
|
214
|
+
};
|
|
215
|
+
};
|
|
216
|
+
type IBLEFirmwareReleaseInfo = {
|
|
217
|
+
required: boolean;
|
|
218
|
+
url: string;
|
|
219
|
+
webUpdate: string;
|
|
220
|
+
fingerprint: string;
|
|
221
|
+
fingerprintWeb: string;
|
|
222
|
+
version: IVersionArray;
|
|
223
|
+
changelog: {
|
|
224
|
+
[k in ILocale]: string;
|
|
225
|
+
};
|
|
226
|
+
};
|
|
227
|
+
type IKnownDevice = Exclude<IDeviceType, 'unknown'>;
|
|
228
|
+
type DeviceTypeMap = {
|
|
229
|
+
[k in IKnownDevice]: {
|
|
230
|
+
firmware: IFirmwareReleaseInfo[];
|
|
231
|
+
'firmware-v1'?: IFirmwareReleaseInfo[];
|
|
232
|
+
'firmware-v2'?: IFirmwareReleaseInfo[];
|
|
233
|
+
'firmware-v8'?: IFirmwareReleaseInfo[];
|
|
234
|
+
'firmware-btc-v8'?: IFirmwareReleaseInfo[];
|
|
235
|
+
ble: IBLEFirmwareReleaseInfo[];
|
|
236
|
+
};
|
|
237
|
+
};
|
|
238
|
+
type AssetsMap = {
|
|
239
|
+
bridge: {
|
|
240
|
+
version: IVersionArray;
|
|
241
|
+
linux32Rpm: string;
|
|
242
|
+
linux64Rpm: string;
|
|
243
|
+
linux32Deb: string;
|
|
244
|
+
linux64Deb: string;
|
|
245
|
+
win: string;
|
|
246
|
+
mac: string;
|
|
247
|
+
sha256sumAsc: string;
|
|
248
|
+
changelog: {
|
|
249
|
+
[k in ILocale]: string;
|
|
250
|
+
};
|
|
251
|
+
};
|
|
252
|
+
};
|
|
253
|
+
type RemoteConfigResponse = {
|
|
254
|
+
bridge: AssetsMap['bridge'];
|
|
255
|
+
} & DeviceTypeMap;
|
|
256
|
+
|
|
257
|
+
type DeviceStatus = 'available' | 'occupied' | 'used';
|
|
258
|
+
declare enum EOneKeyDeviceMode {
|
|
259
|
+
bootloader = "bootloader",
|
|
260
|
+
normal = "normal",
|
|
261
|
+
notInitialized = "notInitialized",
|
|
262
|
+
backupMode = "backupMode"
|
|
263
|
+
}
|
|
264
|
+
type UnavailableCapability = 'no-capability' | 'no-support' | 'update-required' | 'trezor-connect-outdated';
|
|
265
|
+
type UnavailableCapabilities = {
|
|
266
|
+
[key: string]: UnavailableCapability;
|
|
267
|
+
};
|
|
268
|
+
type KnownDevice = {
|
|
269
|
+
connectId: string | null;
|
|
270
|
+
uuid: string;
|
|
271
|
+
deviceId: string | null;
|
|
272
|
+
deviceType: IDeviceType | null;
|
|
273
|
+
commType: OneKeyDeviceCommType | null;
|
|
274
|
+
path: string;
|
|
275
|
+
label: string;
|
|
276
|
+
bleName: string | null;
|
|
277
|
+
name: string;
|
|
278
|
+
displayName?: string;
|
|
279
|
+
error?: typeof undefined;
|
|
280
|
+
mode: EOneKeyDeviceMode;
|
|
281
|
+
features?: Features;
|
|
282
|
+
state?: DeviceState;
|
|
283
|
+
sessionId?: string | null;
|
|
284
|
+
unavailableCapabilities: UnavailableCapabilities;
|
|
285
|
+
bleFirmwareVersion: IVersionArray | null;
|
|
286
|
+
firmwareVersion: IVersionArray | null;
|
|
287
|
+
instanceId?: string;
|
|
288
|
+
sdkInstanceId?: string;
|
|
289
|
+
createdAt?: number;
|
|
290
|
+
};
|
|
291
|
+
type SearchDevice = {
|
|
292
|
+
connectId: string | null;
|
|
293
|
+
uuid: string;
|
|
294
|
+
deviceId: string | null;
|
|
295
|
+
deviceType: IDeviceType;
|
|
296
|
+
name: string;
|
|
297
|
+
displayName?: string;
|
|
298
|
+
commType: OneKeyDeviceCommType;
|
|
299
|
+
};
|
|
300
|
+
type Device$1 = KnownDevice;
|
|
301
|
+
type DeviceFeaturesProtocol = 'V1' | 'V2' | 'unknown';
|
|
302
|
+
type DeviceFeaturesMode = 'normal' | 'bootloader' | 'romloader' | 'notInitialized' | 'backupMode' | 'unknown';
|
|
303
|
+
type DeviceFeaturesVerify = {
|
|
304
|
+
firmwareBuildId?: string;
|
|
305
|
+
firmwareHash?: string;
|
|
306
|
+
bootloaderBuildId?: string;
|
|
307
|
+
bootloaderHash?: string;
|
|
308
|
+
boardBuildId?: string;
|
|
309
|
+
boardHash?: string;
|
|
310
|
+
bleBuildId?: string;
|
|
311
|
+
bleHash?: string;
|
|
312
|
+
se01BuildId?: string;
|
|
313
|
+
se01Hash?: string;
|
|
314
|
+
se02BuildId?: string;
|
|
315
|
+
se02Hash?: string;
|
|
316
|
+
se03BuildId?: string;
|
|
317
|
+
se03Hash?: string;
|
|
318
|
+
se04BuildId?: string;
|
|
319
|
+
se04Hash?: string;
|
|
320
|
+
se01BootBuildId?: string;
|
|
321
|
+
se01BootHash?: string;
|
|
322
|
+
se02BootBuildId?: string;
|
|
323
|
+
se02BootHash?: string;
|
|
324
|
+
se03BootBuildId?: string;
|
|
325
|
+
se03BootHash?: string;
|
|
326
|
+
se04BootBuildId?: string;
|
|
327
|
+
se04BootHash?: string;
|
|
328
|
+
};
|
|
329
|
+
type DeviceFeaturesRaw = {
|
|
330
|
+
protocolV1Features?: Messages.Features;
|
|
331
|
+
protocolV1OneKeyFeatures?: OnekeyFeatures;
|
|
332
|
+
protocolV2DeviceInfo?: ProtocolV2DeviceInfo;
|
|
333
|
+
protocolV2DeviceStatus?: DeviceStatus$1;
|
|
334
|
+
};
|
|
335
|
+
type DeviceFeaturesRawPatch = {
|
|
336
|
+
[Key in keyof DeviceFeaturesRaw]?: DeviceFeaturesRaw[Key] | null;
|
|
337
|
+
};
|
|
338
|
+
type DeviceStateProtocol = DeviceFeaturesProtocol;
|
|
339
|
+
type DeviceStateMode = DeviceFeaturesMode;
|
|
340
|
+
type DeviceStateSection = 'identity' | 'status' | 'settings' | 'versions' | 'verification';
|
|
341
|
+
type DeviceStateUpdateSource = 'initialize' | 'device-info' | 'device-status' | 'apply-settings' | 'change-pin' | 'lock' | 'unlock' | 'passphrase' | 'session-clear' | 'firmware-update' | 'transport-reconnect' | 'compatibility';
|
|
342
|
+
type DeviceStateIdentity = {
|
|
343
|
+
deviceType: IDeviceType;
|
|
344
|
+
firmwareType: EFirmwareType;
|
|
345
|
+
model: string | null;
|
|
346
|
+
vendor: string | null;
|
|
347
|
+
deviceId: string | null;
|
|
348
|
+
serialNo: string;
|
|
349
|
+
label: string | null;
|
|
350
|
+
bleName: string | null;
|
|
351
|
+
displayName: string;
|
|
352
|
+
};
|
|
353
|
+
type DeviceStateStatus = {
|
|
354
|
+
mode: DeviceStateMode;
|
|
355
|
+
initialized: boolean | null;
|
|
356
|
+
unlocked: boolean | null;
|
|
357
|
+
firmwarePresent: boolean | null;
|
|
358
|
+
backupRequired: boolean | null;
|
|
359
|
+
noBackup: boolean | null;
|
|
360
|
+
unfinishedBackup: boolean | null;
|
|
361
|
+
recoveryMode: boolean | null;
|
|
362
|
+
passphraseProtection: boolean | null;
|
|
363
|
+
pinProtection: boolean | null;
|
|
364
|
+
attachToPinEnabled: boolean | null;
|
|
365
|
+
unlockedAttachPin: boolean | null;
|
|
366
|
+
};
|
|
367
|
+
type DeviceStateSettings = {
|
|
368
|
+
language: string | null;
|
|
369
|
+
bleEnabled: boolean | null;
|
|
370
|
+
sdCardPresent: boolean | null;
|
|
371
|
+
sdProtection: boolean | null;
|
|
372
|
+
wipeCodeProtection: boolean | null;
|
|
373
|
+
passphraseAlwaysOnDevice: boolean | null;
|
|
374
|
+
safetyChecks: string | null;
|
|
375
|
+
autoLockDelayMs: number | null;
|
|
376
|
+
autoShutdownDelayMs: number | null;
|
|
377
|
+
displayRotation: number | null;
|
|
378
|
+
experimentalFeatures: boolean | null;
|
|
379
|
+
wallpaperPath: string | null;
|
|
380
|
+
brightness: number | null;
|
|
381
|
+
animationEnabled: boolean | null;
|
|
382
|
+
tapToWake: boolean | null;
|
|
383
|
+
hapticFeedback: boolean | null;
|
|
384
|
+
deviceNameDisplayEnabled: boolean | null;
|
|
385
|
+
airgapMode: boolean | null;
|
|
386
|
+
fidoEnabled: boolean | null;
|
|
387
|
+
usbLockEnabled: boolean | null;
|
|
388
|
+
randomKeypad: boolean | null;
|
|
389
|
+
};
|
|
390
|
+
type DeviceStateVersions = {
|
|
391
|
+
firmware: string | null;
|
|
392
|
+
bootloader: string | null;
|
|
393
|
+
board: string | null;
|
|
394
|
+
ble: string | null;
|
|
395
|
+
se?: string | null;
|
|
396
|
+
se01?: string | null;
|
|
397
|
+
se02?: string | null;
|
|
398
|
+
se03?: string | null;
|
|
399
|
+
se04?: string | null;
|
|
400
|
+
se01Boot?: string | null;
|
|
401
|
+
se02Boot?: string | null;
|
|
402
|
+
se03Boot?: string | null;
|
|
403
|
+
se04Boot?: string | null;
|
|
404
|
+
};
|
|
405
|
+
type DeviceStateSession = {
|
|
406
|
+
sessionId: string | null;
|
|
407
|
+
passphraseState?: string;
|
|
408
|
+
};
|
|
409
|
+
type DeviceState = {
|
|
410
|
+
schemaVersion: 1;
|
|
411
|
+
revision: number;
|
|
412
|
+
updatedAt: number;
|
|
413
|
+
protocol: DeviceStateProtocol;
|
|
414
|
+
protocolVersion: number | null;
|
|
415
|
+
identity: DeviceStateIdentity;
|
|
416
|
+
status: DeviceStateStatus;
|
|
417
|
+
settings: DeviceStateSettings;
|
|
418
|
+
versions: DeviceStateVersions;
|
|
419
|
+
capabilities: Array<number | string>;
|
|
420
|
+
verification?: Partial<DeviceFeaturesVerify>;
|
|
421
|
+
};
|
|
422
|
+
type DeviceStatePatch = {
|
|
423
|
+
protocol?: DeviceStateProtocol;
|
|
424
|
+
protocolVersion?: number | null;
|
|
425
|
+
identity?: Partial<DeviceStateIdentity>;
|
|
426
|
+
status?: Partial<DeviceStateStatus>;
|
|
427
|
+
settings?: Partial<DeviceStateSettings>;
|
|
428
|
+
versions?: Partial<DeviceStateVersions>;
|
|
429
|
+
capabilities?: Array<number | string>;
|
|
430
|
+
verification?: DeviceFeaturesVerify;
|
|
431
|
+
session?: Partial<DeviceStateSession> | null;
|
|
432
|
+
raw?: DeviceFeaturesRawPatch;
|
|
433
|
+
};
|
|
434
|
+
type DeviceStateEvent = {
|
|
435
|
+
connectId: string | null;
|
|
436
|
+
state: DeviceState;
|
|
437
|
+
revision: number;
|
|
438
|
+
source: DeviceStateUpdateSource;
|
|
439
|
+
changedKeys: string[];
|
|
440
|
+
};
|
|
441
|
+
type NormalizedFeatures = {
|
|
442
|
+
protocol: DeviceFeaturesProtocol;
|
|
443
|
+
protocolVersion?: number | null;
|
|
444
|
+
deviceType: IDeviceType;
|
|
445
|
+
firmwareType: EFirmwareType;
|
|
446
|
+
model: string | null;
|
|
447
|
+
vendor: string | null;
|
|
448
|
+
deviceId: string | null;
|
|
449
|
+
serialNo: string;
|
|
450
|
+
label: string | null;
|
|
451
|
+
bleName: string | null;
|
|
452
|
+
capabilities: Array<number | string>;
|
|
453
|
+
mode: DeviceFeaturesMode;
|
|
454
|
+
initialized: boolean | null;
|
|
455
|
+
bootloaderMode: boolean | null;
|
|
456
|
+
unlocked: boolean | null;
|
|
457
|
+
firmwarePresent: boolean | null;
|
|
458
|
+
passphraseProtection: boolean | null;
|
|
459
|
+
pinProtection: boolean | null;
|
|
460
|
+
backupRequired: boolean | null;
|
|
461
|
+
noBackup: boolean | null;
|
|
462
|
+
unfinishedBackup: boolean | null;
|
|
463
|
+
recoveryMode: boolean | null;
|
|
464
|
+
language: string | null;
|
|
465
|
+
bleEnabled: boolean | null;
|
|
466
|
+
sdCardPresent: boolean | null;
|
|
467
|
+
sdProtection: boolean | null;
|
|
468
|
+
wipeCodeProtection: boolean | null;
|
|
469
|
+
passphraseAlwaysOnDevice: boolean | null;
|
|
470
|
+
attachToPinEnabled?: boolean | null;
|
|
471
|
+
safetyChecks: string | null;
|
|
472
|
+
autoLockDelayMs: number | null;
|
|
473
|
+
autoShutdownDelayMs: number | null;
|
|
474
|
+
displayRotation: number | null;
|
|
475
|
+
experimentalFeatures: boolean | null;
|
|
476
|
+
wallpaperPath: string | null;
|
|
477
|
+
brightness: number | null;
|
|
478
|
+
animationEnabled: boolean | null;
|
|
479
|
+
tapToWake: boolean | null;
|
|
480
|
+
hapticFeedback: boolean | null;
|
|
481
|
+
deviceNameDisplayEnabled: boolean | null;
|
|
482
|
+
airgapMode: boolean | null;
|
|
483
|
+
fidoEnabled: boolean | null;
|
|
484
|
+
usbLockEnabled: boolean | null;
|
|
485
|
+
randomKeypad: boolean | null;
|
|
486
|
+
firmwareVersion: string | null;
|
|
487
|
+
bootloaderVersion: string | null;
|
|
488
|
+
boardVersion: string | null;
|
|
489
|
+
bleVersion: string | null;
|
|
490
|
+
se01Version?: string | null;
|
|
491
|
+
se02Version?: string | null;
|
|
492
|
+
se03Version?: string | null;
|
|
493
|
+
se04Version?: string | null;
|
|
494
|
+
se01BootVersion?: string | null;
|
|
495
|
+
se02BootVersion?: string | null;
|
|
496
|
+
se03BootVersion?: string | null;
|
|
497
|
+
se04BootVersion?: string | null;
|
|
498
|
+
seVersion?: string | null;
|
|
499
|
+
verify?: DeviceFeaturesVerify;
|
|
500
|
+
sessionId: string | null;
|
|
501
|
+
passphraseState?: string;
|
|
502
|
+
unlockedAttachPin?: boolean;
|
|
503
|
+
raw?: DeviceFeaturesRaw;
|
|
504
|
+
};
|
|
505
|
+
type Features = NormalizedFeatures & Partial<Omit<Messages.Features, keyof NormalizedFeatures>> & Partial<Omit<Messages.OnekeyFeatures, keyof NormalizedFeatures | keyof Messages.Features>>;
|
|
506
|
+
type OnekeyFeatures = Messages.OnekeyFeatures;
|
|
507
|
+
type IDeviceType = EDeviceType.Unknown | EDeviceType.Classic | EDeviceType.Classic1s | EDeviceType.ClassicPure | EDeviceType.Mini | EDeviceType.Touch | EDeviceType.Pro | EDeviceType.Pro2;
|
|
508
|
+
type IDeviceModel = 'model_classic' | 'model_mini' | 'model_touch' | 'model_classic1s';
|
|
509
|
+
declare const DeviceModelToTypes: {
|
|
510
|
+
[deviceModel in IDeviceModel]: IDeviceType[];
|
|
511
|
+
};
|
|
512
|
+
declare const DeviceTypeToModels: {
|
|
513
|
+
[deviceType in IDeviceType]: IDeviceModel[];
|
|
514
|
+
};
|
|
515
|
+
type IDeviceFirmwareStatus = 'valid' | 'outdated' | 'required' | 'unknown' | 'none';
|
|
516
|
+
type IDeviceBLEFirmwareStatus = 'valid' | 'outdated' | 'required' | 'unknown' | 'none';
|
|
517
|
+
type ITransportStatus = 'valid' | 'outdated';
|
|
518
|
+
type IVersionRange = {
|
|
519
|
+
min: string;
|
|
520
|
+
max?: string;
|
|
521
|
+
unsupported?: boolean;
|
|
522
|
+
};
|
|
523
|
+
type DeviceFirmwareRange = {
|
|
524
|
+
[deviceType in IDeviceType | IDeviceModel]?: IVersionRange;
|
|
525
|
+
};
|
|
526
|
+
type FeaturesNarrowing = {
|
|
527
|
+
major_version: 2;
|
|
528
|
+
fw_major: null;
|
|
529
|
+
fw_minor: null;
|
|
530
|
+
fw_patch: null;
|
|
531
|
+
bootloader_mode: true;
|
|
532
|
+
firmware_present: false;
|
|
533
|
+
} | {
|
|
534
|
+
major_version: 2;
|
|
535
|
+
fw_major: null;
|
|
536
|
+
fw_minor: null;
|
|
537
|
+
fw_patch: null;
|
|
538
|
+
bootloader_mode: null;
|
|
539
|
+
firmware_present: null;
|
|
540
|
+
} | {
|
|
541
|
+
major_version: 2;
|
|
542
|
+
fw_major: 2;
|
|
543
|
+
fw_minor: number;
|
|
544
|
+
fw_patch: number;
|
|
545
|
+
bootloader_mode: true;
|
|
546
|
+
firmware_present: true;
|
|
547
|
+
} | {
|
|
548
|
+
major_version: 1;
|
|
549
|
+
fw_major: null;
|
|
550
|
+
fw_minor: null;
|
|
551
|
+
fw_patch: null;
|
|
552
|
+
bootloader_mode: true;
|
|
553
|
+
firmware_present: false;
|
|
554
|
+
} | {
|
|
555
|
+
major_version: 1;
|
|
556
|
+
fw_major: null;
|
|
557
|
+
fw_minor: null;
|
|
558
|
+
fw_patch: null;
|
|
559
|
+
bootloader_mode: true;
|
|
560
|
+
firmware_present: true;
|
|
561
|
+
};
|
|
562
|
+
type StrictFeatures = Features & FeaturesNarrowing;
|
|
563
|
+
type SupportFeatureType = {
|
|
564
|
+
support: boolean;
|
|
565
|
+
require?: string;
|
|
566
|
+
};
|
|
567
|
+
type SupportFeatures = {
|
|
568
|
+
inputPinOnSoftware: SupportFeatureType;
|
|
569
|
+
modifyHomescreen: SupportFeatureType;
|
|
570
|
+
};
|
|
571
|
+
|
|
572
|
+
type DeviceStateScope = 'runtime' | 'settings' | 'firmware';
|
|
573
|
+
type GetDeviceStateParams = CommonParams & {
|
|
574
|
+
scope?: DeviceStateScope;
|
|
575
|
+
};
|
|
576
|
+
type DeviceStateReadOptions = {
|
|
577
|
+
refreshSections?: DeviceStateSection[];
|
|
578
|
+
includeRaw?: boolean;
|
|
579
|
+
};
|
|
580
|
+
declare function getDeviceState(connectId?: string, params?: GetDeviceStateParams): Response<DeviceState>;
|
|
581
|
+
|
|
153
582
|
type DeviceDescriptorDiff = {
|
|
154
583
|
didUpdate: boolean;
|
|
155
584
|
connected: OneKeyDeviceInfo[];
|
|
@@ -187,38 +616,40 @@ type InitOptions = {
|
|
|
187
616
|
deriveCardano?: boolean;
|
|
188
617
|
connectProtocol?: HardwareConnectProtocol;
|
|
189
618
|
protocolV2DeviceInfoTimeoutMs?: number;
|
|
619
|
+
refreshRuntimeState?: boolean;
|
|
190
620
|
};
|
|
191
621
|
type RunOptions = {
|
|
192
622
|
keepSession?: boolean;
|
|
193
623
|
skipInitialize?: boolean;
|
|
194
624
|
} & InitOptions;
|
|
195
625
|
interface DeviceEvents {
|
|
196
|
-
[DEVICE.PIN]: [Device
|
|
197
|
-
[DEVICE.PASSPHRASE_ON_DEVICE]: [Device
|
|
198
|
-
[DEVICE.ATTACH_PIN_ON_DEVICE]: [Device
|
|
199
|
-
[DEVICE.BUTTON]: [Device
|
|
200
|
-
[DEVICE.FEATURES]: [Device
|
|
626
|
+
[DEVICE.PIN]: [Device, Messages.PinMatrixRequestType | undefined, (err: any, pin: string) => void];
|
|
627
|
+
[DEVICE.PASSPHRASE_ON_DEVICE]: [Device, PassphraseRequestPayload?];
|
|
628
|
+
[DEVICE.ATTACH_PIN_ON_DEVICE]: [Device, PassphraseRequestPayload?];
|
|
629
|
+
[DEVICE.BUTTON]: [Device, DeviceButtonRequestPayload];
|
|
630
|
+
[DEVICE.FEATURES]: [Device, DeviceFeaturesPayload];
|
|
631
|
+
[DEVICE.STATE]: [Device, DeviceStateEvent];
|
|
201
632
|
[DEVICE.PASSPHRASE]: [
|
|
202
|
-
Device
|
|
633
|
+
Device,
|
|
203
634
|
PassphraseRequestPayload,
|
|
204
635
|
(response: PassphrasePromptResponse, error?: Error) => void
|
|
205
636
|
];
|
|
206
637
|
[DEVICE.SELECT_DEVICE_IN_BOOTLOADER_FOR_WEB_DEVICE]: [
|
|
207
|
-
Device
|
|
638
|
+
Device,
|
|
208
639
|
(err: any, deviceId: string) => void
|
|
209
640
|
];
|
|
210
641
|
[DEVICE.SELECT_DEVICE_FOR_SWITCH_FIRMWARE_WEB_DEVICE]: [
|
|
211
|
-
Device
|
|
642
|
+
Device,
|
|
212
643
|
(err: any, deviceId: string) => void
|
|
213
644
|
];
|
|
214
645
|
}
|
|
215
646
|
declare function preloadSessionCache(deviceId: string, passphraseState: string, sessionId: string): void;
|
|
216
|
-
interface Device
|
|
647
|
+
interface Device {
|
|
217
648
|
on<K extends keyof DeviceEvents>(type: K, listener: (...event: DeviceEvents[K]) => void): this;
|
|
218
649
|
off<K extends keyof DeviceEvents>(type: K, listener: (...event: DeviceEvents[K]) => void): this;
|
|
219
650
|
emit<K extends keyof DeviceEvents>(type: K, ...args: DeviceEvents[K]): boolean;
|
|
220
651
|
}
|
|
221
|
-
declare class Device
|
|
652
|
+
declare class Device extends EventEmitter {
|
|
222
653
|
originalDescriptor: OneKeyDeviceInfo;
|
|
223
654
|
sdkInstanceId?: string;
|
|
224
655
|
instanceId: string;
|
|
@@ -228,8 +659,14 @@ declare class Device$1 extends EventEmitter {
|
|
|
228
659
|
commands: DeviceCommands;
|
|
229
660
|
private cancelableAction?;
|
|
230
661
|
private deviceAcquired;
|
|
231
|
-
|
|
232
|
-
|
|
662
|
+
private stateStore;
|
|
663
|
+
private protocolV2StateNeedsReload;
|
|
664
|
+
get state(): (DeviceState & {
|
|
665
|
+
raw?: DeviceFeaturesRaw | undefined;
|
|
666
|
+
session?: DeviceStateSession | undefined;
|
|
667
|
+
}) | undefined;
|
|
668
|
+
get features(): Features | undefined;
|
|
669
|
+
set features(features: Features | undefined);
|
|
233
670
|
runPromise?: Deferred<void> | null;
|
|
234
671
|
externalState: string[];
|
|
235
672
|
unavailableCapabilities: UnavailableCapabilities;
|
|
@@ -243,8 +680,8 @@ declare class Device$1 extends EventEmitter {
|
|
|
243
680
|
private preInitializeMeta?;
|
|
244
681
|
private lastInitializeDurationMs?;
|
|
245
682
|
constructor(descriptor: OneKeyDeviceInfo, sdkInstanceId?: string);
|
|
246
|
-
static fromDescriptor(originalDescriptor: OneKeyDeviceInfo, sdkInstanceId?: string): Device
|
|
247
|
-
toMessageObject(): Device | null;
|
|
683
|
+
static fromDescriptor(originalDescriptor: OneKeyDeviceInfo, sdkInstanceId?: string): Device;
|
|
684
|
+
toMessageObject(): Device$1 | null;
|
|
248
685
|
connect(connectProtocol?: HardwareConnectProtocol): Promise<boolean>;
|
|
249
686
|
acquire(connectProtocol?: HardwareConnectProtocol, options?: {
|
|
250
687
|
throwOnRunPromiseError?: boolean;
|
|
@@ -287,11 +724,20 @@ declare class Device$1 extends EventEmitter {
|
|
|
287
724
|
initialize(options?: InitOptions): Promise<void>;
|
|
288
725
|
private _initializeProtocolV2;
|
|
289
726
|
getFeatures(): Promise<Features | undefined>;
|
|
727
|
+
getDeviceState(params?: DeviceStateReadOptions): Promise<DeviceState>;
|
|
290
728
|
_updateFeatures(protoFeatures: Messages.Features | Features, initSession?: boolean): void;
|
|
729
|
+
updateState(patch: DeviceStatePatch, source: DeviceStateUpdateSource): DeviceState & {
|
|
730
|
+
raw?: DeviceFeaturesRaw | undefined;
|
|
731
|
+
session?: DeviceStateSession | undefined;
|
|
732
|
+
};
|
|
733
|
+
clearCachedSession(deviceId?: string, passphraseState?: string): boolean;
|
|
734
|
+
updateFeaturesPatch(patch: Partial<Features>, source: DeviceStateUpdateSource): Features | undefined;
|
|
291
735
|
updateProtocolV2Features(deviceInfo?: ProtocolV2DeviceInfo, deviceStatus?: DeviceStatus$1 | null): Features;
|
|
292
736
|
updateProtocolV2Status(status: DeviceStatus$1): Features;
|
|
737
|
+
markTransportDisconnected(): void;
|
|
738
|
+
markProtocolV2Reboot(rebootType: DeviceRebootType): void;
|
|
293
739
|
updateDescriptor(descriptor: OneKeyDeviceInfo, forceUpdate?: boolean): void;
|
|
294
|
-
updateFromCache(device: Device
|
|
740
|
+
updateFromCache(device: Device): void;
|
|
295
741
|
run(fn?: () => Promise<void>, options?: RunOptions): Promise<void>;
|
|
296
742
|
_runInner<T>(fn: (() => Promise<T>) | undefined, options: RunOptions): Promise<undefined>;
|
|
297
743
|
interruptionFromOutside(): Promise<void>;
|
|
@@ -339,540 +785,217 @@ interface SdkTracingContext {
|
|
|
339
785
|
activeRequests: Map<number, RequestContext>;
|
|
340
786
|
}
|
|
341
787
|
declare function createSdkTracingContext(): SdkTracingContext;
|
|
342
|
-
declare function createRequestContext(responseID: number, methodName: string, options?: {
|
|
343
|
-
sdkInstanceId?: string;
|
|
344
|
-
connectId?: string;
|
|
345
|
-
deviceInstanceId?: string;
|
|
346
|
-
commandsInstanceId?: string;
|
|
347
|
-
parentResponseID?: number;
|
|
348
|
-
}): RequestContext;
|
|
349
|
-
declare function updateRequestContext(responseID: number, updates: Partial<RequestContext>): void;
|
|
350
|
-
declare function completeRequestContext(responseID: number, error?: Error): void;
|
|
351
|
-
declare function getActiveRequestsByDeviceInstance(deviceInstanceId: string): RequestContext[];
|
|
352
|
-
declare function formatRequestContext(context: RequestContext): string;
|
|
353
|
-
declare function cleanupSdkInstance(sdkInstanceId: string): void;
|
|
354
|
-
|
|
355
|
-
declare class Core extends EventEmitter {
|
|
356
|
-
private tracingContext;
|
|
357
|
-
readonly sdkInstanceId: string;
|
|
358
|
-
private requestQueue;
|
|
359
|
-
private prePendingCallPromise;
|
|
360
|
-
private methodSynchronize;
|
|
361
|
-
constructor();
|
|
362
|
-
cancelOperation(operationId: string): void;
|
|
363
|
-
private getCoreContext;
|
|
364
|
-
handleMessage(message: CoreMessage): Promise<any>;
|
|
365
|
-
dispose(): void;
|
|
366
|
-
}
|
|
367
|
-
declare const init$1: (settings: ConnectSettings, Transport: any, plugin?: LowlevelTransportSharedPlugin) => Promise<Core | undefined>;
|
|
368
|
-
declare const switchTransport: ({ env, Transport, plugin, }: {
|
|
369
|
-
env: ConnectSettings['env'];
|
|
370
|
-
Transport: any;
|
|
371
|
-
plugin?: LowlevelTransportSharedPlugin | undefined;
|
|
372
|
-
}) => void;
|
|
373
|
-
|
|
374
|
-
type DeviceInfoGetTargets = {
|
|
375
|
-
hw?: boolean;
|
|
376
|
-
fw?: boolean;
|
|
377
|
-
coprocessor?: boolean;
|
|
378
|
-
se1?: boolean;
|
|
379
|
-
se2?: boolean;
|
|
380
|
-
se3?: boolean;
|
|
381
|
-
se4?: boolean;
|
|
382
|
-
status?: boolean;
|
|
383
|
-
};
|
|
384
|
-
type DeviceInfoGetTypes = {
|
|
385
|
-
version?: boolean;
|
|
386
|
-
build_id?: boolean;
|
|
387
|
-
hash?: boolean;
|
|
388
|
-
specific?: boolean;
|
|
389
|
-
};
|
|
390
|
-
type DeviceInfoGetParams = {
|
|
391
|
-
targets?: DeviceInfoGetTargets;
|
|
392
|
-
types?: DeviceInfoGetTypes;
|
|
393
|
-
};
|
|
394
|
-
|
|
395
|
-
type HiddenWalletSelection = {
|
|
396
|
-
host_passphrase: DeviceHostPassphrase;
|
|
397
|
-
passphrase_on_device?: never;
|
|
398
|
-
attach_pin_on_device?: never;
|
|
399
|
-
} | {
|
|
400
|
-
host_passphrase?: never;
|
|
401
|
-
passphrase_on_device: DevicePassphraseOnDevice;
|
|
402
|
-
attach_pin_on_device?: never;
|
|
403
|
-
} | {
|
|
404
|
-
host_passphrase?: never;
|
|
405
|
-
passphrase_on_device?: never;
|
|
406
|
-
attach_pin_on_device: DeviceAttachPinOnDevice;
|
|
407
|
-
};
|
|
408
|
-
type DeviceSessionOpenParams = {
|
|
409
|
-
resume: DeviceSessionResume;
|
|
410
|
-
select?: never;
|
|
411
|
-
} | {
|
|
412
|
-
resume?: never;
|
|
413
|
-
select: HiddenWalletSelection;
|
|
414
|
-
};
|
|
415
|
-
|
|
416
|
-
type DeviceSettingsSetParams = {
|
|
417
|
-
settings?: Omit<DeviceSettings, 'passphrase_enable' | 'airgap_mode'>;
|
|
418
|
-
};
|
|
419
|
-
|
|
420
|
-
type SupportedDeviceSettingsPage = DeviceSettingsPage;
|
|
421
|
-
type DeviceSettingsPageShowParams = {
|
|
422
|
-
page?: SupportedDeviceSettingsPage | 'DeviceReset' | 'DevicePinChange' | 'DevicePassphrase' | 'DeviceAirgap';
|
|
423
|
-
fieldName?: string;
|
|
424
|
-
field_name?: string;
|
|
425
|
-
};
|
|
426
|
-
|
|
427
|
-
declare const PRO2_WALLPAPER_WIDTH = 604;
|
|
428
|
-
declare const PRO2_WALLPAPER_HEIGHT = 1024;
|
|
429
|
-
type Pro2WallpaperColorFormat = 'RGB565' | 'RGB565A8';
|
|
430
|
-
declare function encodePro2Wallpaper(options: {
|
|
431
|
-
width: number;
|
|
432
|
-
height: number;
|
|
433
|
-
rgba: Uint8Array | ArrayBuffer;
|
|
434
|
-
}): {
|
|
435
|
-
data: Uint8Array;
|
|
436
|
-
colorFormat: Pro2WallpaperColorFormat;
|
|
437
|
-
};
|
|
438
|
-
|
|
439
|
-
type DeviceUploadWallpaperParams = {
|
|
440
|
-
width: number;
|
|
441
|
-
height: number;
|
|
442
|
-
rgba: Uint8Array | ArrayBuffer;
|
|
443
|
-
fileName?: string;
|
|
444
|
-
chunkSize?: number;
|
|
445
|
-
};
|
|
446
|
-
type DeviceUploadWallpaperResponse = {
|
|
447
|
-
path: string;
|
|
448
|
-
size: number;
|
|
449
|
-
colorFormat: Pro2WallpaperColorFormat;
|
|
450
|
-
message?: string;
|
|
451
|
-
};
|
|
452
|
-
|
|
453
|
-
type FileOpSuccess = {
|
|
454
|
-
message?: string;
|
|
455
|
-
};
|
|
456
|
-
type FileInfo = {
|
|
457
|
-
path: string;
|
|
458
|
-
offset: number;
|
|
459
|
-
total_size: number;
|
|
460
|
-
data?: Uint8Array;
|
|
461
|
-
data_hash?: number;
|
|
462
|
-
processed_byte?: number;
|
|
463
|
-
chunks?: number;
|
|
464
|
-
};
|
|
465
|
-
type DirInfo = {
|
|
466
|
-
path: string;
|
|
467
|
-
child_dirs?: string;
|
|
468
|
-
child_files?: string;
|
|
469
|
-
};
|
|
470
|
-
type PathInfoResult = {
|
|
471
|
-
exist: boolean;
|
|
472
|
-
size: number;
|
|
473
|
-
year: number;
|
|
474
|
-
month: number;
|
|
475
|
-
day: number;
|
|
476
|
-
hour: number;
|
|
477
|
-
minute: number;
|
|
478
|
-
second: number;
|
|
479
|
-
readonly: boolean;
|
|
480
|
-
hidden: boolean;
|
|
481
|
-
system: boolean;
|
|
482
|
-
archive: boolean;
|
|
483
|
-
directory: boolean;
|
|
484
|
-
};
|
|
485
|
-
declare function protocolInfoRequest(connectId: string, params?: CommonParams): Response<ProtocolInfo>;
|
|
486
|
-
declare function ping(connectId: string, params?: CommonParams & {
|
|
487
|
-
message?: string;
|
|
488
|
-
}): Response<Success$1>;
|
|
489
|
-
declare function deviceReboot(connectId: string, params: CommonParams & DeviceRebootParams): Response<Success$1>;
|
|
490
|
-
declare function deviceInfoGet(connectId: string, params?: CommonParams & DeviceInfoGetParams): Response<ProtocolV2DeviceInfo>;
|
|
491
|
-
declare function deviceStatusGet(connectId: string, params?: CommonParams): Response<DeviceStatus$1>;
|
|
492
|
-
declare function deviceGetOnboardingStatus(connectId: string, params?: CommonParams): Response<DevOnboardingStatus>;
|
|
493
|
-
declare function deviceSessionOpen(connectId: string, params: CommonParams & DeviceSessionOpenParams): Response<DeviceSession>;
|
|
494
|
-
declare function deviceFirmwareUpdate(connectId: string, params: CommonParams & DeviceFirmwareUpdateParams): Response<Success$1 | DeviceFirmwareUpdateStatus>;
|
|
495
|
-
declare function deviceGetFirmwareUpdateStatus(connectId: string, params?: CommonParams & DeviceFirmwareUpdateStatusGetParams): Response<DeviceFirmwareUpdateStatus>;
|
|
496
|
-
declare function deviceFactoryInfoSet(connectId: string, params: CommonParams & DeviceFactoryInfoSetParams): Response<Success$1>;
|
|
497
|
-
declare function deviceFactoryInfoGet(connectId: string, params?: CommonParams): Response<DeviceFactoryInfo>;
|
|
498
|
-
declare function deviceSettingsGet(connectId: string, params?: CommonParams): Response<DeviceSettings>;
|
|
499
|
-
declare function deviceSettingsSet(connectId: string, params: CommonParams & DeviceSettingsSetParams): Response<Success$1>;
|
|
500
|
-
declare function deviceSettingsPageShow(connectId: string, params: CommonParams & DeviceSettingsPageShowParams): Response<Success$1>;
|
|
501
|
-
declare function deviceUploadWallpaper(connectId: string, params: CommonParams & DeviceUploadWallpaperParams): Response<DeviceUploadWallpaperResponse>;
|
|
502
|
-
declare function filesystemPermissionFix(connectId: string, params?: CommonParams): Response<Success$1>;
|
|
503
|
-
declare function fileRead(connectId: string, params: {
|
|
504
|
-
path: string;
|
|
505
|
-
offset?: number;
|
|
506
|
-
totalSize?: number;
|
|
507
|
-
chunkLen?: number;
|
|
508
|
-
uiPercentage?: number;
|
|
509
|
-
}): Response<FileInfo>;
|
|
510
|
-
declare function fileWrite(connectId: string, params: {
|
|
511
|
-
path: string;
|
|
512
|
-
offset?: number;
|
|
513
|
-
totalSize?: number;
|
|
514
|
-
chunkSize?: number;
|
|
515
|
-
chunkLen?: number;
|
|
516
|
-
data: ArrayBuffer | Uint8Array | Blob | string;
|
|
517
|
-
overwrite?: boolean;
|
|
518
|
-
append?: boolean;
|
|
519
|
-
uiPercentage?: number;
|
|
520
|
-
timeoutMs?: number | string;
|
|
521
|
-
}): Response<FileInfo>;
|
|
522
|
-
declare function fileDelete(connectId: string, params: {
|
|
523
|
-
path: string;
|
|
524
|
-
}): Response<FileOpSuccess>;
|
|
525
|
-
declare function dirList(connectId: string, params: {
|
|
526
|
-
path: string;
|
|
527
|
-
depth?: number;
|
|
528
|
-
}): Response<DirInfo>;
|
|
529
|
-
declare function dirMake(connectId: string, params: {
|
|
530
|
-
path: string;
|
|
531
|
-
}): Response<FileOpSuccess>;
|
|
532
|
-
declare function dirRemove(connectId: string, params: {
|
|
533
|
-
path: string;
|
|
534
|
-
}): Response<FileOpSuccess>;
|
|
535
|
-
declare function pathInfo(connectId: string, params: {
|
|
536
|
-
path: string;
|
|
537
|
-
timeoutMs?: number | string;
|
|
538
|
-
}): Response<PathInfoResult>;
|
|
539
|
-
declare const filesystemFileRead: typeof fileRead;
|
|
540
|
-
declare const filesystemFileWrite: typeof fileWrite;
|
|
541
|
-
declare function uploadPortfolio(connectId: string, params: {
|
|
542
|
-
operationId?: string;
|
|
543
|
-
packageBytes: ArrayBuffer | Uint8Array | Blob;
|
|
544
|
-
timeoutMs?: number | string;
|
|
545
|
-
}): Response<FileInfo & {
|
|
546
|
-
portfolioUpdated: true;
|
|
547
|
-
}>;
|
|
548
|
-
declare const filesystemFileDelete: typeof fileDelete;
|
|
549
|
-
declare const filesystemDirList: typeof dirList;
|
|
550
|
-
declare const filesystemDirMake: typeof dirMake;
|
|
551
|
-
declare const filesystemDirRemove: typeof dirRemove;
|
|
552
|
-
declare const filesystemPathInfoQuery: typeof pathInfo;
|
|
553
|
-
declare function filesystemFormat(connectId: string): Response<Success$1>;
|
|
554
|
-
|
|
555
|
-
declare const on: <T extends string, P extends (...args: any[]) => any>(type: T, fn: P) => void;
|
|
556
|
-
declare const off: (type: any, fn: any) => void;
|
|
557
|
-
declare const removeAllListeners: (type: any) => void;
|
|
558
|
-
|
|
559
|
-
declare function uiResponse(response: UiResponseEvent): void;
|
|
560
|
-
|
|
561
|
-
type IAddHardwareGlobalEventListener = (coreMessage: CoreMessage) => void;
|
|
562
|
-
interface LowLevelInjectApi {
|
|
563
|
-
call: CallMethod;
|
|
564
|
-
eventEmitter: EventEmitter$1;
|
|
565
|
-
init: CoreApi['init'];
|
|
566
|
-
dispose: CoreApi['dispose'];
|
|
567
|
-
uiResponse: CoreApi['uiResponse'];
|
|
568
|
-
cancel: CoreApi['cancel'];
|
|
569
|
-
cancelOperation: CoreApi['cancelOperation'];
|
|
570
|
-
updateSettings: CoreApi['updateSettings'];
|
|
571
|
-
switchTransport: CoreApi['switchTransport'];
|
|
572
|
-
addHardwareGlobalEventListener: (listener: IAddHardwareGlobalEventListener) => void;
|
|
573
|
-
}
|
|
574
|
-
type LowLevelCoreApi = Omit<CoreApi, 'on' | 'off'> & {
|
|
575
|
-
addHardwareGlobalEventListener: (listener: IAddHardwareGlobalEventListener) => void;
|
|
576
|
-
};
|
|
577
|
-
|
|
578
|
-
type DeviceStatus = 'available' | 'occupied' | 'used';
|
|
579
|
-
declare enum EOneKeyDeviceMode {
|
|
580
|
-
bootloader = "bootloader",
|
|
581
|
-
normal = "normal",
|
|
582
|
-
notInitialized = "notInitialized",
|
|
583
|
-
backupMode = "backupMode"
|
|
584
|
-
}
|
|
585
|
-
type UnavailableCapability = 'no-capability' | 'no-support' | 'update-required' | 'trezor-connect-outdated';
|
|
586
|
-
type UnavailableCapabilities = {
|
|
587
|
-
[key: string]: UnavailableCapability;
|
|
588
|
-
};
|
|
589
|
-
type KnownDevice = {
|
|
590
|
-
connectId: string | null;
|
|
591
|
-
uuid: string;
|
|
592
|
-
deviceId: string | null;
|
|
593
|
-
deviceType: IDeviceType | null;
|
|
594
|
-
commType: OneKeyDeviceCommType | null;
|
|
595
|
-
path: string;
|
|
596
|
-
label: string;
|
|
597
|
-
bleName: string | null;
|
|
598
|
-
name: string;
|
|
599
|
-
error?: typeof undefined;
|
|
600
|
-
mode: EOneKeyDeviceMode;
|
|
601
|
-
features?: Features;
|
|
602
|
-
sessionId?: string | null;
|
|
603
|
-
unavailableCapabilities: UnavailableCapabilities;
|
|
604
|
-
bleFirmwareVersion: IVersionArray | null;
|
|
605
|
-
firmwareVersion: IVersionArray | null;
|
|
606
|
-
instanceId?: string;
|
|
788
|
+
declare function createRequestContext(responseID: number, methodName: string, options?: {
|
|
607
789
|
sdkInstanceId?: string;
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
se03BootBuildId?: string;
|
|
643
|
-
se03BootHash?: string;
|
|
644
|
-
se04BootBuildId?: string;
|
|
645
|
-
se04BootHash?: string;
|
|
646
|
-
};
|
|
647
|
-
type DeviceFeaturesRaw = {
|
|
648
|
-
protocolV1Features?: Messages.Features;
|
|
649
|
-
protocolV1OneKeyFeatures?: OnekeyFeatures;
|
|
650
|
-
protocolV2DeviceInfo?: ProtocolV2DeviceInfo;
|
|
651
|
-
protocolV2DeviceStatus?: DeviceStatus$1;
|
|
652
|
-
};
|
|
653
|
-
type NormalizedFeatures = {
|
|
654
|
-
protocol: DeviceFeaturesProtocol;
|
|
655
|
-
protocolVersion?: number | null;
|
|
656
|
-
deviceType: IDeviceType;
|
|
657
|
-
firmwareType: EFirmwareType;
|
|
658
|
-
model: string | null;
|
|
659
|
-
vendor: string | null;
|
|
660
|
-
deviceId: string | null;
|
|
661
|
-
serialNo: string;
|
|
662
|
-
label: string | null;
|
|
663
|
-
bleName: string | null;
|
|
664
|
-
capabilities: Array<number | string>;
|
|
665
|
-
mode: DeviceFeaturesMode;
|
|
666
|
-
initialized: boolean | null;
|
|
667
|
-
bootloaderMode: boolean | null;
|
|
668
|
-
unlocked: boolean | null;
|
|
669
|
-
firmwarePresent: boolean | null;
|
|
670
|
-
passphraseProtection: boolean | null;
|
|
671
|
-
pinProtection: boolean | null;
|
|
672
|
-
backupRequired: boolean | null;
|
|
673
|
-
noBackup: boolean | null;
|
|
674
|
-
unfinishedBackup: boolean | null;
|
|
675
|
-
recoveryMode: boolean | null;
|
|
676
|
-
language: string | null;
|
|
677
|
-
bleEnabled: boolean | null;
|
|
678
|
-
sdCardPresent: boolean | null;
|
|
679
|
-
sdProtection: boolean | null;
|
|
680
|
-
wipeCodeProtection: boolean | null;
|
|
681
|
-
passphraseAlwaysOnDevice: boolean | null;
|
|
682
|
-
attachToPinEnabled?: boolean | null;
|
|
683
|
-
safetyChecks: string | null;
|
|
684
|
-
autoLockDelayMs: number | null;
|
|
685
|
-
displayRotation: number | null;
|
|
686
|
-
experimentalFeatures: boolean | null;
|
|
687
|
-
firmwareVersion: string | null;
|
|
688
|
-
bootloaderVersion: string | null;
|
|
689
|
-
boardVersion: string | null;
|
|
690
|
-
bleVersion: string | null;
|
|
691
|
-
se01Version?: string | null;
|
|
692
|
-
se02Version?: string | null;
|
|
693
|
-
se03Version?: string | null;
|
|
694
|
-
se04Version?: string | null;
|
|
695
|
-
se01BootVersion?: string | null;
|
|
696
|
-
se02BootVersion?: string | null;
|
|
697
|
-
se03BootVersion?: string | null;
|
|
698
|
-
se04BootVersion?: string | null;
|
|
699
|
-
seVersion?: string | null;
|
|
700
|
-
verify?: DeviceFeaturesVerify;
|
|
701
|
-
sessionId: string | null;
|
|
702
|
-
passphraseState?: string;
|
|
703
|
-
unlockedAttachPin?: boolean;
|
|
704
|
-
raw?: DeviceFeaturesRaw;
|
|
705
|
-
};
|
|
706
|
-
type Features = NormalizedFeatures & Partial<Omit<Messages.Features, keyof NormalizedFeatures>> & Partial<Omit<Messages.OnekeyFeatures, keyof NormalizedFeatures | keyof Messages.Features>>;
|
|
707
|
-
type OnekeyFeatures = Messages.OnekeyFeatures;
|
|
708
|
-
type IDeviceType = EDeviceType.Unknown | EDeviceType.Classic | EDeviceType.Classic1s | EDeviceType.ClassicPure | EDeviceType.Mini | EDeviceType.Touch | EDeviceType.Pro | EDeviceType.Pro2;
|
|
709
|
-
type IDeviceModel = 'model_classic' | 'model_mini' | 'model_touch' | 'model_classic1s';
|
|
710
|
-
declare const DeviceModelToTypes: {
|
|
711
|
-
[deviceModel in IDeviceModel]: IDeviceType[];
|
|
712
|
-
};
|
|
713
|
-
declare const DeviceTypeToModels: {
|
|
714
|
-
[deviceType in IDeviceType]: IDeviceModel[];
|
|
715
|
-
};
|
|
716
|
-
type IDeviceFirmwareStatus = 'valid' | 'outdated' | 'required' | 'unknown' | 'none';
|
|
717
|
-
type IDeviceBLEFirmwareStatus = 'valid' | 'outdated' | 'required' | 'unknown' | 'none';
|
|
718
|
-
type ITransportStatus = 'valid' | 'outdated';
|
|
719
|
-
type IVersionRange = {
|
|
720
|
-
min: string;
|
|
721
|
-
max?: string;
|
|
722
|
-
unsupported?: boolean;
|
|
723
|
-
};
|
|
724
|
-
type DeviceFirmwareRange = {
|
|
725
|
-
[deviceType in IDeviceType | IDeviceModel]?: IVersionRange;
|
|
726
|
-
};
|
|
727
|
-
type FeaturesNarrowing = {
|
|
728
|
-
major_version: 2;
|
|
729
|
-
fw_major: null;
|
|
730
|
-
fw_minor: null;
|
|
731
|
-
fw_patch: null;
|
|
732
|
-
bootloader_mode: true;
|
|
733
|
-
firmware_present: false;
|
|
734
|
-
} | {
|
|
735
|
-
major_version: 2;
|
|
736
|
-
fw_major: null;
|
|
737
|
-
fw_minor: null;
|
|
738
|
-
fw_patch: null;
|
|
739
|
-
bootloader_mode: null;
|
|
740
|
-
firmware_present: null;
|
|
790
|
+
connectId?: string;
|
|
791
|
+
deviceInstanceId?: string;
|
|
792
|
+
commandsInstanceId?: string;
|
|
793
|
+
parentResponseID?: number;
|
|
794
|
+
}): RequestContext;
|
|
795
|
+
declare function updateRequestContext(responseID: number, updates: Partial<RequestContext>): void;
|
|
796
|
+
declare function completeRequestContext(responseID: number, error?: Error): void;
|
|
797
|
+
declare function getActiveRequestsByDeviceInstance(deviceInstanceId: string): RequestContext[];
|
|
798
|
+
declare function formatRequestContext(context: RequestContext): string;
|
|
799
|
+
declare function cleanupSdkInstance(sdkInstanceId: string): void;
|
|
800
|
+
|
|
801
|
+
declare class Core extends EventEmitter {
|
|
802
|
+
private tracingContext;
|
|
803
|
+
readonly sdkInstanceId: string;
|
|
804
|
+
private requestQueue;
|
|
805
|
+
private prePendingCallPromise;
|
|
806
|
+
private methodSynchronize;
|
|
807
|
+
constructor();
|
|
808
|
+
cancelOperation(operationId: string): void;
|
|
809
|
+
private getCoreContext;
|
|
810
|
+
handleMessage(message: CoreMessage): Promise<any>;
|
|
811
|
+
dispose(): void;
|
|
812
|
+
}
|
|
813
|
+
declare const init$1: (settings: ConnectSettings, Transport: any, plugin?: LowlevelTransportSharedPlugin) => Promise<Core | undefined>;
|
|
814
|
+
declare const switchTransport: ({ env, Transport, plugin, }: {
|
|
815
|
+
env: ConnectSettings['env'];
|
|
816
|
+
Transport: any;
|
|
817
|
+
plugin?: LowlevelTransportSharedPlugin | undefined;
|
|
818
|
+
}) => void;
|
|
819
|
+
|
|
820
|
+
type HiddenWalletSelection = {
|
|
821
|
+
host_passphrase: DeviceHostPassphrase;
|
|
822
|
+
passphrase_on_device?: never;
|
|
823
|
+
attach_pin_on_device?: never;
|
|
741
824
|
} | {
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
fw_patch: number;
|
|
746
|
-
bootloader_mode: true;
|
|
747
|
-
firmware_present: true;
|
|
825
|
+
host_passphrase?: never;
|
|
826
|
+
passphrase_on_device: DevicePassphraseOnDevice;
|
|
827
|
+
attach_pin_on_device?: never;
|
|
748
828
|
} | {
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
829
|
+
host_passphrase?: never;
|
|
830
|
+
passphrase_on_device?: never;
|
|
831
|
+
attach_pin_on_device: DeviceAttachPinOnDevice;
|
|
832
|
+
};
|
|
833
|
+
type DeviceSessionOpenParams = {
|
|
834
|
+
resume: DeviceSessionResume;
|
|
835
|
+
select?: never;
|
|
755
836
|
} | {
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
fw_minor: null;
|
|
759
|
-
fw_patch: null;
|
|
760
|
-
bootloader_mode: true;
|
|
761
|
-
firmware_present: true;
|
|
837
|
+
resume?: never;
|
|
838
|
+
select: HiddenWalletSelection;
|
|
762
839
|
};
|
|
763
|
-
|
|
764
|
-
type
|
|
765
|
-
|
|
766
|
-
require?: string;
|
|
840
|
+
|
|
841
|
+
type DeviceSettingsSetParams = {
|
|
842
|
+
settings?: Omit<DeviceSettings, 'passphrase_enable' | 'airgap_mode'>;
|
|
767
843
|
};
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
844
|
+
|
|
845
|
+
type SupportedDeviceSettingsPage = DeviceSettingsPage;
|
|
846
|
+
type DeviceSettingsPageShowParams = {
|
|
847
|
+
page?: SupportedDeviceSettingsPage | 'DeviceReset' | 'DevicePinChange' | 'DevicePassphrase' | 'DeviceAirgap';
|
|
848
|
+
fieldName?: string;
|
|
849
|
+
field_name?: string;
|
|
771
850
|
};
|
|
772
851
|
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
version: string;
|
|
784
|
-
priority: number;
|
|
785
|
-
trustedHost: boolean;
|
|
786
|
-
supportedBrowser?: boolean;
|
|
787
|
-
env: transportEnv;
|
|
788
|
-
timestamp: number;
|
|
789
|
-
isFrame?: boolean;
|
|
790
|
-
preRelease?: boolean;
|
|
791
|
-
fetchConfig?: boolean;
|
|
792
|
-
extension?: string;
|
|
793
|
-
configFetcher?: (url: string) => Promise<RemoteConfigResponse | null>;
|
|
852
|
+
declare const PRO2_WALLPAPER_WIDTH = 604;
|
|
853
|
+
declare const PRO2_WALLPAPER_HEIGHT = 1024;
|
|
854
|
+
type Pro2WallpaperColorFormat = 'RGB565' | 'RGB565A8';
|
|
855
|
+
declare function encodePro2Wallpaper(options: {
|
|
856
|
+
width: number;
|
|
857
|
+
height: number;
|
|
858
|
+
rgba: Uint8Array | ArrayBuffer;
|
|
859
|
+
}): {
|
|
860
|
+
data: Uint8Array;
|
|
861
|
+
colorFormat: Pro2WallpaperColorFormat;
|
|
794
862
|
};
|
|
795
|
-
|
|
796
|
-
type
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
version?: IVersionArray;
|
|
863
|
+
|
|
864
|
+
type DeviceUploadWallpaperParams = {
|
|
865
|
+
width: number;
|
|
866
|
+
height: number;
|
|
867
|
+
rgba: Uint8Array | ArrayBuffer;
|
|
868
|
+
fileName?: string;
|
|
869
|
+
chunkSize?: number;
|
|
803
870
|
};
|
|
804
|
-
type
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
payloadHash?: string;
|
|
810
|
-
headerHash?: string;
|
|
871
|
+
type DeviceUploadWallpaperResponse = {
|
|
872
|
+
path: string;
|
|
873
|
+
size: number;
|
|
874
|
+
colorFormat: Pro2WallpaperColorFormat;
|
|
875
|
+
message?: string;
|
|
811
876
|
};
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
firmwareType?: EFirmwareType;
|
|
816
|
-
resource?: string;
|
|
817
|
-
fullResource?: string;
|
|
818
|
-
fullResourceRange?: string[];
|
|
819
|
-
bootloaderResource?: string;
|
|
820
|
-
bootloaderVersion?: IVersionArray;
|
|
821
|
-
displayBootloaderVersion?: IVersionArray;
|
|
822
|
-
bootloaderRelatedFirmwareVersion?: IVersionArray;
|
|
823
|
-
upgradeType?: 'payload-package-set' | string;
|
|
824
|
-
components?: Record<string, IProtocolV2FirmwareComponent>;
|
|
825
|
-
installOrder?: string[];
|
|
826
|
-
resourceBundles?: IProtocolV2ResourceBundle[];
|
|
827
|
-
bootloaderChangelog?: {
|
|
828
|
-
[k in ILocale]: string;
|
|
829
|
-
};
|
|
830
|
-
fingerprint: string;
|
|
831
|
-
version: IVersionArray;
|
|
832
|
-
changelog: {
|
|
833
|
-
[k in ILocale]: string;
|
|
834
|
-
};
|
|
877
|
+
|
|
878
|
+
type FileOpSuccess = {
|
|
879
|
+
message?: string;
|
|
835
880
|
};
|
|
836
|
-
type
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
[k in ILocale]: string;
|
|
845
|
-
};
|
|
881
|
+
type FileInfo = {
|
|
882
|
+
path: string;
|
|
883
|
+
offset: number;
|
|
884
|
+
total_size: number;
|
|
885
|
+
data?: Uint8Array;
|
|
886
|
+
data_hash?: number;
|
|
887
|
+
processed_byte?: number;
|
|
888
|
+
chunks?: number;
|
|
846
889
|
};
|
|
847
|
-
type
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
'firmware-v1'?: IFirmwareReleaseInfo[];
|
|
852
|
-
'firmware-v2'?: IFirmwareReleaseInfo[];
|
|
853
|
-
'firmware-v8'?: IFirmwareReleaseInfo[];
|
|
854
|
-
'firmware-btc-v8'?: IFirmwareReleaseInfo[];
|
|
855
|
-
ble: IBLEFirmwareReleaseInfo[];
|
|
856
|
-
};
|
|
890
|
+
type DirInfo = {
|
|
891
|
+
path: string;
|
|
892
|
+
child_dirs?: string;
|
|
893
|
+
child_files?: string;
|
|
857
894
|
};
|
|
858
|
-
type
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
895
|
+
type PathInfoResult = {
|
|
896
|
+
exist: boolean;
|
|
897
|
+
size: number;
|
|
898
|
+
year: number;
|
|
899
|
+
month: number;
|
|
900
|
+
day: number;
|
|
901
|
+
hour: number;
|
|
902
|
+
minute: number;
|
|
903
|
+
second: number;
|
|
904
|
+
readonly: boolean;
|
|
905
|
+
hidden: boolean;
|
|
906
|
+
system: boolean;
|
|
907
|
+
archive: boolean;
|
|
908
|
+
directory: boolean;
|
|
909
|
+
};
|
|
910
|
+
declare function protocolInfoRequest(connectId: string, params?: CommonParams): Response<ProtocolInfo>;
|
|
911
|
+
declare function ping(connectId: string, params?: CommonParams & {
|
|
912
|
+
message?: string;
|
|
913
|
+
}): Response<Success$1>;
|
|
914
|
+
declare function deviceReboot(connectId: string, params: CommonParams & DeviceRebootParams): Response<Success$1>;
|
|
915
|
+
declare function deviceGetOnboardingStatus(connectId: string, params?: CommonParams): Response<DevOnboardingStatus>;
|
|
916
|
+
declare function deviceSessionOpen(connectId: string, params: CommonParams & DeviceSessionOpenParams): Response<DeviceSession>;
|
|
917
|
+
declare function deviceFirmwareUpdate(connectId: string, params: CommonParams & DeviceFirmwareUpdateParams): Response<Success$1 | DeviceFirmwareUpdateStatus>;
|
|
918
|
+
declare function deviceGetFirmwareUpdateStatus(connectId: string, params?: CommonParams & DeviceFirmwareUpdateStatusGetParams): Response<DeviceFirmwareUpdateStatus>;
|
|
919
|
+
declare function deviceFactoryInfoSet(connectId: string, params: CommonParams & DeviceFactoryInfoSetParams): Response<Success$1>;
|
|
920
|
+
declare function deviceFactoryInfoGet(connectId: string, params?: CommonParams): Response<DeviceFactoryInfo>;
|
|
921
|
+
declare function deviceSettingsSet(connectId: string, params: CommonParams & DeviceSettingsSetParams): Response<Success$1>;
|
|
922
|
+
declare function deviceSettingsPageShow(connectId: string, params: CommonParams & DeviceSettingsPageShowParams): Response<Success$1>;
|
|
923
|
+
declare function deviceUploadWallpaper(connectId: string, params: CommonParams & DeviceUploadWallpaperParams): Response<DeviceUploadWallpaperResponse>;
|
|
924
|
+
declare function filesystemPermissionFix(connectId: string, params?: CommonParams): Response<Success$1>;
|
|
925
|
+
declare function fileRead(connectId: string, params: {
|
|
926
|
+
path: string;
|
|
927
|
+
offset?: number;
|
|
928
|
+
totalSize?: number;
|
|
929
|
+
chunkLen?: number;
|
|
930
|
+
uiPercentage?: number;
|
|
931
|
+
}): Response<FileInfo>;
|
|
932
|
+
declare function fileWrite(connectId: string, params: {
|
|
933
|
+
path: string;
|
|
934
|
+
offset?: number;
|
|
935
|
+
totalSize?: number;
|
|
936
|
+
chunkSize?: number;
|
|
937
|
+
chunkLen?: number;
|
|
938
|
+
data: ArrayBuffer | Uint8Array | Blob | string;
|
|
939
|
+
overwrite?: boolean;
|
|
940
|
+
append?: boolean;
|
|
941
|
+
uiPercentage?: number;
|
|
942
|
+
timeoutMs?: number | string;
|
|
943
|
+
}): Response<FileInfo>;
|
|
944
|
+
declare function fileDelete(connectId: string, params: {
|
|
945
|
+
path: string;
|
|
946
|
+
}): Response<FileOpSuccess>;
|
|
947
|
+
declare function dirList(connectId: string, params: {
|
|
948
|
+
path: string;
|
|
949
|
+
depth?: number;
|
|
950
|
+
}): Response<DirInfo>;
|
|
951
|
+
declare function dirMake(connectId: string, params: {
|
|
952
|
+
path: string;
|
|
953
|
+
}): Response<FileOpSuccess>;
|
|
954
|
+
declare function dirRemove(connectId: string, params: {
|
|
955
|
+
path: string;
|
|
956
|
+
}): Response<FileOpSuccess>;
|
|
957
|
+
declare function pathInfo(connectId: string, params: {
|
|
958
|
+
path: string;
|
|
959
|
+
timeoutMs?: number | string;
|
|
960
|
+
}): Response<PathInfoResult>;
|
|
961
|
+
declare const filesystemFileRead: typeof fileRead;
|
|
962
|
+
declare const filesystemFileWrite: typeof fileWrite;
|
|
963
|
+
declare function uploadPortfolio(connectId: string, params: {
|
|
964
|
+
operationId?: string;
|
|
965
|
+
packageBytes: ArrayBuffer | Uint8Array | Blob;
|
|
966
|
+
timeoutMs?: number | string;
|
|
967
|
+
}): Response<FileInfo & {
|
|
968
|
+
portfolioUpdated: true;
|
|
969
|
+
}>;
|
|
970
|
+
declare const filesystemFileDelete: typeof fileDelete;
|
|
971
|
+
declare const filesystemDirList: typeof dirList;
|
|
972
|
+
declare const filesystemDirMake: typeof dirMake;
|
|
973
|
+
declare const filesystemDirRemove: typeof dirRemove;
|
|
974
|
+
declare const filesystemPathInfoQuery: typeof pathInfo;
|
|
975
|
+
declare function filesystemFormat(connectId: string): Response<Success$1>;
|
|
976
|
+
|
|
977
|
+
declare const on: <T extends string, P extends (...args: any[]) => any>(type: T, fn: P) => void;
|
|
978
|
+
declare const off: (type: any, fn: any) => void;
|
|
979
|
+
declare const removeAllListeners: (type: any) => void;
|
|
980
|
+
|
|
981
|
+
declare function uiResponse(response: UiResponseEvent): void;
|
|
982
|
+
|
|
983
|
+
type IAddHardwareGlobalEventListener = (coreMessage: CoreMessage) => void;
|
|
984
|
+
interface LowLevelInjectApi {
|
|
985
|
+
call: CallMethod;
|
|
986
|
+
eventEmitter: EventEmitter$1;
|
|
987
|
+
init: CoreApi['init'];
|
|
988
|
+
dispose: CoreApi['dispose'];
|
|
989
|
+
uiResponse: CoreApi['uiResponse'];
|
|
990
|
+
cancel: CoreApi['cancel'];
|
|
991
|
+
cancelOperation: CoreApi['cancelOperation'];
|
|
992
|
+
updateSettings: CoreApi['updateSettings'];
|
|
993
|
+
switchTransport: CoreApi['switchTransport'];
|
|
994
|
+
addHardwareGlobalEventListener: (listener: IAddHardwareGlobalEventListener) => void;
|
|
995
|
+
}
|
|
996
|
+
type LowLevelCoreApi = Omit<CoreApi, 'on' | 'off'> & {
|
|
997
|
+
addHardwareGlobalEventListener: (listener: IAddHardwareGlobalEventListener) => void;
|
|
872
998
|
};
|
|
873
|
-
type RemoteConfigResponse = {
|
|
874
|
-
bridge: AssetsMap['bridge'];
|
|
875
|
-
} & DeviceTypeMap;
|
|
876
999
|
|
|
877
1000
|
declare function init(settings: Partial<ConnectSettings>, lowLevelApi?: LowLevelCoreApi, pulgin?: LowlevelTransportSharedPlugin): Promise<boolean>;
|
|
878
1001
|
declare function updateSettings(settings: Partial<ConnectSettings>): Promise<boolean>;
|
|
@@ -948,90 +1071,6 @@ declare function searchDevices(params?: CommonParams): Response<SearchDevice[]>;
|
|
|
948
1071
|
|
|
949
1072
|
declare function getFeatures(connectId?: string, params?: CommonParams): Response<Features>;
|
|
950
1073
|
|
|
951
|
-
type DeviceInfoProtocol = ProtocolType | 'unknown';
|
|
952
|
-
type DeviceInfoSource = 'features' | 'protocolV1OneKeyFeatures' | 'deviceInfo';
|
|
953
|
-
type DeviceInfoScope = 'basic' | 'versions' | 'verify' | 'full';
|
|
954
|
-
type GetDeviceInfoParams = {
|
|
955
|
-
scope?: DeviceInfoScope;
|
|
956
|
-
refresh?: boolean;
|
|
957
|
-
includeRaw?: boolean;
|
|
958
|
-
};
|
|
959
|
-
type DeviceInfoMode = 'normal' | 'bootloader' | 'romloader' | 'notInitialized' | 'unknown';
|
|
960
|
-
type DeviceInfoStatus = {
|
|
961
|
-
mode: DeviceInfoMode;
|
|
962
|
-
initialized: boolean | null;
|
|
963
|
-
bootloaderMode: boolean | null;
|
|
964
|
-
unlocked: boolean | null;
|
|
965
|
-
passphraseProtection: boolean | null;
|
|
966
|
-
attachToPinEnabled?: boolean | null;
|
|
967
|
-
unlockedAttachPin?: boolean | null;
|
|
968
|
-
backupRequired: boolean | null;
|
|
969
|
-
noBackup: boolean | null;
|
|
970
|
-
language: string | null;
|
|
971
|
-
bleEnabled: boolean | null;
|
|
972
|
-
};
|
|
973
|
-
type DeviceProfileVersions = {
|
|
974
|
-
firmware: string | null;
|
|
975
|
-
bootloader: string | null;
|
|
976
|
-
board: string | null;
|
|
977
|
-
ble: string | null;
|
|
978
|
-
se01?: string | null;
|
|
979
|
-
se02?: string | null;
|
|
980
|
-
se03?: string | null;
|
|
981
|
-
se04?: string | null;
|
|
982
|
-
se01Boot?: string | null;
|
|
983
|
-
se02Boot?: string | null;
|
|
984
|
-
se03Boot?: string | null;
|
|
985
|
-
se04Boot?: string | null;
|
|
986
|
-
};
|
|
987
|
-
type DeviceProfileVerify = {
|
|
988
|
-
firmwareBuildId?: string;
|
|
989
|
-
firmwareHash?: string;
|
|
990
|
-
bootloaderBuildId?: string;
|
|
991
|
-
bootloaderHash?: string;
|
|
992
|
-
boardBuildId?: string;
|
|
993
|
-
boardHash?: string;
|
|
994
|
-
bleBuildId?: string;
|
|
995
|
-
bleHash?: string;
|
|
996
|
-
se01BuildId?: string;
|
|
997
|
-
se01Hash?: string;
|
|
998
|
-
se02BuildId?: string;
|
|
999
|
-
se02Hash?: string;
|
|
1000
|
-
se03BuildId?: string;
|
|
1001
|
-
se03Hash?: string;
|
|
1002
|
-
se04BuildId?: string;
|
|
1003
|
-
se04Hash?: string;
|
|
1004
|
-
se01BootBuildId?: string;
|
|
1005
|
-
se01BootHash?: string;
|
|
1006
|
-
se02BootBuildId?: string;
|
|
1007
|
-
se02BootHash?: string;
|
|
1008
|
-
se03BootBuildId?: string;
|
|
1009
|
-
se03BootHash?: string;
|
|
1010
|
-
se04BootBuildId?: string;
|
|
1011
|
-
se04BootHash?: string;
|
|
1012
|
-
};
|
|
1013
|
-
type DeviceProfileRaw = {
|
|
1014
|
-
features?: Features;
|
|
1015
|
-
protocolV1OneKeyFeatures?: OnekeyFeatures;
|
|
1016
|
-
protocolV2DeviceInfo?: ProtocolV2DeviceInfo;
|
|
1017
|
-
protocolV2DeviceStatus?: DeviceStatus$1;
|
|
1018
|
-
};
|
|
1019
|
-
type DeviceProfile = {
|
|
1020
|
-
protocol: DeviceInfoProtocol;
|
|
1021
|
-
sources: DeviceInfoSource[];
|
|
1022
|
-
deviceType: IDeviceType;
|
|
1023
|
-
firmwareType: EFirmwareType;
|
|
1024
|
-
deviceId: string;
|
|
1025
|
-
serialNo: string;
|
|
1026
|
-
label: string | null;
|
|
1027
|
-
bleName: string | null;
|
|
1028
|
-
status: DeviceInfoStatus;
|
|
1029
|
-
versions: DeviceProfileVersions;
|
|
1030
|
-
verify?: DeviceProfileVerify;
|
|
1031
|
-
raw?: DeviceProfileRaw;
|
|
1032
|
-
};
|
|
1033
|
-
declare function getDeviceInfo(connectId?: string, params?: CommonParams & GetDeviceInfoParams): Response<DeviceProfile>;
|
|
1034
|
-
|
|
1035
1074
|
declare function getOnekeyFeatures(connectId?: string, params?: CommonParams): Response<OnekeyFeatures>;
|
|
1036
1075
|
|
|
1037
1076
|
type GetPassphraseStateParams = CommonParams;
|
|
@@ -1199,7 +1238,15 @@ type DeviceSettingsParams = {
|
|
|
1199
1238
|
experimentalFeatures?: boolean;
|
|
1200
1239
|
autoShutdownDelayMs?: number;
|
|
1201
1240
|
changeBrightness?: boolean;
|
|
1241
|
+
brightness?: number;
|
|
1202
1242
|
hapticFeedback?: boolean;
|
|
1243
|
+
bluetoothEnabled?: boolean;
|
|
1244
|
+
animationEnabled?: boolean;
|
|
1245
|
+
tapToWake?: boolean;
|
|
1246
|
+
deviceNameDisplayEnabled?: boolean;
|
|
1247
|
+
fidoEnabled?: boolean;
|
|
1248
|
+
usbLockEnabled?: boolean;
|
|
1249
|
+
randomKeypad?: boolean;
|
|
1203
1250
|
};
|
|
1204
1251
|
declare function deviceSettings(connectId: string, params: CommonParams & DeviceSettingsParams): Response<Success$1>;
|
|
1205
1252
|
|
|
@@ -1225,7 +1272,7 @@ type DeviceUploadResourceResponse = Success$1 & {
|
|
|
1225
1272
|
declare function deviceUploadResource(connectId: string, params: CommonParams & DeviceUploadResourceParams): Response<DeviceUploadResourceResponse>;
|
|
1226
1273
|
|
|
1227
1274
|
type DeviceSupportFeatures = SupportFeatures & {
|
|
1228
|
-
device: Device | null;
|
|
1275
|
+
device: Device$1 | null;
|
|
1229
1276
|
};
|
|
1230
1277
|
declare function deviceSupportFeatures(connectId?: string): Response<DeviceSupportFeatures>;
|
|
1231
1278
|
|
|
@@ -3140,7 +3187,7 @@ type CoreApi = {
|
|
|
3140
3187
|
searchDevices: typeof searchDevices;
|
|
3141
3188
|
promptWebDeviceAccess: typeof promptWebDeviceAccess;
|
|
3142
3189
|
getFeatures: typeof getFeatures;
|
|
3143
|
-
|
|
3190
|
+
getDeviceState: typeof getDeviceState;
|
|
3144
3191
|
getOnekeyFeatures: typeof getOnekeyFeatures;
|
|
3145
3192
|
getPassphraseState: typeof getPassphraseState;
|
|
3146
3193
|
deviceBackup: typeof deviceBackup;
|
|
@@ -3173,15 +3220,12 @@ type CoreApi = {
|
|
|
3173
3220
|
protocolInfoRequest: typeof protocolInfoRequest;
|
|
3174
3221
|
ping: typeof ping;
|
|
3175
3222
|
deviceReboot: typeof deviceReboot;
|
|
3176
|
-
deviceInfoGet: typeof deviceInfoGet;
|
|
3177
|
-
deviceStatusGet: typeof deviceStatusGet;
|
|
3178
3223
|
deviceGetOnboardingStatus: typeof deviceGetOnboardingStatus;
|
|
3179
3224
|
deviceSessionOpen: typeof deviceSessionOpen;
|
|
3180
3225
|
deviceFirmwareUpdate: typeof deviceFirmwareUpdate;
|
|
3181
3226
|
deviceGetFirmwareUpdateStatus: typeof deviceGetFirmwareUpdateStatus;
|
|
3182
3227
|
deviceFactoryInfoSet: typeof deviceFactoryInfoSet;
|
|
3183
3228
|
deviceFactoryInfoGet: typeof deviceFactoryInfoGet;
|
|
3184
|
-
deviceSettingsGet: typeof deviceSettingsGet;
|
|
3185
3229
|
deviceSettingsSet: typeof deviceSettingsSet;
|
|
3186
3230
|
deviceSettingsPageShow: typeof deviceSettingsPageShow;
|
|
3187
3231
|
deviceUploadWallpaper: typeof deviceUploadWallpaper;
|
|
@@ -3371,6 +3415,7 @@ declare const DEVICE: {
|
|
|
3371
3415
|
readonly SELECT_DEVICE_IN_BOOTLOADER_FOR_WEB_DEVICE: "select_device_in_bootloader_for_web_device";
|
|
3372
3416
|
readonly SELECT_DEVICE_FOR_SWITCH_FIRMWARE_WEB_DEVICE: "select_device_for_switch_firmware_web_device";
|
|
3373
3417
|
readonly FEATURES: "features";
|
|
3418
|
+
readonly STATE: "state";
|
|
3374
3419
|
};
|
|
3375
3420
|
interface DeviceConnnectRequest {
|
|
3376
3421
|
type: typeof DEVICE.CONNECT;
|
|
@@ -3404,6 +3449,10 @@ interface DeviceSendFeatures {
|
|
|
3404
3449
|
type: typeof DEVICE.FEATURES;
|
|
3405
3450
|
payload: DeviceFeaturesPayload;
|
|
3406
3451
|
}
|
|
3452
|
+
interface DeviceSendState {
|
|
3453
|
+
type: typeof DEVICE.STATE;
|
|
3454
|
+
payload: DeviceStateEvent;
|
|
3455
|
+
}
|
|
3407
3456
|
type DeviceSupportFeaturesPayload = SupportFeatures & {
|
|
3408
3457
|
device: KnownDevice | null;
|
|
3409
3458
|
};
|
|
@@ -3411,7 +3460,7 @@ interface DeviceSendSupportFeatures {
|
|
|
3411
3460
|
type: typeof DEVICE.SUPPORT_FEATURES;
|
|
3412
3461
|
payload: DeviceSupportFeaturesPayload;
|
|
3413
3462
|
}
|
|
3414
|
-
type DeviceEvent = DeviceButtonRequest | DeviceSendFeatures | DeviceSendSupportFeatures | DeviceDisconnnectRequest | DeviceConnnectRequest;
|
|
3463
|
+
type DeviceEvent = DeviceButtonRequest | DeviceSendState | DeviceSendFeatures | DeviceSendSupportFeatures | DeviceDisconnnectRequest | DeviceConnnectRequest;
|
|
3415
3464
|
type DeviceEventMessage = DeviceEvent & {
|
|
3416
3465
|
event: typeof DEVICE_EVENT;
|
|
3417
3466
|
};
|
|
@@ -3476,7 +3525,7 @@ interface UiRequestFirmwareProgressing {
|
|
|
3476
3525
|
type UiRequestDeviceAction = {
|
|
3477
3526
|
type: typeof UI_REQUEST.REQUEST_PIN;
|
|
3478
3527
|
payload: ProtocolV2UiEventMetadata & {
|
|
3479
|
-
device: Device;
|
|
3528
|
+
device: Device$1;
|
|
3480
3529
|
type?: Messages.PinMatrixRequestType | 'ButtonRequest_PinEntry' | 'ButtonRequest_AttachPin';
|
|
3481
3530
|
};
|
|
3482
3531
|
};
|
|
@@ -3487,7 +3536,7 @@ interface UiRequestButton {
|
|
|
3487
3536
|
interface UiRequestPassphrase {
|
|
3488
3537
|
type: typeof UI_REQUEST.REQUEST_PASSPHRASE;
|
|
3489
3538
|
payload: {
|
|
3490
|
-
device: Device;
|
|
3539
|
+
device: Device$1;
|
|
3491
3540
|
passphraseState?: string;
|
|
3492
3541
|
existsAttachPinUser?: boolean;
|
|
3493
3542
|
source?: 'wallet-session-coordinator';
|
|
@@ -3498,7 +3547,7 @@ interface UiRequestPassphrase {
|
|
|
3498
3547
|
interface UiRequestPassphraseOnDevice {
|
|
3499
3548
|
type: typeof UI_REQUEST.REQUEST_PASSPHRASE_ON_DEVICE;
|
|
3500
3549
|
payload: {
|
|
3501
|
-
device: Device;
|
|
3550
|
+
device: Device$1;
|
|
3502
3551
|
passphraseState?: string;
|
|
3503
3552
|
source?: 'wallet-session-coordinator';
|
|
3504
3553
|
reason?: 'open-wallet' | 'session-recovery';
|
|
@@ -3507,13 +3556,13 @@ interface UiRequestPassphraseOnDevice {
|
|
|
3507
3556
|
interface UiRequestSelectDeviceInBootloaderForWebDevice {
|
|
3508
3557
|
type: typeof UI_REQUEST.REQUEST_DEVICE_IN_BOOTLOADER_FOR_WEB_DEVICE;
|
|
3509
3558
|
payload: {
|
|
3510
|
-
device: Device;
|
|
3559
|
+
device: Device$1;
|
|
3511
3560
|
};
|
|
3512
3561
|
}
|
|
3513
3562
|
interface UiRequestSelectDeviceForSwitchFirmwareWebDevice {
|
|
3514
3563
|
type: typeof UI_REQUEST.REQUEST_DEVICE_FOR_SWITCH_FIRMWARE_WEB_DEVICE;
|
|
3515
3564
|
payload: {
|
|
3516
|
-
device: Device;
|
|
3565
|
+
device: Device$1;
|
|
3517
3566
|
};
|
|
3518
3567
|
}
|
|
3519
3568
|
interface FirmwareProcessing {
|
|
@@ -3526,7 +3575,7 @@ type IFirmwareUpdateProgressType = 'transferData' | 'installingFirmware';
|
|
|
3526
3575
|
interface FirmwareProgress {
|
|
3527
3576
|
type: typeof UI_REQUEST.FIRMWARE_PROGRESS;
|
|
3528
3577
|
payload: {
|
|
3529
|
-
device: Device;
|
|
3578
|
+
device: Device$1;
|
|
3530
3579
|
progress: number;
|
|
3531
3580
|
progressType: IFirmwareUpdateProgressType;
|
|
3532
3581
|
transferredBytes?: number;
|
|
@@ -3538,7 +3587,7 @@ interface FirmwareProgress {
|
|
|
3538
3587
|
interface FirmwareTip {
|
|
3539
3588
|
type: typeof UI_REQUEST.FIRMWARE_TIP;
|
|
3540
3589
|
payload: {
|
|
3541
|
-
device: Device;
|
|
3590
|
+
device: Device$1;
|
|
3542
3591
|
data: {
|
|
3543
3592
|
message: string;
|
|
3544
3593
|
};
|
|
@@ -3557,7 +3606,7 @@ interface DeviceProgress {
|
|
|
3557
3606
|
interface PreviousAddressResult {
|
|
3558
3607
|
type: typeof UI_REQUEST.PREVIOUS_ADDRESS_RESULT;
|
|
3559
3608
|
payload: {
|
|
3560
|
-
device: Device;
|
|
3609
|
+
device: Device$1;
|
|
3561
3610
|
data: {
|
|
3562
3611
|
address?: string;
|
|
3563
3612
|
path?: string;
|
|
@@ -3818,7 +3867,7 @@ type UiPromiseResponse = UiResponseEvent | {
|
|
|
3818
3867
|
};
|
|
3819
3868
|
type UiPromise<T extends UiPromiseResponse['type']> = Deferred<Extract<UiPromiseResponse, {
|
|
3820
3869
|
type: T;
|
|
3821
|
-
}>, T, Device
|
|
3870
|
+
}>, T, Device>;
|
|
3822
3871
|
|
|
3823
3872
|
declare const LogBlockEvent: Set<string>;
|
|
3824
3873
|
declare function getLogBlockLabel(message: unknown): string | undefined;
|
|
@@ -3895,7 +3944,7 @@ declare const normalizeVersionArray: (version: number[]) => number[];
|
|
|
3895
3944
|
declare const versionSplit: (version: string) => number[];
|
|
3896
3945
|
declare const versionCompare: (a: string | number[], b: string | number[]) => 0 | 1 | -1;
|
|
3897
3946
|
|
|
3898
|
-
declare function patchFeatures(response: DefaultMessageResponse): TypedResponseMessage<"DeviceStatus"> | TypedResponseMessage<"DeviceSession"> | TypedResponseMessage<"PassphraseState"> | TypedResponseMessage<"Address"> | TypedResponseMessage<"DeviceFirmwareUpdateStatus"> | TypedResponseMessage<"Success"> | TypedResponseMessage<"AptosMessagePayload"> | TypedResponseMessage<"BinanceInputOutput"> | TypedResponseMessage<"BinanceCoin"> | TypedResponseMessage<"HDNodePathType"> | TypedResponseMessage<"HDNodeType"> | TypedResponseMessage<"MultisigRedeemScriptType"> | TypedResponseMessage<"TxRequestDetailsType"> | TypedResponseMessage<"TxRequestSerializedType"> | TypedResponseMessage<"TxInputType"> | TypedResponseMessage<"TxOutputBinType"> | TypedResponseMessage<"TxOutputType"> | TypedResponseMessage<"TxAckInputWrapper"> | TypedResponseMessage<"TxAckOutputWrapper"> | TypedResponseMessage<"PrevTx"> | TypedResponseMessage<"TxAckPrevInputWrapper"> | TypedResponseMessage<"PrevInput"> | TypedResponseMessage<"TxAckPrevOutputWrapper"> | TypedResponseMessage<"PrevOutput"> | TypedResponseMessage<"TxAckPrevExtraDataWrapper"> | TypedResponseMessage<"BIP32Address"> | TypedResponseMessage<"CardanoNativeScript"> | TypedResponseMessage<"CardanoBlockchainPointerType"> | TypedResponseMessage<"CardanoAddressParametersType"> | TypedResponseMessage<"CardanoPoolMetadataType"> | TypedResponseMessage<"CardanoPoolParametersType"> | TypedResponseMessage<"CardanoDRep"> | TypedResponseMessage<"CardanoCVoteRegistrationDelegation"> | TypedResponseMessage<"CardanoCVoteRegistrationParametersType"> | TypedResponseMessage<"IdentityType"> | TypedResponseMessage<"Path"> | TypedResponseMessage<"DnxTxKey"> | TypedResponseMessage<"DnxComputedKeyImage"> | TypedResponseMessage<"EmmcFile"> | TypedResponseMessage<"EosTxHeader"> | TypedResponseMessage<"EosActionCommon"> | TypedResponseMessage<"EosActionTransfer"> | TypedResponseMessage<"EosActionDelegate"> | TypedResponseMessage<"EosActionUndelegate"> | TypedResponseMessage<"EosActionRefund"> | TypedResponseMessage<"EosActionBuyRam"> | TypedResponseMessage<"EosActionBuyRamBytes"> | TypedResponseMessage<"EosActionSellRam"> | TypedResponseMessage<"EosActionVoteProducer"> | TypedResponseMessage<"EosActionUpdateAuth"> | TypedResponseMessage<"EosActionDeleteAuth"> | TypedResponseMessage<"EosActionLinkAuth"> | TypedResponseMessage<"EosActionUnlinkAuth"> | TypedResponseMessage<"EosActionNewAccount"> | TypedResponseMessage<"EosActionUnknown"> | TypedResponseMessage<"EosPermissionLevel"> | TypedResponseMessage<"EosAuthorizationKey"> | TypedResponseMessage<"EosAuthorizationAccount"> | TypedResponseMessage<"EosAuthorizationWait"> | TypedResponseMessage<"EosAsset"> | TypedResponseMessage<"EosAuthorization"> | TypedResponseMessage<"EthereumStructMemberOneKey"> | TypedResponseMessage<"EthereumFieldTypeOneKey"> | TypedResponseMessage<"EthereumDefinitions"> | TypedResponseMessage<"EthereumStructMember"> | TypedResponseMessage<"EthereumFieldType"> | TypedResponseMessage<"EthereumAccessListOneKey"> | TypedResponseMessage<"EthereumAuthorizationOneKey"> | TypedResponseMessage<"EthereumAuthorizationSignature"> | TypedResponseMessage<"EthereumAccessList"> | TypedResponseMessage<"KaspaTxRequestSignature"> | TypedResponseMessage<"KaspaOutpoint"> | TypedResponseMessage<"FileInfo"> | TypedResponseMessage<"MoneroOutputEntry"> | TypedResponseMessage<"MoneroMultisigKLRki"> | TypedResponseMessage<"MoneroRctKeyPublic"> | TypedResponseMessage<"MoneroAccountPublicAddress"> | TypedResponseMessage<"MoneroTransactionData"> | TypedResponseMessage<"MoneroTransactionDestinationEntry"> | TypedResponseMessage<"MoneroTransactionRsigData"> | TypedResponseMessage<"MoneroTransactionSourceEntry"> | TypedResponseMessage<"MoneroRingCtSig"> | TypedResponseMessage<"MoneroSubAddressIndicesList"> | TypedResponseMessage<"MoneroTransferDetails"> | TypedResponseMessage<"MoneroExportedKeyImage"> | TypedResponseMessage<"NEMTransactionCommon"> | TypedResponseMessage<"NEMTransfer"> | TypedResponseMessage<"NEMProvisionNamespace"> | TypedResponseMessage<"NEMMosaicCreation"> | TypedResponseMessage<"NEMMosaicSupplyChange"> | TypedResponseMessage<"NEMAggregateModification"> | TypedResponseMessage<"NEMImportanceTransfer"> | TypedResponseMessage<"NEMMosaic"> | TypedResponseMessage<"NEMMosaicDefinition"> | TypedResponseMessage<"NEMCosignatoryModification"> | TypedResponseMessage<"RipplePayment"> | TypedResponseMessage<"SolanaTxATADetails"> | TypedResponseMessage<"SolanaTxExtraInfo"> | TypedResponseMessage<"StellarAsset"> | TypedResponseMessage<"TezosRevealOp"> | TypedResponseMessage<"TezosTransactionOp"> | TypedResponseMessage<"TezosOriginationOp"> | TypedResponseMessage<"TezosDelegationOp"> | TypedResponseMessage<"TezosProposalOp"> | TypedResponseMessage<"TezosBallotOp"> | TypedResponseMessage<"TezosContractID"> | TypedResponseMessage<"TezosParametersManager"> | TypedResponseMessage<"TezosManagerTransfer"> | TypedResponseMessage<"TronContract"> | TypedResponseMessage<"TronTransferContract"> | TypedResponseMessage<"TronVoteWitnessContract"> | TypedResponseMessage<"TronFreezeBalanceContract"> | TypedResponseMessage<"TronUnfreezeBalanceContract"> | TypedResponseMessage<"TronWithdrawBalanceContract"> | TypedResponseMessage<"TronTriggerSmartContract"> | TypedResponseMessage<"TronFreezeBalanceV2Contract"> | TypedResponseMessage<"TronUnfreezeBalanceV2Contract"> | TypedResponseMessage<"TronWithdrawExpireUnfreezeContract"> | TypedResponseMessage<"TronDelegateResourceContract"> | TypedResponseMessage<"TronUnDelegateResourceContract"> | TypedResponseMessage<"TronCancelAllUnfreezeV2Contract"> | TypedResponseMessage<"Vote"> | TypedResponseMessage<"CoinJoinRequest"> | TypedResponseMessage<"PaymentRequestMemo"> | TypedResponseMessage<"TextMemo"> | TypedResponseMessage<"RefundMemo"> | TypedResponseMessage<"CoinPurchaseMemo"> | TypedResponseMessage<"ViewAmount"> | TypedResponseMessage<"ViewDetail"> | TypedResponseMessage<"ViewTip"> | TypedResponseMessage<"ViewRawData"> | TypedResponseMessage<"DeviceSettings"> | TypedResponseMessage<"DeviceCertificate"> | TypedResponseMessage<"DeviceFirmwareTarget"> | TypedResponseMessage<"DeviceFirmwareUpdateRecordFields"> | TypedResponseMessage<"DeviceFirmwareUpdateRecord"> | TypedResponseMessage<"DeviceFactoryInfoManufactureTime"> | TypedResponseMessage<"DeviceFactoryInfo"> | TypedResponseMessage<"DeviceFirmwareImageInfo"> | TypedResponseMessage<"DeviceInfoTargets"> | TypedResponseMessage<"DeviceInfoTypes"> | TypedResponseMessage<"DeviceHardwareInfo"> | TypedResponseMessage<"DeviceMainMcuInfo"> | TypedResponseMessage<"DeviceCoprocessorInfo"> | TypedResponseMessage<"DeviceSEInfo"> | TypedResponseMessage<"DeviceHostPassphrase"> | TypedResponseMessage<"DevicePassphraseOnDevice"> | TypedResponseMessage<"DeviceAttachPinOnDevice"> | TypedResponseMessage<"DeviceSessionResume"> | TypedResponseMessage<"DeviceWalletSelect"> | TypedResponseMessage<"DevOnboardingSetupStatus"> | TypedResponseMessage<"FilesystemFile"> | TypedResponseMessage<"AlephiumGetAddress"> | TypedResponseMessage<"AlephiumAddress"> | TypedResponseMessage<"AlephiumSignTx"> | TypedResponseMessage<"AlephiumSignedTx"> | TypedResponseMessage<"AlephiumTxRequest"> | TypedResponseMessage<"AlephiumTxAck"> | TypedResponseMessage<"AlephiumBytecodeRequest"> | TypedResponseMessage<"AlephiumBytecodeAck"> | TypedResponseMessage<"AlephiumSignMessage"> | TypedResponseMessage<"AlephiumMessageSignature"> | TypedResponseMessage<"AlgorandGetAddress"> | TypedResponseMessage<"AlgorandAddress"> | TypedResponseMessage<"AlgorandSignTx"> | TypedResponseMessage<"AlgorandSignedTx"> | TypedResponseMessage<"AptosGetAddress"> | TypedResponseMessage<"AptosAddress"> | TypedResponseMessage<"AptosSignTx"> | TypedResponseMessage<"AptosSignedTx"> | TypedResponseMessage<"AptosSignMessage"> | TypedResponseMessage<"AptosMessageSignature"> | TypedResponseMessage<"AptosSignSIWAMessage"> | TypedResponseMessage<"BenfenGetAddress"> | TypedResponseMessage<"BenfenAddress"> | TypedResponseMessage<"BenfenSignTx"> | TypedResponseMessage<"BenfenSignedTx"> | TypedResponseMessage<"BenfenTxRequest"> | TypedResponseMessage<"BenfenTxAck"> | TypedResponseMessage<"BenfenSignMessage"> | TypedResponseMessage<"BenfenMessageSignature"> | TypedResponseMessage<"BinanceGetAddress"> | TypedResponseMessage<"BinanceAddress"> | TypedResponseMessage<"BinanceGetPublicKey"> | TypedResponseMessage<"BinancePublicKey"> | TypedResponseMessage<"BinanceSignTx"> | TypedResponseMessage<"BinanceTxRequest"> | TypedResponseMessage<"BinanceTransferMsg"> | TypedResponseMessage<"BinanceOrderMsg"> | TypedResponseMessage<"BinanceCancelMsg"> | TypedResponseMessage<"BinanceSignedTx"> | TypedResponseMessage<"GetPublicKey"> | TypedResponseMessage<"PublicKey"> | TypedResponseMessage<"GetAddress"> | TypedResponseMessage<"GetOwnershipId"> | TypedResponseMessage<"OwnershipId"> | TypedResponseMessage<"SignMessage"> | TypedResponseMessage<"MessageSignature"> | TypedResponseMessage<"VerifyMessage"> | TypedResponseMessage<"SignTx"> | TypedResponseMessage<"TxRequest"> | TypedResponseMessage<"TxAck"> | TypedResponseMessage<"TxAckInput"> | TypedResponseMessage<"TxAckOutput"> | TypedResponseMessage<"TxAckPrevMeta"> | TypedResponseMessage<"TxAckPrevInput"> | TypedResponseMessage<"TxAckPrevOutput"> | TypedResponseMessage<"TxAckPrevExtraData"> | TypedResponseMessage<"GetOwnershipProof"> | TypedResponseMessage<"OwnershipProof"> | TypedResponseMessage<"AuthorizeCoinJoin"> | TypedResponseMessage<"GetPublicKeyMultiple"> | TypedResponseMessage<"PublicKeyMultiple"> | TypedResponseMessage<"SignPsbt"> | TypedResponseMessage<"SignedPsbt"> | TypedResponseMessage<"FirmwareErase"> | TypedResponseMessage<"FirmwareRequest"> | TypedResponseMessage<"FirmwareUpload"> | TypedResponseMessage<"SelfTest"> | TypedResponseMessage<"FirmwareErase_ex"> | TypedResponseMessage<"Reboot"> | TypedResponseMessage<"FirmwareUpdateEmmc"> | TypedResponseMessage<"UpgradeFileHeader"> | TypedResponseMessage<"CardanoGetNativeScriptHash"> | TypedResponseMessage<"CardanoNativeScriptHash"> | TypedResponseMessage<"CardanoGetAddress"> | TypedResponseMessage<"CardanoAddress"> | TypedResponseMessage<"CardanoGetPublicKey"> | TypedResponseMessage<"CardanoPublicKey"> | TypedResponseMessage<"CardanoSignTxInit"> | TypedResponseMessage<"CardanoTxInput"> | TypedResponseMessage<"CardanoTxOutput"> | TypedResponseMessage<"CardanoAssetGroup"> | TypedResponseMessage<"CardanoToken"> | TypedResponseMessage<"CardanoTxInlineDatumChunk"> | TypedResponseMessage<"CardanoTxReferenceScriptChunk"> | TypedResponseMessage<"CardanoPoolOwner"> | TypedResponseMessage<"CardanoPoolRelayParameters"> | TypedResponseMessage<"CardanoTxCertificate"> | TypedResponseMessage<"CardanoTxWithdrawal"> | TypedResponseMessage<"CardanoTxAuxiliaryData"> | TypedResponseMessage<"CardanoTxMint"> | TypedResponseMessage<"CardanoTxCollateralInput"> | TypedResponseMessage<"CardanoTxRequiredSigner"> | TypedResponseMessage<"CardanoTxReferenceInput"> | TypedResponseMessage<"CardanoTxItemAck"> | TypedResponseMessage<"CardanoTxAuxiliaryDataSupplement"> | TypedResponseMessage<"CardanoTxWitnessRequest"> | TypedResponseMessage<"CardanoTxWitnessResponse"> | TypedResponseMessage<"CardanoTxHostAck"> | TypedResponseMessage<"CardanoTxBodyHash"> | TypedResponseMessage<"CardanoSignTxFinished"> | TypedResponseMessage<"CardanoSignMessage"> | TypedResponseMessage<"CardanoMessageSignature"> | TypedResponseMessage<"Failure"> | TypedResponseMessage<"ButtonRequest"> | TypedResponseMessage<"ButtonAck"> | TypedResponseMessage<"PinMatrixRequest"> | TypedResponseMessage<"PinMatrixAck"> | TypedResponseMessage<"PassphraseRequest"> | TypedResponseMessage<"PassphraseAck"> | TypedResponseMessage<"Deprecated_PassphraseStateRequest"> | TypedResponseMessage<"Deprecated_PassphraseStateAck"> | TypedResponseMessage<"BixinPinInputOnDevice"> | TypedResponseMessage<"ConfluxGetAddress"> | TypedResponseMessage<"ConfluxAddress"> | TypedResponseMessage<"ConfluxSignTx"> | TypedResponseMessage<"ConfluxTxRequest"> | TypedResponseMessage<"ConfluxTxAck"> | TypedResponseMessage<"ConfluxSignMessage"> | TypedResponseMessage<"ConfluxMessageSignature"> | TypedResponseMessage<"ConfluxSignMessageCIP23"> | TypedResponseMessage<"CosmosGetAddress"> | TypedResponseMessage<"CosmosAddress"> | TypedResponseMessage<"CosmosSignTx"> | TypedResponseMessage<"CosmosSignedTx"> | TypedResponseMessage<"CipherKeyValue"> | TypedResponseMessage<"CipheredKeyValue"> | TypedResponseMessage<"SignIdentity"> | TypedResponseMessage<"SignedIdentity"> | TypedResponseMessage<"GetECDHSessionKey"> | TypedResponseMessage<"ECDHSessionKey"> | TypedResponseMessage<"BatchGetPublickeys"> | TypedResponseMessage<"EcdsaPublicKeys"> | TypedResponseMessage<"DnxGetAddress"> | TypedResponseMessage<"DnxAddress"> | TypedResponseMessage<"DnxSignTx"> | TypedResponseMessage<"DnxInputRequest"> | TypedResponseMessage<"DnxInputAck"> | TypedResponseMessage<"DnxRTSigsRequest"> | TypedResponseMessage<"DnxSignedTx"> | TypedResponseMessage<"EmmcFixPermission"> | TypedResponseMessage<"EmmcPath"> | TypedResponseMessage<"EmmcPathInfo"> | TypedResponseMessage<"EmmcFileRead"> | TypedResponseMessage<"EmmcFileWrite"> | TypedResponseMessage<"EmmcFileDelete"> | TypedResponseMessage<"EmmcDir"> | TypedResponseMessage<"EmmcDirList"> | TypedResponseMessage<"EmmcDirMake"> | TypedResponseMessage<"EmmcDirRemove"> | TypedResponseMessage<"EosGetPublicKey"> | TypedResponseMessage<"EosPublicKey"> | TypedResponseMessage<"EosSignTx"> | TypedResponseMessage<"EosTxActionRequest"> | TypedResponseMessage<"EosTxActionAck"> | TypedResponseMessage<"EosSignedTx"> | TypedResponseMessage<"EthereumNetworkInfo"> | TypedResponseMessage<"EthereumTokenInfo"> | TypedResponseMessage<"EthereumSignTypedDataOneKey"> | TypedResponseMessage<"EthereumGnosisSafeTxRequest"> | TypedResponseMessage<"EthereumGnosisSafeTxAck"> | TypedResponseMessage<"EthereumTypedDataStructRequestOneKey"> | TypedResponseMessage<"EthereumTypedDataStructAckOneKey"> | TypedResponseMessage<"EthereumTypedDataValueRequestOneKey"> | TypedResponseMessage<"EthereumTypedDataValueAckOneKey"> | TypedResponseMessage<"EthereumSignTypedData"> | TypedResponseMessage<"EthereumTypedDataStructRequest"> | TypedResponseMessage<"EthereumTypedDataStructAck"> | TypedResponseMessage<"EthereumTypedDataValueRequest"> | TypedResponseMessage<"EthereumTypedDataValueAck"> | TypedResponseMessage<"EthereumGetPublicKeyOneKey"> | TypedResponseMessage<"EthereumPublicKeyOneKey"> | TypedResponseMessage<"EthereumGetAddressOneKey"> | TypedResponseMessage<"EthereumAddressOneKey"> | TypedResponseMessage<"EthereumSignTxOneKey"> | TypedResponseMessage<"EthereumSignTxEIP1559OneKey"> | TypedResponseMessage<"EthereumSignTxEIP7702OneKey"> | TypedResponseMessage<"EthereumTxRequestOneKey"> | TypedResponseMessage<"EthereumTxAckOneKey"> | TypedResponseMessage<"EthereumSignMessageOneKey"> | TypedResponseMessage<"EthereumMessageSignatureOneKey"> | TypedResponseMessage<"EthereumVerifyMessageOneKey"> | TypedResponseMessage<"EthereumSignTypedHashOneKey"> | TypedResponseMessage<"EthereumTypedDataSignatureOneKey"> | TypedResponseMessage<"EthereumSignMessageEIP712"> | TypedResponseMessage<"EthereumGetPublicKey"> | TypedResponseMessage<"EthereumPublicKey"> | TypedResponseMessage<"EthereumGetAddress"> | TypedResponseMessage<"EthereumAddress"> | TypedResponseMessage<"EthereumSignTx"> | TypedResponseMessage<"EthereumSignTxEIP1559"> | TypedResponseMessage<"EthereumTxRequest"> | TypedResponseMessage<"EthereumTxAck"> | TypedResponseMessage<"EthereumSignMessage"> | TypedResponseMessage<"EthereumMessageSignature"> | TypedResponseMessage<"EthereumVerifyMessage"> | TypedResponseMessage<"EthereumSignTypedHash"> | TypedResponseMessage<"EthereumTypedDataSignature"> | TypedResponseMessage<"FilecoinGetAddress"> | TypedResponseMessage<"FilecoinAddress"> | TypedResponseMessage<"FilecoinSignTx"> | TypedResponseMessage<"FilecoinSignedTx"> | TypedResponseMessage<"KaspaGetAddress"> | TypedResponseMessage<"KaspaAddress"> | TypedResponseMessage<"KaspaSignTx"> | TypedResponseMessage<"KaspaTxInputRequest"> | TypedResponseMessage<"KaspaTxInputAck"> | TypedResponseMessage<"KaspaTxRequest"> | TypedResponseMessage<"KaspaTxAckInput"> | TypedResponseMessage<"KaspaTxAckOutput"> | TypedResponseMessage<"KaspaTxAckPayloadChunk"> | TypedResponseMessage<"KaspaTxAckPrevMeta"> | TypedResponseMessage<"KaspaTxAckPrevInput"> | TypedResponseMessage<"KaspaTxAckPrevOutput"> | TypedResponseMessage<"KaspaSignedTx"> | TypedResponseMessage<"LnurlAuth"> | TypedResponseMessage<"LnurlAuthResp"> | TypedResponseMessage<"Initialize"> | TypedResponseMessage<"GetFeatures"> | TypedResponseMessage<"OnekeyGetFeatures"> | TypedResponseMessage<"Features"> | TypedResponseMessage<"OnekeyFeatures"> | TypedResponseMessage<"LockDevice"> | TypedResponseMessage<"EndSession"> | TypedResponseMessage<"ApplySettings"> | TypedResponseMessage<"ApplyFlags"> | TypedResponseMessage<"ChangePin"> | TypedResponseMessage<"ChangeWipeCode"> | TypedResponseMessage<"SdProtect"> | TypedResponseMessage<"Ping"> | TypedResponseMessage<"Cancel"> | TypedResponseMessage<"GetEntropy"> | TypedResponseMessage<"Entropy"> | TypedResponseMessage<"WipeDevice"> | TypedResponseMessage<"ResetDevice"> | TypedResponseMessage<"BackupDevice"> | TypedResponseMessage<"EntropyRequest"> | TypedResponseMessage<"EntropyAck"> | TypedResponseMessage<"RecoveryDevice"> | TypedResponseMessage<"WordRequest"> | TypedResponseMessage<"WordAck"> | TypedResponseMessage<"SetU2FCounter"> | TypedResponseMessage<"GetNextU2FCounter"> | TypedResponseMessage<"NextU2FCounter"> | TypedResponseMessage<"DoPreauthorized"> | TypedResponseMessage<"PreauthorizedRequest"> | TypedResponseMessage<"CancelAuthorization"> | TypedResponseMessage<"BixinSeedOperate"> | TypedResponseMessage<"BixinMessageSE"> | TypedResponseMessage<"BixinOutMessageSE"> | TypedResponseMessage<"DeviceBackToBoot"> | TypedResponseMessage<"BixinBackupRequest"> | TypedResponseMessage<"BixinBackupAck"> | TypedResponseMessage<"BixinRestoreRequest"> | TypedResponseMessage<"BixinRestoreAck"> | TypedResponseMessage<"BixinVerifyDeviceRequest"> | TypedResponseMessage<"BixinVerifyDeviceAck"> | TypedResponseMessage<"BixinWhiteListRequest"> | TypedResponseMessage<"BixinWhiteListAck"> | TypedResponseMessage<"BixinLoadDevice"> | TypedResponseMessage<"BixinBackupDevice"> | TypedResponseMessage<"BixinBackupDeviceAck"> | TypedResponseMessage<"DeviceInfoSettings"> | TypedResponseMessage<"GetDeviceInfo"> | TypedResponseMessage<"DeviceInfo"> | TypedResponseMessage<"ReadSEPublicKey"> | TypedResponseMessage<"SEPublicKey"> | TypedResponseMessage<"WriteSEPublicCert"> | TypedResponseMessage<"ReadSEPublicCert"> | TypedResponseMessage<"SEPublicCert"> | TypedResponseMessage<"SpiFlashWrite"> | TypedResponseMessage<"SpiFlashRead"> | TypedResponseMessage<"SpiFlashData"> | TypedResponseMessage<"SESignMessage"> | TypedResponseMessage<"SEMessageSignature"> | TypedResponseMessage<"ResourceUpload"> | TypedResponseMessage<"ZoomRequest"> | TypedResponseMessage<"BlurRequest"> | TypedResponseMessage<"ResourceRequest"> | TypedResponseMessage<"ResourceAck"> | TypedResponseMessage<"ResourceUpdate"> | TypedResponseMessage<"NFTWriteInfo"> | TypedResponseMessage<"NFTWriteData"> | TypedResponseMessage<"RebootToBootloader"> | TypedResponseMessage<"RebootToBoardloader"> | TypedResponseMessage<"ListResDir"> | TypedResponseMessage<"FileInfoList"> | TypedResponseMessage<"DeviceEraseSector"> | TypedResponseMessage<"UnLockDevice"> | TypedResponseMessage<"UnLockDeviceResponse"> | TypedResponseMessage<"GetPassphraseState"> | TypedResponseMessage<"MoneroGetAddress"> | TypedResponseMessage<"MoneroAddress"> | TypedResponseMessage<"MoneroGetWatchKey"> | TypedResponseMessage<"MoneroWatchKey"> | TypedResponseMessage<"MoneroTransactionInitRequest"> | TypedResponseMessage<"MoneroTransactionInitAck"> | TypedResponseMessage<"MoneroTransactionSetInputRequest"> | TypedResponseMessage<"MoneroTransactionSetInputAck"> | TypedResponseMessage<"MoneroTransactionInputsPermutationRequest"> | TypedResponseMessage<"MoneroTransactionInputsPermutationAck"> | TypedResponseMessage<"MoneroTransactionInputViniRequest"> | TypedResponseMessage<"MoneroTransactionInputViniAck"> | TypedResponseMessage<"MoneroTransactionAllInputsSetRequest"> | TypedResponseMessage<"MoneroTransactionAllInputsSetAck"> | TypedResponseMessage<"MoneroTransactionSetOutputRequest"> | TypedResponseMessage<"MoneroTransactionSetOutputAck"> | TypedResponseMessage<"MoneroTransactionAllOutSetRequest"> | TypedResponseMessage<"MoneroTransactionAllOutSetAck"> | TypedResponseMessage<"MoneroTransactionSignInputRequest"> | TypedResponseMessage<"MoneroTransactionSignInputAck"> | TypedResponseMessage<"MoneroTransactionFinalRequest"> | TypedResponseMessage<"MoneroTransactionFinalAck"> | TypedResponseMessage<"MoneroKeyImageExportInitRequest"> | TypedResponseMessage<"MoneroKeyImageExportInitAck"> | TypedResponseMessage<"MoneroKeyImageSyncStepRequest"> | TypedResponseMessage<"MoneroKeyImageSyncStepAck"> | TypedResponseMessage<"MoneroKeyImageSyncFinalRequest"> | TypedResponseMessage<"MoneroKeyImageSyncFinalAck"> | TypedResponseMessage<"MoneroGetTxKeyRequest"> | TypedResponseMessage<"MoneroGetTxKeyAck"> | TypedResponseMessage<"MoneroLiveRefreshStartRequest"> | TypedResponseMessage<"MoneroLiveRefreshStartAck"> | TypedResponseMessage<"MoneroLiveRefreshStepRequest"> | TypedResponseMessage<"MoneroLiveRefreshStepAck"> | TypedResponseMessage<"MoneroLiveRefreshFinalRequest"> | TypedResponseMessage<"MoneroLiveRefreshFinalAck"> | TypedResponseMessage<"NearGetAddress"> | TypedResponseMessage<"NearAddress"> | TypedResponseMessage<"NearSignTx"> | TypedResponseMessage<"NearSignedTx"> | TypedResponseMessage<"NEMGetAddress"> | TypedResponseMessage<"NEMAddress"> | TypedResponseMessage<"NEMSignTx"> | TypedResponseMessage<"NEMSignedTx"> | TypedResponseMessage<"NEMDecryptMessage"> | TypedResponseMessage<"NEMDecryptedMessage"> | TypedResponseMessage<"NeoGetAddress"> | TypedResponseMessage<"NeoAddress"> | TypedResponseMessage<"NeoSignTx"> | TypedResponseMessage<"NeoSignedTx"> | TypedResponseMessage<"NervosGetAddress"> | TypedResponseMessage<"NervosAddress"> | TypedResponseMessage<"NervosSignTx"> | TypedResponseMessage<"NervosSignedTx"> | TypedResponseMessage<"NervosTxRequest"> | TypedResponseMessage<"NervosTxAck"> | TypedResponseMessage<"NexaGetAddress"> | TypedResponseMessage<"NexaAddress"> | TypedResponseMessage<"NexaSignTx"> | TypedResponseMessage<"NexaTxInputRequest"> | TypedResponseMessage<"NexaTxInputAck"> | TypedResponseMessage<"NexaSignedTx"> | TypedResponseMessage<"NostrGetPublicKey"> | TypedResponseMessage<"NostrPublicKey"> | TypedResponseMessage<"NostrSignEvent"> | TypedResponseMessage<"NostrSignedEvent"> | TypedResponseMessage<"NostrSignSchnorr"> | TypedResponseMessage<"NostrSignedSchnorr"> | TypedResponseMessage<"NostrEncryptMessage"> | TypedResponseMessage<"NostrEncryptedMessage"> | TypedResponseMessage<"NostrDecryptMessage"> | TypedResponseMessage<"NostrDecryptedMessage"> | TypedResponseMessage<"PolkadotGetAddress"> | TypedResponseMessage<"PolkadotAddress"> | TypedResponseMessage<"PolkadotSignTx"> | TypedResponseMessage<"PolkadotSignedTx"> | TypedResponseMessage<"RippleGetAddress"> | TypedResponseMessage<"RippleAddress"> | TypedResponseMessage<"RippleSignTx"> | TypedResponseMessage<"RippleSignedTx"> | TypedResponseMessage<"ScdoGetAddress"> | TypedResponseMessage<"ScdoAddress"> | TypedResponseMessage<"ScdoSignTx"> | TypedResponseMessage<"ScdoSignedTx"> | TypedResponseMessage<"ScdoTxAck"> | TypedResponseMessage<"ScdoSignMessage"> | TypedResponseMessage<"ScdoSignedMessage"> | TypedResponseMessage<"SolanaGetAddress"> | TypedResponseMessage<"SolanaAddress"> | TypedResponseMessage<"SolanaSignTx"> | TypedResponseMessage<"SolanaSignedTx"> | TypedResponseMessage<"SolanaSignOffChainMessage"> | TypedResponseMessage<"SolanaSignUnsafeMessage"> | TypedResponseMessage<"SolanaMessageSignature"> | TypedResponseMessage<"StarcoinGetAddress"> | TypedResponseMessage<"StarcoinAddress"> | TypedResponseMessage<"StarcoinGetPublicKey"> | TypedResponseMessage<"StarcoinPublicKey"> | TypedResponseMessage<"StarcoinSignTx"> | TypedResponseMessage<"StarcoinSignedTx"> | TypedResponseMessage<"StarcoinSignMessage"> | TypedResponseMessage<"StarcoinMessageSignature"> | TypedResponseMessage<"StarcoinVerifyMessage"> | TypedResponseMessage<"StellarGetAddress"> | TypedResponseMessage<"StellarAddress"> | TypedResponseMessage<"StellarSignTx"> | TypedResponseMessage<"StellarTxOpRequest"> | TypedResponseMessage<"StellarPaymentOp"> | TypedResponseMessage<"StellarCreateAccountOp"> | TypedResponseMessage<"StellarPathPaymentStrictReceiveOp"> | TypedResponseMessage<"StellarPathPaymentStrictSendOp"> | TypedResponseMessage<"StellarManageSellOfferOp"> | TypedResponseMessage<"StellarManageBuyOfferOp"> | TypedResponseMessage<"StellarCreatePassiveSellOfferOp"> | TypedResponseMessage<"StellarSetOptionsOp"> | TypedResponseMessage<"StellarChangeTrustOp"> | TypedResponseMessage<"StellarAllowTrustOp"> | TypedResponseMessage<"StellarAccountMergeOp"> | TypedResponseMessage<"StellarManageDataOp"> | TypedResponseMessage<"StellarBumpSequenceOp"> | TypedResponseMessage<"StellarInvokeHostFunctionOp"> | TypedResponseMessage<"StellarSorobanDataRequest"> | TypedResponseMessage<"StellarSorobanDataAck"> | TypedResponseMessage<"StellarSignedTx"> | TypedResponseMessage<"SuiGetAddress"> | TypedResponseMessage<"SuiAddress"> | TypedResponseMessage<"SuiSignTx"> | TypedResponseMessage<"SuiSignedTx"> | TypedResponseMessage<"SuiTxRequest"> | TypedResponseMessage<"SuiTxAck"> | TypedResponseMessage<"SuiSignMessage"> | TypedResponseMessage<"SuiMessageSignature"> | TypedResponseMessage<"TezosGetAddress"> | TypedResponseMessage<"TezosAddress"> | TypedResponseMessage<"TezosGetPublicKey"> | TypedResponseMessage<"TezosPublicKey"> | TypedResponseMessage<"TezosSignTx"> | TypedResponseMessage<"TezosSignedTx"> | TypedResponseMessage<"TonGetAddress"> | TypedResponseMessage<"TonAddress"> | TypedResponseMessage<"TonSignMessage"> | TypedResponseMessage<"TonTxAck"> | TypedResponseMessage<"TonSignedMessage"> | TypedResponseMessage<"TonSignProof"> | TypedResponseMessage<"TonSignedProof"> | TypedResponseMessage<"TonSignData"> | TypedResponseMessage<"TonSignedData"> | TypedResponseMessage<"TronGetAddress"> | TypedResponseMessage<"TronAddress"> | TypedResponseMessage<"TronSignTx"> | TypedResponseMessage<"TronSignedTx"> | TypedResponseMessage<"TronSignMessage"> | TypedResponseMessage<"TronMessageSignature"> | TypedResponseMessage<"facotry"> | TypedResponseMessage<"experimental_message"> | TypedResponseMessage<"experimental_field"> | TypedResponseMessage<"TxAckPaymentRequest"> | TypedResponseMessage<"EthereumSignTypedDataQR"> | TypedResponseMessage<"InternalMyAddressRequest"> | TypedResponseMessage<"StartSession"> | TypedResponseMessage<"SetBusy"> | TypedResponseMessage<"GetFirmwareHash"> | TypedResponseMessage<"FirmwareHash"> | TypedResponseMessage<"GetNonce"> | TypedResponseMessage<"Nonce"> | TypedResponseMessage<"WriteSEPrivateKey"> | TypedResponseMessage<"SetWallpaper"> | TypedResponseMessage<"GetWallpaper"> | TypedResponseMessage<"Wallpaper"> | TypedResponseMessage<"UnlockPath"> | TypedResponseMessage<"UnlockedPathRequest"> | TypedResponseMessage<"ViewSignPage"> | TypedResponseMessage<"ViewVerifyPage"> | TypedResponseMessage<"ProtocolInfoRequest"> | TypedResponseMessage<"ProtocolInfo"> | TypedResponseMessage<"DeviceReboot"> | TypedResponseMessage<"DeviceSettingsGet"> | TypedResponseMessage<"DeviceSettingsSet"> | TypedResponseMessage<"DeviceSettingsPageShow"> | TypedResponseMessage<"DeviceCertificateWrite"> | TypedResponseMessage<"DeviceCertificateRead"> | TypedResponseMessage<"DeviceCertificateSignature"> | TypedResponseMessage<"DeviceCertificateSign"> | TypedResponseMessage<"DeviceFirmwareUpdateRequest"> | TypedResponseMessage<"DeviceFirmwareUpdateStatusGet"> | TypedResponseMessage<"DeviceFactoryInfoSet"> | TypedResponseMessage<"DeviceFactoryInfoGet"> | TypedResponseMessage<"DeviceFactoryPermanentLock"> | TypedResponseMessage<"DeviceFactoryTest"> | TypedResponseMessage<"DeviceInfoGet"> | TypedResponseMessage<"DeviceSessionOpen"> | TypedResponseMessage<"DeviceSessionAskPin"> | TypedResponseMessage<"DeviceStatusGet"> | TypedResponseMessage<"DevGetOnboardingStatus"> | TypedResponseMessage<"DevOnboardingStatus"> | TypedResponseMessage<"FilesystemPermissionFix"> | TypedResponseMessage<"FilesystemPathInfo"> | TypedResponseMessage<"FilesystemPathInfoQuery"> | TypedResponseMessage<"FilesystemFileRead"> | TypedResponseMessage<"FilesystemFileWrite"> | TypedResponseMessage<"FilesystemFileDelete"> | TypedResponseMessage<"FilesystemDir"> | TypedResponseMessage<"FilesystemDirList"> | TypedResponseMessage<"FilesystemDirMake"> | TypedResponseMessage<"FilesystemDirRemove"> | TypedResponseMessage<"FilesystemFormat"> | TypedResponseMessage<"PortfolioUpdate">;
|
|
3947
|
+
declare function patchFeatures(response: DefaultMessageResponse): TypedResponseMessage<"DeviceStatus"> | TypedResponseMessage<"DeviceSession"> | TypedResponseMessage<"PassphraseState"> | TypedResponseMessage<"Address"> | TypedResponseMessage<"DeviceInfo"> | TypedResponseMessage<"DeviceFirmwareUpdateStatus"> | TypedResponseMessage<"Success"> | TypedResponseMessage<"AptosMessagePayload"> | TypedResponseMessage<"BinanceInputOutput"> | TypedResponseMessage<"BinanceCoin"> | TypedResponseMessage<"HDNodePathType"> | TypedResponseMessage<"HDNodeType"> | TypedResponseMessage<"MultisigRedeemScriptType"> | TypedResponseMessage<"TxRequestDetailsType"> | TypedResponseMessage<"TxRequestSerializedType"> | TypedResponseMessage<"TxInputType"> | TypedResponseMessage<"TxOutputBinType"> | TypedResponseMessage<"TxOutputType"> | TypedResponseMessage<"TxAckInputWrapper"> | TypedResponseMessage<"TxAckOutputWrapper"> | TypedResponseMessage<"PrevTx"> | TypedResponseMessage<"TxAckPrevInputWrapper"> | TypedResponseMessage<"PrevInput"> | TypedResponseMessage<"TxAckPrevOutputWrapper"> | TypedResponseMessage<"PrevOutput"> | TypedResponseMessage<"TxAckPrevExtraDataWrapper"> | TypedResponseMessage<"BIP32Address"> | TypedResponseMessage<"CardanoNativeScript"> | TypedResponseMessage<"CardanoBlockchainPointerType"> | TypedResponseMessage<"CardanoAddressParametersType"> | TypedResponseMessage<"CardanoPoolMetadataType"> | TypedResponseMessage<"CardanoPoolParametersType"> | TypedResponseMessage<"CardanoDRep"> | TypedResponseMessage<"CardanoCVoteRegistrationDelegation"> | TypedResponseMessage<"CardanoCVoteRegistrationParametersType"> | TypedResponseMessage<"IdentityType"> | TypedResponseMessage<"Path"> | TypedResponseMessage<"DnxTxKey"> | TypedResponseMessage<"DnxComputedKeyImage"> | TypedResponseMessage<"EmmcFile"> | TypedResponseMessage<"EosTxHeader"> | TypedResponseMessage<"EosActionCommon"> | TypedResponseMessage<"EosActionTransfer"> | TypedResponseMessage<"EosActionDelegate"> | TypedResponseMessage<"EosActionUndelegate"> | TypedResponseMessage<"EosActionRefund"> | TypedResponseMessage<"EosActionBuyRam"> | TypedResponseMessage<"EosActionBuyRamBytes"> | TypedResponseMessage<"EosActionSellRam"> | TypedResponseMessage<"EosActionVoteProducer"> | TypedResponseMessage<"EosActionUpdateAuth"> | TypedResponseMessage<"EosActionDeleteAuth"> | TypedResponseMessage<"EosActionLinkAuth"> | TypedResponseMessage<"EosActionUnlinkAuth"> | TypedResponseMessage<"EosActionNewAccount"> | TypedResponseMessage<"EosActionUnknown"> | TypedResponseMessage<"EosPermissionLevel"> | TypedResponseMessage<"EosAuthorizationKey"> | TypedResponseMessage<"EosAuthorizationAccount"> | TypedResponseMessage<"EosAuthorizationWait"> | TypedResponseMessage<"EosAsset"> | TypedResponseMessage<"EosAuthorization"> | TypedResponseMessage<"EthereumStructMemberOneKey"> | TypedResponseMessage<"EthereumFieldTypeOneKey"> | TypedResponseMessage<"EthereumDefinitions"> | TypedResponseMessage<"EthereumStructMember"> | TypedResponseMessage<"EthereumFieldType"> | TypedResponseMessage<"EthereumAccessListOneKey"> | TypedResponseMessage<"EthereumAuthorizationOneKey"> | TypedResponseMessage<"EthereumAuthorizationSignature"> | TypedResponseMessage<"EthereumAccessList"> | TypedResponseMessage<"KaspaTxRequestSignature"> | TypedResponseMessage<"KaspaOutpoint"> | TypedResponseMessage<"FileInfo"> | TypedResponseMessage<"MoneroOutputEntry"> | TypedResponseMessage<"MoneroMultisigKLRki"> | TypedResponseMessage<"MoneroRctKeyPublic"> | TypedResponseMessage<"MoneroAccountPublicAddress"> | TypedResponseMessage<"MoneroTransactionData"> | TypedResponseMessage<"MoneroTransactionDestinationEntry"> | TypedResponseMessage<"MoneroTransactionRsigData"> | TypedResponseMessage<"MoneroTransactionSourceEntry"> | TypedResponseMessage<"MoneroRingCtSig"> | TypedResponseMessage<"MoneroSubAddressIndicesList"> | TypedResponseMessage<"MoneroTransferDetails"> | TypedResponseMessage<"MoneroExportedKeyImage"> | TypedResponseMessage<"NEMTransactionCommon"> | TypedResponseMessage<"NEMTransfer"> | TypedResponseMessage<"NEMProvisionNamespace"> | TypedResponseMessage<"NEMMosaicCreation"> | TypedResponseMessage<"NEMMosaicSupplyChange"> | TypedResponseMessage<"NEMAggregateModification"> | TypedResponseMessage<"NEMImportanceTransfer"> | TypedResponseMessage<"NEMMosaic"> | TypedResponseMessage<"NEMMosaicDefinition"> | TypedResponseMessage<"NEMCosignatoryModification"> | TypedResponseMessage<"RipplePayment"> | TypedResponseMessage<"SolanaTxATADetails"> | TypedResponseMessage<"SolanaTxExtraInfo"> | TypedResponseMessage<"StellarAsset"> | TypedResponseMessage<"TezosRevealOp"> | TypedResponseMessage<"TezosTransactionOp"> | TypedResponseMessage<"TezosOriginationOp"> | TypedResponseMessage<"TezosDelegationOp"> | TypedResponseMessage<"TezosProposalOp"> | TypedResponseMessage<"TezosBallotOp"> | TypedResponseMessage<"TezosContractID"> | TypedResponseMessage<"TezosParametersManager"> | TypedResponseMessage<"TezosManagerTransfer"> | TypedResponseMessage<"TronContract"> | TypedResponseMessage<"TronTransferContract"> | TypedResponseMessage<"TronVoteWitnessContract"> | TypedResponseMessage<"TronFreezeBalanceContract"> | TypedResponseMessage<"TronUnfreezeBalanceContract"> | TypedResponseMessage<"TronWithdrawBalanceContract"> | TypedResponseMessage<"TronTriggerSmartContract"> | TypedResponseMessage<"TronFreezeBalanceV2Contract"> | TypedResponseMessage<"TronUnfreezeBalanceV2Contract"> | TypedResponseMessage<"TronWithdrawExpireUnfreezeContract"> | TypedResponseMessage<"TronDelegateResourceContract"> | TypedResponseMessage<"TronUnDelegateResourceContract"> | TypedResponseMessage<"TronCancelAllUnfreezeV2Contract"> | TypedResponseMessage<"Vote"> | TypedResponseMessage<"CoinJoinRequest"> | TypedResponseMessage<"PaymentRequestMemo"> | TypedResponseMessage<"TextMemo"> | TypedResponseMessage<"RefundMemo"> | TypedResponseMessage<"CoinPurchaseMemo"> | TypedResponseMessage<"ViewAmount"> | TypedResponseMessage<"ViewDetail"> | TypedResponseMessage<"ViewTip"> | TypedResponseMessage<"ViewRawData"> | TypedResponseMessage<"DeviceSettings"> | TypedResponseMessage<"DeviceCertificate"> | TypedResponseMessage<"DeviceFirmwareTarget"> | TypedResponseMessage<"DeviceFirmwareUpdateRecordFields"> | TypedResponseMessage<"DeviceFirmwareUpdateRecord"> | TypedResponseMessage<"DeviceFactoryInfoManufactureTime"> | TypedResponseMessage<"DeviceFactoryInfo"> | TypedResponseMessage<"DeviceFirmwareImageInfo"> | TypedResponseMessage<"DeviceInfoTargets"> | TypedResponseMessage<"DeviceInfoTypes"> | TypedResponseMessage<"DeviceHardwareInfo"> | TypedResponseMessage<"DeviceMainMcuInfo"> | TypedResponseMessage<"DeviceCoprocessorInfo"> | TypedResponseMessage<"DeviceSEInfo"> | TypedResponseMessage<"DeviceHostPassphrase"> | TypedResponseMessage<"DevicePassphraseOnDevice"> | TypedResponseMessage<"DeviceAttachPinOnDevice"> | TypedResponseMessage<"DeviceSessionResume"> | TypedResponseMessage<"DeviceWalletSelect"> | TypedResponseMessage<"DevOnboardingSetupStatus"> | TypedResponseMessage<"FilesystemFile"> | TypedResponseMessage<"AlephiumGetAddress"> | TypedResponseMessage<"AlephiumAddress"> | TypedResponseMessage<"AlephiumSignTx"> | TypedResponseMessage<"AlephiumSignedTx"> | TypedResponseMessage<"AlephiumTxRequest"> | TypedResponseMessage<"AlephiumTxAck"> | TypedResponseMessage<"AlephiumBytecodeRequest"> | TypedResponseMessage<"AlephiumBytecodeAck"> | TypedResponseMessage<"AlephiumSignMessage"> | TypedResponseMessage<"AlephiumMessageSignature"> | TypedResponseMessage<"AlgorandGetAddress"> | TypedResponseMessage<"AlgorandAddress"> | TypedResponseMessage<"AlgorandSignTx"> | TypedResponseMessage<"AlgorandSignedTx"> | TypedResponseMessage<"AptosGetAddress"> | TypedResponseMessage<"AptosAddress"> | TypedResponseMessage<"AptosSignTx"> | TypedResponseMessage<"AptosSignedTx"> | TypedResponseMessage<"AptosSignMessage"> | TypedResponseMessage<"AptosMessageSignature"> | TypedResponseMessage<"AptosSignSIWAMessage"> | TypedResponseMessage<"BenfenGetAddress"> | TypedResponseMessage<"BenfenAddress"> | TypedResponseMessage<"BenfenSignTx"> | TypedResponseMessage<"BenfenSignedTx"> | TypedResponseMessage<"BenfenTxRequest"> | TypedResponseMessage<"BenfenTxAck"> | TypedResponseMessage<"BenfenSignMessage"> | TypedResponseMessage<"BenfenMessageSignature"> | TypedResponseMessage<"BinanceGetAddress"> | TypedResponseMessage<"BinanceAddress"> | TypedResponseMessage<"BinanceGetPublicKey"> | TypedResponseMessage<"BinancePublicKey"> | TypedResponseMessage<"BinanceSignTx"> | TypedResponseMessage<"BinanceTxRequest"> | TypedResponseMessage<"BinanceTransferMsg"> | TypedResponseMessage<"BinanceOrderMsg"> | TypedResponseMessage<"BinanceCancelMsg"> | TypedResponseMessage<"BinanceSignedTx"> | TypedResponseMessage<"GetPublicKey"> | TypedResponseMessage<"PublicKey"> | TypedResponseMessage<"GetAddress"> | TypedResponseMessage<"GetOwnershipId"> | TypedResponseMessage<"OwnershipId"> | TypedResponseMessage<"SignMessage"> | TypedResponseMessage<"MessageSignature"> | TypedResponseMessage<"VerifyMessage"> | TypedResponseMessage<"SignTx"> | TypedResponseMessage<"TxRequest"> | TypedResponseMessage<"TxAck"> | TypedResponseMessage<"TxAckInput"> | TypedResponseMessage<"TxAckOutput"> | TypedResponseMessage<"TxAckPrevMeta"> | TypedResponseMessage<"TxAckPrevInput"> | TypedResponseMessage<"TxAckPrevOutput"> | TypedResponseMessage<"TxAckPrevExtraData"> | TypedResponseMessage<"GetOwnershipProof"> | TypedResponseMessage<"OwnershipProof"> | TypedResponseMessage<"AuthorizeCoinJoin"> | TypedResponseMessage<"GetPublicKeyMultiple"> | TypedResponseMessage<"PublicKeyMultiple"> | TypedResponseMessage<"SignPsbt"> | TypedResponseMessage<"SignedPsbt"> | TypedResponseMessage<"FirmwareErase"> | TypedResponseMessage<"FirmwareRequest"> | TypedResponseMessage<"FirmwareUpload"> | TypedResponseMessage<"SelfTest"> | TypedResponseMessage<"FirmwareErase_ex"> | TypedResponseMessage<"Reboot"> | TypedResponseMessage<"FirmwareUpdateEmmc"> | TypedResponseMessage<"UpgradeFileHeader"> | TypedResponseMessage<"CardanoGetNativeScriptHash"> | TypedResponseMessage<"CardanoNativeScriptHash"> | TypedResponseMessage<"CardanoGetAddress"> | TypedResponseMessage<"CardanoAddress"> | TypedResponseMessage<"CardanoGetPublicKey"> | TypedResponseMessage<"CardanoPublicKey"> | TypedResponseMessage<"CardanoSignTxInit"> | TypedResponseMessage<"CardanoTxInput"> | TypedResponseMessage<"CardanoTxOutput"> | TypedResponseMessage<"CardanoAssetGroup"> | TypedResponseMessage<"CardanoToken"> | TypedResponseMessage<"CardanoTxInlineDatumChunk"> | TypedResponseMessage<"CardanoTxReferenceScriptChunk"> | TypedResponseMessage<"CardanoPoolOwner"> | TypedResponseMessage<"CardanoPoolRelayParameters"> | TypedResponseMessage<"CardanoTxCertificate"> | TypedResponseMessage<"CardanoTxWithdrawal"> | TypedResponseMessage<"CardanoTxAuxiliaryData"> | TypedResponseMessage<"CardanoTxMint"> | TypedResponseMessage<"CardanoTxCollateralInput"> | TypedResponseMessage<"CardanoTxRequiredSigner"> | TypedResponseMessage<"CardanoTxReferenceInput"> | TypedResponseMessage<"CardanoTxItemAck"> | TypedResponseMessage<"CardanoTxAuxiliaryDataSupplement"> | TypedResponseMessage<"CardanoTxWitnessRequest"> | TypedResponseMessage<"CardanoTxWitnessResponse"> | TypedResponseMessage<"CardanoTxHostAck"> | TypedResponseMessage<"CardanoTxBodyHash"> | TypedResponseMessage<"CardanoSignTxFinished"> | TypedResponseMessage<"CardanoSignMessage"> | TypedResponseMessage<"CardanoMessageSignature"> | TypedResponseMessage<"Failure"> | TypedResponseMessage<"ButtonRequest"> | TypedResponseMessage<"ButtonAck"> | TypedResponseMessage<"PinMatrixRequest"> | TypedResponseMessage<"PinMatrixAck"> | TypedResponseMessage<"PassphraseRequest"> | TypedResponseMessage<"PassphraseAck"> | TypedResponseMessage<"Deprecated_PassphraseStateRequest"> | TypedResponseMessage<"Deprecated_PassphraseStateAck"> | TypedResponseMessage<"BixinPinInputOnDevice"> | TypedResponseMessage<"ConfluxGetAddress"> | TypedResponseMessage<"ConfluxAddress"> | TypedResponseMessage<"ConfluxSignTx"> | TypedResponseMessage<"ConfluxTxRequest"> | TypedResponseMessage<"ConfluxTxAck"> | TypedResponseMessage<"ConfluxSignMessage"> | TypedResponseMessage<"ConfluxMessageSignature"> | TypedResponseMessage<"ConfluxSignMessageCIP23"> | TypedResponseMessage<"CosmosGetAddress"> | TypedResponseMessage<"CosmosAddress"> | TypedResponseMessage<"CosmosSignTx"> | TypedResponseMessage<"CosmosSignedTx"> | TypedResponseMessage<"CipherKeyValue"> | TypedResponseMessage<"CipheredKeyValue"> | TypedResponseMessage<"SignIdentity"> | TypedResponseMessage<"SignedIdentity"> | TypedResponseMessage<"GetECDHSessionKey"> | TypedResponseMessage<"ECDHSessionKey"> | TypedResponseMessage<"BatchGetPublickeys"> | TypedResponseMessage<"EcdsaPublicKeys"> | TypedResponseMessage<"DnxGetAddress"> | TypedResponseMessage<"DnxAddress"> | TypedResponseMessage<"DnxSignTx"> | TypedResponseMessage<"DnxInputRequest"> | TypedResponseMessage<"DnxInputAck"> | TypedResponseMessage<"DnxRTSigsRequest"> | TypedResponseMessage<"DnxSignedTx"> | TypedResponseMessage<"EmmcFixPermission"> | TypedResponseMessage<"EmmcPath"> | TypedResponseMessage<"EmmcPathInfo"> | TypedResponseMessage<"EmmcFileRead"> | TypedResponseMessage<"EmmcFileWrite"> | TypedResponseMessage<"EmmcFileDelete"> | TypedResponseMessage<"EmmcDir"> | TypedResponseMessage<"EmmcDirList"> | TypedResponseMessage<"EmmcDirMake"> | TypedResponseMessage<"EmmcDirRemove"> | TypedResponseMessage<"EosGetPublicKey"> | TypedResponseMessage<"EosPublicKey"> | TypedResponseMessage<"EosSignTx"> | TypedResponseMessage<"EosTxActionRequest"> | TypedResponseMessage<"EosTxActionAck"> | TypedResponseMessage<"EosSignedTx"> | TypedResponseMessage<"EthereumNetworkInfo"> | TypedResponseMessage<"EthereumTokenInfo"> | TypedResponseMessage<"EthereumSignTypedDataOneKey"> | TypedResponseMessage<"EthereumGnosisSafeTxRequest"> | TypedResponseMessage<"EthereumGnosisSafeTxAck"> | TypedResponseMessage<"EthereumTypedDataStructRequestOneKey"> | TypedResponseMessage<"EthereumTypedDataStructAckOneKey"> | TypedResponseMessage<"EthereumTypedDataValueRequestOneKey"> | TypedResponseMessage<"EthereumTypedDataValueAckOneKey"> | TypedResponseMessage<"EthereumSignTypedData"> | TypedResponseMessage<"EthereumTypedDataStructRequest"> | TypedResponseMessage<"EthereumTypedDataStructAck"> | TypedResponseMessage<"EthereumTypedDataValueRequest"> | TypedResponseMessage<"EthereumTypedDataValueAck"> | TypedResponseMessage<"EthereumGetPublicKeyOneKey"> | TypedResponseMessage<"EthereumPublicKeyOneKey"> | TypedResponseMessage<"EthereumGetAddressOneKey"> | TypedResponseMessage<"EthereumAddressOneKey"> | TypedResponseMessage<"EthereumSignTxOneKey"> | TypedResponseMessage<"EthereumSignTxEIP1559OneKey"> | TypedResponseMessage<"EthereumSignTxEIP7702OneKey"> | TypedResponseMessage<"EthereumTxRequestOneKey"> | TypedResponseMessage<"EthereumTxAckOneKey"> | TypedResponseMessage<"EthereumSignMessageOneKey"> | TypedResponseMessage<"EthereumMessageSignatureOneKey"> | TypedResponseMessage<"EthereumVerifyMessageOneKey"> | TypedResponseMessage<"EthereumSignTypedHashOneKey"> | TypedResponseMessage<"EthereumTypedDataSignatureOneKey"> | TypedResponseMessage<"EthereumSignMessageEIP712"> | TypedResponseMessage<"EthereumGetPublicKey"> | TypedResponseMessage<"EthereumPublicKey"> | TypedResponseMessage<"EthereumGetAddress"> | TypedResponseMessage<"EthereumAddress"> | TypedResponseMessage<"EthereumSignTx"> | TypedResponseMessage<"EthereumSignTxEIP1559"> | TypedResponseMessage<"EthereumTxRequest"> | TypedResponseMessage<"EthereumTxAck"> | TypedResponseMessage<"EthereumSignMessage"> | TypedResponseMessage<"EthereumMessageSignature"> | TypedResponseMessage<"EthereumVerifyMessage"> | TypedResponseMessage<"EthereumSignTypedHash"> | TypedResponseMessage<"EthereumTypedDataSignature"> | TypedResponseMessage<"FilecoinGetAddress"> | TypedResponseMessage<"FilecoinAddress"> | TypedResponseMessage<"FilecoinSignTx"> | TypedResponseMessage<"FilecoinSignedTx"> | TypedResponseMessage<"KaspaGetAddress"> | TypedResponseMessage<"KaspaAddress"> | TypedResponseMessage<"KaspaSignTx"> | TypedResponseMessage<"KaspaTxInputRequest"> | TypedResponseMessage<"KaspaTxInputAck"> | TypedResponseMessage<"KaspaTxRequest"> | TypedResponseMessage<"KaspaTxAckInput"> | TypedResponseMessage<"KaspaTxAckOutput"> | TypedResponseMessage<"KaspaTxAckPayloadChunk"> | TypedResponseMessage<"KaspaTxAckPrevMeta"> | TypedResponseMessage<"KaspaTxAckPrevInput"> | TypedResponseMessage<"KaspaTxAckPrevOutput"> | TypedResponseMessage<"KaspaSignedTx"> | TypedResponseMessage<"LnurlAuth"> | TypedResponseMessage<"LnurlAuthResp"> | TypedResponseMessage<"Initialize"> | TypedResponseMessage<"GetFeatures"> | TypedResponseMessage<"OnekeyGetFeatures"> | TypedResponseMessage<"Features"> | TypedResponseMessage<"OnekeyFeatures"> | TypedResponseMessage<"LockDevice"> | TypedResponseMessage<"EndSession"> | TypedResponseMessage<"ApplySettings"> | TypedResponseMessage<"ApplyFlags"> | TypedResponseMessage<"ChangePin"> | TypedResponseMessage<"ChangeWipeCode"> | TypedResponseMessage<"SdProtect"> | TypedResponseMessage<"Ping"> | TypedResponseMessage<"Cancel"> | TypedResponseMessage<"GetEntropy"> | TypedResponseMessage<"Entropy"> | TypedResponseMessage<"WipeDevice"> | TypedResponseMessage<"ResetDevice"> | TypedResponseMessage<"BackupDevice"> | TypedResponseMessage<"EntropyRequest"> | TypedResponseMessage<"EntropyAck"> | TypedResponseMessage<"RecoveryDevice"> | TypedResponseMessage<"WordRequest"> | TypedResponseMessage<"WordAck"> | TypedResponseMessage<"SetU2FCounter"> | TypedResponseMessage<"GetNextU2FCounter"> | TypedResponseMessage<"NextU2FCounter"> | TypedResponseMessage<"DoPreauthorized"> | TypedResponseMessage<"PreauthorizedRequest"> | TypedResponseMessage<"CancelAuthorization"> | TypedResponseMessage<"BixinSeedOperate"> | TypedResponseMessage<"BixinMessageSE"> | TypedResponseMessage<"BixinOutMessageSE"> | TypedResponseMessage<"DeviceBackToBoot"> | TypedResponseMessage<"BixinBackupRequest"> | TypedResponseMessage<"BixinBackupAck"> | TypedResponseMessage<"BixinRestoreRequest"> | TypedResponseMessage<"BixinRestoreAck"> | TypedResponseMessage<"BixinVerifyDeviceRequest"> | TypedResponseMessage<"BixinVerifyDeviceAck"> | TypedResponseMessage<"BixinWhiteListRequest"> | TypedResponseMessage<"BixinWhiteListAck"> | TypedResponseMessage<"BixinLoadDevice"> | TypedResponseMessage<"BixinBackupDevice"> | TypedResponseMessage<"BixinBackupDeviceAck"> | TypedResponseMessage<"DeviceInfoSettings"> | TypedResponseMessage<"GetDeviceInfo"> | TypedResponseMessage<"ReadSEPublicKey"> | TypedResponseMessage<"SEPublicKey"> | TypedResponseMessage<"WriteSEPublicCert"> | TypedResponseMessage<"ReadSEPublicCert"> | TypedResponseMessage<"SEPublicCert"> | TypedResponseMessage<"SpiFlashWrite"> | TypedResponseMessage<"SpiFlashRead"> | TypedResponseMessage<"SpiFlashData"> | TypedResponseMessage<"SESignMessage"> | TypedResponseMessage<"SEMessageSignature"> | TypedResponseMessage<"ResourceUpload"> | TypedResponseMessage<"ZoomRequest"> | TypedResponseMessage<"BlurRequest"> | TypedResponseMessage<"ResourceRequest"> | TypedResponseMessage<"ResourceAck"> | TypedResponseMessage<"ResourceUpdate"> | TypedResponseMessage<"NFTWriteInfo"> | TypedResponseMessage<"NFTWriteData"> | TypedResponseMessage<"RebootToBootloader"> | TypedResponseMessage<"RebootToBoardloader"> | TypedResponseMessage<"ListResDir"> | TypedResponseMessage<"FileInfoList"> | TypedResponseMessage<"DeviceEraseSector"> | TypedResponseMessage<"UnLockDevice"> | TypedResponseMessage<"UnLockDeviceResponse"> | TypedResponseMessage<"GetPassphraseState"> | TypedResponseMessage<"MoneroGetAddress"> | TypedResponseMessage<"MoneroAddress"> | TypedResponseMessage<"MoneroGetWatchKey"> | TypedResponseMessage<"MoneroWatchKey"> | TypedResponseMessage<"MoneroTransactionInitRequest"> | TypedResponseMessage<"MoneroTransactionInitAck"> | TypedResponseMessage<"MoneroTransactionSetInputRequest"> | TypedResponseMessage<"MoneroTransactionSetInputAck"> | TypedResponseMessage<"MoneroTransactionInputsPermutationRequest"> | TypedResponseMessage<"MoneroTransactionInputsPermutationAck"> | TypedResponseMessage<"MoneroTransactionInputViniRequest"> | TypedResponseMessage<"MoneroTransactionInputViniAck"> | TypedResponseMessage<"MoneroTransactionAllInputsSetRequest"> | TypedResponseMessage<"MoneroTransactionAllInputsSetAck"> | TypedResponseMessage<"MoneroTransactionSetOutputRequest"> | TypedResponseMessage<"MoneroTransactionSetOutputAck"> | TypedResponseMessage<"MoneroTransactionAllOutSetRequest"> | TypedResponseMessage<"MoneroTransactionAllOutSetAck"> | TypedResponseMessage<"MoneroTransactionSignInputRequest"> | TypedResponseMessage<"MoneroTransactionSignInputAck"> | TypedResponseMessage<"MoneroTransactionFinalRequest"> | TypedResponseMessage<"MoneroTransactionFinalAck"> | TypedResponseMessage<"MoneroKeyImageExportInitRequest"> | TypedResponseMessage<"MoneroKeyImageExportInitAck"> | TypedResponseMessage<"MoneroKeyImageSyncStepRequest"> | TypedResponseMessage<"MoneroKeyImageSyncStepAck"> | TypedResponseMessage<"MoneroKeyImageSyncFinalRequest"> | TypedResponseMessage<"MoneroKeyImageSyncFinalAck"> | TypedResponseMessage<"MoneroGetTxKeyRequest"> | TypedResponseMessage<"MoneroGetTxKeyAck"> | TypedResponseMessage<"MoneroLiveRefreshStartRequest"> | TypedResponseMessage<"MoneroLiveRefreshStartAck"> | TypedResponseMessage<"MoneroLiveRefreshStepRequest"> | TypedResponseMessage<"MoneroLiveRefreshStepAck"> | TypedResponseMessage<"MoneroLiveRefreshFinalRequest"> | TypedResponseMessage<"MoneroLiveRefreshFinalAck"> | TypedResponseMessage<"NearGetAddress"> | TypedResponseMessage<"NearAddress"> | TypedResponseMessage<"NearSignTx"> | TypedResponseMessage<"NearSignedTx"> | TypedResponseMessage<"NEMGetAddress"> | TypedResponseMessage<"NEMAddress"> | TypedResponseMessage<"NEMSignTx"> | TypedResponseMessage<"NEMSignedTx"> | TypedResponseMessage<"NEMDecryptMessage"> | TypedResponseMessage<"NEMDecryptedMessage"> | TypedResponseMessage<"NeoGetAddress"> | TypedResponseMessage<"NeoAddress"> | TypedResponseMessage<"NeoSignTx"> | TypedResponseMessage<"NeoSignedTx"> | TypedResponseMessage<"NervosGetAddress"> | TypedResponseMessage<"NervosAddress"> | TypedResponseMessage<"NervosSignTx"> | TypedResponseMessage<"NervosSignedTx"> | TypedResponseMessage<"NervosTxRequest"> | TypedResponseMessage<"NervosTxAck"> | TypedResponseMessage<"NexaGetAddress"> | TypedResponseMessage<"NexaAddress"> | TypedResponseMessage<"NexaSignTx"> | TypedResponseMessage<"NexaTxInputRequest"> | TypedResponseMessage<"NexaTxInputAck"> | TypedResponseMessage<"NexaSignedTx"> | TypedResponseMessage<"NostrGetPublicKey"> | TypedResponseMessage<"NostrPublicKey"> | TypedResponseMessage<"NostrSignEvent"> | TypedResponseMessage<"NostrSignedEvent"> | TypedResponseMessage<"NostrSignSchnorr"> | TypedResponseMessage<"NostrSignedSchnorr"> | TypedResponseMessage<"NostrEncryptMessage"> | TypedResponseMessage<"NostrEncryptedMessage"> | TypedResponseMessage<"NostrDecryptMessage"> | TypedResponseMessage<"NostrDecryptedMessage"> | TypedResponseMessage<"PolkadotGetAddress"> | TypedResponseMessage<"PolkadotAddress"> | TypedResponseMessage<"PolkadotSignTx"> | TypedResponseMessage<"PolkadotSignedTx"> | TypedResponseMessage<"RippleGetAddress"> | TypedResponseMessage<"RippleAddress"> | TypedResponseMessage<"RippleSignTx"> | TypedResponseMessage<"RippleSignedTx"> | TypedResponseMessage<"ScdoGetAddress"> | TypedResponseMessage<"ScdoAddress"> | TypedResponseMessage<"ScdoSignTx"> | TypedResponseMessage<"ScdoSignedTx"> | TypedResponseMessage<"ScdoTxAck"> | TypedResponseMessage<"ScdoSignMessage"> | TypedResponseMessage<"ScdoSignedMessage"> | TypedResponseMessage<"SolanaGetAddress"> | TypedResponseMessage<"SolanaAddress"> | TypedResponseMessage<"SolanaSignTx"> | TypedResponseMessage<"SolanaSignedTx"> | TypedResponseMessage<"SolanaSignOffChainMessage"> | TypedResponseMessage<"SolanaSignUnsafeMessage"> | TypedResponseMessage<"SolanaMessageSignature"> | TypedResponseMessage<"StarcoinGetAddress"> | TypedResponseMessage<"StarcoinAddress"> | TypedResponseMessage<"StarcoinGetPublicKey"> | TypedResponseMessage<"StarcoinPublicKey"> | TypedResponseMessage<"StarcoinSignTx"> | TypedResponseMessage<"StarcoinSignedTx"> | TypedResponseMessage<"StarcoinSignMessage"> | TypedResponseMessage<"StarcoinMessageSignature"> | TypedResponseMessage<"StarcoinVerifyMessage"> | TypedResponseMessage<"StellarGetAddress"> | TypedResponseMessage<"StellarAddress"> | TypedResponseMessage<"StellarSignTx"> | TypedResponseMessage<"StellarTxOpRequest"> | TypedResponseMessage<"StellarPaymentOp"> | TypedResponseMessage<"StellarCreateAccountOp"> | TypedResponseMessage<"StellarPathPaymentStrictReceiveOp"> | TypedResponseMessage<"StellarPathPaymentStrictSendOp"> | TypedResponseMessage<"StellarManageSellOfferOp"> | TypedResponseMessage<"StellarManageBuyOfferOp"> | TypedResponseMessage<"StellarCreatePassiveSellOfferOp"> | TypedResponseMessage<"StellarSetOptionsOp"> | TypedResponseMessage<"StellarChangeTrustOp"> | TypedResponseMessage<"StellarAllowTrustOp"> | TypedResponseMessage<"StellarAccountMergeOp"> | TypedResponseMessage<"StellarManageDataOp"> | TypedResponseMessage<"StellarBumpSequenceOp"> | TypedResponseMessage<"StellarInvokeHostFunctionOp"> | TypedResponseMessage<"StellarSorobanDataRequest"> | TypedResponseMessage<"StellarSorobanDataAck"> | TypedResponseMessage<"StellarSignedTx"> | TypedResponseMessage<"SuiGetAddress"> | TypedResponseMessage<"SuiAddress"> | TypedResponseMessage<"SuiSignTx"> | TypedResponseMessage<"SuiSignedTx"> | TypedResponseMessage<"SuiTxRequest"> | TypedResponseMessage<"SuiTxAck"> | TypedResponseMessage<"SuiSignMessage"> | TypedResponseMessage<"SuiMessageSignature"> | TypedResponseMessage<"TezosGetAddress"> | TypedResponseMessage<"TezosAddress"> | TypedResponseMessage<"TezosGetPublicKey"> | TypedResponseMessage<"TezosPublicKey"> | TypedResponseMessage<"TezosSignTx"> | TypedResponseMessage<"TezosSignedTx"> | TypedResponseMessage<"TonGetAddress"> | TypedResponseMessage<"TonAddress"> | TypedResponseMessage<"TonSignMessage"> | TypedResponseMessage<"TonTxAck"> | TypedResponseMessage<"TonSignedMessage"> | TypedResponseMessage<"TonSignProof"> | TypedResponseMessage<"TonSignedProof"> | TypedResponseMessage<"TonSignData"> | TypedResponseMessage<"TonSignedData"> | TypedResponseMessage<"TronGetAddress"> | TypedResponseMessage<"TronAddress"> | TypedResponseMessage<"TronSignTx"> | TypedResponseMessage<"TronSignedTx"> | TypedResponseMessage<"TronSignMessage"> | TypedResponseMessage<"TronMessageSignature"> | TypedResponseMessage<"facotry"> | TypedResponseMessage<"experimental_message"> | TypedResponseMessage<"experimental_field"> | TypedResponseMessage<"TxAckPaymentRequest"> | TypedResponseMessage<"EthereumSignTypedDataQR"> | TypedResponseMessage<"InternalMyAddressRequest"> | TypedResponseMessage<"StartSession"> | TypedResponseMessage<"SetBusy"> | TypedResponseMessage<"GetFirmwareHash"> | TypedResponseMessage<"FirmwareHash"> | TypedResponseMessage<"GetNonce"> | TypedResponseMessage<"Nonce"> | TypedResponseMessage<"WriteSEPrivateKey"> | TypedResponseMessage<"SetWallpaper"> | TypedResponseMessage<"GetWallpaper"> | TypedResponseMessage<"Wallpaper"> | TypedResponseMessage<"UnlockPath"> | TypedResponseMessage<"UnlockedPathRequest"> | TypedResponseMessage<"ViewSignPage"> | TypedResponseMessage<"ViewVerifyPage"> | TypedResponseMessage<"ProtocolInfoRequest"> | TypedResponseMessage<"ProtocolInfo"> | TypedResponseMessage<"DeviceReboot"> | TypedResponseMessage<"DeviceSettingsGet"> | TypedResponseMessage<"DeviceSettingsSet"> | TypedResponseMessage<"DeviceSettingsPageShow"> | TypedResponseMessage<"DeviceCertificateWrite"> | TypedResponseMessage<"DeviceCertificateRead"> | TypedResponseMessage<"DeviceCertificateSignature"> | TypedResponseMessage<"DeviceCertificateSign"> | TypedResponseMessage<"DeviceFirmwareUpdateRequest"> | TypedResponseMessage<"DeviceFirmwareUpdateStatusGet"> | TypedResponseMessage<"DeviceFactoryInfoSet"> | TypedResponseMessage<"DeviceFactoryInfoGet"> | TypedResponseMessage<"DeviceFactoryPermanentLock"> | TypedResponseMessage<"DeviceFactoryTest"> | TypedResponseMessage<"DeviceInfoGet"> | TypedResponseMessage<"DeviceSessionOpen"> | TypedResponseMessage<"DeviceSessionAskPin"> | TypedResponseMessage<"DeviceStatusGet"> | TypedResponseMessage<"DevGetOnboardingStatus"> | TypedResponseMessage<"DevOnboardingStatus"> | TypedResponseMessage<"FilesystemPermissionFix"> | TypedResponseMessage<"FilesystemPathInfo"> | TypedResponseMessage<"FilesystemPathInfoQuery"> | TypedResponseMessage<"FilesystemFileRead"> | TypedResponseMessage<"FilesystemFileWrite"> | TypedResponseMessage<"FilesystemFileDelete"> | TypedResponseMessage<"FilesystemDir"> | TypedResponseMessage<"FilesystemDirList"> | TypedResponseMessage<"FilesystemDirMake"> | TypedResponseMessage<"FilesystemDirRemove"> | TypedResponseMessage<"FilesystemFormat"> | TypedResponseMessage<"PortfolioUpdate">;
|
|
3899
3948
|
|
|
3900
3949
|
declare const getDeviceType: (features?: Features) => IDeviceType;
|
|
3901
3950
|
declare const getDeviceTypeByBleName: (name?: string) => IDeviceType;
|
|
@@ -4028,4 +4077,4 @@ declare const HardwareSdk: ({ init, call, dispose, eventEmitter, uiResponse, can
|
|
|
4028
4077
|
declare const HardwareSDKLowLevel: ({ init, call, dispose, eventEmitter, addHardwareGlobalEventListener, uiResponse, cancel, cancelOperation, updateSettings, switchTransport, }: LowLevelInjectApi) => LowLevelCoreApi;
|
|
4029
4078
|
declare const HardwareTopLevelSdk: () => CoreApi;
|
|
4030
4079
|
|
|
4031
|
-
export { AccountAddress, AccountAddresses, AlephiumAddress, AlephiumGetAddressParams, AlephiumSignMessageParams, AlephiumSignTransactionParams, AlephiumSignedTx, AlgoAddress, AlgoGetAddressParams, AlgoSignTransactionParams, AlgoSignedTx, AllFirmwareRelease, AllNetworkAddressParams, AllNetworkGetAddressParams, AptosAddress, AptosGetAddressParams, AptosGetPublicKeyParams, AptosMessageSignature, AptosPublicKey, AptosSignInMessageParams, AptosSignInMessageSignature, AptosSignMessageParams, AptosSignTransactionParams, AptosSignedTx, AssetsMap, BTCAddress, BTCGetAddressParams, BTCGetPublicKeyParams, BTCPublicKey, BTCSignMessageParams, BTCSignTransactionParams, BTCVerifyMessageParams, BenfenAddress, BenfenGetAddressParams, BenfenGetPublicKeyParams, BenfenPublicKey, BenfenSignMessageParams, BenfenSignTransactionParams, BenfenSignedTx, BleReleaseInfoEvent, BleReleaseInfoPayload, CORE_EVENT, CallMethod, CallMethodAnyResponse, CallMethodKeys, CallMethodPayload, CallMethodResponse, CallMethodUnion, CardanoAddress, CardanoGetAddressMethodParams, CardanoGetAddressParams, CardanoSignMessageMethodParams, CardanoSignMessageParams, CardanoSignTransaction, CardanoSignedTxData, CipheredKeyValue, CipheredKeyValueParams, ClearSessionCacheParams, ClearSessionCachePayload, CommonParams, ConfluxAddress, ConfluxGetAddressParams, ConfluxSignMessageCIP23Params, ConfluxSignMessageParams, ConfluxSignTransactionParams, ConfluxSignedTx, ConfluxTransaction, ConnectSettings, Core, CoreApi, CoreMessage, CosmosAddress, CosmosGetAddressParams, CosmosGetPublicKeyParams, CosmosPublicKey, CosmosSignTransactionParams, CosmosSignedTx, DEFAULT_PRIORITY, DEVICE, DEVICE_EVENT, DataManager, Device, DeviceButtonRequest, DeviceButtonRequestPayload, DeviceChangePinParams, DeviceConnnectRequest, DeviceDisconnnectRequest, DeviceEvent, DeviceEventListenerFn, DeviceEventMessage, DeviceFeaturesMode, DeviceFeaturesPayload, DeviceFeaturesProtocol, DeviceFeaturesRaw, DeviceFeaturesVerify, DeviceFirmwareRange, DeviceFlagsParams,
|
|
4080
|
+
export { AccountAddress, AccountAddresses, AlephiumAddress, AlephiumGetAddressParams, AlephiumSignMessageParams, AlephiumSignTransactionParams, AlephiumSignedTx, AlgoAddress, AlgoGetAddressParams, AlgoSignTransactionParams, AlgoSignedTx, AllFirmwareRelease, AllNetworkAddressParams, AllNetworkGetAddressParams, AptosAddress, AptosGetAddressParams, AptosGetPublicKeyParams, AptosMessageSignature, AptosPublicKey, AptosSignInMessageParams, AptosSignInMessageSignature, AptosSignMessageParams, AptosSignTransactionParams, AptosSignedTx, AssetsMap, BTCAddress, BTCGetAddressParams, BTCGetPublicKeyParams, BTCPublicKey, BTCSignMessageParams, BTCSignTransactionParams, BTCVerifyMessageParams, BenfenAddress, BenfenGetAddressParams, BenfenGetPublicKeyParams, BenfenPublicKey, BenfenSignMessageParams, BenfenSignTransactionParams, BenfenSignedTx, BleReleaseInfoEvent, BleReleaseInfoPayload, CORE_EVENT, CallMethod, CallMethodAnyResponse, CallMethodKeys, CallMethodPayload, CallMethodResponse, CallMethodUnion, CardanoAddress, CardanoGetAddressMethodParams, CardanoGetAddressParams, CardanoSignMessageMethodParams, CardanoSignMessageParams, CardanoSignTransaction, CardanoSignedTxData, CipheredKeyValue, CipheredKeyValueParams, ClearSessionCacheParams, ClearSessionCachePayload, CommonParams, ConfluxAddress, ConfluxGetAddressParams, ConfluxSignMessageCIP23Params, ConfluxSignMessageParams, ConfluxSignTransactionParams, ConfluxSignedTx, ConfluxTransaction, ConnectSettings, Core, CoreApi, CoreMessage, CosmosAddress, CosmosGetAddressParams, CosmosGetPublicKeyParams, CosmosPublicKey, CosmosSignTransactionParams, CosmosSignedTx, DEFAULT_PRIORITY, DEVICE, DEVICE_EVENT, DataManager, Device$1 as Device, DeviceButtonRequest, DeviceButtonRequestPayload, DeviceChangePinParams, DeviceConnnectRequest, DeviceDisconnnectRequest, DeviceEvent, DeviceEventListenerFn, DeviceEventMessage, DeviceFeaturesMode, DeviceFeaturesPayload, DeviceFeaturesProtocol, DeviceFeaturesRaw, DeviceFeaturesRawPatch, DeviceFeaturesVerify, DeviceFirmwareRange, DeviceFlagsParams, DeviceModelToTypes, DeviceProgress, DeviceRecoveryParams, DeviceResetParams, DeviceSendFeatures, DeviceSendState, DeviceSendSupportFeatures, DeviceSettingsParams, DeviceState, DeviceStateEvent, DeviceStateIdentity, DeviceStateMode, DeviceStatePatch, DeviceStateProtocol, DeviceStateScope, DeviceStateSection, DeviceStateSession, DeviceStateSettings, DeviceStateStatus, DeviceStateUpdateSource, DeviceStateVersions, DeviceStatus, DeviceSupportFeatures, DeviceSupportFeaturesPayload, DeviceTypeMap, DeviceTypeToModels, DeviceUploadResourceParams, DeviceUploadResourceResponse, DeviceVerifyParams, DeviceVerifySignature, DnxAddress, DnxGetAddressParams, DnxSignTransactionParams, DnxSignature, DnxTxKey, EOneKeyDeviceMode, EVMAccessList, EVMAddress, EVMAuthorization, EVMAuthorizationSignature, EVMGetAddressParams, EVMGetPublicKeyParams, EVMPublicKey, EVMSignMessageEIP712Params, EVMSignMessageParams, EVMSignTransactionParams, EVMSignTypedDataParams, EVMSignedTx, EVMTransaction, EVMTransactionEIP1559, EVMTransactionEIP7702, EVMVerifyMessageParams, EthereumSignTypedDataMessage, EthereumSignTypedDataTypeProperty, EthereumSignTypedDataTypes, FIRMWARE, FIRMWARE_EVENT, Features, FilecoinAddress, FilecoinGetAddressParams, FilecoinSignTransactionParams, FilecoinSignedTx, FirmwareEvent, FirmwareMessage, FirmwareProcessing, FirmwareProgress, FirmwareRange, FirmwareRelease, FirmwareTip, FirmwareUpdateBinaryParams, FirmwareUpdateParams, FirmwareUpdateTipMessage, FirmwareUpdateV3Params, FirmwareUpdateV4Params, GetDeviceStateParams, GetPassphraseStateParams, HardwareSDKLowLevel, HardwareTopLevelSdk, IBLEFirmwareReleaseInfo, IDeviceBLEFirmwareStatus, IDeviceFirmwareStatus, IDeviceModel, IDeviceType, IFRAME, IFirmwareField, IFirmwareReleaseInfo, IFirmwareUpdateProgressType, IFirmwareUpdateTipMessage, IFrameBridge, IFrameCallMessage, IFrameCallback, IFrameCallbackMessage, IFrameCancelMessage, IFrameCancelOperationMessage, IFrameEvent, IFrameEventMessage, IFrameInit, IFrameSwitchTransport, IFrameSwitchTransportMessage, ILocale, IProtocolV2FirmwareComponent, IProtocolV2FirmwareComponentTarget, IProtocolV2ResourceBundle, ITransportStatus, IVersionArray, IVersionRange, KaspaAddress, KaspaGetAddressParams, KaspaSignInputParams, KaspaSignOutputParams, KaspaSignTransactionParams, KaspaSignature, KnownDevice, LOG, LOG_EVENT, LogBlockEvent, LogEvent, LogEventMessage, LogOutput, LoggerNames, LowLevelCoreApi, LowLevelInjectApi, MajorVersion, MethodResponseMessage, NEMAddress, NEMAggregateModificationTransaction, NEMGetAddressParams, NEMImportanceTransaction, NEMMosaic, NEMMosaicCreationTransaction, NEMMultisigTransaction, NEMProvisionNamespaceTransaction, NEMSignTransactionParams, NEMSupplyChangeTransaction, NEMTransaction, NEMTransferTransaction, NearAddress, NearGetAddressParams, NearSignTransactionParams, NervosAddress, NervosGetAddressParams, NervosSignTransactionParams, NervosSignedTx, NexaAddress, NexaGetAddressParams, NexaSignInputParams, NexaSignOutputParams, NexaSignTransactionParams, NexaSignature, NormalizedFeatures, OnekeyFeatures, PRO2_WALLPAPER_HEIGHT, PRO2_WALLPAPER_WIDTH, Params, PassphraseRequestPayload, PolkadotAddress, PolkadotGetAddressParams, PolkadotSignTransactionParams, PolkadotSignedTx, PostMessageEvent, PreviousAddressResult, Pro2WallpaperColorFormat, ProtocolV2UiCompletion, ProtocolV2UiEventMetadata, ProtocolV2UiEventSource, RESPONSE_EVENT, RefTransaction, ReleaseInfo, ReleaseInfoEvent, ReleaseInfoPayload, RemoteConfigResponse, RequestContext, Response, ScdoAddress, ScdoGetAddressParams, ScdoSignMessageParams, ScdoSignTransactionParams, ScdoSignedTx, SdkTracingContext, SearchDevice, SignedTransaction, SolSignMessageParams, SolSignMessageResponse, SolSignOffchainMessageParams, SolSignOffchainMessageResponse, SolanaAddress, SolanaGetAddressParams, SolanaSignTransactionParams, SolanaSignedTx, StarcoinAddress, StarcoinGetAddressParams, StarcoinGetPublicKeyParams, StarcoinPublicKey, StarcoinSignMessageParams, StarcoinSignTransactionParams, StarcoinVerifyMessageParams, StellarAddress, StellarAsset, StellarGetAddressParams, StellarOperation, StellarSignTransactionParams, StellarTransaction, StrictFeatures, Success, SuiAddress, SuiGetAddressParams, SuiGetPublicKeyParams, SuiPublicKey, SuiSignMessageParams, SuiSignTransactionParams, SuiSignedTx, SupportFeatureType, SupportFeatures, TonAddress, TonGetAddressParams, TonSignDataParams, TonSignMessageParams, TonSignProofParams, TopLevelInjectApi, TransactionOptions, TransportReleaseStatus, TronAddress, TronDelegateResourceContract, TronFreezeBalanceV2Contract, TronGetAddressParams, TronSignMessageParams, TronSignTransactionParams, TronTransaction, TronTransactionContract, TronTransferContract, TronTriggerSmartContract, TronUnDelegateResourceContract, TronUnfreezeBalanceV2Contract, TronWithdrawBalanceContract, TronWithdrawExpireUnfreezeContract, UI_EVENT, UI_REQUEST, UI_RESPONSE, UiEvent, UiEventMessage, UiPromise, UiPromiseResponse, UiRequestButton, UiRequestDeviceAction, UiRequestFirmwareProgressing, UiRequestPassphrase, UiRequestPassphraseOnDevice, UiRequestSelectDeviceForSwitchFirmwareWebDevice, UiRequestSelectDeviceInBootloaderForWebDevice, UiRequestWithoutPayload, UiResponseEvent, UiResponseMessage, UiResponsePassphrase, UiResponsePin, UiResponseSelectDeviceForSwitchFirmwareWebDevice, UiResponseSelectDeviceInBootloaderForWebDevice, UnavailableCapabilities, UnavailableCapability, Unsuccessful, VersionArray, checkNeedUpdateBootForClassicAndMini, checkNeedUpdateBootForTouch, cleanupCallback, cleanupSdkInstance, completeRequestContext, corsValidator, createDeviceMessage, createErrorMessage, createFirmwareMessage, createIFrameMessage, createLogMessage, createRequestContext, createResponseMessage, createSdkTracingContext, createUiMessage, createUiResponse, HardwareSdk as default, enableLog, encodePro2Wallpaper, executeCallback, formatRequestContext, generateInstanceId, generateSdkInstanceId, getActiveRequestsByDeviceInstance, getAutoLockOptions, getAutoShutDownOptions, getDeviceBLEFirmwareVersion, getDeviceBleName, getDeviceBoardloaderVersion, getDeviceBootloaderVersion, getDeviceFirmwareVersion, getDeviceLabel, getDeviceType, getDeviceTypeByBleName, getDeviceUUID, getEnv, getFirmwareType, getFirmwareUpdateField, getFirmwareUpdateFieldArray, getHDPath, getHomeScreenDefaultList, getHomeScreenHex, getHomeScreenSize, getLanguageConfig, getLog, getLogBlockLabel, getLogger, getMethodVersionRange, getOutputScriptType, getSDKVersion, getScriptType, getTimeStamp, httpRequest, init$1 as initCore, isBleConnect, isMethodVersionRangeUnsupported, isValidVersionArray, isValidVersionString, normalizeVersionArray, parseConnectSettings, parseMessage, patchFeatures, preloadSessionCache, safeThrowError, setLoggerPostMessage, supportInputPinOnSoftware, switchTransport, transportEnv, updateRequestContext, versionCompare, versionSplit, wait, whitelist, whitelistExtension };
|