@riocrypto/common 1.0.676 → 1.0.679

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.
@@ -26,7 +26,7 @@ import { OrderUpdate } from "../types/order-update";
26
26
  export declare class RioAdminClient {
27
27
  private axios;
28
28
  constructor(axios: AxiosStatic | AxiosInstance);
29
- getOrders(): Promise<Order[]>;
29
+ getOrders(page?: number, limit?: number): Promise<Order[]>;
30
30
  getQuote(crypto: Crypto, fiat: Fiat, quoteInCrypto: boolean, side: Side, amountFiat?: Number, amountCrypto?: Number, country?: Country, paymentMethod?: PaymentMethod, payoutMethod?: PayoutMethod): Promise<Quote>;
31
31
  getUsers(type?: UserType, brokerId?: string): Promise<User[]>;
32
32
  signinAdmin(email: string, password: string, authenticatorCode: string): Promise<any>;
@@ -23,9 +23,16 @@ class RioAdminClient {
23
23
  return config;
24
24
  });
25
25
  }
26
- getOrders() {
26
+ getOrders(page, limit) {
27
27
  return __awaiter(this, void 0, void 0, function* () {
28
- const { data } = yield this.axios.get(`/api/orders`);
28
+ let url = `/api/orders?`;
29
+ if (page) {
30
+ url += `page=${page}&`;
31
+ }
32
+ if (limit) {
33
+ url += `limit=${limit}`;
34
+ }
35
+ const { data } = yield this.axios.get(url);
29
36
  return data;
30
37
  });
31
38
  }
@@ -8,10 +8,12 @@ const humanizeKYCStatus = (status) => {
8
8
  return "Failed";
9
9
  case kyc_status_1.KYCStatus.Review:
10
10
  return "Review";
11
- case kyc_status_1.KYCStatus.businessApproved:
12
- return "Business approved";
13
- case kyc_status_1.KYCStatus.Passed:
14
- return "Passed";
11
+ case kyc_status_1.KYCStatus.Approved:
12
+ return "Approved";
13
+ case kyc_status_1.KYCStatus.LegalRepresentativePassed:
14
+ return "Legal Representative Passed";
15
+ case kyc_status_1.KYCStatus.LegalRepresentativeFailed:
16
+ return "Legal Representative Failed";
15
17
  case kyc_status_1.KYCStatus.None:
16
18
  return "None";
17
19
  default:
@@ -1,7 +1,8 @@
1
1
  export declare enum KYCStatus {
2
- Passed = "passed",
2
+ Approved = "approved",
3
+ LegalRepresentativePassed = "legalRepresentativeApproved",
4
+ LegalRepresentativeFailed = "legalRepresentativeFailed",
3
5
  Failed = "failed",
4
6
  Review = "review",
5
- businessApproved = "businessApproved",
6
7
  None = "none"
7
8
  }
@@ -3,9 +3,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.KYCStatus = void 0;
4
4
  var KYCStatus;
5
5
  (function (KYCStatus) {
6
- KYCStatus["Passed"] = "passed";
6
+ KYCStatus["Approved"] = "approved";
7
+ KYCStatus["LegalRepresentativePassed"] = "legalRepresentativeApproved";
8
+ KYCStatus["LegalRepresentativeFailed"] = "legalRepresentativeFailed";
7
9
  KYCStatus["Failed"] = "failed";
8
10
  KYCStatus["Review"] = "review";
9
- KYCStatus["businessApproved"] = "businessApproved";
10
11
  KYCStatus["None"] = "none";
11
12
  })(KYCStatus = exports.KYCStatus || (exports.KYCStatus = {}));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riocrypto/common",
3
- "version": "1.0.676",
3
+ "version": "1.0.679",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",