node-easywechat 3.3.3 → 3.3.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -136,7 +136,7 @@ class Application {
|
|
|
136
136
|
getAuthorization(authorizationCode) {
|
|
137
137
|
return __awaiter(this, void 0, void 0, function* () {
|
|
138
138
|
let response = (yield this.getClient().request('post', 'cgi-bin/component/api_query_auth', {
|
|
139
|
-
|
|
139
|
+
json: {
|
|
140
140
|
component_appid: this.getAccount().getAppId(),
|
|
141
141
|
authorization_code: authorizationCode,
|
|
142
142
|
}
|
|
@@ -157,7 +157,7 @@ class Application {
|
|
|
157
157
|
refreshAuthorizerToken(authorizerAppId, authorizerRefreshToken) {
|
|
158
158
|
return __awaiter(this, void 0, void 0, function* () {
|
|
159
159
|
let response = (yield this.getClient().request('post', 'cgi-bin/component/api_authorizer_token', {
|
|
160
|
-
|
|
160
|
+
json: {
|
|
161
161
|
component_appid: this.getAccount().getAppId(),
|
|
162
162
|
authorizer_appid: authorizerAppId,
|
|
163
163
|
authorizer_refresh_token: authorizerRefreshToken,
|
|
@@ -177,7 +177,7 @@ class Application {
|
|
|
177
177
|
createPreAuthorizationCode() {
|
|
178
178
|
return __awaiter(this, void 0, void 0, function* () {
|
|
179
179
|
let response = (yield this.getClient().request('post', 'cgi-bin/component/api_create_preauthcode', {
|
|
180
|
-
|
|
180
|
+
json: {
|
|
181
181
|
component_appid: this.getAccount().getAppId(),
|
|
182
182
|
}
|
|
183
183
|
})).toObject();
|
|
@@ -67,7 +67,7 @@ class ComponentAccessToken {
|
|
|
67
67
|
refresh() {
|
|
68
68
|
return __awaiter(this, void 0, void 0, function* () {
|
|
69
69
|
let response = (yield this.httpClient.request('post', 'cgi-bin/component/api_component_token', {
|
|
70
|
-
|
|
70
|
+
data: {
|
|
71
71
|
component_appid: this.appId,
|
|
72
72
|
component_appsecret: this.secret,
|
|
73
73
|
component_verify_ticket: yield this.verifyTicket.getTicket(),
|
|
@@ -210,7 +210,7 @@ class Application {
|
|
|
210
210
|
return __awaiter(this, void 0, void 0, function* () {
|
|
211
211
|
if (!suiteAccessToken)
|
|
212
212
|
suiteAccessToken = this.getSuiteAccessToken();
|
|
213
|
-
let response = (yield this.getClient().request('
|
|
213
|
+
let response = (yield this.getClient().request('get', 'cgi-bin/service/get_pre_auth_code', {
|
|
214
214
|
params: {
|
|
215
215
|
suite_access_token: yield suiteAccessToken.getToken(),
|
|
216
216
|
}
|
|
@@ -67,7 +67,7 @@ class SuiteAccessToken {
|
|
|
67
67
|
refresh() {
|
|
68
68
|
return __awaiter(this, void 0, void 0, function* () {
|
|
69
69
|
let response = (yield this.httpClient.request('post', 'cgi-bin/service/get_suite_token', {
|
|
70
|
-
|
|
70
|
+
json: {
|
|
71
71
|
suite_id: this.suiteId,
|
|
72
72
|
suite_secret: this.suiteSecret,
|
|
73
73
|
suite_ticket: yield this.suiteTicket.getTicket(),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "node-easywechat",
|
|
3
|
-
"version": "3.3.
|
|
3
|
+
"version": "3.3.5",
|
|
4
4
|
"description": "EasyWechat SDK for Node.js (NOT OFFICIAL)",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
"axios-retry": "^3.3.1",
|
|
34
34
|
"form-data": "^4.0.0",
|
|
35
35
|
"merge": "^2.1.1",
|
|
36
|
-
"node-socialite": "^1.3.
|
|
36
|
+
"node-socialite": "^1.3.2",
|
|
37
37
|
"qs": "^6.10.3",
|
|
38
38
|
"raw-body": "^2.5.1",
|
|
39
39
|
"xml2js": "^0.5.0"
|