@riocrypto/common 1.0.1407 → 1.0.1409

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.
@@ -72,6 +72,7 @@ export declare class RioAdminClient {
72
72
  id: string;
73
73
  phoneNumber: string;
74
74
  }[]>;
75
+ requestOnboardingReview(country: Country, userId?: string): Promise<User>;
75
76
  getOnboardingRequirements(userType: UserType, country: Country, countryOfOrigin: CountryOfOrigin): Promise<{
76
77
  textRequirements: ("personalId" | "taxId")[];
77
78
  fileRequirements: KYCFileType[];
@@ -127,6 +127,15 @@ class RioAdminClient {
127
127
  return response.data;
128
128
  });
129
129
  }
130
+ requestOnboardingReview(country, userId) {
131
+ return __awaiter(this, void 0, void 0, function* () {
132
+ const url = userId
133
+ ? `/api/users/${userId}/onboarding-review`
134
+ : `/api/users/onboarding-review`;
135
+ const { data } = yield this.axios.post(url, { country });
136
+ return data;
137
+ });
138
+ }
130
139
  getOnboardingRequirements(userType, country, countryOfOrigin) {
131
140
  return __awaiter(this, void 0, void 0, function* () {
132
141
  const { data } = yield this.axios.get(`/api/users/requirements`, {
@@ -50,6 +50,7 @@ export declare class RioClient {
50
50
  getUsers(page: number, limit?: number, query?: UserQuery): Promise<User[]>;
51
51
  getUBOS(page: number, limit?: number): Promise<UBO[]>;
52
52
  updateUser(update: UserUpdate, userId?: string): Promise<User>;
53
+ requestOnboardingReview(country: Country, userId?: string): Promise<User>;
53
54
  updateUBO(update: UBOUpdate, uboId?: string): Promise<UBO>;
54
55
  uploadCOI(id: string, formData: FormData): Promise<User>;
55
56
  uploadFile(id: string, country: CountryOfOrigin, fileType: KYCFileType, formData: FormData): Promise<User>;
@@ -91,6 +91,15 @@ class RioClient {
91
91
  return data;
92
92
  });
93
93
  }
94
+ requestOnboardingReview(country, userId) {
95
+ return __awaiter(this, void 0, void 0, function* () {
96
+ const url = userId
97
+ ? `/api/users/${userId}/onboarding-review`
98
+ : `/api/users/onboarding-review`;
99
+ const { data } = yield this.axios.post(url, { country });
100
+ return data;
101
+ });
102
+ }
94
103
  updateUBO(update, uboId) {
95
104
  return __awaiter(this, void 0, void 0, function* () {
96
105
  const { data } = yield this.axios.patch(`/api/ubos/${uboId}`, update);
@@ -0,0 +1,8 @@
1
+ import { BankAccount } from "../types/bank-account";
2
+ import { Subjects } from "./subjects";
3
+ export interface BankAccountDeletedEvent {
4
+ subject: Subjects.BankAccountDeleted;
5
+ data: {
6
+ bankAcount: BankAccount;
7
+ };
8
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -78,6 +78,7 @@ export declare enum Subjects {
78
78
  AuthorizedPhoneNumberCreated = "authorizedPhoneNumber:created",
79
79
  BankAccountCreated = "bankAccount:created",
80
80
  BankAccountUpdated = "bankAccount:updated",
81
+ BankAccountDeleted = "bankAccount:deleted",
81
82
  BankTransferCompleted = "bankTransfer:completed",
82
83
  BitsoReceivingAccountCreated = "bitsoReceivingAccount:created",
83
84
  BitsoBankAccountCreated = "bitsoBankAccount:created",
@@ -82,6 +82,7 @@ var Subjects;
82
82
  Subjects["AuthorizedPhoneNumberCreated"] = "authorizedPhoneNumber:created";
83
83
  Subjects["BankAccountCreated"] = "bankAccount:created";
84
84
  Subjects["BankAccountUpdated"] = "bankAccount:updated";
85
+ Subjects["BankAccountDeleted"] = "bankAccount:deleted";
85
86
  Subjects["BankTransferCompleted"] = "bankTransfer:completed";
86
87
  Subjects["BitsoReceivingAccountCreated"] = "bitsoReceivingAccount:created";
87
88
  Subjects["BitsoBankAccountCreated"] = "bitsoBankAccount:created";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riocrypto/common",
3
- "version": "1.0.1407",
3
+ "version": "1.0.1409",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",