philliphoff / carwings2 Goto Github PK
View Code? Open in Web Editor NEWA Node.js client library for the Nissan Leaf "Carwings" API
License: MIT License
A Node.js client library for the Nissan Leaf "Carwings" API
License: MIT License
Is this project still active? When attempting to run the sample script I get a http 404 not found error, see below. Has maybe the carwings URL changed?
Error: Response was status code: 404 (Not Found)
at Request._callback (C:\Users\Todd\Desktop\node_modules\carwings2\release\Api.js:29:33)
at Request.self.callback (C:\Users\Todd\Desktop\node_modules\request\request.js:185:22)
at Request.emit (events.js:198:13)
at Request.<anonymous> (C:\Users\Todd\Desktop\node_modules\request\request.js:1161:10)
at Request.emit (events.js:198:13)
at IncomingMessage.<anonymous> (C:\Users\Todd\Desktop\node_modules\request\request.js:1083:12)
at Object.onceWrapper (events.js:286:20)
at IncomingMessage.emit (events.js:203:15)
at endReadableNT (_stream_readable.js:1145:12)
at process._tickCallback (internal/process/next_tick.js:63:19)
I've forked the repo here https://github.com/matthew1001/carwings2-mrw and updated the code to work for the NNE (Europe) region. There are a bunch of temporary changes in my fork (my own custom build scripts etc) that I plan to remove, different git URL etc., but once those are taken back out are you happy accepting the changes as a PR?
It will be fine if we can have a node-red node for NissanConnect EV.
npm install carwings2 --save npm WARN saveError ENOENT: no such file or directory, open '/tmp/package.json' npm WARN enoent ENOENT: no such file or directory, open '/tmp/package.json' npm WARN tmp No description npm WARN tmp No repository field. npm WARN tmp No README data npm WARN tmp No license field.
And when I start a a script :
`node /tmp/leaf.js
module.js:327
throw err;
^
Error: Cannot find module 'carwings2'
at Function.Module._resolveFilename (module.js:325:15)
at Function.Module._load (module.js:276:25)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at Object. (/tmp/leaf.js:1:78)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Function.Module.runMain (module.js:441:10)
`
I am getting the following error when running the sample getLiveStatus.js
{"status":404,"message":"INVALID PARAMS"}
Response did not include vehicle information.
Response did not include a customer info object.
Error: Login failed
at C:\Users\sean.trace\Documents\nissan\node_modules\carwings2\release\Client.js:26:37
at Request._callback (C:\Users\sean.trace\Documents\nissan\node_modules\carwings2\release\Api.js:53:13)
at Request.self.callback (C:\Users\sean.trace\Documents\nissan\node_modules\request\request.js:185:22)
at Request.emit (events.js:182:13)
at Request.<anonymous> (C:\Users\sean.trace\Documents\nissan\node_modules\request\request.js:1161:10)
at Request.emit (events.js:182:13)
at IncomingMessage.<anonymous> (C:\Users\sean.trace\Documents\nissan\node_modules\request\request.js:1083:12)
at Object.onceWrapper (events.js:273:13)
at IncomingMessage.emit (events.js:187:15)
at endReadableNT (_stream_readable.js:1094:12)
The python version is working still.
Hi,
With my 2018 Leaf in Belgium, Carwings2 works fine most of the time. I use Python 3.7.3.
Sometimes I get errors that I could not properly analyze as I did not output the log into a file.
Now, I added error handling in my object that calls Carwings and stream the logging into a file.
Last night I got the following 2 errors:
DEBUG:pycarwings2.pycarwings2:Response HTTP Response Body: b'{"status":401}'
ERROR:pycarwings2.pycarwings2:carwings error; logging in and trying request again: {'status': 401}
-- after this, logging in and getting the parameters worked normally
The server is temporarily unable to service your\nrequest due to maintenance downtime or capacity\nproblems. Please try again later.
\n\n'As a learning, I will reduce the frequency of requests when I get a 503 error.
My conclusion: the Carwings2 module works fine.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.