shred-api-client 1.9.12 → 1.9.14

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.
@@ -35,7 +35,7 @@ class ProjectAPI {
35
35
  }
36
36
  async list(context, query) {
37
37
  const endpointData = Project_schema_1.ProjectEndpoints.List;
38
- const data = await this.clientHTTP.makeRequest(this.env, endpointData.uri, endpointData.method, query, context);
38
+ const data = await this.clientHTTP.makeRequest(this.env, `${endpointData.uri}?startDate=${query.startDate}&endDate=${query.endDate}&timezone=${query.timeZone}`, endpointData.method, null, context);
39
39
  return data;
40
40
  }
41
41
  async deny(ctx, pId, denyFB) {
@@ -8,7 +8,7 @@ declare class UserAPI implements UserAPISchema {
8
8
  sendValidationCode(email: string): Promise<boolean>;
9
9
  changePassword(email: string, pass: string, passConfirm: string, code: number): Promise<boolean>;
10
10
  changeEmail(ctx: Context, email: string, code: number): Promise<boolean>;
11
- confirmCode(email: string, code: number): Promise<boolean>;
11
+ confirmCode(email: string, code: number, keepCode?: boolean): Promise<boolean>;
12
12
  isEmailAvaliable(email: string): Promise<boolean>;
13
13
  update(context: Context, update: Partial<Update>): Promise<boolean>;
14
14
  getBindedUsers(context: Context): Promise<User[]>;
@@ -25,9 +25,9 @@ class UserAPI {
25
25
  const data = await this.clientHTTP.makeRequest(this.env, endpointData.uri, endpointData.method, { email, code }, ctx);
26
26
  return data.success;
27
27
  }
28
- async confirmCode(email, code) {
28
+ async confirmCode(email, code, keepCode) {
29
29
  const endpointData = User_schema_1.UserEndpoints.ConfirmCode;
30
- const data = await this.clientHTTP.makeRequest(this.env, `${endpointData.uri}?email=${email}&code=${code}`, endpointData.method);
30
+ const data = await this.clientHTTP.makeRequest(this.env, `${endpointData.uri}?email=${email}&code=${code}&keepCode=${keepCode}`, endpointData.method);
31
31
  return data.success;
32
32
  }
33
33
  async isEmailAvaliable(email) {
@@ -4,7 +4,7 @@ interface UserAPISchema {
4
4
  getUserInfo: (context: Context) => Promise<User>;
5
5
  isEmailAvaliable: (email: string) => Promise<boolean>;
6
6
  sendValidationCode: (email: string) => Promise<boolean>;
7
- confirmCode: (email: string, code: number) => Promise<boolean>;
7
+ confirmCode: (email: string, code: number, keepCode?: boolean) => Promise<boolean>;
8
8
  changePassword: (email: string, pass: string, passConfirm: string, code: number) => Promise<boolean>;
9
9
  changeEmail: (ctx: Context, email: string, code: number) => Promise<boolean>;
10
10
  authenticate: (context: Context, system: System) => Promise<string>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shred-api-client",
3
- "version": "1.9.12",
3
+ "version": "1.9.14",
4
4
  "description": "API Client for Shred",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",