New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@tuyapi/openapi

Package Overview
Dependencies
Maintainers
2
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tuyapi/openapi - npm Package Compare versions

Comparing version

to
0.1.2

4

dist/api.js

@@ -45,3 +45,3 @@ "use strict";

headers: {
_client_id: this._key,
client_id: this._key,
sign_method: 'HMAC-SHA256'

@@ -59,3 +59,3 @@ },

if (this.tokenAccess === '') {
sign = crypto.createHmac('sha256', this._secret).update(`${this._key}${now}`).digest('hex').toUpperCase();
sign = crypto.createHmac('sha256', this._secret).update(this._key + now.toString()).digest('hex').toUpperCase();
} else {

@@ -62,0 +62,0 @@ sign = crypto.createHmac('sha256', this._secret).update(`${this._key}${this.tokenAccess}${now}`).digest('hex').toUpperCase();

{
"name": "@tuyapi/openapi",
"version": "0.1.0",
"version": "0.1.2",
"description": "🚪 a wrapper for Tuya's OpenAPI",

@@ -5,0 +5,0 @@ "main": "dist/api.js",

@@ -45,1 +45,3 @@ # A TypeScript wrapper for Tuya's [OpenAPI](https://docs.tuya.com/en/iot/open-api/quick-start/solution-overview)

```
## [Docs](https://tuyaapi.github.io/openapi/)