Comments (7)
The 1.0.2 to be released supports CommonJS. I need some time for a complete test. If you are willing to try it out,
You can add https://github.com/coolkit-carl/ewelink-api-next/tree/main/dist These four files add https://github.com/coolkit-carl/ewelink-api-next/blob/main/package.json Copy this file to your node_modules, delete the content from the previous 'dist'.
Then you can use it, like this:
const eWeLink = require('ewelink-api-next').default
const client = new eWeLink.WebAPI({
appId: 'xxx',
appSecret: 'xxx',
region: 'eu',
logObj: eWeLink.createLogger('eu'),
})
;(async () => {
let response = await client.user.login({
account: 'xxx',
password: 'xxx',
areaCode: '+1',
})
console.info(JSON.stringify(response))
})()
from ewelink-api.
Hi carl
Thanks for the information.
We are facing a problem with my own APPID as #220 (comment)
Please tell us how to solve the error that appears when setDevice method.
from ewelink-api.
This is an example of eWeLink OAuth2.0 login:https://github.com/coolkit-carl/eWeLinkOAuthLoginDemo
from ewelink-api.
@coolkit-carl This new library https://www.npmjs.com/package/ewelink-api-next its broken : Error [ERR_REQUIRE_ESM]: require() of ES Module!! ewelink-api-next/dist/utils/index.js
from ewelink-api.
Did you miss this bit in the readme?
from ewelink-api.
Did you miss this bit in the readme?
I know that, but at the moment I can't use type module;
from ewelink-api.
Hi,
As a skilled back end developer, I have a rich experience in API development using node.js.
I saw your job post in upwork.
I wanna work with you.
Please contact me.
Thank you.
from ewelink-api.
Related Issues (20)
- Install error
- Trouble with getDevicePowerUsage
- How do I know the type of device (Power meter, thermometer, etc.)? HOT 1
- Slow api, ETIMEDOUT, ECONRESET, ECONNREFUSED HOT 14
- problem with setInterval wsp.send('ping') openWebSocket.js HOT 1
- { error: 500, msg: 'SyntaxError: Unexpected token < in JSON at position 0' } HOT 1
- New and Simple REST API with Ready Scripts
- Error 401: Wrong account or password HOT 21
- ewelink
- Unable to install on Raspberry Pi
- THR316 doesn't update
- Unable to use power consumption with sonoff POW Elite HOT 6
- Get Voltage and current on POWR2 device HOT 2
- Error 401: Wrong account or password -- again HOT 54
- Error: 406 { error: 406, msg: 'Authentication failed' } HOT 21
- Support for changing the network indicator led?
- Is There Any PHP Version HOT 1
- error: 401, msg: 'Wrong account or password'
- Sonoff Dual R3 - Power Consumption Issue HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ewelink-api.