Using node-red-contrib-toyota-myt

I am trying to access my new Toyota via Connected Services, using Node-Red. Found a node that looks promising.
Downloaded it, imported into a flow, filled all required fields and attached debug nodes to the four outputs.
But it is unclear how this node gets triggered: there is an input connector, but what should it connect to?

I tried to contact the author, but no response yet. Node was last updated 3 yrs, 2 mnths ago, so perhaps the author has lost interest and is no longer active.

Does anyone have experience using this node?
Alternatively, is there another way to pull information from the car?

Looking at the nodes source, it does not expect anything - but since the author put the active code in the oninput handler, it means you do need to fire something into it for it to "do its thing". So just wire an inject node into it. It doesnt really matter what is inside the injected msg (since the node doesnt consume the msg in any way!)

TBF, all that node does is 4 HTTP requests - all easily replicated using the built in http-request node (i.e. you dont really need this contrib node)

Thanks for looking into this, Steve.

I have already tried to inject a timestamp, nothing happens. Also tried to find the source, but cannot find it....

Hans

Stephen McLaughlin via Node-RED Forum schreef op 19-03-2025 17:48:

I linked the source ↓

If you mean on your installation, it will be under node_modules in your .node-red directory

Did you connect a wire from the inject to the input of the node-red-contrib-toyota-myt node??
Did you wire a debug to the output(s) of the node-red-contrib-toyota-myt node?

Did you see any errors in the node-red console? (the source shows a catch that feeds any error to console.log (link to source: node-red-contrib-toyota-myt/MyT.js at f171e7e5ce2ab93fa0573d3700ff2eba0747f236 · zoernert/node-red-contrib-toyota-myt · GitHub)

Steve,

I connected the inject node to the input, and four debug nodes to the output connectors, and deployed.
When I click the inject node, nothing happens.
No debug messages, nor any errors in the debug window at the right.
I assume that is what you mean by "node-red console"?

thanks for your patience, I am struggling....

Hans

Stephen McLaughlin via Node-RED Forum schreef op 19-03-2025 20:41:

No. Node-red outputs to std out. How do you launch node-red?

If you are running it on a pi/Debian based system and installed using the official script, you can run node-red-log in a terminal and watch the std out output.

OK, now I see some info.

node-red-log


      host: 'myt-agg.toyota-europe.com',
      protocol: 'https:',
      _redirectable: [Writable],
      [Symbol(shapeMode)]: false,
      [Symbol(kCapture)]: false,
      [Symbol(kBytesWritten)]: 0,
      [Symbol(kNeedDrain)]: false,
      [Symbol(corked)]: 0,
      [Symbol(kOutHeaders)]: [Object: null prototype],
      [Symbol(errored)]: null,
      [Symbol(kHighWaterMark)]: 16384,
      [Symbol(kRejectNonStandardBodyWrites)]: false,
      [Symbol(kUniqueHeaders)]: null
    },
    data: {
      timestamp: 1742418180160,
      status: 403,
      error: 'Forbidden',
      message: 'Verification is missing.',
      errorCode: 'CMA403'
    }
  },
  isAxiosError: true,
  toJSON: [Function: toJSON]
}

I assume 403 means "not authorized". But I am 100% sure that I use the same mail address and password that I use to log into the Android app!

403 means forbidden

The source code seems to expect a username (though email and username is often interchangeable). Perhaps it is a clue?

Not really, I think it should be the same info as what I use for the app, which is my mail address and a password. I don't have a username.
Also, when I look at the fields when editing the node, it says "Email"...