On this page

latest contributor to this doc

Last Edit:

@gcharang

Komodo DeFi Framework Method: task::init_trezor::user_action

API-v2task::init_trezor::user_action

When you see the pin grid on your device, or it asks for a passphrase word, use this method.

Parameter* = requiredTypeDescription
task_id*
integer
The identifying number returned when initiating the initialisation process.
user_action*
object
Object containing the params below
user_action.action_type*
string
Either TrezorPin or TrezorPassphrase, depending on which is requested by responses from related methods returning "status": "UserActionRequired"
user_action.passphrase
string
Optional. The passphrase functions like an extra word added to your recovery seed, and it used to access hidden wallets. To access the default wallet, input an empty string here.
user_action.pin
string (number)
Optional. When the Trezor device is displaying a grid of numbers for PIN entry, this param will contain your Trezor pin, as mapped through your keyboard numpad. See the image below for more information.
Trezor Pin

Parameter* = requiredTypeDescription
result*
string
The outcome of the request.

Even an incorrect PIN will return success. This doesn't mean the PIN was accepted, just that it was communicated without errors. If the PIN was incorrect, you will see an error like below in the next response for a method that requires authentication.

{
  "mmrpc": "2.0",
  "result": {
    "status": "Error",
    "details": {
      "error": "Error on platform coin KMD creation: Hardware Wallet context is not initialized",
      "error_path": "lib.init_utxo_standard_activation.utxo_coin_builder",
      "error_trace": "lib:103] init_utxo_standard_activation:79] utxo_coin_builder:317]",
      "error_type": "CoinCreationError",
      "error_data": {
        "ticker": "KMD",
        "error": "Hardware Wallet context is not initialized"
      }
    }
  },
  "id": null
}

task::init_trezor::user_action

POST
task::init_trezor::user_action
{
  "userpass": "RPC_UserP@SSW0RD",
  "mmrpc": "2.0",
  "method": "task::init_trezor::user_action",
  "params": {
    "task_id": 0,
    "user_action": {
      "action_type": "TrezorPin",
      "pin": "862743"
    }
  }
}

task::init_trezor::user_action

POST
task::init_trezor::user_action
{
  "userpass": "RPC_UserP@SSW0RD",
  "mmrpc": "2.0",
  "method": "task::init_trezor::user_action",
  "params": {
    "task_id": 0,
    "user_action": {
      "action_type": "TrezorPassphrase",
      "passphrase": "breakfast"
    }
  }
}

{
  "mmrpc": "2.0",
  "result": "success",
  "id": null
}