@doist/todoist-api-typescript 6.1.4 → 6.1.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/dist/cjs/rest-client.js
CHANGED
|
@@ -17,9 +17,14 @@ function paramsSerializer(params) {
|
|
|
17
17
|
if (Array.isArray(value)) {
|
|
18
18
|
qs.append(key, value.join(','));
|
|
19
19
|
}
|
|
20
|
-
else
|
|
20
|
+
else if (typeof value === 'string' ||
|
|
21
|
+
typeof value === 'number' ||
|
|
22
|
+
typeof value === 'boolean') {
|
|
21
23
|
qs.append(key, String(value));
|
|
22
24
|
}
|
|
25
|
+
else {
|
|
26
|
+
qs.append(key, JSON.stringify(value));
|
|
27
|
+
}
|
|
23
28
|
}
|
|
24
29
|
});
|
|
25
30
|
return qs.toString();
|
package/dist/esm/rest-client.js
CHANGED
|
@@ -12,9 +12,14 @@ export function paramsSerializer(params) {
|
|
|
12
12
|
if (Array.isArray(value)) {
|
|
13
13
|
qs.append(key, value.join(','));
|
|
14
14
|
}
|
|
15
|
-
else
|
|
15
|
+
else if (typeof value === 'string' ||
|
|
16
|
+
typeof value === 'number' ||
|
|
17
|
+
typeof value === 'boolean') {
|
|
16
18
|
qs.append(key, String(value));
|
|
17
19
|
}
|
|
20
|
+
else {
|
|
21
|
+
qs.append(key, JSON.stringify(value));
|
|
22
|
+
}
|
|
18
23
|
}
|
|
19
24
|
});
|
|
20
25
|
return qs.toString();
|
|
@@ -100,7 +100,8 @@ export declare function getAuthorizationUrl({ clientId, permissions, state, base
|
|
|
100
100
|
/**
|
|
101
101
|
* @deprecated Use options object instead: getAuthToken(args, { baseUrl, customFetch })
|
|
102
102
|
*/
|
|
103
|
-
export declare function getAuthToken(args: AuthTokenRequestArgs, baseUrl
|
|
103
|
+
export declare function getAuthToken(args: AuthTokenRequestArgs, baseUrl: string): Promise<AuthTokenResponse>;
|
|
104
|
+
export declare function getAuthToken(args: AuthTokenRequestArgs): Promise<AuthTokenResponse>;
|
|
104
105
|
export declare function getAuthToken(args: AuthTokenRequestArgs, options?: AuthOptions): Promise<AuthTokenResponse>;
|
|
105
106
|
/**
|
|
106
107
|
* Revokes an access token, making it invalid for future use.
|
|
@@ -121,7 +122,8 @@ export declare function getAuthToken(args: AuthTokenRequestArgs, options?: AuthO
|
|
|
121
122
|
/**
|
|
122
123
|
* @deprecated Use options object instead: revokeAuthToken(args, { baseUrl, customFetch })
|
|
123
124
|
*/
|
|
124
|
-
export declare function revokeAuthToken(args: RevokeAuthTokenRequestArgs, baseUrl
|
|
125
|
+
export declare function revokeAuthToken(args: RevokeAuthTokenRequestArgs, baseUrl: string): Promise<boolean>;
|
|
126
|
+
export declare function revokeAuthToken(args: RevokeAuthTokenRequestArgs): Promise<boolean>;
|
|
125
127
|
export declare function revokeAuthToken(args: RevokeAuthTokenRequestArgs, options?: AuthOptions): Promise<boolean>;
|
|
126
128
|
/**
|
|
127
129
|
* Revokes a token using the RFC 7009 OAuth 2.0 Token Revocation standard.
|
|
@@ -145,5 +147,6 @@ export declare function revokeAuthToken(args: RevokeAuthTokenRequestArgs, option
|
|
|
145
147
|
/**
|
|
146
148
|
* @deprecated Use options object instead: revokeToken(args, { baseUrl, customFetch })
|
|
147
149
|
*/
|
|
148
|
-
export declare function revokeToken(args: RevokeTokenRequestArgs, baseUrl
|
|
150
|
+
export declare function revokeToken(args: RevokeTokenRequestArgs, baseUrl: string): Promise<boolean>;
|
|
151
|
+
export declare function revokeToken(args: RevokeTokenRequestArgs): Promise<boolean>;
|
|
149
152
|
export declare function revokeToken(args: RevokeTokenRequestArgs, options?: AuthOptions): Promise<boolean>;
|
|
@@ -42,7 +42,8 @@ export declare class TodoistApi {
|
|
|
42
42
|
/**
|
|
43
43
|
* @deprecated Use options object instead: new TodoistApi(token, { baseUrl, customFetch })
|
|
44
44
|
*/
|
|
45
|
-
constructor(authToken: string, baseUrl
|
|
45
|
+
constructor(authToken: string, baseUrl: string);
|
|
46
|
+
constructor(authToken: string);
|
|
46
47
|
constructor(authToken: string, options?: TodoistApiOptions);
|
|
47
48
|
/**
|
|
48
49
|
* Retrieves information about the authenticated user.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@doist/todoist-api-typescript",
|
|
3
|
-
"version": "6.1.
|
|
3
|
+
"version": "6.1.5",
|
|
4
4
|
"description": "A typescript wrapper for the Todoist REST API.",
|
|
5
5
|
"author": "Doist developers",
|
|
6
6
|
"repository": "git@github.com:doist/todoist-api-typescript.git",
|
|
@@ -48,12 +48,12 @@
|
|
|
48
48
|
"zod": "4.1.12"
|
|
49
49
|
},
|
|
50
50
|
"devDependencies": {
|
|
51
|
-
"@doist/eslint-config": "
|
|
51
|
+
"@doist/eslint-config": "12.0.0",
|
|
52
52
|
"@doist/prettier-config": "4.0.0",
|
|
53
53
|
"@types/jest": "30.0.0",
|
|
54
|
-
"@typescript-eslint/eslint-plugin": "
|
|
55
|
-
"@typescript-eslint/parser": "
|
|
56
|
-
"eslint": "8.
|
|
54
|
+
"@typescript-eslint/eslint-plugin": "8.46.3",
|
|
55
|
+
"@typescript-eslint/parser": "8.46.3",
|
|
56
|
+
"eslint": "8.57.1",
|
|
57
57
|
"eslint-config-prettier": "8.7.0",
|
|
58
58
|
"eslint-import-resolver-webpack": "0.13.2",
|
|
59
59
|
"eslint-plugin-import": "2.27.5",
|