repzo 1.0.262 → 1.0.264
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/lib/index.d.ts +1 -0
- package/lib/index.js +4 -0
- package/lib/types/index.d.ts +14 -0
- package/package.json +1 -1
- package/src/index.ts +12 -0
- package/src/types/index.ts +18 -0
package/lib/index.d.ts
CHANGED
|
@@ -968,6 +968,7 @@ export default class Repzo {
|
|
|
968
968
|
get: (id: Service.Approval.Get.ID, params?: Service.Approval.Get.Params) => Promise<Service.Approval.Get.Result>;
|
|
969
969
|
create: (body: Service.Approval.Create.Body) => Promise<Service.Approval.Create.Result>;
|
|
970
970
|
update: (id: Service.Approval.Update.ID, body: Service.Approval.Update.Body) => Promise<Service.Approval.Update.Result>;
|
|
971
|
+
patch: (params: Service.Approval.Patch.Params, body: Service.Approval.Patch.Body) => Promise<Service.Approval.Patch.Result>;
|
|
971
972
|
remove: (id: Service.Approval.Remove.ID) => Promise<Service.Approval.Remove.Result>;
|
|
972
973
|
};
|
|
973
974
|
workorderCategory: {
|
package/lib/index.js
CHANGED
|
@@ -1813,6 +1813,10 @@ class Repzo {
|
|
|
1813
1813
|
let res = await this._update(this.svAPIEndpoint, this.approval._path + `/${id}`, body);
|
|
1814
1814
|
return res;
|
|
1815
1815
|
},
|
|
1816
|
+
patch: async (params, body) => {
|
|
1817
|
+
let res = await this._patch(this.svAPIEndpoint, this.approval._path, body, params);
|
|
1818
|
+
return res;
|
|
1819
|
+
},
|
|
1816
1820
|
remove: async (id) => {
|
|
1817
1821
|
let res = await this._delete(this.svAPIEndpoint, this.approval._path + `/${id}`);
|
|
1818
1822
|
return res;
|
package/lib/types/index.d.ts
CHANGED
|
@@ -8252,6 +8252,19 @@ export declare namespace Service {
|
|
|
8252
8252
|
type Body = UpdateBody;
|
|
8253
8253
|
type Result = Data;
|
|
8254
8254
|
}
|
|
8255
|
+
namespace Patch {
|
|
8256
|
+
type ID = string;
|
|
8257
|
+
type Params = {
|
|
8258
|
+
bulkUpdatePositions?: boolean;
|
|
8259
|
+
[key: string]: any;
|
|
8260
|
+
};
|
|
8261
|
+
type Body = Pick<Data, "_id" | "position">[];
|
|
8262
|
+
type Result = {
|
|
8263
|
+
messages: string[];
|
|
8264
|
+
errors: any[];
|
|
8265
|
+
status: "success" | "failed" | "partial";
|
|
8266
|
+
};
|
|
8267
|
+
}
|
|
8255
8268
|
namespace Remove {
|
|
8256
8269
|
type ID = string;
|
|
8257
8270
|
type Result = Data;
|
|
@@ -14556,6 +14569,7 @@ export declare namespace Service {
|
|
|
14556
14569
|
}
|
|
14557
14570
|
}
|
|
14558
14571
|
namespace AuthenticateAdmin {
|
|
14572
|
+
export type MfaMethod = "email" | "whatsapp" | "authenticator" | "recovery_codes";
|
|
14559
14573
|
interface Subscription_data {
|
|
14560
14574
|
name_space: string;
|
|
14561
14575
|
grace_until: number;
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -4621,6 +4621,18 @@ export default class Repzo {
|
|
|
4621
4621
|
);
|
|
4622
4622
|
return res;
|
|
4623
4623
|
},
|
|
4624
|
+
patch: async (
|
|
4625
|
+
params: Service.Approval.Patch.Params,
|
|
4626
|
+
body: Service.Approval.Patch.Body,
|
|
4627
|
+
): Promise<Service.Approval.Patch.Result> => {
|
|
4628
|
+
let res: Service.Approval.Patch.Result = await this._patch(
|
|
4629
|
+
this.svAPIEndpoint,
|
|
4630
|
+
this.approval._path,
|
|
4631
|
+
body,
|
|
4632
|
+
params,
|
|
4633
|
+
);
|
|
4634
|
+
return res;
|
|
4635
|
+
},
|
|
4624
4636
|
remove: async (
|
|
4625
4637
|
id: Service.Approval.Remove.ID,
|
|
4626
4638
|
): Promise<Service.Approval.Remove.Result> => {
|
package/src/types/index.ts
CHANGED
|
@@ -8806,6 +8806,19 @@ export namespace Service {
|
|
|
8806
8806
|
export type Body = UpdateBody;
|
|
8807
8807
|
export type Result = Data;
|
|
8808
8808
|
}
|
|
8809
|
+
export namespace Patch {
|
|
8810
|
+
export type ID = string;
|
|
8811
|
+
export type Params = {
|
|
8812
|
+
bulkUpdatePositions?: boolean;
|
|
8813
|
+
[key: string]: any;
|
|
8814
|
+
};
|
|
8815
|
+
export type Body = Pick<Data, "_id" | "position">[];
|
|
8816
|
+
export type Result = {
|
|
8817
|
+
messages: string[];
|
|
8818
|
+
errors: any[];
|
|
8819
|
+
status: "success" | "failed" | "partial";
|
|
8820
|
+
};
|
|
8821
|
+
}
|
|
8809
8822
|
export namespace Remove {
|
|
8810
8823
|
export type ID = string;
|
|
8811
8824
|
export type Result = Data;
|
|
@@ -15626,6 +15639,11 @@ export namespace Service {
|
|
|
15626
15639
|
}
|
|
15627
15640
|
|
|
15628
15641
|
export namespace AuthenticateAdmin {
|
|
15642
|
+
export type MfaMethod =
|
|
15643
|
+
| "email"
|
|
15644
|
+
| "whatsapp"
|
|
15645
|
+
| "authenticator"
|
|
15646
|
+
| "recovery_codes";
|
|
15629
15647
|
interface Subscription_data {
|
|
15630
15648
|
name_space: string;
|
|
15631
15649
|
grace_until: number;
|