@opexa/portal-sdk 0.59.8 → 0.59.9
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/dist/index.cjs +22 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.js +22 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -4041,6 +4041,17 @@ var AccountService = class {
|
|
|
4041
4041
|
data: res.data.memberVerificationRequestAutomaticApprovalEnabled
|
|
4042
4042
|
};
|
|
4043
4043
|
}
|
|
4044
|
+
async file(variables) {
|
|
4045
|
+
const res = await this.client.request(
|
|
4046
|
+
FILE_QUERY,
|
|
4047
|
+
variables
|
|
4048
|
+
);
|
|
4049
|
+
if (!res.ok) return res;
|
|
4050
|
+
return {
|
|
4051
|
+
ok: true,
|
|
4052
|
+
data: res.data.node
|
|
4053
|
+
};
|
|
4054
|
+
}
|
|
4044
4055
|
};
|
|
4045
4056
|
|
|
4046
4057
|
// src/utils/status-code-to-operation-error.ts
|
|
@@ -10803,6 +10814,17 @@ var Sdk = class {
|
|
|
10803
10814
|
data: res.data ? this.transformer.transform.file(res.data) : null
|
|
10804
10815
|
};
|
|
10805
10816
|
}
|
|
10817
|
+
/**
|
|
10818
|
+
* Similar to `file` query but uses the account service.
|
|
10819
|
+
*/
|
|
10820
|
+
async _file(id) {
|
|
10821
|
+
const res = await this.accountService.file({ id });
|
|
10822
|
+
if (!res.ok) return res;
|
|
10823
|
+
return {
|
|
10824
|
+
ok: true,
|
|
10825
|
+
data: res.data ? this.transformer.transform.file(res.data) : null
|
|
10826
|
+
};
|
|
10827
|
+
}
|
|
10806
10828
|
async uploadImageFile(input) {
|
|
10807
10829
|
const id = input.id ?? objectId.ObjectId.generate(ObjectType.File).toString();
|
|
10808
10830
|
const res = await this.fileService.uploadPrivateImageFile({
|