repzo 1.0.118 → 1.0.119
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 +8 -0
- package/lib/index.js +12 -0
- package/lib/types/index.d.ts +11 -1
- package/package.json +1 -1
- package/src/index.ts +17 -0
- package/src/types/index.ts +12 -1
package/lib/index.d.ts
CHANGED
|
@@ -86,6 +86,7 @@ export default class Repzo {
|
|
|
86
86
|
readonly SETTINGS: "settings";
|
|
87
87
|
readonly MAIL_UNSUBSCRIBE: "mail-unsubscribe";
|
|
88
88
|
readonly APPROVAL_REQUEST: "approval-request";
|
|
89
|
+
readonly SAFE_INVOICE_SERIAL_COUNTER: "safe-invoice-serial-counter";
|
|
89
90
|
};
|
|
90
91
|
private _fetch;
|
|
91
92
|
private _create;
|
|
@@ -1338,4 +1339,11 @@ export default class Repzo {
|
|
|
1338
1339
|
params: Service.ApprovalRequest.Remove.Params
|
|
1339
1340
|
) => Promise<Service.ApprovalRequest.Remove.Result>;
|
|
1340
1341
|
};
|
|
1342
|
+
safeInvoiceSerialCounter: {
|
|
1343
|
+
_path: "safe-invoice-serial-counter";
|
|
1344
|
+
update: (
|
|
1345
|
+
id: Service.SafeInvoiceSerialCounter.Update.ID,
|
|
1346
|
+
body: Service.SafeInvoiceSerialCounter.Update.Body
|
|
1347
|
+
) => Promise<Service.SafeInvoiceSerialCounter.Update.Result>;
|
|
1348
|
+
};
|
|
1341
1349
|
}
|
package/lib/index.js
CHANGED
|
@@ -75,6 +75,7 @@ export default class Repzo {
|
|
|
75
75
|
SETTINGS: "settings",
|
|
76
76
|
MAIL_UNSUBSCRIBE: "mail-unsubscribe",
|
|
77
77
|
APPROVAL_REQUEST: "approval-request",
|
|
78
|
+
SAFE_INVOICE_SERIAL_COUNTER: "safe-invoice-serial-counter",
|
|
78
79
|
};
|
|
79
80
|
this.END_POINTS = this._end_points;
|
|
80
81
|
this.client = {
|
|
@@ -2467,6 +2468,17 @@ export default class Repzo {
|
|
|
2467
2468
|
return res;
|
|
2468
2469
|
},
|
|
2469
2470
|
};
|
|
2471
|
+
this.safeInvoiceSerialCounter = {
|
|
2472
|
+
_path: this._end_points.SAFE_INVOICE_SERIAL_COUNTER,
|
|
2473
|
+
update: async (id, body) => {
|
|
2474
|
+
let res = await this._update(
|
|
2475
|
+
this.svAPIEndpoint,
|
|
2476
|
+
this.safeInvoiceSerialCounter._path + `/${id}`,
|
|
2477
|
+
body
|
|
2478
|
+
);
|
|
2479
|
+
return res;
|
|
2480
|
+
},
|
|
2481
|
+
};
|
|
2470
2482
|
this.svAPIEndpoint =
|
|
2471
2483
|
!options?.env || options?.env == "production"
|
|
2472
2484
|
? "https://sv.api.repzo.me"
|
package/lib/types/index.d.ts
CHANGED
|
@@ -6742,7 +6742,7 @@ export declare namespace Service {
|
|
|
6742
6742
|
};
|
|
6743
6743
|
cycle: Cycle.Schema & {
|
|
6744
6744
|
can_edit: boolean;
|
|
6745
|
-
current_nodes: string[];
|
|
6745
|
+
current_nodes: string[] | AdminOrRep[];
|
|
6746
6746
|
};
|
|
6747
6747
|
};
|
|
6748
6748
|
}
|
|
@@ -12738,6 +12738,16 @@ export declare namespace Service {
|
|
|
12738
12738
|
}
|
|
12739
12739
|
export {};
|
|
12740
12740
|
}
|
|
12741
|
+
namespace SafeInvoiceSerialCounter {
|
|
12742
|
+
interface UpdateBody {
|
|
12743
|
+
counter: number;
|
|
12744
|
+
}
|
|
12745
|
+
namespace Update {
|
|
12746
|
+
type ID = StringId;
|
|
12747
|
+
type Body = UpdateBody;
|
|
12748
|
+
type Result = Settings.Data;
|
|
12749
|
+
}
|
|
12750
|
+
}
|
|
12741
12751
|
}
|
|
12742
12752
|
export type StringId = string;
|
|
12743
12753
|
export type NameSpaces = string[];
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -110,6 +110,7 @@ export default class Repzo {
|
|
|
110
110
|
SETTINGS: "settings",
|
|
111
111
|
MAIL_UNSUBSCRIBE: "mail-unsubscribe",
|
|
112
112
|
APPROVAL_REQUEST: "approval-request",
|
|
113
|
+
SAFE_INVOICE_SERIAL_COUNTER: "safe-invoice-serial-counter",
|
|
113
114
|
} as const;
|
|
114
115
|
public END_POINTS = this._end_points;
|
|
115
116
|
private async _fetch(baseUrl: string, path: string, params?: Params) {
|
|
@@ -3798,6 +3799,22 @@ export default class Repzo {
|
|
|
3798
3799
|
return res;
|
|
3799
3800
|
},
|
|
3800
3801
|
};
|
|
3802
|
+
|
|
3803
|
+
safeInvoiceSerialCounter = {
|
|
3804
|
+
_path: this._end_points.SAFE_INVOICE_SERIAL_COUNTER,
|
|
3805
|
+
|
|
3806
|
+
update: async (
|
|
3807
|
+
id: Service.SafeInvoiceSerialCounter.Update.ID,
|
|
3808
|
+
body: Service.SafeInvoiceSerialCounter.Update.Body
|
|
3809
|
+
): Promise<Service.SafeInvoiceSerialCounter.Update.Result> => {
|
|
3810
|
+
let res: Service.SafeInvoiceSerialCounter.Update.Result = await this._update(
|
|
3811
|
+
this.svAPIEndpoint,
|
|
3812
|
+
this.safeInvoiceSerialCounter._path + `/${id}`,
|
|
3813
|
+
body
|
|
3814
|
+
);
|
|
3815
|
+
return res;
|
|
3816
|
+
},
|
|
3817
|
+
};
|
|
3801
3818
|
}
|
|
3802
3819
|
|
|
3803
3820
|
function normalizeParams(params: Params): { [key: string]: any } {
|
package/src/types/index.ts
CHANGED
|
@@ -6648,7 +6648,7 @@ export namespace Service {
|
|
|
6648
6648
|
};
|
|
6649
6649
|
cycle: Cycle.Schema & {
|
|
6650
6650
|
can_edit: boolean;
|
|
6651
|
-
current_nodes: string[];
|
|
6651
|
+
current_nodes: string[] | AdminOrRep[];
|
|
6652
6652
|
};
|
|
6653
6653
|
};
|
|
6654
6654
|
}
|
|
@@ -12276,6 +12276,17 @@ export namespace Service {
|
|
|
12276
12276
|
export type Result = Data;
|
|
12277
12277
|
}
|
|
12278
12278
|
}
|
|
12279
|
+
|
|
12280
|
+
export namespace SafeInvoiceSerialCounter {
|
|
12281
|
+
export interface UpdateBody {
|
|
12282
|
+
counter: number;
|
|
12283
|
+
}
|
|
12284
|
+
export namespace Update {
|
|
12285
|
+
export type ID = StringId;
|
|
12286
|
+
export type Body = UpdateBody;
|
|
12287
|
+
export type Result = Settings.Data;
|
|
12288
|
+
}
|
|
12289
|
+
}
|
|
12279
12290
|
}
|
|
12280
12291
|
|
|
12281
12292
|
export type StringId = string;
|